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

Side by Side Diff: chrome/browser/chrome_browser_main_win.cc

Issue 133923002: Use a Finch Experiment to control the Browser Blacklist (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix unittests Created 6 years, 11 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
« no previous file with comments | « chrome/browser/DEPS ('k') | chrome/browser/chrome_elf_init_unittest_win.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 #include "chrome/browser/chrome_browser_main_win.h" 5 #include "chrome/browser/chrome_browser_main_win.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 #include <shellapi.h> 8 #include <shellapi.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
11 11
12 #include "base/command_line.h" 12 #include "base/command_line.h"
13 #include "base/environment.h" 13 #include "base/environment.h"
14 #include "base/files/file_path.h" 14 #include "base/files/file_path.h"
15 #include "base/i18n/rtl.h" 15 #include "base/i18n/rtl.h"
16 #include "base/memory/scoped_ptr.h" 16 #include "base/memory/scoped_ptr.h"
17 #include "base/path_service.h" 17 #include "base/path_service.h"
18 #include "base/scoped_native_library.h" 18 #include "base/scoped_native_library.h"
19 #include "base/strings/string_number_conversions.h" 19 #include "base/strings/string_number_conversions.h"
20 #include "base/strings/utf_string_conversions.h" 20 #include "base/strings/utf_string_conversions.h"
21 #include "base/win/metro.h" 21 #include "base/win/metro.h"
22 #include "base/win/windows_version.h" 22 #include "base/win/windows_version.h"
23 #include "base/win/wrapped_window_proc.h" 23 #include "base/win/wrapped_window_proc.h"
24 #include "chrome/browser/browser_util_win.h" 24 #include "chrome/browser/browser_util_win.h"
25 #include "chrome/browser/chrome_elf_init_win.h"
25 #include "chrome/browser/install_verification/win/install_verification.h" 26 #include "chrome/browser/install_verification/win/install_verification.h"
26 #include "chrome/browser/profiles/profile_info_cache.h" 27 #include "chrome/browser/profiles/profile_info_cache.h"
27 #include "chrome/browser/profiles/profile_shortcut_manager.h" 28 #include "chrome/browser/profiles/profile_shortcut_manager.h"
28 #include "chrome/browser/shell_integration.h" 29 #include "chrome/browser/shell_integration.h"
29 #include "chrome/browser/ui/simple_message_box.h" 30 #include "chrome/browser/ui/simple_message_box.h"
30 #include "chrome/browser/ui/uninstall_browser_prompt.h" 31 #include "chrome/browser/ui/uninstall_browser_prompt.h"
31 #include "chrome/common/chrome_constants.h" 32 #include "chrome/common/chrome_constants.h"
32 #include "chrome/common/chrome_result_codes.h" 33 #include "chrome/common/chrome_result_codes.h"
33 #include "chrome/common/chrome_switches.h" 34 #include "chrome/common/chrome_switches.h"
34 #include "chrome/common/chrome_version_info.h" 35 #include "chrome/common/chrome_version_info.h"
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 void ChromeBrowserMainPartsWin::PostBrowserStart() { 246 void ChromeBrowserMainPartsWin::PostBrowserStart() {
246 ChromeBrowserMainParts::PostBrowserStart(); 247 ChromeBrowserMainParts::PostBrowserStart();
247 248
248 // Set up a task to verify installed modules in the current process. Use a 249 // Set up a task to verify installed modules in the current process. Use a
249 // delay to reduce the impact on startup time. 250 // delay to reduce the impact on startup time.
250 content::BrowserThread::GetMessageLoopProxyForThread( 251 content::BrowserThread::GetMessageLoopProxyForThread(
251 content::BrowserThread::UI)->PostDelayedTask( 252 content::BrowserThread::UI)->PostDelayedTask(
252 FROM_HERE, 253 FROM_HERE,
253 base::Bind(&VerifyInstallation), 254 base::Bind(&VerifyInstallation),
254 base::TimeDelta::FromSeconds(45)); 255 base::TimeDelta::FromSeconds(45));
256
257 InitializeChromeElf();
255 } 258 }
256 259
257 // static 260 // static
258 void ChromeBrowserMainPartsWin::PrepareRestartOnCrashEnviroment( 261 void ChromeBrowserMainPartsWin::PrepareRestartOnCrashEnviroment(
259 const CommandLine& parsed_command_line) { 262 const CommandLine& parsed_command_line) {
260 // Clear this var so child processes don't show the dialog by default. 263 // Clear this var so child processes don't show the dialog by default.
261 scoped_ptr<base::Environment> env(base::Environment::Create()); 264 scoped_ptr<base::Environment> env(base::Environment::Create());
262 env->UnSetVar(env_vars::kShowRestart); 265 env->UnSetVar(env_vars::kShowRestart);
263 266
264 // For non-interactive tests we don't restart on crash. 267 // For non-interactive tests we don't restart on crash.
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
424 if (resource_id) 427 if (resource_id)
425 return l10n_util::GetStringUTF16(resource_id); 428 return l10n_util::GetStringUTF16(resource_id);
426 return base::string16(); 429 return base::string16();
427 } 430 }
428 431
429 // static 432 // static
430 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() { 433 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() {
431 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ()); 434 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ());
432 installer::SetTranslationDelegate(&delegate); 435 installer::SetTranslationDelegate(&delegate);
433 } 436 }
OLDNEW
« no previous file with comments | « chrome/browser/DEPS ('k') | chrome/browser/chrome_elf_init_unittest_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698