Changeset 51832 in webkit
- Timestamp:
- Dec 7, 2009 8:55:46 PM (14 years ago)
- Location:
- trunk/WebKit/chromium
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKit/chromium/ChangeLog
r51827 r51832 1 2009-12-07 Zhe Su <suzhe@chromium.org> 2 3 Reviewed by Darin Fisher. 4 5 [Chromium] accesskey is not supported on Chromium Mac. 6 https://bugs.webkit.org/show_bug.cgi?id=32213 7 8 This change fixes (partially) the accesskey issue by decoupling the 9 code for handling accesskeys and system keys. Because on Mac, 10 the modifiers of accesskeys are ctrl+alt, which are not marked as 11 system keys. 12 In order to fully fix this issue, some changes in Chromium code is 13 also required. 14 15 * src/WebViewImpl.cpp: 16 (WebKit::WebViewImpl::keyEvent): 17 (WebKit::WebViewImpl::charEvent): 18 1 19 2009-12-07 Evan Martin <evan@chromium.org> 2 20 -
trunk/WebKit/chromium/src/WebViewImpl.cpp
r51827 r51832 465 465 466 466 if (handler->keyEvent(evt)) { 467 if (WebInputEvent::RawKeyDown == event.type && !evt.isSystemKey())467 if (WebInputEvent::RawKeyDown == event.type) 468 468 m_suppressNextKeypressEvent = true; 469 469 return true; … … 530 530 // keyPress(char) event and a keyUp event. We reset this flag here as it 531 531 // only applies to the current keyPress event. 532 if (m_suppressNextKeypressEvent) { 533 m_suppressNextKeypressEvent = false; 534 return true; 535 } 532 bool suppress = m_suppressNextKeypressEvent; 533 m_suppressNextKeypressEvent = false; 536 534 537 535 Frame* frame = focusedWebCoreFrame(); 538 536 if (!frame) 539 return false;537 return suppress; 540 538 541 539 EventHandler* handler = frame->eventHandler(); 542 540 if (!handler) 543 return keyEventDefault(event);541 return suppress || keyEventDefault(event); 544 542 545 543 PlatformKeyboardEventBuilder evt(event); 546 544 if (!evt.isCharacterKey()) 545 return true; 546 547 // Accesskeys are triggered by char events and can't be suppressed. 548 if (handler->handleAccessKey(evt)) 547 549 return true; 548 550 … … 552 554 // events. 553 555 if (evt.isSystemKey()) 554 return handler->handleAccessKey(evt);555 556 if (! handler->keyEvent(evt))556 return false; 557 558 if (!suppress && !handler->keyEvent(evt)) 557 559 return keyEventDefault(event); 558 560
Note: See TracChangeset
for help on using the changeset viewer.