2015-03-02 09:13:28 +00:00
|
|
|
struct InputSettings : TabFrameItem {
|
|
|
|
InputSettings(TabFrame*);
|
|
|
|
auto activeEmulator() -> InputEmulator&;
|
|
|
|
auto activePort() -> InputPort&;
|
|
|
|
auto activeDevice() -> InputDevice&;
|
|
|
|
auto reloadPorts() -> void;
|
|
|
|
auto reloadDevices() -> void;
|
|
|
|
auto reloadMappings() -> void;
|
|
|
|
auto refreshMappings() -> void;
|
|
|
|
auto assignMapping() -> void;
|
|
|
|
auto inputEvent(HID::Device& device, unsigned group, unsigned input, int16 oldValue, int16 newValue) -> void;
|
|
|
|
|
|
|
|
InputMapping* activeMapping = nullptr;
|
|
|
|
|
|
|
|
VerticalLayout layout{this};
|
|
|
|
HorizontalLayout selectionLayout{&layout, Size{~0, 0}};
|
|
|
|
ComboButton emulatorList{&selectionLayout, Size{~0, 0}};
|
|
|
|
ComboButton portList{&selectionLayout, Size{~0, 0}};
|
|
|
|
ComboButton deviceList{&selectionLayout, Size{~0, 0}};
|
|
|
|
ListView mappingList{&layout, Size{~0, ~0}};
|
|
|
|
HorizontalLayout controlLayout{&layout, Size{~0, 0}};
|
|
|
|
Widget spacer{&controlLayout, Size{~0, 0}};
|
|
|
|
Button resetButton{&controlLayout, Size{80, 0}};
|
|
|
|
Button eraseButton{&controlLayout, Size{80, 0}};
|
|
|
|
};
|
|
|
|
|
2015-04-13 11:16:33 +00:00
|
|
|
struct HotkeySettings : TabFrameItem {
|
|
|
|
HotkeySettings(TabFrame*);
|
|
|
|
auto reloadMappings() -> void;
|
|
|
|
auto refreshMappings() -> void;
|
|
|
|
auto assignMapping() -> void;
|
|
|
|
auto inputEvent(HID::Device& device, unsigned group, unsigned input, int16 oldValue, int16 newValue) -> void;
|
|
|
|
|
|
|
|
InputMapping* activeMapping = nullptr;
|
|
|
|
|
|
|
|
VerticalLayout layout{this};
|
|
|
|
ListView mappingList{&layout, Size{~0, ~0}};
|
|
|
|
HorizontalLayout controlLayout{&layout, Size{~0, 0}};
|
|
|
|
Widget spacer{&controlLayout, Size{~0, 0}};
|
|
|
|
Button eraseButton{&controlLayout, Size{80, 0}};
|
|
|
|
};
|
|
|
|
|
2015-03-03 10:14:49 +00:00
|
|
|
struct AdvancedSettings : TabFrameItem {
|
|
|
|
AdvancedSettings(TabFrame*);
|
|
|
|
|
|
|
|
VerticalLayout layout{this};
|
Update to v094r13 release.
byuu says:
This version polishes up the input dialogue (reset, erase, disable
button when item not focused, split device ID from mapping name), adds
color emulation toggle, and add dummy menu items for remaining features
(to be filled in later.)
Also, it now compiles cleanly on Windows with GTK.
I didn't test with TDM-GCC-32, because for god knows what reason, the
32-bit version ships with headers from Windows 95 OSR2 only. So I built
with TDM-GCC-64 with arch=x86.
And uh, apparently, moving or resizing a window causes a Visual C++
runtime exception in the GTK+ DLLs. This doesn't happen with trance or
renshuu built with TDM-GCC-32. So, yeah, like I said, don't use -m32.
2015-03-07 10:21:47 +00:00
|
|
|
Label driverLabel{&layout, Size{~0, 0}, 2};
|
2015-03-03 10:14:49 +00:00
|
|
|
HorizontalLayout driverLayout{&layout, Size{~0, 0}};
|
|
|
|
Label videoLabel{&driverLayout, Size{0, 0}};
|
|
|
|
ComboButton videoDriver{&driverLayout, Size{~0, 0}};
|
|
|
|
Label audioLabel{&driverLayout, Size{0, 0}};
|
|
|
|
ComboButton audioDriver{&driverLayout, Size{~0, 0}};
|
|
|
|
Label inputLabel{&driverLayout, Size{0, 0}};
|
|
|
|
ComboButton inputDriver{&driverLayout, Size{~0, 0}};
|
|
|
|
};
|
|
|
|
|
2015-03-02 09:13:28 +00:00
|
|
|
struct SettingsManager : Window {
|
|
|
|
SettingsManager();
|
|
|
|
|
|
|
|
VerticalLayout layout{this};
|
|
|
|
TabFrame panelLayout{&layout, Size{~0, ~0}};
|
|
|
|
InputSettings input{&panelLayout};
|
2015-04-13 11:16:33 +00:00
|
|
|
HotkeySettings hotkeys{&panelLayout};
|
2015-03-03 10:14:49 +00:00
|
|
|
AdvancedSettings advanced{&panelLayout};
|
2015-03-02 09:13:28 +00:00
|
|
|
|
|
|
|
StatusBar statusBar{this};
|
|
|
|
};
|
|
|
|
|
|
|
|
extern SettingsManager* settingsManager;
|