File tree 1 file changed +9
-0
lines changed
1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change 1
1
import 'dart:async' ;
2
2
3
3
import 'package:flutter/material.dart' ;
4
+ import 'package:fluttertoast/fluttertoast.dart' ;
4
5
import 'package:gsy_github_app_flutter/common/dao/ReposDao.dart' ;
5
6
import 'package:gsy_github_app_flutter/common/model/FileModel.dart' ;
6
7
import 'package:gsy_github_app_flutter/common/style/GSYStyle.dart' ;
@@ -91,6 +92,10 @@ class RepositoryDetailFileListPageState extends GSYListState<RepositoryDetailFil
91
92
92
93
///头部列表点击
93
94
_resolveHeaderClick (index) {
95
+ if (isLoading) {
96
+ Fluttertoast .showToast (msg: CommonUtils .getLocale (context).loading_text);
97
+ return ;
98
+ }
94
99
if (headerList[index] != "." ) {
95
100
List <String > newHeaderList = headerList.sublist (0 , index + 1 );
96
101
String path = newHeaderList.sublist (1 , newHeaderList.length).join ("/" );
@@ -111,6 +116,10 @@ class RepositoryDetailFileListPageState extends GSYListState<RepositoryDetailFil
111
116
///item文件列表点击
112
117
_resolveItemClick (FileItemViewModel fileItemViewModel) {
113
118
if (fileItemViewModel.type == "dir" ) {
119
+ if (isLoading) {
120
+ Fluttertoast .showToast (msg: CommonUtils .getLocale (context).loading_text);
121
+ return ;
122
+ }
114
123
this .setState (() {
115
124
headerList.add (fileItemViewModel.name);
116
125
});
You can’t perform that action at this time.
0 commit comments