switch sides

Signed-off-by: 21pages <pages21@163.com>
This commit is contained in:
21pages
2023-01-17 13:28:33 +08:00
parent 45c0e10102
commit 333092f983
49 changed files with 373 additions and 61 deletions

View File

@@ -516,6 +516,15 @@ class _CmControlPanel extends StatelessWidget {
return Column(
mainAxisAlignment: MainAxisAlignment.end,
children: [
Offstage(
offstage: !client.fromSwitch,
child: buildButton(context,
color: Colors.purple,
onClick: () => handleSwitchBack(context),
icon: Icon(Icons.reply, color: Colors.white),
text: "Switch Sides",
textColor: Colors.white),
),
Offstage(
offstage: !showElevation,
child: buildButton(context, color: Colors.green[700], onClick: () {
@@ -674,6 +683,10 @@ class _CmControlPanel extends StatelessWidget {
windowManager.close();
}
}
void handleSwitchBack(BuildContext context) {
bind.cmSwitchBack(connId: client.id);
}
}
void checkClickTime(int id, Function() callback) async {