Commit 0a412a1a authored by Mihai Adrian's avatar Mihai Adrian Committed by Sawyer Blatz
Browse files

For #6992 Always hide toolbar when showing find in page bar (#7567)

parent 666b3d96
Loading
Loading
Loading
Loading
+2 −6
Original line number Diff line number Diff line
@@ -7,7 +7,6 @@ package org.mozilla.fenix.components
import android.view.View
import android.view.ViewStub
import mozilla.components.browser.state.selector.findCustomTabOrSelectedTab
import mozilla.components.browser.state.state.CustomTabSessionState
import mozilla.components.browser.state.store.BrowserStore
import mozilla.components.browser.toolbar.BrowserToolbar
import mozilla.components.concept.engine.EngineView
@@ -33,11 +32,8 @@ class FindInPageIntegration(

    override fun onLaunch(view: View, feature: LifecycleAwareFeature) {
        store.state.findCustomTabOrSelectedTab(sessionId)?.let { tab ->
            if (tab !is CustomTabSessionState) {
                // Hide the toolbar to display find in page query (only
                // needs to be done for regular tabs with bottom toolbar).
            // Always hide the toolbar and display find in page query
            toolbar.visibility = View.GONE
            }
            view.visibility = View.VISIBLE
            (feature as FindInPageFeature).bind(tab)
            view.layoutParams.height = toolbar.height