summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2011-11-14 17:10:28 +0000
committerManolo Gouy <Manolo>2011-11-14 17:10:28 +0000
commit12a0cb308ec838972c06b15c269cbb74b2b22a23 (patch)
tree4a9cfc08391454ba25491618049561bf9709948f /src
parent74720fd2055a0ac599d7ad3c6c46d98bd38cf007 (diff)
Fix STR #2769: Mac OS crash during creation of non-modal window on secondary screen
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9177 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
-rw-r--r--src/Fl_cocoa.mm8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm
index cad2081ee..df07d9dae 100644
--- a/src/Fl_cocoa.mm
+++ b/src/Fl_cocoa.mm
@@ -2067,6 +2067,10 @@ void Fl_X::make(Fl_Window* w)
[cw setHasShadow:YES];
[cw setAcceptsMouseMovedEvents:YES];
x->xid = cw;
+ x->w = w; w->i = x;
+ x->wait_for_expose = 1;
+ x->next = Fl_X::first;
+ Fl_X::first = x;
FLView *myview = [[FLView alloc] init];
[cw setContentView:myview];
[cw setLevel:winlevel];
@@ -2085,10 +2089,6 @@ void Fl_X::make(Fl_Window* w)
if(w->menu_window()) { // make menu windows slightly transparent
[cw setAlphaValue:0.97];
}
- x->w = w; w->i = x;
- x->wait_for_expose = 1;
- x->next = Fl_X::first;
- Fl_X::first = x;
// Install DnD handlers
[myview registerForDraggedTypes:[NSArray arrayWithObjects:
NSStringPboardType, NSFilenamesPboardType, nil]];