summaryrefslogtreecommitdiffstats
path: root/ash/launcher
diff options
context:
space:
mode:
Diffstat (limited to 'ash/launcher')
-rw-r--r--ash/launcher/launcher.cc4
-rw-r--r--ash/launcher/launcher.h7
-rw-r--r--ash/launcher/launcher_view.cc6
3 files changed, 11 insertions, 6 deletions
diff --git a/ash/launcher/launcher.cc b/ash/launcher/launcher.cc
index 03e7ff8..3dd2a14 100644
--- a/ash/launcher/launcher.cc
+++ b/ash/launcher/launcher.cc
@@ -186,4 +186,8 @@ gfx::Rect Launcher::GetLauncherViewBounds() const {
return launcher_view_->bounds();
}
+app_list::ApplicationDragAndDropHost* Launcher::GetDragAndDropHostForAppList() {
+ return launcher_view_;
+}
+
} // namespace ash
diff --git a/ash/launcher/launcher.h b/ash/launcher/launcher.h
index f9bdcc0..c670801 100644
--- a/ash/launcher/launcher.h
+++ b/ash/launcher/launcher.h
@@ -13,6 +13,10 @@
#include "ui/gfx/size.h"
#include "ui/views/widget/widget_observer.h"
+namespace app_list {
+class ApplicationDragAndDropHost;
+}
+
namespace aura {
class Window;
}
@@ -103,6 +107,9 @@ class ASH_EXPORT Launcher {
void SetLauncherViewBounds(gfx::Rect bounds);
gfx::Rect GetLauncherViewBounds() const;
+ // Returns ApplicationDragAndDropHost for this Launcher.
+ app_list::ApplicationDragAndDropHost* GetDragAndDropHostForAppList();
+
private:
// LauncherView used to display icons.
internal::LauncherView* launcher_view_;
diff --git a/ash/launcher/launcher_view.cc b/ash/launcher/launcher_view.cc
index ea027f6..3d32892 100644
--- a/ash/launcher/launcher_view.cc
+++ b/ash/launcher/launcher_view.cc
@@ -25,7 +25,6 @@
#include "ash/shelf/shelf_widget.h"
#include "ash/shell_delegate.h"
#include "base/auto_reset.h"
-#include "base/command_line.h"
#include "base/memory/scoped_ptr.h"
#include "grit/ash_resources.h"
#include "grit/ash_strings.h"
@@ -1524,11 +1523,6 @@ void LauncherView::ButtonPressed(views::Button* sender,
Shell::GetInstance()->delegate()->RecordUserMetricsAction(
UMA_LAUNCHER_CLICK_ON_APPLIST_BUTTON);
Shell::GetInstance()->ToggleAppList(GetWidget()->GetNativeView());
- // By setting us as DnD recipient, the app list knows that we can
- // handle items.
- if (!CommandLine::ForCurrentProcess()->HasSwitch(
- ash::switches::kAshDisableDragAndDropAppListToLauncher))
- Shell::GetInstance()->SetDragAndDropHostOfCurrentAppList(this);
break;
}
}