Index: chrome/browser/ui/webui/ntp/new_tab_ui.cc |
diff --git a/chrome/browser/ui/webui/ntp/new_tab_ui.cc b/chrome/browser/ui/webui/ntp/new_tab_ui.cc |
index 10165722a0f7b7bc3b75134c926dffcd3a61f353..60020dd9036fc6ada1bcb430f99082ed9aee9f41 100644 |
--- a/chrome/browser/ui/webui/ntp/new_tab_ui.cc |
+++ b/chrome/browser/ui/webui/ntp/new_tab_ui.cc |
@@ -52,6 +52,10 @@ |
#include "chrome/browser/ui/webui/theme_handler.h" |
#endif |
+#if defined(USE_ASH) |
+#include "chrome/browser/ui/host_desktop.h" |
+#endif |
+ |
using content::BrowserThread; |
using content::RenderViewHost; |
using content::WebUIController; |
@@ -242,14 +246,14 @@ void NewTabUI::RegisterUserPrefs(PrefRegistrySyncable* registry) { |
// static |
bool NewTabUI::ShouldShowApps() { |
+// Ash shows apps in app list thus should not show apps page in NTP4. |
+// Android does not have apps. |
#if defined(OS_ANDROID) |
- // Ash shows apps in app list thus should not show apps page in NTP4. |
- // Android does not have apps. |
return false; |
+#elif defined(USE_ASH) |
+ return chrome::GetActiveDesktop() != chrome::HOST_DESKTOP_TYPE_ASH; |
#else |
- // This needs to be synchronous, so we use the value the last time it |
- // was checked. |
- return !apps::WasAppLauncherEnabled(); |
+ return true; |
#endif |
} |