better support for keypad

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH-1_2_X@4591 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Jean-Marc Lasgouttes 2002-07-10 14:53:01 +00:00
parent 53fb6e093a
commit 94fa1b9e6f
5 changed files with 38 additions and 1 deletions

View File

@ -1,3 +1,7 @@
2002-07-10 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
* minibuffer.C (peek_event): support keypad keys
2002-06-20 Jean-Marc Lasgouttes <lasgouttes@freesurf.fr>
* text.C (changeRegionCase): do not change case of all the

View File

@ -1,8 +1,14 @@
2002-07-10 Andrew Zabolotny <zap@cobra.ru>
* combox.C (peek_event):
* DropDown.C (peek): support keypad keys
2002-06-27 Juergen Spitzmueller <j.spitzmueller@gmx.de>
* FormInclude.C: Comment out unneeded and wrong update mechanism
(related to bug #459)
*forms/form_include.fd: define missing callbacks (bug #459)
* forms/form_include.fd: define missing callbacks (bug #459)
2002-07-03 Vitaly Lipatov <LAV@VL3143.spb.edu>

View File

@ -134,12 +134,21 @@ int DropDown::peek(XEvent * xev)
XLookupString(&xev->xkey, s_r, 10, &keysym_return, 0);
switch (keysym_return) {
case XK_Down:
#ifdef XK_KP_Down
case XK_KP_Down:
#endif
line_down();
return 1;
case XK_Up:
#ifdef XK_KP_Up
case XK_KP_Up:
#endif
line_up();
return 1;
case XK_Return:
#ifdef XK_KP_Enter
case XK_KP_Enter:
#endif
completed();
return 1;
case XK_Escape:

View File

@ -459,6 +459,9 @@ int Combox::peek_event(FL_FORM * form, void * xev)
XFlush(fl_get_display());
switch (keysym_return) {
case XK_Down:
#ifdef XK_KP_Down
case XK_KP_Down:
#endif
if (fl_get_browser(combo->browser) <
fl_get_browser_maxline(combo->browser))
fl_select_browser_line(combo->browser,
@ -475,6 +478,9 @@ int Combox::peek_event(FL_FORM * form, void * xev)
fl_get_browser(combo->browser));
return 1;
case XK_Up:
#ifdef XK_KP_Up
case XK_KP_Up:
#endif
if (fl_get_browser(combo->browser) > 1)
fl_select_browser_line(combo->browser,
fl_get_browser(combo->browser)-1);
@ -490,6 +496,9 @@ int Combox::peek_event(FL_FORM * form, void * xev)
fl_get_browser(combo->browser));
return 1;
case XK_Return:
#ifdef XK_KP_Enter
case XK_KP_Enter:
#endif
combo->hide();
return 1;
case XK_Escape:

View File

@ -129,6 +129,9 @@ int MiniBuffer::peek_event(FL_OBJECT * ob, int event, int key)
switch (key) {
case XK_Down:
#ifdef XK_KP_Down
case XK_KP_Down:
#endif
if (hist_iter != history_->end()) {
++hist_iter;
}
@ -141,6 +144,9 @@ int MiniBuffer::peek_event(FL_OBJECT * ob, int event, int key)
}
return 1;
case XK_Up:
#ifdef XK_KP_Up
case XK_KP_Up:
#endif
if (hist_iter == history_->begin()) {
// no further history
stored_set(input);
@ -215,6 +221,9 @@ int MiniBuffer::peek_event(FL_OBJECT * ob, int event, int key)
return 1;
case 13:
case XK_Return:
#ifdef XK_KP_Enter
case XK_KP_Enter:
#endif
{
#if 0
// This will go in again in a little while