diff options
| author | Matthias Melcher <fltk@matthiasm.com> | 2009-12-25 20:53:22 +0000 |
|---|---|---|
| committer | Matthias Melcher <fltk@matthiasm.com> | 2009-12-25 20:53:22 +0000 |
| commit | 38c15442a418a238462b1207adb681cf992edab7 (patch) | |
| tree | 3588313acf89c15ac6ad705038464304c7849ec7 /fluid/function_panel.fl | |
| parent | 9a505ef44c8433c8f58c68b79888c6f52c7739db (diff) | |
Changed widget bin closing behavior when pressing ESC (which IMO should quit the app, not the widget bin).
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6981 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'fluid/function_panel.fl')
| -rw-r--r-- | fluid/function_panel.fl | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/fluid/function_panel.fl b/fluid/function_panel.fl index 21aa03dd4..426f0ef56 100644 --- a/fluid/function_panel.fl +++ b/fluid/function_panel.fl @@ -43,6 +43,12 @@ decl {extern class Fl_Type *Fl_Type_make(const char*);} {} decl {extern void select_only(Fl_Type*);} {} +decl {extern void exit_cb(Fl_Widget*, void*);} {global +} + +decl {extern void toggle_widgetbin_cb(Fl_Widget*, void*);} {global +} + Function {make_function_panel()} {} { Fl_Window function_panel { label {Function/Method Properties} open @@ -432,7 +438,11 @@ Function {type_make_cb(Fl_Widget*,void*d)} {return_type void Function {make_widgetbin()} {} { Fl_Window widgetbin_panel { label {Widget Bin} - xywh {411 171 550 85} type Single align 80 non_modal visible + callback {if (Fl::event()==FL_SHORTCUT && Fl::event_key()==FL_Escape) + exit_cb((Fl_Widget*)o, v); +else + toggle_widgetbin_cb((Fl_Widget*)o, v);} open selected + xywh {410 171 550 85} type Single align 80 non_modal visible } { Fl_Group {} { xywh {3 3 79 79} @@ -763,8 +773,7 @@ Function {make_widgetbin()} {} { } } -Function {make_sourceview()} {selected -} { +Function {make_sourceview()} {} { Fl_Window sourceview_panel { label {Code View} callback toggle_sourceview_cb |
