mirror of
git://git.sv.gnu.org/nano.git
synced 2025-02-12 03:14:54 +03:00
tweaks: avoid fiddling with the keybuffer when it's not needed
Just change KEY_MOUSE directly into KEY_ENTER for a double click.
This commit is contained in:
parent
7dcc8f1d7a
commit
04e557fdaf
@ -138,10 +138,11 @@ char *do_browser(char *path)
|
|||||||
/* If we selected the same filename as last time, fake a
|
/* If we selected the same filename as last time, fake a
|
||||||
* press of the Enter key so that the file is read in. */
|
* press of the Enter key so that the file is read in. */
|
||||||
if (old_selected == selected)
|
if (old_selected == selected)
|
||||||
unget_kbinput(KEY_ENTER, FALSE);
|
kbinput = KEY_ENTER;
|
||||||
}
|
}
|
||||||
|
|
||||||
continue;
|
if (kbinput == KEY_MOUSE)
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
#endif /* ENABLE_MOUSE */
|
#endif /* ENABLE_MOUSE */
|
||||||
|
|
||||||
|
@ -608,7 +608,6 @@ void record_macro(void);
|
|||||||
void run_macro(void);
|
void run_macro(void);
|
||||||
size_t get_key_buffer_len(void);
|
size_t get_key_buffer_len(void);
|
||||||
void put_back(int keycode);
|
void put_back(int keycode);
|
||||||
void unget_kbinput(int kbinput, bool metakey);
|
|
||||||
#ifdef ENABLE_NANORC
|
#ifdef ENABLE_NANORC
|
||||||
void implant(const char *string);
|
void implant(const char *string);
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user