Index: ash/system/tray/tray_event_filter.cc |
diff --git a/ash/system/tray/tray_event_filter.cc b/ash/system/tray/tray_event_filter.cc |
index 43f142b4cd7e4ee240918cf5f1d0762bdfb37538..8be7545fa014c31ae7eaf89ce150039bdd090f2b 100644 |
--- a/ash/system/tray/tray_event_filter.cc |
+++ b/ash/system/tray/tray_event_filter.cc |
@@ -5,10 +5,12 @@ |
#include "ash/system/tray/tray_event_filter.h" |
#include "ash/public/cpp/shell_window_ids.h" |
+#include "ash/shell.h" |
#include "ash/shell_port.h" |
#include "ash/system/tray/tray_background_view.h" |
#include "ash/system/tray/tray_bubble_wrapper.h" |
#include "ash/wm/container_finder.h" |
+#include "ash/wm/maximize_mode/maximize_mode_controller.h" |
#include "ui/aura/window.h" |
#include "ui/views/widget/widget.h" |
@@ -73,6 +75,14 @@ void TrayEventFilter::ProcessPressedEvent(const gfx::Point& location_in_screen, |
gfx::Rect bounds = bubble_widget->GetWindowBoundsInScreen(); |
bounds.Inset(wrapper->bubble_view()->GetBorderInsets()); |
+ // System tray can be dragged to show the bubble if it is in maximize mode. |
+ // The events happened on the clipped part of the bubble should be considerd |
+ // happened outside the bubble. |
tdanderson
2017/06/26 18:13:02
Suggestion to re-word the second sentence: "During
minch1
2017/06/26 23:26:48
Yes, thanks.
|
+ if (Shell::Get() |
+ ->maximize_mode_controller() |
+ ->IsMaximizeModeWindowManagerEnabled()) { |
tdanderson
2017/06/26 18:13:02
Do you intentionally not check container_id == kSh
minch1
2017/06/26 23:26:49
I don't think that for all the other containers th
|
+ bounds.Intersect(bubble_widget->GetWorkAreaBoundsInScreen()); |
+ } |
if (bounds.Contains(location_in_screen)) |
continue; |
if (wrapper->tray()) { |