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

Unified Diff: chrome/browser/ui/browser.cc

Issue 8585040: Fix DownloadTests and change cros/aura to use shelf (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Review nits Created 9 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
Index: chrome/browser/ui/browser.cc
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
index 70e8b1c8080ac31db344661651f61585454e65ef..feb12336137346185cf985c96cfc4ce700ea3af7 100644
--- a/chrome/browser/ui/browser.cc
+++ b/chrome/browser/ui/browser.cc
@@ -184,7 +184,9 @@
#if defined(OS_CHROMEOS)
#include "chrome/browser/chromeos/boot_times_loader.h"
#include "chrome/browser/ui/webui/active_downloads_ui.h"
-#else
+#endif
+
+#if !defined(OS_CHROMEOS) || defined(USE_AURA)
#include "chrome/browser/download/download_shelf.h"
#endif
@@ -1437,11 +1439,11 @@ bool Browser::SupportsWindowFeatureImpl(WindowFeature feature,
unsigned int features = FEATURE_INFOBAR | FEATURE_SIDEBAR;
-#if !defined(OS_CHROMEOS)
+#if !defined(OS_CHROMEOS) || defined(USE_AURA)
// Chrome OS opens a FileBrowse pop up instead of using download shelf.
// So FEATURE_DOWNLOADSHELF is only added for non-chromeos platforms.
features |= FEATURE_DOWNLOADSHELF;
-#endif // !defined(OS_CHROMEOS)
+#endif // !defined(OS_CHROMEOS) || defined(USE_AURA)
if (is_type_tabbed())
features |= FEATURE_BOOKMARKBAR;
@@ -3724,7 +3726,7 @@ void Browser::OnStartDownload(TabContents* source, DownloadItem* download) {
return;
if (DisplayOldDownloadsUI()) {
-#if defined(OS_CHROMEOS)
+#if defined(OS_CHROMEOS) && !defined(USE_AURA)
// Don't show content browser for extension/theme downloads from gallery.
ExtensionService* service = profile_->GetExtensionService();
if (!ChromeDownloadManagerDelegate::IsExtensionDownload(download) ||
@@ -3734,7 +3736,7 @@ void Browser::OnStartDownload(TabContents* source, DownloadItem* download) {
// Open the Active Downloads ui for chromeos.
ActiveDownloadsUI::OpenPopup(profile_);
}
-#elif !defined(USE_AURA)
+#else
// GetDownloadShelf creates the download shelf if it was not yet created.
DownloadShelf* shelf = window()->GetDownloadShelf();
shelf->AddDownload(new DownloadItemModel(download));
« no previous file with comments | « chrome/browser/download/download_util.cc ('k') | chrome/browser/ui/views/download/download_started_animation_views.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698