Currently basic undo functionality with the 'u' key depends on
FEATURE_VI_YANKMARK. These two features are separate, so we can remove this
dependency.
Signed-off-by: Andrew Fuller <abf@google.com>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
string_insert(dot, p, ALLOW_UNDO); // insert the string
end_cmd_q(); // stop adding to q
break;
-#if ENABLE_FEATURE_VI_UNDO
- case 'u': // u- undo last operation
- undo_pop();
- break;
-#endif
case 'U': // U- Undo; replace current line with original version
if (reg[Ureg] != NULL) {
p = begin_line(dot);
}
break;
#endif /* FEATURE_VI_YANKMARK */
+#if ENABLE_FEATURE_VI_UNDO
+ case 'u': // u- undo last operation
+ undo_pop();
+ break;
+#endif
case '$': // $- goto end of line
case KEYCODE_END: // Cursor Key End
for (;;) {