diff --git a/src/html/htmlctrl/webkit/webkit.mm b/src/html/htmlctrl/webkit/webkit.mm
index 49ebedf1f3..5af328fa45 100755
--- a/src/html/htmlctrl/webkit/webkit.mm
+++ b/src/html/htmlctrl/webkit/webkit.mm
@@ -219,7 +219,7 @@ static pascal OSStatus wxWebKitCtrlEventHandler( EventHandlerCallRef handler , E
ControlRef controlRef ;
wxWebKitCtrl* thisWindow = (wxWebKitCtrl*) data ;
- wxTopLevelWindowMac* tlw = NULL;
+ wxNonOwnedWindow* tlw = NULL;
if (thisWindow)
tlw = thisWindow->MacGetTopLevelWindow();