Chromium Code Reviews| Index: ui/views/view.cc |
| diff --git a/ui/views/view.cc b/ui/views/view.cc |
| index 9e6d59df3ed405ff8e039bf7d9ce0534ee6cd443..c98dd2a8470b83ae4839ba8b148efcd200de895a 100644 |
| --- a/ui/views/view.cc |
| +++ b/ui/views/view.cc |
| @@ -42,6 +42,7 @@ |
| #include "ui/views/layout/layout_manager.h" |
| #include "ui/views/rect_based_targeting_utils.h" |
| #include "ui/views/views_delegate.h" |
| +#include "ui/views/views_switches.h" |
| #include "ui/views/widget/native_widget_private.h" |
| #include "ui/views/widget/root_view.h" |
| #include "ui/views/widget/tooltip_manager.h" |
| @@ -97,7 +98,7 @@ class PostEventDispatchHandler : public ui::EventHandler { |
| public: |
| explicit PostEventDispatchHandler(View* owner) |
| : owner_(owner), |
| - touch_dnd_enabled_(switches::IsTouchDragDropEnabled()) { |
| + touch_dnd_enabled_(::switches::IsTouchDragDropEnabled()) { |
| } |
| virtual ~PostEventDispatchHandler() {} |
| @@ -949,7 +950,7 @@ bool View::HitTestPoint(const gfx::Point& point) const { |
| bool View::HitTestRect(const gfx::Rect& rect) const { |
| if (GetLocalBounds().Intersects(rect)) { |
| - if (HasHitTestMask()) { |
| + if (views::switches::IsRectBasedTargetingEnabled() && HasHitTestMask()) { |
|
sadrul
2014/01/23 00:40:42
Does this break hit-testing along the slanted edge
msw
2014/01/23 00:54:32
Hmm, yeah. Adjacent tabs obscure the right half of
|
| gfx::Path mask; |
| HitTestSource source = HIT_TEST_SOURCE_MOUSE; |
| if (!views::UsePointBasedTargeting(rect)) |