summaryrefslogtreecommitdiffstats
path: root/tdecore/tdehw/tdehardwaredevices.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tdecore/tdehw/tdehardwaredevices.cpp')
-rw-r--r--tdecore/tdehw/tdehardwaredevices.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/tdecore/tdehw/tdehardwaredevices.cpp b/tdecore/tdehw/tdehardwaredevices.cpp
index 250cd11b6..2922ec4d8 100644
--- a/tdecore/tdehw/tdehardwaredevices.cpp
+++ b/tdecore/tdehw/tdehardwaredevices.cpp
@@ -3135,6 +3135,16 @@ void TDEHardwareDevices::updateExistingDeviceInformation(TDEGenericDevice* exist
supportedSwitches = supportedSwitches | TDESwitchType::LineInInsert;
}
#endif
+ // Keep in sync with ACPI Event/Input identification routines above
+ if (edevice->systemPath().contains("PNP0C0D")) {
+ supportedSwitches = supportedSwitches | TDESwitchType::Lid;
+ }
+ if (edevice->systemPath().contains("PNP0C0E") || edevice->systemPath().contains("/LNXSLPBN")) {
+ supportedSwitches = supportedSwitches | TDESwitchType::SleepButton;
+ }
+ if (edevice->systemPath().contains("PNP0C0C") || edevice->systemPath().contains("/LNXPWRBN")) {
+ supportedSwitches = supportedSwitches | TDESwitchType::PowerButton;
+ }
}
edevice->internalSetProvidedSwitches(supportedSwitches);