[PowerStateMonitor] Be conservative when determining power state
Summary:
When the state defaults to AC-powered, the indexer may start some
energy consuming tasks, only to stop these later when the pending
DBus call finishes. Especially the content indexer can take a while
to stop, until the current batch is finished.
In case the DBus call fails AC-powered is assumed, to match the previous
default.
Test Plan:
unplug AC power
start baloo_file
-> the content indexer no longer processes its first batch
Reviewers: Baloo, ngraham, astippich, poboiko
Reviewed By: poboiko
Subscribers: kde-frameworks-devel, Baloo
Tags: Frameworks, Baloo
Differential Revision: https://phabricator.kde.org/D21672