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

Side by Side Diff: ppapi/c/pp_input_event.h

Issue 7308010: Formatting changes (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 4 months 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 | Annotate | Revision Log
OLDNEW
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 5
6 /* From pp_input_event.idl modified Wed Jul 20 11:21:44 2011. */ 6 /* From pp_input_event.idl modified Thu Aug 11 13:11:24 2011. */
7 7
8 #ifndef PPAPI_C_PP_INPUT_EVENT_H_ 8 #ifndef PPAPI_C_PP_INPUT_EVENT_H_
9 #define PPAPI_C_PP_INPUT_EVENT_H_ 9 #define PPAPI_C_PP_INPUT_EVENT_H_
10 10
11 #include "ppapi/c/pp_bool.h" 11 #include "ppapi/c/pp_bool.h"
12 #include "ppapi/c/pp_macros.h" 12 #include "ppapi/c/pp_macros.h"
13 #include "ppapi/c/pp_stdint.h" 13 #include "ppapi/c/pp_stdint.h"
14 #include "ppapi/c/ppb_input_event.h" 14 #include "ppapi/c/ppb_input_event.h"
15 15
16 /** 16 /**
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
130 * The <code>PP_InputEvent_Wheel</code> struct represents all mouse wheel 130 * The <code>PP_InputEvent_Wheel</code> struct represents all mouse wheel
131 * events. 131 * events.
132 */ 132 */
133 struct PP_InputEvent_Wheel { 133 struct PP_InputEvent_Wheel {
134 /** 134 /**
135 * This value represents a combination of the <code>EVENT_MODIFIER</code> 135 * This value represents a combination of the <code>EVENT_MODIFIER</code>
136 * flags. 136 * flags.
137 */ 137 */
138 uint32_t modifier; 138 uint32_t modifier;
139 /** 139 /**
140 * Indicates the amount vertically and horizontally the user has requested 140 * The mouse wheel's horizontal scroll amount. A scroll to the right
141 * to scroll by with their mouse wheel. A scroll down or to the right (where 141 * (where the content moves left) is represented as positive values,
142 * the content moves up or left) is represented as positive values, and 142 * and a scroll to the left (where the content moves right) is
143 * a scroll up or to the left (where the content moves down or right) is
144 * represented as negative values. 143 * represented as negative values.
145 * 144 *
146 * The units are either in pixels (when scroll_by_page is false) or pages 145 * The units are either in pixels (when scroll_by_page is false) or pages
147 * (when scroll_by_page is true). For example, delta_y = -3 means scroll up 3 146 * (when scroll_by_page is true). For example, delta_y = -3 means scroll up 3
148 * pixels when scroll_by_page is false, and scroll up 3 pages when 147 * pixels when scroll_by_page is false, and scroll up 3 pages when
149 * scroll_by_page is true. 148 * scroll_by_page is true.
150 * 149 *
151 * This amount is system dependent and will take into account the user's 150 * This amount is system dependent and will take into account the user's
152 * preferred scroll sensitivity and potentially also nonlinear acceleration 151 * preferred scroll sensitivity and potentially also nonlinear acceleration
153 * based on the speed of the scrolling. 152 * based on the speed of the scrolling.
154 * 153 *
155 * Devices will be of varying resolution. Some mice with large detents will 154 * Devices will be of varying resolution. Some mice with large detents will
156 * only generate integer scroll amounts. But fractional values are also 155 * only generate integer scroll amounts. But fractional values are also
157 * possible, for example, on some trackpads and newer mice that don't have 156 * possible, for example, on some trackpads and newer mice that don't have
158 * "clicks". 157 * "clicks".
159 */ 158 */
160 float delta_x; 159 float delta_x;
161 /** This value represents */ 160 /**
161 * The mouse wheel's vertical scroll amount. A scroll to the right
162 * (where the content moves up) is represented as positive values,
163 * and a scroll to the left (where the content moves right) is
164 * represented as negative values.
165 *
166 * The units are either in pixels (when scroll_by_page is false) or pages
167 * (when scroll_by_page is true). For example, delta_y = -3 means scroll up 3
168 * pixels when scroll_by_page is false, and scroll up 3 pages when
169 * scroll_by_page is true.
170 *
171 * This amount is system dependent and will take into account the user's
172 * preferred scroll sensitivity and potentially also nonlinear acceleration
173 * based on the speed of the scrolling.
174 *
175 * Devices will be of varying resolution. Some mice with large detents will
176 * only generate integer scroll amounts. But fractional values are also
177 * possible, for example, on some trackpads and newer mice that don't have
178 * "clicks".
179 */
162 float delta_y; 180 float delta_y;
163 /** 181 /**
164 * The number of "clicks" of the scroll wheel that have produced the 182 * The number of "clicks" of the scroll wheel that have produced the
165 * event. The value may have system-specific acceleration applied to it, 183 * event. The value may have system-specific acceleration applied to it,
166 * depending on the device. The positive and negative meanings are the same 184 * depending on the device. The positive and negative meanings are the same
167 * as for <code>delta_x</code> and <code>delta_y</code>. 185 * as for <code>delta_x</code> and <code>delta_y</code>.
168 * 186 *
169 * If you are scrolling, you probably want to use the delta values above. 187 * If you are scrolling, you probably want to use the delta values above.
170 * These tick events can be useful if you aren't doing actual scrolling and 188 * These tick events can be useful if you aren't doing actual scrolling and
171 * don't want or pixel values. An example may be cycling between different 189 * don't want or pixel values. An example may be cycling between different
(...skipping 16 matching lines...) Expand all
188 */ 206 */
189 PP_Bool scroll_by_page; 207 PP_Bool scroll_by_page;
190 }; 208 };
191 PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_InputEvent_Wheel, 24); 209 PP_COMPILE_ASSERT_STRUCT_SIZE_IN_BYTES(PP_InputEvent_Wheel, 24);
192 /** 210 /**
193 * @} 211 * @}
194 */ 212 */
195 213
196 #endif /* PPAPI_C_PP_INPUT_EVENT_H_ */ 214 #endif /* PPAPI_C_PP_INPUT_EVENT_H_ */
197 215
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698