mirror of
https://github.com/gnustep/libs-gui.git
synced 2025-04-23 02:04:20 +00:00
Minor fix. Move panel instantiation to after lock.
This commit is contained in:
parent
54fc199d73
commit
34cfca2d06
1 changed files with 7 additions and 5 deletions
|
@ -83,14 +83,16 @@ static NSColorSampler *_gs_gui_color_sampler = nil;
|
|||
NSRect contentRect = NSMakeRect(-1024,-1024,0,0);
|
||||
unsigned int style = NSTitledWindowMask | NSClosableWindowMask
|
||||
| NSResizableWindowMask | NSUtilityWindowMask;
|
||||
NSPanel *w = [[NSPanel alloc] initWithContentRect: contentRect
|
||||
styleMask: style
|
||||
backing: NSBackingStoreRetained
|
||||
defer: NO
|
||||
screen: nil];
|
||||
NSPanel *w = nil;
|
||||
NSColor *color = nil;
|
||||
|
||||
[_gs_gui_color_sampler_lock lock];
|
||||
|
||||
w = [[NSPanel alloc] initWithContentRect: contentRect
|
||||
styleMask: style
|
||||
backing: NSBackingStoreRetained
|
||||
defer: NO
|
||||
screen: nil];
|
||||
|
||||
[w setBecomesKeyOnlyIfNeeded: YES];
|
||||
[w makeKeyAndOrderFront: self];
|
||||
|
|
Loading…
Reference in a new issue