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

Side by Side Diff: Source/web/WebViewImpl.cpp

Issue 663523002: Adding support for DOM3 KeyboardEvents Code in KeyboardEvents (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Updated to use domCode instead of native domCode Created 5 years, 11 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 Google 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 945 matching lines...) Expand 10 before | Expand all | Expand 10 after
956 webFrame->client()->forwardInputEvent(&event); 956 webFrame->client()->forwardInputEvent(&event);
957 return true; 957 return true;
958 } 958 }
959 959
960 if (!focusedFrame || !focusedFrame->isLocalFrame()) 960 if (!focusedFrame || !focusedFrame->isLocalFrame())
961 return false; 961 return false;
962 962
963 LocalFrame* frame = toLocalFrame(focusedFrame.get()); 963 LocalFrame* frame = toLocalFrame(focusedFrame.get());
964 964
965 PlatformKeyboardEventBuilder evt(event); 965 PlatformKeyboardEventBuilder evt(event);
966 evt.setKeyboardEventDOMCodeValue(m_client->keyboardDOMCodeValue(evt.domCode( )));
Wez 2015/01/08 01:14:48 It reads very oddly to be passing evt.domCode() in
Habib Virji 2015/01/12 15:34:17 I have deferred it, please have a look. It now hap
Wez 2015/01/17 02:35:10 SGTM - please check w/ e.g. rbyers@ that the frame
966 967
967 if (frame->eventHandler().keyEvent(evt)) { 968 if (frame->eventHandler().keyEvent(evt)) {
968 if (WebInputEvent::RawKeyDown == event.type) { 969 if (WebInputEvent::RawKeyDown == event.type) {
969 // Suppress the next keypress event unless the focused node is a plu g-in node. 970 // Suppress the next keypress event unless the focused node is a plu g-in node.
970 // (Flash needs these keypress events to handle non-US keyboards.) 971 // (Flash needs these keypress events to handle non-US keyboards.)
971 Element* element = focusedElement(); 972 Element* element = focusedElement();
972 if (!element || !element->renderer() || !element->renderer()->isEmbe ddedObject()) 973 if (!element || !element->renderer() || !element->renderer()->isEmbe ddedObject())
973 m_suppressNextKeypressEvent = true; 974 m_suppressNextKeypressEvent = true;
974 } 975 }
975 return true; 976 return true;
(...skipping 3526 matching lines...) Expand 10 before | Expand all | Expand 10 after
4502 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width 4503 return mainFrameImpl()->frameView()->layoutSize().width() == m_size.width
4503 || (constraints.minimumScale == constraints.maximumScale && constraints. minimumScale != -1); 4504 || (constraints.minimumScale == constraints.maximumScale && constraints. minimumScale != -1);
4504 } 4505 }
4505 4506
4506 void WebViewImpl::forceNextWebGLContextCreationToFail() 4507 void WebViewImpl::forceNextWebGLContextCreationToFail()
4507 { 4508 {
4508 WebGLRenderingContext::forceNextWebGLContextCreationToFail(); 4509 WebGLRenderingContext::forceNextWebGLContextCreationToFail();
4509 } 4510 }
4510 4511
4511 } // namespace blink 4512 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698