Merge pull request #2936 from kiwix/Issue#625

Search widget issue fix
This commit is contained in:
Kelson 2022-08-10 14:17:23 +02:00 committed by GitHub
commit 0e644e813a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 0 deletions

View File

@ -157,6 +157,7 @@ abstract class CoreMainActivity : BaseActivity(), WebViewProvider {
override fun onNewIntent(intent: Intent) {
super.onNewIntent(intent)
this.intent.action = intent.action
activeFragments().filterIsInstance<FragmentActivityExtensions>().forEach {
it.onNewIntent(intent, this)
}

View File

@ -1240,12 +1240,15 @@ public abstract class CoreReaderFragment extends BaseFragment
}
case CoreSearchWidget.TEXT_CLICKED:
goToSearch(false);
intent.setAction(null);
break;
case CoreSearchWidget.STAR_CLICKED:
goToBookmarks();
intent.setAction(null);
break;
case CoreSearchWidget.MIC_CLICKED:
goToSearch(true);
intent.setAction(null);
break;
case Intent.ACTION_VIEW:
if (intent.getType() == null || !intent.getType().equals("application/octet-stream")) {