Index: ui/views/view.cc |
diff --git a/ui/views/view.cc b/ui/views/view.cc |
index 955ad2482d25ba893528f1db1ac3d3bd56e70910..3d902a6487fb939c2f0bd437a5215d4701034f6e 100644 |
--- a/ui/views/view.cc |
+++ b/ui/views/view.cc |
@@ -849,6 +849,9 @@ View* View::GetEventHandlerForRect(const gfx::Rect& rect) { |
for (int i = child_count() - 1; i >= 0; --i) { |
View* child = child_at(i); |
+ if (!child->CanProcessEventsWithinSubtree()) |
+ continue; |
+ |
// Ignore any children which are invisible or do not intersect |rect|. |
if (!child->visible()) |
continue; |
@@ -904,6 +907,10 @@ View* View::GetEventHandlerForRect(const gfx::Rect& rect) { |
return rect_view ? rect_view : point_view; |
} |
+bool View::CanProcessEventsWithinSubtree() const { |
+ return true; |
+} |
+ |
View* View::GetTooltipHandlerForPoint(const gfx::Point& point) { |
if (!HitTestPoint(point)) |
return NULL; |
@@ -915,6 +922,9 @@ View* View::GetTooltipHandlerForPoint(const gfx::Point& point) { |
if (!child->visible()) |
continue; |
+ if (!child->CanProcessEventsWithinSubtree()) |
+ continue; |
+ |
gfx::Point point_in_child_coords(point); |
ConvertPointToTarget(this, child, &point_in_child_coords); |
View* handler = child->GetTooltipHandlerForPoint(point_in_child_coords); |