Skip to content

Commit 0246b78

Browse files
committed
mouse: change naturalScroll from QComboBox to QCheckBox
1 parent 4d4ffa4 commit 0246b78

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

src/mouse.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,13 @@ void Mouse::activate()
2626
ui->cursorSize->setValue(getInt("XCURSOR_SIZE"));
2727

2828
/* Natural Scroll */
29-
ui->naturalScroll->addItem("no");
30-
ui->naturalScroll->addItem("yes");
31-
ui->naturalScroll->setCurrentIndex(getBool("/labwc_config/libinput/device/naturalScroll"));
29+
ui->naturalScroll->setChecked(getBool("/labwc_config/libinput/device/naturalScroll"));
3230
}
3331

3432
void Mouse::onApply()
3533
{
3634
/* ~/.config/labwc/rc.xml */
37-
setBoolfromString("/labwc_config/libinput/device/naturalScroll", TEXT(ui->naturalScroll));
35+
setBool("/labwc_config/libinput/device/naturalScroll", ui->naturalScroll->isChecked());
3836

3937
/* ~/.config/labwc/environment */
4038
environmentSet("XCURSOR_THEME", TEXT(ui->cursorTheme));

src/mouse.ui

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
</widget>
5252
</item>
5353
<item row="2" column="1">
54-
<widget class="QComboBox" name="naturalScroll"/>
54+
<widget class="QCheckBox" name="naturalScroll"/>
5555
</item>
5656
</layout>
5757
</widget>

0 commit comments

Comments
 (0)