From 8af06a9f25b8b0cc64f7b3667ecd361cd00b179a Mon Sep 17 00:00:00 2001 From: ByteHamster Date: Sat, 11 Nov 2023 10:52:16 +0100 Subject: [PATCH] Fix deeplink/search?query=xy intent (#6754) --- .../main/java/de/danoeh/antennapod/activity/MainActivity.java | 2 +- .../main/java/de/danoeh/antennapod/fragment/SearchFragment.java | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java b/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java index b42fb6d5f..1baa90d28 100644 --- a/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java +++ b/app/src/main/java/de/danoeh/antennapod/activity/MainActivity.java @@ -608,7 +608,7 @@ public class MainActivity extends CastEnabledActivity { } else if (intent.getBooleanExtra(MainActivityStarter.EXTRA_OPEN_PLAYER, false)) { sheetBehavior.setState(BottomSheetBehavior.STATE_EXPANDED); bottomSheetCallback.onSlide(null, 1.0f); - } else if (Intent.ACTION_VIEW.equals(intent.getAction())) { + } else { handleDeeplink(intent.getData()); } diff --git a/app/src/main/java/de/danoeh/antennapod/fragment/SearchFragment.java b/app/src/main/java/de/danoeh/antennapod/fragment/SearchFragment.java index 30822e5c5..0f959d9d1 100644 --- a/app/src/main/java/de/danoeh/antennapod/fragment/SearchFragment.java +++ b/app/src/main/java/de/danoeh/antennapod/fragment/SearchFragment.java @@ -248,6 +248,7 @@ public class SearchFragment extends Fragment implements EpisodeItemListAdapter.O item.expandActionView(); searchView = (SearchView) item.getActionView(); searchView.setQueryHint(getString(R.string.search_label)); + searchView.setQuery(getArguments().getString(ARG_QUERY), true); searchView.requestFocus(); searchView.setOnQueryTextListener(new SearchView.OnQueryTextListener() { @Override