@@ -117,44 +117,48 @@ class YYDialog {
117117 child: Row (
118118 mainAxisAlignment: getRowMainAxisAlignment (gravity),
119119 children: < Widget > [
120- FlatButton (
120+ TextButton (
121121 onPressed: () {
122122 if (onTap1 != null ) onTap1 ();
123123 if (isClickAutoDismiss) {
124124 dismiss ();
125125 }
126126 },
127- padding: buttonPadding1,
128- child: Text (
129- text1 ?? "" ,
130- style: TextStyle (
127+ style: TextButton .styleFrom (
128+ padding: buttonPadding1,
129+ textStyle: TextStyle (
131130 color: color1 ?? null ,
132131 fontSize: fontSize1 ?? null ,
133132 fontWeight: fontWeight1,
134133 fontFamily: fontFamily1,
135- ),
134+ )
135+ ),
136+ child: Text (
137+ text1 ?? "" ,
136138 ),
137139 ),
138140 Visibility (
139141 visible: withDivider,
140142 child: VerticalDivider (),
141143 ),
142- FlatButton (
144+ TextButton (
143145 onPressed: () {
144146 if (onTap2 != null ) onTap2 ();
145147 if (isClickAutoDismiss) {
146148 dismiss ();
147149 }
148150 },
149- padding: buttonPadding2,
151+ style: TextButton .styleFrom (
152+ padding: buttonPadding2,
153+ textStyle: TextStyle (
154+ color: color2 ?? Colors .black,
155+ fontSize: fontSize2 ?? 14.0 ,
156+ fontWeight: fontWeight2,
157+ fontFamily: fontFamily2,
158+ ),
159+ ),
150160 child: Text (
151161 text2 ?? "" ,
152- style: TextStyle (
153- color: color2 ?? Colors .black,
154- fontSize: fontSize2 ?? 14.0 ,
155- fontWeight: fontWeight2,
156- fontFamily: fontFamily2,
157- ),
158162 ),
159163 )
160164 ],
0 commit comments