Properly remove button from toolbar
Signed-off-by: Juraj Oravec <sgd.orava@gmail.com>
This commit is contained in:
parent
3c1a16afc6
commit
2ec9deb2aa
@ -61,8 +61,12 @@ class Readability(Falkon.PluginInterface, QtCore.QObject):
|
||||
self.buttons[window] = button
|
||||
|
||||
def onMainWindowDeleted(self, window):
|
||||
if window in self.buttons:
|
||||
del self.buttons[window]
|
||||
if window not in self.buttons:
|
||||
return
|
||||
|
||||
button = self.buttons[window]
|
||||
window.navigationBar().removeToolButton(button)
|
||||
del self.buttons[window]
|
||||
|
||||
def populateWebViewMenu(self, menu, view, hitTestResult):
|
||||
if not self.config["contextMenu"]:
|
||||
|
Loading…
Reference in New Issue
Block a user