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

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

Issue 23513049: Implement install module verification metric. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 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 | Annotate | Revision Log
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/install_module_verifier_win.h"
25 #include "chrome/browser/profiles/profile_info_cache.h" 26 #include "chrome/browser/profiles/profile_info_cache.h"
26 #include "chrome/browser/profiles/profile_shortcut_manager.h" 27 #include "chrome/browser/profiles/profile_shortcut_manager.h"
27 #include "chrome/browser/shell_integration.h" 28 #include "chrome/browser/shell_integration.h"
28 #include "chrome/browser/ui/simple_message_box.h" 29 #include "chrome/browser/ui/simple_message_box.h"
29 #include "chrome/browser/ui/uninstall_browser_prompt.h" 30 #include "chrome/browser/ui/uninstall_browser_prompt.h"
30 #include "chrome/common/chrome_constants.h" 31 #include "chrome/common/chrome_constants.h"
31 #include "chrome/common/chrome_result_codes.h" 32 #include "chrome/common/chrome_result_codes.h"
32 #include "chrome/common/chrome_switches.h" 33 #include "chrome/common/chrome_switches.h"
33 #include "chrome/common/chrome_version_info.h" 34 #include "chrome/common/chrome_version_info.h"
34 #include "chrome/common/env_vars.h" 35 #include "chrome/common/env_vars.h"
(...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after
217 218
218 return rv; 219 return rv;
219 } 220 }
220 221
221 void ChromeBrowserMainPartsWin::ShowMissingLocaleMessageBox() { 222 void ChromeBrowserMainPartsWin::ShowMissingLocaleMessageBox() {
222 ui::MessageBox(NULL, ASCIIToUTF16(chrome_browser::kMissingLocaleDataMessage), 223 ui::MessageBox(NULL, ASCIIToUTF16(chrome_browser::kMissingLocaleDataMessage),
223 ASCIIToUTF16(chrome_browser::kMissingLocaleDataTitle), 224 ASCIIToUTF16(chrome_browser::kMissingLocaleDataTitle),
224 MB_OK | MB_ICONERROR | MB_TOPMOST); 225 MB_OK | MB_ICONERROR | MB_TOPMOST);
225 } 226 }
226 227
228 void ChromeBrowserMainPartsWin::PostBrowserStart() {
229 ChromeBrowserMainParts::PostBrowserStart();
230 InitiateInstalledModuleVerification();
231 }
232
erikwright (departed) 2013/09/13 14:47:07 remove one blank line
erikwright (departed) 2013/09/13 20:19:56 Done.
233
227 // static 234 // static
228 void ChromeBrowserMainPartsWin::PrepareRestartOnCrashEnviroment( 235 void ChromeBrowserMainPartsWin::PrepareRestartOnCrashEnviroment(
229 const CommandLine& parsed_command_line) { 236 const CommandLine& parsed_command_line) {
230 // Clear this var so child processes don't show the dialog by default. 237 // Clear this var so child processes don't show the dialog by default.
231 scoped_ptr<base::Environment> env(base::Environment::Create()); 238 scoped_ptr<base::Environment> env(base::Environment::Create());
232 env->UnSetVar(env_vars::kShowRestart); 239 env->UnSetVar(env_vars::kShowRestart);
233 240
234 // For non-interactive tests we don't restart on crash. 241 // For non-interactive tests we don't restart on crash.
235 if (env->HasVar(env_vars::kHeadless)) 242 if (env->HasVar(env_vars::kHeadless))
236 return; 243 return;
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
393 if (resource_id) 400 if (resource_id)
394 return l10n_util::GetStringUTF16(resource_id); 401 return l10n_util::GetStringUTF16(resource_id);
395 return string16(); 402 return string16();
396 } 403 }
397 404
398 // static 405 // static
399 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() { 406 void ChromeBrowserMainPartsWin::SetupInstallerUtilStrings() {
400 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ()); 407 CR_DEFINE_STATIC_LOCAL(TranslationDelegate, delegate, ());
401 installer::SetTranslationDelegate(&delegate); 408 installer::SetTranslationDelegate(&delegate);
402 } 409 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698