Skip to content

Commit

Permalink
Add pointingMotionXYMultiplier, pointingMotionWheelsMultiplier
Browse files Browse the repository at this point in the history
  • Loading branch information
tekezo committed Dec 30, 2024
1 parent 7555ad1 commit c8d1396
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions src/apps/share/swift/LibKrbn/Models/ConnectedDeviceSetting.swift
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,14 @@ extension LibKrbn {
libkrbn_core_configuration_get_selected_profile_device_disable_built_in_keyboard_if_exists(
connectedDevice.libkrbnDeviceIdentifiers)

pointingMotionXYMultiplier =
libkrbn_core_configuration_get_selected_profile_device_pointing_motion_xy_multiplier(
connectedDevice.libkrbnDeviceIdentifiers)

pointingMotionWheelsMultiplier =
libkrbn_core_configuration_get_selected_profile_device_pointing_motion_wheels_multiplier(
connectedDevice.libkrbnDeviceIdentifiers)

//
// mouseFlipXXX
//
Expand Down Expand Up @@ -204,6 +212,28 @@ extension LibKrbn {
}
}

@Published var pointingMotionXYMultiplier: Double = 1.0 {
didSet {
if didSetEnabled {
libkrbn_core_configuration_set_selected_profile_device_pointing_motion_xy_multiplier(
connectedDevice.libkrbnDeviceIdentifiers, pointingMotionXYMultiplier)

Settings.shared.save()
}
}
}

@Published var pointingMotionWheelsMultiplier: Double = 1.0 {
didSet {
if didSetEnabled {
libkrbn_core_configuration_set_selected_profile_device_pointing_motion_wheels_multiplier(
connectedDevice.libkrbnDeviceIdentifiers, pointingMotionWheelsMultiplier)

Settings.shared.save()
}
}
}

@Published var mouseFlipX: Bool = false {
didSet {
if didSetEnabled {
Expand Down

0 comments on commit c8d1396

Please sign in to comment.