diff options
| author | Matthias Melcher <fltk@matthiasm.com> | 2010-04-11 09:52:05 +0000 |
|---|---|---|
| committer | Matthias Melcher <fltk@matthiasm.com> | 2010-04-11 09:52:05 +0000 |
| commit | 896c6c27664e679907195f9cc9a32e55c81998fb (patch) | |
| tree | 8864092a1ec755ae8f10e06a4d01525dc0f2c37d | |
| parent | 2fe7eabb6249c4c9ff0f6e697679a7f9f85ce0eb (diff) | |
Apple Cocoa: modal windows would not resize.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7479 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
| -rw-r--r-- | fluid/Fl_Widget_Type.cxx | 5 | ||||
| -rw-r--r-- | src/Fl_cocoa.mm | 5 |
2 files changed, 6 insertions, 4 deletions
diff --git a/fluid/Fl_Widget_Type.cxx b/fluid/Fl_Widget_Type.cxx index c47519752..13d625713 100644 --- a/fluid/Fl_Widget_Type.cxx +++ b/fluid/Fl_Widget_Type.cxx @@ -1188,7 +1188,6 @@ void align_position_cb(Fl_Choice *i, void *v) { Fl_Widget_Type* q = (Fl_Widget_Type*)o; Fl_Align x = q->o->align(); Fl_Align y = (x & ~FL_ALIGN_POSITION_MASK) | b; - //printf("x:%04x y:%04x b:%04x\n", x, y, b); if (x != y) { q->o->align(y); q->redraw(); @@ -1787,6 +1786,7 @@ void live_mode_cb(Fl_Button*o,void *) { } if (o->value()) { if (numselected == 1) { + Fl_Group::current(0L); live_widget = current_widget->enter_live_mode(1); if (live_widget) { live_type = current_widget; @@ -1804,8 +1804,9 @@ void live_mode_cb(Fl_Button*o,void *) { Fl_Button *btn = new Fl_Button(10, h+20, 100, 25, "Exit Live Mode"); btn->labelsize(12); btn->callback(leave_live_mode_cb); - live_widget->position(10, 10); + rsz->end(); live_window->add(live_widget); + live_widget->position(10, 10); live_window->resizable(live_widget); live_window->set_modal(); // block all other UI live_window->callback(leave_live_mode_cb); diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm index 3480bd0ab..6a9654f75 100644 --- a/src/Fl_cocoa.mm +++ b/src/Fl_cocoa.mm @@ -2100,7 +2100,7 @@ void Fl_X::make(Fl_Window* w) winstyle |= NSResizableWindowMask; } } else { - if (w->resizable()) { + if (w->resizable()) { Fl_Widget *o = w->resizable(); int minw = o->w(); if (minw > 100) minw = 100; int minh = o->h(); if (minh > 100) minh = 100; @@ -2121,7 +2121,8 @@ void Fl_X::make(Fl_Window* w) winstyle = NSBorderlessWindowMask; } } else if (w->modal()) { - winstyle &= ~(NSResizableWindowMask | NSMiniaturizableWindowMask); + winstyle &= ~NSMiniaturizableWindowMask; + // winstyle &= ~(NSResizableWindowMask | NSMiniaturizableWindowMask); // winlevel = NSModalPanelWindowLevel; } else if (w->non_modal()) { |
