| 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/aura/window.h" | 5 #include "ui/aura/window.h" |
| 6 | 6 |
| 7 #include "base/basictypes.h" | 7 #include "base/basictypes.h" |
| 8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
| 9 #include "base/stringprintf.h" | 9 #include "base/stringprintf.h" |
| 10 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 void set_touch_event_count(int value) { touch_event_count_ = value; } | 105 void set_touch_event_count(int value) { touch_event_count_ = value; } |
| 106 | 106 |
| 107 virtual bool OnMouseEvent(MouseEvent* event) OVERRIDE { | 107 virtual bool OnMouseEvent(MouseEvent* event) OVERRIDE { |
| 108 mouse_event_count_++; | 108 mouse_event_count_++; |
| 109 return false; | 109 return false; |
| 110 } | 110 } |
| 111 virtual ui::TouchStatus OnTouchEvent(TouchEvent* event) OVERRIDE { | 111 virtual ui::TouchStatus OnTouchEvent(TouchEvent* event) OVERRIDE { |
| 112 touch_event_count_++; | 112 touch_event_count_++; |
| 113 return ui::TOUCH_STATUS_UNKNOWN; | 113 return ui::TOUCH_STATUS_UNKNOWN; |
| 114 } | 114 } |
| 115 virtual ui::GestureStatus OnGestureEvent(GestureEvent* event) OVERRIDE { |
| 116 return ui::GESTURE_STATUS_UNKNOWN; |
| 117 } |
| 115 virtual void OnCaptureLost() OVERRIDE { | 118 virtual void OnCaptureLost() OVERRIDE { |
| 116 capture_lost_count_++; | 119 capture_lost_count_++; |
| 117 } | 120 } |
| 118 | 121 |
| 119 private: | 122 private: |
| 120 int capture_lost_count_; | 123 int capture_lost_count_; |
| 121 int mouse_event_count_; | 124 int mouse_event_count_; |
| 122 int touch_event_count_; | 125 int touch_event_count_; |
| 123 | 126 |
| 124 DISALLOW_COPY_AND_ASSIGN(CaptureWindowDelegateImpl); | 127 DISALLOW_COPY_AND_ASSIGN(CaptureWindowDelegateImpl); |
| (...skipping 905 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1030 EXPECT_EQ("name=test old=1 new=2", PropertyChangeInfoAndClear()); | 1033 EXPECT_EQ("name=test old=1 new=2", PropertyChangeInfoAndClear()); |
| 1031 w1->SetProperty(key, NULL); | 1034 w1->SetProperty(key, NULL); |
| 1032 EXPECT_EQ("name=test old=2 new=0", PropertyChangeInfoAndClear()); | 1035 EXPECT_EQ("name=test old=2 new=0", PropertyChangeInfoAndClear()); |
| 1033 | 1036 |
| 1034 // Sanity check to see if |PropertyChangeInfoAndClear| really clears. | 1037 // Sanity check to see if |PropertyChangeInfoAndClear| really clears. |
| 1035 EXPECT_EQ("name= old=0 new=0", PropertyChangeInfoAndClear()); | 1038 EXPECT_EQ("name= old=0 new=0", PropertyChangeInfoAndClear()); |
| 1036 } | 1039 } |
| 1037 | 1040 |
| 1038 } // namespace test | 1041 } // namespace test |
| 1039 } // namespace aura | 1042 } // namespace aura |
| OLD | NEW |