Skip to content
Commit 9827d403 authored by Jakob Petsovits's avatar Jakob Petsovits
Browse files

Don't use profile generation for global config file

Instead, use a parameterized PowerDevil::GlobalSettings that will
determine the correct default for your system on every startup,
as opposed to just the first time when profile generation is run.

There was only a single global setting requiring parameterization,
namely BatteryCriticalAction. But the impact is considerable:

* generateProfiles() now doesn't need canSuspendToDisk, which
  reduces the surface area of profile generation autotests.
* We need a new GlobalDefaults::defaultBatteryCriticalAction(),
  so powerdevilprofiledefaults.{h,cpp} gets renamed to
  powerdevilsettingsdefaults.h for both global and profile defaults.
* PowerDevil::Core switches from the previous settings singleton
  to an owned GlobalSettings object, initialized in onBackendReady().

The unused "doNotInhibitOnLidClose" config entry is dropped from
PowerDevilGlobalSettings.kcfg.

This commit requires a clean (re)build because the global config KCM
had already generated an earl...
parent b5ed2fd1
Pipeline #479622 passed with stage
in 1 minute and 33 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment