| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/events/event.h" | 5 #include "ui/views/events/event.h" |
| 6 | 6 |
| 7 #include "ui/views/view.h" | 7 #include "ui/views/view.h" |
| 8 | 8 |
| 9 namespace ui { | 9 namespace ui { |
| 10 | 10 |
| (...skipping 26 matching lines...) Expand all Loading... |
| 37 int flags) | 37 int flags) |
| 38 : Event(type, flags), | 38 : Event(type, flags), |
| 39 location_(location) { | 39 location_(location) { |
| 40 } | 40 } |
| 41 | 41 |
| 42 LocatedEvent::LocatedEvent(const LocatedEvent& other, | 42 LocatedEvent::LocatedEvent(const LocatedEvent& other, |
| 43 View* source, | 43 View* source, |
| 44 View* target) | 44 View* target) |
| 45 : Event(other.type(), other.flags()) { | 45 : Event(other.type(), other.flags()) { |
| 46 location_ = other.location(); | 46 location_ = other.location(); |
| 47 View::ConvertPointToView(source, target, &location_); | 47 View::ConvertPointToView(*source, *target, &location_); |
| 48 } | 48 } |
| 49 | 49 |
| 50 //////////////////////////////////////////////////////////////////////////////// | 50 //////////////////////////////////////////////////////////////////////////////// |
| 51 // MouseEvent, public: | 51 // MouseEvent, public: |
| 52 | 52 |
| 53 MouseEvent::MouseEvent(const MouseEvent& other, View* source, View* target) | 53 MouseEvent::MouseEvent(const MouseEvent& other, View* source, View* target) |
| 54 : LocatedEvent(other, source, target) { | 54 : LocatedEvent(other, source, target) { |
| 55 } | 55 } |
| 56 | 56 |
| 57 } // namespace ui | 57 } // namespace ui |
| OLD | NEW |