mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-20 21:08:08 +01:00
Fixed problems in menu scrolling caused by the patch sent by Swivel.
This commit is contained in:
20
src/event.c
20
src/event.c
@@ -979,26 +979,6 @@ handleEnterNotify(XEvent *event)
|
||||
}
|
||||
}
|
||||
|
||||
/* start my fix scrolled menus */
|
||||
if (wPreferences.scrollable_menus) {
|
||||
if (scr->flags.jump_back_pending ||
|
||||
event->xcrossing.x_root <= 1 ||
|
||||
event->xcrossing.x_root >= (scr->scr_width - 2) ||
|
||||
event->xcrossing.y_root <= 1 ||
|
||||
event->xcrossing.y_root >= (scr->scr_height - 2)) {
|
||||
#ifdef DEBUG
|
||||
L("pointer at screen edge in EnterNotify event, fear");
|
||||
#endif
|
||||
menu = wMenuUnderPointer(scr);
|
||||
if (menu!=NULL) {
|
||||
wMenuScroll(menu, event);
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
/* end fix scrolled menus */
|
||||
|
||||
|
||||
if (XFindContext(dpy, event->xcrossing.window, wWinContext,
|
||||
(XPointer *)&desc)!=XCNOENT) {
|
||||
if(desc->handle_enternotify)
|
||||
|
||||
@@ -1792,12 +1792,7 @@ wMenuScroll(WMenu *menu, XEvent *event)
|
||||
WMNextEvent(dpy, &ev);
|
||||
switch (ev.type) {
|
||||
case EnterNotify:
|
||||
/*
|
||||
this um causes a nasty crash ugly ugh i dont see *why* we do this,
|
||||
everything seems fine without it. ( swivel )
|
||||
WMHandleEvent(&ev);
|
||||
*/
|
||||
break;
|
||||
case MotionNotify:
|
||||
x = (ev.type==MotionNotify) ? ev.xmotion.x_root : ev.xcrossing.x_root;
|
||||
y = (ev.type==MotionNotify) ? ev.xmotion.y_root : ev.xcrossing.y_root;
|
||||
|
||||
Reference in New Issue
Block a user