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

Side by Side Diff: content/browser/renderer_host/web_input_event_aurax11.cc

Issue 8763020: aura: Detect double clicks and set ui::EF_IS_DOUBLE_CLICK appropriately. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | ui/aura/event.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 // Portions based heavily on: 5 // Portions based heavily on:
6 // third_party/WebKit/Source/WebKit/chromium/public/gtk/WebInputEventFactory.cpp 6 // third_party/WebKit/Source/WebKit/chromium/public/gtk/WebInputEventFactory.cpp
7 // 7 //
8 /* 8 /*
9 * Copyright (C) 2006-2011 Google Inc. All rights reserved. 9 * Copyright (C) 2006-2011 Google Inc. All rights reserved.
10 * 10 *
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 webkit_event.modifiers = XStateToWebEventModifiers(native_key_event->state); 308 webkit_event.modifiers = XStateToWebEventModifiers(native_key_event->state);
309 309
310 switch (native_event->type) { 310 switch (native_event->type) {
311 case KeyPress: 311 case KeyPress:
312 webkit_event.type = event->is_char() ? WebKit::WebInputEvent::Char : 312 webkit_event.type = event->is_char() ? WebKit::WebInputEvent::Char :
313 WebKit::WebInputEvent::RawKeyDown; 313 WebKit::WebInputEvent::RawKeyDown;
314 break; 314 break;
315 case KeyRelease: 315 case KeyRelease:
316 webkit_event.type = WebKit::WebInputEvent::KeyUp; 316 webkit_event.type = WebKit::WebInputEvent::KeyUp;
317 break; 317 break;
318 case GenericEvent:
319 // TODO(sadrul): touch!
320 break;
321 default: 318 default:
322 NOTREACHED(); 319 NOTREACHED();
323 } 320 }
324 321
325 if (webkit_event.modifiers & WebKit::WebInputEvent::AltKey) 322 if (webkit_event.modifiers & WebKit::WebInputEvent::AltKey)
326 webkit_event.isSystemKey = true; 323 webkit_event.isSystemKey = true;
327 324
328 webkit_event.windowsKeyCode = XKeyEventToWindowsKeyCode(native_key_event); 325 webkit_event.windowsKeyCode = XKeyEventToWindowsKeyCode(native_key_event);
329 webkit_event.nativeKeyCode = native_key_event->keycode; 326 webkit_event.nativeKeyCode = native_key_event->keycode;
330 327
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 } 409 }
413 410
414 // Update the type of the touch event. 411 // Update the type of the touch event.
415 web_event->type = TouchEventTypeFromEvent(event); 412 web_event->type = TouchEventTypeFromEvent(event);
416 web_event->timeStampSeconds = event->time_stamp().ToDoubleT(); 413 web_event->timeStampSeconds = event->time_stamp().ToDoubleT();
417 414
418 return point; 415 return point;
419 } 416 }
420 417
421 } // namespace content 418 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | ui/aura/event.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698