Skip to content

Commit

Permalink
Integrate StatusBarItem interface in _draw_widgets()
Browse files Browse the repository at this point in the history
  • Loading branch information
pylbrecht committed Jul 13, 2024
1 parent c4d54d8 commit 711cd44
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions qutebrowser/mainwindow/statusbar/bar.py
Original file line number Diff line number Diff line change
Expand Up @@ -253,16 +253,10 @@ def _draw_widgets(self):

self._hbox.addWidget(widget.widget)

if segment in ('history', 'progress'):
widget.widget.enabled = True
if tab:
widget.widget.on_tab_changed(tab)
if isinstance(widget, (backforward.Backforward, progress.Progress)) and tab:
widget.widget.on_tab_changed(tab)

# Do not call .show() for these widgets. They are not always shown, and
# dynamically show/hide themselves in their on_tab_changed() methods.
continue

widget.show()
widget.enable()

def _clear_widgets(self):
"""Clear widgets before redrawing them."""
Expand Down

0 comments on commit 711cd44

Please sign in to comment.