| 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_EVENTS_EVENT_H_ | 5 #ifndef UI_EVENTS_EVENT_H_ |
| 6 #define UI_EVENTS_EVENT_H_ | 6 #define UI_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 617 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 628 // This is useful in the multi-monitor setup where it needs to be scaled | 628 // This is useful in the multi-monitor setup where it needs to be scaled |
| 629 // to provide a consistent user experience. | 629 // to provide a consistent user experience. |
| 630 void Scale(const float factor); | 630 void Scale(const float factor); |
| 631 | 631 |
| 632 float x_offset() const { return x_offset_; } | 632 float x_offset() const { return x_offset_; } |
| 633 float y_offset() const { return y_offset_; } | 633 float y_offset() const { return y_offset_; } |
| 634 float x_offset_ordinal() const { return x_offset_ordinal_; } | 634 float x_offset_ordinal() const { return x_offset_ordinal_; } |
| 635 float y_offset_ordinal() const { return y_offset_ordinal_; } | 635 float y_offset_ordinal() const { return y_offset_ordinal_; } |
| 636 int finger_count() const { return finger_count_; } | 636 int finger_count() const { return finger_count_; } |
| 637 | 637 |
| 638 // Overridden from LocatedEvent. | |
| 639 virtual void UpdateForRootTransform( | |
| 640 const gfx::Transform& inverted_root_transform) OVERRIDE; | |
| 641 | |
| 642 private: | 638 private: |
| 643 // Potential accelerated offsets. | 639 // Potential accelerated offsets. |
| 644 float x_offset_; | 640 float x_offset_; |
| 645 float y_offset_; | 641 float y_offset_; |
| 646 // Unaccelerated offsets. | 642 // Unaccelerated offsets. |
| 647 float x_offset_ordinal_; | 643 float x_offset_ordinal_; |
| 648 float y_offset_ordinal_; | 644 float y_offset_ordinal_; |
| 649 // Number of fingers on the pad. | 645 // Number of fingers on the pad. |
| 650 int finger_count_; | 646 int finger_count_; |
| 651 }; | 647 }; |
| (...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 688 // The set of indices of ones in the binary representation of | 684 // The set of indices of ones in the binary representation of |
| 689 // touch_ids_bitfield_ is the set of touch_ids associate with this gesture. | 685 // touch_ids_bitfield_ is the set of touch_ids associate with this gesture. |
| 690 // This value is stored as a bitfield because the number of touch ids varies, | 686 // This value is stored as a bitfield because the number of touch ids varies, |
| 691 // but we currently don't need more than 32 touches at a time. | 687 // but we currently don't need more than 32 touches at a time. |
| 692 const unsigned int touch_ids_bitfield_; | 688 const unsigned int touch_ids_bitfield_; |
| 693 }; | 689 }; |
| 694 | 690 |
| 695 } // namespace ui | 691 } // namespace ui |
| 696 | 692 |
| 697 #endif // UI_EVENTS_EVENT_H_ | 693 #endif // UI_EVENTS_EVENT_H_ |
| OLD | NEW |