Index: [thread] [date] [subject] [author]
  From: Alexander Peuchert <peuc@comnets.rwth-aachen.de>
  To  : ggi-develop@eskimo.com
  Date: Wed, 10 Mar 1999 10:40:30 +0100 (MET)

Re: libgii -> mice

On Tue, 9 Mar 1999, Marcus Sundberg wrote:

> Alexander Peuchert wrote:
> > 
> > hi
> > 
> > just a question to the ligii / mice people:
> > 
> > How is the input from the mouse translated into a gii event ?
> > Is every movement of the mouse put into an event or is the mouse device
> > read until no further data arrives and is after that a new gii event
> > generated ?
> 
> The former.
> 
> > ( the second one should be much faster because multible mouse
> > movments are translated into one event )
> 
> Not really. The syscalls required to actully read the data is in
> most cases what takes time.
> 
> Besides you can't do the latter.
> Imagine you are in a GUI app and quickly move the mouse to a button,
> click the button and move the mouse back. You most probably wouldn't
> want the LibGII mouse driver to merge all the movements together
> and realize that "hey, nothing's changed so I don't have to send
> an event"...

Well, I'm developing a gui app for slow processor and I don't want the app
to draw the mouse on one place although it has move to another already.
Okay, I catch all mouse events until no more arrive and draw then the
mouse pointer, but this could be done in the gii driver. You could merge
all movements until a button is pressed or a short time periode has
passed, so that the movement events and the button press events are still
synced ...

On second thought I can think of apps which want to get every mouse event,
so either the driver could be configurable or the app should implement
this behavior. I chooce the second one, cause its less programming effort.

So, sorry for stealing your time ... ;-)

alex

> 
> //Marcus
> -- 
> -------------------------------+------------------------------------
>         Marcus Sundberg        | http://www.stacken.kth.se/~mackan
>  Royal Institute of Technology |       Phone: +46 707 295404
>        Stockholm, Sweden       |   E-Mail: mackan@stacken.kth.se
> 

Alexander Peuchert
mailto:peuc@comnets.rwth-aachen.de

Index: [thread] [date] [subject] [author]