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

Side by Side Diff: third_party/WebKit/Source/core/input/EventHandler.cpp

Issue 1454363002: Close tooltip for |title| attribute on any keyboard event. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed. 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserv ed.
3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org) 3 * Copyright (C) 2006 Alexey Proskuryakov (ap@webkit.org)
4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies) 4 * Copyright (C) 2012 Digia Plc. and/or its subsidiary(-ies)
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 3133 matching lines...) Expand 10 before | Expand all | Expand 10 after
3144 Element* elem = m_frame->document()->getElementByAccessKey(key.lower()); 3144 Element* elem = m_frame->document()->getElementByAccessKey(key.lower());
3145 if (!elem) 3145 if (!elem)
3146 return false; 3146 return false;
3147 elem->accessKeyAction(false); 3147 elem->accessKeyAction(false);
3148 return true; 3148 return true;
3149 } 3149 }
3150 3150
3151 bool EventHandler::keyEvent(const PlatformKeyboardEvent& initialKeyEvent) 3151 bool EventHandler::keyEvent(const PlatformKeyboardEvent& initialKeyEvent)
3152 { 3152 {
3153 RefPtrWillBeRawPtr<FrameView> protector(m_frame->view()); 3153 RefPtrWillBeRawPtr<FrameView> protector(m_frame->view());
3154 m_frame->chromeClient().setToolTip(String(), LTR);
3154 3155
3155 if (initialKeyEvent.windowsVirtualKeyCode() == VK_CAPITAL) 3156 if (initialKeyEvent.windowsVirtualKeyCode() == VK_CAPITAL)
3156 capsLockStateMayHaveChanged(); 3157 capsLockStateMayHaveChanged();
3157 3158
3158 #if OS(WIN) 3159 #if OS(WIN)
3159 if (panScrollInProgress()) { 3160 if (panScrollInProgress()) {
3160 // If a key is pressed while the panScroll is in progress then we want t o stop 3161 // If a key is pressed while the panScroll is in progress then we want t o stop
3161 if (initialKeyEvent.type() == PlatformEvent::KeyDown || initialKeyEvent. type() == PlatformEvent::RawKeyDown) 3162 if (initialKeyEvent.type() == PlatformEvent::KeyDown || initialKeyEvent. type() == PlatformEvent::RawKeyDown)
3162 stopAutoscroll(); 3163 stopAutoscroll();
3163 3164
(...skipping 923 matching lines...) Expand 10 before | Expand all | Expand 10 after
4087 PlatformEvent::Modifiers EventHandler::accessKeyModifiers() 4088 PlatformEvent::Modifiers EventHandler::accessKeyModifiers()
4088 { 4089 {
4089 #if OS(MACOSX) 4090 #if OS(MACOSX)
4090 return static_cast<PlatformEvent::Modifiers>(PlatformEvent::CtrlKey | Platfo rmEvent::AltKey); 4091 return static_cast<PlatformEvent::Modifiers>(PlatformEvent::CtrlKey | Platfo rmEvent::AltKey);
4091 #else 4092 #else
4092 return PlatformEvent::AltKey; 4093 return PlatformEvent::AltKey;
4093 #endif 4094 #endif
4094 } 4095 }
4095 4096
4096 } // namespace blink 4097 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698