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

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

Issue 764753003: Enable streamlined-apps flag on Chrome for Mac. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments reguarding shortcuts on Mac Created 6 years, 1 month 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/about_flags.cc ('k') | chrome/browser/ui/browser_command_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/tab_helper.cc
diff --git a/chrome/browser/extensions/tab_helper.cc b/chrome/browser/extensions/tab_helper.cc
index bb1a06d97376255edc7546e6cf84bd64c1040179..19100e4386476ef0c26635035fe625882a98e594 100644
--- a/chrome/browser/extensions/tab_helper.cc
+++ b/chrome/browser/extensions/tab_helper.cc
@@ -148,11 +148,7 @@ bool TabHelper::CanCreateApplicationShortcuts() const {
}
bool TabHelper::CanCreateBookmarkApp() const {
-#if defined(OS_MACOSX)
- return false;
-#else
return IsValidBookmarkAppUrl(web_contents()->GetURL());
-#endif
}
void TabHelper::AddScriptExecutionObserver(ScriptExecutionObserver* observer) {
@@ -295,7 +291,6 @@ void TabHelper::DidCloneToNewWebContents(WebContents* old_web_contents,
}
void TabHelper::OnDidGetWebApplicationInfo(const WebApplicationInfo& info) {
-#if !defined(OS_MACOSX)
web_app_info_ = info;
NavigationEntry* entry =
@@ -305,12 +300,14 @@ void TabHelper::OnDidGetWebApplicationInfo(const WebApplicationInfo& info) {
last_committed_page_id_ = -1;
switch (pending_web_app_action_) {
+#if !defined(OS_MACOSX)
case CREATE_SHORTCUT: {
chrome::ShowCreateWebAppShortcutsDialog(
web_contents()->GetTopLevelNativeWindow(),
web_contents());
break;
}
+#endif
case CREATE_HOSTED_APP: {
if (web_app_info_.app_url.is_empty())
web_app_info_.app_url = web_contents()->GetURL();
@@ -340,7 +337,6 @@ void TabHelper::OnDidGetWebApplicationInfo(const WebApplicationInfo& info) {
// fails.
if (pending_web_app_action_ != CREATE_HOSTED_APP)
pending_web_app_action_ = NONE;
-#endif
}
void TabHelper::OnInlineWebstoreInstall(int install_id,
« no previous file with comments | « chrome/browser/about_flags.cc ('k') | chrome/browser/ui/browser_command_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698