mirror of
https://github.com/git-touch/git-touch
synced 2024-12-18 19:22:54 +01:00
improvement: action tap effect
This commit is contained in:
parent
ffa3ef79d9
commit
68e031ebe5
@ -48,9 +48,11 @@ class ActionButton extends StatelessWidget {
|
||||
final theme = Provider.of<ThemeModel>(context);
|
||||
switch (theme.theme) {
|
||||
case AppThemeType.cupertino:
|
||||
return GestureDetector(
|
||||
return CupertinoButton(
|
||||
minSize: 0,
|
||||
child: Icon(iconData, size: 22),
|
||||
onTap: () async {
|
||||
padding: EdgeInsets.zero,
|
||||
onPressed: () async {
|
||||
var value = await showCupertinoModalPopup<int>(
|
||||
context: context,
|
||||
builder: (BuildContext context) {
|
||||
|
@ -1,3 +1,4 @@
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:git_touch/models/theme.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
@ -11,9 +12,11 @@ class ActionEntry extends StatelessWidget {
|
||||
Widget build(BuildContext context) {
|
||||
switch (Provider.of<ThemeModel>(context).theme) {
|
||||
case AppThemeType.cupertino:
|
||||
return GestureDetector(
|
||||
return CupertinoButton(
|
||||
minSize: 0,
|
||||
child: Icon(iconData, size: 22),
|
||||
onTap: onTap,
|
||||
padding: EdgeInsets.zero,
|
||||
onPressed: onTap,
|
||||
);
|
||||
default:
|
||||
return IconButton(
|
||||
|
Loading…
Reference in New Issue
Block a user