wok diff xorg-xf86-input-evtouch/stuff/evtouch.u @ rev 14738
libpng+apng: remove ERROR: trigger
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Jun 14 07:23:16 2013 +0200 (2013-06-14) |
parents | |
children |
line diff
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000 1.2 +++ b/xorg-xf86-input-evtouch/stuff/evtouch.u Fri Jun 14 07:23:16 2013 +0200 1.3 @@ -0,0 +1,178 @@ 1.4 +Remove unused variables and code just to make gcc happy 1.5 + 1.6 +Index: xserver-xorg-input-evtouch/evtouch.c 1.7 +=================================================================== 1.8 +--- xserver-xorg-input-evtouch.orig/evtouch.c 2009-01-21 20:06:50.647249439 +0900 1.9 ++++ xserver-xorg-input-evtouch/evtouch.c 2009-01-21 20:07:39.518253785 +0900 1.10 +@@ -352,7 +352,6 @@ void EVTouchProcessAbs(EVTouchPrivatePtr 1.11 + void EVTouchProcessRel(EVTouchPrivatePtr priv) 1.12 + { 1.13 + struct input_event *ev; /* packet being/just read */ 1.14 +- int dummy; 1.15 + 1.16 + ev = &priv->ev; 1.17 + if ( ev->code == REL_X ) { 1.18 +@@ -745,17 +744,6 @@ EVTouchNewPacket (EVTouchPrivatePtr priv 1.19 + 1.20 + 1.21 + 1.22 +-static unsigned char 1.23 +-EVTouchRead(EVTouchPrivatePtr priv) 1.24 +-{ 1.25 +- unsigned char c; 1.26 +- XisbBlockDuration (priv->buffer, EV_TIMEOUT); 1.27 +- c = XisbRead(priv->buffer); 1.28 +- return (c); 1.29 +-} 1.30 +- 1.31 +- 1.32 +- 1.33 + static Bool 1.34 + EVTouchGetPacket (EVTouchPrivatePtr priv) 1.35 + { 1.36 +From: Thomas Jaeger <ThJaeger@gmail.com> 1.37 +Date: Sun, 22 Mar 2009 20:58:58 -0400 1.38 +Subject: Make calibration work on xserver-1.6 1.39 + 1.40 +Stolen from Ubuntu. 1.41 + 1.42 +Index: xserver-xorg-input-evtouch/ev_calibrate.c 1.43 +=================================================================== 1.44 +--- xserver-xorg-input-evtouch.orig/ev_calibrate.c 1.45 ++++ xserver-xorg-input-evtouch/ev_calibrate.c 1.46 +@@ -218,7 +218,7 @@ 1.47 + int cap_style = CapButt; /* style of the line's edje and */ 1.48 + int join_style = JoinBevel; /* joined lines. */ 1.49 + 1.50 +- int event_mask = ExposureMask | ButtonReleaseMask | PointerMotionMask | KeyPressMask; 1.51 ++ int event_mask = ExposureMask | ButtonPressMask | ButtonReleaseMask | PointerMotionMask | KeyPressMask; 1.52 + 1.53 + int depth; 1.54 + int screen_num; 1.55 +Index: xserver-xorg-input-evtouch/evtouch.c 1.56 +=================================================================== 1.57 +--- xserver-xorg-input-evtouch.orig/evtouch.c 1.58 ++++ xserver-xorg-input-evtouch/evtouch.c 1.59 +@@ -306,7 +306,7 @@ 1.60 + } 1.61 + 1.62 + if (pos_changed == 1) { 1.63 +-#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 2 1.64 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 2 1.65 + ConvertProc(priv->local, 0, 2, 1.66 + priv->raw_x, priv->raw_y, 1.67 + 0, 0, 0, 0, 1.68 +@@ -369,7 +369,7 @@ 1.69 + priv->raw_y = priv->min_y; 1.70 + } 1.71 + 1.72 +-#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 2 1.73 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 2 1.74 + ConvertProc(priv->local, 0, 2, 1.75 + priv->raw_x, priv->raw_y, 1.76 + 0, 0, 0, 0, 1.77 +Index: xserver-xorg-input-evtouch/evtouch.c 1.78 +=================================================================== 1.79 +--- xserver-xorg-input-evtouch.orig/evtouch.c 1.80 ++++ xserver-xorg-input-evtouch/evtouch.c 1.81 +@@ -30,10 +30,8 @@ 1.82 + 1.83 + #define _evdev_touch_C_ 1.84 + 1.85 +-#include <xf86Version.h> 1.86 +-#if XF86_VERSION_CURRENT >= XF86_VERSION_NUMERIC(3,9,0,0,0) 1.87 ++#include <xorgVersion.h> 1.88 + #define XFREE86_V4 1.89 +-#endif 1.90 + 1.91 + /***************************************************************************** 1.92 + * Standard Headers 1.93 +@@ -74,7 +72,6 @@ 1.94 + #include "xf86_OSproc.h" 1.95 + #include "xf86Xinput.h" 1.96 + #include "exevents.h" 1.97 +-#include "xf86OSmouse.h" 1.98 + #include "randrstr.h" 1.99 + 1.100 + #ifndef NEED_XF86_TYPES 1.101 +@@ -139,7 +136,7 @@ 1.102 + "Kenan Esau", 1.103 + MODINFOSTRING1, 1.104 + MODINFOSTRING2, 1.105 +- XF86_VERSION_CURRENT, 1.106 ++ XORG_VERSION_CURRENT, 1.107 + 0, 8, 8, 1.108 + ABI_CLASS_XINPUT, 1.109 + ABI_XINPUT_VERSION, 1.110 +@@ -590,6 +587,10 @@ 1.111 + EVTouchPrivatePtr priv = (EVTouchPrivatePtr) (local->private); 1.112 + unsigned char map[EV_MAX_BUTTONS]; 1.113 + int i; 1.114 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 1.115 ++ Atom btn_label; 1.116 ++ Atom axis_labels[2] = { 0, 0 }; 1.117 ++#endif 1.118 + 1.119 + for (i = 0; i < EV_MAX_BUTTONS; i++) 1.120 + map[i] = i; 1.121 +@@ -628,7 +629,11 @@ 1.122 + /* 1.123 + * Device reports button press for 5 buttons. 1.124 + */ 1.125 +- if (InitButtonClassDeviceStruct (dev, EV_MAX_BUTTONS, map) == FALSE) 1.126 ++ if (InitButtonClassDeviceStruct (dev, EV_MAX_BUTTONS, 1.127 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 1.128 ++ &btn_label, 1.129 ++#endif 1.130 ++ map) == FALSE) 1.131 + { 1.132 + ErrorF("Unable to allocate EVTouch touchscreen ButtonClassDeviceStruct\n"); 1.133 + return BadAlloc; 1.134 +@@ -652,26 +657,43 @@ 1.135 + * Device reports motions on 2 axes in absolute coordinates. 1.136 + * Axes min and max values are reported in raw coordinates. 1.137 + */ 1.138 +- if (InitValuatorClassDeviceStruct(dev, 2, xf86GetMotionEvents, 1.139 ++ if (InitValuatorClassDeviceStruct(dev, 2, 1.140 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 1.141 ++ axis_labels, 1.142 ++#endif 1.143 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) < 3 1.144 ++ xf86GetMotionEvents, 1.145 ++#endif 1.146 + local->history_size, Absolute) == FALSE) 1.147 + { 1.148 + ErrorF ("Unable to allocate EVTouch touchscreen ValuatorClassDeviceStruct\n"); 1.149 + return !Success; 1.150 + } 1.151 + 1.152 +-#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) == 2 1.153 +- xf86InitValuatorAxisStruct(dev, 0, 0, priv->screen_width, 1.154 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 2 1.155 ++ xf86InitValuatorAxisStruct(dev, 0, 1.156 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 1.157 ++ axis_labels[0], 1.158 ++#endif 1.159 ++ 0, priv->screen_width, 1.160 + 1024, 1.161 + EV_AXIS_MIN_RES /* min_res */ , 1.162 + EV_AXIS_MAX_RES /* max_res */ ); 1.163 + xf86InitValuatorDefaults(dev, 0); 1.164 +- xf86InitValuatorAxisStruct(dev, 1, 0, priv->screen_height, 1.165 ++ xf86InitValuatorAxisStruct(dev, 1, 1.166 ++#if GET_ABI_MAJOR(ABI_XINPUT_VERSION) >= 7 1.167 ++ axis_labels[1], 1.168 ++#endif 1.169 ++ 0, priv->screen_height, 1.170 + 1024, 1.171 + EV_AXIS_MIN_RES /* min_res */ , 1.172 + EV_AXIS_MAX_RES /* max_res */ ); 1.173 + xf86InitValuatorDefaults(dev, 1); 1.174 + #else 1.175 + xf86InitValuatorAxisStruct(dev, 0, priv->min_x, priv->max_x, 1.176 ++ 1024, 1.177 ++ EV_AXIS_MIN_RES /* min_res */ , 1.178 ++ EV_AXIS_MAX_RES /* max_res */ ); 1.179 + xf86InitValuatorDefaults(dev, 1); 1.180 + #endif 1.181 +