mirror of
https://github.com/rustdesk/rustdesk.git
synced 2025-12-11 18:47:47 +00:00
switched to grid layout
This commit is contained in:
@@ -2,6 +2,7 @@ import 'dart:async';
|
||||
|
||||
import 'package:dash_chat_2/dash_chat_2.dart';
|
||||
import 'package:draggable_float_widget/draggable_float_widget.dart';
|
||||
import 'package:fluentui_system_icons/fluentui_system_icons.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_hbb/models/platform_model.dart';
|
||||
import 'package:get/get_rx/src/rx_types/rx_types.dart';
|
||||
@@ -104,21 +105,23 @@ class ChatModel with ChangeNotifier {
|
||||
|
||||
final overlay = OverlayEntry(builder: (context) {
|
||||
return DraggableFloatWidget(
|
||||
config: DraggableFloatWidgetBaseConfig(
|
||||
initPositionYInTop: false,
|
||||
initPositionYMarginBorder: 100,
|
||||
borderTopContainTopBar: true,
|
||||
),
|
||||
child: FloatingActionButton(
|
||||
onPressed: () {
|
||||
if (chatWindowOverlayEntry == null) {
|
||||
showChatWindowOverlay();
|
||||
} else {
|
||||
hideChatWindowOverlay();
|
||||
}
|
||||
},
|
||||
backgroundColor: Theme.of(context).colorScheme.primary,
|
||||
child: Icon(Icons.message)));
|
||||
config: DraggableFloatWidgetBaseConfig(
|
||||
initPositionYInTop: false,
|
||||
initPositionYMarginBorder: 100,
|
||||
borderTopContainTopBar: true,
|
||||
),
|
||||
child: FloatingActionButton(
|
||||
onPressed: () {
|
||||
if (chatWindowOverlayEntry == null) {
|
||||
showChatWindowOverlay();
|
||||
} else {
|
||||
hideChatWindowOverlay();
|
||||
}
|
||||
},
|
||||
backgroundColor: Theme.of(context).colorScheme.primary,
|
||||
child: Icon(FluentIcons.chat_24_filled),
|
||||
),
|
||||
);
|
||||
});
|
||||
overlayState.insert(overlay);
|
||||
chatIconOverlayEntry = overlay;
|
||||
|
||||
@@ -288,8 +288,8 @@ class ServerModel with ChangeNotifier {
|
||||
/// Toggle the screen sharing service.
|
||||
toggleService() async {
|
||||
if (_isStart) {
|
||||
final res =
|
||||
await parent.target?.dialogManager.show<bool>((setState, close, context) {
|
||||
final res = await parent.target?.dialogManager
|
||||
.show<bool>((setState, close, context) {
|
||||
submit() => close(true);
|
||||
return CustomAlertDialog(
|
||||
title: Row(children: [
|
||||
@@ -311,8 +311,8 @@ class ServerModel with ChangeNotifier {
|
||||
stopService();
|
||||
}
|
||||
} else {
|
||||
final res =
|
||||
await parent.target?.dialogManager.show<bool>((setState, close, context) {
|
||||
final res = await parent.target?.dialogManager
|
||||
.show<bool>((setState, close, context) {
|
||||
submit() => close(true);
|
||||
return CustomAlertDialog(
|
||||
title: Row(children: [
|
||||
|
||||
Reference in New Issue
Block a user