Skip to content

Commit

Permalink
Bugfix FXIOS-9755 Update the url bar even if there is no webview (#21431
Browse files Browse the repository at this point in the history
) (#21433)

(cherry picked from commit 43f44fc)

Co-authored-by: OrlaM <[email protected]>
  • Loading branch information
mergify[bot] and OrlaM authored Aug 17, 2024
1 parent 31e4e40 commit 61ba62d
Showing 1 changed file with 12 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3200,8 +3200,9 @@ extension BrowserViewController: TabManagerDelegate {
selected?.webView?.applyTheme(theme: currentTheme())
}

if let tab = selected, let webView = tab.webView {
if let tab = selected {
updateURLBarDisplayURL(tab)

if !isToolbarRefactorEnabled, urlBar.inOverlayMode, tab.url?.displayURL != nil {
urlBar.leaveOverlayMode(reason: .finished, shouldCancelLoading: false)
}
Expand All @@ -3215,16 +3216,18 @@ extension BrowserViewController: TabManagerDelegate {

scrollController.tab = tab

webView.accessibilityLabel = .WebViewAccessibilityLabel
webView.accessibilityIdentifier = "contentView"
webView.accessibilityElementsHidden = false
if let webView = tab.webView {
webView.accessibilityLabel = .WebViewAccessibilityLabel
webView.accessibilityIdentifier = "contentView"
webView.accessibilityElementsHidden = false

browserDelegate?.show(webView: webView)
browserDelegate?.show(webView: webView)

if webView.url == nil {
// The web view can go gray if it was zombified due to memory pressure.
// When this happens, the URL is nil, so try restoring the page upon selection.
tab.reload()
if webView.url == nil {
// The web view can go gray if it was zombified due to memory pressure.
// When this happens, the URL is nil, so try restoring the page upon selection.
tab.reload()
}
}

// Update Fakespot sidebar if necessary
Expand Down

1 comment on commit 61ba62d

@firefoxci-taskcluster
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uh oh! Looks like an error!

InterpreterError at template.tasks[0].extra[0].treeherder[1].symbol: unknown context value cron

Please sign in to comment.