Fix initial tab sizing with vertical tabbar
This commit is contained in:
parent
b37d040d44
commit
9cc688ea2b
@ -433,6 +433,10 @@ class TabbedBrowser(tabwidget.TabWidget):
|
|||||||
# Make sure the background tab has the correct initial size.
|
# Make sure the background tab has the correct initial size.
|
||||||
# With a foreground tab, it's going to be resized correctly by the
|
# With a foreground tab, it's going to be resized correctly by the
|
||||||
# layout anyways.
|
# layout anyways.
|
||||||
|
if self.tabBar().vertical:
|
||||||
|
tab_size = QSize(self.width() - self.tabBar().width(),
|
||||||
|
self.height())
|
||||||
|
else:
|
||||||
tab_size = QSize(self.width(),
|
tab_size = QSize(self.width(),
|
||||||
self.height() - self.tabBar().height())
|
self.height() - self.tabBar().height())
|
||||||
tab.resize(tab_size)
|
tab.resize(tab_size)
|
||||||
|
@ -116,3 +116,12 @@ Feature: Javascript stuff
|
|||||||
And I wait for "[*/data/javascript/windowsize.html:*] loaded" in the log
|
And I wait for "[*/data/javascript/windowsize.html:*] loaded" in the log
|
||||||
And I run :tab-next
|
And I run :tab-next
|
||||||
Then the window sizes should be the same
|
Then the window sizes should be the same
|
||||||
|
|
||||||
|
Scenario: Checking visible/invisible window size with vertical tabbar
|
||||||
|
When I run :tab-only
|
||||||
|
And I set general -> log-javascript-console to info
|
||||||
|
And I set tabs -> position to left
|
||||||
|
And I open data/javascript/windowsize.html in a new background tab
|
||||||
|
And I wait for "[*/data/javascript/windowsize.html:*] loaded" in the log
|
||||||
|
And I run :tab-next
|
||||||
|
Then the window sizes should be the same
|
||||||
|
Loading…
Reference in New Issue
Block a user