Summary: | [GTK] Text editor does not handle common keystrokes | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Alp Toker <alp> | ||||||
Component: | New Bugs | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | CC: | mh+webkit | ||||||
Priority: | P2 | Keywords: | Gtk | ||||||
Version: | 523.x (Safari 3) | ||||||||
Hardware: | All | ||||||||
OS: | All | ||||||||
Attachments: |
|
Description
Alp Toker
2007-10-23 18:01:40 PDT
Created attachment 16823 [details]
Implementation A
This is the first of two possible implementations that should achieve the same thing. Whichever will become part of WebKit/Gtk+ is up to the audience.
Created attachment 16824 [details]
Implementation B
This is the second of two possible implementations that should achieve the same thing. Whichever will become part of WebKit/Gtk+ is up to the audience.
Bug #16104 has yet another approach to this problem that's worth looking at. Hmmm, I think the windows path is clearer, and broadly nicer See WebView::interpretKeyEvent in WebKit/win/WebView.cpp IIRC there's a patch somewhere to make gtk, win, and qt share there interpretKeyEvents implementation for handleKeyPress, though i can't rememember the number and i suspect it's been orphaned. Comment on attachment 16823 [details]
Implementation A
As i said in a previous comment i don't think either of these approaches is really ideal
(In reply to comment #3) > Bug #16104 has yet another approach to this problem that's worth looking at. Bug #16104 doesn't exist. Sorry, I meant #15057 I came up with the quick solution so we could get more testing for clipboard and tab/focus issues, but if an alternative is ready, that's great. I had a feeling at the start that eventually we're going to use the GDK_KP directly, but maybe it does make sense to share this code instead. *** Bug 15628 has been marked as a duplicate of this bug. *** To be clear, if we were to do a dynamic lookup table, we would just go and use GtkBindingSet. However, there are no resources to implement this right now and the provided patch works, and there is precedent for this hack to get positive review in the Qt port. Please reconsider this review so users can get basic input support as a temporary measure. Comment on attachment 16824 [details]
Implementation B
While this approach is suboptimal in the long run, the Gtk port is in need of some form of sane input handling so that work on related features can progress. The ideal approach probably involves using GtkBindingSet which, as I understand it, will respect user-customised key bindings and all that fancy stuff.
r=me if a new bug is filed about switching to GtkBindingSet at some point in the future, and the comment in the patch is updated to a FIXME referencing the bug.
Landed in r27624. See also bug #15911 (GtkBindingSet). |