flutter_desktop: disable scroll wheel event
Signed-off-by: fufesou <shuanglongchen@yeah.net>
This commit is contained in:
parent
98d66ed43c
commit
b731d8e38a
@ -906,54 +906,30 @@ class ImagePaint extends StatelessWidget {
|
|||||||
}
|
}
|
||||||
|
|
||||||
Widget _buildCrossScrollbar(Widget child) {
|
Widget _buildCrossScrollbar(Widget child) {
|
||||||
debugPrint(
|
final physicsVertical =
|
||||||
'REMOVE ME ==================================== _buildCrossScrollbar ${cursorOverImage.value}');
|
cursorOverImage.value ? const NeverScrollableScrollPhysics() : null;
|
||||||
// final physicsVertical =
|
final physicsHorizontal =
|
||||||
// cursorOverImage.value ? const NeverScrollableScrollPhysics() : null;
|
cursorOverImage.value ? const NeverScrollableScrollPhysics() : null;
|
||||||
// final physicsHorizontal =
|
return Scrollbar(
|
||||||
// cursorOverImage.value ? const NeverScrollableScrollPhysics() : null;
|
controller: _vertical,
|
||||||
|
thumbVisibility: true,
|
||||||
if (cursorOverImage.value) {
|
trackVisibility: true,
|
||||||
return Scrollbar(
|
child: Scrollbar(
|
||||||
controller: _vertical,
|
controller: _horizontal,
|
||||||
thumbVisibility: true,
|
thumbVisibility: true,
|
||||||
trackVisibility: true,
|
trackVisibility: true,
|
||||||
child: Scrollbar(
|
notificationPredicate: (notif) => notif.depth == 1,
|
||||||
controller: _horizontal,
|
child: SingleChildScrollView(
|
||||||
thumbVisibility: true,
|
controller: _vertical,
|
||||||
trackVisibility: true,
|
physics: physicsVertical,
|
||||||
notificationPredicate: (notif) => notif.depth == 1,
|
|
||||||
child: SingleChildScrollView(
|
child: SingleChildScrollView(
|
||||||
controller: _vertical,
|
controller: _horizontal,
|
||||||
physics: const NeverScrollableScrollPhysics(),
|
scrollDirection: Axis.horizontal,
|
||||||
child: SingleChildScrollView(
|
physics: physicsHorizontal,
|
||||||
controller: _horizontal,
|
child: child,
|
||||||
scrollDirection: Axis.horizontal,
|
|
||||||
physics: const NeverScrollableScrollPhysics(),
|
|
||||||
child: child,
|
|
||||||
),
|
|
||||||
),
|
),
|
||||||
));
|
),
|
||||||
} else {
|
));
|
||||||
return Scrollbar(
|
|
||||||
controller: _vertical,
|
|
||||||
thumbVisibility: true,
|
|
||||||
trackVisibility: true,
|
|
||||||
child: Scrollbar(
|
|
||||||
controller: _horizontal,
|
|
||||||
thumbVisibility: true,
|
|
||||||
trackVisibility: true,
|
|
||||||
notificationPredicate: (notif) => notif.depth == 1,
|
|
||||||
child: SingleChildScrollView(
|
|
||||||
controller: _vertical,
|
|
||||||
child: SingleChildScrollView(
|
|
||||||
controller: _horizontal,
|
|
||||||
scrollDirection: Axis.horizontal,
|
|
||||||
child: child,
|
|
||||||
),
|
|
||||||
),
|
|
||||||
));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Widget _buildListener(Widget child) {
|
Widget _buildListener(Widget child) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user