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

Side by Side Diff: chromeos/dbus/power_manager_client.h

Issue 10544011: chromeos: Notify power manager about user activity. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: RootWindowEventFilter -> EnvEventFilter Created 8 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chromeos/dbus/mock_power_manager_client.h ('k') | chromeos/dbus/power_manager_client.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROMEOS_DBUS_POWER_MANAGER_CLIENT_H_ 5 #ifndef CHROMEOS_DBUS_POWER_MANAGER_CLIENT_H_
6 #define CHROMEOS_DBUS_POWER_MANAGER_CLIENT_H_ 6 #define CHROMEOS_DBUS_POWER_MANAGER_CLIENT_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 // NOTE: This notification is one shot, once the machine has been idle for 165 // NOTE: This notification is one shot, once the machine has been idle for
166 // threshold time, a notification will be sent and then that request will be 166 // threshold time, a notification will be sent and then that request will be
167 // removed from the notification queue. If you wish notifications the next 167 // removed from the notification queue. If you wish notifications the next
168 // time the machine goes idle for that much time, request again. 168 // time the machine goes idle for that much time, request again.
169 virtual void RequestIdleNotification(int64 threshold_secs) = 0; 169 virtual void RequestIdleNotification(int64 threshold_secs) = 0;
170 170
171 // Requests that the observers be notified in case of an Idle->Active event. 171 // Requests that the observers be notified in case of an Idle->Active event.
172 // NOTE: Like the previous request, this will also get triggered exactly once. 172 // NOTE: Like the previous request, this will also get triggered exactly once.
173 virtual void RequestActiveNotification() = 0; 173 virtual void RequestActiveNotification() = 0;
174 174
175 // Notifies the power manager that the user is active (i.e. generating input
176 // events).
177 virtual void NotifyUserActivity(
178 const base::TimeTicks& last_activity_time) = 0;
179
175 // Notifies the power manager that a video is currently playing. 180 // Notifies the power manager that a video is currently playing.
176 virtual void NotifyVideoActivity( 181 virtual void NotifyVideoActivity(
177 const base::TimeTicks& last_activity_time) = 0; 182 const base::TimeTicks& last_activity_time) = 0;
178 183
179 // Override the current power state on the machine. The overrides will be 184 // Override the current power state on the machine. The overrides will be
180 // applied to the request ID specified. To specify a new request; use 0 as 185 // applied to the request ID specified. To specify a new request; use 0 as
181 // the request id and the method will call the provided callback with the 186 // the request id and the method will call the provided callback with the
182 // new request ID for use with further calls. 187 // new request ID for use with further calls.
183 // The overrides parameter will & out the PowerStateOverrideType types to 188 // The overrides parameter will & out the PowerStateOverrideType types to
184 // allow specific selection of overrides. For example, to override just dim 189 // allow specific selection of overrides. For example, to override just dim
(...skipping 15 matching lines...) Expand all
200 // Create() should be used instead. 205 // Create() should be used instead.
201 PowerManagerClient(); 206 PowerManagerClient();
202 207
203 private: 208 private:
204 DISALLOW_COPY_AND_ASSIGN(PowerManagerClient); 209 DISALLOW_COPY_AND_ASSIGN(PowerManagerClient);
205 }; 210 };
206 211
207 } // namespace chromeos 212 } // namespace chromeos
208 213
209 #endif // CHROMEOS_DBUS_POWER_MANAGER_CLIENT_H_ 214 #endif // CHROMEOS_DBUS_POWER_MANAGER_CLIENT_H_
OLDNEW
« no previous file with comments | « chromeos/dbus/mock_power_manager_client.h ('k') | chromeos/dbus/power_manager_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698