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

Side by Side Diff: chrome/browser/protector/settings_change_global_error.cc

Issue 8437002: Move BrowserThread to content namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: A few updates. 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 #include "chrome/browser/protector/settings_change_global_error.h" 5 #include "chrome/browser/protector/settings_change_global_error.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
11 #include "chrome/app/chrome_command_ids.h" 11 #include "chrome/app/chrome_command_ids.h"
12 #include "chrome/browser/profiles/profile.h" 12 #include "chrome/browser/profiles/profile.h"
13 #include "chrome/browser/protector/settings_change_global_error_delegate.h" 13 #include "chrome/browser/protector/settings_change_global_error_delegate.h"
14 #include "chrome/browser/ui/browser_list.h" 14 #include "chrome/browser/ui/browser_list.h"
15 #include "chrome/browser/ui/global_error_service.h" 15 #include "chrome/browser/ui/global_error_service.h"
16 #include "chrome/browser/ui/global_error_service_factory.h" 16 #include "chrome/browser/ui/global_error_service_factory.h"
17 #include "content/public/browser/browser_thread.h" 17 #include "content/public/browser/browser_thread.h"
18 #include "grit/chromium_strings.h" 18 #include "grit/chromium_strings.h"
19 #include "grit/generated_resources.h" 19 #include "grit/generated_resources.h"
20 #include "ui/base/l10n/l10n_util.h" 20 #include "ui/base/l10n/l10n_util.h"
21 21
22 using content::BrowserThread;
23
22 namespace protector { 24 namespace protector {
23 25
24 namespace { 26 namespace {
25 27
26 // Timeout before the global error is removed (wrench menu item disappears). 28 // Timeout before the global error is removed (wrench menu item disappears).
27 const int kMenuItemDisplayPeriodMs = 10*60*1000; // 10 min 29 const int kMenuItemDisplayPeriodMs = 10*60*1000; // 10 min
28 30
29 // IDs of menu item labels. 31 // IDs of menu item labels.
30 const int kMenuItemLabelIDs[] = { 32 const int kMenuItemLabelIDs[] = {
31 IDS_SEARCH_ENGINE_CHANGE_WRENCH_MENU_ITEM, 33 IDS_SEARCH_ENGINE_CHANGE_WRENCH_MENU_ITEM,
(...skipping 176 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 210
209 void SettingsChangeGlobalError::Show() { 211 void SettingsChangeGlobalError::Show() {
210 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); 212 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
211 DCHECK(profile_); 213 DCHECK(profile_);
212 browser_ = BrowserList::GetLastActiveWithProfile(profile_); 214 browser_ = BrowserList::GetLastActiveWithProfile(profile_);
213 if (browser_) 215 if (browser_)
214 ShowBubbleView(browser_); 216 ShowBubbleView(browser_);
215 } 217 }
216 218
217 } // namespace protector 219 } // namespace protector
OLDNEW
« no previous file with comments | « chrome/browser/protector/protector.cc ('k') | chrome/browser/renderer_host/chrome_render_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698