Unify the laptop aura power stuff

This commit is contained in:
Luke D. Jones
2024-04-08 21:33:28 +12:00
parent 635d0378ac
commit 91ca049298
14 changed files with 425 additions and 501 deletions

View File

@@ -46,6 +46,7 @@ impl From<crate::slint_generatedMainWindow::AuraEffect> for rog_aura::AuraEffect
}
}
use rog_aura::aura_detection::PowerZones;
use rog_aura::keyboard::{AuraPowerState, LaptopOldAuraPower, LaptopTufAuraPower};
use rog_aura::usb::AuraPowerDev;
use slint::{Model, ModelRc, RgbaColor};
@@ -102,11 +103,12 @@ use crate::slint_generatedMainWindow::PowerZones as SlintPowerZones;
impl From<rog_aura::aura_detection::PowerZones> for SlintPowerZones {
fn from(value: rog_aura::aura_detection::PowerZones) -> Self {
match value {
rog_aura::aura_detection::PowerZones::Logo => SlintPowerZones::Logo,
rog_aura::aura_detection::PowerZones::Keyboard => SlintPowerZones::Keyboard,
rog_aura::aura_detection::PowerZones::Lightbar => SlintPowerZones::Lightbar,
rog_aura::aura_detection::PowerZones::Lid => SlintPowerZones::Lid,
rog_aura::aura_detection::PowerZones::RearGlow => SlintPowerZones::RearGlow,
PowerZones::Logo => SlintPowerZones::Logo,
PowerZones::Keyboard => SlintPowerZones::Keyboard,
PowerZones::Lightbar => SlintPowerZones::Lightbar,
PowerZones::Lid => SlintPowerZones::Lid,
PowerZones::RearGlow => SlintPowerZones::RearGlow,
PowerZones::KeyboardAndLightbar => todo!(),
}
}
}