summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2010-12-01 18:31:23 +0000
committerManolo Gouy <Manolo>2010-12-01 18:31:23 +0000
commit2f8b7e47c2e3b2e3ecabd0711e8daf735f32f09d (patch)
treefffcfc5d687ab3d345fa087321ec23fc9acd93c6 /src
parentbbb273cb3a6530673c18f4e98cde324d378f0ee4 (diff)
Should fix STR #2464 by not calling fl_open_display when running fluid in command line mode
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7934 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
-rw-r--r--src/Fl_cocoa.mm4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm
index 79ef1180d..96f65329f 100644
--- a/src/Fl_cocoa.mm
+++ b/src/Fl_cocoa.mm
@@ -1447,12 +1447,14 @@ void fl_close_display() {
// Gets the border sizes and the titlebar size
static void get_window_frame_sizes(int &bx, int &by, int &bt) {
- fl_open_display();
+ NSAutoreleasePool *localPool;
+ localPool = [[NSAutoreleasePool alloc] init];
NSRect inside = { {20,20}, {100,100} };
NSRect outside = [NSWindow frameRectForContentRect:inside styleMask:NSTitledWindowMask];
bx = int(outside.origin.x - inside.origin.x);
by = int(outside.origin.y - inside.origin.y);
bt = int(outside.size.height - inside.size.height - by);
+ [localPool release];
}
/*