mirror of
https://github.com/RetroShare/RetroShare.git
synced 2024-10-01 02:35:48 -04:00
Merge pull request #2268 from defnax/appeareancepage
Fixed to hide ToolButton Style when the List View is used & set defau…
This commit is contained in:
commit
ccb39a87d8
@ -136,6 +136,14 @@ void AppearancePage::updateRbtPageOnToolBar()
|
||||
{
|
||||
Settings->setPageButtonLoc(!ui.mainPageButtonType_CB->currentIndex());
|
||||
Settings->setActionButtonLoc(!ui.mainPageButtonType_CB->currentIndex());
|
||||
|
||||
int index = ui.mainPageButtonType_CB->currentIndex();
|
||||
if (index != 0) {
|
||||
ui.cmboTollButtonsStyle->hide();
|
||||
}else {
|
||||
ui.cmboTollButtonsStyle->show();
|
||||
}
|
||||
|
||||
NotifyQt::getInstance()->notifySettingsChanged();
|
||||
}
|
||||
void AppearancePage::updateStatusToolTip() { MainWindow::getInstance()->toggleStatusToolTip(ui.checkBoxDisableSysTrayToolTip->isChecked()); }
|
||||
@ -173,11 +181,11 @@ void AppearancePage::updateCmboToolButtonSize()
|
||||
Settings->setListItemIconSize(16);
|
||||
break;
|
||||
case 2:
|
||||
default:
|
||||
Settings->setToolButtonSize(24);
|
||||
Settings->setListItemIconSize(24);
|
||||
break;
|
||||
case 3:
|
||||
default:
|
||||
Settings->setToolButtonSize(32);
|
||||
Settings->setListItemIconSize(32);
|
||||
break;
|
||||
@ -234,6 +242,13 @@ void AppearancePage::load()
|
||||
index = ui.cmboStyleSheet->findData("");
|
||||
}
|
||||
whileBlocking(ui.cmboStyleSheet)->setCurrentIndex(index);
|
||||
|
||||
index = ui.mainPageButtonType_CB->findData(Settings->getPageButtonLoc());
|
||||
if (index != 0) {
|
||||
ui.cmboTollButtonsStyle->hide();
|
||||
}else {
|
||||
ui.cmboTollButtonsStyle->show();
|
||||
}
|
||||
|
||||
whileBlocking(ui.mainPageButtonType_CB)->setCurrentIndex(!Settings->getPageButtonLoc());
|
||||
// ui.menuItemsButtonType_CB->setCurrentIndex(!Settings->getActionButtonLoc());
|
||||
@ -262,10 +277,10 @@ void AppearancePage::load()
|
||||
whileBlocking(ui.cmboTollButtonsSize)->setCurrentIndex(1);
|
||||
break;
|
||||
case 24:
|
||||
default:
|
||||
whileBlocking(ui.cmboTollButtonsSize)->setCurrentIndex(2);
|
||||
break;
|
||||
case 32:
|
||||
default:
|
||||
whileBlocking(ui.cmboTollButtonsSize)->setCurrentIndex(3);
|
||||
break;
|
||||
case 64:
|
||||
|
@ -6,8 +6,8 @@
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>1170</width>
|
||||
<height>897</height>
|
||||
<width>662</width>
|
||||
<height>585</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="contextMenuPolicy">
|
||||
@ -249,6 +249,40 @@
|
||||
<enum>QFrame::NoFrame</enum>
|
||||
</property>
|
||||
<layout class="QGridLayout" name="frameToolListStyleGLayout">
|
||||
<item row="1" column="0">
|
||||
<widget class="QComboBox" name="cmboTollButtonsSize">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 8x8</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 16x16</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 24x24</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 32x32</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 64x64</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 128x128</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="2" column="0">
|
||||
<widget class="QComboBox" name="cmboTollButtonsStyle">
|
||||
<item>
|
||||
@ -286,39 +320,18 @@
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item row="1" column="0">
|
||||
<widget class="QComboBox" name="cmboTollButtonsSize">
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 8x8</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 16x16</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 24x24</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 32x32</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 64x64</string>
|
||||
</property>
|
||||
</item>
|
||||
<item>
|
||||
<property name="text">
|
||||
<string>Icon Size = 128x128</string>
|
||||
</property>
|
||||
</item>
|
||||
</widget>
|
||||
<item row="3" column="0">
|
||||
<spacer name="verticalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
|
@ -266,7 +266,7 @@ int RshareSettings::getToolButtonSize()
|
||||
{
|
||||
static int sizes[6] = { 8,16,24,32,64,128 } ;
|
||||
|
||||
return value(SETTING_TOOLBUTTONSIZE, computeBestIconSize(6,sizes,24)).toInt();
|
||||
return value(SETTING_TOOLBUTTONSIZE, computeBestIconSize(6,sizes,32)).toInt();
|
||||
}
|
||||
|
||||
/** Sets the tool button's size.*/
|
||||
@ -281,10 +281,10 @@ void RshareSettings::setToolButtonSize(int size)
|
||||
setValue(SETTING_TOOLBUTTONSIZE, 16);
|
||||
break;
|
||||
case 24:
|
||||
default:
|
||||
setValue(SETTING_TOOLBUTTONSIZE, 24);
|
||||
break;
|
||||
case 32:
|
||||
default:
|
||||
setValue(SETTING_TOOLBUTTONSIZE, 32);
|
||||
break;
|
||||
case 64:
|
||||
|
Loading…
Reference in New Issue
Block a user