+NSRect wxTopLevelWindowCocoa::MakeInitialNSWindowContentRect(const wxPoint& pos, const wxSize& size, unsigned int cocoaStyleMask)
+{
+ // Arbitrarily use (100,100) as the origin when default coords are given.
+ wxCoord x = pos.x!=wxDefaultCoord ? pos.x : 100;
+ wxCoord y = pos.y!=wxDefaultCoord ? pos.y : 100;
+
+ wxCoord w = WidthDefault(size.x);
+ wxCoord h = HeightDefault(size.y);
+
+ NSPoint cocoaOrigin = OriginInCocoaScreenCoordinatesForRectInWxDisplayCoordinates(x,y,w,h,true);
+
+ return [NSWindow
+ contentRectForFrameRect:NSMakeRect(cocoaOrigin.x,cocoaOrigin.y,w,h)
+ styleMask:cocoaStyleMask];
+
+}
+