Add option for enable/disable apply AC/Bat policy on change

This commit is contained in:
Luke D. Jones
2024-05-12 11:55:34 +12:00
parent 92ca7bc70d
commit 6c7e1a6467
9 changed files with 150 additions and 81 deletions

View File

@@ -143,12 +143,24 @@ trait Platform {
#[zbus(property)]
fn set_throttle_policy_on_ac(&self, throttle_policy: ThrottlePolicy) -> zbus::Result<()>;
/// ChangeThrottlePolicyOnAc property
#[zbus(property)]
fn change_throttle_policy_on_ac(&self) -> zbus::Result<bool>;
#[zbus(property)]
fn set_change_throttle_policy_on_ac(&self, change: bool) -> zbus::Result<()>;
/// ThrottlePolicyOnBattery property
#[zbus(property)]
fn throttle_policy_on_battery(&self) -> zbus::Result<ThrottlePolicy>;
#[zbus(property)]
fn set_throttle_policy_on_battery(&self, throttle_policy: ThrottlePolicy) -> zbus::Result<()>;
/// ChangeThrottlePolicyOnAc property
#[zbus(property)]
fn change_throttle_policy_on_battery(&self) -> zbus::Result<bool>;
#[zbus(property)]
fn set_change_throttle_policy_on_battery(&self, change: bool) -> zbus::Result<()>;
/// ThrottleQuietEpp property
#[zbus(property)]
fn throttle_quiet_epp(&self) -> zbus::Result<CPUEPP>;