-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix endless loading in TimetableSearchPage
- Loading branch information
1 parent
9924c4d
commit e3080f2
Showing
2 changed files
with
5 additions
and
30 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 0 additions & 19 deletions
19
...eatures/timetable_search_page/state_holders/timetable_search_page_querry_in_progress.dart
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,20 +1 @@ | ||
import 'package:flutter_riverpod/flutter_riverpod.dart'; | ||
|
||
final timetableSearchPageQuerryInProgress = | ||
StateNotifierProvider<TimetableSearchPageQuerryInProgressNotifier, int>( | ||
(ref) { | ||
return TimetableSearchPageQuerryInProgressNotifier( | ||
0, | ||
); | ||
}); | ||
|
||
class TimetableSearchPageQuerryInProgressNotifier extends StateNotifier<int> { | ||
TimetableSearchPageQuerryInProgressNotifier(super.state); | ||
|
||
@override | ||
get state => super.state; | ||
|
||
void add() => state = state + 1; | ||
|
||
void sub() => state = state - 1; | ||
} |