mirror of
https://github.com/libretro/ppsspp.git
synced 2025-02-24 02:40:43 +00:00
Add skeleton code for Windows multitouch, to be filled in by someone who can test :P
This commit is contained in:
parent
2347bc877a
commit
98daf18d56
@ -531,7 +531,6 @@ void GPUCommon::ExecuteOp(u32 op, u32 diff) {
|
||||
auto &stackEntry = currentList->stack[--currentList->stackptr];
|
||||
gstate_c.offsetAddr = stackEntry.offsetAddr;
|
||||
u32 target = (currentList->pc & 0xF0000000) | (stackEntry.pc & 0x0FFFFFFF);
|
||||
//target = (target + gstate_c.originAddr) & 0xFFFFFFF;
|
||||
UpdateCycles(currentList->pc, target - 4);
|
||||
currentList->pc = target - 4;
|
||||
if (!Memory::IsValidAddress(currentList->pc)) {
|
||||
|
@ -685,6 +685,7 @@ static const char * credits[] = {
|
||||
"soywiz",
|
||||
"kovensky",
|
||||
"xele",
|
||||
"cinaera",
|
||||
"",
|
||||
"Written in C++ for speed and portability",
|
||||
"",
|
||||
|
@ -38,6 +38,8 @@
|
||||
#include "XPTheme.h"
|
||||
#endif
|
||||
|
||||
#define ENABLE_TOUCH 0
|
||||
|
||||
static BOOL g_bFullScreen = FALSE;
|
||||
static RECT g_normalRC = {0};
|
||||
|
||||
@ -209,6 +211,10 @@ namespace MainWindow
|
||||
//accept dragged files
|
||||
DragAcceptFiles(hwndMain, TRUE);
|
||||
|
||||
#if ENABLE_TOUCH
|
||||
RegisterTouchWindow(hwndDisplay, TWF_WANTPALM);
|
||||
#endif
|
||||
|
||||
SetFocus(hwndMain);
|
||||
|
||||
return TRUE;
|
||||
@ -304,6 +310,38 @@ namespace MainWindow
|
||||
}
|
||||
break;
|
||||
|
||||
case WM_TOUCH:
|
||||
{
|
||||
// TODO: Enabling this section will probably break things on Windows XP.
|
||||
// We probably need to manually fetch pointers to GetTouchInputInfo and CloseTouchInputHandle.
|
||||
#if ENABLE_TOUCH
|
||||
UINT inputCount = LOWORD(wParam);
|
||||
TOUCHINPUT *inputs = new TOUCHINPUT[inputCount];
|
||||
if (GetTouchInputInfo((HTOUCHINPUT)lParam,
|
||||
inputCount,
|
||||
inputs,
|
||||
sizeof(TOUCHINPUT)))
|
||||
{
|
||||
for (int i = 0; i < inputCount; i++) {
|
||||
// TODO: process inputs here!
|
||||
|
||||
}
|
||||
|
||||
if (!CloseTouchInputHandle((HTOUCHINPUT)lParam))
|
||||
{
|
||||
// error handling
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// GetLastError() and error handling
|
||||
}
|
||||
delete [] inputs;
|
||||
return DefWindowProc(hWnd, message, wParam, lParam);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
case WM_PAINT:
|
||||
return DefWindowProc(hWnd, message, wParam, lParam);
|
||||
default:
|
||||
|
Loading…
x
Reference in New Issue
Block a user