mirror of
https://github.com/Maschell/hid_to_vpad.git
synced 2024-12-22 11:21:49 +01:00
Now you can disable the network controller. In some games (e.g. splatoon) the network thread causes disconnects. This will hopefully fix this
This commit is contained in:
parent
f7ccd7d58d
commit
c6ddfdc86f
@ -71,7 +71,7 @@ msgstr "Ajuda"
|
||||
msgid "Network Client"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:32
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:33
|
||||
msgid "Settings"
|
||||
msgstr ""
|
||||
|
||||
@ -247,22 +247,28 @@ msgstr "É de código aberto e pode encontrar aquí:"
|
||||
msgid "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:44
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
msgid "Language"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:49
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:51
|
||||
msgid "Rumble"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
#: src/menu/drc/content/ContentSettings.cpp:47
|
||||
#: src/menu/drc/content/ContentSettings.cpp:52
|
||||
msgid "Music"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:66
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:53
|
||||
#, fuzzy
|
||||
msgid "Network Controller"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:74
|
||||
msgid "<Default>"
|
||||
msgstr ""
|
||||
|
||||
|
@ -70,7 +70,7 @@ msgstr ""
|
||||
msgid "Network Client"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:32
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:33
|
||||
msgid "Settings"
|
||||
msgstr ""
|
||||
|
||||
@ -246,22 +246,27 @@ msgstr ""
|
||||
msgid "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:44
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
msgid "Language"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:49
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:51
|
||||
msgid "Rumble"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
#: src/menu/drc/content/ContentSettings.cpp:47
|
||||
#: src/menu/drc/content/ContentSettings.cpp:52
|
||||
msgid "Music"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:66
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:53
|
||||
msgid "Network Controller"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:74
|
||||
msgid "<Default>"
|
||||
msgstr ""
|
||||
|
||||
|
@ -70,7 +70,7 @@ msgstr "Aide"
|
||||
msgid "Network Client"
|
||||
msgstr "Client réseau"
|
||||
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:32
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:33
|
||||
msgid "Settings"
|
||||
msgstr "Paramètres"
|
||||
|
||||
@ -246,22 +246,28 @@ msgstr "Il est Open source et peut être trouvé ici: "
|
||||
msgid "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
msgstr "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:44
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
msgid "Language"
|
||||
msgstr "Langue"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:49
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:51
|
||||
msgid "Rumble"
|
||||
msgstr "Vibration"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
#: src/menu/drc/content/ContentSettings.cpp:47
|
||||
#: src/menu/drc/content/ContentSettings.cpp:52
|
||||
msgid "Music"
|
||||
msgstr "Musique"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:66
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:53
|
||||
#, fuzzy
|
||||
msgid "Network Controller"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:74
|
||||
msgid "<Default>"
|
||||
msgstr "<Défaut>"
|
||||
|
||||
|
@ -71,7 +71,7 @@ msgstr "Hilfe"
|
||||
msgid "Network Client"
|
||||
msgstr "Network Client"
|
||||
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:32
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:33
|
||||
msgid "Settings"
|
||||
msgstr "Einstellungen"
|
||||
|
||||
@ -247,22 +247,28 @@ msgstr "Es ist Open-Source und kann hier geladen werden:"
|
||||
msgid "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:44
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
msgid "Language"
|
||||
msgstr "Sprache"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:49
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:51
|
||||
msgid "Rumble"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
#: src/menu/drc/content/ContentSettings.cpp:47
|
||||
#: src/menu/drc/content/ContentSettings.cpp:52
|
||||
msgid "Music"
|
||||
msgstr "Musik"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:66
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:53
|
||||
#, fuzzy
|
||||
msgid "Network Controller"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:74
|
||||
msgid "<Default>"
|
||||
msgstr ""
|
||||
|
||||
|
@ -70,7 +70,7 @@ msgstr "Aiuto"
|
||||
msgid "Network Client"
|
||||
msgstr "Network Client"
|
||||
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:32
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:33
|
||||
msgid "Settings"
|
||||
msgstr "Impostazioni"
|
||||
|
||||
@ -246,22 +246,28 @@ msgstr "È open source e puoi trovarlo qui:"
|
||||
msgid "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
msgstr "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:44
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
msgid "Language"
|
||||
msgstr "Lingua"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:49
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:51
|
||||
msgid "Rumble"
|
||||
msgstr "Vibrazione"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
#: src/menu/drc/content/ContentSettings.cpp:47
|
||||
#: src/menu/drc/content/ContentSettings.cpp:52
|
||||
msgid "Music"
|
||||
msgstr "Musica"
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:66
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:53
|
||||
#, fuzzy
|
||||
msgid "Network Controller"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:74
|
||||
msgid "<Default>"
|
||||
msgstr "<Default>"
|
||||
|
||||
|
@ -71,7 +71,7 @@ msgstr "Ayuda"
|
||||
msgid "Network Client"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:32
|
||||
#: src/menu/drc/MenuListDRC.cpp:42 src/menu/drc/content/ContentSettings.cpp:33
|
||||
msgid "Settings"
|
||||
msgstr ""
|
||||
|
||||
@ -247,22 +247,28 @@ msgstr "Es de código abierto y puedes encontrarlo aquí:"
|
||||
msgid "https://github.com/QuarkTheAwesome/HIDtoVPADNetworkClient"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:44
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
msgid "Language"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:45
|
||||
#: src/menu/drc/content/ContentSettings.cpp:49
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:51
|
||||
msgid "Rumble"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:46
|
||||
#: src/menu/drc/content/ContentSettings.cpp:50
|
||||
#: src/menu/drc/content/ContentSettings.cpp:47
|
||||
#: src/menu/drc/content/ContentSettings.cpp:52
|
||||
msgid "Music"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:66
|
||||
#: src/menu/drc/content/ContentSettings.cpp:48
|
||||
#: src/menu/drc/content/ContentSettings.cpp:53
|
||||
#, fuzzy
|
||||
msgid "Network Controller"
|
||||
msgstr ""
|
||||
|
||||
#: src/menu/drc/content/ContentSettings.cpp:74
|
||||
msgid "<Default>"
|
||||
msgstr ""
|
||||
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit f8aa5558cdb6bf8a50da0cae0c340555994800a4
|
||||
Subproject commit 718ac61d77c076900a5e59c93892f94f9fe354a3
|
@ -106,6 +106,8 @@ extern "C" s32 Menu_Main(void){
|
||||
bool rumble = CSettings::instance()->getValueAsBool(CSettings::RumbleActivated);
|
||||
log_printf("Menu_Main (line %d): Setting rumble to: %d\n",__LINE__,rumble);
|
||||
ControllerPatcher::setRumbleActivated(rumble);
|
||||
bool networkController = CSettings::instance()->getValueAsBool(CSettings::NetworkControllerActivated);
|
||||
ControllerPatcher::setNetworkControllerActivated(networkController);
|
||||
log_printf("Menu_Main (line %d): Unmount SD\n",__LINE__);
|
||||
unmount_sd_fat("sd");
|
||||
log_printf("Menu_Main (line %d): Release memory\n",__LINE__);
|
||||
|
@ -27,6 +27,7 @@ ContentSettings::ContentSettings():ContentTemplate()
|
||||
, languageSelectBox("",NULL)
|
||||
, rumbleSwitch(CSettings::instance()->getValueAsBool(CSettings::RumbleActivated))
|
||||
, musicSwitch(CSettings::instance()->getValueAsBool(CSettings::MusicActivated))
|
||||
, networkControllerSwitch(CSettings::instance()->getValueAsBool(CSettings::NetworkControllerActivated))
|
||||
, buttonClickSound(Resources::GetSound("settings_click_2.mp3"))
|
||||
{
|
||||
headLine.setText(gettext("Settings"));
|
||||
@ -44,10 +45,12 @@ ContentSettings::ContentSettings():ContentTemplate()
|
||||
settings[gettext("Language")] = &languageSelectBox;
|
||||
settings[gettext("Rumble")] = &rumbleSwitch;
|
||||
settings[gettext("Music")] = &musicSwitch;
|
||||
settings[gettext("Network Controller")] = &networkControllerSwitch;
|
||||
|
||||
settingsOrder.push_back(gettext("Language"));
|
||||
settingsOrder.push_back(gettext("Rumble"));
|
||||
settingsOrder.push_back(gettext("Music"));
|
||||
settingsOrder.push_back(gettext("Network Controller"));
|
||||
|
||||
rumbleSwitch.setTrigger(&touchTrigger);
|
||||
rumbleSwitch.setTrigger(&wpadTouchTrigger);
|
||||
@ -59,6 +62,11 @@ ContentSettings::ContentSettings():ContentTemplate()
|
||||
musicSwitch.setSoundClick(buttonClickSound);
|
||||
musicSwitch.valueChanged.connect(this, &ContentSettings::OnMusicValueChanged);
|
||||
|
||||
networkControllerSwitch.setTrigger(&touchTrigger);
|
||||
networkControllerSwitch.setTrigger(&wpadTouchTrigger);
|
||||
networkControllerSwitch.setSoundClick(buttonClickSound);
|
||||
networkControllerSwitch.valueChanged.connect(this, &ContentSettings::OnNetworkControllerValueChanged);
|
||||
|
||||
DirList dirList(DEFAULT_LANG_PATH, LANGUAGE_FILE_EXT, DirList::Files);
|
||||
dirList.SortList();
|
||||
|
||||
@ -156,3 +164,13 @@ void ContentSettings::OnRumbleValueChanged(GuiToggle * toggle,bool value){
|
||||
bChanged = true;
|
||||
}
|
||||
|
||||
void ContentSettings::OnNetworkControllerValueChanged(GuiToggle * toggle,bool value){
|
||||
CSettings::setValueAsBool(CSettings::NetworkControllerActivated,value);
|
||||
ControllerPatcher::setNetworkControllerActivated(value);
|
||||
if(!value){
|
||||
ControllerPatcher::stopNetworkServer();
|
||||
}else{
|
||||
ControllerPatcher::startNetworkServer();
|
||||
}
|
||||
bChanged = true;
|
||||
}
|
||||
|
@ -40,6 +40,7 @@ private:
|
||||
GuiText headLine;
|
||||
GuiSwitch rumbleSwitch;
|
||||
GuiSwitch musicSwitch;
|
||||
GuiSwitch networkControllerSwitch;
|
||||
GuiSound *buttonClickSound;
|
||||
|
||||
std::map<std::string,GuiElement*> settings;
|
||||
@ -54,6 +55,7 @@ private:
|
||||
|
||||
void OnMusicValueChanged(GuiToggle * toggle,bool value);
|
||||
void OnRumbleValueChanged(GuiToggle * toggle,bool value);
|
||||
void OnNetworkControllerValueChanged(GuiToggle * toggle,bool value);
|
||||
|
||||
};
|
||||
|
||||
|
@ -72,6 +72,10 @@ void CSettings::SetDefault()
|
||||
settingsNames[MusicActivated] = "MusicActivated";
|
||||
settingsValues[MusicActivated].dataType = TypeBool;
|
||||
settingsValues[MusicActivated].ucValue = SETTING_ON;
|
||||
|
||||
settingsNames[NetworkControllerActivated] = "NetworkControllerActivated";
|
||||
settingsValues[NetworkControllerActivated].dataType = TypeBool;
|
||||
settingsValues[NetworkControllerActivated].ucValue = SETTING_ON;
|
||||
}
|
||||
|
||||
bool CSettings::Load(){
|
||||
|
@ -70,6 +70,7 @@ public:
|
||||
AppLanguage,
|
||||
RumbleActivated,
|
||||
MusicActivated,
|
||||
NetworkControllerActivated,
|
||||
MAX_VALUE
|
||||
};
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user