@@ -16,6 +16,8 @@ class PButton extends PlatformAdaptingWidget {
16
16
final Color androidTextColor;
17
17
final Color androidSplashColor;
18
18
final double androidElevation;
19
+ final double androidFocusElevation;
20
+ final double androidHoverElevation;
19
21
final double androidHighlightElevation;
20
22
final double androidDisabledElevation;
21
23
final Clip androidClipBehavior;
@@ -25,8 +27,12 @@ class PButton extends PlatformAdaptingWidget {
25
27
final ShapeBorder androidShape;
26
28
final Color androidHighlightColor;
27
29
final ButtonTextTheme androidTextTheme;
28
-
30
+ final ValueChanged < bool > androidOnHighlightChanged;
29
31
final Color androidDisabledTextColor;
32
+ final Color androidFocusColor;
33
+ final Color androidHoverColor;
34
+ final FocusNode androidFocusNode;
35
+ final bool androidAutofocus;
30
36
31
37
final BorderRadius iosBorderRadius;
32
38
final double iosPressedOpacity;
@@ -55,6 +61,13 @@ class PButton extends PlatformAdaptingWidget {
55
61
this .androidHighlightColor,
56
62
this .androidTextTheme,
57
63
this .androidDisabledTextColor,
64
+ this .androidOnHighlightChanged,
65
+ this .androidFocusColor,
66
+ this .androidHoverColor,
67
+ this .androidFocusNode,
68
+ this .androidAutofocus = false ,
69
+ this .androidFocusElevation,
70
+ this .androidHoverElevation,
58
71
TargetPlatform renderPlatform})
59
72
: super (key: key, renderPlatform: renderPlatform);
60
73
@@ -80,6 +93,13 @@ class PButton extends PlatformAdaptingWidget {
80
93
highlightColor: androidHighlightColor,
81
94
textTheme: androidTextTheme,
82
95
disabledTextColor: androidDisabledTextColor,
96
+ onHighlightChanged: androidOnHighlightChanged,
97
+ focusColor: androidFocusColor,
98
+ hoverColor: androidHoverColor,
99
+ focusNode: androidFocusNode,
100
+ autofocus: androidAutofocus,
101
+ focusElevation: androidFocusElevation,
102
+ hoverElevation: androidHoverElevation,
83
103
);
84
104
};
85
105
@@ -131,6 +151,20 @@ class PFlatButton extends PlatformAdaptingWidget {
131
151
final double iosMinSize;
132
152
final PAlertData iosAlertData;
133
153
154
+ final ValueChanged <bool > androidOnHighlightChanged;
155
+ final ButtonTextTheme androidTextTheme;
156
+ final Color androidTextColor;
157
+ final Color androidDisabledTextColor;
158
+ final Color androidFocusColor;
159
+ final Color androidHoverColor;
160
+ final Color androidHighlightColor;
161
+ final Color androidSplashColor;
162
+ final Brightness androidColorBrightness;
163
+ final Clip androidClipBehavior;
164
+ final FocusNode androidFocusNode;
165
+ final bool androidAutofocus;
166
+ final MaterialTapTargetSize androidMaterialTapTargetSize;
167
+
134
168
const PFlatButton (
135
169
{Key key,
136
170
@required this .child,
@@ -143,6 +177,19 @@ class PFlatButton extends PlatformAdaptingWidget {
143
177
this .iosPressedOpacity = 0.1 ,
144
178
this .iosMinSize = 44.0 ,
145
179
this .iosAlertData,
180
+ this .androidOnHighlightChanged,
181
+ this .androidTextTheme,
182
+ this .androidTextColor,
183
+ this .androidDisabledTextColor,
184
+ this .androidFocusColor,
185
+ this .androidHoverColor,
186
+ this .androidHighlightColor,
187
+ this .androidSplashColor,
188
+ this .androidColorBrightness,
189
+ this .androidClipBehavior = Clip .none,
190
+ this .androidFocusNode,
191
+ this .androidAutofocus = false ,
192
+ this .androidMaterialTapTargetSize,
146
193
TargetPlatform renderPlatform})
147
194
: super (key: key, renderPlatform: renderPlatform);
148
195
@@ -181,6 +228,19 @@ class PFlatButton extends PlatformAdaptingWidget {
181
228
disabledColor: disabledColor,
182
229
padding: padding,
183
230
shape: androidShape,
231
+ onHighlightChanged: androidOnHighlightChanged,
232
+ textTheme: androidTextTheme,
233
+ textColor: androidTextColor,
234
+ disabledTextColor: androidDisabledTextColor,
235
+ focusColor: androidFocusColor,
236
+ hoverColor: androidHoverColor,
237
+ highlightColor: androidHighlightColor,
238
+ splashColor: androidSplashColor,
239
+ colorBrightness: androidColorBrightness,
240
+ clipBehavior: androidClipBehavior,
241
+ focusNode: androidFocusNode,
242
+ autofocus: androidAutofocus,
243
+ materialTapTargetSize: androidMaterialTapTargetSize,
184
244
);
185
245
};
186
246
0 commit comments