Changeset 64155 in webkit
- Timestamp:
- Jul 27, 2010 2:06:35 PM (14 years ago)
- Location:
- trunk/WebKit2
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebKit2/ChangeLog
r64154 r64155 1 2010-07-27 Adam Roben <aroben@apple.com> 2 3 Fix PageClient ownership in WebPageProxy 4 5 WKView now owns the PageClient, similar to how things work on Windows 6 (where the WebView is the PageClient). 7 8 Fixes <http://webkit.org/b/40185> WebPageProxy should keep a weak 9 reference to the PageClient 10 11 Reviewed by Anders Carlsson. 12 13 * UIProcess/API/mac/WKView.mm: 14 (-[WKView initWithFrame:pageNamespaceRef:]): Store the PageClientImpl 15 on our WKViewData object and pass it to the WebPageProxy. 16 17 * UIProcess/WebPageProxy.cpp: 18 (WebKit::WebPageProxy::setPageClient): 19 * UIProcess/WebPageProxy.h: 20 Removed Mac-specific code that put the PageClient in an OwnPtr. We now 21 store it in a bare pointer just like on Windows. 22 1 23 2010-07-27 Anders Carlsson <andersca@apple.com> 2 24 -
trunk/WebKit2/UIProcess/API/mac/WKView.mm
r63843 r64155 50 50 @interface WKViewData : NSObject { 51 51 @public 52 OwnPtr<PageClientImpl> _pageClient; 52 53 RefPtr<WebPageProxy> _page; 53 54 … … 85 86 _data = [[WKViewData alloc] init]; 86 87 88 _data->_pageClient.set(new PageClientImpl(self)); 87 89 _data->_page = toWK(pageNamespaceRef)->createWebPage(); 88 _data->_page->setPageClient( new PageClientImpl(self));90 _data->_page->setPageClient(_data->_pageClient.get()); 89 91 _data->_page->initializeWebPage(IntSize(frame.size), new ChunkedUpdateDrawingAreaProxy(self)); 90 92 _data->_page->setIsInWindow([self window]); -
trunk/WebKit2/UIProcess/WebPageProxy.cpp
r64132 r64155 98 98 void WebPageProxy::setPageClient(PageClient* pageClient) 99 99 { 100 #if PLATFORM(WIN)101 100 m_pageClient = pageClient; 102 #else103 m_pageClient.set(pageClient);104 #endif105 101 } 106 102 -
trunk/WebKit2/UIProcess/WebPageProxy.h
r64065 r64155 211 211 #endif 212 212 213 #if PLATFORM(WIN)214 213 PageClient* m_pageClient; 215 #else216 // FIXME: This should not be an OwnPtr to the PageClient. We need to find a better way to clean up m_pageClient on mac.217 // http://bugs.webkit.org/show_bug.cgi?id=40185218 OwnPtr<PageClient> m_pageClient;219 #endif220 214 WebLoaderClient m_loaderClient; 221 215 WebPolicyClient m_policyClient;
Note: See TracChangeset
for help on using the changeset viewer.