Touchpad Issue Fix
Fixed interchanged cases of landscape and landscapeInv in tpReadX() and tpReadY()
This commit is contained in:
parent
a03b2fbf5d
commit
c35988ffb5
1 changed files with 7 additions and 7 deletions
|
@ -157,11 +157,11 @@ uint16_t tpReadX(void) {
|
|||
case portrait:
|
||||
return x;
|
||||
case landscape:
|
||||
return SCREEN_HEIGHT - y;
|
||||
case portraitInv:
|
||||
return SCREEN_WIDTH - x;
|
||||
case landscapeInv:
|
||||
return y;
|
||||
case portraitInv:
|
||||
return SCREEN_WIDTH - x - 1;
|
||||
case landscapeInv:
|
||||
return SCREEN_HEIGHT - y - 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
@ -184,11 +184,11 @@ uint16_t tpReadY(void) {
|
|||
case portrait:
|
||||
return y;
|
||||
case landscape:
|
||||
return x;
|
||||
return SCREEN_WIDTH - x - 1;
|
||||
case portraitInv:
|
||||
return SCREEN_HEIGHT - y;
|
||||
return SCREEN_HEIGHT - y - 1;
|
||||
case landscapeInv:
|
||||
return SCREEN_WIDTH - x;
|
||||
return x;
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
Loading…
Add table
Reference in a new issue