MPX updated
Daniel Stone
daniel at fooishbar.org
Fri Dec 8 04:01:01 PST 2006
On Fri, Dec 08, 2006 at 11:52:53AM +1030, Peter Hutterer wrote:
> I've been working on getting MPX [1] up-to-date with the current
> server for the last few weeks. (MPX is a patch against X.org to get
> multiple mouse cursors). Thanks to Daniel Stone's changes [2], MPX
> fits now snugly into the event generation.
>
> MPX now
> - is integrated rather than bolted on top
> - has it's own extension protocol
> - does proper mouse cursor rendering
> - has a lot of still-unused stuff under the hood
>
> This is the first set of patches I can offer for people to play with.
> It's not overly stable or mature yet. More features will be added but
> you can get a grip on what it does.
Hi Peter,
Just a few comments as I'm reading the patch from the plane.
Firstly, the number of #ifdef MPXes is kind of scary. If it's rather
useful -- and requires breaking core APIs anyway -- we can just merge it
into the new Xi, which I've been planning for a while. This will reduce
the number of new events, makes the semantics slightly less complicated,
and Xi is now required, so you get a grand total of zero ifdefs. Sound
decent?
One thing that might be interesting to chase up, as an internal
implementation detail, is having a struct PointerRec or so, and then
pointer devices can just have a pointer to the relevant PointerRec,
which can either be their own (for MPX devices), or the core pointer.
This also allows you to aggregate multiple extended devices into one
pointer, should you so wish -- pathological though that seems. This
would, in theory, also get rid of the mpsprites global.
POINTER_MULTI seems kind of redundant: can we not just infer this from
the device? Also, if we make a more generic SpriteRec *pointer, this
will go away anyway. But your GPE change seems to be quite generically
useful in collapsing a highly redundant codepath.
Also:
--- a/mi/mipointer.c
+++ b/mi/mipointer.c
@@ -1,5 +1,5 @@
/*
- * mipointer.c
+ * miPointer->c
*/
:)
Some of your '#if !defined MPX blah #else otherblah #endif' constructs
seem a bit backwards, too.
Overall, looks rocking, though. I think we can solve most of my
concerns by just folding MPX into a revision of Xi, thus reducing the
number of events, and also making the concept of multiple pointers
unconditional in the same way that the concept of multiple pointing
devices is now -- that will reduce code complexity a great deal.
Thanks a lot!
Cheers,
Daniel
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.x.org/archives/xorg/attachments/20061208/e3ce74ca/attachment.pgp>
More information about the xorg
mailing list