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 #ifndef UI_BASE_EVENTS_EVENT_H_ | 5 #ifndef UI_BASE_EVENTS_EVENT_H_ |
6 #define UI_BASE_EVENTS_EVENT_H_ | 6 #define UI_BASE_EVENTS_EVENT_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
10 #include "base/event_types.h" | 10 #include "base/event_types.h" |
(...skipping 637 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
648 // This is useful in the multi-monitor setup where it needs to be scaled | 648 // This is useful in the multi-monitor setup where it needs to be scaled |
649 // to provide a consistent user experience. | 649 // to provide a consistent user experience. |
650 void Scale(const float factor); | 650 void Scale(const float factor); |
651 | 651 |
652 float x_offset() const { return x_offset_; } | 652 float x_offset() const { return x_offset_; } |
653 float y_offset() const { return y_offset_; } | 653 float y_offset() const { return y_offset_; } |
654 float x_offset_ordinal() const { return x_offset_ordinal_; } | 654 float x_offset_ordinal() const { return x_offset_ordinal_; } |
655 float y_offset_ordinal() const { return y_offset_ordinal_; } | 655 float y_offset_ordinal() const { return y_offset_ordinal_; } |
656 int finger_count() const { return finger_count_; } | 656 int finger_count() const { return finger_count_; } |
657 | 657 |
| 658 // Overridden from LocatedEvent. |
| 659 virtual void UpdateForRootTransform( |
| 660 const gfx::Transform& root_transform) OVERRIDE; |
| 661 |
658 private: | 662 private: |
659 // Potential accelerated offsets. | 663 // Potential accelerated offsets. |
660 float x_offset_; | 664 float x_offset_; |
661 float y_offset_; | 665 float y_offset_; |
662 // Unaccelerated offsets. | 666 // Unaccelerated offsets. |
663 float x_offset_ordinal_; | 667 float x_offset_ordinal_; |
664 float y_offset_ordinal_; | 668 float y_offset_ordinal_; |
665 // Number of fingers on the pad. | 669 // Number of fingers on the pad. |
666 int finger_count_; | 670 int finger_count_; |
667 }; | 671 }; |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
702 // This value is stored as a bitfield because the number of touch ids varies, | 706 // This value is stored as a bitfield because the number of touch ids varies, |
703 // but we currently don't need more than 32 touches at a time. | 707 // but we currently don't need more than 32 touches at a time. |
704 const unsigned int touch_ids_bitfield_; | 708 const unsigned int touch_ids_bitfield_; |
705 | 709 |
706 DISALLOW_COPY_AND_ASSIGN(GestureEvent); | 710 DISALLOW_COPY_AND_ASSIGN(GestureEvent); |
707 }; | 711 }; |
708 | 712 |
709 } // namespace ui | 713 } // namespace ui |
710 | 714 |
711 #endif // UI_BASE_EVENTS_EVENT_H_ | 715 #endif // UI_BASE_EVENTS_EVENT_H_ |
OLD | NEW |