Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(92)

Unified Diff: chromeos/dbus/power_policy_controller.h

Issue 129303003: Revert of Revert of chromeos: Don't send empty power management policies. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chromeos/dbus/fake_power_manager_client.cc ('k') | chromeos/dbus/power_policy_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chromeos/dbus/power_policy_controller.h
diff --git a/chromeos/dbus/power_policy_controller.h b/chromeos/dbus/power_policy_controller.h
index 7db9091af22f87eb610ffc95965306a70314aecb..cb994cdb830a1fb71c73cbcf8c0566db7a1644f5 100644
--- a/chromeos/dbus/power_policy_controller.h
+++ b/chromeos/dbus/power_policy_controller.h
@@ -11,7 +11,6 @@
#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "chromeos/chromeos_export.h"
-#include "chromeos/dbus/dbus_thread_manager_observer.h"
#include "chromeos/dbus/power_manager/policy.pb.h"
#include "chromeos/dbus/power_manager_client.h"
@@ -22,8 +21,7 @@
// PowerPolicyController is responsible for sending Chrome's assorted power
// management preferences to the Chrome OS power manager.
class CHROMEOS_EXPORT PowerPolicyController
- : public DBusThreadManagerObserver,
- public PowerManagerClient::Observer {
+ : public PowerManagerClient::Observer {
public:
// Note: Do not change these values; they are used by preferences.
enum Action {
@@ -79,9 +77,6 @@
// Updates |prefs_policy_| with |values| and sends an updated policy.
void ApplyPrefs(const PrefValues& values);
- // Resets |prefs_policy_| to its defaults and sends an updated policy.
- void ClearPrefs();
-
// Registers a request to temporarily prevent the screen from getting
// dimmed or turned off or the system from suspending in response to user
// inactivity and sends an updated policy. |reason| is a human-readable
@@ -94,10 +89,6 @@
// AddSystemWakeLock() and sends an updated policy.
void RemoveWakeLock(int id);
- // DBusThreadManagerObserver implementation:
- virtual void OnDBusThreadManagerDestroying(DBusThreadManager* manager)
- OVERRIDE;
-
// PowerManagerClient::Observer implementation:
virtual void PowerManagerRestarted() OVERRIDE;
@@ -109,11 +100,7 @@
// Sends a policy based on |prefs_policy_| to the power manager.
void SendCurrentPolicy();
- // Sends an empty policy to the power manager to reset its configuration.
- void SendEmptyPolicy();
-
- DBusThreadManager* manager_; // not owned
- PowerManagerClient* client_; // not owned
+ PowerManagerClient* client_; // weak
// Policy derived from values passed to ApplyPrefs().
power_manager::PowerManagementPolicy prefs_policy_;
« no previous file with comments | « chromeos/dbus/fake_power_manager_client.cc ('k') | chromeos/dbus/power_policy_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698