diff options
author | Willem Jan Palenstijn | 2017-02-26 19:44:09 +0100 |
---|---|---|
committer | Willem Jan Palenstijn | 2017-02-28 15:55:51 +0100 |
commit | af831f26b97590024218801528f50e008f3b2f72 (patch) | |
tree | 502a9f642bfab3bb5572bf7c9e0781d46e1e6b07 | |
parent | 7314e04fe9dd97718e5b713adf67e84d7eca3ee2 (diff) | |
download | scummvm-rg350-af831f26b97590024218801528f50e008f3b2f72.tar.gz scummvm-rg350-af831f26b97590024218801528f50e008f3b2f72.tar.bz2 scummvm-rg350-af831f26b97590024218801528f50e008f3b2f72.zip |
GUI: Clean up GlobalOptionsDialog reflow changing visible tabs
-rw-r--r-- | gui/options.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/gui/options.cpp b/gui/options.cpp index f9c0541716..d70c843ee0 100644 --- a/gui/options.cpp +++ b/gui/options.cpp @@ -2002,14 +2002,8 @@ void GlobalOptionsDialog::handleCommand(CommandSender *sender, uint32 cmd, uint3 #ifdef USE_LIBCURL case kPopUpItemSelectedCmd: { - //update container's scrollbar and make sure tabs are not re-arranged - if (_tabWidget) { - int oldFirstVisible = _tabWidget->getFirstVisible(); - reflowLayout(); - _tabWidget->setFirstVisible(oldFirstVisible); - } else { - reflowLayout(); - } + // update container's scrollbar + reflowLayout(); break; } case kConfigureStorageCmd: @@ -2125,6 +2119,7 @@ void GlobalOptionsDialog::handleTickle() { } void GlobalOptionsDialog::reflowLayout() { + int firstVisible = _tabWidget->getFirstVisible(); int activeTab = _tabWidget->getActiveTab(); if (_midiTabId != -1) { @@ -2156,6 +2151,8 @@ void GlobalOptionsDialog::reflowLayout() { } _tabWidget->setActiveTab(activeTab); + _tabWidget->setFirstVisible(firstVisible); + OptionsDialog::reflowLayout(); #ifdef USE_CLOUD setupCloudTab(); |