WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] Re: PVFB wheel events (z-axis)

To: Pat Campbell <plc@xxxxxxxxxx>
Subject: Re: [Xen-devel] Re: PVFB wheel events (z-axis)
From: Markus Armbruster <armbru@xxxxxxxxxx>
Date: Thu, 28 Feb 2008 13:59:14 +0100
Cc: xen-devel@xxxxxxxxxxxxxxxxxxx
Delivery-date: Thu, 28 Feb 2008 04:59:39 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxx
In-reply-to: <87pruhzc6j.fsf@xxxxxxxxxxxxxxxxx> (Markus Armbruster's message of "Thu\, 28 Feb 2008 10\:02\:12 +0100")
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <87tzk19xqf.fsf@xxxxxxxxxxxxxxxxx> <47C0287F.5070901@xxxxxxxxxx> <87bq656tzb.fsf@xxxxxxxxxxxxxxxxx> <47C2FE4D.1030502@xxxxxxxxxx> <87prui1j8n.fsf@xxxxxxxxxxxxxxxxx> <87pruhzc6j.fsf@xxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux)
Buddy patch for ioemu:

Rename struct xenkbd_position member abs_z to rel_z

Z-axis motion is relative, not absolute.


diff -r 2a8eaba24bf0 tools/ioemu/hw/xenfb.c
--- a/tools/ioemu/hw/xenfb.c    Tue Feb 26 15:11:51 2008 +0000
+++ b/tools/ioemu/hw/xenfb.c    Thu Feb 28 13:57:13 2008 +0100
@@ -592,7 +592,8 @@ static int xenfb_send_key(struct xenfb *
 }
 
 /* Send a relative mouse movement event */
-static int xenfb_send_motion(struct xenfb *xenfb, int rel_x, int rel_y, int 
rel_z)
+static int xenfb_send_motion(struct xenfb *xenfb,
+                            int rel_x, int rel_y, int rel_z)
 {
        union xenkbd_in_event event;
 
@@ -606,7 +607,8 @@ static int xenfb_send_motion(struct xenf
 }
 
 /* Send an absolute mouse movement event */
-static int xenfb_send_position(struct xenfb *xenfb, int abs_x, int abs_y, int 
abs_z)
+static int xenfb_send_position(struct xenfb *xenfb,
+                              int abs_x, int abs_y, int rel_z)
 {
        union xenkbd_in_event event;
 
@@ -614,7 +616,7 @@ static int xenfb_send_position(struct xe
        event.type = XENKBD_TYPE_POS;
        event.pos.abs_x = abs_x;
        event.pos.abs_y = abs_y;
-       event.pos.abs_z = abs_z;
+       event.pos.rel_z = rel_z;
 
        return xenfb_kbd_event(xenfb, &event);
 }
diff -r 2a8eaba24bf0 xen/include/public/io/kbdif.h
--- a/xen/include/public/io/kbdif.h     Tue Feb 26 15:11:51 2008 +0000
+++ b/xen/include/public/io/kbdif.h     Thu Feb 28 13:57:13 2008 +0100
@@ -65,7 +65,7 @@ struct xenkbd_position
     uint8_t type;        /* XENKBD_TYPE_POS */
     int32_t abs_x;       /* absolute X position (in FB pixels) */
     int32_t abs_y;       /* absolute Y position (in FB pixels) */
-    int32_t abs_z;       /* absolute Z position (wheel) */
+    int32_t rel_z;       /* relative Z motion (wheel) */
 };
 
 #define XENKBD_IN_EVENT_SIZE 40

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel