New tab opens as unrelated
This commit is contained in:
parent
4d780e23af
commit
50983f01b8
@ -116,7 +116,7 @@ class TabbedBrowser(tabwidget.TabWidget):
|
||||
self._tab_insert_idx_right = -1
|
||||
self.shutting_down = False
|
||||
self.tabCloseRequested.connect(self.on_tab_close_requested)
|
||||
self.new_tab_requested.connect(self.openurl)
|
||||
self.new_tab_requested.connect(self.tabopen)
|
||||
self.currentChanged.connect(self.on_current_changed)
|
||||
self.cur_load_started.connect(self.on_cur_load_started)
|
||||
self.cur_fullscreen_requested.connect(self.tabBar().maybe_hide)
|
||||
@ -403,6 +403,7 @@ class TabbedBrowser(tabwidget.TabWidget):
|
||||
|
||||
@pyqtSlot('QUrl')
|
||||
@pyqtSlot('QUrl', bool)
|
||||
@pyqtSlot('QUrl', bool, bool)
|
||||
def tabopen(self, url=None, background=None, related=True, idx=None, *,
|
||||
ignore_tabs_are_windows=False):
|
||||
"""Open a new tab with a given URL.
|
||||
|
@ -50,7 +50,7 @@ class TabWidget(QTabWidget):
|
||||
"""
|
||||
|
||||
tab_index_changed = pyqtSignal(int, int)
|
||||
new_tab_requested = pyqtSignal('QUrl', bool)
|
||||
new_tab_requested = pyqtSignal('QUrl', bool, bool)
|
||||
|
||||
def __init__(self, win_id, parent=None):
|
||||
super().__init__(parent)
|
||||
@ -267,7 +267,7 @@ class TabWidget(QTabWidget):
|
||||
@pyqtSlot()
|
||||
def _on_new_tab_requested(self):
|
||||
"""Open a new tab."""
|
||||
self.new_tab_requested.emit(config.val.url.default_page, True)
|
||||
self.new_tab_requested.emit(config.val.url.default_page, False, False)
|
||||
|
||||
def tab_url(self, idx):
|
||||
"""Get the URL of the tab at the given index.
|
||||
|
Loading…
Reference in New Issue
Block a user