X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e82b00a76d14e0c8717cce0ed7523047e6359352..15f37147958a61adb54e0d64c82dc7b93c1f1cbe:/src/cocoa/dialog.mm diff --git a/src/cocoa/dialog.mm b/src/cocoa/dialog.mm index f8d3faeafb..1f412b0a33 100644 --- a/src/cocoa/dialog.mm +++ b/src/cocoa/dialog.mm @@ -57,13 +57,9 @@ bool wxDialog::Create(wxWindow *parent, wxWindowID winid, if (parent) parent->AddChild(this); - NSRect cocoaRect = NSMakeRect(300,300,200,200); + unsigned int cocoaStyle = NSWindowStyleForWxStyle(style); - unsigned int cocoaStyle = 0; - cocoaStyle |= NSTitledWindowMask; - cocoaStyle |= NSClosableWindowMask; - cocoaStyle |= NSMiniaturizableWindowMask; - cocoaStyle |= NSResizableWindowMask; + NSRect cocoaRect = MakeInitialNSWindowContentRect(pos,size,cocoaStyle); m_cocoaNSWindow = NULL; SetNSPanel([[NSPanel alloc] initWithContentRect:cocoaRect styleMask:cocoaStyle backing:NSBackingStoreBuffered defer:NO]);