mirror of
https://github.com/Chatterino/chatterino2.git
synced 2024-11-21 22:24:07 +01:00
rename lockUiScale setting to lockUiScaleHotkeys
This commit is contained in:
parent
bcd2676754
commit
f3ade88846
4 changed files with 8 additions and 7 deletions
|
@ -36,7 +36,7 @@ public:
|
|||
BoolSetting alternateMessageBackground = {"/appearance/messages/alternateMessageBackground",
|
||||
false};
|
||||
IntSetting uiScale = {"/appearance/uiScale", 0};
|
||||
BoolSetting lockUiScale = {"/appearance/lockUiScale", false};
|
||||
BoolSetting lockUiScaleHotkeys = {"/appearance/lockUiScaleHotkeys", false};
|
||||
BoolSetting windowTopMost = {"/appearance/windowAlwaysOnTop", false};
|
||||
BoolSetting showTabCloseButton = {"/appearance/showTabCloseButton", true};
|
||||
BoolSetting hidePreferencesButton = {"/appearance/hidePreferencesButton", false};
|
||||
|
|
|
@ -60,7 +60,7 @@ BaseWindow::BaseWindow(QWidget *parent, Flags _flags)
|
|||
this->updateScale();
|
||||
|
||||
createWindowShortcut(this, "CTRL+0", [] {
|
||||
if (!getSettings()->lockUiScale.getValue()) {
|
||||
if (!getSettings()->lockUiScaleHotkeys.getValue()) {
|
||||
getSettings()->uiScale.setValue(0);
|
||||
}
|
||||
});
|
||||
|
@ -259,12 +259,12 @@ void BaseWindow::wheelEvent(QWheelEvent *event)
|
|||
|
||||
if (event->modifiers() & Qt::ControlModifier) {
|
||||
if (event->delta() > 0) {
|
||||
if (!getSettings()->lockUiScale.getValue()) {
|
||||
if (!getSettings()->lockUiScaleHotkeys.getValue()) {
|
||||
getSettings()->uiScale.setValue(
|
||||
WindowManager::clampUiScale(getSettings()->uiScale.getValue() + 1));
|
||||
}
|
||||
} else {
|
||||
if (!getSettings()->lockUiScale.getValue()) {
|
||||
if (!getSettings()->lockUiScaleHotkeys.getValue()) {
|
||||
getSettings()->uiScale.setValue(
|
||||
WindowManager::clampUiScale(getSettings()->uiScale.getValue() - 1));
|
||||
}
|
||||
|
|
|
@ -263,7 +263,7 @@ void Window::addShortcuts()
|
|||
auto s = new QShortcut(QKeySequence::ZoomIn, this);
|
||||
s->setContext(Qt::WindowShortcut);
|
||||
QObject::connect(s, &QShortcut::activated, this, [] {
|
||||
if (!getSettings()->lockUiScale.getValue()) {
|
||||
if (!getSettings()->lockUiScaleHotkeys.getValue()) {
|
||||
getSettings()->uiScale.setValue(
|
||||
WindowManager::clampUiScale(getSettings()->uiScale.getValue() + 1));
|
||||
}
|
||||
|
@ -275,7 +275,7 @@ void Window::addShortcuts()
|
|||
auto s = new QShortcut(QKeySequence::ZoomOut, this);
|
||||
s->setContext(Qt::WindowShortcut);
|
||||
QObject::connect(s, &QShortcut::activated, this, [] {
|
||||
if (!getSettings()->lockUiScale.getValue()) {
|
||||
if (!getSettings()->lockUiScaleHotkeys.getValue()) {
|
||||
getSettings()->uiScale.setValue(
|
||||
WindowManager::clampUiScale(getSettings()->uiScale.getValue() - 1));
|
||||
}
|
||||
|
|
|
@ -86,7 +86,8 @@ void LookPage::addInterfaceTab(LayoutCreator<QVBoxLayout> layout)
|
|||
box.append(this->createUiScaleSlider());
|
||||
}
|
||||
|
||||
layout.append(this->createCheckBox("Lock window scale hotkeys", getSettings()->lockUiScale));
|
||||
layout.append(
|
||||
this->createCheckBox("Lock window scale hotkeys", getSettings()->lockUiScaleHotkeys));
|
||||
|
||||
layout.append(this->createCheckBox(WINDOW_TOPMOST, getSettings()->windowTopMost));
|
||||
|
||||
|
|
Loading…
Reference in a new issue