mirror of
https://github.com/bsnes-emu/bsnes.git
synced 2025-08-11 17:53:58 +02:00
Update to v106r26 release.
byuu says: Changelog: - nall: added -static-libgcc -static-libstdc++ to Windows/GCC link flags - bsnes, higan: added program icons to main window when game isn't loaded - bsnes: improved recent games menu sorting - bsnes: fixed multi-game recent game loading on Windows - bsnes: completed path override support - bsnes, higan: added screensaver suppression on Windows - icarus: add 32K volatile RAM to SuperFX boards that report no RAM (fixes Starfox) - bsnes, higan: added automatic dependency generation [Talarubi] - hiro/GTK: appending actions to menus restores enabled() state - higan: use board node inside manifest.bml if it exists - bsnes: added blur emulation and color emulation options to view menu - ruby: upgraded input.sdl to SDL 2.0 (though it makes no functional difference sadly) - ruby: removed video.sdl (due to deprecating SDL 1.2) - nall, ruby: improvements to HID class (generic vendor and product IDs) Errata: - bsnes, higan: on Windows, Application::Windows::onScreenSaver needs `[&]` lambda capture, not `[]` - find it in presentation/presentation.cpp
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
#ifndef RUBY_INPUT_MOUSE_XLIB
|
||||
#define RUBY_INPUT_MOUSE_XLIB
|
||||
#pragma once
|
||||
|
||||
struct InputMouseXlib {
|
||||
Input& input;
|
||||
@@ -12,16 +11,16 @@ struct InputMouseXlib {
|
||||
Display* display = nullptr;
|
||||
Window rootWindow = 0;
|
||||
Cursor invisibleCursor = 0;
|
||||
unsigned screenWidth = 0;
|
||||
unsigned screenHeight = 0;
|
||||
uint screenWidth = 0;
|
||||
uint screenHeight = 0;
|
||||
|
||||
struct Mouse {
|
||||
bool acquired = false;
|
||||
signed numerator = 0;
|
||||
signed denominator = 0;
|
||||
signed threshold = 0;
|
||||
unsigned relativeX = 0;
|
||||
unsigned relativeY = 0;
|
||||
int numerator = 0;
|
||||
int denominator = 0;
|
||||
int threshold = 0;
|
||||
uint relativeX = 0;
|
||||
uint relativeY = 0;
|
||||
} ms;
|
||||
|
||||
auto acquired() -> bool {
|
||||
@@ -57,7 +56,7 @@ struct InputMouseXlib {
|
||||
return true;
|
||||
}
|
||||
|
||||
auto assign(unsigned groupID, unsigned inputID, int16_t value) -> void {
|
||||
auto assign(uint groupID, uint inputID, int16_t value) -> void {
|
||||
auto& group = hid->group(groupID);
|
||||
if(group.input(inputID).value() == value) return;
|
||||
input.doChange(hid, groupID, inputID, group.input(inputID).value(), value);
|
||||
@@ -67,11 +66,11 @@ struct InputMouseXlib {
|
||||
auto poll(vector<shared_pointer<HID::Device>>& devices) -> void {
|
||||
Window rootReturn;
|
||||
Window childReturn;
|
||||
signed rootXReturn = 0;
|
||||
signed rootYReturn = 0;
|
||||
signed windowXReturn = 0;
|
||||
signed windowYReturn = 0;
|
||||
unsigned maskReturn = 0;
|
||||
int rootXReturn = 0;
|
||||
int rootYReturn = 0;
|
||||
int windowXReturn = 0;
|
||||
int windowYReturn = 0;
|
||||
uint maskReturn = 0;
|
||||
XQueryPointer(display, handle, &rootReturn, &childReturn, &rootXReturn, &rootYReturn, &windowXReturn, &windowYReturn, &maskReturn);
|
||||
|
||||
if(acquired()) {
|
||||
@@ -132,7 +131,9 @@ struct InputMouseXlib {
|
||||
ms.relativeX = 0;
|
||||
ms.relativeY = 0;
|
||||
|
||||
hid->setID(2);
|
||||
hid->setVendorID(HID::Mouse::GenericVendorID);
|
||||
hid->setProductID(HID::Mouse::GenericProductID);
|
||||
hid->setPathID(0);
|
||||
|
||||
hid->axes().append("X");
|
||||
hid->axes().append("Y");
|
||||
@@ -158,5 +159,3 @@ struct InputMouseXlib {
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user