mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
opt: store search index
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -19,6 +19,8 @@ class SSearchController extends GetxController {
|
||||
|
||||
Rx<LoadingState> loadingState = LoadingState.loading().obs;
|
||||
|
||||
int initIndex = 0;
|
||||
|
||||
@override
|
||||
void onInit() {
|
||||
super.onInit();
|
||||
@@ -74,9 +76,13 @@ class SSearchController extends GetxController {
|
||||
GStorage.historyWord.put('cacheList', historyList);
|
||||
searchFocusNode.unfocus();
|
||||
|
||||
await Get.toNamed('/searchResult', parameters: {
|
||||
'keyword': controller.text,
|
||||
});
|
||||
await Get.toNamed(
|
||||
'/searchResult',
|
||||
parameters: {
|
||||
'keyword': controller.text,
|
||||
},
|
||||
arguments: initIndex,
|
||||
);
|
||||
searchFocusNode.requestFocus();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user