Call tab.openurl _after_ connecting signals.

This commit is contained in:
Florian Bruhin 2014-02-13 07:10:41 +01:00
parent 0326a66758
commit ca97a50820

View File

@ -85,7 +85,6 @@ class TabbedBrowser(TabWidget):
logging.debug("Opening {}".format(url)) logging.debug("Opening {}".format(url))
url = urlutils.qurl(url) url = urlutils.qurl(url)
tab = BrowserTab(self) tab = BrowserTab(self)
tab.openurl(url)
self.cur_url_changed.emit(url) self.cur_url_changed.emit(url)
self.addTab(tab, urlutils.urlstring(url)) self.addTab(tab, urlutils.urlstring(url))
self.setCurrentWidget(tab) self.setCurrentWidget(tab)
@ -103,6 +102,7 @@ class TabbedBrowser(TabWidget):
tab.titleChanged.connect(self._titleChanged_handler) tab.titleChanged.connect(self._titleChanged_handler)
# FIXME sometimes this doesn't load # FIXME sometimes this doesn't load
tab.open_tab.connect(self.tabopen) tab.open_tab.connect(self.tabopen)
tab.openurl(url)
def tabopencur(self): def tabopencur(self):
"""Set the statusbar to :tabopen and the current URL.""" """Set the statusbar to :tabopen and the current URL."""