From 77a3acf5cc24410c7bc4b53b30c1f2e8e2f6f63c Mon Sep 17 00:00:00 2001 From: Rajat <38572147+afreakyelf@users.noreply.github.com> Date: Wed, 26 Jan 2022 23:37:26 -0500 Subject: [PATCH] Fix search inputs accepting formatted text (#6501) * Fix Global and extension search input accepts formatted text #6495 * Code change as requested because of performance issue * code changes as requested * minor code changes --- .../controller/SearchableNucleusController.kt | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/base/controller/SearchableNucleusController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/base/controller/SearchableNucleusController.kt index ddeadcb33f..1f6e7dbd09 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/base/controller/SearchableNucleusController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/base/controller/SearchableNucleusController.kt @@ -2,12 +2,16 @@ package eu.kanade.tachiyomi.ui.base.controller import android.app.Activity import android.os.Bundle +import android.text.Editable +import android.text.TextWatcher +import android.text.style.StyleSpan import android.view.Menu import android.view.MenuInflater import android.view.MenuItem import androidx.annotation.StringRes import androidx.appcompat.widget.SearchView import androidx.viewbinding.ViewBinding +import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.ui.base.presenter.BasePresenter import kotlinx.coroutines.flow.launchIn import kotlinx.coroutines.flow.onEach @@ -52,6 +56,21 @@ abstract class SearchableNucleusController