summaryrefslogtreecommitdiff
path: root/fluid/function_panel.fl
diff options
context:
space:
mode:
authorGreg Ercolano <erco@seriss.com>2013-10-25 22:03:47 +0000
committerGreg Ercolano <erco@seriss.com>2013-10-25 22:03:47 +0000
commitf9470425359e8180ebe73f9585a4f27531f72839 (patch)
tree2fbcf91f316c6b0b1379913462d86039dcd4b844 /fluid/function_panel.fl
parentd2f83a42c27b6689e79173201624994d23ff1123 (diff)
STR #2997: Disable ESC from closing code window.
This drives VI users crazy; a comman 'save' pattern is: (1) enter some code, (2) hit ESC, (3) type :w ENTER. In VI these actions save the code entered. in fluid it /dumps/ the code typed because ESC is a shortcut for the Cancel key. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10010 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'fluid/function_panel.fl')
-rw-r--r--fluid/function_panel.fl12
1 files changed, 8 insertions, 4 deletions
diff --git a/fluid/function_panel.fl b/fluid/function_panel.fl
index aaf34efb6..657b1f360 100644
--- a/fluid/function_panel.fl
+++ b/fluid/function_panel.fl
@@ -112,7 +112,7 @@ Function {make_function_panel()} {} {
}
Fl_Button f_panel_cancel {
label Cancel
- tooltip {Cancel the changes.} xywh {280 200 50 20} shortcut 0xff1b labelsize 11
+ tooltip {Cancel the changes.} xywh {280 200 50 20} labelsize 11
}
Fl_Box {} {
xywh {10 200 205 20} resizable
@@ -126,9 +126,13 @@ Function {make_function_panel()} {} {
}
}
-Function {make_code_panel()} {} {
+Function {make_code_panel()} {open
+} {
Fl_Window code_panel {
label {Code Properties}
+ callback {if (Fl::event()==FL_SHORTCUT && Fl::event_key()==FL_Escape)
+ return; // ignore Escape
+code_panel->hide(); // otherwise hide..} open selected
xywh {353 262 540 180} type Double labelsize 11 resizable
code0 {o->size_range(200, 150);} modal visible
} {
@@ -147,7 +151,7 @@ Function {make_code_panel()} {} {
}
Fl_Button code_panel_cancel {
label Cancel
- xywh {470 150 60 20} shortcut 0xff1b labelsize 11
+ xywh {470 150 60 20} labelsize 11
}
Fl_Box {} {
xywh {10 150 380 20} labelsize 11 resizable
@@ -825,7 +829,7 @@ else
}
Fl_Button {} {
user_data {"Fl_Tree"}
- callback type_make_cb selected
+ callback type_make_cb
tooltip Tree xywh {484 5 24 24} box THIN_UP_BOX
code0 {o->image(pixmap[50]);}
}