Fix weird keyboard problem

This commit is contained in:
Dees_Troy
2012-10-15 15:56:10 -04:00
parent 31a5143ae3
commit 0cb64e5b23
2 changed files with 4 additions and 4 deletions
+3 -3
View File
@@ -323,7 +323,7 @@ int GUIKeyboard::SetRenderPos(int x, int y, int w, int h)
int GUIKeyboard::GetSelection(int x, int y)
{
if (x < mRenderX || x - mRenderX > mRenderW || y < mRenderY || y - mRenderY > mRenderH) return -1;
if (x < mRenderX || x - mRenderX > KeyboardWidth || y < mRenderY || y - mRenderY > KeyboardHeight) return -1;
return 0;
}
@@ -368,10 +368,10 @@ int GUIKeyboard::NotifyTouch(TOUCH_STATE state, int x, int y)
case TOUCH_DRAG:
break;
case TOUCH_RELEASE:
if (x < startX - (mRenderW * 0.5)) {
if (x < startX - (KeyboardWidth * 0.5)) {
PageManager::NotifyKeyboard(KEYBOARD_SWIPE_LEFT);
return 0;
} else if (x > startX + (mRenderW * 0.5)) {
} else if (x > startX + (KeyboardWidth * 0.5)) {
PageManager::NotifyKeyboard(KEYBOARD_SWIPE_RIGHT);
return 0;
}
+1 -1
View File
@@ -17,7 +17,7 @@
#ifndef _VARIABLES_HEADER_
#define _VARIABLES_HEADER_
#define TW_VERSION_STR "2.3.1.0"
#define TW_VERSION_STR "2.3.1.1"
#define TW_USE_COMPRESSION_VAR "tw_use_compression"
#define TW_IGNORE_IMAGE_SIZE "tw_ignore_image_size"