Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Marco Bubke
flatpak-qt-creator
Commits
f9281451
Commit
f9281451
authored
Nov 27, 2009
by
Kimitake
Committed by
hjk
Nov 27, 2009
Browse files
^[ should work as well as ESC key in insert mode.
Merge-request: 2157 Reviewed-by:
hjk
<
qtc-committer@nokia.com
>
parent
8abc551b
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/plugins/fakevim/fakevimhandler.cpp
View file @
f9281451
...
...
@@ -514,7 +514,7 @@ bool FakeVimHandler::Private::wantsOverride(QKeyEvent *ev)
const
int
mods
=
ev
->
modifiers
();
KEY_DEBUG
(
"SHORTCUT OVERRIDE"
<<
key
<<
" PASSING: "
<<
m_passing
);
if
(
key
==
Key_Escape
)
{
if
(
key
==
Key_Escape
||
(
mods
==
Qt
::
ControlModifier
&&
key
==
Key_BracketLeft
)
)
{
// Not sure this feels good. People often hit Esc several times
if
(
m_visualMode
==
NoVisualMode
&&
m_mode
==
CommandMode
)
return
false
;
...
...
@@ -1631,7 +1631,8 @@ EventResult FakeVimHandler::Private::handleCommandMode(int key, int unmodified,
EventResult
FakeVimHandler
::
Private
::
handleInsertMode
(
int
key
,
int
,
const
QString
&
text
)
{
if
(
key
==
Key_Escape
||
key
==
27
||
key
==
control
(
'c'
))
{
if
(
key
==
Key_Escape
||
key
==
27
||
key
==
control
(
'c'
)
||
key
==
379
/* ^[ */
)
{
// start with '1', as one instance was already physically inserted
// while typing
QString
data
=
m_lastInsertion
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment