Fix mouse mapping under reflection
This commit is contained in:
parent
a80e1e5aed
commit
9373d9186b
|
@ -21,7 +21,7 @@
|
|||
* TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
/* $XFree86: xc/programs/Xserver/hw/kdrive/kinput.c,v 1.24 2002/08/15 18:07:57 keithp Exp $ */
|
||||
/* $XFree86: xc/programs/Xserver/hw/kdrive/kinput.c,v 1.25 2002/10/03 22:09:04 keithp Exp $ */
|
||||
|
||||
#include "kdrive.h"
|
||||
#include "inputstr.h"
|
||||
|
@ -387,22 +387,22 @@ KdComputeMouseMatrix (KdMouseMatrix *m, Rotation randr, int width, int height)
|
|||
m->matrix[1][0] = 0; m->matrix[1][1] = y_dir;
|
||||
break;
|
||||
case RR_Rotate_90:
|
||||
m->matrix[0][0] = 0; m->matrix[0][1] = -y_dir;
|
||||
m->matrix[1][0] = x_dir; m->matrix[1][1] = 0;
|
||||
m->matrix[0][0] = 0; m->matrix[0][1] = -x_dir;
|
||||
m->matrix[1][0] = y_dir; m->matrix[1][1] = 0;
|
||||
break;
|
||||
case RR_Rotate_180:
|
||||
m->matrix[0][0] = -x_dir; m->matrix[0][1] = 0;
|
||||
m->matrix[1][0] = 0; m->matrix[1][1] = -y_dir;
|
||||
break;
|
||||
case RR_Rotate_270:
|
||||
m->matrix[0][0] = 0; m->matrix[0][1] = y_dir;
|
||||
m->matrix[1][0] = -x_dir; m->matrix[1][1] = 0;
|
||||
m->matrix[0][0] = 0; m->matrix[0][1] = x_dir;
|
||||
m->matrix[1][0] = -y_dir; m->matrix[1][1] = 0;
|
||||
break;
|
||||
}
|
||||
for (i = 0; i < 2; i++)
|
||||
for (j = 0 ; j < 2; j++)
|
||||
if (m->matrix[i][j] < 0)
|
||||
m->matrix[i][3] = size[j] - 1;
|
||||
m->matrix[i][2] = size[j] - 1;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
Loading…
Reference in New Issue
Block a user