2011-03-24 Jon Lee <jonlee@apple.com>

        Reviewed by Darin Adler.

        WebKit2: Tabbing from the last focused field to a non-webpage element leaves the selection in a weird state
        <rdar://problem/8553962>

        * WebProcess/WebPage/WebPage.cpp:
        (WebKit::WebPage::setFocused): When the page loses focus, clear out any selection in the frame

git-svn-id: svn://svn.chromium.org/blink/trunk@81880 bbb929c8-8fbe-4397-9dbb-9b2b20218538
parent adcd899a
2011-03-24 Jon Lee <jonlee@apple.com>
Reviewed by Darin Adler.
WebKit2: Tabbing from the last focused field to a non-webpage element leaves the selection in a weird state
<rdar://problem/8553962>
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::setFocused): When the page loses focus, clear out any selection in the frame
2011-03-24 Brian Weinstein <bweinstein@apple.com>
Rubber-stamped by Sam Weinig.
......
......@@ -1126,6 +1126,8 @@ void WebPage::viewWillEndLiveResize()
void WebPage::setFocused(bool isFocused)
{
if (!isFocused)
m_page->focusController()->focusedOrMainFrame()->selection()->clear();
m_page->focusController()->setFocused(isFocused);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment