fixed touchpad orientation

ugfx_release_2.6
Tectu 2012-08-22 16:33:40 +02:00
parent 217f15b4d3
commit bee96e39ad
1 changed files with 2 additions and 10 deletions

View File

@ -158,8 +158,7 @@ uint16_t tpReadX(void) {
x = cal.xm * _tpReadRealX() + cal.xn; x = cal.xm * _tpReadRealX() + cal.xn;
y = cal.ym * _tpReadRealY() + cal.yn; y = cal.ym * _tpReadRealY() + cal.yn;
/* switch(gdispGetOrientation()) {
switch(gdispGetOrientation()) { // implement gdispGetOrientation()
case portrait: case portrait:
return x; return x;
case landscape: case landscape:
@ -169,9 +168,6 @@ uint16_t tpReadX(void) {
case landscapeInv: case landscapeInv:
return y; return y;
} }
*/
return x;
} }
/** /**
@ -187,8 +183,7 @@ uint16_t tpReadY(void) {
x = cal.xm * _tpReadRealX() + cal.xn; x = cal.xm * _tpReadRealX() + cal.xn;
y = cal.ym * _tpReadRealY() + cal.yn; y = cal.ym * _tpReadRealY() + cal.yn;
/* switch(gdispGetOrientation()) {
switch(gdispGetOrientation()) { // implement gdispGetOrientation()
case portrait: case portrait:
return y; return y;
case landscape: case landscape:
@ -198,9 +193,6 @@ uint16_t tpReadY(void) {
case landscapeInv: case landscapeInv:
return SCREEN_WIDTH - x; return SCREEN_WIDTH - x;
} }
*/
return y;
} }
void tpCalibrate(void) { void tpCalibrate(void) {