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

Unified Diff: chrome/browser/apps/shortcut_manager.cc

Issue 298953002: Remove --disable-app-shims. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Sync and rebase Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/app_controller_mac.mm ('k') | chrome/browser/resources/ntp4/apps_page.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/apps/shortcut_manager.cc
diff --git a/chrome/browser/apps/shortcut_manager.cc b/chrome/browser/apps/shortcut_manager.cc
index 66ba3d75838db500072d969a9ed93cd920d3c61f..2e5221a4471cb009e326bd06480383a39715113b 100644
--- a/chrome/browser/apps/shortcut_manager.cc
+++ b/chrome/browser/apps/shortcut_manager.cc
@@ -28,10 +28,6 @@
#include "extensions/browser/extension_system.h"
#include "extensions/common/extension_set.h"
-#if defined(OS_MACOSX)
-#include "apps/app_shim/app_shim_mac.h"
-#endif
-
using extensions::Extension;
namespace {
@@ -110,11 +106,6 @@ void AppShortcutManager::Observe(int type,
break;
}
case chrome::NOTIFICATION_EXTENSION_INSTALLED_DEPRECATED: {
-#if defined(OS_MACOSX)
- if (!apps::IsAppShimsEnabled())
- break;
-#endif // defined(OS_MACOSX)
-
const extensions::InstalledExtensionInfo* installed_info =
content::Details<const extensions::InstalledExtensionInfo>(details)
.ptr();
@@ -152,22 +143,11 @@ void AppShortcutManager::OnProfileWillBeRemoved(
}
void AppShortcutManager::OnceOffCreateShortcuts() {
- bool was_enabled = prefs_->GetBoolean(prefs::kAppShortcutsHaveBeenCreated);
-
- // Creation of shortcuts on Mac currently can be disabled with
- // --disable-app-shims, so check the flag, and set the pref accordingly.
-#if defined(OS_MACOSX)
- bool is_now_enabled = apps::IsAppShimsEnabled();
-#else
- bool is_now_enabled = true;
-#endif // defined(OS_MACOSX)
-
- if (was_enabled != is_now_enabled)
- prefs_->SetBoolean(prefs::kAppShortcutsHaveBeenCreated, is_now_enabled);
-
- if (was_enabled || !is_now_enabled)
+ if (prefs_->GetBoolean(prefs::kAppShortcutsHaveBeenCreated))
return;
+ prefs_->SetBoolean(prefs::kAppShortcutsHaveBeenCreated, true);
+
// Check if extension system/service are available. They might not be in
// tests.
extensions::ExtensionSystem* extension_system;
« no previous file with comments | « chrome/browser/app_controller_mac.mm ('k') | chrome/browser/resources/ntp4/apps_page.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698