@@ -26,24 +26,24 @@ class FirstPageState extends State<FirstPage> with AutomaticKeepAliveClientMixin
26
26
bool get wantKeepAlive => true ;
27
27
28
28
29
- @override
29
+ @override
30
30
void initState () {
31
31
super .initState ();
32
32
if (key == null ) {
33
- key = GlobalKey <DisclaimerMsgState >();
34
- // key = const Key('__RIKEY1__');
33
+ key = GlobalKey <DisclaimerMsgState >();
34
+ // key = const Key('__RIKEY1__');
35
35
//获取sharePre
36
- _unKnow = _prefs.then ((SharedPreferences prefs) {
37
- return (prefs.getBool ('disclaimer::Boolean' ) ?? false );
38
- });
36
+ _unKnow = _prefs.then ((SharedPreferences prefs) {
37
+ return (prefs.getBool ('disclaimer::Boolean' ) ?? false );
38
+ });
39
39
40
40
/// 判断是否需要弹出免责声明,已经勾选过不在显示,就不会主动弹
41
41
_unKnow.then ((bool value) {
42
- new Future .delayed (const Duration (seconds: 1 ),(){
43
- if (! value && key.currentState is DisclaimerMsgState && key.currentState.showAlertDialog is Function ) {
44
- key.currentState.showAlertDialog (context);
45
- }
46
- });
42
+ new Future .delayed (const Duration (seconds: 1 ),(){
43
+ if (! value && key.currentState is DisclaimerMsgState && key.currentState.showAlertDialog is Function ) {
44
+ key.currentState.showAlertDialog (context);
45
+ }
46
+ });
47
47
});
48
48
}
49
49
}
@@ -93,15 +93,15 @@ class FirstPageState extends State<FirstPage> with AutomaticKeepAliveClientMixin
93
93
Column (
94
94
children: < Widget > [
95
95
Stack (
96
- //alignment: const FractionalOffset(0.9, 0.1),//方法一
97
- children: < Widget > [
98
- Pagination (),
99
- Positioned (//方法二
100
- top: 10.0 ,
101
- left: 0.0 ,
102
- child: DisclaimerMsg (key: key,pWidget: this )
103
- ),
104
- ]),
96
+ //alignment: const FractionalOffset(0.9, 0.1),//方法一
97
+ children: < Widget > [
98
+ Pagination (),
99
+ Positioned (//方法二
100
+ top: 10.0 ,
101
+ left: 0.0 ,
102
+ child: DisclaimerMsg (key: key,pWidget: this )
103
+ ),
104
+ ]),
105
105
SizedBox (height: 1 , child: Container (color: Theme .of (context).primaryColor)),
106
106
SizedBox (height: 10 ),
107
107
],
@@ -127,7 +127,7 @@ class FirstPageState extends State<FirstPage> with AutomaticKeepAliveClientMixin
127
127
// SizedBox(height: 2, child:Container(color: Theme.of(context).primaryColor)),
128
128
new Expanded (
129
129
//child: new List(),
130
- child: listComp.ListRefresh (getIndexListData,makeCard,headerView)
130
+ child: listComp.ListRefresh (getIndexListData,makeCard,headerView)
131
131
)
132
132
]
133
133
0 commit comments