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

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

Issue 1375703002: Fire accessibility hover events when the touch exploration flag is set. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use asserts instead of checks in test Created 5 years, 2 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 2068 matching lines...) Expand 10 before | Expand all | Expand 10 after
2079 return true; 2079 return true;
2080 2080
2081 if (m_devToolsEmulator->handleInputEvent(inputEvent)) 2081 if (m_devToolsEmulator->handleInputEvent(inputEvent))
2082 return true; 2082 return true;
2083 2083
2084 if (InspectorOverlay* overlay = inspectorOverlay()) { 2084 if (InspectorOverlay* overlay = inspectorOverlay()) {
2085 if (overlay->handleInputEvent(inputEvent)) 2085 if (overlay->handleInputEvent(inputEvent))
2086 return true; 2086 return true;
2087 } 2087 }
2088 2088
2089 if (inputEvent.modifiers & WebInputEvent::IsTouchAccessibility
2090 && WebInputEvent::isMouseEventType(inputEvent.type)) {
2091 PlatformMouseEventBuilder pme(mainFrameImpl()->frameView(), static_cast< const WebMouseEvent&>(inputEvent));
2092
2093 // Find the right target frame. See issue 1186900.
2094 HitTestResult result = hitTestResultForRootFramePos(pme.position());
2095 Frame* targetFrame;
2096 if (result.innerNodeOrImageMapImage())
2097 targetFrame = result.innerNodeOrImageMapImage()->document().frame();
2098 else
2099 targetFrame = m_page->focusController().focusedOrMainFrame();
2100
2101 if (targetFrame->isLocalFrame()) {
2102 LocalFrame* targetLocalFrame = toLocalFrame(targetFrame);
2103 Document* document = targetLocalFrame->document();
2104 if (document) {
2105 AXObjectCache* cache = document->existingAXObjectCache();
2106 if (cache)
2107 cache->onTouchAccessibilityHover(pme.position());
2108 }
2109 }
2110 }
2111
2089 // Report the event to be NOT processed by WebKit, so that the browser can h andle it appropriately. 2112 // Report the event to be NOT processed by WebKit, so that the browser can h andle it appropriately.
2090 if (m_ignoreInputEvents) 2113 if (m_ignoreInputEvents)
2091 return false; 2114 return false;
2092 2115
2093 TemporaryChange<const WebInputEvent*> currentEventChange(m_currentInputEvent , &inputEvent); 2116 TemporaryChange<const WebInputEvent*> currentEventChange(m_currentInputEvent , &inputEvent);
2094 UIEventWithKeyState::clearNewTabModifierSetFromIsolatedWorld(); 2117 UIEventWithKeyState::clearNewTabModifierSetFromIsolatedWorld();
2095 2118
2096 if (isPointerLocked() && WebInputEvent::isMouseEventType(inputEvent.type)) { 2119 if (isPointerLocked() && WebInputEvent::isMouseEventType(inputEvent.type)) {
2097 pointerLockMouseEvent(inputEvent); 2120 pointerLockMouseEvent(inputEvent);
2098 return true; 2121 return true;
(...skipping 2330 matching lines...) Expand 10 before | Expand all | Expand 10 after
4429 if (m_pageColorOverlay) 4452 if (m_pageColorOverlay)
4430 m_pageColorOverlay->update(); 4453 m_pageColorOverlay->update();
4431 if (InspectorOverlay* overlay = inspectorOverlay()) { 4454 if (InspectorOverlay* overlay = inspectorOverlay()) {
4432 PageOverlay* inspectorPageOverlay = overlay->pageOverlay(); 4455 PageOverlay* inspectorPageOverlay = overlay->pageOverlay();
4433 if (inspectorPageOverlay) 4456 if (inspectorPageOverlay)
4434 inspectorPageOverlay->update(); 4457 inspectorPageOverlay->update();
4435 } 4458 }
4436 } 4459 }
4437 4460
4438 } // namespace blink 4461 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/web/AssertMatchingEnums.cpp ('k') | third_party/WebKit/public/web/WebAXEnums.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698