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

Side by Side Diff: extensions/browser/api/idle/idle_manager.h

Issue 1355063004: Template methods on Timer classes instead of the classes themselves. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: timer: fixcaller Created 5 years, 3 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
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 EXTENSIONS_BROWSER_API_IDLE_IDLE_MANAGER_H_ 5 #ifndef EXTENSIONS_BROWSER_API_IDLE_IDLE_MANAGER_H_
6 #define EXTENSIONS_BROWSER_API_IDLE_IDLE_MANAGER_H_ 6 #define EXTENSIONS_BROWSER_API_IDLE_IDLE_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 10
(...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 void StartPolling(); 119 void StartPolling();
120 void StopPolling(); 120 void StopPolling();
121 void UpdateIdleState(); 121 void UpdateIdleState();
122 void UpdateIdleStateCallback(int idle_time); 122 void UpdateIdleStateCallback(int idle_time);
123 123
124 content::BrowserContext* const context_; 124 content::BrowserContext* const context_;
125 125
126 ui::IdleState last_state_; 126 ui::IdleState last_state_;
127 MonitorMap monitors_; 127 MonitorMap monitors_;
128 128
129 base::RepeatingTimer<IdleManager> poll_timer_; 129 base::RepeatingTimer poll_timer_;
130 130
131 scoped_ptr<IdleTimeProvider> idle_time_provider_; 131 scoped_ptr<IdleTimeProvider> idle_time_provider_;
132 scoped_ptr<EventDelegate> event_delegate_; 132 scoped_ptr<EventDelegate> event_delegate_;
133 133
134 base::ThreadChecker thread_checker_; 134 base::ThreadChecker thread_checker_;
135 135
136 // Listen to extension unloaded notification. 136 // Listen to extension unloaded notification.
137 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver> 137 ScopedObserver<ExtensionRegistry, ExtensionRegistryObserver>
138 extension_registry_observer_; 138 extension_registry_observer_;
139 139
140 base::WeakPtrFactory<IdleManager> weak_factory_; 140 base::WeakPtrFactory<IdleManager> weak_factory_;
141 141
142 DISALLOW_COPY_AND_ASSIGN(IdleManager); 142 DISALLOW_COPY_AND_ASSIGN(IdleManager);
143 }; 143 };
144 144
145 } // namespace extensions 145 } // namespace extensions
146 146
147 #endif // EXTENSIONS_BROWSER_API_IDLE_IDLE_MANAGER_H_ 147 #endif // EXTENSIONS_BROWSER_API_IDLE_IDLE_MANAGER_H_
OLDNEW
« no previous file with comments | « extensions/browser/api/cast_channel/cast_socket.cc ('k') | extensions/browser/app_window/app_window_geometry_cache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698