summaryrefslogtreecommitdiff
path: root/dw/fltkui.cc
diff options
context:
space:
mode:
authorcorvid <corvid@lavabit.com>2012-12-25 04:18:11 +0000
committercorvid <corvid@lavabit.com>2012-12-25 04:18:11 +0000
commit00c41f8b6d20217588d2965e44c9eae88ffee0c8 (patch)
tree1355eebef9298fdec94a70113c8d3e2d66658cb5 /dw/fltkui.cc
parent5b82fe650996097b18d6bc9fe4d78eaeb07b0609 (diff)
don't let form text input insert ^I, ^J, ^L, ^M
In bug #1110, Alexander pointed out that it grabs ^L instead of letting it trigger focusing of the location bar. I note that the html5 draft currently insists that ^J and ^M not be permitted to find their way into the control's value. I imagine they could still be pasted in, but *shrugs*.
Diffstat (limited to 'dw/fltkui.cc')
-rw-r--r--dw/fltkui.cc4
1 files changed, 4 insertions, 0 deletions
diff --git a/dw/fltkui.cc b/dw/fltkui.cc
index 4c3415c7..a43edf15 100644
--- a/dw/fltkui.cc
+++ b/dw/fltkui.cc
@@ -70,6 +70,10 @@ int CustInput2::handle(int e)
} else if (k == 'd') {
cut(position(), position()+1);
return 1;
+ } else if (k == 'i' || k == 'j' || k == 'l' || k == 'm') {
+ // Fl_Input wants to "insert a few selected control characters
+ // literally", but this gets in the way of key commands.
+ return 0;
}
}
return Fl_Input::handle(e);