| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/views/widget/native_widget_aura.h" | 5 #include "ui/views/widget/native_widget_aura.h" |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
| 9 #include "third_party/skia/include/core/SkRegion.h" | 9 #include "third_party/skia/include/core/SkRegion.h" |
| 10 #include "ui/aura/client/activation_client.h" | 10 #include "ui/aura/client/activation_client.h" |
| (...skipping 823 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 834 return delegate_->OnMouseEvent(mwe) ? ui::ER_HANDLED : ui::ER_UNHANDLED; | 834 return delegate_->OnMouseEvent(mwe) ? ui::ER_HANDLED : ui::ER_UNHANDLED; |
| 835 } | 835 } |
| 836 return delegate_->OnScrollEvent(event); | 836 return delegate_->OnScrollEvent(event); |
| 837 } | 837 } |
| 838 | 838 |
| 839 ui::EventResult NativeWidgetAura::OnTouchEvent(ui::TouchEvent* event) { | 839 ui::EventResult NativeWidgetAura::OnTouchEvent(ui::TouchEvent* event) { |
| 840 DCHECK(window_->IsVisible()); | 840 DCHECK(window_->IsVisible()); |
| 841 return delegate_->OnTouchEvent(event); | 841 return delegate_->OnTouchEvent(event); |
| 842 } | 842 } |
| 843 | 843 |
| 844 ui::EventResult NativeWidgetAura::OnGestureEvent(ui::GestureEvent* event) { | 844 void NativeWidgetAura::OnGestureEvent(ui::GestureEvent* event) { |
| 845 DCHECK(window_->IsVisible()); | 845 DCHECK(window_->IsVisible()); |
| 846 return delegate_->OnGestureEvent(event); | 846 delegate_->OnGestureEvent(event); |
| 847 } | 847 } |
| 848 | 848 |
| 849 //////////////////////////////////////////////////////////////////////////////// | 849 //////////////////////////////////////////////////////////////////////////////// |
| 850 // NativeWidgetAura, aura::ActivationDelegate implementation: | 850 // NativeWidgetAura, aura::ActivationDelegate implementation: |
| 851 | 851 |
| 852 bool NativeWidgetAura::ShouldActivate() const { | 852 bool NativeWidgetAura::ShouldActivate() const { |
| 853 return can_activate_ && delegate_->CanActivate(); | 853 return can_activate_ && delegate_->CanActivate(); |
| 854 } | 854 } |
| 855 | 855 |
| 856 void NativeWidgetAura::OnActivated() { | 856 void NativeWidgetAura::OnActivated() { |
| (...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1059 return aura::Env::GetInstance()->is_mouse_button_down(); | 1059 return aura::Env::GetInstance()->is_mouse_button_down(); |
| 1060 } | 1060 } |
| 1061 | 1061 |
| 1062 // static | 1062 // static |
| 1063 bool NativeWidgetPrivate::IsTouchDown() { | 1063 bool NativeWidgetPrivate::IsTouchDown() { |
| 1064 return aura::Env::GetInstance()->is_touch_down(); | 1064 return aura::Env::GetInstance()->is_touch_down(); |
| 1065 } | 1065 } |
| 1066 | 1066 |
| 1067 } // namespace internal | 1067 } // namespace internal |
| 1068 } // namespace views | 1068 } // namespace views |
| OLD | NEW |