mirror of
https://github.com/bsnes-emu/bsnes.git
synced 2025-08-09 07:06:29 +02:00
Update to v106r53 release.
byuu says: Okay, so the WIPs-within-WIPs thing wasn't achieving its desired effect, and it ended up causing me to have to redo some work on hiro since my last local snapshot was of r52. So, heck it. I'll just do mostly non-functional WIPs for a bit, and worry about the fallout years later when I'm trying to find an emulation regression and cursing that the WIPs aren't compiling. I ported all of the ruby input drivers to the new syntax, as well as the OpenAL driver. If you patch the ruby drivers for Linux with this in mind, bsnes should compile and run there again. Also, the bsnes program icon has returned, now that the new hiro layout code is mature enough and I can simply add and remove the icon as a Canvas instead of having to try and render into a viewport. The icon shows up instantly with the main window.
This commit is contained in:
@@ -1,11 +1,15 @@
|
||||
#include "keyboard/quartz.cpp"
|
||||
|
||||
struct InputQuartz : Input {
|
||||
InputQuartz() : _keyboard(*this) { initialize(); }
|
||||
struct InputQuartz : InputDriver {
|
||||
InputQuartz(Input& super) : InputDriver(super), keyboard(super) {}
|
||||
~InputQuartz() { terminate(); }
|
||||
|
||||
auto create() -> bool override {
|
||||
return initialize();
|
||||
}
|
||||
|
||||
auto driver() -> string override { return "Quartz"; }
|
||||
auto ready() -> bool override { return _ready; }
|
||||
auto ready() -> bool override { return isReady; }
|
||||
|
||||
auto acquired() -> bool override { return false; }
|
||||
auto acquire() -> bool override { return false; }
|
||||
@@ -13,7 +17,7 @@ struct InputQuartz : Input {
|
||||
|
||||
auto poll() -> vector<shared_pointer<HID::Device>> override {
|
||||
vector<shared_pointer<HID::Device>> devices;
|
||||
_keyboard.poll(devices);
|
||||
keyboard.poll(devices);
|
||||
return devices;
|
||||
}
|
||||
|
||||
@@ -24,16 +28,16 @@ struct InputQuartz : Input {
|
||||
private:
|
||||
auto initialize() -> bool {
|
||||
terminate();
|
||||
if(!_keyboard.initialize()) return false;
|
||||
if(!keyboard.initialize()) return false;
|
||||
return _ready = true;
|
||||
}
|
||||
|
||||
auto terminate() -> void {
|
||||
_ready = false;
|
||||
_keyboard.terminate();
|
||||
isReady = false;
|
||||
keyboard.terminate();
|
||||
}
|
||||
|
||||
bool _ready = false;
|
||||
|
||||
InputKeyboardQuartz _keyboard;
|
||||
InputQuartz& self = *this;
|
||||
bool isReady = false;
|
||||
InputKeyboardQuartz keyboard;
|
||||
};
|
||||
|
Reference in New Issue
Block a user