Source/WebCore: WK2: Cannot set focus on an element when focus is outside of WKView
authorcfleizach@apple.com <cfleizach@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 8 Mar 2011 20:04:42 +0000 (20:04 +0000)
committercfleizach@apple.com <cfleizach@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 8 Mar 2011 20:04:42 +0000 (20:04 +0000)
commit8ef4984ae3ccc48031b631c058e38eabe9878bb6
tree0f3331ec57ca9ba53e5425e7691ca91a229feba8
parent223a6a6c0445b8e17da6caf96822a8531d2bbf0a
Source/WebCore: WK2: Cannot set focus on an element when focus is outside of WKView
https://bugs.webkit.org/show_bug.cgi?id=55281

Reviewed by Sam Weinig.

In WK2, focus cannot be set from the WebProcess side because there's no platformWidget().
Instead, the focus/unfocus messages need to be sent to the UIProcess side.

* platform/mac/WidgetMac.mm:
(WebCore::Widget::setFocus):

Source/WebKit2: WK2: Cannot set focus on an element when focus is outside of WKView
https://bugs.webkit.org/show_bug.cgi?id=55281

Reviewed by Sam Weinig.

* UIProcess/API/mac/PageClientImpl.h:
* UIProcess/API/mac/PageClientImpl.mm:
(WebKit::PageClientImpl::setFocus):
* UIProcess/API/qt/qwkpage_p.h:
(QWKPagePrivate::setFocus):
* UIProcess/PageClient.h:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::setFocus):
* UIProcess/WebPageProxy.h:
* UIProcess/WebPageProxy.messages.in:
* UIProcess/win/WebView.h:
(WebKit::WebView::setFocus):
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::focus):
(WebKit::WebChromeClient::unfocus):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@80578 268f45cc-cd09-0410-ab3c-d52691b4dbfc
12 files changed:
Source/WebCore/ChangeLog
Source/WebCore/platform/mac/WidgetMac.mm
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/mac/PageClientImpl.h
Source/WebKit2/UIProcess/API/mac/PageClientImpl.mm
Source/WebKit2/UIProcess/API/qt/qwkpage_p.h
Source/WebKit2/UIProcess/PageClient.h
Source/WebKit2/UIProcess/WebPageProxy.cpp
Source/WebKit2/UIProcess/WebPageProxy.h
Source/WebKit2/UIProcess/WebPageProxy.messages.in
Source/WebKit2/UIProcess/win/WebView.h
Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp