File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1010 android : theme =" @style/LaunchTheme"
1111 android : configChanges =" orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
1212 android : hardwareAccelerated =" true"
13- android : windowSoftInputMode =" adjustResize" >
13+ android : windowSoftInputMode =" adjustResize"
14+ android : allowBackup =" false"
15+ android : fullBackupContent =" false" >
1416 <!-- Specifies an Android theme to apply to this Activity as soon as
1517 the Android process has started. This theme is visible to the user
1618 while the Flutter UI initializes. After that, this theme continues
Original file line number Diff line number Diff line change @@ -159,6 +159,11 @@ class TimeTableService with ChangeNotifier {
159159
160160 Future <String > getSchool () async {
161161 final prefs = await SharedPreferences .getInstance ();
162+ final school = prefs.getString ("school" );
163+
164+ if (school == null || school.isEmpty) {
165+ return "bbs1-mainz" ;
166+ }
162167 return prefs.getString ("school" ) ?? "bbs1-mainz" ;
163168 }
164169
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ class LoginScreen extends ConsumerStatefulWidget {
1515class _LoginScreenState extends ConsumerState <LoginScreen > {
1616 final usernameController = TextEditingController ();
1717 final passwordController = TextEditingController ();
18- final schoolController = TextEditingController ();
18+ final schoolController = TextEditingController (text : "bbs1-mainz" );
1919 final passwordFocusNode = FocusNode ();
2020 final schoolFocusNode = FocusNode ();
2121
@@ -33,11 +33,11 @@ class _LoginScreenState extends ConsumerState<LoginScreen> {
3333 Future <void > getUserDataFromStorage () async {
3434 final username = await ref.read (timeTableService).getUserName ();
3535 final password = await ref.read (timeTableService).getPassword ();
36- final school = await ref. read (timeTableService). getSchool () ;
36+ const school = "bbs1-mainz" ;
3737
3838 usernameController.text = username;
3939 passwordController.text = password;
40- schoolController.text = school ;
40+ schoolController.text = "bbs1-mainz" ;
4141
4242 if (username.isNotEmpty && password.isNotEmpty && school.isNotEmpty) {
4343 ref.read (timeTableService).login (
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ dependencies:
1515 flutter :
1616 sdk : flutter
1717 flutter_search_bar : ^3.0.0-dev.1
18- flutter_secure_storage : ^5.0.2
18+ flutter_secure_storage : 4.2.1
1919 flutter_staggered_animations : ^1.0.0
2020 fluttericon : ^2.0.0
2121 google_fonts : 2.2.0
Original file line number Diff line number Diff line change 66
77#include " generated_plugin_registrant.h"
88
9- #include < flutter_secure_storage_windows/flutter_secure_storage_windows_plugin.h>
109#include < url_launcher_windows/url_launcher_windows.h>
1110
1211void RegisterPlugins (flutter::PluginRegistry* registry) {
13- FlutterSecureStorageWindowsPluginRegisterWithRegistrar (
14- registry->GetRegistrarForPlugin (" FlutterSecureStorageWindowsPlugin" ));
1512 UrlLauncherWindowsRegisterWithRegistrar (
1613 registry->GetRegistrarForPlugin (" UrlLauncherWindows" ));
1714}
Original file line number Diff line number Diff line change 33#
44
55list (APPEND FLUTTER_PLUGIN_LIST
6- flutter_secure_storage_windows
76 url_launcher_windows
87)
98
You can’t perform that action at this time.
0 commit comments