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

Side by Side Diff: chrome/browser/automation/automation_provider.cc

Issue 7995: Move Time, TimeDelta and TimeTicks into namespace base. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 12 years, 2 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
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 #include "chrome/browser/automation/automation_provider.h" 5 #include "chrome/browser/automation/automation_provider.h"
6 6
7 #include "base/path_service.h" 7 #include "base/path_service.h"
8 #include "base/process_util.h" 8 #include "base/process_util.h"
9 #include "chrome/app/chrome_dll_resource.h" 9 #include "chrome/app/chrome_dll_resource.h"
10 #include "chrome/browser/automation/automation_provider_list.h" 10 #include "chrome/browser/automation/automation_provider_list.h"
(...skipping 16 matching lines...) Expand all
27 #include "chrome/browser/web_contents.h" 27 #include "chrome/browser/web_contents.h"
28 #include "chrome/browser/web_contents_view.h" 28 #include "chrome/browser/web_contents_view.h"
29 #include "chrome/browser/views/bookmark_bar_view.h" 29 #include "chrome/browser/views/bookmark_bar_view.h"
30 #include "chrome/browser/views/location_bar_view.h" 30 #include "chrome/browser/views/location_bar_view.h"
31 #include "chrome/common/chrome_paths.h" 31 #include "chrome/common/chrome_paths.h"
32 #include "chrome/common/pref_service.h" 32 #include "chrome/common/pref_service.h"
33 #include "chrome/test/automation/automation_messages.h" 33 #include "chrome/test/automation/automation_messages.h"
34 #include "net/base/cookie_monster.h" 34 #include "net/base/cookie_monster.h"
35 #include "net/url_request/url_request_filter.h" 35 #include "net/url_request/url_request_filter.h"
36 36
37 using base::Time;
38
37 class InitialLoadObserver : public NotificationObserver { 39 class InitialLoadObserver : public NotificationObserver {
38 public: 40 public:
39 InitialLoadObserver(size_t tab_count, AutomationProvider* automation) 41 InitialLoadObserver(size_t tab_count, AutomationProvider* automation)
40 : outstanding_tab_count_(tab_count), 42 : outstanding_tab_count_(tab_count),
41 automation_(automation) { 43 automation_(automation) {
42 if (outstanding_tab_count_ > 0) { 44 if (outstanding_tab_count_ > 0) {
43 NotificationService* service = NotificationService::current(); 45 NotificationService* service = NotificationService::current();
44 service->AddObserver(this, NOTIFY_LOAD_START, 46 service->AddObserver(this, NOTIFY_LOAD_START,
45 NotificationService::AllSources()); 47 NotificationService::AllSources());
46 service->AddObserver(this, NOTIFY_LOAD_STOP, 48 service->AddObserver(this, NOTIFY_LOAD_STOP,
(...skipping 2376 matching lines...) Expand 10 before | Expand all | Expand 10 after
2423 int value) { 2425 int value) {
2424 bool success = false; 2426 bool success = false;
2425 if (browser_tracker_->ContainsHandle(handle)) { 2427 if (browser_tracker_->ContainsHandle(handle)) {
2426 Browser* browser = browser_tracker_->GetResource(handle); 2428 Browser* browser = browser_tracker_->GetResource(handle);
2427 browser->profile()->GetPrefs()->SetInteger(name.c_str(), value); 2429 browser->profile()->GetPrefs()->SetInteger(name.c_str(), value);
2428 success = true; 2430 success = true;
2429 } 2431 }
2430 Send(new AutomationMsg_SetIntPreferenceResponse(message.routing_id(), 2432 Send(new AutomationMsg_SetIntPreferenceResponse(message.routing_id(),
2431 success)); 2433 success));
2432 } 2434 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698