mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
opt: close popup dialog with anim
This commit is contained in:
34
lib/common/widgets/no_splash_factory.dart
Normal file
34
lib/common/widgets/no_splash_factory.dart
Normal file
@@ -0,0 +1,34 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class NoSplashFactory extends InteractiveInkFeatureFactory {
|
||||
@override
|
||||
InteractiveInkFeature create(
|
||||
{required MaterialInkController controller,
|
||||
required RenderBox referenceBox,
|
||||
required Offset position,
|
||||
required Color color,
|
||||
required TextDirection textDirection,
|
||||
bool containedInkWell = false,
|
||||
RectCallback? rectCallback,
|
||||
BorderRadius? borderRadius,
|
||||
ShapeBorder? customBorder,
|
||||
double? radius,
|
||||
VoidCallback? onRemoved}) {
|
||||
return _NoInteractiveInkFeature(
|
||||
controller: controller,
|
||||
referenceBox: referenceBox,
|
||||
color: color,
|
||||
onRemoved: onRemoved);
|
||||
}
|
||||
}
|
||||
|
||||
class _NoInteractiveInkFeature extends InteractiveInkFeature {
|
||||
@override
|
||||
void paintFeature(Canvas canvas, Matrix4 transform) {}
|
||||
_NoInteractiveInkFeature({
|
||||
required super.controller,
|
||||
required super.referenceBox,
|
||||
required super.color,
|
||||
super.onRemoved,
|
||||
});
|
||||
}
|
||||
Reference in New Issue
Block a user