Re: Mouse wheel support added



> > Mouse scroll wheel is now supported in the internal editor on xterm and
> > gnome-terminal. Konsole and rxvt don't work yet.
> >
> What?  Where?  How?

I simply added two more buttons GPM_B_UP and GPM_B_DOWN to src/mouse.h.  
Then I added checks for those buttons to the event callback of the editor.

> I think rxvt needs to be fixed to make that work, and gpm is another 
> story...

I have already sent patches for rxvt and Konsole to their authors.

As for gpm, that's indeed another story.  Good thing is that it's
maintained again, and that the ouse wheel support has been added.  Bad
thing is that the Gpm_Event structure has changed in gpm-1.20.1rc1 to
support the wheel.

I believe the first thing that needs to be done is to stop using that
structure everywhere in the mc code, except calls to gpm.

Then we can simply check in configure if gpm is recent enough to support
mouse wheel.  If yes, the new fields will be somehow converted to the
GPM_B_UP and GPM_B_DOWN events (the GPM prefix will probably go away to
show that it's not gpm API).

-- 
Regards,
Pavel Roskin




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]