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

Side by Side Diff: chrome/browser/chromeos/boot_times_loader.h

Issue 8638016: Add OVERRIDE to chrome/browser/chromeos/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 CHROME_BROWSER_CHROMEOS_BOOT_TIMES_LOADER_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_BOOT_TIMES_LOADER_H_
6 #define CHROME_BROWSER_CHROMEOS_BOOT_TIMES_LOADER_H_ 6 #define CHROME_BROWSER_CHROMEOS_BOOT_TIMES_LOADER_H_
7 #pragma once 7 #pragma once
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
11 11
12 #include "base/atomic_sequence_num.h" 12 #include "base/atomic_sequence_num.h"
13 #include "base/callback_old.h" 13 #include "base/callback_old.h"
14 #include "base/compiler_specific.h"
14 #include "base/time.h" 15 #include "base/time.h"
15 #include "content/browser/cancelable_request.h" 16 #include "content/browser/cancelable_request.h"
16 #include "content/browser/renderer_host/render_widget_host.h" 17 #include "content/browser/renderer_host/render_widget_host.h"
17 #include "content/public/browser/notification_observer.h" 18 #include "content/public/browser/notification_observer.h"
18 #include "content/public/browser/notification_registrar.h" 19 #include "content/public/browser/notification_registrar.h"
19 20
20 namespace chromeos { 21 namespace chromeos {
21 22
22 // BootTimesLoader loads the bootimes of Chrome OS from the file system. 23 // BootTimesLoader loads the bootimes of Chrome OS from the file system.
23 // Loading is done asynchronously on the file thread. Once loaded, 24 // Loading is done asynchronously on the file thread. Once loaded,
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
98 // file thread. Existing stats files will not be overwritten. 99 // file thread. Existing stats files will not be overwritten.
99 void RecordChromeMainStats(); 100 void RecordChromeMainStats();
100 101
101 // Records the time that a login was attempted. This will overwrite any 102 // Records the time that a login was attempted. This will overwrite any
102 // previous login attempt times. 103 // previous login attempt times.
103 void RecordLoginAttempted(); 104 void RecordLoginAttempted();
104 105
105 // content::NotificationObserver implementation. 106 // content::NotificationObserver implementation.
106 virtual void Observe(int type, 107 virtual void Observe(int type,
107 const content::NotificationSource& source, 108 const content::NotificationSource& source,
108 const content::NotificationDetails& details); 109 const content::NotificationDetails& details) OVERRIDE;
109 110
110 // Writes the logout times to a /tmp/logout-times-sent. Unlike login 111 // Writes the logout times to a /tmp/logout-times-sent. Unlike login
111 // times, we manually call this function for logout times, as we cannot 112 // times, we manually call this function for logout times, as we cannot
112 // rely on notification service to tell when the logout is done. 113 // rely on notification service to tell when the logout is done.
113 void WriteLogoutTimes(); 114 void WriteLogoutTimes();
114 115
115 private: 116 private:
116 // BootTimesLoader calls into the Backend on the file thread to load 117 // BootTimesLoader calls into the Backend on the file thread to load
117 // the boot times. 118 // the boot times.
118 class Backend : public base::RefCountedThreadSafe<Backend> { 119 class Backend : public base::RefCountedThreadSafe<Backend> {
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 std::vector<TimeMarker> login_time_markers_; 174 std::vector<TimeMarker> login_time_markers_;
174 std::vector<TimeMarker> logout_time_markers_; 175 std::vector<TimeMarker> logout_time_markers_;
175 std::set<RenderWidgetHost*> render_widget_hosts_loading_; 176 std::set<RenderWidgetHost*> render_widget_hosts_loading_;
176 177
177 DISALLOW_COPY_AND_ASSIGN(BootTimesLoader); 178 DISALLOW_COPY_AND_ASSIGN(BootTimesLoader);
178 }; 179 };
179 180
180 } // namespace chromeos 181 } // namespace chromeos
181 182
182 #endif // CHROME_BROWSER_CHROMEOS_BOOT_TIMES_LOADER_H_ 183 #endif // CHROME_BROWSER_CHROMEOS_BOOT_TIMES_LOADER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698