Skip to content

Commit

Permalink
Start implementation
Browse files Browse the repository at this point in the history
  • Loading branch information
clefebvre committed Nov 6, 2024
1 parent 3724d7a commit 2268ad3
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions files/usr/share/cinnamon/cinnamon-settings/modules/cs_mouse.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,10 @@ def on_module_selected(self):

page = SettingsPage()

settings = page.add_section(_("General"))
settings = page.add_rounded_section(_("General"))

switch = GSettingsSwitch(_("Left handed (mouse buttons inverted)"), "org.cinnamon.desktop.peripherals.mouse", "left-handed")
switch.set_tooltip_text(_("blah blah"))
settings.add_row(switch)

switch = GSettingsSwitch(_("Reverse scrolling direction"), "org.cinnamon.desktop.peripherals.mouse", "natural-scroll")
Expand All @@ -50,7 +51,7 @@ def on_module_selected(self):
spin = GSettingsSpinButton(_("Drag-and-drop threshold"), "org.cinnamon.desktop.peripherals.mouse", "drag-threshold", _("pixels"), 1, 400)
settings.add_row(spin)

settings = page.add_section(_("Pointer size and speed"))
settings = page.add_rounded_section(_("Pointer size and speed"))

widget = GSettingsRange(_("Size"), "org.cinnamon.desktop.interface", "cursor-size", _("Smaller"), _("Larger"), 5, 50, show_value=False)
widget.add_mark(24.0, Gtk.PositionType.TOP, None)
Expand All @@ -70,7 +71,7 @@ def on_module_selected(self):
combo = GSettingsComboBox(_("Acceleration"), "org.cinnamon.desktop.peripherals.mouse", "accel-profile", accel_profiles, valtype=str)
settings.add_row(combo)

settings = page.add_section(_("Double-Click timeout"))
settings = page.add_rounded_section(_("Double-Click timeout"))

slider = GSettingsRange(_("Timeout"), "org.cinnamon.desktop.peripherals.mouse", "double-click", _("Short"), _("Long"), 100, 1000, show_value=False)
settings.add_row(slider)
Expand Down Expand Up @@ -100,7 +101,7 @@ def on_module_selected(self):
revealer = SettingsRevealer("org.cinnamon.desktop.peripherals.touchpad", "send-events", values=("enabled", "disabled-on-external-mouse"))
page.pack_start(revealer, False, True, 0)

settings = SettingsSection(_("General"))
settings = RoundedSettingsSection(_("General"))
revealer.add(settings)

switch = GSettingsSwitch(_("Tap to click"), "org.cinnamon.desktop.peripherals.touchpad", "tap-to-click")
Expand All @@ -119,7 +120,7 @@ def on_module_selected(self):
combo = GSettingsComboBox(_("Click actions"), "org.cinnamon.desktop.peripherals.touchpad", "click-method", clickpad_list, valtype=str)
settings.add_row(combo)

settings = SettingsSection(_("Scrolling"))
settings = RoundedSettingsSection(_("Scrolling"))
revealer.add(settings)

switch = GSettingsSwitch(_("Reverse scrolling direction"), "org.cinnamon.desktop.peripherals.touchpad", "natural-scroll")
Expand All @@ -128,7 +129,7 @@ def on_module_selected(self):
combo = ScrollMethodCombo()
settings.add_row(combo)

settings = SettingsSection(None)
settings = RoundedSettingsSection(None)
revealer.add(settings)

slider = GSettingsRange(_("Speed"), "org.cinnamon.desktop.peripherals.touchpad", "speed", _("Slower"), _("Faster"), -1.0, 1.0, show_value=False)
Expand Down

0 comments on commit 2268ad3

Please sign in to comment.