This commit is contained in:
toly
2023-10-23 10:17:40 +08:00
parent bcba7ebae2
commit e26099ac18
50 changed files with 3616 additions and 135 deletions

View File

@@ -0,0 +1,22 @@
import 'package:flutter/material.dart';
import 'package:window_manager/window_manager.dart';
class DragToMoveWrap extends StatelessWidget {
final Widget child;
const DragToMoveWrap({
Key? key,
required this.child,
}) : super(key: key);
@override
Widget build(BuildContext context) {
return GestureDetector(
behavior: HitTestBehavior.translucent,
onPanStart: (details) {
windowManager.startDragging();
},
child: child,
);
}
}