From ca897b518463b85fba8ba55e66c372a8604fec2e Mon Sep 17 00:00:00 2001 From: Steve Lamerton Date: Sat, 6 Aug 2011 13:55:15 +0000 Subject: [PATCH] Remove old WXCOCOA code. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/SOC2011_WEBVIEW@68573 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/osx/webview_webkit.mm | 43 +-------------------------------------- 1 file changed, 1 insertion(+), 42 deletions(-) diff --git a/src/osx/webview_webkit.mm b/src/osx/webview_webkit.mm index 2285278f6a..ac2838319c 100644 --- a/src/osx/webview_webkit.mm +++ b/src/osx/webview_webkit.mm @@ -24,16 +24,12 @@ #include "wx/wx.h" #endif -#ifdef __WXCOCOA__ -#include "wx/cocoa/autorelease.h" -#else #include "wx/osx/private.h" #include "wx/cocoa/string.h" #include #include #include -#endif #include @@ -334,43 +330,6 @@ bool wxWebViewWebKit::Create(wxWindow *parent, { m_busy = false; - //still needed for wxCocoa?? -/* - int width, height; - wxSize sizeInstance; - if (size.x == wxDefaultCoord || size.y == wxDefaultCoord) - { - m_parent->GetClientSize(&width, &height); - sizeInstance.x = width; - sizeInstance.y = height; - } - else - { - sizeInstance.x = size.x; - sizeInstance.y = size.y; - } -*/ - // now create and attach WebKit view... -#ifdef __WXCOCOA__ - wxControl::Create(parent, m_windowID, pos, sizeInstance, style, name); - SetSize(pos.x, pos.y, sizeInstance.x, sizeInstance.y); - - wxTopLevelWindowCocoa *topWin = wxDynamicCast(this, wxTopLevelWindowCocoa); - NSWindow* nsWin = topWin->GetNSWindow(); - NSRect rect; - rect.origin.x = pos.x; - rect.origin.y = pos.y; - rect.size.width = sizeInstance.x; - rect.size.height = sizeInstance.y; - m_webView = (WebView*)[[WebView alloc] initWithFrame:rect - frameName:@"webkitFrame" - groupName:@"webkitGroup"]; - SetNSView(m_webView); - [m_cocoaNSView release]; - - if(m_parent) m_parent->CocoaAddChild(this); - SetInitialFrameRect(pos,sizeInstance); -#else wxControl::Create(parent, winID, pos, size, style, wxDefaultValidator, name); #if wxOSX_USE_CARBON @@ -405,7 +364,7 @@ bool wxWebViewWebKit::Create(wxWindow *parent, #endif [m_webView setHidden:false]; -#endif + // Register event listener interfaces MyFrameLoadMonitor* myFrameLoadMonitor = -- 2.45.2