| OLD | NEW |
| 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/first_run/first_run.h" | 5 #include "chrome/browser/first_run/first_run.h" |
| 6 | 6 |
| 7 #include <shlobj.h> | 7 #include <shlobj.h> |
| 8 #include <windows.h> | 8 #include <windows.h> |
| 9 | 9 |
| 10 #include <set> | 10 #include <set> |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 #include "chrome/browser/profiles/profile.h" | 29 #include "chrome/browser/profiles/profile.h" |
| 30 #include "chrome/common/chrome_notification_types.h" | 30 #include "chrome/common/chrome_notification_types.h" |
| 31 #include "chrome/common/chrome_result_codes.h" | 31 #include "chrome/common/chrome_result_codes.h" |
| 32 #include "chrome/common/chrome_switches.h" | 32 #include "chrome/common/chrome_switches.h" |
| 33 #include "chrome/common/worker_thread_ticker.h" | 33 #include "chrome/common/worker_thread_ticker.h" |
| 34 #include "chrome/installer/util/browser_distribution.h" | 34 #include "chrome/installer/util/browser_distribution.h" |
| 35 #include "chrome/installer/util/install_util.h" | 35 #include "chrome/installer/util/install_util.h" |
| 36 #include "chrome/installer/util/master_preferences.h" | 36 #include "chrome/installer/util/master_preferences.h" |
| 37 #include "chrome/installer/util/shell_util.h" | 37 #include "chrome/installer/util/shell_util.h" |
| 38 #include "chrome/installer/util/util_constants.h" | 38 #include "chrome/installer/util/util_constants.h" |
| 39 #include "content/browser/user_metrics.h" | |
| 40 #include "content/public/browser/notification_service.h" | 39 #include "content/public/browser/notification_service.h" |
| 40 #include "content/public/browser/user_metrics.h" |
| 41 #include "google_update_idl.h" | 41 #include "google_update_idl.h" |
| 42 #include "grit/chromium_strings.h" | 42 #include "grit/chromium_strings.h" |
| 43 #include "grit/generated_resources.h" | 43 #include "grit/generated_resources.h" |
| 44 #include "grit/locale_settings.h" | 44 #include "grit/locale_settings.h" |
| 45 #include "grit/theme_resources.h" | 45 #include "grit/theme_resources.h" |
| 46 #include "ui/base/resource/resource_bundle.h" | 46 #include "ui/base/resource/resource_bundle.h" |
| 47 #include "ui/base/ui_base_switches.h" | 47 #include "ui/base/ui_base_switches.h" |
| 48 | 48 |
| 49 using content::UserMetricsAction; |
| 50 |
| 49 namespace { | 51 namespace { |
| 50 | 52 |
| 51 // Helper class that performs delayed first-run tasks that need more of the | 53 // Helper class that performs delayed first-run tasks that need more of the |
| 52 // chrome infrastructure to be up and running before they can be attempted. | 54 // chrome infrastructure to be up and running before they can be attempted. |
| 53 class FirstRunDelayedTasks : public content::NotificationObserver { | 55 class FirstRunDelayedTasks : public content::NotificationObserver { |
| 54 public: | 56 public: |
| 55 enum Tasks { | 57 enum Tasks { |
| 56 NO_TASK, | 58 NO_TASK, |
| 57 INSTALL_EXTENSIONS | 59 INSTALL_EXTENSIONS |
| 58 }; | 60 }; |
| (...skipping 352 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 411 parent_window, | 413 parent_window, |
| 412 static_cast<uint16>(items_to_import), | 414 static_cast<uint16>(items_to_import), |
| 413 importer_host, | 415 importer_host, |
| 414 &importer_observer, | 416 &importer_observer, |
| 415 importer_list->GetSourceProfileForImporterType(importer_type), | 417 importer_list->GetSourceProfileForImporterType(importer_type), |
| 416 profile, | 418 profile, |
| 417 true); | 419 true); |
| 418 importer_observer.RunLoop(); | 420 importer_observer.RunLoop(); |
| 419 return importer_observer.import_result(); | 421 return importer_observer.import_result(); |
| 420 } | 422 } |
| OLD | NEW |