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

Unified Diff: chrome/browser/extensions/app_host_installer.cc

Issue 11054006: Make application shortcuts point to app_host.exe, install App Host during app installation. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Changing code entry from class to function. Created 8 years, 2 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
Index: chrome/browser/extensions/app_host_installer.cc
diff --git a/chrome/browser/extensions/app_host_installer.cc b/chrome/browser/extensions/app_host_installer.cc
new file mode 100644
index 0000000000000000000000000000000000000000..62ca0261627a462691d7de0936af9049aa53762d
--- /dev/null
+++ b/chrome/browser/extensions/app_host_installer.cc
@@ -0,0 +1,33 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "chrome/browser/extensions/app_host_installer.h"
+
+#include "base/callback.h"
+
+#if defined(OS_WIN)
+#include "chrome/browser/extensions/app_host_installer_impl_win.h"
+#endif
+
+namespace extensions {
+
+class Extension;
+
+namespace app_host_installer {
+
+void InstallAppHostIfNecessary(const Extension& extension,
+ const base::Callback<void(bool)>& completion_callback) {
+#if defined(OS_WIN)
+ // The implementation.
erikwright (departed) 2012/10/09 19:24:48 Go ahead and do the is_platform_app() check here,
huangs 2012/10/09 21:09:15 Done.
+ AppHostInstallerImpl* impl = new AppHostInstallerImpl();
erikwright (departed) 2012/10/09 19:24:48 Make the constructor and destructor of AppHostInst
huangs 2012/10/09 21:09:15 Nice. Done.
+ impl->InstallAppHostIfNecessary(extension, completion_callback);
+ // impl will handle its own destruction.
+#else
+ completion_callback.Run(true);
+#endif
+}
+
+} // namespace app_host_installer
+
+} // namespace extensions

Powered by Google App Engine
This is Rietveld 408576698