Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(23)

Side by Side Diff: Source/platform/PlatformMouseEvent.h

Issue 765203002: Remove PlatformMouseEvent::m_modifierFlags member. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « Source/core/page/EventHandler.cpp ('k') | Source/web/ChromeClientImpl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2006, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2005, 2006, 2009 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 30 matching lines...) Expand all
41 RealOrIndistinguishable, 41 RealOrIndistinguishable,
42 // Mouse events derived from touch input 42 // Mouse events derived from touch input
43 FromTouch, 43 FromTouch,
44 }; 44 };
45 45
46 PlatformMouseEvent() 46 PlatformMouseEvent()
47 : PlatformEvent(PlatformEvent::MouseMoved) 47 : PlatformEvent(PlatformEvent::MouseMoved)
48 , m_button(NoButton) 48 , m_button(NoButton)
49 , m_clickCount(0) 49 , m_clickCount(0)
50 , m_synthesized(RealOrIndistinguishable) 50 , m_synthesized(RealOrIndistinguishable)
51 , m_modifierFlags(0)
52 { 51 {
53 } 52 }
54 53
55 PlatformMouseEvent(const IntPoint& position, const IntPoint& globalPosition, MouseButton button, PlatformEvent::Type type, int clickCount, Modifiers modifie rs, double timestamp) 54 PlatformMouseEvent(const IntPoint& position, const IntPoint& globalPosition, MouseButton button, PlatformEvent::Type type, int clickCount, Modifiers modifie rs, double timestamp)
56 : PlatformEvent(type, modifiers, timestamp) 55 : PlatformEvent(type, modifiers, timestamp)
57 , m_position(position) 56 , m_position(position)
58 , m_globalPosition(globalPosition) 57 , m_globalPosition(globalPosition)
59 , m_button(button) 58 , m_button(button)
60 , m_clickCount(clickCount) 59 , m_clickCount(clickCount)
61 , m_synthesized(RealOrIndistinguishable) 60 , m_synthesized(RealOrIndistinguishable)
62 , m_modifierFlags(0)
63 { 61 {
64 } 62 }
65 63
66 PlatformMouseEvent(const IntPoint& position, const IntPoint& globalPosition, MouseButton button, PlatformEvent::Type type, int clickCount, Modifiers modifie rs, SyntheticEventType synthesized, double timestamp) 64 PlatformMouseEvent(const IntPoint& position, const IntPoint& globalPosition, MouseButton button, PlatformEvent::Type type, int clickCount, Modifiers modifie rs, SyntheticEventType synthesized, double timestamp)
67 : PlatformEvent(type, modifiers, timestamp) 65 : PlatformEvent(type, modifiers, timestamp)
68 , m_position(position) 66 , m_position(position)
69 , m_globalPosition(globalPosition) 67 , m_globalPosition(globalPosition)
70 , m_button(button) 68 , m_button(button)
71 , m_clickCount(clickCount) 69 , m_clickCount(clickCount)
72 , m_synthesized(synthesized) 70 , m_synthesized(synthesized)
73 , m_modifierFlags(0)
74 { 71 {
75 } 72 }
76 73
77 PlatformMouseEvent(const IntPoint& position, const IntPoint& globalPosition, MouseButton button, PlatformEvent::Type type, int clickCount, bool shiftKey, bo ol ctrlKey, bool altKey, bool metaKey, SyntheticEventType synthesized, double ti mestamp) 74 PlatformMouseEvent(const IntPoint& position, const IntPoint& globalPosition, MouseButton button, PlatformEvent::Type type, int clickCount, bool shiftKey, bo ol ctrlKey, bool altKey, bool metaKey, SyntheticEventType synthesized, double ti mestamp)
78 : PlatformEvent(type, shiftKey, ctrlKey, altKey, metaKey, timestamp) 75 : PlatformEvent(type, shiftKey, ctrlKey, altKey, metaKey, timestamp)
79 , m_position(position) 76 , m_position(position)
80 , m_globalPosition(globalPosition) 77 , m_globalPosition(globalPosition)
81 , m_button(button) 78 , m_button(button)
82 , m_clickCount(clickCount) 79 , m_clickCount(clickCount)
83 , m_synthesized(synthesized) 80 , m_synthesized(synthesized)
84 , m_modifierFlags(0)
85 { 81 {
86 } 82 }
87 83
88 const IntPoint& position() const { return m_position; } 84 const IntPoint& position() const { return m_position; }
89 const IntPoint& globalPosition() const { return m_globalPosition; } 85 const IntPoint& globalPosition() const { return m_globalPosition; }
90 const IntPoint& movementDelta() const { return m_movementDelta; } 86 const IntPoint& movementDelta() const { return m_movementDelta; }
91 87
92 MouseButton button() const { return m_button; } 88 MouseButton button() const { return m_button; }
93 int clickCount() const { return m_clickCount; } 89 int clickCount() const { return m_clickCount; }
94 unsigned modifierFlags() const { return m_modifierFlags; }
95 bool fromTouch() const { return m_synthesized == FromTouch; } 90 bool fromTouch() const { return m_synthesized == FromTouch; }
96 SyntheticEventType syntheticEventType() const { return m_synthesized; } 91 SyntheticEventType syntheticEventType() const { return m_synthesized; }
97 92
98 protected: 93 protected:
99 IntPoint m_position; 94 IntPoint m_position;
100 IntPoint m_globalPosition; 95 IntPoint m_globalPosition;
101 IntPoint m_movementDelta; 96 IntPoint m_movementDelta;
102 MouseButton m_button; 97 MouseButton m_button;
103 int m_clickCount; 98 int m_clickCount;
104 SyntheticEventType m_synthesized; 99 SyntheticEventType m_synthesized;
105 unsigned m_modifierFlags;
106 }; 100 };
107 101
108 } // namespace blink 102 } // namespace blink
109 103
110 #endif // PlatformMouseEvent_h 104 #endif // PlatformMouseEvent_h
OLDNEW
« no previous file with comments | « Source/core/page/EventHandler.cpp ('k') | Source/web/ChromeClientImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698