I don’t have an answer, but a similar problem. Vintage seems to eat my “enter” events in a specific view. I have the following in my Default.sublime-keymap for my plugin:
{
"command": "gdb_edit_register",
"keys": "enter"],
"context": {"key": "gdb_running"}, {"key": "gdb_register_view"}]
},
{
"command": "gdb_edit_variable",
"keys": "enter"],
"context": {"key": "gdb_running"}, {"key": "gdb_variables_view"}]
},
and in my EventListener:
class GdbEventListener(sublime_plugin.EventListener):
def on_query_context(self, view, key, operator, operand, match_all):
print "key: %s" % key
if key == "gdb_running":
return is_running()
elif key == "gdb_variables_view":
print "querying gdb_variables_view"
return gdb_variables_view.is_open() and view.id() == gdb_variables_view.get_view().id()
elif key == "gdb_register_view":
print "querying gdb_register_view"
return gdb_register_view.is_open() and view.id() == gdb_register_view.get_view().id()
print "unknown query: %s" % key
return None
With sublime.log_commands(True) I get this when pressing enter in the register view:
key: gdb_running
key: gdb_variables_view
querying gdb_variables_view
command: set_motion {"motion": "move", "motion_args": {"by": "lines", "extend": true, "forward": true}}
So “gdb_register_view” is never queried, but “gdb_variables_view” is… Is there anything I can do to fix this? Thanks