mirror of
https://github.com/hrydgard/ppsspp.git
synced 2024-11-22 21:09:52 +00:00
Fix some issues with clicking touch buttons using the mouse after the hover change.
Increase a buffer size.
This commit is contained in:
parent
305453b52d
commit
107bd01536
@ -122,7 +122,7 @@ bool Buffer::ReadAllWithProgress(int fd, int knownSize, RequestProgress *progres
|
|||||||
}
|
}
|
||||||
|
|
||||||
int Buffer::Read(int fd, size_t sz) {
|
int Buffer::Read(int fd, size_t sz) {
|
||||||
char buf[1024];
|
char buf[4096];
|
||||||
int retval;
|
int retval;
|
||||||
size_t received = 0;
|
size_t received = 0;
|
||||||
while ((retval = recv(fd, buf, std::min(sz, sizeof(buf)), MSG_NOSIGNAL)) > 0) {
|
while ((retval = recv(fd, buf, std::min(sz, sizeof(buf)), MSG_NOSIGNAL)) > 0) {
|
||||||
|
@ -107,10 +107,12 @@ bool MultiTouchButton::Touch(const TouchInput &input) {
|
|||||||
usedPointerMask |= 1 << input.id;
|
usedPointerMask |= 1 << input.id;
|
||||||
}
|
}
|
||||||
if (input.flags & TOUCH_MOVE) {
|
if (input.flags & TOUCH_MOVE) {
|
||||||
if (bounds_.Contains(input.x, input.y) && !(analogPointerMask & (1 << input.id)))
|
if (!(input.flags & TOUCH_MOUSE) || input.buttons) {
|
||||||
pointerDownMask_ |= 1 << input.id;
|
if (bounds_.Contains(input.x, input.y) && !(analogPointerMask & (1 << input.id)))
|
||||||
else
|
pointerDownMask_ |= 1 << input.id;
|
||||||
pointerDownMask_ &= ~(1 << input.id);
|
else
|
||||||
|
pointerDownMask_ &= ~(1 << input.id);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (input.flags & TOUCH_UP) {
|
if (input.flags & TOUCH_UP) {
|
||||||
pointerDownMask_ &= ~(1 << input.id);
|
pointerDownMask_ &= ~(1 << input.id);
|
||||||
@ -291,11 +293,13 @@ bool PSPDpad::Touch(const TouchInput &input) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (input.flags & TOUCH_MOVE) {
|
if (input.flags & TOUCH_MOVE) {
|
||||||
if (dragPointerId_ == -1 && bounds_.Contains(input.x, input.y) && !(analogPointerMask & (1 << input.id))) {
|
if (!(input.flags & TOUCH_MOUSE) || input.buttons) {
|
||||||
dragPointerId_ = input.id;
|
if (dragPointerId_ == -1 && bounds_.Contains(input.x, input.y) && !(analogPointerMask & (1 << input.id))) {
|
||||||
}
|
dragPointerId_ = input.id;
|
||||||
if (input.id == dragPointerId_) {
|
}
|
||||||
ProcessTouch(input.x, input.y, true);
|
if (input.id == dragPointerId_) {
|
||||||
|
ProcessTouch(input.x, input.y, true);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (input.flags & TOUCH_UP) {
|
if (input.flags & TOUCH_UP) {
|
||||||
|
Loading…
Reference in New Issue
Block a user