From 0711650ff8c7827bdfee8d0b6b5fcb24b412903d Mon Sep 17 00:00:00 2001 From: Roy Yosef Date: Sat, 6 Jun 2020 23:44:04 +0300 Subject: [PATCH] Fix search suggestions not working on resume * add searchSuggestionString, isCorrectedSearch fields to state and load onResume --- .../fragments/list/search/SearchFragment.java | 27 ++++++++++++++----- 1 file changed, 20 insertions(+), 7 deletions(-) diff --git a/app/src/main/java/org/schabi/newpipe/fragments/list/search/SearchFragment.java b/app/src/main/java/org/schabi/newpipe/fragments/list/search/SearchFragment.java index a5c3d0bb8..aa2ad8340 100644 --- a/app/src/main/java/org/schabi/newpipe/fragments/list/search/SearchFragment.java +++ b/app/src/main/java/org/schabi/newpipe/fragments/list/search/SearchFragment.java @@ -118,6 +118,12 @@ public class SearchFragment extends BaseListFragment { correctSuggestionPanel.setVisibility(View.GONE); - search(result.getSearchSuggestion(), contentFilter, sortFilter); - searchEditText.setText(result.getSearchSuggestion()); + search(searchSuggestion, contentFilter, sortFilter); + searchEditText.setText(searchSuggestion); }); correctSuggestionPanel.setVisibility(View.VISIBLE);