From a8936b005461dc5fc41863908ecb536a34d30b8b Mon Sep 17 00:00:00 2001 From: "ardi@ist-einmalig.de" Date: Sat, 24 Oct 2009 22:03:12 +0000 Subject: [PATCH] * little stuff in FreeTypeGX * changes is setting-dialogs - Update the Gui-Texts only if is needed - alls stuff for an option in one code-block this makes it easier to add, move or remove an option * customoptionbrowser-stuff --- Languages/czech.lang | 47 +- Languages/danish.lang | 47 +- Languages/dutch.lang | 47 +- Languages/english.lang | 26 +- Languages/finnish.lang | 47 +- Languages/french.lang | 50 +- Languages/german.lang | 47 +- Languages/hungarian.lang | 47 +- Languages/italian.lang | 47 +- Languages/japanese.lang | 47 +- Languages/korean.lang | 47 +- Languages/norwegian.lang | 47 +- Languages/polish.lang | 47 +- Languages/portuguese_br.lang | 47 +- Languages/portuguese_pt.lang | 47 +- Languages/russian.lang | 41 +- Languages/schinese.lang | 47 +- Languages/spanish.lang | 47 +- Languages/swedish.lang | 47 +- Languages/tchinese.lang | 47 +- Languages/thai.lang | 47 +- Languages/turkish.lang | 47 +- source/FreeTypeGX.cpp | 12 +- source/FreeTypeGX.h | 3 +- source/cheats/cheatmenu.cpp | 205 +- source/libwiigui/gui_customoptionbrowser.cpp | 241 +- source/libwiigui/gui_customoptionbrowser.h | 9 +- source/menu.cpp | 4 +- source/settings/Settings.cpp | 5194 +++++++++--------- source/settings/cfg.h | 457 +- 30 files changed, 3641 insertions(+), 3494 deletions(-) diff --git a/Languages/czech.lang b/Languages/czech.lang index d3bcab5a..cea913e2 100644 --- a/Languages/czech.lang +++ b/Languages/czech.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: David Jelinek (djelinek@hotmail.com) \n" "Language-Team: r719 - last version on http://volny.cz/djelinek/_USBLoderGX/czech.lang \n" @@ -297,9 +297,6 @@ msgstr "Nelze nastavit USB" msgid "Cover Download" msgstr "Stažení obalu" -msgid "Cover Path Change" -msgstr "Zmena cesty k obalom" - msgid "Cover Path Changed" msgstr "Cesta k obalum zmenena" @@ -318,9 +315,6 @@ msgstr "Upravené/Originál" msgid "DOL Path" msgstr "Cesta k DOL" -msgid "DOL path change" -msgstr "Zmena cesty k DOL" - msgid "DOL path changed" msgstr "Cesta k DOL zmenena" @@ -378,9 +372,6 @@ msgstr "Potisky DVD" msgid "Disc Path Changed" msgstr "Cesta k diskum zmenena" -msgid "Disc Path change" -msgstr "Zmena cesty k diskum" - msgid "DiskFlip" msgstr "" @@ -576,9 +567,6 @@ msgstr "Hlavní menu" msgid "Homebrew Apps Path" msgstr "Cesta pro Homebrew aplikace" -msgid "Homebrew Appspath change" -msgstr "Zmenit cestu pro Homebrew aplikace" - msgid "Homebrew Appspath changed" msgstr "Cesta pro Homebrew aplikace zmenena" @@ -921,9 +909,6 @@ msgstr "Vibrace" msgid "SChinese" msgstr "Cínsky" -msgid "SD/USB selected" -msgstr "SD/USB vybrána" - msgid "SFX Volume" msgstr "Hlasitost SFX" @@ -1036,9 +1021,6 @@ msgstr "Instalace WAD souboru selhala s chybou %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Cesta ke skinum" msgid "Theme Path Changed" msgstr "Cesta ke skinum zmenena" -msgid "Theme Path change" -msgstr "Zmena cesty ke skinum" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB Soubory" msgid "WiiTDB Path" msgstr "Cesta k WiiTDB" -msgid "WiiTDB Path change" -msgstr "Zmenit cestu k WiiTDB" - msgid "WiiTDB Path changed." msgstr "Cesta k WiiTDB zmenena" @@ -1276,5 +1252,26 @@ msgstr "z " msgid "seconds left" msgstr "sekund zbývá" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB vybrána" + +#~ msgid "Cover Path Change" +#~ msgstr "Zmena cesty k obalom" + +#~ msgid "DOL path change" +#~ msgstr "Zmena cesty k DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Zmena cesty k diskum" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Zmenit cestu pro Homebrew aplikace" + +#~ msgid "Theme Path change" +#~ msgstr "Zmena cesty ke skinum" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Zmenit cestu k WiiTDB" + #~ msgid "Homebrew Channel" #~ msgstr "Homebrew kanál" diff --git a/Languages/danish.lang b/Languages/danish.lang index 6c95d34c..fbbbe6f2 100644 --- a/Languages/danish.lang +++ b/Languages/danish.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: dorf[dk]\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "Kunne ikke sætte USB." msgid "Cover Download" msgstr "Cover-download" -msgid "Cover Path Change" -msgstr "Ændringer af sti til covers" - msgid "Cover Path Changed" msgstr "Sti til covers ændret" @@ -318,9 +315,6 @@ msgstr "Tilpassede/Originale" msgid "DOL Path" msgstr "Stil til DOL" -msgid "DOL path change" -msgstr "Ændringer af sti til DOL" - msgid "DOL path changed" msgstr "Sti til DOL ændret" @@ -378,9 +372,6 @@ msgstr "DVD-billeder" msgid "Disc Path Changed" msgstr "Sti til DVD-billeder" -msgid "Disc Path change" -msgstr "Ændringer til DVD-sti" - msgid "DiskFlip" msgstr "" @@ -576,9 +567,6 @@ msgstr "" msgid "Homebrew Apps Path" msgstr "Sti til homebrew-programmer" -msgid "Homebrew Appspath change" -msgstr "Ændringer af sti til homebrew-programmer" - msgid "Homebrew Appspath changed" msgstr "Sti til homebrew-programmer ændret" @@ -921,9 +909,6 @@ msgstr "Vibration" msgid "SChinese" msgstr "Kinesisk (std.)" -msgid "SD/USB selected" -msgstr "SD/USB er valgt" - msgid "SFX Volume" msgstr "Lydstyrke for effekter" @@ -1036,9 +1021,6 @@ msgstr "WAD-installationen mislykkedes med fejl %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Sti til temaer" msgid "Theme Path Changed" msgstr "Sti til temaer ændret" -msgid "Theme Path change" -msgstr "Ændringer af sti til temaer" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB-filer" msgid "WiiTDB Path" msgstr "Sti til WiiTDB" -msgid "WiiTDB Path change" -msgstr "Ændringer af sti til WiiTDB" - msgid "WiiTDB Path changed." msgstr "Sti til WiiTDB ændret" @@ -1275,3 +1251,24 @@ msgstr "af" msgid "seconds left" msgstr "sekunder tilbage" + +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB er valgt" + +#~ msgid "Cover Path Change" +#~ msgstr "Ændringer af sti til covers" + +#~ msgid "DOL path change" +#~ msgstr "Ændringer af sti til DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Ændringer til DVD-sti" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Ændringer af sti til homebrew-programmer" + +#~ msgid "Theme Path change" +#~ msgstr "Ændringer af sti til temaer" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Ændringer af sti til WiiTDB" diff --git a/Languages/dutch.lang b/Languages/dutch.lang index 60e24d78..ad5cddd4 100644 --- a/Languages/dutch.lang +++ b/Languages/dutch.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: tj_cool\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "Kan USB niet instellen" msgid "Cover Download" msgstr "Download hoesjes" -msgid "Cover Path Change" -msgstr "Hoesjesmap wijzigen" - msgid "Cover Path Changed" msgstr "Locatie hoesjes gewijzigd" @@ -318,9 +315,6 @@ msgstr "Aangepast/Origineel" msgid "DOL Path" msgstr "Locatie DOL" -msgid "DOL path change" -msgstr "Locatie DOL wijzigen" - msgid "DOL path changed" msgstr "Locatie DOL gewijzigd" @@ -378,9 +372,6 @@ msgstr "DVD labels" msgid "Disc Path Changed" msgstr "Locatie DVD labels gewijzigd" -msgid "Disc Path change" -msgstr "Locatie DVD labels wijzigen" - msgid "DiskFlip" msgstr "DVDFlip" @@ -576,9 +567,6 @@ msgstr "" msgid "Homebrew Apps Path" msgstr "Locatie Homebrew apps" -msgid "Homebrew Appspath change" -msgstr "Locatie HB apps wijzigen" - msgid "Homebrew Appspath changed" msgstr "Locatie HB apps gewijzigd" @@ -921,9 +909,6 @@ msgstr "Trilfunctie" msgid "SChinese" msgstr "SChinees" -msgid "SD/USB selected" -msgstr "SD/USB geselecteerd" - msgid "SFX Volume" msgstr "Volume effecten" @@ -1036,9 +1021,6 @@ msgstr "De wad installatie is mislukt met error %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Locatie thema" msgid "Theme Path Changed" msgstr "Locatie thema gewijzigd" -msgid "Theme Path change" -msgstr "Locatie thema wijzigen" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB" msgid "WiiTDB Path" msgstr "Locatie WiiTDB" -msgid "WiiTDB Path change" -msgstr "Locatie WiiTDB wijzigen" - msgid "WiiTDB Path changed." msgstr "Locatie WiiTDB gewijzigd" @@ -1276,6 +1252,27 @@ msgstr "van" msgid "seconds left" msgstr "seconden over:" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB geselecteerd" + +#~ msgid "Cover Path Change" +#~ msgstr "Hoesjesmap wijzigen" + +#~ msgid "DOL path change" +#~ msgstr "Locatie DOL wijzigen" + +#~ msgid "Disc Path change" +#~ msgstr "Locatie DVD labels wijzigen" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Locatie HB apps wijzigen" + +#~ msgid "Theme Path change" +#~ msgstr "Locatie thema wijzigen" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Locatie WiiTDB wijzigen" + #~ msgid "Homebrew Channel" #~ msgstr "Homebrew Kanaal" diff --git a/Languages/english.lang b/Languages/english.lang index 7b4801b4..15862bda 100644 --- a/Languages/english.lang +++ b/Languages/english.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: \n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "" msgid "Cover Download" msgstr "" -msgid "Cover Path Change" -msgstr "" - msgid "Cover Path Changed" msgstr "" @@ -318,9 +315,6 @@ msgstr "" msgid "DOL Path" msgstr "" -msgid "DOL path change" -msgstr "" - msgid "DOL path changed" msgstr "" @@ -378,9 +372,6 @@ msgstr "" msgid "Disc Path Changed" msgstr "" -msgid "Disc Path change" -msgstr "" - msgid "DiskFlip" msgstr "" @@ -576,9 +567,6 @@ msgstr "" msgid "Homebrew Apps Path" msgstr "" -msgid "Homebrew Appspath change" -msgstr "" - msgid "Homebrew Appspath changed" msgstr "" @@ -921,9 +909,6 @@ msgstr "" msgid "SChinese" msgstr "" -msgid "SD/USB selected" -msgstr "" - msgid "SFX Volume" msgstr "" @@ -1036,9 +1021,6 @@ msgstr "" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "" msgid "Theme Path Changed" msgstr "" -msgid "Theme Path change" -msgstr "" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "" msgid "WiiTDB Path" msgstr "" -msgid "WiiTDB Path change" -msgstr "" - msgid "WiiTDB Path changed." msgstr "" diff --git a/Languages/finnish.lang b/Languages/finnish.lang index 08f0141c..feefa35c 100644 --- a/Languages/finnish.lang +++ b/Languages/finnish.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: c64rmx\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "USB:tä ei voitu asettaa" msgid "Cover Download" msgstr "Kansien lataus" -msgid "Cover Path Change" -msgstr "Kansipolun vaihto" - msgid "Cover Path Changed" msgstr "Kansien polku muutettu" @@ -318,9 +315,6 @@ msgstr "Omat/Alkuperäiset" msgid "DOL Path" msgstr "DOL:in polku" -msgid "DOL path change" -msgstr "DOL:in polun muutto" - msgid "DOL path changed" msgstr "DOL:in polku muutettu" @@ -378,9 +372,6 @@ msgstr "Levykuvat" msgid "Disc Path Changed" msgstr "Levykuvien polku muutettu" -msgid "Disc Path change" -msgstr "Levykuvien polku" - msgid "DiskFlip" msgstr "Levynvaihto" @@ -576,9 +567,6 @@ msgstr "" msgid "Homebrew Apps Path" msgstr "Homebrew Apps polku" -msgid "Homebrew Appspath change" -msgstr "Homebrew Apps polunvaihto" - msgid "Homebrew Appspath changed" msgstr "Homebrew Apps polku vaihdettu" @@ -921,9 +909,6 @@ msgstr "Värinä" msgid "SChinese" msgstr "SKiina" -msgid "SD/USB selected" -msgstr "SD/USB valittu" - msgid "SFX Volume" msgstr "Ääniefektien voimakkuus" @@ -1036,9 +1021,6 @@ msgstr "Wad asennus epäonnistui: %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Teeman sijainti" msgid "Theme Path Changed" msgstr "Teeman sijainti muutettu" -msgid "Theme Path change" -msgstr "Teeman sijainti" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB tiedostot" msgid "WiiTDB Path" msgstr "WiiTDB polku" -msgid "WiiTDB Path change" -msgstr "WiiTDB polun muutto" - msgid "WiiTDB Path changed." msgstr "WiiTDB polku muutettu" @@ -1275,3 +1251,24 @@ msgstr "josta" msgid "seconds left" msgstr "sekuntia jäljellä" + +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB valittu" + +#~ msgid "Cover Path Change" +#~ msgstr "Kansipolun vaihto" + +#~ msgid "DOL path change" +#~ msgstr "DOL:in polun muutto" + +#~ msgid "Disc Path change" +#~ msgstr "Levykuvien polku" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Homebrew Apps polunvaihto" + +#~ msgid "Theme Path change" +#~ msgstr "Teeman sijainti" + +#~ msgid "WiiTDB Path change" +#~ msgstr "WiiTDB polun muutto" diff --git a/Languages/french.lang b/Languages/french.lang index 3ba2c970..9f446bec 100644 --- a/Languages/french.lang +++ b/Languages/french.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: Kin8\n" "Language-Team: Badablek, Amour, ikya, dj_skual & Kin8\n" @@ -297,9 +297,6 @@ msgstr "Accès USB impossible." msgid "Cover Download" msgstr "Téléchargement Jaquettes" -msgid "Cover Path Change" -msgstr "Dossier des jaquettes" - msgid "Cover Path Changed" msgstr "Dossier des jaquettes modifié" @@ -318,9 +315,6 @@ msgstr "Persos/Originaux" msgid "DOL Path" msgstr "Dossier DOL Alternatif" -msgid "DOL path change" -msgstr "Dossier du DOL alternatif" - msgid "DOL path changed" msgstr "Dossier DOL alternatif modifié" @@ -378,9 +372,6 @@ msgstr "Labels DVD" msgid "Disc Path Changed" msgstr "Dossier des labels DVD modifié" -msgid "Disc Path change" -msgstr "Dossier des labels DVD" - msgid "DiskFlip" msgstr "Inversion Disque" @@ -576,9 +567,6 @@ msgstr "Menu HOME" msgid "Homebrew Apps Path" msgstr "Dossier Homebrew Apps" -msgid "Homebrew Appspath change" -msgstr "Dossier Homebrew Apps" - msgid "Homebrew Appspath changed" msgstr "Dossier Homebrew Apps modifié" @@ -921,9 +909,6 @@ msgstr "Vibrations" msgid "SChinese" msgstr "Chinois simplifié" -msgid "SD/USB selected" -msgstr "SD/USB Sélectionné" - msgid "SFX Volume" msgstr "Volume SFX" @@ -1036,9 +1021,6 @@ msgstr "L'installation WAD a échoué avec erreur %ld" msgid "Theme Download Path" msgstr "Dossier Thèmes Téléch." -msgid "Theme Download Path change" -msgstr "Dossier des Thèmes Téléchargés" - msgid "Theme Download Path changed" msgstr "Dossier Thèmes Téléch. modifié" @@ -1051,9 +1033,6 @@ msgstr "Dossier Thème" msgid "Theme Path Changed" msgstr "Dossier du thème modifié" -msgid "Theme Path change" -msgstr "Dossier du thème" - msgid "Theme Title:" msgstr "Titre du Thème:" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB" msgid "WiiTDB Path" msgstr "Dossier WiiTDB" -msgid "WiiTDB Path change" -msgstr "Dossier de WiiTDB" - msgid "WiiTDB Path changed." msgstr "Dossier de WiiTDB modifié" @@ -1276,6 +1252,30 @@ msgstr "sur" msgid "seconds left" msgstr "secondes restantes" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB Sélectionné" + +#~ msgid "Cover Path Change" +#~ msgstr "Dossier des jaquettes" + +#~ msgid "DOL path change" +#~ msgstr "Dossier du DOL alternatif" + +#~ msgid "Disc Path change" +#~ msgstr "Dossier des labels DVD" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Dossier Homebrew Apps" + +#~ msgid "Theme Download Path change" +#~ msgstr "Dossier des Thèmes Téléchargés" + +#~ msgid "Theme Path change" +#~ msgstr "Dossier du thème" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Dossier de WiiTDB" + #~ msgid "You need to start this game one time to create a save file, then exit and start it again." #~ msgstr "Vous devez lancer ce jeu une fois pour créer une sauvegarde, puis éteindre et le lancer à nouveau." diff --git a/Languages/german.lang b/Languages/german.lang index 1ac27fdd..03da49c1 100644 --- a/Languages/german.lang +++ b/Languages/german.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: Snoozer\n" "Language-Team: Snoozer, wishmasterf\n" @@ -297,9 +297,6 @@ msgstr "Konnte USB nicht setzen." msgid "Cover Download" msgstr "Cover Download" -msgid "Cover Path Change" -msgstr "Cover Pfad ändern" - msgid "Cover Path Changed" msgstr "Cover Pfad geändert" @@ -318,9 +315,6 @@ msgstr "Benutzerdefiniert/Original" msgid "DOL Path" msgstr "DOL Pfad" -msgid "DOL path change" -msgstr "DOL pfad änderung" - msgid "DOL path changed" msgstr "DOL pfad geändert" @@ -378,9 +372,6 @@ msgstr "Disk Cover" msgid "Disc Path Changed" msgstr "Disk Pfad geändert" -msgid "Disc Path change" -msgstr "Disk Pfad ändern" - msgid "DiskFlip" msgstr "" @@ -576,9 +567,6 @@ msgstr "HOME Menü" msgid "Homebrew Apps Path" msgstr "Homebrew Programmpfad" -msgid "Homebrew Appspath change" -msgstr "Homebrew Programmpfad Änderung" - msgid "Homebrew Appspath changed" msgstr "Homebrew Programmpfad geändert" @@ -921,9 +909,6 @@ msgstr "Vibration" msgid "SChinese" msgstr "Vereinfachtes Chinesisch" -msgid "SD/USB selected" -msgstr "SD/USB gewählt" - msgid "SFX Volume" msgstr "SFX Lautstärke" @@ -1036,9 +1021,6 @@ msgstr "Die wad Installation schlug fehl durch Fehler %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Theme Pfad" msgid "Theme Path Changed" msgstr "Theme Pfad geändert" -msgid "Theme Path change" -msgstr "Theme Pfad ändern" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB Dateien" msgid "WiiTDB Path" msgstr "WiiTDB Pfad" -msgid "WiiTDB Path change" -msgstr "WiiTDB Pfad ändern" - msgid "WiiTDB Path changed." msgstr "WiiTDB Pfad geändert." @@ -1276,6 +1252,27 @@ msgstr "von" msgid "seconds left" msgstr "Sekunden verbleiben" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB gewählt" + +#~ msgid "Cover Path Change" +#~ msgstr "Cover Pfad ändern" + +#~ msgid "DOL path change" +#~ msgstr "DOL pfad änderung" + +#~ msgid "Disc Path change" +#~ msgstr "Disk Pfad ändern" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Homebrew Programmpfad Änderung" + +#~ msgid "Theme Path change" +#~ msgstr "Theme Pfad ändern" + +#~ msgid "WiiTDB Path change" +#~ msgstr "WiiTDB Pfad ändern" + #~ msgid "Homebrew Channel" #~ msgstr "Homebrew Kanal" diff --git a/Languages/hungarian.lang b/Languages/hungarian.lang index 75a2bb2b..bc6891d1 100644 --- a/Languages/hungarian.lang +++ b/Languages/hungarian.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-15 14:20+0100\n" "Last-Translator: Springdale \n" "Language-Team: Tusk, Springdale\n" @@ -297,9 +297,6 @@ msgstr "USB beállítási hiba." msgid "Cover Download" msgstr "Boritó Letöltés" -msgid "Cover Path Change" -msgstr "Borító útvonal megváltoztatás" - msgid "Cover Path Changed" msgstr "Boritó Útvonala megváltozott" @@ -318,9 +315,6 @@ msgstr "Egyéni/Eredeti" msgid "DOL Path" msgstr "DOL útvonal" -msgid "DOL path change" -msgstr "DOL útvonal megváltoztatása" - msgid "DOL path changed" msgstr "DOL útvonal megváltozott" @@ -378,9 +372,6 @@ msgstr "Lemez Képek" msgid "Disc Path Changed" msgstr "Lemezképek Útvonala megváltoztatva" -msgid "Disc Path change" -msgstr "Lemezképek útvonalának megváltoztatása" - msgid "DiskFlip" msgstr "Lemezforgatás" @@ -576,9 +567,6 @@ msgstr "HOME Menû" msgid "Homebrew Apps Path" msgstr "Homebrew útvonal" -msgid "Homebrew Appspath change" -msgstr "Homebrew útvonal megváltoztatás" - msgid "Homebrew Appspath changed" msgstr "Homebrew útvonal megváltoztatva" @@ -921,9 +909,6 @@ msgstr "Rezgés" msgid "SChinese" msgstr "SKínai" -msgid "SD/USB selected" -msgstr "SD/USB kiválasztva" - msgid "SFX Volume" msgstr "Effekt Hangerõ" @@ -1036,9 +1021,6 @@ msgstr "A wad telepítés nem sikerült - hiba %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Témák Útvonala" msgid "Theme Path Changed" msgstr "Témák Útvonala megváltozott" -msgid "Theme Path change" -msgstr "Témák Útvonalának megváltoztatása" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB fájlok" msgid "WiiTDB Path" msgstr "WiiTDB útvonal" -msgid "WiiTDB Path change" -msgstr "WiiTDB útvonal vált." - msgid "WiiTDB Path changed." msgstr "WiiTDB útvonal megváltozott." @@ -1275,3 +1251,24 @@ msgstr "./" msgid "seconds left" msgstr "hátralévõ másodperc" + +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB kiválasztva" + +#~ msgid "Cover Path Change" +#~ msgstr "Borító útvonal megváltoztatás" + +#~ msgid "DOL path change" +#~ msgstr "DOL útvonal megváltoztatása" + +#~ msgid "Disc Path change" +#~ msgstr "Lemezképek útvonalának megváltoztatása" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Homebrew útvonal megváltoztatás" + +#~ msgid "Theme Path change" +#~ msgstr "Témák Útvonalának megváltoztatása" + +#~ msgid "WiiTDB Path change" +#~ msgstr "WiiTDB útvonal vált." diff --git a/Languages/italian.lang b/Languages/italian.lang index 16e33aeb..bf2f8b0b 100644 --- a/Languages/italian.lang +++ b/Languages/italian.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: Cambo \n" "Language-Team: FoxeJoe, Cambo\n" @@ -297,9 +297,6 @@ msgstr "Non è stato possibile impostare la porta USB." msgid "Cover Download" msgstr "Scaricamento Copertine" -msgid "Cover Path Change" -msgstr "Modifica Percorso Copertine" - msgid "Cover Path Changed" msgstr "Percorso Copertine Modificato" @@ -318,9 +315,6 @@ msgstr "Modific./Origin." msgid "DOL Path" msgstr "Percorso File DOL" -msgid "DOL path change" -msgstr "Modifica percorso file DOL" - msgid "DOL path changed" msgstr "Percorso File DOL Modificato" @@ -378,9 +372,6 @@ msgstr "Immagini Disco" msgid "Disc Path Changed" msgstr "Percorso Immagini Disco Modificato" -msgid "Disc Path change" -msgstr "Modifica Percorso Immagini Disco" - msgid "DiskFlip" msgstr "Gira i dischi" @@ -576,9 +567,6 @@ msgstr "Menu HOME" msgid "Homebrew Apps Path" msgstr "Percorso Applic. Homebrew" -msgid "Homebrew Appspath change" -msgstr "Modifica percorso app. Homebrew" - msgid "Homebrew Appspath changed" msgstr "Percorso app. Homebrew modificato" @@ -921,9 +909,6 @@ msgstr "Vibrazione" msgid "SChinese" msgstr "Cinese Moderno" -msgid "SD/USB selected" -msgstr "Selezionata SD/USB" - msgid "SFX Volume" msgstr "Volume SFX" @@ -1036,9 +1021,6 @@ msgstr "L'installazione del WAD è fallita con errore %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Percorso Tema" msgid "Theme Path Changed" msgstr "Percorso Tema modificato" -msgid "Theme Path change" -msgstr "Modifica Percorso Tema" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "File WiiTDB" msgid "WiiTDB Path" msgstr "Percorso Archivio WiiTDB" -msgid "WiiTDB Path change" -msgstr "Modifica percorso archivio WiiTDB" - msgid "WiiTDB Path changed." msgstr "Percorso archivio WiiTDB modificato." @@ -1276,6 +1252,27 @@ msgstr "di" msgid "seconds left" msgstr "secondi mancanti" +#~ msgid "SD/USB selected" +#~ msgstr "Selezionata SD/USB" + +#~ msgid "Cover Path Change" +#~ msgstr "Modifica Percorso Copertine" + +#~ msgid "DOL path change" +#~ msgstr "Modifica percorso file DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Modifica Percorso Immagini Disco" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Modifica percorso app. Homebrew" + +#~ msgid "Theme Path change" +#~ msgstr "Modifica Percorso Tema" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Modifica percorso archivio WiiTDB" + #~ msgid "Homebrew Channel" #~ msgstr "Canale Homebrew" diff --git a/Languages/japanese.lang b/Languages/japanese.lang index 84186ab4..8010a2cf 100644 --- a/Languages/japanese.lang +++ b/Languages/japanese.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: hosigumayuugi\n" "Language-Team: hosigumayuugi\n" @@ -297,9 +297,6 @@ msgstr "USBをセットできません" msgid "Cover Download" msgstr "どの画像をダウンロードしますか" -msgid "Cover Path Change" -msgstr "カバーのパスの変更" - msgid "Cover Path Changed" msgstr "カバーのパスを変更しました" @@ -318,9 +315,6 @@ msgstr "自作メイン" msgid "DOL Path" msgstr "DOLのパス" -msgid "DOL path change" -msgstr "DOLのパスの変更" - msgid "DOL path changed" msgstr "DOLのパスが変更されました" @@ -378,9 +372,6 @@ msgstr "ディスク画像" msgid "Disc Path Changed" msgstr "ディスク画像のパスを変更しました" -msgid "Disc Path change" -msgstr "ディスク画像のパスの変更" - msgid "DiskFlip" msgstr "ディスクの回転のように" @@ -576,9 +567,6 @@ msgstr "HOMEボタンメニュー" msgid "Homebrew Apps Path" msgstr "Homebrewのパス" -msgid "Homebrew Appspath change" -msgstr "Homebrewのパスの変更" - msgid "Homebrew Appspath changed" msgstr "Homebrewのパスを変更しました" @@ -921,9 +909,6 @@ msgstr "振動機能" msgid "SChinese" msgstr "簡体中国語" -msgid "SD/USB selected" -msgstr "SD/USBを選択" - msgid "SFX Volume" msgstr "効果音の音量" @@ -1036,9 +1021,6 @@ msgstr "WADのインストールはエラー:%ldで失敗しました" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "テーマのパス" msgid "Theme Path Changed" msgstr "テーマのパスを変更しました" -msgid "Theme Path change" -msgstr "テーマのパスの変更" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDBファイル" msgid "WiiTDB Path" msgstr "WiiTDBのパス" -msgid "WiiTDB Path change" -msgstr "WiiTDBのパスの変更" - msgid "WiiTDB Path changed." msgstr "WiiTDBのパスを変更しました." @@ -1276,5 +1252,26 @@ msgstr "中" msgid "seconds left" msgstr "完了までの秒数" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USBを選択" + +#~ msgid "Cover Path Change" +#~ msgstr "カバーのパスの変更" + +#~ msgid "DOL path change" +#~ msgstr "DOLのパスの変更" + +#~ msgid "Disc Path change" +#~ msgstr "ディスク画像のパスの変更" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Homebrewのパスの変更" + +#~ msgid "Theme Path change" +#~ msgstr "テーマのパスの変更" + +#~ msgid "WiiTDB Path change" +#~ msgstr "WiiTDBのパスの変更" + #~ msgid "Homebrew Channel" #~ msgstr "HBCへ" diff --git a/Languages/korean.lang b/Languages/korean.lang index 1589f13f..8c9a058b 100644 --- a/Languages/korean.lang +++ b/Languages/korean.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: nextos@korea.com\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "USB 를 설정할수 없음." msgid "Cover Download" msgstr "표지 다운로드" -msgid "Cover Path Change" -msgstr "커퍼경로 변경" - msgid "Cover Path Changed" msgstr "표지 경로 변경됨" @@ -318,9 +315,6 @@ msgstr "커스텀/오리지널" msgid "DOL Path" msgstr "DOL 패치" -msgid "DOL path change" -msgstr "DOL 경로 변겸" - msgid "DOL path changed" msgstr "DOL 경로 변경됨" @@ -378,9 +372,6 @@ msgstr "디스크 이미지" msgid "Disc Path Changed" msgstr "디스크 경로 변경됨" -msgid "Disc Path change" -msgstr "디스크 경로 변경" - msgid "DiskFlip" msgstr "디스크 플립" @@ -576,9 +567,6 @@ msgstr "HOME 메뉴" msgid "Homebrew Apps Path" msgstr "홈브류 경로" -msgid "Homebrew Appspath change" -msgstr "홈브류 경로 변경" - msgid "Homebrew Appspath changed" msgstr "홈브류 경로 변경됨" @@ -921,9 +909,6 @@ msgstr "진동" msgid "SChinese" msgstr "중국어(간체)" -msgid "SD/USB selected" -msgstr "SD/USB 선택됨" - msgid "SFX Volume" msgstr "SFX 볼륨" @@ -1036,9 +1021,6 @@ msgstr "WAD 인스톨 실패 에러 %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "테마 경로" msgid "Theme Path Changed" msgstr "테마 경로 변경됨" -msgid "Theme Path change" -msgstr "테마 경로 변경" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB 화일" msgid "WiiTDB Path" msgstr "WiiTDB경로" -msgid "WiiTDB Path change" -msgstr "WiiTDB경로 변경" - msgid "WiiTDB Path changed." msgstr "WiiTDB경로 변경됨." @@ -1276,5 +1252,26 @@ msgstr "중" msgid "seconds left" msgstr "초 남았습니다" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB 선택됨" + +#~ msgid "Cover Path Change" +#~ msgstr "커퍼경로 변경" + +#~ msgid "DOL path change" +#~ msgstr "DOL 경로 변겸" + +#~ msgid "Disc Path change" +#~ msgstr "디스크 경로 변경" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "홈브류 경로 변경" + +#~ msgid "Theme Path change" +#~ msgstr "테마 경로 변경" + +#~ msgid "WiiTDB Path change" +#~ msgstr "WiiTDB경로 변경" + #~ msgid "Homebrew Channel" #~ msgstr "홈브류 채널" diff --git a/Languages/norwegian.lang b/Languages/norwegian.lang index 8fa500b6..8d908a77 100644 --- a/Languages/norwegian.lang +++ b/Languages/norwegian.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: raschi\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "Kan ikke velge USB." msgid "Cover Download" msgstr "Cover nedlasting" -msgid "Cover Path Change" -msgstr "Endre cover sti" - msgid "Cover Path Changed" msgstr "Cover sti endret" @@ -318,9 +315,6 @@ msgstr "Custom/Original" msgid "DOL Path" msgstr "DOL sti" -msgid "DOL path change" -msgstr "Endre DOL sti" - msgid "DOL path changed" msgstr "DOL sti endret" @@ -378,9 +372,6 @@ msgstr "Plate bilder" msgid "Disc Path Changed" msgstr "Plate sti endret" -msgid "Disc Path change" -msgstr "Endre plate sti" - msgid "DiskFlip" msgstr "Snu plate" @@ -576,9 +567,6 @@ msgstr "HOME Meny" msgid "Homebrew Apps Path" msgstr "Homebrew Apps sti" -msgid "Homebrew Appspath change" -msgstr "Endre Homebrew Apps sti" - msgid "Homebrew Appspath changed" msgstr "Homebrew Apps sti endret" @@ -921,9 +909,6 @@ msgstr "Vibrasjon" msgid "SChinese" msgstr "S.Kinesisk" -msgid "SD/USB selected" -msgstr "SD/USB valgt" - msgid "SFX Volume" msgstr "Effekt volum" @@ -1036,9 +1021,6 @@ msgstr "WAD installasjonen feilet med feilkode %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Tema sti" msgid "Theme Path Changed" msgstr "Tema sti endret" -msgid "Theme Path change" -msgstr "Endre tema sti" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB filer" msgid "WiiTDB Path" msgstr "WiiTDB sti" -msgid "WiiTDB Path change" -msgstr "Endre WiiTDB sti" - msgid "WiiTDB Path changed." msgstr "WiiTDB sti endret." @@ -1276,6 +1252,27 @@ msgstr "av" msgid "seconds left" msgstr "sekunder gjenstår" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB valgt" + +#~ msgid "Cover Path Change" +#~ msgstr "Endre cover sti" + +#~ msgid "DOL path change" +#~ msgstr "Endre DOL sti" + +#~ msgid "Disc Path change" +#~ msgstr "Endre plate sti" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Endre Homebrew Apps sti" + +#~ msgid "Theme Path change" +#~ msgstr "Endre tema sti" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Endre WiiTDB sti" + #~ msgid "ERROR: USB device could not be loaded!" #~ msgstr "FEIL: USB enhet kan ikke lastes!" diff --git a/Languages/polish.lang b/Languages/polish.lang index cd855cb2..d3f67807 100644 --- a/Languages/polish.lang +++ b/Languages/polish.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: ziom666 (zadania_prog@vp.pl)\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "Nie mozna ustawic USB" msgid "Cover Download" msgstr "Pobierz okladki" -msgid "Cover Path Change" -msgstr "Zmien Sciezke okladek" - msgid "Cover Path Changed" msgstr "Sciezka do okladek zostala zmieniona" @@ -318,9 +315,6 @@ msgstr "" msgid "DOL Path" msgstr "Sciezka plikow .DOL" -msgid "DOL path change" -msgstr "Zmien sciezke plikow .DOL" - msgid "DOL path changed" msgstr "Zmieniono sciezke plikow .DOL" @@ -378,9 +372,6 @@ msgstr "Obrazki plyt" msgid "Disc Path Changed" msgstr "Sciezka do dysku zmieniona" -msgid "Disc Path change" -msgstr "Sciezka do plyt" - msgid "DiskFlip" msgstr "Obrot plytami" @@ -576,9 +567,6 @@ msgstr "Menu" msgid "Homebrew Apps Path" msgstr "Sciezka plikacji homebrew" -msgid "Homebrew Appspath change" -msgstr "Zmien Sciezke aplikacji homebrew" - msgid "Homebrew Appspath changed" msgstr "Sciezka aplikacji homebrew zmieniona" @@ -921,9 +909,6 @@ msgstr "Wibracje" msgid "SChinese" msgstr "uproszczony chinski" -msgid "SD/USB selected" -msgstr "Wybrano SD/USB" - msgid "SFX Volume" msgstr "Poziom glosnosci SFX" @@ -1036,9 +1021,6 @@ msgstr "Instalacja wad zakonczona bledek %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Sciezka skorek" msgid "Theme Path Changed" msgstr "Zmieniono sciezke skorek" -msgid "Theme Path change" -msgstr "Zmien sciezke skorek" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB" msgid "WiiTDB Path" msgstr "Sciezka WiiTDBPath" -msgid "WiiTDB Path change" -msgstr "Zmiana sciezki WiiTDBPath" - msgid "WiiTDB Path changed." msgstr "Sciezka WiiTDBPath zmieniona" @@ -1275,3 +1251,24 @@ msgstr "z" msgid "seconds left" msgstr "sekund pozostalo" + +#~ msgid "SD/USB selected" +#~ msgstr "Wybrano SD/USB" + +#~ msgid "Cover Path Change" +#~ msgstr "Zmien Sciezke okladek" + +#~ msgid "DOL path change" +#~ msgstr "Zmien sciezke plikow .DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Sciezka do plyt" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Zmien Sciezke aplikacji homebrew" + +#~ msgid "Theme Path change" +#~ msgstr "Zmien sciezke skorek" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Zmiana sciezki WiiTDBPath" diff --git a/Languages/portuguese_br.lang b/Languages/portuguese_br.lang index c9cfbbfd..6781157c 100644 --- a/Languages/portuguese_br.lang +++ b/Languages/portuguese_br.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: boto12\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "Não foi possível configurar a porta USB." msgid "Cover Download" msgstr "Download de Capas" -msgid "Cover Path Change" -msgstr "Alterar Pasta das Capas" - msgid "Cover Path Changed" msgstr "Pasta das Capas alterada" @@ -318,9 +315,6 @@ msgstr "Alternativas/Originais" msgid "DOL Path" msgstr "Pasta DOL" -msgid "DOL path change" -msgstr "Alterar Pasta do DOL" - msgid "DOL path changed" msgstr "Pasta do DOL alterada" @@ -378,9 +372,6 @@ msgstr "Imagens de Disco" msgid "Disc Path Changed" msgstr "Pasta das Imagens Disco alterada" -msgid "Disc Path change" -msgstr "Alterar a Pasta das Imagens de Disco" - msgid "DiskFlip" msgstr "Voltar Disco" @@ -576,9 +567,6 @@ msgstr "Menu Inicial" msgid "Homebrew Apps Path" msgstr "Pasta Apps Homebrew" -msgid "Homebrew Appspath change" -msgstr "Alterar Pasta Apps Homebrew" - msgid "Homebrew Appspath changed" msgstr "Pasta Apps Homebrew alterada" @@ -921,9 +909,6 @@ msgstr "Vibração" msgid "SChinese" msgstr "Chinês Simplificado" -msgid "SD/USB selected" -msgstr "SD/USB selecionado" - msgid "SFX Volume" msgstr "Volume dos Efeitos" @@ -1036,9 +1021,6 @@ msgstr "A instalação do wad falhou com o seguinte erro: %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Pasta Temas" msgid "Theme Path Changed" msgstr "Pasta dos Temas alterada" -msgid "Theme Path change" -msgstr "Alterar pasta dos Temas" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB" msgid "WiiTDB Path" msgstr "Pasta WiiTDB" -msgid "WiiTDB Path change" -msgstr "Alterar Pasta WiiTDB" - msgid "WiiTDB Path changed." msgstr "Pasta WiiTDB alterada." @@ -1276,5 +1252,26 @@ msgstr "de" msgid "seconds left" msgstr "segundos restantes" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB selecionado" + +#~ msgid "Cover Path Change" +#~ msgstr "Alterar Pasta das Capas" + +#~ msgid "DOL path change" +#~ msgstr "Alterar Pasta do DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Alterar a Pasta das Imagens de Disco" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Alterar Pasta Apps Homebrew" + +#~ msgid "Theme Path change" +#~ msgstr "Alterar pasta dos Temas" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Alterar Pasta WiiTDB" + #~ msgid "Homebrew Channel" #~ msgstr "Canal Homebrew" diff --git a/Languages/portuguese_pt.lang b/Languages/portuguese_pt.lang index 72301fd3..c18d2ec3 100644 --- a/Languages/portuguese_pt.lang +++ b/Languages/portuguese_pt.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-12 14:51+0000\n" "Last-Translator: Sky8000\n" "Language-Team: Sky8000 \n" @@ -297,9 +297,6 @@ msgstr "Não foi possível configurar a porta USB." msgid "Cover Download" msgstr "Download de Capas" -msgid "Cover Path Change" -msgstr "Alterar Pasta das Capas" - msgid "Cover Path Changed" msgstr "Pasta das Capas alterada" @@ -318,9 +315,6 @@ msgstr "Alternativas/Originais" msgid "DOL Path" msgstr "Pasta DOL" -msgid "DOL path change" -msgstr "Alterar Pasta DOL" - msgid "DOL path changed" msgstr "Pasta DOL alterada" @@ -378,9 +372,6 @@ msgstr "Imagens de Disco" msgid "Disc Path Changed" msgstr "Pasta das Imagens Disco Alterada" -msgid "Disc Path change" -msgstr "Alterar da Pasta das Imagens de Disco" - msgid "DiskFlip" msgstr "Voltar Disco" @@ -576,9 +567,6 @@ msgstr "Menú Inicial" msgid "Homebrew Apps Path" msgstr "Pasta Apps Homebrew" -msgid "Homebrew Appspath change" -msgstr "Alterar Pasta Apps Homebrew" - msgid "Homebrew Appspath changed" msgstr "Pasta Apps Homebrew alterada" @@ -921,9 +909,6 @@ msgstr "Vibração" msgid "SChinese" msgstr "Chinês Simplificado" -msgid "SD/USB selected" -msgstr "SD/USB seleccionado" - msgid "SFX Volume" msgstr "Volume Efeitos" @@ -1036,9 +1021,6 @@ msgstr "A instalação do wad falhou com o seguinte erro: %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Pasta Temas" msgid "Theme Path Changed" msgstr "Pasta dos Temas alterada" -msgid "Theme Path change" -msgstr "Alterar pasta dos Temas" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB" msgid "WiiTDB Path" msgstr "Pasta WiiTDB" -msgid "WiiTDB Path change" -msgstr "Alterar Pasta WiiTDB" - msgid "WiiTDB Path changed." msgstr "Pasta WiiTDB alterada." @@ -1276,5 +1252,26 @@ msgstr "de" msgid "seconds left" msgstr "segundos restantes" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB seleccionado" + +#~ msgid "Cover Path Change" +#~ msgstr "Alterar Pasta das Capas" + +#~ msgid "DOL path change" +#~ msgstr "Alterar Pasta DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Alterar da Pasta das Imagens de Disco" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Alterar Pasta Apps Homebrew" + +#~ msgid "Theme Path change" +#~ msgstr "Alterar pasta dos Temas" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Alterar Pasta WiiTDB" + #~ msgid "Homebrew Channel" #~ msgstr "Canal Homebrew" diff --git a/Languages/russian.lang b/Languages/russian.lang index 3b760eca..446ec1e2 100644 --- a/Languages/russian.lang +++ b/Languages/russian.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: Kir\n" "Language-Team: Kir\n" @@ -297,9 +297,6 @@ msgstr "Не могу настроить USB" msgid "Cover Download" msgstr "Скачать обложку" -msgid "Cover Path Change" -msgstr "Изменить путь к обложкам" - msgid "Cover Path Changed" msgstr "Путь к обложкам был изменен." @@ -318,9 +315,6 @@ msgstr "" msgid "DOL Path" msgstr "Путь к DOL" -msgid "DOL path change" -msgstr "Изменить путь к DOL" - msgid "DOL path changed" msgstr "Путь к DOL изменен" @@ -378,9 +372,6 @@ msgstr "Изображения дисков" msgid "Disc Path Changed" msgstr "Путь к изображениям дисков изменен" -msgid "Disc Path change" -msgstr "Изменить путь к изображениям дисков" - msgid "DiskFlip" msgstr "ДискФлип" @@ -576,9 +567,6 @@ msgstr "Домашнее Меню" msgid "Homebrew Apps Path" msgstr "Путь к хоумбрю-программам" -msgid "Homebrew Appspath change" -msgstr "Изменить путь к хоумбрю-программам" - msgid "Homebrew Appspath changed" msgstr "Путь к хоумбрю-программам изменен" @@ -921,9 +909,6 @@ msgstr "Вибрация" msgid "SChinese" msgstr "Упрощенный китайский" -msgid "SD/USB selected" -msgstr "" - msgid "SFX Volume" msgstr "Громкость эффектов" @@ -1036,9 +1021,6 @@ msgstr "Установка WAD не удалась, код ошибки %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Путь к темам" msgid "Theme Path Changed" msgstr "путь к темам изменён" -msgid "Theme Path change" -msgstr "изменить путь к темам" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "" msgid "WiiTDB Path" msgstr "" -msgid "WiiTDB Path change" -msgstr "" - msgid "WiiTDB Path changed." msgstr "" @@ -1275,3 +1251,18 @@ msgstr "из" msgid "seconds left" msgstr "секунд осталось" + +#~ msgid "Cover Path Change" +#~ msgstr "Изменить путь к обложкам" + +#~ msgid "DOL path change" +#~ msgstr "Изменить путь к DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Изменить путь к изображениям дисков" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Изменить путь к хоумбрю-программам" + +#~ msgid "Theme Path change" +#~ msgstr "изменить путь к темам" diff --git a/Languages/schinese.lang b/Languages/schinese.lang index 3f4af12b..5fed43c0 100644 --- a/Languages/schinese.lang +++ b/Languages/schinese.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: knife.hu kavid\n" "Language-Team: kavid\n" @@ -297,9 +297,6 @@ msgstr "无法设置 USB." msgid "Cover Download" msgstr "下载封面" -msgid "Cover Path Change" -msgstr "变更封面路径" - msgid "Cover Path Changed" msgstr "封面路径已变更" @@ -318,9 +315,6 @@ msgstr "自定义/官方" msgid "DOL Path" msgstr "DOL 路径" -msgid "DOL path change" -msgstr "变更 DOL 路径" - msgid "DOL path changed" msgstr "DOL 路径已变更" @@ -378,9 +372,6 @@ msgstr "光盘图片" msgid "Disc Path Changed" msgstr "光盘图片路径已变更" -msgid "Disc Path change" -msgstr "变更光盘图片路径" - msgid "DiskFlip" msgstr "光盘滑动" @@ -576,9 +567,6 @@ msgstr "主菜单" msgid "Homebrew Apps Path" msgstr "自制程序路径" -msgid "Homebrew Appspath change" -msgstr "变更自制程序路径" - msgid "Homebrew Appspath changed" msgstr "自制程序路径已变更" @@ -921,9 +909,6 @@ msgstr "震动" msgid "SChinese" msgstr "简体中文" -msgid "SD/USB selected" -msgstr "SD/USB 已选择" - msgid "SFX Volume" msgstr "SFX 音量" @@ -1036,9 +1021,6 @@ msgstr "WAD 安装失败,错误号 %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "主题路径" msgid "Theme Path Changed" msgstr "主题路径已变更" -msgid "Theme Path change" -msgstr "变更主题路径" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB 文件" msgid "WiiTDB Path" msgstr "WiiTDB 文件路径" -msgid "WiiTDB Path change" -msgstr "变更 WiiTDB 路径" - msgid "WiiTDB Path changed." msgstr "WiiTDB 路径已变更" @@ -1276,5 +1252,26 @@ msgstr "的" msgid "seconds left" msgstr "剩余秒数" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB 已选择" + +#~ msgid "Cover Path Change" +#~ msgstr "变更封面路径" + +#~ msgid "DOL path change" +#~ msgstr "变更 DOL 路径" + +#~ msgid "Disc Path change" +#~ msgstr "变更光盘图片路径" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "变更自制程序路径" + +#~ msgid "Theme Path change" +#~ msgstr "变更主题路径" + +#~ msgid "WiiTDB Path change" +#~ msgstr "变更 WiiTDB 路径" + #~ msgid "Homebrew Channel" #~ msgstr "Homebrew 频道" diff --git a/Languages/spanish.lang b/Languages/spanish.lang index fc76f0b1..abbfad01 100644 --- a/Languages/spanish.lang +++ b/Languages/spanish.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: Penn\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "No se pudo configurar USB." msgid "Cover Download" msgstr "Descarga de Carátulas" -msgid "Cover Path Change" -msgstr "Cambio ruta Carátulas" - msgid "Cover Path Changed" msgstr "Ruta de Carátulas cambiada" @@ -318,9 +315,6 @@ msgstr "Alternativas/Originales" msgid "DOL Path" msgstr "Ruta DOL" -msgid "DOL path change" -msgstr "Cambio ruta DOL" - msgid "DOL path changed" msgstr "Ruta de DOL cambiada" @@ -378,9 +372,6 @@ msgstr "Imágen Discos" msgid "Disc Path Changed" msgstr "Ruta Img. Disco cambiada" -msgid "Disc Path change" -msgstr "Cambio ruta Img. Disco" - msgid "DiskFlip" msgstr "GiroDisco" @@ -576,9 +567,6 @@ msgstr "Menú HOME" msgid "Homebrew Apps Path" msgstr "Ruta aplic. Homebrew" -msgid "Homebrew Appspath change" -msgstr "Cambio Ruta aplic. Homebrew" - msgid "Homebrew Appspath changed" msgstr "Ruta aplic. Homebrew cambiada" @@ -921,9 +909,6 @@ msgstr "Vibración" msgid "SChinese" msgstr "Chino Simplif." -msgid "SD/USB selected" -msgstr "SD/USB seleccionada" - msgid "SFX Volume" msgstr "Volumen SFX" @@ -1036,9 +1021,6 @@ msgstr "La instalación del wad falló con error %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Ruta del Tema" msgid "Theme Path Changed" msgstr "Ruta de Tema cambiada" -msgid "Theme Path change" -msgstr "Cambio Ruta de Tema" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB" msgid "WiiTDB Path" msgstr "Ruta WiiTDB" -msgid "WiiTDB Path change" -msgstr "Cambio ruta WiiTDB" - msgid "WiiTDB Path changed." msgstr "Ruta WiiTDB cambiada." @@ -1276,6 +1252,27 @@ msgstr "de" msgid "seconds left" msgstr "segundos restantes" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB seleccionada" + +#~ msgid "Cover Path Change" +#~ msgstr "Cambio ruta Carátulas" + +#~ msgid "DOL path change" +#~ msgstr "Cambio ruta DOL" + +#~ msgid "Disc Path change" +#~ msgstr "Cambio ruta Img. Disco" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Cambio Ruta aplic. Homebrew" + +#~ msgid "Theme Path change" +#~ msgstr "Cambio Ruta de Tema" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Cambio ruta WiiTDB" + #~ msgid "Homebrew Channel" #~ msgstr "Canal Homebrew" diff --git a/Languages/swedish.lang b/Languages/swedish.lang index 5cacce0b..87907205 100644 --- a/Languages/swedish.lang +++ b/Languages/swedish.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: Katsurou\n" "Language-Team: Katsurou, pirateX\n" @@ -297,9 +297,6 @@ msgstr "Kunde inte ställa in USB." msgid "Cover Download" msgstr "Omslagsnedladdning" -msgid "Cover Path Change" -msgstr "Ändra omslagsmapp" - msgid "Cover Path Changed" msgstr "Omslagsmapp ändrad" @@ -318,9 +315,6 @@ msgstr "Anpassade/Original" msgid "DOL Path" msgstr "DOL-sökväg" -msgid "DOL path change" -msgstr "Ändra DOL-sökväg" - msgid "DOL path changed" msgstr "DOL-sökväg ändrad" @@ -378,9 +372,6 @@ msgstr "Skivbilder" msgid "Disc Path Changed" msgstr "Skivbildsmapp ändrad" -msgid "Disc Path change" -msgstr "Ändra skivbildsmapp" - msgid "DiskFlip" msgstr "Vänd Skiva" @@ -576,9 +567,6 @@ msgstr "Hemmeny" msgid "Homebrew Apps Path" msgstr "Homebrew Apps" -msgid "Homebrew Appspath change" -msgstr "Ändra Homebrew Apps" - msgid "Homebrew Appspath changed" msgstr "Homebrew Apps ändrad" @@ -921,9 +909,6 @@ msgstr "Vibration" msgid "SChinese" msgstr "SKinesiska" -msgid "SD/USB selected" -msgstr "SD/USB vald" - msgid "SFX Volume" msgstr "SFX Volym" @@ -1036,9 +1021,6 @@ msgstr "Wad installation misslyckades med fel %ld" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Tema-mapp" msgid "Theme Path Changed" msgstr "Tema-mapp ändrad" -msgid "Theme Path change" -msgstr "Byt Tema-mapp" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB" msgid "WiiTDB Path" msgstr "WiiTDB-sökväg" -msgid "WiiTDB Path change" -msgstr "Ändra WiiTDB-sökväg" - msgid "WiiTDB Path changed." msgstr "WiiTDB-sökväg ändrad." @@ -1276,6 +1252,27 @@ msgstr "av" msgid "seconds left" msgstr "sekunder kvar" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB vald" + +#~ msgid "Cover Path Change" +#~ msgstr "Ändra omslagsmapp" + +#~ msgid "DOL path change" +#~ msgstr "Ändra DOL-sökväg" + +#~ msgid "Disc Path change" +#~ msgstr "Ändra skivbildsmapp" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Ändra Homebrew Apps" + +#~ msgid "Theme Path change" +#~ msgstr "Byt Tema-mapp" + +#~ msgid "WiiTDB Path change" +#~ msgstr "Ändra WiiTDB-sökväg" + #~ msgid "Homebrew Channel" #~ msgstr "Homebrew Kanalen" diff --git a/Languages/tchinese.lang b/Languages/tchinese.lang index 2fa0f769..5bd66246 100644 --- a/Languages/tchinese.lang +++ b/Languages/tchinese.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: kyogc\n" "Language-Team: \n" @@ -297,9 +297,6 @@ msgstr "無法設置USB" msgid "Cover Download" msgstr "下載封面" -msgid "Cover Path Change" -msgstr "變更封面路徑" - msgid "Cover Path Changed" msgstr "封面路徑已變更" @@ -318,9 +315,6 @@ msgstr "自製/原始" msgid "DOL Path" msgstr "DOL路徑" -msgid "DOL path change" -msgstr "變更DOL路徑" - msgid "DOL path changed" msgstr "DOL路徑已變更" @@ -378,9 +372,6 @@ msgstr "光碟圖像" msgid "Disc Path Changed" msgstr "光碟圖像路徑已變更" -msgid "Disc Path change" -msgstr "變更光碟圖像路徑" - msgid "DiskFlip" msgstr "光碟滑動" @@ -576,9 +567,6 @@ msgstr "主選單" msgid "Homebrew Apps Path" msgstr "HBC應用程式路徑" -msgid "Homebrew Appspath change" -msgstr "變更HBC應用程式路徑" - msgid "Homebrew Appspath changed" msgstr "HBC應用程式路徑已變更" @@ -921,9 +909,6 @@ msgstr "震動" msgid "SChinese" msgstr "簡體中文" -msgid "SD/USB selected" -msgstr "SD/USB卡已選擇" - msgid "SFX Volume" msgstr "音效音量" @@ -1036,9 +1021,6 @@ msgstr "wad安裝失敗,錯誤代碼:" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "背景主題路徑" msgid "Theme Path Changed" msgstr "背景主題路徑已變更" -msgid "Theme Path change" -msgstr "變更背景主題路徑" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB檔案" msgid "WiiTDB Path" msgstr "WiiTDB路徑" -msgid "WiiTDB Path change" -msgstr "變更WiiTDB路徑" - msgid "WiiTDB Path changed." msgstr "WiiTDB路徑已變更" @@ -1276,5 +1252,26 @@ msgstr "剩餘空間 總容量" msgid "seconds left" msgstr "剩餘秒數" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB卡已選擇" + +#~ msgid "Cover Path Change" +#~ msgstr "變更封面路徑" + +#~ msgid "DOL path change" +#~ msgstr "變更DOL路徑" + +#~ msgid "Disc Path change" +#~ msgstr "變更光碟圖像路徑" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "變更HBC應用程式路徑" + +#~ msgid "Theme Path change" +#~ msgstr "變更背景主題路徑" + +#~ msgid "WiiTDB Path change" +#~ msgstr "變更WiiTDB路徑" + #~ msgid "Homebrew Channel" #~ msgstr "Homebrew Channel" diff --git a/Languages/thai.lang b/Languages/thai.lang index 864b6635..e5e8d41f 100644 --- a/Languages/thai.lang +++ b/Languages/thai.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: Nitro_subzero \n" "Language-Team: Nitro_subzero\n" @@ -297,9 +297,6 @@ msgstr "ไม่สามารถตั้งค่า USB ได้" msgid "Cover Download" msgstr "ดาวน์โหลดปก" -msgid "Cover Path Change" -msgstr "ที่เก็บ ปก ถูกเปลี่ยนแปลง" - msgid "Cover Path Changed" msgstr "ที่เก็บ ปก ถูกเปลี่ยนแปลง" @@ -318,9 +315,6 @@ msgstr "กำหนดเอง/ดั้งเดิม" msgid "DOL Path" msgstr "ที่เก็บ DOL" -msgid "DOL path change" -msgstr "ที่เก็บ DOL ถูกเปลี่ยนแปลง" - msgid "DOL path changed" msgstr "ที่เก็บ DOL ถูกเปลี่ยนแปลง" @@ -378,9 +372,6 @@ msgstr "ภาพแผ่น" msgid "Disc Path Changed" msgstr "ที่เก็บ ภาพแผ่น ถูกเปลี่ยนแปลง" -msgid "Disc Path change" -msgstr "ที่เก็บ ภาพแผ่น ถูกเปลี่ยนแปลง" - msgid "DiskFlip" msgstr "สลับด้านแผ่น" @@ -576,9 +567,6 @@ msgstr "เมนู HOME" msgid "Homebrew Apps Path" msgstr "ที่เก็บโปรแกรม Homebrew" -msgid "Homebrew Appspath change" -msgstr "ที่เก็บโปรแกรม Homebrew ถูกเปลี่ยนแปลง" - msgid "Homebrew Appspath changed" msgstr "ที่เก็บโปรแกรม Homebrew ถูกเปลี่ยนแปลง" @@ -921,9 +909,6 @@ msgstr "สั่น" msgid "SChinese" msgstr "จีน" -msgid "SD/USB selected" -msgstr "SD/USB ถูกเลือก" - msgid "SFX Volume" msgstr "ความดังของ SFX" @@ -1036,9 +1021,6 @@ msgstr "การติดตั้งไฟล์ Wad ล้มเหลวด msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "ที่อยู่ Theme" msgid "Theme Path Changed" msgstr "ที่อยู่ Theme ถูกเปลี่ยนแปลง" -msgid "Theme Path change" -msgstr "ที่อยู่ Theme ถูกเปลี่ยนแปลง" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "ไฟล์ WiiTDB" msgid "WiiTDB Path" msgstr "ที่อยู่ WiiTDB" -msgid "WiiTDB Path change" -msgstr "เปลี่ยนที่อยู่ WiiTDB" - msgid "WiiTDB Path changed." msgstr "ที่อยู่ WiiTDB ถูกเปลี่ยนแปลง" @@ -1276,6 +1252,27 @@ msgstr "จาก" msgid "seconds left" msgstr "วินาทีที่เหลือ" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB ถูกเลือก" + +#~ msgid "Cover Path Change" +#~ msgstr "ที่เก็บ ปก ถูกเปลี่ยนแปลง" + +#~ msgid "DOL path change" +#~ msgstr "ที่เก็บ DOL ถูกเปลี่ยนแปลง" + +#~ msgid "Disc Path change" +#~ msgstr "ที่เก็บ ภาพแผ่น ถูกเปลี่ยนแปลง" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "ที่เก็บโปรแกรม Homebrew ถูกเปลี่ยนแปลง" + +#~ msgid "Theme Path change" +#~ msgstr "ที่อยู่ Theme ถูกเปลี่ยนแปลง" + +#~ msgid "WiiTDB Path change" +#~ msgstr "เปลี่ยนที่อยู่ WiiTDB" + #~ msgid "You need to start this game one time to create a save file, then exit and start it again." #~ msgstr "คุณต้องเริ่มโหลดเกมส์นี้ใหม่ เพื่อสร้างไฟล์เซฟ ดังนั้นออกจากเกมส์แล้วเริ่มโหลดอีกครั้ง" diff --git a/Languages/turkish.lang b/Languages/turkish.lang index a612ed1c..e88b3f06 100644 --- a/Languages/turkish.lang +++ b/Languages/turkish.lang @@ -5,7 +5,7 @@ msgid "" msgstr "" "Project-Id-Version: USB Loader GX\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-10-22 15:33+0200\n" +"POT-Creation-Date: 2009-10-24 23:27+0200\n" "PO-Revision-Date: 2009-10-01 01:00+0200\n" "Last-Translator: omercigingelini\n" "Language-Team: omercigingelini\n" @@ -297,9 +297,6 @@ msgstr "USB ayarlanamadı" msgid "Cover Download" msgstr "Kapak Indirme" -msgid "Cover Path Change" -msgstr "Kapak Yolu Değiştirme" - msgid "Cover Path Changed" msgstr "Kapak Yolu Değiştir" @@ -318,9 +315,6 @@ msgstr "Kişisel/Orjinal" msgid "DOL Path" msgstr "DOL Yolu" -msgid "DOL path change" -msgstr "DOL Yolu değiştirme" - msgid "DOL path changed" msgstr "DOL yolu değiştirildi" @@ -378,9 +372,6 @@ msgstr "Disk Resimleri" msgid "Disc Path Changed" msgstr "Disk Yolu Değiştirildi" -msgid "Disc Path change" -msgstr "Disk Yolunu Değiştir" - msgid "DiskFlip" msgstr "" @@ -576,9 +567,6 @@ msgstr "HOME Menü" msgid "Homebrew Apps Path" msgstr "Homebrew Yazılımlarının Yolu" -msgid "Homebrew Appspath change" -msgstr "Homebrew Yazılım Yolu değiştir" - msgid "Homebrew Appspath changed" msgstr "Homebrew Yazılım Yolu değişti" @@ -921,9 +909,6 @@ msgstr "Titreşim" msgid "SChinese" msgstr "Basitleştirilmis Çince" -msgid "SD/USB selected" -msgstr "SD/USB seçildi" - msgid "SFX Volume" msgstr "Efekt Seviyesi" @@ -1036,9 +1021,6 @@ msgstr "Wad kurulumu %ld hatasıyla başarısız oldu" msgid "Theme Download Path" msgstr "" -msgid "Theme Download Path change" -msgstr "" - msgid "Theme Download Path changed" msgstr "" @@ -1051,9 +1033,6 @@ msgstr "Tema Yolu" msgid "Theme Path Changed" msgstr "Tema Yolu Değişti" -msgid "Theme Path change" -msgstr "Tema yolunu değiştir" - msgid "Theme Title:" msgstr "" @@ -1182,9 +1161,6 @@ msgstr "WiiTDB Dosyaları" msgid "WiiTDB Path" msgstr "WiiTDB Yaması" -msgid "WiiTDB Path change" -msgstr "WiiTDB Yolunu değiştir" - msgid "WiiTDB Path changed." msgstr "WiiTDB Yolu değişti" @@ -1276,5 +1252,26 @@ msgstr "./" msgid "seconds left" msgstr "saniye kaldı" +#~ msgid "SD/USB selected" +#~ msgstr "SD/USB seçildi" + +#~ msgid "Cover Path Change" +#~ msgstr "Kapak Yolu Değiştirme" + +#~ msgid "DOL path change" +#~ msgstr "DOL Yolu değiştirme" + +#~ msgid "Disc Path change" +#~ msgstr "Disk Yolunu Değiştir" + +#~ msgid "Homebrew Appspath change" +#~ msgstr "Homebrew Yazılım Yolu değiştir" + +#~ msgid "Theme Path change" +#~ msgstr "Tema yolunu değiştir" + +#~ msgid "WiiTDB Path change" +#~ msgstr "WiiTDB Yolunu değiştir" + #~ msgid "Homebrew Channel" #~ msgstr "Homebrew Kanalı" diff --git a/source/FreeTypeGX.cpp b/source/FreeTypeGX.cpp index b9099d2d..31b2294f 100644 --- a/source/FreeTypeGX.cpp +++ b/source/FreeTypeGX.cpp @@ -545,7 +545,7 @@ int16_t FreeTypeGX::getStyleOffsetHeight(ftgxDataOffset *offset, uint16_t format * @param textStyle Flags which specify any styling which should be applied to the rendered string. * @return The number of characters printed. */ -uint16_t FreeTypeGX::drawText(int16_t x, int16_t y, wchar_t *text, GXColor color, uint16_t textStyle) { +uint16_t FreeTypeGX::drawText(int16_t x, int16_t y, const wchar_t *text, GXColor color, uint16_t textStyle) { uint16_t strLength = wcslen(text); uint16_t x_pos = x, printed = 0; uint16_t x_offset = 0, y_offset = 0; @@ -592,12 +592,6 @@ uint16_t FreeTypeGX::drawText(int16_t x, int16_t y, wchar_t *text, GXColor color return printed; } -/** - * \overload - */ -uint16_t FreeTypeGX::drawText(int16_t x, int16_t y, wchar_t const *text, GXColor color, uint16_t textStyle) { - return this->drawText(x, y, (wchar_t *)text, color, textStyle); -} void FreeTypeGX::drawTextFeature(int16_t x, int16_t y, uint16_t width, ftgxDataOffset *offsetData, uint16_t format, GXColor color) { uint16_t featureHeight = this->ftPointSize_v >> 4 > 0 ? this->ftPointSize_v >> 4 : 1; @@ -663,7 +657,7 @@ uint16_t FreeTypeGX::getWidth(const wchar_t *text) { if ( fontData.find(text[i]) != fontData.end() ) { glyphData = &fontData[text[i]]; } else { - glyphData = this->cacheGlyphData(text[i]); + glyphData = this->cacheGlyphData(text[i], fontData); } if (glyphData != NULL) { @@ -717,7 +711,7 @@ ftgxDataOffset* FreeTypeGX::getOffset(const wchar_t *text, ftgxDataOffset* offse if ( fontData.find(text[i]) != fontData.end() ) { glyphData = &fontData[text[i]]; } else { - glyphData = this->cacheGlyphData(text[i]); + glyphData = this->cacheGlyphData(text[i], fontData); } if (glyphData != NULL) { diff --git a/source/FreeTypeGX.h b/source/FreeTypeGX.h index 3276abe5..4fa2b17c 100644 --- a/source/FreeTypeGX.h +++ b/source/FreeTypeGX.h @@ -265,8 +265,7 @@ public: uint16_t loadFont(const char* fontPath, const uint8_t* fontBuffer, FT_Long bufferSize, FT_UInt pointSize, bool cacheAll = false); void changeSize(FT_UInt vPointSize, FT_UInt hPointSize=0); - uint16_t drawText(int16_t x, int16_t y, wchar_t *text, GXColor color = ftgxWhite, uint16_t textStyling = FTGX_NULL); - uint16_t drawText(int16_t x, int16_t y, wchar_t const *text, GXColor color = ftgxWhite, uint16_t textStyling = FTGX_NULL); + uint16_t drawText(int16_t x, int16_t y, const wchar_t *text, GXColor color = ftgxWhite, uint16_t textStyling = FTGX_NULL); uint16_t getWidth(const wchar_t *text); uint16_t getHeight(const wchar_t *text); diff --git a/source/cheats/cheatmenu.cpp b/source/cheats/cheatmenu.cpp index a76e7cec..ccb3f5a6 100644 --- a/source/cheats/cheatmenu.cpp +++ b/source/cheats/cheatmenu.cpp @@ -24,109 +24,114 @@ extern GuiWindow * mainWindow; * CheatMenu ***************************************************************************/ int CheatMenu(const char * gameID) { - int choice = 0; - bool exit = false; - int ret = 1; + int choice = 0; + bool exit = false; + int ret = 1; - GuiSound btnClick(button_click2_pcm, button_click2_pcm_size, SOUND_PCM, Settings.sfxvolume); + GuiSound btnClick(button_click2_pcm, button_click2_pcm_size, SOUND_PCM, Settings.sfxvolume); - char imgPath[100]; - snprintf(imgPath, sizeof(imgPath), "%sbutton_dialogue_box.png", CFG.theme_path); - GuiImageData btnOutline(imgPath, button_dialogue_box_png); - snprintf(imgPath, sizeof(imgPath), "%ssettings_background.png", CFG.theme_path); - GuiImageData settingsbg(imgPath, settings_background_png); - GuiImage settingsbackground(&settingsbg); + char imgPath[100]; + snprintf(imgPath, sizeof(imgPath), "%sbutton_dialogue_box.png", CFG.theme_path); + GuiImageData btnOutline(imgPath, button_dialogue_box_png); + snprintf(imgPath, sizeof(imgPath), "%ssettings_background.png", CFG.theme_path); + GuiImageData settingsbg(imgPath, settings_background_png); + GuiImage settingsbackground(&settingsbg); - GuiTrigger trigA; - trigA.SetSimpleTrigger(-1, WPAD_BUTTON_A | WPAD_CLASSIC_BUTTON_A, PAD_BUTTON_A); - GuiTrigger trigB; - trigB.SetButtonOnlyTrigger(-1, WPAD_BUTTON_B | WPAD_CLASSIC_BUTTON_B, PAD_BUTTON_B); + GuiTrigger trigA; + trigA.SetSimpleTrigger(-1, WPAD_BUTTON_A | WPAD_CLASSIC_BUTTON_A, PAD_BUTTON_A); + GuiTrigger trigB; + trigB.SetButtonOnlyTrigger(-1, WPAD_BUTTON_B | WPAD_CLASSIC_BUTTON_B, PAD_BUTTON_B); - GuiText backBtnTxt(tr("Back") , 22, THEME.prompttext); - backBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); - GuiImage backBtnImg(&btnOutline); - GuiButton backBtn(&backBtnImg,&backBtnImg, 2, 3, -140, 400, &trigA, NULL, &btnClick,1); - backBtn.SetLabel(&backBtnTxt); - backBtn.SetTrigger(&trigB); + GuiText backBtnTxt(tr("Back") , 22, THEME.prompttext); + backBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); + GuiImage backBtnImg(&btnOutline); + GuiButton backBtn(&backBtnImg,&backBtnImg, 2, 3, -140, 400, &trigA, NULL, &btnClick,1); + backBtn.SetLabel(&backBtnTxt); + backBtn.SetTrigger(&trigB); - GuiText createBtnTxt(tr("Create") , 22, THEME.prompttext); - createBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); - GuiImage createBtnImg(&btnOutline); - GuiButton createBtn(&createBtnImg,&createBtnImg, 2, 3, 160, 400, &trigA, NULL, &btnClick,1); - createBtn.SetLabel(&createBtnTxt); + GuiText createBtnTxt(tr("Create") , 22, THEME.prompttext); + createBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); + GuiImage createBtnImg(&btnOutline); + GuiButton createBtn(&createBtnImg,&createBtnImg, 2, 3, 160, 400, &trigA, NULL, &btnClick,1); + createBtn.SetLabel(&createBtnTxt); - char txtfilename[55]; - snprintf(txtfilename,sizeof(txtfilename),"%s%s.txt",Settings.TxtCheatcodespath,gameID); + char txtfilename[55]; + snprintf(txtfilename,sizeof(txtfilename),"%s%s.txt",Settings.TxtCheatcodespath,gameID); - GCTCheats c; - int check = c.openTxtfile(txtfilename); + GCTCheats c; + int check = c.openTxtfile(txtfilename); - int download =0; + int download =0; - switch (check) { - case -1: - WindowPrompt(tr("Error"),tr("Cheatfile is blank"),tr("OK")); - break; - case 0: - download = WindowPrompt(tr("Error"),tr("No Cheatfile found"),tr("Download Now"),tr("Cancel")); - if (download==1) - download = CodeDownload(gameID); - break; - case 1: - int cntcheats = c.getCnt(); - customOptionList cheatslst(cntcheats); - GuiCustomOptionBrowser chtBrowser(400, 280, &cheatslst, CFG.theme_path, "bg_options_settings.png", bg_options_settings_png, 1, 90); - chtBrowser.SetPosition(0, 90); - chtBrowser.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - chtBrowser.SetClickable(true); + switch (check) { + case -1: + WindowPrompt(tr("Error"),tr("Cheatfile is blank"),tr("OK")); + break; + case 0: + download = WindowPrompt(tr("Error"),tr("No Cheatfile found"),tr("Download Now"),tr("Cancel")); + if (download==1) + { + download = CodeDownload(gameID); + if(download < 0 || c.openTxtfile(txtfilename) != 1) + break; + } + else + break; + case 1: + int cntcheats = c.getCnt(); + customOptionList cheatslst(cntcheats); + GuiCustomOptionBrowser chtBrowser(400, 280, &cheatslst, CFG.theme_path, "bg_options_settings.png", bg_options_settings_png, 1, 90); + chtBrowser.SetPosition(0, 90); + chtBrowser.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + chtBrowser.SetClickable(true); - GuiText titleTxt(c.getGameName().c_str(), 28, (GXColor) {0, 0, 0, 255}); - titleTxt.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - titleTxt.SetMaxWidth(350, GuiText::SCROLL); - titleTxt.SetPosition(12,40); + GuiText titleTxt(c.getGameName().c_str(), 28, (GXColor) {0, 0, 0, 255}); + titleTxt.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + titleTxt.SetMaxWidth(350, GuiText::SCROLL); + titleTxt.SetPosition(12,40); - for (int i = 0; i <= cntcheats; i++) { + for (int i = 0; i <= cntcheats; i++) { cheatslst.SetValue(i, "%s",c.getCheatName(i).c_str()); cheatslst.SetName(i, "OFF"); } - HaltGui(); - GuiWindow w(screenwidth, screenheight); - w.Append(&settingsbackground); - w.Append(&titleTxt); - w.Append(&backBtn); - w.Append(&createBtn); - w.Append(&chtBrowser); - mainWindow->SetState(STATE_DISABLED); - mainWindow->ChangeFocus(&w); - mainWindow->Append(&w); - ResumeGui(); + HaltGui(); + GuiWindow w(screenwidth, screenheight); + w.Append(&settingsbackground); + w.Append(&titleTxt); + w.Append(&backBtn); + w.Append(&createBtn); + w.Append(&chtBrowser); + mainWindow->SetState(STATE_DISABLED); + mainWindow->ChangeFocus(&w); + mainWindow->Append(&w); + ResumeGui(); - while (!exit) { - VIDEO_WaitVSync (); + while (!exit) { + VIDEO_WaitVSync (); - ret = chtBrowser.GetClickedOption(); - if (ret != -1) { - const char *strCheck = cheatslst.GetName(ret); - if (strncmp(strCheck,"ON",2) == 0) { - cheatslst.SetName(ret,"%s","OFF"); - } else if (strncmp(strCheck,"OFF",3) == 0) { - cheatslst.SetName(ret,"%s","ON"); - } - } + ret = chtBrowser.GetClickedOption(); + if (ret != -1) { + const char *strCheck = cheatslst.GetName(ret); + if (strncmp(strCheck,"ON",2) == 0) { + cheatslst.SetName(ret,"%s","OFF"); + } else if (strncmp(strCheck,"OFF",3) == 0) { + cheatslst.SetName(ret,"%s","ON"); + } + } - if (createBtn.GetState() == STATE_CLICKED) { - createBtn.ResetState(); - if (cntcheats > 0) { - int selectednrs[30]; - int x = 0; - for (int i = 0; i <= cntcheats; i++) { - const char *strCheck = cheatslst.GetName(i); - if (strncmp(strCheck,"ON",2) == 0) { - selectednrs[x] = i; - x++; - } - } + if (createBtn.GetState() == STATE_CLICKED) { + createBtn.ResetState(); + if (cntcheats > 0) { + int selectednrs[30]; + int x = 0; + for (int i = 0; i <= cntcheats; i++) { + const char *strCheck = cheatslst.GetName(i); + if (strncmp(strCheck,"ON",2) == 0) { + selectednrs[x] = i; + x++; + } + } if (x == 0) { WindowPrompt(tr("Error"),tr("No cheats were selected"),tr("OK")); } else { @@ -138,21 +143,21 @@ int CheatMenu(const char * gameID) { exit = true; break; } - } else WindowPrompt(tr("Error"),tr("Could not create GCT file"),tr("OK")); - } + } else WindowPrompt(tr("Error"),tr("Could not create GCT file"),tr("OK")); + } - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } - } - HaltGui(); - mainWindow->SetState(STATE_DEFAULT); - mainWindow->Remove(&w); - ResumeGui(); - break; - } + if (backBtn.GetState() == STATE_CLICKED) { + backBtn.ResetState(); + exit = true; + break; + } + } + HaltGui(); + mainWindow->SetState(STATE_DEFAULT); + mainWindow->Remove(&w); + ResumeGui(); + break; + } - return choice; + return choice; } diff --git a/source/libwiigui/gui_customoptionbrowser.cpp b/source/libwiigui/gui_customoptionbrowser.cpp index f4a4e1f2..070ac65f 100644 --- a/source/libwiigui/gui_customoptionbrowser.cpp +++ b/source/libwiigui/gui_customoptionbrowser.cpp @@ -16,23 +16,19 @@ #define GAMESELECTSIZE 30 +#define OPTION_LIST_PADDING PAGESIZE - -customOptionList::customOptionList(int size) +customOptionList::customOptionList(int Size) { - name = new char * [size]; - value = new char * [size]; - for (int i = 0; i < size; i++) - { - name[i] = 0; - value[i] = 0; - } - length = size; + name = value = NULL; + size = 0; + SetSize(Size==0 ? PAGESIZE : Size); + length = Size; changed = false; } customOptionList::~customOptionList() { - for (int i = 0; i < length; i++) + for (int i = 0; i < size; i++) { free(name[i]); free(value[i]); @@ -40,13 +36,55 @@ customOptionList::~customOptionList() delete [] name; delete [] value; } -void customOptionList::SetLength(int size) //set number of lines +void customOptionList::SetLength(int Length) //set number of lines { - length = size; - changed = true; + if(Length < 0 || Length == length) return; + + if(Length > size) + SetSize(Length + OPTION_LIST_PADDING); + if(Length < length) + { + for (int i = Length; i < length; i++) + { + free(name[i]); // clear unused + name[i] = NULL; + free(value[i]); + value[i] = NULL; + } + } + length = Length; + changed = true; +} +void customOptionList::SetSize(int Size) //set number of lines +{ + if(Size < 0 || Size == size) return; + + if(Size > size) + { + char **newName = new char *[Size]; + char **newValue = new char *[Size]; + int i; + for (i = 0; i < size; i++) + { + newName[i] = name[i]; // copy + newValue[i] = value[i]; + } + for (; i < Size; i++) + { + newName[i] = NULL; // fill rest with NULL + newValue[i] = NULL; + } + delete [] name; + name = newName; // set new + delete [] value; + value = newValue; + size = Size; + } } void customOptionList::SetName(int i, const char *format, ...) { + if(i >= length) SetLength(i+1); + if(i >= 0 && i < length) { if(name[i]) free(name[i]); @@ -60,6 +98,8 @@ void customOptionList::SetName(int i, const char *format, ...) } void customOptionList::SetValue(int i, const char *format, ...) { + if(i >= length) SetLength(i+1); + if(i >= 0 && i < length) { char *tmp=0; @@ -81,6 +121,20 @@ void customOptionList::SetValue(int i, const char *format, ...) } } } +void customOptionList::Clear(bool OnlyValue/*=false*/) +{ + for (int i = 0; i < size; i++) + { + if(!OnlyValue) + { + free(name[i]); + name[i] = NULL; + } + free(value[i]); + value[i] = NULL; + } + changed = true; +} /** * Constructor for the GuiCustomOptionBrowser class. @@ -90,7 +144,7 @@ GuiCustomOptionBrowser::GuiCustomOptionBrowser(int w, int h, customOptionList * width = w; height = h; options = l; - size = ((l->GetLength() > PAGESIZE)? PAGESIZE: l->GetLength()); + size = PAGESIZE; scrollbaron = scrollon; selectable = true; listOffset = this->FindMenuItem(-1, 1); @@ -101,7 +155,7 @@ GuiCustomOptionBrowser::GuiCustomOptionBrowser(int w, int h, customOptionList * trigA = new GuiTrigger; trigA->SetSimpleTrigger(-1, WPAD_BUTTON_A | WPAD_CLASSIC_BUTTON_A, PAD_BUTTON_A); - trigHeldA = new GuiTrigger; + trigHeldA = new GuiTrigger; trigHeldA->SetHeldTrigger(-1, WPAD_BUTTON_A, PAD_BUTTON_A); btnSoundClick = new GuiSound(button_click_pcm, button_click_pcm_size, SOUND_PCM, Settings.sfxvolume); @@ -170,7 +224,7 @@ GuiCustomOptionBrowser::GuiCustomOptionBrowser(int w, int h, customOptionList * scrollbarBoxBtn->SetAlignment(ALIGN_CENTRE, ALIGN_TOP); scrollbarBoxBtn->SetSelectable(false); scrollbarBoxBtn->SetEffectOnOver(EFFECT_SCALE, 50, 120); - scrollbarBoxBtn->SetMinY(0); + scrollbarBoxBtn->SetMinY(0); scrollbarBoxBtn->SetMaxY(height-30); scrollbarBoxBtn->SetHoldable(true); scrollbarBoxBtn->SetTrigger(trigHeldA); @@ -235,7 +289,7 @@ GuiCustomOptionBrowser::~GuiCustomOptionBrowser() delete scrollbarBox; delete scrollbarBoxOver; - delete bgOptionsImg; + delete bgOptionsImg; delete bgOptions; delete bgOptionsEntry; @@ -330,8 +384,8 @@ void GuiCustomOptionBrowser::SetScrollbar(int enable) void GuiCustomOptionBrowser::SetOffset(int optionnumber) { - listOffset = optionnumber; - selectedItem = optionnumber; + listOffset = optionnumber; + selectedItem = optionnumber; } /**************************************************************************** @@ -377,17 +431,18 @@ void GuiCustomOptionBrowser::Draw() break; } - if(scrollbaron == 1) { - scrollbarImg->Draw(); - arrowUpBtn->Draw(); - arrowDownBtn->Draw(); - scrollbarBoxBtn->Draw(); - } + if(scrollbaron == 1) { + scrollbarImg->Draw(); + arrowUpBtn->Draw(); + arrowDownBtn->Draw(); + scrollbarBoxBtn->Draw(); + } this->UpdateEffects(); } void GuiCustomOptionBrowser::UpdateListEntries() { + scrollbaron = options->GetLength() > size; if(listOffset<0) listOffset = this->FindMenuItem(-1, 1); int next = listOffset; @@ -446,90 +501,90 @@ void GuiCustomOptionBrowser::Update(GuiTrigger * t) } int old_listOffset = listOffset; - if (scrollbaron == 1) + if (scrollbaron == 1) { // update the location of the scroll box based on the position in the option list arrowUpBtn->Update(t); arrowDownBtn->Update(t); scrollbarBoxBtn->Update(t); - } + } next = listOffset; - u32 buttonshold = ButtonsHold(); + u32 buttonshold = ButtonsHold(); - if(buttonshold != WPAD_BUTTON_UP && buttonshold != WPAD_BUTTON_DOWN) { - for(int i=0; i < size; i++) - { - if(next >= 0) - next = this->FindMenuItem(next, 1); - - if(focus) + if(buttonshold != WPAD_BUTTON_UP && buttonshold != WPAD_BUTTON_DOWN) { + for(int i=0; i < size; i++) { - if(i != selectedItem && optionBtn[i]->GetState() == STATE_SELECTED) { - optionBtn[i]->ResetState(); - } else if(i == selectedItem && optionBtn[i]->GetState() == STATE_DEFAULT) { - optionBtn[selectedItem]->SetState(STATE_SELECTED); + if(next >= 0) + next = this->FindMenuItem(next, 1); + + if(focus) + { + if(i != selectedItem && optionBtn[i]->GetState() == STATE_SELECTED) { + optionBtn[i]->ResetState(); + } else if(i == selectedItem && optionBtn[i]->GetState() == STATE_DEFAULT) { + optionBtn[selectedItem]->SetState(STATE_SELECTED); + } + } + + + optionBtn[i]->Update(t); + + if(optionBtn[i]->GetState() == STATE_SELECTED) + { + selectedItem = i; } } - - - optionBtn[i]->Update(t); - - if(optionBtn[i]->GetState() == STATE_SELECTED) - { - selectedItem = i; - } - } } // pad/joystick navigation if(!focus) return; // skip navigation - if(t->Down()) - { - next = this->FindMenuItem(optionIndex[selectedItem], 1); - - if(next >= 0) - { - if(selectedItem == size-1) - { - // move list down by 1 - listOffset = this->FindMenuItem(listOffset, 1); - } - else if(optionBtn[selectedItem+1]->IsVisible()) - { - optionBtn[selectedItem]->ResetState(); - optionBtn[selectedItem+1]->SetState(STATE_SELECTED, t->chan); - selectedItem++; - } - } - } - else if(t->Up()) - { - prev = this->FindMenuItem(optionIndex[selectedItem], -1); - - if(prev >= 0) - { - if(selectedItem == 0) - { - // move list up by 1 - listOffset = prev; - } - else - { - optionBtn[selectedItem]->ResetState(); - optionBtn[selectedItem-1]->SetState(STATE_SELECTED, t->chan); - selectedItem--; - } - } - } - - if (scrollbaron == 1) + if(t->Down()) { - if (arrowDownBtn->GetState() == STATE_CLICKED || - arrowDownBtn->GetState() == STATE_HELD) + next = this->FindMenuItem(optionIndex[selectedItem], 1); + + if(next >= 0) + { + if(selectedItem == size-1) + { + // move list down by 1 + listOffset = this->FindMenuItem(listOffset, 1); + } + else if(optionBtn[selectedItem+1]->IsVisible()) + { + optionBtn[selectedItem]->ResetState(); + optionBtn[selectedItem+1]->SetState(STATE_SELECTED, t->chan); + selectedItem++; + } + } + } + else if(t->Up()) + { + prev = this->FindMenuItem(optionIndex[selectedItem], -1); + + if(prev >= 0) + { + if(selectedItem == 0) + { + // move list up by 1 + listOffset = prev; + } + else + { + optionBtn[selectedItem]->ResetState(); + optionBtn[selectedItem-1]->SetState(STATE_SELECTED, t->chan); + selectedItem--; + } + } + } + + if (scrollbaron == 1) + { + if (arrowDownBtn->GetState() == STATE_CLICKED || + arrowDownBtn->GetState() == STATE_HELD) { next = this->FindMenuItem(optionIndex[selectedItem], 1); @@ -555,7 +610,7 @@ void GuiCustomOptionBrowser::Update(GuiTrigger * t) } } else if(arrowUpBtn->GetState() == STATE_CLICKED || - arrowUpBtn->GetState() == STATE_HELD) + arrowUpBtn->GetState() == STATE_HELD) { prev = this->FindMenuItem(optionIndex[selectedItem], -1); @@ -622,7 +677,7 @@ void GuiCustomOptionBrowser::Update(GuiTrigger * t) listOffset = 0; } } - } + } if(old_listOffset != listOffset) UpdateListEntries(); diff --git a/source/libwiigui/gui_customoptionbrowser.h b/source/libwiigui/gui_customoptionbrowser.h index 93f14cca..8bc8d176 100644 --- a/source/libwiigui/gui_customoptionbrowser.h +++ b/source/libwiigui/gui_customoptionbrowser.h @@ -2,9 +2,9 @@ class customOptionList { public: - customOptionList(int size); + customOptionList(int Size); ~customOptionList(); - void SetLength(int size); + void SetLength(int Length); void SetName(int i, const char *format, ...) __attribute__((format (printf, 3, 4))); const char *GetName(int i) { @@ -21,12 +21,15 @@ class customOptionList { else return ""; } + void Clear(bool OnlyValue=false); int GetLength() { return length; } bool IsChanged() { bool ret = changed; changed = false; return ret;} private: - int length; + void SetSize(int Size); + int size; char ** name; char ** value; + int length; bool changed; }; diff --git a/source/menu.cpp b/source/menu.cpp index ede42f14..096a1c0f 100644 --- a/source/menu.cpp +++ b/source/menu.cpp @@ -1565,7 +1565,7 @@ int MenuDiscList() { bool returnHere = true;// prompt to start game while (returnHere) { returnHere = false; - if (Settings.wiilight != 2) wiilight(1); + if (Settings.wiilight != wiilight_forInstall) wiilight(1); choice = GameWindowPrompt(); // header = &gameList[gameSelected]; //reset header @@ -1907,7 +1907,7 @@ static int MenuFormat() { int menu = MENU_NONE; char imgPath[100]; - customOptionList options(5); + customOptionList options(MAX_PARTITIONS); partitionEntry partitions[MAX_PARTITIONS]; u32 cnt, sector_size; diff --git a/source/settings/Settings.cpp b/source/settings/Settings.cpp index a075fce5..980d946a 100644 --- a/source/settings/Settings.cpp +++ b/source/settings/Settings.cpp @@ -23,8 +23,7 @@ /*** Extern functions ***/ extern void ResumeGui(); extern void HaltGui(); -extern bool -Database(char* xmlfilepath, char* argdblang, bool argJPtoEN, bool openfile, bool loadtitles, bool keepopen); +extern bool Database(char* xmlfilepath, char* argdblang, bool argJPtoEN, bool openfile, bool loadtitles, bool keepopen); extern void titles_default(); /*** Extern variables ***/ @@ -38,2630 +37,2803 @@ extern u8 reset; extern u8 mountMethod; extern struct discHdr *dvdheader; + +static const char *opts_no_yes[settings_off_on_max] = {trNOOP("No"),trNOOP("Yes") }; +static const char *opts_off_on[settings_off_on_max] = {trNOOP("OFF"),trNOOP("ON") }; +static const char *opts_videomode[settings_language_max][2] = {{"",trNOOP("Disc Default")},{trNOOP("System Default"),""},{trNOOP("AutoPatch"),""},{trNOOP("Force"), " PAL50"},{trNOOP("Force")," PAL60"},{trNOOP("Force")," NTSC"}}; +static const char *opts_language[settings_language_max] = {trNOOP("Console Default"),trNOOP("Japanese"),trNOOP("English"),trNOOP("German"),trNOOP("French"),trNOOP("Spanish"),trNOOP("Italian"),trNOOP("Dutch"),trNOOP("SChinese"),trNOOP("TChinese"),trNOOP("Korean")}; +static const char *opts_cios[settings_ios_max] = {"IOS 249","IOS 222", "IOS 223"}; +static const char *opts_parentalcontrol[5] = {trNOOP("0 (Everyone)"),trNOOP("1 (Child 7+)"),trNOOP("2 (Teen 12+)"),trNOOP("3 (Mature 16+)"),trNOOP("4 (Adults Only 18+)")}; +static const char *opts_error002[settings_error002_max] = {trNOOP("No"),trNOOP("Yes"),trNOOP("Anti")}; + /**************************************************************************** * MenuSettings ***************************************************************************/ -int MenuSettings() { - int menu = MENU_NONE; - int ret; - int choice = 0; - bool exit = false; +int MenuSettings() +{ + int menu = MENU_NONE; + int ret; + int choice = 0; + bool exit = false; - // backup game language setting - char opt_lang[100]; - strcpy(opt_lang,Settings.language_path); + // backup game language setting + char opt_lang[100]; + strcpy(opt_lang,Settings.language_path); // backup title override setting int opt_override = Settings.titlesOverride; - enum { - FADE, - LEFT, - RIGHT - }; - - int slidedirection = FADE; - - GuiSound btnSoundOver(button_over_pcm, button_over_pcm_size, SOUND_PCM, Settings.sfxvolume); - GuiSound btnClick(button_click2_pcm, button_click2_pcm_size, SOUND_PCM, Settings.sfxvolume); - GuiSound btnClick1(button_click_pcm, button_click_pcm_size, SOUND_PCM, Settings.sfxvolume); - - char imgPath[100]; - - snprintf(imgPath, sizeof(imgPath), "%sbutton_dialogue_box.png", CFG.theme_path); - GuiImageData btnOutline(imgPath, button_dialogue_box_png); - snprintf(imgPath, sizeof(imgPath), "%ssettings_background.png", CFG.theme_path); - GuiImageData settingsbg(imgPath, settings_background_png); - - snprintf(imgPath, sizeof(imgPath), "%ssettings_title.png", CFG.theme_path); - GuiImageData MainButtonImgData(imgPath, settings_title_png); - - snprintf(imgPath, sizeof(imgPath), "%ssettings_title_over.png", CFG.theme_path); - GuiImageData MainButtonImgOverData(imgPath, settings_title_over_png); - - snprintf(imgPath, sizeof(imgPath), "%spageindicator.png", CFG.theme_path); - GuiImageData PageindicatorImgData(imgPath, pageindicator_png); - - snprintf(imgPath, sizeof(imgPath), "%sstartgame_arrow_left.png", CFG.theme_path); - GuiImageData arrow_left(imgPath, startgame_arrow_left_png); - - snprintf(imgPath, sizeof(imgPath), "%sstartgame_arrow_right.png", CFG.theme_path); - GuiImageData arrow_right(imgPath, startgame_arrow_right_png); - - snprintf(imgPath, sizeof(imgPath), "%scredits_button.png", CFG.theme_path); - GuiImageData creditsImgData(imgPath, credits_button_png); - - snprintf(imgPath, sizeof(imgPath), "%scredits_button_over.png", CFG.theme_path); - GuiImageData creditsOver(imgPath, credits_button_over_png); - - GuiImage creditsImg(&creditsImgData); - GuiImage creditsImgOver(&creditsOver); - - GuiTrigger trigA; - trigA.SetSimpleTrigger(-1, WPAD_BUTTON_A | WPAD_CLASSIC_BUTTON_A, PAD_BUTTON_A); - GuiTrigger trigHome; - trigHome.SetButtonOnlyTrigger(-1, WPAD_BUTTON_HOME | WPAD_CLASSIC_BUTTON_HOME, 0); - GuiTrigger trigB; - trigB.SetButtonOnlyTrigger(-1, WPAD_BUTTON_B | WPAD_CLASSIC_BUTTON_B, PAD_BUTTON_B); - GuiTrigger trigL; - trigL.SetButtonOnlyTrigger(-1, WPAD_BUTTON_LEFT | WPAD_CLASSIC_BUTTON_LEFT, PAD_BUTTON_LEFT); - GuiTrigger trigR; - trigR.SetButtonOnlyTrigger(-1, WPAD_BUTTON_RIGHT | WPAD_CLASSIC_BUTTON_RIGHT, PAD_BUTTON_RIGHT); - GuiTrigger trigMinus; - trigMinus.SetButtonOnlyTrigger(-1, WPAD_BUTTON_MINUS | WPAD_CLASSIC_BUTTON_MINUS, 0); - GuiTrigger trigPlus; - trigPlus.SetButtonOnlyTrigger(-1, WPAD_BUTTON_PLUS | WPAD_CLASSIC_BUTTON_PLUS, 0); - - GuiText titleTxt(tr("Settings"), 28, (GXColor) {0, 0, 0, 255}); - titleTxt.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - titleTxt.SetPosition(0,40); - - GuiImage settingsbackground(&settingsbg); - - GuiText backBtnTxt(tr("Back") , 22, THEME.prompttext); - backBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); - GuiImage backBtnImg(&btnOutline); - if (Settings.wsprompt == yes) { - backBtnTxt.SetWidescreen(CFG.widescreen); - backBtnImg.SetWidescreen(CFG.widescreen); - } - GuiButton backBtn(&backBtnImg,&backBtnImg, 2, 3, -180, 400, &trigA, &btnSoundOver, &btnClick,1); - backBtn.SetLabel(&backBtnTxt); - backBtn.SetTrigger(&trigB); - - GuiButton homo(1,1); - homo.SetTrigger(&trigHome); - - GuiImage PageindicatorImg1(&PageindicatorImgData); - GuiText PageindicatorTxt1("1", 22, (GXColor) { 0, 0, 0, 255}); - GuiButton PageIndicatorBtn1(PageindicatorImg1.GetWidth(), PageindicatorImg1.GetHeight()); - PageIndicatorBtn1.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - PageIndicatorBtn1.SetPosition(165, 400); - PageIndicatorBtn1.SetImage(&PageindicatorImg1); - PageIndicatorBtn1.SetLabel(&PageindicatorTxt1); - PageIndicatorBtn1.SetSoundOver(&btnSoundOver); - PageIndicatorBtn1.SetSoundClick(&btnClick1); - PageIndicatorBtn1.SetTrigger(&trigA); - PageIndicatorBtn1.SetEffectGrow(); - - GuiImage PageindicatorImg2(&PageindicatorImgData); - GuiText PageindicatorTxt2("2", 22, (GXColor) {0, 0, 0, 255}); - GuiButton PageIndicatorBtn2(PageindicatorImg2.GetWidth(), PageindicatorImg2.GetHeight()); - PageIndicatorBtn2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - PageIndicatorBtn2.SetPosition(200, 400); - PageIndicatorBtn2.SetImage(&PageindicatorImg2); - PageIndicatorBtn2.SetLabel(&PageindicatorTxt2); - PageIndicatorBtn2.SetSoundOver(&btnSoundOver); - PageIndicatorBtn2.SetSoundClick(&btnClick1); - PageIndicatorBtn2.SetTrigger(&trigA); - PageIndicatorBtn2.SetEffectGrow(); - - GuiImage PageindicatorImg3(&PageindicatorImgData); - GuiText PageindicatorTxt3("3", 22, (GXColor) {0, 0, 0, 255}); - GuiButton PageIndicatorBtn3(PageindicatorImg3.GetWidth(), PageindicatorImg3.GetHeight()); - PageIndicatorBtn3.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - PageIndicatorBtn3.SetPosition(235, 400); - PageIndicatorBtn3.SetImage(&PageindicatorImg3); - PageIndicatorBtn3.SetLabel(&PageindicatorTxt3); - PageIndicatorBtn3.SetSoundOver(&btnSoundOver); - PageIndicatorBtn3.SetSoundClick(&btnClick1); - PageIndicatorBtn3.SetTrigger(&trigA); - PageIndicatorBtn3.SetEffectGrow(); - - GuiImage GoLeftImg(&arrow_left); - GuiButton GoLeftBtn(GoLeftImg.GetWidth(), GoLeftImg.GetHeight()); - GoLeftBtn.SetAlignment(ALIGN_LEFT, ALIGN_MIDDLE); - GoLeftBtn.SetPosition(25, -25); - GoLeftBtn.SetImage(&GoLeftImg); - GoLeftBtn.SetSoundOver(&btnSoundOver); - GoLeftBtn.SetSoundClick(&btnClick); - GoLeftBtn.SetEffectGrow(); - GoLeftBtn.SetTrigger(&trigA); - GoLeftBtn.SetTrigger(&trigL); - GoLeftBtn.SetTrigger(&trigMinus); - - GuiImage GoRightImg(&arrow_right); - GuiButton GoRightBtn(GoRightImg.GetWidth(), GoRightImg.GetHeight()); - GoRightBtn.SetAlignment(ALIGN_RIGHT, ALIGN_MIDDLE); - GoRightBtn.SetPosition(-25, -25); - GoRightBtn.SetImage(&GoRightImg); - GoRightBtn.SetSoundOver(&btnSoundOver); - GoRightBtn.SetSoundClick(&btnClick); - GoRightBtn.SetEffectGrow(); - GoRightBtn.SetTrigger(&trigA); - GoRightBtn.SetTrigger(&trigR); - GoRightBtn.SetTrigger(&trigPlus); - - char MainButtonText[50]; - snprintf(MainButtonText, sizeof(MainButtonText), "%s", " "); - - GuiImage MainButton1Img(&MainButtonImgData); - GuiImage MainButton1ImgOver(&MainButtonImgOverData); - GuiText MainButton1Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); - MainButton1Txt.SetMaxWidth(MainButton1Img.GetWidth()); - GuiButton MainButton1(MainButton1Img.GetWidth(), MainButton1Img.GetHeight()); - MainButton1.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton1.SetPosition(0, 90); - MainButton1.SetImage(&MainButton1Img); - MainButton1.SetImageOver(&MainButton1ImgOver); - MainButton1.SetLabel(&MainButton1Txt); - MainButton1.SetSoundOver(&btnSoundOver); - MainButton1.SetSoundClick(&btnClick1); - MainButton1.SetEffectGrow(); - MainButton1.SetTrigger(&trigA); - - GuiImage MainButton2Img(&MainButtonImgData); - GuiImage MainButton2ImgOver(&MainButtonImgOverData); - GuiText MainButton2Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255 }); - MainButton2Txt.SetMaxWidth(MainButton2Img.GetWidth()); - GuiButton MainButton2(MainButton2Img.GetWidth(), MainButton2Img.GetHeight()); - MainButton2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton2.SetPosition(0, 160); - MainButton2.SetImage(&MainButton2Img); - MainButton2.SetImageOver(&MainButton2ImgOver); - MainButton2.SetLabel(&MainButton2Txt); - MainButton2.SetSoundOver(&btnSoundOver); - MainButton2.SetSoundClick(&btnClick1); - MainButton2.SetEffectGrow(); - MainButton2.SetTrigger(&trigA); - - GuiImage MainButton3Img(&MainButtonImgData); - GuiImage MainButton3ImgOver(&MainButtonImgOverData); - GuiText MainButton3Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); - MainButton3Txt.SetMaxWidth(MainButton3Img.GetWidth()); - GuiButton MainButton3(MainButton3Img.GetWidth(), MainButton3Img.GetHeight()); - MainButton3.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton3.SetPosition(0, 230); - MainButton3.SetImage(&MainButton3Img); - MainButton3.SetImageOver(&MainButton3ImgOver); - MainButton3.SetLabel(&MainButton3Txt); - MainButton3.SetSoundOver(&btnSoundOver); - MainButton3.SetSoundClick(&btnClick1); - MainButton3.SetEffectGrow(); - MainButton3.SetTrigger(&trigA); - - GuiImage MainButton4Img(&MainButtonImgData); - GuiImage MainButton4ImgOver(&MainButtonImgOverData); - GuiText MainButton4Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); - MainButton4Txt.SetMaxWidth(MainButton4Img.GetWidth()); - GuiButton MainButton4(MainButton4Img.GetWidth(), MainButton4Img.GetHeight()); - MainButton4.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton4.SetPosition(0, 300); - MainButton4.SetImage(&MainButton4Img); - MainButton4.SetImageOver(&MainButton4ImgOver); - MainButton4.SetLabel(&MainButton4Txt); - MainButton4.SetSoundOver(&btnSoundOver); - MainButton4.SetSoundClick(&btnClick1); - MainButton4.SetEffectGrow(); - MainButton4.SetTrigger(&trigA); - - customOptionList options2(MAXOPTIONS); - GuiCustomOptionBrowser optionBrowser2(396, 280, &options2, CFG.theme_path, "bg_options_settings.png", bg_options_settings_png, 0, 150); - optionBrowser2.SetPosition(0, 90); - optionBrowser2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - - GuiWindow w(screenwidth, screenheight); - - int pageToDisplay = 1; - while ( pageToDisplay > 0) { //set pageToDisplay to 0 to quit - VIDEO_WaitVSync (); - - menu = MENU_NONE; - - if ( pageToDisplay == 1) { - /** Standard procedure made in all pages **/ - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); - - if (slidedirection == RIGHT) { - MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - while (MainButton1.GetEffect()>0) usleep(50); - } else if (slidedirection == LEFT) { - MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - while (MainButton1.GetEffect()>0) usleep(50); - } - - HaltGui(); - - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("GUI Settings")); - MainButton1Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Game Load")); - MainButton2Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Parental Control")); - MainButton3Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Sound")); - MainButton4Txt.SetText(MainButtonText); - - mainWindow->RemoveAll(); - mainWindow->Append(&w); - w.RemoveAll(); - w.Append(&settingsbackground); - w.Append(&PageIndicatorBtn1); - w.Append(&PageIndicatorBtn2); - w.Append(&PageIndicatorBtn3); - w.Append(&titleTxt); - w.Append(&backBtn); - w.Append(&homo); - w.Append(&GoRightBtn); - w.Append(&GoLeftBtn); - w.Append(&MainButton1); - w.Append(&MainButton2); - w.Append(&MainButton3); - w.Append(&MainButton4); - - PageIndicatorBtn1.SetAlpha(255); - PageIndicatorBtn2.SetAlpha(50); - PageIndicatorBtn3.SetAlpha(50); - - /** Creditsbutton change **/ - MainButton4.SetImage(&MainButton4Img); - MainButton4.SetImageOver(&MainButton4ImgOver); - - /** Disable ability to click through MainButtons */ - optionBrowser2.SetClickable(false); - /** Default no scrollbar and reset position **/ - optionBrowser2.SetScrollbar(0); - optionBrowser2.SetOffset(0); - - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); - - MainButton1.SetEffectGrow(); - MainButton2.SetEffectGrow(); - MainButton3.SetEffectGrow(); - MainButton4.SetEffectGrow(); - - if (slidedirection == FADE) { - MainButton1.SetEffect(EFFECT_FADE, 20); - MainButton2.SetEffect(EFFECT_FADE, 20); - MainButton3.SetEffect(EFFECT_FADE, 20); - MainButton4.SetEffect(EFFECT_FADE, 20); - } else if (slidedirection == LEFT) { - MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - } else if (slidedirection == RIGHT) { - MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - } - - mainWindow->Append(&w); - - ResumeGui(); - - while (MainButton1.GetEffect() > 0) usleep(50); - - } else if ( pageToDisplay == 2 ) { - /** Standard procedure made in all pages **/ - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); - - if (slidedirection == RIGHT) { - MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - while (MainButton1.GetEffect()>0) usleep(50); - } else if (slidedirection == LEFT) { - MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - while (MainButton1.GetEffect()>0) usleep(50); - } - - HaltGui(); - - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Custom Paths")); - MainButton1Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Update")); - MainButton2Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Default Settings")); - MainButton3Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Credits")); - MainButton4Txt.SetText(MainButtonText); - - mainWindow->RemoveAll(); - mainWindow->Append(&w); - w.RemoveAll(); - w.Append(&settingsbackground); - w.Append(&PageIndicatorBtn1); - w.Append(&PageIndicatorBtn2); - w.Append(&PageIndicatorBtn3); - w.Append(&titleTxt); - w.Append(&backBtn); - w.Append(&homo); - w.Append(&GoRightBtn); - w.Append(&GoLeftBtn); - w.Append(&MainButton1); - w.Append(&MainButton2); - w.Append(&MainButton3); - w.Append(&MainButton4); - - PageIndicatorBtn1.SetAlpha(50); - PageIndicatorBtn2.SetAlpha(255); - PageIndicatorBtn3.SetAlpha(50); - - /** Creditsbutton change **/ - MainButton4.SetImage(&creditsImg); - MainButton4.SetImageOver(&creditsImgOver); - - /** Disable ability to click through MainButtons */ - optionBrowser2.SetClickable(false); - /** Default no scrollbar and reset position **/ - optionBrowser2.SetScrollbar(0); - optionBrowser2.SetOffset(0); - - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); - - MainButton1.SetEffectGrow(); - MainButton2.SetEffectGrow(); - MainButton3.SetEffectGrow(); - MainButton4.SetEffectGrow(); - - if (slidedirection == FADE) { - MainButton1.SetEffect(EFFECT_FADE, 20); - MainButton2.SetEffect(EFFECT_FADE, 20); - MainButton3.SetEffect(EFFECT_FADE, 20); - MainButton4.SetEffect(EFFECT_FADE, 20); - } else if (slidedirection == LEFT) { - MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - } else if (slidedirection == RIGHT) { - MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - } - - mainWindow->Append(&w); - - ResumeGui(); - - while (MainButton1.GetEffect() > 0) usleep(50); - - } - else if ( pageToDisplay == 3 ) { - /** Standard procedure made in all pages **/ - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); - - if (slidedirection == RIGHT) { - MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); - while (MainButton1.GetEffect()>0) usleep(50); - } else if (slidedirection == LEFT) { - MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); - while (MainButton1.GetEffect()>0) usleep(50); - } - - HaltGui(); - - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Theme Downloader")); - MainButton1Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr(" ")); - MainButton2Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr(" ")); - MainButton3Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr(" ")); - MainButton4Txt.SetText(MainButtonText); - - mainWindow->RemoveAll(); - mainWindow->Append(&w); - w.RemoveAll(); - w.Append(&settingsbackground); - w.Append(&PageIndicatorBtn1); - w.Append(&PageIndicatorBtn2); - w.Append(&PageIndicatorBtn3); - w.Append(&titleTxt); - w.Append(&backBtn); - w.Append(&homo); - w.Append(&GoRightBtn); - w.Append(&GoLeftBtn); - w.Append(&MainButton1); - - PageIndicatorBtn1.SetAlpha(50); - PageIndicatorBtn2.SetAlpha(50); - PageIndicatorBtn3.SetAlpha(255); - - /** Disable ability to click through MainButtons */ - optionBrowser2.SetClickable(false); - /** Default no scrollbar and reset position **/ - optionBrowser2.SetScrollbar(0); - optionBrowser2.SetOffset(0); - - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); - - MainButton1.SetEffectGrow(); - MainButton2.SetEffectGrow(); - MainButton3.SetEffectGrow(); - MainButton4.SetEffectGrow(); - - if (slidedirection == FADE) { - MainButton1.SetEffect(EFFECT_FADE, 20); - MainButton2.SetEffect(EFFECT_FADE, 20); - MainButton3.SetEffect(EFFECT_FADE, 20); - MainButton4.SetEffect(EFFECT_FADE, 20); - } else if (slidedirection == LEFT) { - MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); - } else if (slidedirection == RIGHT) { - MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); - } - - mainWindow->Append(&w); - - ResumeGui(); - - while (MainButton1.GetEffect() > 0) usleep(50); - } - - while (menu == MENU_NONE) { - VIDEO_WaitVSync (); - - if ( pageToDisplay == 1 ) { - if (MainButton1.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton1.GetEffect() > 0) usleep(50); - HaltGui(); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - titleTxt.SetText(tr("GUI Settings")); - exit = false; - options2.SetLength(13); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetName(i, NULL); - options2.SetName(0, "%s",tr("App Language")); - options2.SetName(1, "%s",tr("Display")); - options2.SetName(2, "%s",tr("Clock")); - options2.SetName(3, "%s",tr("Tooltips")); - options2.SetName(4, "%s",tr("Flip-X")); - options2.SetName(5, "%s",tr("Prompts Buttons")); - options2.SetName(6, "%s",tr("Keyboard")); - options2.SetName(7, "%s",tr("Disc Artwork Download")); - options2.SetName(8, "%s",tr("Wiilight")); - options2.SetName(9, "%s",tr("Rumble")); - options2.SetName(10, "%s",tr("AutoInit Network")); - options2.SetName(11, "%s",tr("Titles from WiiTDB")); - options2.SetName(12, "%s",tr("Screensaver")); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetValue(i, NULL); - optionBrowser2.SetScrollbar(1); - w.Append(&optionBrowser2); - optionBrowser2.SetClickable(true); - ResumeGui(); - - VIDEO_WaitVSync (); - optionBrowser2.SetEffect(EFFECT_FADE, 20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - - int returnhere = 1; - char * languagefile; - languagefile = strrchr(Settings.language_path, '/')+1; - - while (!exit) { - VIDEO_WaitVSync (); - - returnhere = 1; - - if (Settings.sinfo >= settings_sinfo_max) - Settings.sinfo = 0; - if (Settings.hddinfo >= settings_clock_max) - Settings.hddinfo = 0; //CLOCK - if (Settings.tooltips >= settings_tooltips_max) - Settings.tooltips = 0; - if ( Settings.xflip >= settings_xflip_max) - Settings.xflip = 0; - if ( Settings.wsprompt > 1 ) - Settings.wsprompt = 0; - if ( Settings.keyset >= settings_keyset_max) - Settings.keyset = 0; - if ( Settings.wiilight > 2 ) - Settings.wiilight = 0; - if (Settings.rumble >= settings_rumble_max) - Settings.rumble = 0; //RUMBLE - if (Settings.screensaver >= settings_screensaver_max) - Settings.screensaver = 0; //RUMBLE - if (Settings.titlesOverride >= 2) - Settings.titlesOverride = 0; - if (Settings.discart >= 4) - Settings.discart = 0; - if (!strcmp("notset", Settings.language_path)) - options2.SetValue(0, "%s", tr("Default")); - else - options2.SetValue(0, "%s", languagefile); - - if (Settings.sinfo == GameID) options2.SetValue(1,"%s",tr("Game ID")); - else if (Settings.sinfo == GameRegion) options2.SetValue(1,"%s",tr("Game Region")); - else if (Settings.sinfo == Both) options2.SetValue(1,"%s",tr("Both")); - else if (Settings.sinfo == Neither) options2.SetValue(1,"%s",tr("Neither")); - - if (Settings.hddinfo == hr12) options2.SetValue(2,"12 %s",tr("Hour")); - else if (Settings.hddinfo == hr24) options2.SetValue(2,"24 %s",tr("Hour")); - else if (Settings.hddinfo == Off) options2.SetValue(2,"%s",tr("OFF")); - - if (Settings.tooltips == TooltipsOn) options2.SetValue(3,"%s",tr("ON")); - else if (Settings.tooltips == TooltipsOff) options2.SetValue(3,"%s",tr("OFF")); - - if (Settings.xflip == no) options2.SetValue(4,"%s/%s",tr("Right"),tr("Next")); - else if (Settings.xflip == yes) options2.SetValue(4,"%s/%s",tr("Left"),tr("Prev")); - else if (Settings.xflip == sysmenu) options2.SetValue(4,"%s", tr("Like SysMenu")); - else if (Settings.xflip == wtf) options2.SetValue(4,"%s/%s",tr("Right"),tr("Prev")); - else if (Settings.xflip == disk3d) options2.SetValue(4,tr("DiskFlip")); - - if (Settings.wsprompt == no) options2.SetValue(5,"%s",tr("Normal")); - else if (Settings.wsprompt == yes) options2.SetValue(5,"%s",tr("Widescreen Fix")); - - if (Settings.keyset == us) options2.SetValue(6,"QWERTY"); - else if (Settings.keyset == qwerty) options2.SetValue(6,"QWERTY 2"); - else if (Settings.keyset == dvorak) options2.SetValue(6,"DVORAK"); - else if (Settings.keyset == euro) options2.SetValue(6,"QWERTZ"); - else if (Settings.keyset == azerty) options2.SetValue(6,"AZERTY"); - - if (Settings.discart == 0) options2.SetValue(7,"%s",tr("Only Original")); - else if (Settings.discart == 1) options2.SetValue(7,tr("Only Customs")); - else if (Settings.discart == 2) options2.SetValue(7,tr("Original/Customs")); - else if (Settings.discart == 3) options2.SetValue(7,tr("Customs/Original")); - - if (Settings.wiilight == 0) options2.SetValue(8,"%s",tr("OFF")); - else if (Settings.wiilight == 1) options2.SetValue(8,"%s",tr("ON")); - else if (Settings.wiilight == 2) options2.SetValue(8,"%s",tr("Only for Install")); - - if (Settings.rumble == RumbleOn) options2.SetValue(9,"%s",tr("ON")); - else if (Settings.rumble == RumbleOff) options2.SetValue(9,"%s",tr("OFF")); - - if (Settings.autonetwork == on) options2.SetValue(10,"%s",tr("ON")); - else if (Settings.autonetwork == off) options2.SetValue(10,"%s",tr("OFF")); - - if (Settings.titlesOverride == 0) options2.SetValue(11,"%s",tr("OFF")); - else if (Settings.titlesOverride == 1) options2.SetValue(11,"%s",tr("ON")); - - if (Settings.screensaver == 0) options2.SetValue(12,"%s",tr("OFF")); - else if (Settings.screensaver == 1) options2.SetValue(12,tr("3 min")); - else if (Settings.screensaver == 2) options2.SetValue(12,tr("5 min")); - else if (Settings.screensaver == 3) options2.SetValue(12,tr("10 min")); - else if (Settings.screensaver == 4) options2.SetValue(12,tr("20 min")); - else if (Settings.screensaver == 5) options2.SetValue(12,tr("30 min")); - else if (Settings.screensaver == 6) options2.SetValue(12,tr("1 hour")); - - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } - - if (shutdown == 1) - Sys_Shutdown(); - else if (reset == 1) - Sys_Reboot(); - - else if (menu == MENU_DISCLIST) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - WindowCredits(); - w.Append(&optionBrowser2); - w.Append(&backBtn); - } else if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } - - ret = optionBrowser2.GetClickedOption(); - - switch (ret) { - case 0: - if (isInserted(bootDevice)) { - if ( Settings.godmode == 1) { - w.SetEffect(EFFECT_FADE, -20); - while (w.GetEffect()>0) usleep(50); - mainWindow->Remove(&w); - while (returnhere == 1) - returnhere = MenuLanguageSelect(); - if (returnhere == 2) { - menu = MENU_SETTINGS; - pageToDisplay = 0; - exit = true; - mainWindow->Append(&w); - break; - } else { - HaltGui(); - mainWindow->Append(&w); - w.SetEffect(EFFECT_FADE, 20); - ResumeGui(); - while (w.GetEffect()>0) usleep(50); - } - } else { - WindowPrompt(tr("Language change:"),tr("Console should be unlocked to modify it."),tr("OK")); - } - } else { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to use this option."), tr("OK")); - } - break; - case 1: - Settings.sinfo++; - break; - case 2: - Settings.hddinfo++; - break; - case 3: - Settings.tooltips++; - break; - case 4: - Settings.xflip++; - break; - case 5: - Settings.wsprompt++; - break; - case 6: - Settings.keyset++; - break; - case 7: - Settings.discart++; - break; - case 8: - Settings.wiilight++; - break; - case 9: - Settings.rumble++; - break; - case 10: - Settings.autonetwork++; - if (Settings.autonetwork > 1) - Settings.autonetwork = 0; - break; - case 11: - Settings.titlesOverride++; - break; - case 12: - Settings.screensaver++; - break; - - } - } - optionBrowser2.SetEffect(EFFECT_FADE, -20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - titleTxt.SetText(tr("Settings")); - slidedirection = FADE; - if (returnhere != 2) - pageToDisplay = 1; - MainButton1.ResetState(); - break; - } - - if (MainButton2.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton2.GetEffect() > 0) usleep(50); - HaltGui(); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - titleTxt.SetText(tr("Game Load")); - exit = false; - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetName(i, NULL); - options2.SetLength(8); - options2.SetName(0, "%s",tr("Video Mode")); - options2.SetName(1, "%s",tr("VIDTV Patch")); - options2.SetName(2, "%s",tr("Game Language")); - options2.SetName(3, "%s",tr("Patch Country Strings")); - options2.SetName(4, "Ocarina"); - options2.SetName(5,"%s", tr("Boot/Standard")); - options2.SetName(6, "%s",tr("Quick Boot")); - options2.SetName(7, "%s",tr("Error 002 fix")); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetValue(i, NULL); - w.Append(&optionBrowser2); - optionBrowser2.SetClickable(true); - ResumeGui(); - - VIDEO_WaitVSync (); - optionBrowser2.SetEffect(EFFECT_FADE, 20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - - while (!exit) { - VIDEO_WaitVSync (); - if (Settings.video >= settings_video_max) - Settings.video = 0; - if (Settings.vpatch >= settings_off_on_max) - Settings.vpatch = 0; - if ( Settings.patchcountrystrings > 1) - Settings.patchcountrystrings = 0; - if (Settings.ocarina >= settings_off_on_max) - Settings.ocarina = 0; - if ( Settings.qboot > 1 ) - Settings.qboot = 0; - if ( Settings.cios >= settings_cios_max) - Settings.cios = 0; - if ( Settings.language >= settings_language_max) - Settings.language = 0; - if (Settings.error002 >= settings_off_on_max+1) - Settings.error002 = 0; - - if (Settings.video == discdefault) options2.SetValue(0,"%s",tr("Disc Default")); - else if (Settings.video == systemdefault) options2.SetValue(0,"%s",tr("System Default")); - else if (Settings.video == patch) options2.SetValue(0,"%s",tr("AutoPatch")); - else if (Settings.video == pal50) options2.SetValue(0,"%s PAL50",tr("Force")); - else if (Settings.video == pal60) options2.SetValue(0,"%s PAL60",tr("Force")); - else if (Settings.video == ntsc) options2.SetValue(0,"%s NTSC",tr("Force")); - - if (Settings.vpatch == on) options2.SetValue(1,"%s",tr("ON")); - else if (Settings.vpatch == off) options2.SetValue(1,"%s",tr("OFF")); - - if (Settings.language == ConsoleLangDefault) options2.SetValue(2,"%s",tr("Console Default")); - else if (Settings.language == jap) options2.SetValue(2,"%s",tr("Japanese")); - else if (Settings.language == ger) options2.SetValue(2,"%s",tr("German")); - else if (Settings.language == eng) options2.SetValue(2,"%s",tr("English")); - else if (Settings.language == fren) options2.SetValue(2,"%s",tr("French")); - else if (Settings.language == esp) options2.SetValue(2,"%s",tr("Spanish")); - else if (Settings.language == it) options2.SetValue(2,"%s",tr("Italian")); - else if (Settings.language == dut) options2.SetValue(2,"%s",tr("Dutch")); - else if (Settings.language == schin) options2.SetValue(2,"%s",tr("SChinese")); - else if (Settings.language == tchin) options2.SetValue(2,"%s",tr("TChinese")); - else if (Settings.language == kor) options2.SetValue(2,"%s",tr("Korean")); - - if (Settings.patchcountrystrings == 0) options2.SetValue(3,"%s",tr("OFF")); - else if (Settings.patchcountrystrings == 1) options2.SetValue(3,"%s",tr("ON")); - - if (Settings.ocarina == on) options2.SetValue(4,"%s",tr("ON")); - else if (Settings.ocarina == off) options2.SetValue(4,"%s",tr("OFF")); - - if (Settings.godmode != 1) options2.SetValue(5, "********"); - else if (Settings.cios == ios249) options2.SetValue(5,"cIOS 249"); - else if (Settings.cios == ios222) options2.SetValue(5,"cIOS 222"); - - if (Settings.qboot == no) options2.SetValue(6,"%s",tr("No")); - else if (Settings.qboot == yes) options2.SetValue(6,"%s",tr("Yes")); - - if (Settings.error002 == no) options2.SetValue(7,"%s",tr("No")); - else if (Settings.error002 == yes) options2.SetValue(7,"%s",tr("Yes")); - else if (Settings.error002 == anti) options2.SetValue(7,"%s",tr("Anti")); - - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } - - if (shutdown == 1) - Sys_Shutdown(); - else if (reset == 1) - Sys_Reboot(); - - else if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } - - ret = optionBrowser2.GetClickedOption(); - - switch (ret) { - case 0: - Settings.video++; - break; - case 1: - Settings.vpatch++; - break; - case 2: - Settings.language++; - break; - case 3: - Settings.patchcountrystrings++; - break; - case 4: - Settings.ocarina++; - break; - case 5: - if (Settings.godmode) - Settings.cios++; - break; - case 6: - Settings.qboot++; - break; - case 7: - Settings.error002++; - break; - - } - } - optionBrowser2.SetEffect(EFFECT_FADE, -20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - titleTxt.SetText(tr("Settings")); - slidedirection = FADE; - pageToDisplay = 1; - MainButton2.ResetState(); - break; - } - - if (MainButton3.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton3.GetEffect() > 0) usleep(50); - HaltGui(); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - titleTxt.SetText(tr("Parental Control")); - exit = false; - options2.SetLength(3); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetName(i, NULL); - options2.SetName(0, "%s",tr("Console")); - options2.SetName(1, "%s",tr("Password")); - options2.SetName(2, "%s",tr("Controllevel")); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetValue(i, NULL); - w.Append(&optionBrowser2); - optionBrowser2.SetClickable(true); - ResumeGui(); - - VIDEO_WaitVSync (); - optionBrowser2.SetEffect(EFFECT_FADE, 20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - - while (!exit) { - VIDEO_WaitVSync (); - - if (Settings.parentalcontrol > 4 ) - Settings.parentalcontrol = 0; - - if ( Settings.godmode == 1 ) options2.SetValue(0, tr("Unlocked")); - else if ( Settings.godmode == 0 ) options2.SetValue(0, tr("Locked")); - - if ( Settings.godmode != 1) options2.SetValue(1, "********"); - else if (!strcmp("", Settings.unlockCode)) options2.SetValue(1, "%s",tr("not set")); - else options2.SetValue(1, Settings.unlockCode); - - if (Settings.godmode != 1) options2.SetValue(2, "********"); - else if (Settings.parentalcontrol == 0) options2.SetValue(2, tr("OFF")); - else if (Settings.parentalcontrol == 1) options2.SetValue(2, tr("1 (Child 7+)")); - else if (Settings.parentalcontrol == 2) options2.SetValue(2, tr("2 (Teen 12+)")); - else if (Settings.parentalcontrol == 3) options2.SetValue(2, tr("3 (Mature 16+)")); - else if (Settings.parentalcontrol == 4) options2.SetValue(2, tr("4 (Adults Only 18+)")); - - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } - - if (shutdown == 1) - Sys_Shutdown(); - else if (reset == 1) - Sys_Reboot(); - - else if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } - - ret = optionBrowser2.GetClickedOption(); - - switch (ret) { - case 0: - if (!strcmp("", Settings.unlockCode)) { - Settings.godmode = !Settings.godmode; - break; - } else if ( Settings.godmode == 0 ) { - //password check to unlock Install,Delete and Format - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[20] = ""; - int result = OnScreenKeyboard(entered, 20,0); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - if (!strcmp(entered, Settings.unlockCode)) { //if password correct - if (Settings.godmode == 0) { - WindowPrompt(tr("Correct Password"),tr("All the features of USB Loader GX are unlocked."),tr("OK")); - Settings.godmode = 1; - //__Menu_GetEntries(); - menu = MENU_DISCLIST; - } - } else { - WindowPrompt(tr("Wrong Password"),tr("USB Loader GX is protected"),tr("OK")); - } - } - } else { - int choice = WindowPrompt (tr("Lock Console"),tr("Are you sure?"),tr("Yes"),tr("No")); - if (choice == 1) { - WindowPrompt(tr("Console Locked"),tr("USB Loader GX is protected"),tr("OK")); - Settings.godmode = 0; - //__Menu_GetEntries(); - menu = MENU_DISCLIST; - } - } - break; - case 1:// Modify Password - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[20] = ""; - strlcpy(entered, Settings.unlockCode, sizeof(entered)); - int result = OnScreenKeyboard(entered, 20,0); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - strlcpy(Settings.unlockCode, entered, sizeof(Settings.unlockCode)); - WindowPrompt(tr("Password Changed"),tr("Password has been changed"),tr("OK")); - } - } else { - WindowPrompt(tr("Password Changed"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 2: - if (Settings.godmode) - Settings.parentalcontrol++; - break; - } - } - optionBrowser2.SetEffect(EFFECT_FADE, -20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - titleTxt.SetText(tr("Settings")); - slidedirection = FADE; - pageToDisplay = 1; - MainButton3.ResetState(); - break; - } - - if (MainButton4.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton4.GetEffect() > 0) usleep(50); - HaltGui(); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - titleTxt.SetText(tr("Sound")); - exit = false; - options2.SetLength(3); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetName(i, NULL); - options2.SetName(0, "%s",tr("Backgroundmusic")); - options2.SetName(1, "%s",tr("Music Volume")); - options2.SetName(2, "%s",tr("SFX Volume")); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetValue(i, NULL); - w.Append(&optionBrowser2); - optionBrowser2.SetClickable(true); - ResumeGui(); - - VIDEO_WaitVSync (); - optionBrowser2.SetEffect(EFFECT_FADE, 20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - - - char * oggfile; - - while (!exit) { - VIDEO_WaitVSync (); - - bool returnhere = true; - - if (!strcmp("notset", Settings.ogg_path)) - options2.SetValue(0, "%s", tr("Standard")); - else { - oggfile = strrchr(Settings.ogg_path, '/')+1; - options2.SetValue(0, "%s", oggfile); - } - - if (Settings.volume > 0) - options2.SetValue(1,"%i", Settings.volume); - else - options2.SetValue(1,"%s", tr("OFF")); - if (Settings.sfxvolume > 0) - options2.SetValue(2,"%i", Settings.sfxvolume); - else - options2.SetValue(2,"%s", tr("OFF")); - - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } - - if (shutdown == 1) - Sys_Shutdown(); - else if (reset == 1) - Sys_Reboot(); - - else if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } - - ret = optionBrowser2.GetClickedOption(); - - switch (ret) { - case 0: - if (isInserted(bootDevice)) { - w.SetEffect(EFFECT_FADE, -20); - while (w.GetEffect()>0) usleep(50); - mainWindow->Remove(&w); - while (returnhere) - returnhere = MenuOGG(); - HaltGui(); - mainWindow->Append(&w); - w.SetEffect(EFFECT_FADE, 20); - ResumeGui(); - while (w.GetEffect()>0) usleep(50); - } else - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to use this option."), tr("OK")); - break; - case 1: - Settings.volume += 10; - if (Settings.volume > 100) - Settings.volume = 0; - SetVolumeOgg(255*(Settings.volume/100.0)); - break; - case 2: - Settings.sfxvolume += 10; - if (Settings.sfxvolume > 100) - Settings.sfxvolume = 0; - btnSoundOver.SetVolume(Settings.sfxvolume); - btnClick.SetVolume(Settings.sfxvolume); - btnClick1.SetVolume(Settings.sfxvolume); - break; - } - } - optionBrowser2.SetEffect(EFFECT_FADE, -20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - titleTxt.SetText(tr("Settings")); - slidedirection = FADE; - pageToDisplay = 1; - MainButton4.ResetState(); - break; - } - } - - if ( pageToDisplay == 2) { - if (MainButton1.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton1.GetEffect() > 0) usleep(50); - HaltGui(); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - titleTxt.SetText(tr("Custom Paths")); - exit = false; - options2.SetLength(11); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetName(i, NULL); - options2.SetName(0, "%s", tr("3D Cover Path")); - options2.SetName(1, "%s", tr("2D Cover Path")); - options2.SetName(2, "%s", tr("Disc Artwork Path")); - options2.SetName(3, "%s", tr("Theme Path")); - options2.SetName(4, "%s", tr("WiiTDB Path")); - options2.SetName(5, "%s", tr("Update Path")); - options2.SetName(6, "%s", tr("GCT Cheatcodes Path")); - options2.SetName(7, "%s", tr("TXT Cheatcodes Path")); - options2.SetName(8, "%s", tr("DOL Path")); - options2.SetName(9, "%s", tr("Homebrew Apps Path")); - options2.SetName(10, "%s", tr("Theme Download Path")); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetValue(i, NULL); - optionBrowser2.SetScrollbar(1); - w.Append(&optionBrowser2); - optionBrowser2.SetClickable(true); - ResumeGui(); - - VIDEO_WaitVSync (); - optionBrowser2.SetEffect(EFFECT_FADE, 20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - - if (Settings.godmode) { - - while (!exit) { - VIDEO_WaitVSync (); - - options2.SetValue(0, "%s", Settings.covers_path); - options2.SetValue(1, "%s", Settings.covers2d_path); - options2.SetValue(2, "%s", Settings.disc_path); - options2.SetValue(3, "%s", CFG.theme_path); - options2.SetValue(4, "%s", Settings.titlestxt_path); - options2.SetValue(5, "%s", Settings.update_path); - options2.SetValue(6, "%s", Settings.Cheatcodespath); - options2.SetValue(7, "%s", Settings.TxtCheatcodespath); - options2.SetValue(8, "%s", Settings.dolpath); - options2.SetValue(9, "%s", Settings.homebrewapps_path); - options2.SetValue(10, "%s", Settings.theme_downloadpath); - - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } - - if (shutdown == 1) - Sys_Shutdown(); - else if (reset == 1) - Sys_Reboot(); - - else if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } - - ret = optionBrowser2.GetClickedOption(); - - switch (ret) { - case 0: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.covers_path, sizeof(entered)); - titleTxt.SetText(tr("3D Cover Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.covers_path, entered, sizeof(Settings.covers_path)); - WindowPrompt(tr("Cover Path Changed"),0,tr("OK")); - if (!isInserted(bootDevice)) { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } - } - } else { - WindowPrompt(tr("Cover Path Change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 1: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.covers2d_path, sizeof(entered)); - titleTxt.SetText(tr("2D Cover Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.covers2d_path, entered, sizeof(Settings.covers2d_path)); - WindowPrompt(tr("Cover Path Changed"),0,tr("OK")); - if (!isInserted(bootDevice)) { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } - } - } else { - WindowPrompt(tr("Cover Path Change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 2: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.disc_path, sizeof(entered)); - titleTxt.SetText(tr("Disc Artwork Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.disc_path, entered, sizeof(Settings.disc_path)); - WindowPrompt(tr("Disc Path Changed"),0,tr("OK")); - if (!isInserted(bootDevice)) { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } - } - } else { - WindowPrompt(tr("Disc Path change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 3: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - titleTxt.SetText(tr("Theme Path")); - strlcpy(entered, CFG.theme_path, sizeof(entered)); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - HaltGui(); - w.RemoveAll(); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(CFG.theme_path, entered, sizeof(CFG.theme_path)); - WindowPrompt(tr("Theme Path Changed"),0,tr("OK")); - if (!isInserted(bootDevice)) { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } else { - cfg_save_global(); - } - mainWindow->Remove(bgImg); + enum + { + FADE, + LEFT, + RIGHT + }; + + int slidedirection = FADE; + + GuiSound btnSoundOver(button_over_pcm, button_over_pcm_size, SOUND_PCM, Settings.sfxvolume); + GuiSound btnClick(button_click2_pcm, button_click2_pcm_size, SOUND_PCM, Settings.sfxvolume); + GuiSound btnClick1(button_click_pcm, button_click_pcm_size, SOUND_PCM, Settings.sfxvolume); + + char imgPath[100]; + + snprintf(imgPath, sizeof(imgPath), "%sbutton_dialogue_box.png", CFG.theme_path); + GuiImageData btnOutline(imgPath, button_dialogue_box_png); + snprintf(imgPath, sizeof(imgPath), "%ssettings_background.png", CFG.theme_path); + GuiImageData settingsbg(imgPath, settings_background_png); + + snprintf(imgPath, sizeof(imgPath), "%ssettings_title.png", CFG.theme_path); + GuiImageData MainButtonImgData(imgPath, settings_title_png); + + snprintf(imgPath, sizeof(imgPath), "%ssettings_title_over.png", CFG.theme_path); + GuiImageData MainButtonImgOverData(imgPath, settings_title_over_png); + + snprintf(imgPath, sizeof(imgPath), "%spageindicator.png", CFG.theme_path); + GuiImageData PageindicatorImgData(imgPath, pageindicator_png); + + snprintf(imgPath, sizeof(imgPath), "%sstartgame_arrow_left.png", CFG.theme_path); + GuiImageData arrow_left(imgPath, startgame_arrow_left_png); + + snprintf(imgPath, sizeof(imgPath), "%sstartgame_arrow_right.png", CFG.theme_path); + GuiImageData arrow_right(imgPath, startgame_arrow_right_png); + + snprintf(imgPath, sizeof(imgPath), "%scredits_button.png", CFG.theme_path); + GuiImageData creditsImgData(imgPath, credits_button_png); + + snprintf(imgPath, sizeof(imgPath), "%scredits_button_over.png", CFG.theme_path); + GuiImageData creditsOver(imgPath, credits_button_over_png); + + GuiImage creditsImg(&creditsImgData); + GuiImage creditsImgOver(&creditsOver); + + GuiTrigger trigA; + trigA.SetSimpleTrigger(-1, WPAD_BUTTON_A | WPAD_CLASSIC_BUTTON_A, PAD_BUTTON_A); + GuiTrigger trigHome; + trigHome.SetButtonOnlyTrigger(-1, WPAD_BUTTON_HOME | WPAD_CLASSIC_BUTTON_HOME, 0); + GuiTrigger trigB; + trigB.SetButtonOnlyTrigger(-1, WPAD_BUTTON_B | WPAD_CLASSIC_BUTTON_B, PAD_BUTTON_B); + GuiTrigger trigL; + trigL.SetButtonOnlyTrigger(-1, WPAD_BUTTON_LEFT | WPAD_CLASSIC_BUTTON_LEFT, PAD_BUTTON_LEFT); + GuiTrigger trigR; + trigR.SetButtonOnlyTrigger(-1, WPAD_BUTTON_RIGHT | WPAD_CLASSIC_BUTTON_RIGHT, PAD_BUTTON_RIGHT); + GuiTrigger trigMinus; + trigMinus.SetButtonOnlyTrigger(-1, WPAD_BUTTON_MINUS | WPAD_CLASSIC_BUTTON_MINUS, 0); + GuiTrigger trigPlus; + trigPlus.SetButtonOnlyTrigger(-1, WPAD_BUTTON_PLUS | WPAD_CLASSIC_BUTTON_PLUS, 0); + + GuiText titleTxt(tr("Settings"), 28, (GXColor) {0, 0, 0, 255}); + titleTxt.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + titleTxt.SetPosition(0,40); + + GuiImage settingsbackground(&settingsbg); + + GuiText backBtnTxt(tr("Back") , 22, THEME.prompttext); + backBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); + GuiImage backBtnImg(&btnOutline); + if (Settings.wsprompt == yes) + { + backBtnTxt.SetWidescreen(CFG.widescreen); + backBtnImg.SetWidescreen(CFG.widescreen); + } + GuiButton backBtn(&backBtnImg,&backBtnImg, 2, 3, -180, 400, &trigA, &btnSoundOver, &btnClick,1); + backBtn.SetLabel(&backBtnTxt); + backBtn.SetTrigger(&trigB); + + GuiButton homo(1,1); + homo.SetTrigger(&trigHome); + + GuiImage PageindicatorImg1(&PageindicatorImgData); + GuiText PageindicatorTxt1("1", 22, (GXColor) { 0, 0, 0, 255}); + GuiButton PageIndicatorBtn1(PageindicatorImg1.GetWidth(), PageindicatorImg1.GetHeight()); + PageIndicatorBtn1.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + PageIndicatorBtn1.SetPosition(165, 400); + PageIndicatorBtn1.SetImage(&PageindicatorImg1); + PageIndicatorBtn1.SetLabel(&PageindicatorTxt1); + PageIndicatorBtn1.SetSoundOver(&btnSoundOver); + PageIndicatorBtn1.SetSoundClick(&btnClick1); + PageIndicatorBtn1.SetTrigger(&trigA); + PageIndicatorBtn1.SetEffectGrow(); + + GuiImage PageindicatorImg2(&PageindicatorImgData); + GuiText PageindicatorTxt2("2", 22, (GXColor) {0, 0, 0, 255}); + GuiButton PageIndicatorBtn2(PageindicatorImg2.GetWidth(), PageindicatorImg2.GetHeight()); + PageIndicatorBtn2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + PageIndicatorBtn2.SetPosition(200, 400); + PageIndicatorBtn2.SetImage(&PageindicatorImg2); + PageIndicatorBtn2.SetLabel(&PageindicatorTxt2); + PageIndicatorBtn2.SetSoundOver(&btnSoundOver); + PageIndicatorBtn2.SetSoundClick(&btnClick1); + PageIndicatorBtn2.SetTrigger(&trigA); + PageIndicatorBtn2.SetEffectGrow(); + + GuiImage PageindicatorImg3(&PageindicatorImgData); + GuiText PageindicatorTxt3("3", 22, (GXColor) {0, 0, 0, 255}); + GuiButton PageIndicatorBtn3(PageindicatorImg3.GetWidth(), PageindicatorImg3.GetHeight()); + PageIndicatorBtn3.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + PageIndicatorBtn3.SetPosition(235, 400); + PageIndicatorBtn3.SetImage(&PageindicatorImg3); + PageIndicatorBtn3.SetLabel(&PageindicatorTxt3); + PageIndicatorBtn3.SetSoundOver(&btnSoundOver); + PageIndicatorBtn3.SetSoundClick(&btnClick1); + PageIndicatorBtn3.SetTrigger(&trigA); + PageIndicatorBtn3.SetEffectGrow(); + + GuiImage GoLeftImg(&arrow_left); + GuiButton GoLeftBtn(GoLeftImg.GetWidth(), GoLeftImg.GetHeight()); + GoLeftBtn.SetAlignment(ALIGN_LEFT, ALIGN_MIDDLE); + GoLeftBtn.SetPosition(25, -25); + GoLeftBtn.SetImage(&GoLeftImg); + GoLeftBtn.SetSoundOver(&btnSoundOver); + GoLeftBtn.SetSoundClick(&btnClick); + GoLeftBtn.SetEffectGrow(); + GoLeftBtn.SetTrigger(&trigA); + GoLeftBtn.SetTrigger(&trigL); + GoLeftBtn.SetTrigger(&trigMinus); + + GuiImage GoRightImg(&arrow_right); + GuiButton GoRightBtn(GoRightImg.GetWidth(), GoRightImg.GetHeight()); + GoRightBtn.SetAlignment(ALIGN_RIGHT, ALIGN_MIDDLE); + GoRightBtn.SetPosition(-25, -25); + GoRightBtn.SetImage(&GoRightImg); + GoRightBtn.SetSoundOver(&btnSoundOver); + GoRightBtn.SetSoundClick(&btnClick); + GoRightBtn.SetEffectGrow(); + GoRightBtn.SetTrigger(&trigA); + GoRightBtn.SetTrigger(&trigR); + GoRightBtn.SetTrigger(&trigPlus); + + char MainButtonText[50]; + snprintf(MainButtonText, sizeof(MainButtonText), "%s", " "); + + GuiImage MainButton1Img(&MainButtonImgData); + GuiImage MainButton1ImgOver(&MainButtonImgOverData); + GuiText MainButton1Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); + MainButton1Txt.SetMaxWidth(MainButton1Img.GetWidth()); + GuiButton MainButton1(MainButton1Img.GetWidth(), MainButton1Img.GetHeight()); + MainButton1.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton1.SetPosition(0, 90); + MainButton1.SetImage(&MainButton1Img); + MainButton1.SetImageOver(&MainButton1ImgOver); + MainButton1.SetLabel(&MainButton1Txt); + MainButton1.SetSoundOver(&btnSoundOver); + MainButton1.SetSoundClick(&btnClick1); + MainButton1.SetEffectGrow(); + MainButton1.SetTrigger(&trigA); + + GuiImage MainButton2Img(&MainButtonImgData); + GuiImage MainButton2ImgOver(&MainButtonImgOverData); + GuiText MainButton2Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255 }); + MainButton2Txt.SetMaxWidth(MainButton2Img.GetWidth()); + GuiButton MainButton2(MainButton2Img.GetWidth(), MainButton2Img.GetHeight()); + MainButton2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton2.SetPosition(0, 160); + MainButton2.SetImage(&MainButton2Img); + MainButton2.SetImageOver(&MainButton2ImgOver); + MainButton2.SetLabel(&MainButton2Txt); + MainButton2.SetSoundOver(&btnSoundOver); + MainButton2.SetSoundClick(&btnClick1); + MainButton2.SetEffectGrow(); + MainButton2.SetTrigger(&trigA); + + GuiImage MainButton3Img(&MainButtonImgData); + GuiImage MainButton3ImgOver(&MainButtonImgOverData); + GuiText MainButton3Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); + MainButton3Txt.SetMaxWidth(MainButton3Img.GetWidth()); + GuiButton MainButton3(MainButton3Img.GetWidth(), MainButton3Img.GetHeight()); + MainButton3.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton3.SetPosition(0, 230); + MainButton3.SetImage(&MainButton3Img); + MainButton3.SetImageOver(&MainButton3ImgOver); + MainButton3.SetLabel(&MainButton3Txt); + MainButton3.SetSoundOver(&btnSoundOver); + MainButton3.SetSoundClick(&btnClick1); + MainButton3.SetEffectGrow(); + MainButton3.SetTrigger(&trigA); + + GuiImage MainButton4Img(&MainButtonImgData); + GuiImage MainButton4ImgOver(&MainButtonImgOverData); + GuiText MainButton4Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); + MainButton4Txt.SetMaxWidth(MainButton4Img.GetWidth()); + GuiButton MainButton4(MainButton4Img.GetWidth(), MainButton4Img.GetHeight()); + MainButton4.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton4.SetPosition(0, 300); + MainButton4.SetImage(&MainButton4Img); + MainButton4.SetImageOver(&MainButton4ImgOver); + MainButton4.SetLabel(&MainButton4Txt); + MainButton4.SetSoundOver(&btnSoundOver); + MainButton4.SetSoundClick(&btnClick1); + MainButton4.SetEffectGrow(); + MainButton4.SetTrigger(&trigA); + + customOptionList options2(MAXOPTIONS); + GuiCustomOptionBrowser optionBrowser2(396, 280, &options2, CFG.theme_path, "bg_options_settings.png", bg_options_settings_png, 0, 150); + optionBrowser2.SetPosition(0, 90); + optionBrowser2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + + GuiWindow w(screenwidth, screenheight); + + int pageToDisplay = 1; + while ( pageToDisplay > 0) { //set pageToDisplay to 0 to quit + VIDEO_WaitVSync (); + + menu = MENU_NONE; + + if ( pageToDisplay == 1) + { + /** Standard procedure made in all pages **/ + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); + + if (slidedirection == RIGHT) + { + MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + while (MainButton1.GetEffect()>0) usleep(50); + } + else if (slidedirection == LEFT) + { + MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + while (MainButton1.GetEffect()>0) usleep(50); + } + + HaltGui(); + + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("GUI Settings")); + MainButton1Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Game Load")); + MainButton2Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Parental Control")); + MainButton3Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Sound")); + MainButton4Txt.SetText(MainButtonText); + + mainWindow->RemoveAll(); + mainWindow->Append(&w); + w.RemoveAll(); + w.Append(&settingsbackground); + w.Append(&PageIndicatorBtn1); + w.Append(&PageIndicatorBtn2); + w.Append(&PageIndicatorBtn3); + w.Append(&titleTxt); + w.Append(&backBtn); + w.Append(&homo); + w.Append(&GoRightBtn); + w.Append(&GoLeftBtn); + w.Append(&MainButton1); + w.Append(&MainButton2); + w.Append(&MainButton3); + w.Append(&MainButton4); + + PageIndicatorBtn1.SetAlpha(255); + PageIndicatorBtn2.SetAlpha(50); + PageIndicatorBtn3.SetAlpha(50); + + /** Creditsbutton change **/ + MainButton4.SetImage(&MainButton4Img); + MainButton4.SetImageOver(&MainButton4ImgOver); + + /** Disable ability to click through MainButtons */ + optionBrowser2.SetClickable(false); + /** Default no scrollbar and reset position **/ +// optionBrowser2.SetScrollbar(0); + optionBrowser2.SetOffset(0); + + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); + + MainButton1.SetEffectGrow(); + MainButton2.SetEffectGrow(); + MainButton3.SetEffectGrow(); + MainButton4.SetEffectGrow(); + + if (slidedirection == FADE) + { + MainButton1.SetEffect(EFFECT_FADE, 20); + MainButton2.SetEffect(EFFECT_FADE, 20); + MainButton3.SetEffect(EFFECT_FADE, 20); + MainButton4.SetEffect(EFFECT_FADE, 20); + } + else if (slidedirection == LEFT) + { + MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + } + else if (slidedirection == RIGHT) + { + MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + } + + mainWindow->Append(&w); + + ResumeGui(); + + while (MainButton1.GetEffect() > 0) usleep(50); + + } + else if ( pageToDisplay == 2 ) + { + /** Standard procedure made in all pages **/ + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); + + if (slidedirection == RIGHT) + { + MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + while (MainButton1.GetEffect()>0) usleep(50); + } + else if (slidedirection == LEFT) + { + MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + while (MainButton1.GetEffect()>0) usleep(50); + } + + HaltGui(); + + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Custom Paths")); + MainButton1Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Update")); + MainButton2Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Default Settings")); + MainButton3Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Credits")); + MainButton4Txt.SetText(MainButtonText); + + mainWindow->RemoveAll(); + mainWindow->Append(&w); + w.RemoveAll(); + w.Append(&settingsbackground); + w.Append(&PageIndicatorBtn1); + w.Append(&PageIndicatorBtn2); + w.Append(&PageIndicatorBtn3); + w.Append(&titleTxt); + w.Append(&backBtn); + w.Append(&homo); + w.Append(&GoRightBtn); + w.Append(&GoLeftBtn); + w.Append(&MainButton1); + w.Append(&MainButton2); + w.Append(&MainButton3); + w.Append(&MainButton4); + + PageIndicatorBtn1.SetAlpha(50); + PageIndicatorBtn2.SetAlpha(255); + PageIndicatorBtn3.SetAlpha(50); + + /** Creditsbutton change **/ + MainButton4.SetImage(&creditsImg); + MainButton4.SetImageOver(&creditsImgOver); + + /** Disable ability to click through MainButtons */ + optionBrowser2.SetClickable(false); + /** Default no scrollbar and reset position **/ +// optionBrowser2.SetScrollbar(0); + optionBrowser2.SetOffset(0); + + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); + + MainButton1.SetEffectGrow(); + MainButton2.SetEffectGrow(); + MainButton3.SetEffectGrow(); + MainButton4.SetEffectGrow(); + + if (slidedirection == FADE) + { + MainButton1.SetEffect(EFFECT_FADE, 20); + MainButton2.SetEffect(EFFECT_FADE, 20); + MainButton3.SetEffect(EFFECT_FADE, 20); + MainButton4.SetEffect(EFFECT_FADE, 20); + } + else if (slidedirection == LEFT) + { + MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + } + else if (slidedirection == RIGHT) + { + MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + } + + mainWindow->Append(&w); + + ResumeGui(); + + while (MainButton1.GetEffect() > 0) usleep(50); + + } + else if ( pageToDisplay == 3 ) + { + /** Standard procedure made in all pages **/ + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); + + if (slidedirection == RIGHT) + { + MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 35); + while (MainButton1.GetEffect()>0) usleep(50); + } + else if (slidedirection == LEFT) + { + MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_OUT, 35); + while (MainButton1.GetEffect()>0) usleep(50); + } + + HaltGui(); + + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Theme Downloader")); + MainButton1Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr(" ")); + MainButton2Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr(" ")); + MainButton3Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr(" ")); + MainButton4Txt.SetText(MainButtonText); + + mainWindow->RemoveAll(); + mainWindow->Append(&w); + w.RemoveAll(); + w.Append(&settingsbackground); + w.Append(&PageIndicatorBtn1); + w.Append(&PageIndicatorBtn2); + w.Append(&PageIndicatorBtn3); + w.Append(&titleTxt); + w.Append(&backBtn); + w.Append(&homo); + w.Append(&GoRightBtn); + w.Append(&GoLeftBtn); + w.Append(&MainButton1); + + PageIndicatorBtn1.SetAlpha(50); + PageIndicatorBtn2.SetAlpha(50); + PageIndicatorBtn3.SetAlpha(255); + + /** Disable ability to click through MainButtons */ + optionBrowser2.SetClickable(false); + /** Default no scrollbar and reset position **/ +// optionBrowser2.SetScrollbar(0); + optionBrowser2.SetOffset(0); + + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); + + MainButton1.SetEffectGrow(); + MainButton2.SetEffectGrow(); + MainButton3.SetEffectGrow(); + MainButton4.SetEffectGrow(); + + if (slidedirection == FADE) + { + MainButton1.SetEffect(EFFECT_FADE, 20); + MainButton2.SetEffect(EFFECT_FADE, 20); + MainButton3.SetEffect(EFFECT_FADE, 20); + MainButton4.SetEffect(EFFECT_FADE, 20); + } + else if (slidedirection == LEFT) + { + MainButton1.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton2.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton3.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + MainButton4.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 35); + } + else if (slidedirection == RIGHT) + { + MainButton1.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton2.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton3.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + MainButton4.SetEffect(EFFECT_SLIDE_RIGHT | EFFECT_SLIDE_IN, 35); + } + + mainWindow->Append(&w); + + ResumeGui(); + + while (MainButton1.GetEffect() > 0) usleep(50); + } + + while (menu == MENU_NONE) + { + VIDEO_WaitVSync (); + + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + + if ( pageToDisplay == 1 ) + { + if (MainButton1.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton1.GetEffect() > 0) usleep(50); + HaltGui(); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + titleTxt.SetText(tr("GUI Settings")); + exit = false; + options2.SetLength(0); +// optionBrowser2.SetScrollbar(1); + w.Append(&optionBrowser2); + optionBrowser2.SetClickable(true); + ResumeGui(); + + VIDEO_WaitVSync (); + optionBrowser2.SetEffect(EFFECT_FADE, 20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + + int returnhere = 1; + char * languagefile; + languagefile = strrchr(Settings.language_path, '/')+1; + + bool firstRun = true; + while (!exit) + { + VIDEO_WaitVSync (); + + returnhere = 1; + + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + + else if (backBtn.GetState() == STATE_CLICKED) + { + backBtn.ResetState(); + exit = true; + break; + } + + else if (menu == MENU_DISCLIST) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + WindowCredits(); + w.Append(&optionBrowser2); + w.Append(&backBtn); + } + + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } + + ret = optionBrowser2.GetClickedOption(); + + if(firstRun || ret >= 0) + { + int Idx = -1; + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("App Language")); + if(ret == Idx) + { + if (isInserted(bootDevice)) + { + if ( Settings.godmode == 1) + { + w.SetEffect(EFFECT_FADE, -20); + while (w.GetEffect()>0) usleep(50); + mainWindow->Remove(&w); + while (returnhere == 1) + returnhere = MenuLanguageSelect(); + if (returnhere == 2) + { + menu = MENU_SETTINGS; + pageToDisplay = 0; + exit = true; + mainWindow->Append(&w); + break; + } + else + { + HaltGui(); + mainWindow->Append(&w); + w.SetEffect(EFFECT_FADE, 20); + ResumeGui(); + while (w.GetEffect()>0) usleep(50); + } + } + else + { + WindowPrompt(tr("Language change:"),tr("Console should be unlocked to modify it."),tr("OK")); + } + } + else + { + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to use this option."), tr("OK")); + } + } + + if (!strcmp("notset", Settings.language_path)) + options2.SetValue(Idx, "%s", tr("Default")); + else + options2.SetValue(Idx, "%s", languagefile); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Display")); + if(ret == Idx && ++Settings.sinfo >= settings_sinfo_max) + Settings.sinfo = 0; + static const char *opts[settings_sinfo_max] = {trNOOP("Game ID"),trNOOP("Game Region"),trNOOP("Both"),trNOOP("Neither")}; + options2.SetValue(Idx,"%s",tr(opts[Settings.sinfo])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Clock")); + if(ret == Idx && ++Settings.hddinfo >= settings_clock_max) + Settings.hddinfo = 0; //CLOCK + if (Settings.hddinfo == hr12) options2.SetValue(Idx,"12 %s",tr("Hour")); + else if (Settings.hddinfo == hr24) options2.SetValue(Idx,"24 %s",tr("Hour")); + else if (Settings.hddinfo == Off) options2.SetValue(Idx,"%s",tr("OFF")); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Tooltips")); + if(ret == Idx && ++Settings.tooltips >= settings_tooltips_max) + Settings.tooltips = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[Settings.tooltips])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Flip-X")); + if(ret == Idx && ++Settings.keyset >= settings_keyset_max) + Settings.keyset = 0; + static const char *opts[settings_keyset_max][3] = { {trNOOP("Right"),"/",trNOOP("Next")}, + {trNOOP("Left"),"/",trNOOP("Prev")}, + {trNOOP("Like SysMenu"),"",""}, + {trNOOP("Right"),"/",trNOOP("Prev")}, + {trNOOP("DiskFlip"),"",""}}; + options2.SetValue(Idx,"%s%s%s",tr(opts[Settings.keyset][0]),opts[Settings.keyset][1],tr(opts[Settings.keyset][2])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Prompts Buttons")); + if(ret == Idx && ++Settings.wsprompt >= settings_off_on_max ) + Settings.wsprompt = 0; + static const char *opts[settings_off_on_max] = {trNOOP("Normal"),trNOOP("Widescreen Fix")}; + options2.SetValue(Idx,"%s",tr(opts[Settings.wsprompt])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Keyboard")); + if(ret == Idx && ++Settings.keyset >= settings_keyset_max) + Settings.keyset = 0; + static const char *opts[settings_keyset_max] = {"QWERTY","QWERTY 2","DVORAK","QWERTZ","AZERTY"}; + options2.SetValue(Idx,"%s", opts[Settings.keyset]); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Disc Artwork Download")); + if(ret == Idx && ++Settings.discart >= 4) + Settings.discart = 0; + static const char *opts[4] = {trNOOP("Only Original"),trNOOP("Only Customs"),trNOOP("Original/Customs"),trNOOP("Customs/Original")}; + options2.SetValue(Idx,"%s",tr(opts[Settings.discart])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Wiilight")); + if(ret == Idx && ++Settings.wiilight >= settings_wiilight_max ) + Settings.wiilight = 0; + static const char *opts[settings_wiilight_max] = {trNOOP("OFF"),trNOOP("ON"),trNOOP("Only for Install")}; + options2.SetValue(Idx,"%s",tr(opts[Settings.wiilight])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Rumble")); + if(ret == Idx && ++Settings.rumble >= settings_rumble_max) + Settings.rumble = 0; //RUMBLE + options2.SetValue(Idx,"%s",tr(opts_off_on[Settings.rumble])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("AutoInit Network")); + if(ret == Idx && ++Settings.autonetwork >= settings_off_on_max) + Settings.autonetwork = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[Settings.autonetwork])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Titles from WiiTDB")); + if(ret == Idx && ++Settings.titlesOverride >= settings_off_on_max) + Settings.titlesOverride = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[Settings.titlesOverride])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Screensaver")); + if(ret == Idx && ++Settings.screensaver >= settings_screensaver_max) + Settings.screensaver = 0; //RUMBLE + static const char *opts[settings_screensaver_max] = {trNOOP("OFF"),trNOOP("3 min"),trNOOP("5 min"),trNOOP("10 min"),trNOOP("20 min"),trNOOP("30 min"),trNOOP("1 hour")}; + options2.SetValue(Idx,"%s",tr(opts[Settings.screensaver])); + } + + firstRun = false; + } + } + optionBrowser2.SetEffect(EFFECT_FADE, -20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + titleTxt.SetText(tr("Settings")); + slidedirection = FADE; + if (returnhere != 2) + pageToDisplay = 1; + MainButton1.ResetState(); + break; + } + + else if (MainButton2.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton2.GetEffect() > 0) usleep(50); + HaltGui(); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + titleTxt.SetText(tr("Game Load")); + exit = false; + options2.SetLength(0); + w.Append(&optionBrowser2); + optionBrowser2.SetClickable(true); + ResumeGui(); + + VIDEO_WaitVSync (); + optionBrowser2.SetEffect(EFFECT_FADE, 20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + + bool firstRun = true; + while (!exit) + { + VIDEO_WaitVSync (); + + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + + else if (backBtn.GetState() == STATE_CLICKED) + { + backBtn.ResetState(); + exit = true; + break; + } + + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } + + ret = optionBrowser2.GetClickedOption(); + + if(firstRun || ret >= 0) + { + int Idx = -1; + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Video Mode")); + if(ret == Idx && ++Settings.video >= settings_video_max) + Settings.video = 0; + options2.SetValue(Idx,"%s%s",opts_videomode[Settings.video][0], tr(opts_videomode[Settings.video][1])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("VIDTV Patch")); + if(ret == Idx && ++Settings.vpatch >= settings_off_on_max) + Settings.vpatch = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[Settings.vpatch])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Game Language")); + if(ret == Idx && ++Settings.language >= settings_language_max) + Settings.language = 0; + options2.SetValue(Idx,"%s",tr(opts_language[Settings.language])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Patch Country Strings")); + if(ret == Idx && ++Settings.patchcountrystrings >= settings_off_on_max) + Settings.patchcountrystrings = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[Settings.patchcountrystrings])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "Ocarina"); + if(ret == Idx && ++Settings.ocarina >= settings_off_on_max) + Settings.ocarina = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[Settings.ocarina])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx,"%s", tr("Boot/Standard")); + if(ret == Idx && Settings.godmode == 1 && ++Settings.cios >= settings_cios_max) + Settings.cios = 0; + if (Settings.godmode == 1) + options2.SetValue(Idx,"%s", opts_cios[Settings.cios]); + else + options2.SetValue(Idx, "********"); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Quick Boot")); + if(ret == Idx && ++Settings.qboot >= settings_off_on_max) + Settings.qboot = 0; + options2.SetValue(Idx,"%s",tr(opts_no_yes[Settings.qboot])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Error 002 fix")); + if(ret == Idx && ++Settings.error002 >= settings_error002_max) + Settings.error002 = 0; + options2.SetValue(Idx,"%s",tr(opts_error002[Settings.error002])); + } + + firstRun = false; + } + } + optionBrowser2.SetEffect(EFFECT_FADE, -20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + titleTxt.SetText(tr("Settings")); + slidedirection = FADE; + pageToDisplay = 1; + MainButton2.ResetState(); + break; + } + + else if (MainButton3.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton3.GetEffect() > 0) usleep(50); + HaltGui(); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + titleTxt.SetText(tr("Parental Control")); + exit = false; + options2.SetLength(0); + w.Append(&optionBrowser2); + optionBrowser2.SetClickable(true); + ResumeGui(); + + VIDEO_WaitVSync (); + optionBrowser2.SetEffect(EFFECT_FADE, 20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + + bool firstRun = true; + while (!exit) + { + VIDEO_WaitVSync (); + + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + + else if (backBtn.GetState() == STATE_CLICKED) + { + backBtn.ResetState(); + exit = true; + break; + } + + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } + + ret = optionBrowser2.GetClickedOption(); + + if(firstRun || ret >= 0) + { + + int Idx = -1; + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Console")); + if(ret == Idx) + { + if (!strcmp("", Settings.unlockCode)) + { + Settings.godmode = !Settings.godmode; + } + else if ( Settings.godmode == 0 ) + { + //password check to unlock Install,Delete and Format + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[20] = ""; + int result = OnScreenKeyboard(entered, 20,0); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + if (!strcmp(entered, Settings.unlockCode)) { //if password correct + if (Settings.godmode == 0) + { + WindowPrompt(tr("Correct Password"),tr("All the features of USB Loader GX are unlocked."),tr("OK")); + Settings.godmode = 1; + menu = MENU_DISCLIST; + } + } + else + WindowPrompt(tr("Wrong Password"),tr("USB Loader GX is protected"),tr("OK")); + } + } + else + { + int choice = WindowPrompt (tr("Lock Console"),tr("Are you sure?"),tr("Yes"),tr("No")); + if (choice == 1) + { + WindowPrompt(tr("Console Locked"),tr("USB Loader GX is protected"),tr("OK")); + Settings.godmode = 0; + menu = MENU_DISCLIST; + } + } + } + static const char *opts[] = {trNOOP("Locked"),trNOOP("Unlocked")}; + options2.SetValue(Idx,"%s",tr(opts[Settings.godmode])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Password")); + if(ret == Idx) + { + if ( Settings.godmode == 1) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[20] = ""; + strlcpy(entered, Settings.unlockCode, sizeof(entered)); + int result = OnScreenKeyboard(entered, 20,0); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + strlcpy(Settings.unlockCode, entered, sizeof(Settings.unlockCode)); + WindowPrompt(tr("Password Changed"),tr("Password has been changed"),tr("OK")); + } + } + else + { + WindowPrompt(tr("Password Changed"),tr("Console should be unlocked to modify it."),tr("OK")); + } + } + if ( Settings.godmode != 1) options2.SetValue(Idx, "********"); + else if (!strcmp("", Settings.unlockCode)) options2.SetValue(Idx, "%s",tr("not set")); + else options2.SetValue(Idx, Settings.unlockCode); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Controllevel")); + if(ret == Idx && Settings.godmode == 1 && ++Settings.parentalcontrol >= 5 ) + Settings.parentalcontrol = 0; + if (Settings.godmode == 1) + options2.SetValue(Idx,"%s",tr(opts_parentalcontrol[Settings.parentalcontrol])); + else + options2.SetValue(Idx, "********"); + } + + firstRun = false; + } + } + optionBrowser2.SetEffect(EFFECT_FADE, -20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + titleTxt.SetText(tr("Settings")); + slidedirection = FADE; + pageToDisplay = 1; + MainButton3.ResetState(); + break; + } + + else if (MainButton4.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton4.GetEffect() > 0) usleep(50); + HaltGui(); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + titleTxt.SetText(tr("Sound")); + exit = false; + options2.SetLength(0); + w.Append(&optionBrowser2); + optionBrowser2.SetClickable(true); + ResumeGui(); + + VIDEO_WaitVSync (); + optionBrowser2.SetEffect(EFFECT_FADE, 20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + + + char * oggfile; + + bool firstRun = true; + while (!exit) + { + VIDEO_WaitVSync (); + + bool returnhere = true; + + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + else if (backBtn.GetState() == STATE_CLICKED) + { + backBtn.ResetState(); + exit = true; + break; + } + + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } + + ret = optionBrowser2.GetClickedOption(); + + if(firstRun || ret >= 0) + { + int Idx = -1; + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Backgroundmusic")); + if(ret == Idx) + { + if (isInserted(bootDevice)) + { + w.SetEffect(EFFECT_FADE, -20); + while (w.GetEffect()>0) usleep(50); + mainWindow->Remove(&w); + while (returnhere) + returnhere = MenuOGG(); HaltGui(); - CFG_Load(); - CFG_LoadGlobal(); + mainWindow->Append(&w); + w.SetEffect(EFFECT_FADE, 20); ResumeGui(); - menu = MENU_SETTINGS; -#ifdef HW_RVL - snprintf(imgPath, sizeof(imgPath), "%splayer1_point.png", CFG.theme_path); - pointer[0] = new GuiImageData(imgPath, player1_point_png); - snprintf(imgPath, sizeof(imgPath), "%splayer2_point.png", CFG.theme_path); - pointer[1] = new GuiImageData(imgPath, player2_point_png); - snprintf(imgPath, sizeof(imgPath), "%splayer3_point.png", CFG.theme_path); - pointer[2] = new GuiImageData(imgPath, player3_point_png); - snprintf(imgPath, sizeof(imgPath), "%splayer4_point.png", CFG.theme_path); - pointer[3] = new GuiImageData(imgPath, player4_point_png); -#endif - if (CFG.widescreen) - snprintf(imgPath, sizeof(imgPath), "%swbackground.png", CFG.theme_path); - else - snprintf(imgPath, sizeof(imgPath), "%sbackground.png", CFG.theme_path); + while (w.GetEffect()>0) usleep(50); + } else + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to use this option."), tr("OK")); + } + if (!strcmp("notset", Settings.ogg_path)) + options2.SetValue(Idx, "%s", tr("Standard")); + else + { + oggfile = strrchr(Settings.ogg_path, '/')+1; + options2.SetValue(Idx, "%s", oggfile); + } + } - background = new GuiImageData(imgPath, CFG.widescreen? wbackground_png : background_png); + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Music Volume")); + if(ret == Idx) + { + Settings.volume += 10; + if (Settings.volume > 100) + Settings.volume = 0; + SetVolumeOgg(255*(Settings.volume/100.0)); + } + if (Settings.volume > 0) + options2.SetValue(Idx,"%i", Settings.volume); + else + options2.SetValue(Idx,"%s", tr("OFF")); + } - bgImg = new GuiImage(background); - mainWindow->Append(bgImg); - mainWindow->Append(&w); - } - w.Append(&settingsbackground); - w.Append(&titleTxt); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&backBtn); - w.Append(&optionBrowser2); - ResumeGui(); - } else { - WindowPrompt(tr("Theme Path change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 4: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - titleTxt.SetText(tr("WiiTDB Path")); - strlcpy(entered, Settings.titlestxt_path, sizeof(entered)); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - w.Append(&optionBrowser2); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.titlestxt_path, entered, sizeof(Settings.titlestxt_path)); - WindowPrompt(tr("WiiTDB Path changed."),0,tr("OK")); - if (isInserted(bootDevice)) { - cfg_save_global(); - HaltGui(); - CFG_Load(); + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("SFX Volume")); + if(ret == Idx) + { + Settings.sfxvolume += 10; + if (Settings.sfxvolume > 100) + Settings.sfxvolume = 0; + btnSoundOver.SetVolume(Settings.sfxvolume); + btnClick.SetVolume(Settings.sfxvolume); + btnClick1.SetVolume(Settings.sfxvolume); + } + if (Settings.sfxvolume > 0) + options2.SetValue(Idx,"%i", Settings.sfxvolume); + else + options2.SetValue(Idx,"%s", tr("OFF")); + } + + firstRun = false; + } + } + optionBrowser2.SetEffect(EFFECT_FADE, -20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + titleTxt.SetText(tr("Settings")); + slidedirection = FADE; + pageToDisplay = 1; + MainButton4.ResetState(); + break; + } + } + + else if ( pageToDisplay == 2) + { + if (MainButton1.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton1.GetEffect() > 0) usleep(50); + HaltGui(); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + titleTxt.SetText(tr("Custom Paths")); + exit = false; + options2.SetLength(0); +// optionBrowser2.SetScrollbar(1); + w.Append(&optionBrowser2); + optionBrowser2.SetClickable(true); + ResumeGui(); + + VIDEO_WaitVSync (); + optionBrowser2.SetEffect(EFFECT_FADE, 20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + + if (Settings.godmode) + { + bool firstRun = true; + while (!exit) + { + VIDEO_WaitVSync (); + + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + + else if (backBtn.GetState() == STATE_CLICKED) + { + backBtn.ResetState(); + exit = true; + break; + } + + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } + + ret = optionBrowser2.GetClickedOption(); + + if(firstRun || ret >= 0) + { + + int Idx = -1; + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("3D Cover Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.covers_path, sizeof(entered)); + titleTxt.SetText(tr("3D Cover Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.covers_path, entered, sizeof(Settings.covers_path)); + WindowPrompt(tr("Cover Path Changed"),0,tr("OK")); + if (!isInserted(bootDevice)) + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.covers_path); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("2D Cover Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.covers2d_path, sizeof(entered)); + titleTxt.SetText(tr("2D Cover Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.covers2d_path, entered, sizeof(Settings.covers2d_path)); + WindowPrompt(tr("Cover Path Changed"),0,tr("OK")); + if (!isInserted(bootDevice)) + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.covers2d_path); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Disc Artwork Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.disc_path, sizeof(entered)); + titleTxt.SetText(tr("Disc Artwork Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.disc_path, entered, sizeof(Settings.disc_path)); + WindowPrompt(tr("Disc Path Changed"),0,tr("OK")); + if (!isInserted(bootDevice)) + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.disc_path); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Theme Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + titleTxt.SetText(tr("Theme Path")); + strlcpy(entered, CFG.theme_path, sizeof(entered)); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + HaltGui(); + w.RemoveAll(); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(CFG.theme_path, entered, sizeof(CFG.theme_path)); + WindowPrompt(tr("Theme Path Changed"),0,tr("OK")); + if (!isInserted(bootDevice)) + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + else + cfg_save_global(); + mainWindow->Remove(bgImg); + HaltGui(); + CFG_Load(); + CFG_LoadGlobal(); ResumeGui(); - } else { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } - } - } else { - WindowPrompt(tr("WiiTDB Path change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 5: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.update_path, sizeof(entered)); - titleTxt.SetText(tr("Update Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.update_path, entered, sizeof(Settings.update_path)); - WindowPrompt(tr("Update Path changed."),0,tr("OK")); - } - } else - WindowPrompt(0,tr("Console should be unlocked to modify it."),tr("OK")); - break; - case 6: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.Cheatcodespath, sizeof(entered)); - titleTxt.SetText(tr("GCT Cheatcodes Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.Cheatcodespath, entered, sizeof(Settings.Cheatcodespath)); - WindowPrompt(tr("GCT Cheatcodes Path changed"),0,tr("OK")); - } - } else - WindowPrompt(0,tr("Console should be unlocked to modify it."),tr("OK")); - break; - case 7: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.TxtCheatcodespath, sizeof(entered)); - titleTxt.SetText(tr("TXT Cheatcodes Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.TxtCheatcodespath, entered, sizeof(Settings.TxtCheatcodespath)); - WindowPrompt(tr("TXT Cheatcodes Path changed"),0,tr("OK")); - } - } else - WindowPrompt(0,tr("Console should be unlocked to modify it."),tr("OK")); - break; - case 8: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.dolpath, sizeof(entered)); - titleTxt.SetText(tr("DOL Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.dolpath, entered, sizeof(Settings.dolpath)); - WindowPrompt(tr("DOL path changed"),0,tr("OK")); - if (!isInserted(bootDevice)) { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } - } - } else { - WindowPrompt(tr("DOL path change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 9: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.homebrewapps_path, sizeof(entered)); - titleTxt.SetText(tr("Homebrew Apps Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.homebrewapps_path, entered, sizeof(Settings.homebrewapps_path)); - WindowPrompt(tr("Homebrew Appspath changed"),0,tr("OK")); - if (!isInserted(bootDevice)) { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } - } - } else { - WindowPrompt(tr("Homebrew Appspath change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; - case 10: - if ( Settings.godmode == 1) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - char entered[43] = ""; - strlcpy(entered, Settings.theme_downloadpath, sizeof(entered)); - titleTxt.SetText(tr("Theme Download Path")); - int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); - titleTxt.SetText(tr("Custom Paths")); - w.Append(&optionBrowser2); - w.Append(&backBtn); - if ( result == 1 ) { - int len = (strlen(entered)-1); - if (entered[len] !='/') - strncat (entered, "/", 1); - strlcpy(Settings.theme_downloadpath, entered, sizeof(Settings.theme_downloadpath)); - WindowPrompt(tr("Theme Download Path changed"),0,tr("OK")); - if (!isInserted(bootDevice)) { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } - } - } else { - WindowPrompt(tr("Theme Download Path change"),tr("Console should be unlocked to modify it."),tr("OK")); - } - break; + menu = MENU_SETTINGS; + #ifdef HW_RVL + snprintf(imgPath, sizeof(imgPath), "%splayer1_point.png", CFG.theme_path); + pointer[0] = new GuiImageData(imgPath, player1_point_png); + snprintf(imgPath, sizeof(imgPath), "%splayer2_point.png", CFG.theme_path); + pointer[1] = new GuiImageData(imgPath, player2_point_png); + snprintf(imgPath, sizeof(imgPath), "%splayer3_point.png", CFG.theme_path); + pointer[2] = new GuiImageData(imgPath, player3_point_png); + snprintf(imgPath, sizeof(imgPath), "%splayer4_point.png", CFG.theme_path); + pointer[3] = new GuiImageData(imgPath, player4_point_png); + #endif + if (CFG.widescreen) + snprintf(imgPath, sizeof(imgPath), "%swbackground.png", CFG.theme_path); + else + snprintf(imgPath, sizeof(imgPath), "%sbackground.png", CFG.theme_path); - } - } - /** If not godmode don't let him inside **/ - } else { - WindowPrompt(tr("Console Locked"), tr("Unlock console to use this option."), tr("OK")); - } - optionBrowser2.SetEffect(EFFECT_FADE, -20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - titleTxt.SetText(tr("Settings")); - slidedirection = FADE; - pageToDisplay = 2; - MainButton1.ResetState(); - break; - } + background = new GuiImageData(imgPath, CFG.widescreen? wbackground_png : background_png); - if (MainButton2.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton2.GetEffect() > 0) usleep(50); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - if (isInserted(bootDevice) && Settings.godmode) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - int ret = ProgressUpdateWindow(); - if (ret < 0) { - WindowPrompt(tr("Update failed"),0,tr("OK")); - } - w.Append(&optionBrowser2); - w.Append(&backBtn); - } else { - WindowPrompt(tr("Console Locked"), tr("Unlock console to use this option."), tr("OK")); - } - slidedirection = FADE; - pageToDisplay = 2; - MainButton2.ResetState(); - break; - } + bgImg = new GuiImage(background); + mainWindow->Append(bgImg); + mainWindow->Append(&w); + } + w.Append(&settingsbackground); + w.Append(&titleTxt); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&backBtn); + w.Append(&optionBrowser2); + ResumeGui(); + } + options2.SetValue(Idx, "%s", CFG.theme_path); + } - if (MainButton3.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton3.GetEffect() > 0) usleep(50); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - w.Remove(&backBtn); - w.Remove(&optionBrowser2); - if (Settings.godmode) { - int choice = WindowPrompt(tr("Are you sure?"), 0, tr("Yes"), tr("Cancel")); - if (choice == 1) { - if (isInserted(bootDevice)) { - char GXGlobal_cfg[26]; - sprintf(GXGlobal_cfg, "%s/config/GXGlobal.cfg", bootDevice); - remove(GXGlobal_cfg); - } - gettextCleanUp(); + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("WiiTDB Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + titleTxt.SetText(tr("WiiTDB Path")); + strlcpy(entered, Settings.titlestxt_path, sizeof(entered)); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + w.Append(&optionBrowser2); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.titlestxt_path, entered, sizeof(Settings.titlestxt_path)); + WindowPrompt(tr("WiiTDB Path changed."),0,tr("OK")); + if (isInserted(bootDevice)) + { + cfg_save_global(); + HaltGui(); + CFG_Load(); + ResumeGui(); + } + else + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.titlestxt_path); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Update Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.update_path, sizeof(entered)); + titleTxt.SetText(tr("Update Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.update_path, entered, sizeof(Settings.update_path)); + WindowPrompt(tr("Update Path changed."),0,tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.update_path); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("GCT Cheatcodes Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.Cheatcodespath, sizeof(entered)); + titleTxt.SetText(tr("GCT Cheatcodes Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.Cheatcodespath, entered, sizeof(Settings.Cheatcodespath)); + WindowPrompt(tr("GCT Cheatcodes Path changed"),0,tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.Cheatcodespath); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("TXT Cheatcodes Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.TxtCheatcodespath, sizeof(entered)); + titleTxt.SetText(tr("TXT Cheatcodes Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.TxtCheatcodespath, entered, sizeof(Settings.TxtCheatcodespath)); + WindowPrompt(tr("TXT Cheatcodes Path changed"),0,tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.TxtCheatcodespath); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("DOL Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.dolpath, sizeof(entered)); + titleTxt.SetText(tr("DOL Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.dolpath, entered, sizeof(Settings.dolpath)); + WindowPrompt(tr("DOL path changed"),0,tr("OK")); + if (!isInserted(bootDevice)) + { + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + } + } + } + options2.SetValue(Idx, "%s", Settings.dolpath); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Homebrew Apps Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.homebrewapps_path, sizeof(entered)); + titleTxt.SetText(tr("Homebrew Apps Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.homebrewapps_path, entered, sizeof(Settings.homebrewapps_path)); + WindowPrompt(tr("Homebrew Appspath changed"),0,tr("OK")); + if (!isInserted(bootDevice)) + { + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + } + } + } + options2.SetValue(Idx, "%s", Settings.homebrewapps_path); + } + + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Theme Download Path")); + if(ret == Idx) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + char entered[43] = ""; + strlcpy(entered, Settings.theme_downloadpath, sizeof(entered)); + titleTxt.SetText(tr("Theme Download Path")); + int result = BrowseDevice(entered, sizeof(entered), FB_DEFAULT, noFILES); + titleTxt.SetText(tr("Custom Paths")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + if ( result == 1 ) + { + int len = (strlen(entered)-1); + if (entered[len] !='/') + strncat (entered, "/", 1); + strlcpy(Settings.theme_downloadpath, entered, sizeof(Settings.theme_downloadpath)); + WindowPrompt(tr("Theme Download Path changed"),0,tr("OK")); + if (!isInserted(bootDevice)) + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); + } + } + options2.SetValue(Idx, "%s", Settings.theme_downloadpath); + } + + firstRun = false; + } + } + /** If not godmode don't let him inside **/ + } + else + WindowPrompt(tr("Console Locked"), tr("Unlock console to use this option."), tr("OK")); + optionBrowser2.SetEffect(EFFECT_FADE, -20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + titleTxt.SetText(tr("Settings")); + slidedirection = FADE; + pageToDisplay = 2; + MainButton1.ResetState(); + break; + } + + else if (MainButton2.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton2.GetEffect() > 0) usleep(50); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + if (isInserted(bootDevice) && Settings.godmode) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + int ret = ProgressUpdateWindow(); + if (ret < 0) + WindowPrompt(tr("Update failed"),0,tr("OK")); + w.Append(&optionBrowser2); + w.Append(&backBtn); + } + else + WindowPrompt(tr("Console Locked"), tr("Unlock console to use this option."), tr("OK")); + slidedirection = FADE; + pageToDisplay = 2; + MainButton2.ResetState(); + break; + } + + else if (MainButton3.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton3.GetEffect() > 0) usleep(50); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + w.Remove(&backBtn); + w.Remove(&optionBrowser2); + if (Settings.godmode) + { + int choice = WindowPrompt(tr("Are you sure?"), 0, tr("Yes"), tr("Cancel")); + if (choice == 1) + { + if (isInserted(bootDevice)) + { + char GXGlobal_cfg[26]; + sprintf(GXGlobal_cfg, "%s/config/GXGlobal.cfg", bootDevice); + remove(GXGlobal_cfg); + } + gettextCleanUp(); HaltGui(); - CFG_Load(); + CFG_Load(); ResumeGui(); - menu = MENU_SETTINGS; - pageToDisplay = 0; - } - } else { - WindowPrompt(tr("Console Locked"), tr("Unlock console to use this option."), tr("OK")); - } - w.Append(&backBtn); - w.Append(&optionBrowser2); - slidedirection = FADE; - pageToDisplay = 2; - MainButton3.ResetState(); - break; - } + menu = MENU_SETTINGS; + pageToDisplay = 0; + } + } + else + WindowPrompt(tr("Console Locked"), tr("Unlock console to use this option."), tr("OK")); + w.Append(&backBtn); + w.Append(&optionBrowser2); + slidedirection = FADE; + pageToDisplay = 2; + MainButton3.ResetState(); + break; + } - if (MainButton4.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton4.GetEffect() > 0) usleep(50); - w.Remove(&PageIndicatorBtn1); - w.Remove(&PageIndicatorBtn2); - w.Remove(&PageIndicatorBtn3); - w.Remove(&GoRightBtn); - w.Remove(&GoLeftBtn); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - WindowCredits(); - slidedirection = FADE; - pageToDisplay = 2; - MainButton4.ResetState(); - break; - } - } + else if (MainButton4.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton4.GetEffect() > 0) usleep(50); + w.Remove(&PageIndicatorBtn1); + w.Remove(&PageIndicatorBtn2); + w.Remove(&PageIndicatorBtn3); + w.Remove(&GoRightBtn); + w.Remove(&GoLeftBtn); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + WindowCredits(); + slidedirection = FADE; + pageToDisplay = 2; + MainButton4.ResetState(); + break; + } + } - if(pageToDisplay == 3) { - if (MainButton1.GetState() == STATE_CLICKED) { - if (isInserted(bootDevice)) { - cfg_save_global(); - } - menu = MENU_THEMEDOWNLOADER; - pageToDisplay = 0; - break; - } - } - - if (shutdown == 1) - Sys_Shutdown(); - if (reset == 1) - Sys_Reboot(); - - if (backBtn.GetState() == STATE_CLICKED) { - //Add the procedure call to save the global configuration - if (isInserted(bootDevice)) { - cfg_save_global(); - } - menu = MENU_DISCLIST; - pageToDisplay = 0; - break; - } - - if (GoLeftBtn.GetState() == STATE_CLICKED) { - pageToDisplay--; - /** Change direction of the flying buttons **/ - if (pageToDisplay < 1) - pageToDisplay = 3; - slidedirection = LEFT; - GoLeftBtn.ResetState(); - break; - } - - if (GoRightBtn.GetState() == STATE_CLICKED) { - pageToDisplay++; - /** Change direction of the flying buttons **/ - if (pageToDisplay > 3) - pageToDisplay = 1; - slidedirection = RIGHT; - GoRightBtn.ResetState(); - break; - } - - if (PageIndicatorBtn1.GetState() == STATE_CLICKED) { - if (pageToDisplay > 1) { - slidedirection = LEFT; - pageToDisplay = 1; - PageIndicatorBtn1.ResetState(); - break; - } - PageIndicatorBtn1.ResetState(); - } else if (PageIndicatorBtn2.GetState() == STATE_CLICKED) { - if (pageToDisplay < 2) { - slidedirection = RIGHT; - pageToDisplay = 2; - PageIndicatorBtn2.ResetState(); - break; - } else if (pageToDisplay > 2) { - slidedirection = LEFT; - pageToDisplay = 2; - PageIndicatorBtn2.ResetState(); - break; - } - else - PageIndicatorBtn2.ResetState(); - } else if (PageIndicatorBtn3.GetState() == STATE_CLICKED) { - if (pageToDisplay < 3) { - slidedirection = RIGHT; - pageToDisplay = 3; - PageIndicatorBtn3.ResetState(); - break; - } else - PageIndicatorBtn3.ResetState(); - } - - if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } - } - } - - w.SetEffect(EFFECT_FADE, -20); - while (w.GetEffect()>0) usleep(50); + else if(pageToDisplay == 3) + { + if (MainButton1.GetState() == STATE_CLICKED) + { + if (isInserted(bootDevice)) + cfg_save_global(); + menu = MENU_THEMEDOWNLOADER; + pageToDisplay = 0; + break; + } + } - // if language has changed, reload titles - char opt_langnew[100]; - strcpy(opt_langnew,Settings.language_path); - int opt_overridenew = Settings.titlesOverride; - if (strcmp(opt_lang,opt_langnew) || (opt_override != opt_overridenew && Settings.titlesOverride==1)) { - OpenXMLDatabase(Settings.titlestxt_path, Settings.db_language, Settings.db_JPtoEN, false, Settings.titlesOverride==1?true:false, true); // open file, reload titles, keep in memory - } - // disable titles from database - if (opt_override != opt_overridenew && Settings.titlesOverride==0) { - titles_default(); + if (backBtn.GetState() == STATE_CLICKED) + { + //Add the procedure call to save the global configuration + if (isInserted(bootDevice)) + cfg_save_global(); + menu = MENU_DISCLIST; + pageToDisplay = 0; + break; + } + + else if (GoLeftBtn.GetState() == STATE_CLICKED) + { + pageToDisplay--; + /** Change direction of the flying buttons **/ + if (pageToDisplay < 1) + pageToDisplay = 3; + slidedirection = LEFT; + GoLeftBtn.ResetState(); + break; + } + + else if (GoRightBtn.GetState() == STATE_CLICKED) + { + pageToDisplay++; + /** Change direction of the flying buttons **/ + if (pageToDisplay > 3) + pageToDisplay = 1; + slidedirection = RIGHT; + GoRightBtn.ResetState(); + break; + } + else if (PageIndicatorBtn1.GetState() == STATE_CLICKED) + { + if (pageToDisplay > 1) + { + slidedirection = LEFT; + pageToDisplay = 1; + PageIndicatorBtn1.ResetState(); + break; + } + PageIndicatorBtn1.ResetState(); + } + else if (PageIndicatorBtn2.GetState() == STATE_CLICKED) + { + if (pageToDisplay < 2) + { + slidedirection = RIGHT; + pageToDisplay = 2; + PageIndicatorBtn2.ResetState(); + break; + } + else if (pageToDisplay > 2) + { + slidedirection = LEFT; + pageToDisplay = 2; + PageIndicatorBtn2.ResetState(); + break; + } + else + PageIndicatorBtn2.ResetState(); + } + else if (PageIndicatorBtn3.GetState() == STATE_CLICKED) + { + if (pageToDisplay < 3) + { + slidedirection = RIGHT; + pageToDisplay = 3; + PageIndicatorBtn3.ResetState(); + break; + } + else + PageIndicatorBtn3.ResetState(); + } + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } + } } - HaltGui(); + w.SetEffect(EFFECT_FADE, -20); + while (w.GetEffect()>0) usleep(50); - mainWindow->RemoveAll(); - mainWindow->Append(bgImg); - ResumeGui(); - return menu; -} + // if language has changed, reload titles + char opt_langnew[100]; + strcpy(opt_langnew,Settings.language_path); + int opt_overridenew = Settings.titlesOverride; + if (strcmp(opt_lang,opt_langnew) || (opt_override != opt_overridenew && Settings.titlesOverride==1)) + OpenXMLDatabase(Settings.titlestxt_path, Settings.db_language, Settings.db_JPtoEN, false, Settings.titlesOverride==1?true:false, true); // open file, reload titles, keep in memory + // disable titles from database + if (opt_override != opt_overridenew && Settings.titlesOverride==0) + titles_default(); + + HaltGui(); + + mainWindow->RemoveAll(); + mainWindow->Append(bgImg); + + ResumeGui(); + return menu; + } /******************************************************************************** *Game specific settings *********************************************************************************/ -int GameSettings(struct discHdr * header) { - int menu = MENU_NONE; - int ret; - int choice = 0; - bool exit = false; +int GameSettings(struct discHdr * header) +{ + int menu = MENU_NONE; + int ret; + int choice = 0; + bool exit = false; - int retVal = 0; + int retVal = 0; - GuiSound btnSoundOver(button_over_pcm, button_over_pcm_size, SOUND_PCM, Settings.sfxvolume); - GuiSound btnClick(button_click2_pcm, button_click2_pcm_size, SOUND_PCM, Settings.sfxvolume); - GuiSound btnClick1(button_click_pcm, button_click_pcm_size, SOUND_PCM, Settings.sfxvolume); + GuiSound btnSoundOver(button_over_pcm, button_over_pcm_size, SOUND_PCM, Settings.sfxvolume); + GuiSound btnClick(button_click2_pcm, button_click2_pcm_size, SOUND_PCM, Settings.sfxvolume); + GuiSound btnClick1(button_click_pcm, button_click_pcm_size, SOUND_PCM, Settings.sfxvolume); - char imgPath[100]; + char imgPath[100]; - snprintf(imgPath, sizeof(imgPath), "%sbutton_dialogue_box.png", CFG.theme_path); - GuiImageData btnOutline(imgPath, button_dialogue_box_png); - snprintf(imgPath, sizeof(imgPath), "%ssettings_background.png", CFG.theme_path); - GuiImageData settingsbg(imgPath, settings_background_png); + snprintf(imgPath, sizeof(imgPath), "%sbutton_dialogue_box.png", CFG.theme_path); + GuiImageData btnOutline(imgPath, button_dialogue_box_png); + snprintf(imgPath, sizeof(imgPath), "%ssettings_background.png", CFG.theme_path); + GuiImageData settingsbg(imgPath, settings_background_png); - snprintf(imgPath, sizeof(imgPath), "%ssettings_title.png", CFG.theme_path); - GuiImageData MainButtonImgData(imgPath, settings_title_png); + snprintf(imgPath, sizeof(imgPath), "%ssettings_title.png", CFG.theme_path); + GuiImageData MainButtonImgData(imgPath, settings_title_png); - snprintf(imgPath, sizeof(imgPath), "%ssettings_title_over.png", CFG.theme_path); - GuiImageData MainButtonImgOverData(imgPath, settings_title_over_png); + snprintf(imgPath, sizeof(imgPath), "%ssettings_title_over.png", CFG.theme_path); + GuiImageData MainButtonImgOverData(imgPath, settings_title_over_png); - GuiTrigger trigA; - trigA.SetSimpleTrigger(-1, WPAD_BUTTON_A | WPAD_CLASSIC_BUTTON_A, PAD_BUTTON_A); - GuiTrigger trigHome; - trigHome.SetButtonOnlyTrigger(-1, WPAD_BUTTON_HOME | WPAD_CLASSIC_BUTTON_HOME, 0); - GuiTrigger trigB; - trigB.SetButtonOnlyTrigger(-1, WPAD_BUTTON_B | WPAD_CLASSIC_BUTTON_B, PAD_BUTTON_B); + GuiTrigger trigA; + trigA.SetSimpleTrigger(-1, WPAD_BUTTON_A | WPAD_CLASSIC_BUTTON_A, PAD_BUTTON_A); + GuiTrigger trigHome; + trigHome.SetButtonOnlyTrigger(-1, WPAD_BUTTON_HOME | WPAD_CLASSIC_BUTTON_HOME, 0); + GuiTrigger trigB; + trigB.SetButtonOnlyTrigger(-1, WPAD_BUTTON_B | WPAD_CLASSIC_BUTTON_B, PAD_BUTTON_B); - char gameName[31]; + char gameName[31]; if (!mountMethod) { - if (strlen(get_title(header)) < (27 + 3)) { + if (strlen(get_title(header)) < (27 + 3)) sprintf(gameName, "%s", get_title(header)); - } else { - strncpy(gameName, get_title(header), 27); + else + { + strncpy(gameName, get_title(header), 27); gameName[27] = '\0'; strncat(gameName, "...", 3); } } - else sprintf(gameName, "%c%c%c%c%c%c", header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); + else + sprintf(gameName, "%c%c%c%c%c%c", header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); GuiText titleTxt(!mountMethod?get_title(header):gameName, 28, (GXColor) {0, 0, 0, 255}); - titleTxt.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - titleTxt.SetPosition(12,40); - titleTxt.SetMaxWidth(356, GuiText::SCROLL); + titleTxt.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + titleTxt.SetPosition(12,40); + titleTxt.SetMaxWidth(356, GuiText::SCROLL); - GuiImage settingsbackground(&settingsbg); + GuiImage settingsbackground(&settingsbg); - GuiText backBtnTxt(tr("Back") , 22, THEME.prompttext); - backBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); - GuiImage backBtnImg(&btnOutline); - if (Settings.wsprompt == yes) { - backBtnTxt.SetWidescreen(CFG.widescreen); - backBtnImg.SetWidescreen(CFG.widescreen); - } - GuiButton backBtn(&backBtnImg,&backBtnImg, 2, 3, -180, 400, &trigA, &btnSoundOver, &btnClick,1); - backBtn.SetLabel(&backBtnTxt); - backBtn.SetTrigger(&trigB); + GuiText backBtnTxt(tr("Back"), 22, THEME.prompttext); + backBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); + GuiImage backBtnImg(&btnOutline); + if (Settings.wsprompt == yes) + { + backBtnTxt.SetWidescreen(CFG.widescreen); + backBtnImg.SetWidescreen(CFG.widescreen); + } + GuiButton backBtn(&backBtnImg,&backBtnImg, 2, 3, -180, 400, &trigA, &btnSoundOver, &btnClick,1); + backBtn.SetLabel(&backBtnTxt); + backBtn.SetTrigger(&trigB); - GuiButton homo(1,1); - homo.SetTrigger(&trigHome); + GuiButton homo(1,1); + homo.SetTrigger(&trigHome); - GuiText saveBtnTxt(tr("Save"), 22, THEME.prompttext); - saveBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); - GuiImage saveBtnImg(&btnOutline); - if (Settings.wsprompt == yes) { - saveBtnTxt.SetWidescreen(CFG.widescreen); - saveBtnImg.SetWidescreen(CFG.widescreen); - } - GuiButton saveBtn(&saveBtnImg,&saveBtnImg, 2, 3, 180, 400, &trigA, &btnSoundOver, &btnClick,1); - saveBtn.SetLabel(&saveBtnTxt); + GuiText saveBtnTxt(tr("Save"), 22, THEME.prompttext); + saveBtnTxt.SetMaxWidth(btnOutline.GetWidth()-30); + GuiImage saveBtnImg(&btnOutline); + if (Settings.wsprompt == yes) + { + saveBtnTxt.SetWidescreen(CFG.widescreen); + saveBtnImg.SetWidescreen(CFG.widescreen); + } + GuiButton saveBtn(&saveBtnImg,&saveBtnImg, 2, 3, 180, 400, &trigA, &btnSoundOver, &btnClick,1); + saveBtn.SetLabel(&saveBtnTxt); - char MainButtonText[50]; - snprintf(MainButtonText, sizeof(MainButtonText), "%s", " "); + char MainButtonText[50]; + snprintf(MainButtonText, sizeof(MainButtonText), "%s", " "); - GuiImage MainButton1Img(&MainButtonImgData); - GuiImage MainButton1ImgOver(&MainButtonImgOverData); - GuiText MainButton1Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); - MainButton1Txt.SetMaxWidth(MainButton1Img.GetWidth()); - GuiButton MainButton1(MainButton1Img.GetWidth(), MainButton1Img.GetHeight()); - MainButton1.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton1.SetPosition(0, 90); - MainButton1.SetImage(&MainButton1Img); - MainButton1.SetImageOver(&MainButton1ImgOver); - MainButton1.SetLabel(&MainButton1Txt); - MainButton1.SetSoundOver(&btnSoundOver); - MainButton1.SetSoundClick(&btnClick1); - MainButton1.SetEffectGrow(); - MainButton1.SetTrigger(&trigA); + GuiImage MainButton1Img(&MainButtonImgData); + GuiImage MainButton1ImgOver(&MainButtonImgOverData); + GuiText MainButton1Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); + MainButton1Txt.SetMaxWidth(MainButton1Img.GetWidth()); + GuiButton MainButton1(MainButton1Img.GetWidth(), MainButton1Img.GetHeight()); + MainButton1.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton1.SetPosition(0, 90); + MainButton1.SetImage(&MainButton1Img); + MainButton1.SetImageOver(&MainButton1ImgOver); + MainButton1.SetLabel(&MainButton1Txt); + MainButton1.SetSoundOver(&btnSoundOver); + MainButton1.SetSoundClick(&btnClick1); + MainButton1.SetEffectGrow(); + MainButton1.SetTrigger(&trigA); - GuiImage MainButton2Img(&MainButtonImgData); - GuiImage MainButton2ImgOver(&MainButtonImgOverData); - GuiText MainButton2Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); - MainButton2Txt.SetMaxWidth(MainButton2Img.GetWidth()); - GuiButton MainButton2(MainButton2Img.GetWidth(), MainButton2Img.GetHeight()); - MainButton2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton2.SetPosition(0, 160); - MainButton2.SetImage(&MainButton2Img); - MainButton2.SetImageOver(&MainButton2ImgOver); - MainButton2.SetLabel(&MainButton2Txt); - MainButton2.SetSoundOver(&btnSoundOver); - MainButton2.SetSoundClick(&btnClick1); - MainButton2.SetEffectGrow(); - MainButton2.SetTrigger(&trigA); + GuiImage MainButton2Img(&MainButtonImgData); + GuiImage MainButton2ImgOver(&MainButtonImgOverData); + GuiText MainButton2Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); + MainButton2Txt.SetMaxWidth(MainButton2Img.GetWidth()); + GuiButton MainButton2(MainButton2Img.GetWidth(), MainButton2Img.GetHeight()); + MainButton2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton2.SetPosition(0, 160); + MainButton2.SetImage(&MainButton2Img); + MainButton2.SetImageOver(&MainButton2ImgOver); + MainButton2.SetLabel(&MainButton2Txt); + MainButton2.SetSoundOver(&btnSoundOver); + MainButton2.SetSoundClick(&btnClick1); + MainButton2.SetEffectGrow(); + MainButton2.SetTrigger(&trigA); - GuiImage MainButton3Img(&MainButtonImgData); - GuiImage MainButton3ImgOver(&MainButtonImgOverData); - GuiText MainButton3Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); - MainButton3Txt.SetMaxWidth(MainButton3Img.GetWidth()); - GuiButton MainButton3(MainButton3Img.GetWidth(), MainButton3Img.GetHeight()); - MainButton3.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton3.SetPosition(0, 230); - MainButton3.SetImage(&MainButton3Img); - MainButton3.SetImageOver(&MainButton3ImgOver); - MainButton3.SetLabel(&MainButton3Txt); - MainButton3.SetSoundOver(&btnSoundOver); - MainButton3.SetSoundClick(&btnClick1); - MainButton3.SetEffectGrow(); - MainButton3.SetTrigger(&trigA); + GuiImage MainButton3Img(&MainButtonImgData); + GuiImage MainButton3ImgOver(&MainButtonImgOverData); + GuiText MainButton3Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); + MainButton3Txt.SetMaxWidth(MainButton3Img.GetWidth()); + GuiButton MainButton3(MainButton3Img.GetWidth(), MainButton3Img.GetHeight()); + MainButton3.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton3.SetPosition(0, 230); + MainButton3.SetImage(&MainButton3Img); + MainButton3.SetImageOver(&MainButton3ImgOver); + MainButton3.SetLabel(&MainButton3Txt); + MainButton3.SetSoundOver(&btnSoundOver); + MainButton3.SetSoundClick(&btnClick1); + MainButton3.SetEffectGrow(); + MainButton3.SetTrigger(&trigA); - GuiImage MainButton4Img(&MainButtonImgData); - GuiImage MainButton4ImgOver(&MainButtonImgOverData); - GuiText MainButton4Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); - MainButton4Txt.SetMaxWidth(MainButton4Img.GetWidth()); - GuiButton MainButton4(MainButton4Img.GetWidth(), MainButton4Img.GetHeight()); - MainButton4.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - MainButton4.SetPosition(0, 300); - MainButton4.SetImage(&MainButton4Img); - MainButton4.SetImageOver(&MainButton4ImgOver); - MainButton4.SetLabel(&MainButton4Txt); - MainButton4.SetSoundOver(&btnSoundOver); - MainButton4.SetSoundClick(&btnClick1); - MainButton4.SetEffectGrow(); - MainButton4.SetTrigger(&trigA); + GuiImage MainButton4Img(&MainButtonImgData); + GuiImage MainButton4ImgOver(&MainButtonImgOverData); + GuiText MainButton4Txt(MainButtonText, 22, (GXColor) {0, 0, 0, 255}); + MainButton4Txt.SetMaxWidth(MainButton4Img.GetWidth()); + GuiButton MainButton4(MainButton4Img.GetWidth(), MainButton4Img.GetHeight()); + MainButton4.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + MainButton4.SetPosition(0, 300); + MainButton4.SetImage(&MainButton4Img); + MainButton4.SetImageOver(&MainButton4ImgOver); + MainButton4.SetLabel(&MainButton4Txt); + MainButton4.SetSoundOver(&btnSoundOver); + MainButton4.SetSoundClick(&btnClick1); + MainButton4.SetEffectGrow(); + MainButton4.SetTrigger(&trigA); - customOptionList options2(MAXOPTIONS); - GuiCustomOptionBrowser optionBrowser2(396, 280, &options2, CFG.theme_path, "bg_options_settings.png", bg_options_settings_png, 0, 150); - optionBrowser2.SetPosition(0, 90); - optionBrowser2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); + customOptionList options2(MAXOPTIONS); + GuiCustomOptionBrowser optionBrowser2(396, 280, &options2, CFG.theme_path, "bg_options_settings.png", bg_options_settings_png, 0, 150); + optionBrowser2.SetPosition(0, 90); + optionBrowser2.SetAlignment(ALIGN_CENTRE, ALIGN_TOP); - GuiWindow w(screenwidth, screenheight); - //int opt_lang = languageChoice; // backup language setting - struct Game_CFG* game_cfg = CFG_get_game_opt(header->id); + GuiWindow w(screenwidth, screenheight); + //int opt_lang = languageChoice; // backup language setting + struct Game_CFG* game_cfg = CFG_get_game_opt(header->id); - int pageToDisplay = 1; - while ( pageToDisplay > 0) { //set pageToDisplay to 0 to quit - VIDEO_WaitVSync (); + int pageToDisplay = 1; + while ( pageToDisplay > 0) { //set pageToDisplay to 0 to quit + VIDEO_WaitVSync (); - menu = MENU_NONE; + menu = MENU_NONE; - /** Standard procedure made in all pages **/ - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); + /** Standard procedure made in all pages **/ + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); - HaltGui(); + HaltGui(); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Game Load")); - MainButton1Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "Ocarina"); - MainButton2Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Uninstall Menu")); - MainButton3Txt.SetText(MainButtonText); - snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Default Gamesettings")); - MainButton4Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Game Load")); + MainButton1Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "Ocarina"); + MainButton2Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Uninstall Menu")); + MainButton3Txt.SetText(MainButtonText); + snprintf(MainButtonText, sizeof(MainButtonText), "%s", tr("Default Gamesettings")); + MainButton4Txt.SetText(MainButtonText); - mainWindow->RemoveAll(); - mainWindow->Append(&w); - w.RemoveAll(); - w.Append(&settingsbackground); - w.Append(&titleTxt); - w.Append(&backBtn); - w.Append(&homo); - w.Append(&MainButton1); - w.Append(&MainButton2); - w.Append(&MainButton3); - w.Append(&MainButton4); + mainWindow->RemoveAll(); + mainWindow->Append(&w); + w.RemoveAll(); + w.Append(&settingsbackground); + w.Append(&titleTxt); + w.Append(&backBtn); + w.Append(&homo); + w.Append(&MainButton1); + w.Append(&MainButton2); + w.Append(&MainButton3); + w.Append(&MainButton4); - /** Disable ability to click through MainButtons */ - optionBrowser2.SetClickable(false); - /** Default no scrollbar and reset position **/ - optionBrowser2.SetScrollbar(0); - optionBrowser2.SetOffset(0); + /** Disable ability to click through MainButtons */ + optionBrowser2.SetClickable(false); + /** Default no scrollbar and reset position **/ +// optionBrowser2.SetScrollbar(0); + optionBrowser2.SetOffset(0); - MainButton1.StopEffect(); - MainButton2.StopEffect(); - MainButton3.StopEffect(); - MainButton4.StopEffect(); + MainButton1.StopEffect(); + MainButton2.StopEffect(); + MainButton3.StopEffect(); + MainButton4.StopEffect(); - MainButton1.SetEffectGrow(); - MainButton2.SetEffectGrow(); - MainButton3.SetEffectGrow(); - MainButton4.SetEffectGrow(); + MainButton1.SetEffectGrow(); + MainButton2.SetEffectGrow(); + MainButton3.SetEffectGrow(); + MainButton4.SetEffectGrow(); - MainButton1.SetEffect(EFFECT_FADE, 20); - MainButton2.SetEffect(EFFECT_FADE, 20); - MainButton3.SetEffect(EFFECT_FADE, 20); - MainButton4.SetEffect(EFFECT_FADE, 20); + MainButton1.SetEffect(EFFECT_FADE, 20); + MainButton2.SetEffect(EFFECT_FADE, 20); + MainButton3.SetEffect(EFFECT_FADE, 20); + MainButton4.SetEffect(EFFECT_FADE, 20); - mainWindow->Append(&w); + mainWindow->Append(&w); - if (game_cfg) { //if there are saved settings for this game use them - videoChoice = game_cfg->video; - languageChoice = game_cfg->language; - ocarinaChoice = game_cfg->ocarina; - viChoice = game_cfg->vipatch; - iosChoice = game_cfg->ios; - parentalcontrolChoice = game_cfg->parentalcontrol; - fix002 = game_cfg->errorfix002; - countrystrings = game_cfg->patchcountrystrings; - alternatedol = game_cfg->loadalternatedol; - alternatedoloffset = game_cfg->alternatedolstart; - reloadblock = game_cfg->iosreloadblock; - strlcpy(alternatedname, game_cfg->alternatedolname, sizeof(alternatedname)); - } else { - videoChoice = Settings.video; - languageChoice = Settings.language; - ocarinaChoice = Settings.ocarina; - viChoice = Settings.vpatch; - if (Settings.cios == ios222) { - iosChoice = i222; - } else { - iosChoice = i249; - } - parentalcontrolChoice = 0; - fix002 = Settings.error002; - countrystrings = Settings.patchcountrystrings; - alternatedol = off; - alternatedoloffset = 0; - reloadblock = off; - strcpy(alternatedname, ""); - } + if (game_cfg) { //if there are saved settings for this game use them + videoChoice = game_cfg->video; + languageChoice = game_cfg->language; + ocarinaChoice = game_cfg->ocarina; + viChoice = game_cfg->vipatch; + iosChoice = game_cfg->ios; + parentalcontrolChoice = game_cfg->parentalcontrol; + fix002 = game_cfg->errorfix002; + countrystrings = game_cfg->patchcountrystrings; + alternatedol = game_cfg->loadalternatedol; + alternatedoloffset = game_cfg->alternatedolstart; + reloadblock = game_cfg->iosreloadblock; + strlcpy(alternatedname, game_cfg->alternatedolname, sizeof(alternatedname)); + } + else + { + videoChoice = Settings.video; + languageChoice = Settings.language; + ocarinaChoice = Settings.ocarina; + viChoice = Settings.vpatch; + if (Settings.cios == ios222) + iosChoice = i222; + else + iosChoice = i249; + parentalcontrolChoice = 0; + fix002 = Settings.error002; + countrystrings = Settings.patchcountrystrings; + alternatedol = off; + alternatedoloffset = 0; + reloadblock = off; + strcpy(alternatedname, ""); + } - ResumeGui(); + ResumeGui(); - while (MainButton1.GetEffect() > 0) usleep(50); + while (MainButton1.GetEffect() > 0) usleep(50); - while (menu == MENU_NONE) { - VIDEO_WaitVSync (); + while (menu == MENU_NONE) + { + VIDEO_WaitVSync (); - if (MainButton1.GetState() == STATE_CLICKED) { - w.Append(&saveBtn); - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton1.GetEffect() > 0) usleep(50); - HaltGui(); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - exit = false; - options2.SetLength(11); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetName(i, NULL); - options2.SetName(0, "%s",tr("Video Mode")); - options2.SetName(1, "%s",tr("VIDTV Patch")); - options2.SetName(2,"%s", tr("Game Language")); - options2.SetName(3, "Ocarina"); - options2.SetName(4, "IOS"); - options2.SetName(5,"%s", tr("Parental Control")); - options2.SetName(6,"%s", tr("Error 002 fix")); - options2.SetName(7,"%s", tr("Patch Country Strings")); - options2.SetName(8,"%s", tr("Alternate DOL")); - options2.SetName(9,"%s", tr("Selected DOL")); - options2.SetName(10,"%s", tr("Block IOS Reload")); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetValue(i, NULL); - optionBrowser2.SetScrollbar(1); - w.Append(&optionBrowser2); - optionBrowser2.SetClickable(true); - ResumeGui(); + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); - VIDEO_WaitVSync (); - optionBrowser2.SetEffect(EFFECT_FADE, 20); - while (optionBrowser2.GetEffect() > 0) usleep(50); + if (MainButton1.GetState() == STATE_CLICKED) + { + w.Append(&saveBtn); + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton1.GetEffect() > 0) usleep(50); + HaltGui(); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + exit = false; + options2.SetLength(0); +// optionBrowser2.SetScrollbar(1); + w.Append(&optionBrowser2); + optionBrowser2.SetClickable(true); + ResumeGui(); - int returnhere = 1; - char * languagefile; - languagefile = strrchr(Settings.language_path, '/')+1; + VIDEO_WaitVSync (); + optionBrowser2.SetEffect(EFFECT_FADE, 20); + while (optionBrowser2.GetEffect() > 0) usleep(50); - while (!exit) { - VIDEO_WaitVSync (); + int returnhere = 1; + char * languagefile; + languagefile = strrchr(Settings.language_path, '/')+1; - returnhere = 1; + bool firstRun = true; + while (!exit) + { + VIDEO_WaitVSync (); - if (videoChoice >= 6) - videoChoice = 0; - if (viChoice >= 2) - viChoice = 0; - if (languageChoice >= 11) - languageChoice = 0; - if ( ocarinaChoice >= 2) - ocarinaChoice = 0; - if ( Settings.wsprompt > 1 ) - Settings.wsprompt = 0; - if ( iosChoice >= 3) - iosChoice = 0; - if ( Settings.wiilight > 2 ) - Settings.wiilight = 0; - if (parentalcontrolChoice >= 5) - parentalcontrolChoice = 0; - if (fix002 >= 3) - fix002 = 0; //RUMBLE - if (countrystrings >= 2) - countrystrings = 0; - if (alternatedol >= 3) - alternatedol = 0; - if (reloadblock >= 2) - reloadblock = 0; + returnhere = 1; - if (videoChoice == discdefault) options2.SetValue(0,"%s",tr("Disc Default")); - else if (videoChoice == systemdefault) options2.SetValue(0,"%s",tr("System Default")); - else if (videoChoice == patch) options2.SetValue(0,"%s",tr("AutoPatch")); - else if (videoChoice == pal50) options2.SetValue(0,"%s PAL50",tr("Force")); - else if (videoChoice == pal60) options2.SetValue(0,"%s PAL60",tr("Force")); - else if (videoChoice == ntsc) options2.SetValue(0,"%s NTSC",tr("Force")); + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + if (backBtn.GetState() == STATE_CLICKED) + { + backBtn.ResetState(); + exit = true; + break; + } - if (viChoice == on) options2.SetValue(1,"%s",tr("ON")); - else if (viChoice == off) options2.SetValue(1,"%s",tr("OFF")); + else if (menu == MENU_DISCLIST) + { + w.Remove(&optionBrowser2); + w.Remove(&backBtn); + WindowCredits(); + w.Append(&optionBrowser2); + w.Append(&backBtn); + } - if (languageChoice == ConsoleLangDefault) options2.SetValue(2,"%s",tr("Console Default")); - else if (languageChoice == jap) options2.SetValue(2,"%s",tr("Japanese")); - else if (languageChoice == ger) options2.SetValue(2,"%s",tr("German")); - else if (languageChoice == eng) options2.SetValue(2,"%s",tr("English")); - else if (languageChoice == fren) options2.SetValue(2,"%s",tr("French")); - else if (languageChoice == esp) options2.SetValue(2,"%s",tr("Spanish")); - else if (languageChoice == it) options2.SetValue(2,"%s",tr("Italian")); - else if (languageChoice == dut) options2.SetValue(2,"%s",tr("Dutch")); - else if (languageChoice == schin) options2.SetValue(2,"%s",tr("SChinese")); - else if (languageChoice == tchin) options2.SetValue(2,"%s",tr("TChinese")); - else if (languageChoice == kor) options2.SetValue(2,"%s",tr("Korean")); + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } - if (ocarinaChoice == on) options2.SetValue(3,"%s",tr("ON")); - else if (ocarinaChoice == off) options2.SetValue(3,"%s",tr("OFF")); + else if (saveBtn.GetState() == STATE_CLICKED) + { + if (isInserted(bootDevice)) + { + if (CFG_save_game_opt(header->id)) + { + /* commented because the database language now depends on the main language setting, this could be enabled again if there is a separate language setting for the database + // if game language has changed when saving game settings, reload titles + int opt_langnew = 0; + game_cfg = CFG_get_game_opt(header->id); + if (game_cfg) opt_langnew = game_cfg->language; + if (Settings.titlesOverride==1 && opt_lang != opt_langnew) + OpenXMLDatabase(Settings.titlestxt_path, Settings.db_language, Settings.db_JPtoEN, true, true, false); // open file, reload titles, do not keep in memory + // titles are refreshed in menu.cpp as soon as this function returns + */ + game_cfg = CFG_get_game_opt(header->id); // needed here for "if (game_cfg)" earlier in case it's the first time settings are saved for a game + WindowPrompt(tr("Successfully Saved"), 0, tr("OK")); + } + else + WindowPrompt(tr("Save Failed"), 0, tr("OK")); + } + else + WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - if (iosChoice == i249) options2.SetValue(4,"249"); - else if (iosChoice == i222) options2.SetValue(4,"222"); - else if (iosChoice == i223) options2.SetValue(4,"223"); + saveBtn.ResetState(); + optionBrowser2.SetFocus(1); + } - if (parentalcontrolChoice == 0) options2.SetValue(5, tr("0 (Everyone)")); - else if (parentalcontrolChoice == 1) options2.SetValue(5, tr("1 (Child 7+)")); - else if (parentalcontrolChoice == 2) options2.SetValue(5, tr("2 (Teen 12+)")); - else if (parentalcontrolChoice == 3) options2.SetValue(5, tr("3 (Mature 16+)")); - else if (parentalcontrolChoice == 4) options2.SetValue(5, tr("4 (Adults Only 18+)")); + ret = optionBrowser2.GetClickedOption(); - if (fix002 == on) options2.SetValue(6,tr("ON")); - else if (fix002 == off) options2.SetValue(6,tr("OFF")); - else if (fix002 == anti) options2.SetValue(6,tr("Anti")); + if(ret >= 0 || firstRun == true) + { + int Idx = -1; + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("Video Mode")); + if(ret == Idx && ++videoChoice >= settings_video_max) + videoChoice = 0; + options2.SetValue(Idx,"%s%s",opts_videomode[videoChoice][0], tr(opts_videomode[videoChoice][1])); + } + + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s",tr("VIDTV Patch")); + if(ret == Idx && ++viChoice >= settings_off_on_max) + viChoice = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[viChoice])); - if (countrystrings == on) options2.SetValue(7,tr("ON")); - else if (countrystrings == off) options2.SetValue(7,tr("OFF")); + } - if (alternatedol == on) options2.SetValue(8,tr("Load From SD/USB")); - if (alternatedol == 2) options2.SetValue(8,tr("Select a DOL")); - else if (alternatedol == off) options2.SetValue(8,tr("Default")); + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Game Language")); + if(ret == Idx && ++languageChoice >= settings_language_max) + languageChoice = 0; + options2.SetValue(Idx,"%s",tr(opts_language[languageChoice])); + } - if (alternatedol == on) options2.SetValue(9,tr("SD/USB selected")); - else if (alternatedol == off) options2.SetValue(9,tr("Default")); - else options2.SetValue(9, alternatedname); + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "Ocarina"); + if(ret == Idx && ++ocarinaChoice >= settings_off_on_max) + ocarinaChoice = 0; + options2.SetValue(Idx,"%s",tr(opts_off_on[ocarinaChoice])); + } - if (reloadblock == on) options2.SetValue(10,tr("ON")); - else if (reloadblock == off) options2.SetValue(10,tr("OFF")); + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "IOS"); + if(ret == Idx && ++iosChoice >= settings_ios_max) + iosChoice = 0; + options2.SetValue(Idx,"%s",opts_cios[iosChoice]); + } - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Parental Control")); + if(ret == Idx && ++parentalcontrolChoice >= 5) + parentalcontrolChoice = 0; + options2.SetValue(Idx,"%s", tr(opts_parentalcontrol[parentalcontrolChoice])); + } - if (shutdown == 1) - Sys_Shutdown(); - else if (reset == 1) - Sys_Reboot(); + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Error 002 fix")); + if(ret == Idx && ++fix002 >= settings_error002_max) + fix002 = 0; + options2.SetValue(Idx,"%s", tr(opts_error002[fix002])); + } - else if (menu == MENU_DISCLIST) { - w.Remove(&optionBrowser2); - w.Remove(&backBtn); - WindowCredits(); - w.Append(&optionBrowser2); - w.Append(&backBtn); - } else if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Patch Country Strings")); + if(ret == Idx && ++countrystrings >= settings_off_on_max) + countrystrings = 0; + options2.SetValue(Idx,"%s", tr(opts_off_on[countrystrings])); + } - ret = optionBrowser2.GetClickedOption(); - - switch (ret) { - case 0: - videoChoice = (videoChoice + 1) % CFG_VIDEO_COUNT; - break; - case 1: - viChoice = (viChoice + 1) % 2; - break; - case 2: - languageChoice = (languageChoice + 1) % CFG_LANG_COUNT; - break; - case 3: - ocarinaChoice = (ocarinaChoice + 1) % 2; - break; - case 4: - iosChoice = (iosChoice + 1) % 3; - break; - case 5: - parentalcontrolChoice = (parentalcontrolChoice + 1) % 5; - break; - case 6: - fix002 = (fix002+1) % 3; - break; - case 7: - countrystrings = (countrystrings+1) % 2; - break; - case 8: - alternatedol = (alternatedol+2) % 3; - break; - case 9: - if (alternatedol == 2) { - char filename[10]; - snprintf(filename,sizeof(filename),"%c%c%c%c%c%c",header->id[0], header->id[1], header->id[2], - header->id[3],header->id[4], header->id[5]); - int dolchoice = 0; - //alt dol menu for games that require more than a single alt dol - int autodol = autoSelectDolMenu(filename,false); - - if (autodol>0) { - alternatedoloffset = autodol; - snprintf(alternatedname, sizeof(alternatedname), "%s <%i>", tr("AUTO"),autodol); - } else if (autodol == 0) { - // default was chosen + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Alternate DOL")); + int last_alternatedol = alternatedol; + if(ret == Idx && (alternatedol = (alternatedol+2) % 3) >= 3) // 0->2->1->0 alternatedol = 0; - } else { - //check to see if we already know the offset of the correct dol - int autodol = autoSelectDol(filename, false); - //if we do know that offset ask if they want to use it - if (autodol>0) { - dolchoice = WindowPrompt(0,tr("Do you want to use the alternate DOL that is known to be correct?"),tr("Yes"),tr("Pick from a list"),tr("Cancel")); - if (dolchoice==0) { - alternatedol = 0; - } else if (dolchoice==1) { + static const char *opts[] = {trNOOP("Default"),trNOOP("Load From SD/USB"),trNOOP("Select a DOL")}; + options2.SetValue(Idx,"%s", tr(opts[alternatedol])); + if(last_alternatedol != 1) + { + firstRun = true; // force re-init follow Entries + options2.SetLength(Idx+1); + } + } + + + if(alternatedol == 2 && (ret == ++Idx || firstRun)) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Selected DOL")); + if(ret == Idx) + { + if (alternatedol == 2) + { + char filename[10]; + snprintf(filename,sizeof(filename),"%c%c%c%c%c%c",header->id[0], header->id[1], header->id[2], + header->id[3],header->id[4], header->id[5]); + int dolchoice = 0; + //alt dol menu for games that require more than a single alt dol + int autodol = autoSelectDolMenu(filename, false); + + if (autodol>0) + { alternatedoloffset = autodol; - snprintf(alternatedname, sizeof(alternatedname), "%s <%i>", tr("AUTO"),autodol); - } else if (dolchoice==2) {//they want to search for the correct dol themselves - int res = DiscBrowse(header); - if ((res >= 0)&&(res !=696969)) {//if res==696969 they pressed the back button - alternatedoloffset = res; - } + snprintf(alternatedname, sizeof(alternatedname), "%s <%i>", tr("AUTO"), autodol); } - } else { - int res = DiscBrowse(header); - if ((res >= 0)&&(res !=696969)){ - alternatedoloffset = res; - char tmp[170]; - snprintf(tmp,sizeof(tmp),"%s %s - %i",tr("It seems that you have some information that will be helpful to us. Please pass this information along to the DEV team.") ,filename,alternatedoloffset); - WindowPrompt(0,tmp,tr("OK")); + else if (autodol == 0) + alternatedol = 0; // default was chosen + else + { + //check to see if we already know the offset of the correct dol + int autodol = autoSelectDol(filename, false); + //if we do know that offset ask if they want to use it + if (autodol>0) + { + dolchoice = WindowPrompt(0,tr("Do you want to use the alternate DOL that is known to be correct?"),tr("Yes"),tr("Pick from a list"),tr("Cancel")); + if (dolchoice==0) + alternatedol = 0; + else if (dolchoice==1) + { + alternatedoloffset = autodol; + snprintf(alternatedname, sizeof(alternatedname), "%s <%i>", tr("AUTO"),autodol); + } + else if (dolchoice==2) //they want to search for the correct dol themselves + { + int res = DiscBrowse(header); + if ((res >= 0)&&(res !=696969)) //if res==696969 they pressed the back button + alternatedoloffset = res; + } + } + else + { + int res = DiscBrowse(header); + if ((res >= 0)&&(res !=696969)) + { + alternatedoloffset = res; + char tmp[170]; + snprintf(tmp,sizeof(tmp),"%s %s - %i",tr("It seems that you have some information that will be helpful to us. Please pass this information along to the DEV team.") ,filename,alternatedoloffset); + WindowPrompt(0,tmp,tr("OK")); + } + } } } } - } - break; - case 10: - reloadblock = (reloadblock+1) % 2; - break; + if(alternatedol == 0) + { + firstRun = true; // force re-init follow Entries + options2.SetLength(Idx--); // remove this Entry + options2.SetValue(Idx, "%s", tr("Default")); // re-set prev Entry + } + else + options2.SetValue(Idx, alternatedname); + } - } + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx, "%s", tr("Block IOS Reload")); + if(ret == Idx && ++reloadblock >= settings_off_on_max) + reloadblock = 0; + options2.SetValue(Idx,"%s", tr(opts_off_on[reloadblock])); + } - if (saveBtn.GetState() == STATE_CLICKED) { + firstRun = false; + } + } - if (isInserted(bootDevice)) { - if (CFG_save_game_opt(header->id)) { - /* commented because the database language now depends on the main language setting, this could be enabled again if there is a separate language setting for the database - // if game language has changed when saving game settings, reload titles - int opt_langnew = 0; - game_cfg = CFG_get_game_opt(header->id); - if (game_cfg) opt_langnew = game_cfg->language; - if (Settings.titlesOverride==1 && opt_lang != opt_langnew) - OpenXMLDatabase(Settings.titlestxt_path, Settings.db_language, Settings.db_JPtoEN, true, true, false); // open file, reload titles, do not keep in memory - // titles are refreshed in menu.cpp as soon as this function returns - */ - game_cfg = CFG_get_game_opt(header->id); // needed here for "if (game_cfg)" earlier in case it's the first time settings are saved for a game - WindowPrompt(tr("Successfully Saved"), 0, tr("OK")); - } else { - WindowPrompt(tr("Save Failed"), 0, tr("OK")); - } - } else { - WindowPrompt(tr("No SD-Card inserted!"), tr("Insert an SD-Card to save."), tr("OK")); - } + optionBrowser2.SetEffect(EFFECT_FADE, -20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + MainButton1.ResetState(); + break; + w.Remove(&saveBtn); + } - saveBtn.ResetState(); - optionBrowser2.SetFocus(1); - } - } + else if (MainButton2.GetState() == STATE_CLICKED) + { + char ID[7]; + snprintf (ID,sizeof(ID),"%c%c%c%c%c%c", header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); + CheatMenu(ID); + MainButton2.ResetState(); + break; + } - optionBrowser2.SetEffect(EFFECT_FADE, -20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - MainButton1.ResetState(); - break; - w.Remove(&saveBtn); - } + else if (MainButton3.GetState() == STATE_CLICKED) + { + MainButton1.SetEffect(EFFECT_FADE, -20); + MainButton2.SetEffect(EFFECT_FADE, -20); + MainButton3.SetEffect(EFFECT_FADE, -20); + MainButton4.SetEffect(EFFECT_FADE, -20); + while (MainButton3.GetEffect() > 0) usleep(50); + HaltGui(); + w.Remove(&MainButton1); + w.Remove(&MainButton2); + w.Remove(&MainButton3); + w.Remove(&MainButton4); + exit = false; + options2.SetLength(0); + w.Append(&optionBrowser2); + optionBrowser2.SetClickable(true); + ResumeGui(); - if (MainButton2.GetState() == STATE_CLICKED) { - char ID[7]; - snprintf (ID,sizeof(ID),"%c%c%c%c%c%c", header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); - CheatMenu(ID); - MainButton2.ResetState(); - break; - } + bool firstRun = true; - if (MainButton3.GetState() == STATE_CLICKED) { - MainButton1.SetEffect(EFFECT_FADE, -20); - MainButton2.SetEffect(EFFECT_FADE, -20); - MainButton3.SetEffect(EFFECT_FADE, -20); - MainButton4.SetEffect(EFFECT_FADE, -20); - while (MainButton3.GetEffect() > 0) usleep(50); - HaltGui(); - w.Remove(&MainButton1); - w.Remove(&MainButton2); - w.Remove(&MainButton3); - w.Remove(&MainButton4); - exit = false; - options2.SetLength(6); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetName(i, NULL); - options2.SetName(0,"%s", tr("Uninstall Game")); - options2.SetName(1,"%s", tr("Reset Playcounter")); - options2.SetName(2,"%s", tr("Delete Cover Artwork")); - options2.SetName(3,"%s", tr("Delete Disc Artwork")); - options2.SetName(4,"%s", tr("Delete Cheat TXT")); - options2.SetName(5,"%s", tr("Delete Cheat GCT")); - for (int i = 0; i <= MAXOPTIONS; i++) options2.SetValue(i, NULL); - w.Append(&optionBrowser2); - optionBrowser2.SetClickable(true); - ResumeGui(); + optionBrowser2.SetEffect(EFFECT_FADE, 20); + while (optionBrowser2.GetEffect() > 0) usleep(50); - VIDEO_WaitVSync (); - optionBrowser2.SetEffect(EFFECT_FADE, 20); - while (optionBrowser2.GetEffect() > 0) usleep(50); + while (!exit) + { + VIDEO_WaitVSync (); - while (!exit) { - VIDEO_WaitVSync (); + if (shutdown == 1) + Sys_Shutdown(); + if (reset == 1) + Sys_Reboot(); + if (backBtn.GetState() == STATE_CLICKED) + { + backBtn.ResetState(); + exit = true; + break; + } - if (backBtn.GetState() == STATE_CLICKED) { - backBtn.ResetState(); - exit = true; - break; - } + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } - if (shutdown == 1) - Sys_Shutdown(); - else if (reset == 1) - Sys_Reboot(); + ret = optionBrowser2.GetClickedOption(); - else if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } + if(firstRun || ret >= 0) + { + int Idx = -1; + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx,"%s", tr("Uninstall Game")); + if(ret == Idx) + { + int choice1 = WindowPrompt(tr("Do you really want to delete:"),gameName,tr("Yes"),tr("Cancel")); + if (choice1 == 1 && !mountMethod) + { + CFG_forget_game_opt(header->id); + CFG_forget_game_num(header->id); + ret = WBFS_RemoveGame(header->id); + if (ret < 0) + { + WindowPrompt( + tr("Can't delete:"), + gameName, + tr("OK")); + } + else + { + WindowPrompt(tr("Successfully deleted:"),gameName,tr("OK")); + retVal = 1; + } + } + else if (choice1 == 0) + optionBrowser2.SetFocus(1); + } + } - ret = optionBrowser2.GetClickedOption(); + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx,"%s", tr("Reset Playcounter")); + if(ret == Idx) + { + int result = WindowPrompt(tr("Are you sure?"),0,tr("Yes"),tr("Cancel")); + if (result == 1) + { + if (isInserted(bootDevice)) + { + struct Game_NUM* game_num = CFG_get_game_num(header->id); + if (game_num) + { + favoritevar = game_num->favorite; + playcount = game_num->count; + } + else + { + favoritevar = 0; + playcount = 0; + } + playcount = 0; + CFG_save_game_num(header->id); + } + } + } + } - int choice1; - char tmp[200]; - switch (ret) { - case 0: - choice1 = WindowPrompt(tr("Do you really want to delete:"),gameName,tr("Yes"),tr("Cancel")); - if (choice1 == 1 && !mountMethod) { - CFG_forget_game_opt(header->id); - CFG_forget_game_num(header->id); - ret = WBFS_RemoveGame(header->id); - if (ret < 0) { - WindowPrompt( - tr("Can't delete:"), - gameName, - tr("OK")); - } else { - WindowPrompt(tr("Successfully deleted:"),gameName,tr("OK")); - retVal = 1; - } - } else if (choice1 == 0) { - optionBrowser2.SetFocus(1); - } - break; - case 1: - int result; - result = WindowPrompt(tr("Are you sure?"),0,tr("Yes"),tr("Cancel")); - if (result == 1) { - if (isInserted(bootDevice)) { - struct Game_NUM* game_num = CFG_get_game_num(header->id); - if (game_num) { - favoritevar = game_num->favorite; - playcount = game_num->count; - } else { - favoritevar = 0; - playcount = 0; - } - playcount = 0; - CFG_save_game_num(header->id); - } - } - break; - case 2: + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx,"%s", tr("Delete Cover Artwork")); + if(ret == Idx) + { + char tmp[200]; + snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.png", Settings.covers_path, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); - snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.png", Settings.covers_path, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); + int choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); + if (choice1==1) + { + if (checkfile(tmp)) + remove(tmp); + } + } + } - choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); - if (choice1==1) { - if (checkfile(tmp)) - remove(tmp); - } - break; - case 3: + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx,"%s", tr("Delete Disc Artwork")); + if(ret == Idx) + { + char tmp[200]; + snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.png", Settings.disc_path, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); - snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.png", Settings.disc_path, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); + int choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); + if (choice1==1) + { + if (checkfile(tmp)) + remove(tmp); + } + } + } - choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); - if (choice1==1) { - if (checkfile(tmp)) - remove(tmp); - } - break; - case 4: + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx,"%s", tr("Delete Cheat TXT")); + if(ret == Idx) + { + char tmp[200]; + snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.txt", Settings.TxtCheatcodespath, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); - snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.txt", Settings.TxtCheatcodespath, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); + int choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); + if (choice1==1) + { + if (checkfile(tmp)) + remove(tmp); + } + } + } - choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); - if (choice1==1) { - if (checkfile(tmp)) - remove(tmp); - } - break; - case 5: + if(ret == ++Idx || firstRun) + { + if(firstRun) options2.SetName(Idx,"%s", tr("Delete Cheat GCT")); + if(ret == Idx) + { + char tmp[200]; + snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.gct", Settings.Cheatcodespath, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); - snprintf(tmp,sizeof(tmp),"%s%c%c%c%c%c%c.gct", Settings.Cheatcodespath, header->id[0], header->id[1], header->id[2],header->id[3], header->id[4], header->id[5]); + int choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); + if (choice1==1) + { + if (checkfile(tmp)) + remove(tmp); + } + } + } - choice1 = WindowPrompt(tr("Delete"),tmp,tr("Yes"),tr("No")); - if (choice1==1) { - if (checkfile(tmp)) - remove(tmp); - } - break; - } - } - optionBrowser2.SetEffect(EFFECT_FADE, -20); - while (optionBrowser2.GetEffect() > 0) usleep(50); - pageToDisplay = 1; - MainButton3.ResetState(); - break; - } + firstRun = false; + } + } + optionBrowser2.SetEffect(EFFECT_FADE, -20); + while (optionBrowser2.GetEffect() > 0) usleep(50); + pageToDisplay = 1; + MainButton3.ResetState(); + break; + } - if (MainButton4.GetState() == STATE_CLICKED) { - - int choice1 = WindowPrompt(tr("Are you sure?"),0,tr("Yes"),tr("Cancel")); - if (choice1 == 1) { - videoChoice = Settings.video; - viChoice = Settings.vpatch; - languageChoice = Settings.language; - ocarinaChoice = Settings.ocarina; - fix002 = Settings.error002; - countrystrings = Settings.patchcountrystrings; - alternatedol = off; - alternatedoloffset = 0; - reloadblock = off; - if (Settings.cios == ios222) { - iosChoice = i222; - } else { - iosChoice = i249; - } - parentalcontrolChoice = 0; - strcpy(alternatedname, ""); - CFG_forget_game_opt(header->id); + else if (MainButton4.GetState() == STATE_CLICKED) + { + int choice1 = WindowPrompt(tr("Are you sure?"),0,tr("Yes"),tr("Cancel")); + if (choice1 == 1) + { + videoChoice = Settings.video; + viChoice = Settings.vpatch; + languageChoice = Settings.language; + ocarinaChoice = Settings.ocarina; + fix002 = Settings.error002; + countrystrings = Settings.patchcountrystrings; + alternatedol = off; + alternatedoloffset = 0; + reloadblock = off; + if (Settings.cios == ios222) + iosChoice = i222; + else + iosChoice = i249; + parentalcontrolChoice = 0; + strcpy(alternatedname, ""); + CFG_forget_game_opt(header->id); /* commented because the database language now depends on the main language setting, this could be enabled again if there is a separate language setting for the database - // if default language is different than language from main settings, reload titles - int opt_langnew = 0; - opt_langnew = Settings.language; - if (Settings.titlesOverride==1 && opt_lang != opt_langnew) - OpenXMLDatabase(Settings.titlestxt_path, Settings.db_language, Settings.db_JPtoEN, true, true, false); // open file, reload titles, do not keep in memory - // titles are refreshed in menu.cpp as soon as this function returns + // if default language is different than language from main settings, reload titles + int opt_langnew = 0; + opt_langnew = Settings.language; + if (Settings.titlesOverride==1 && opt_lang != opt_langnew) + OpenXMLDatabase(Settings.titlestxt_path, Settings.db_language, Settings.db_JPtoEN, true, true, false); // open file, reload titles, do not keep in memory + // titles are refreshed in menu.cpp as soon as this function returns */ - } + } - pageToDisplay = 1; - MainButton4.ResetState(); - break; - } + pageToDisplay = 1; + MainButton4.ResetState(); + break; + } - if (shutdown == 1) - Sys_Shutdown(); - if (reset == 1) - Sys_Reboot(); + else if (backBtn.GetState() == STATE_CLICKED) + { + menu = MENU_DISCLIST; + pageToDisplay = 0; + break; + } - if (backBtn.GetState() == STATE_CLICKED) { - menu = MENU_DISCLIST; - pageToDisplay = 0; - break; - } - - if (homo.GetState() == STATE_CLICKED) { - cfg_save_global(); - optionBrowser2.SetState(STATE_DISABLED); - s32 thetimeofbg = bgMusic->GetPlayTime(); - bgMusic->Stop(); - choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); + else if (homo.GetState() == STATE_CLICKED) + { + cfg_save_global(); + optionBrowser2.SetState(STATE_DISABLED); + s32 thetimeofbg = bgMusic->GetPlayTime(); + bgMusic->Stop(); + choice = WindowExitPrompt(tr("Exit USB Loader GX?"),0, tr("Back to Loader"),tr("Wii Menu"),tr("Back"),0); /* // if language has changed, reload titles int opt_langnew = 0; @@ -2671,35 +2843,33 @@ int GameSettings(struct discHdr * header) { OpenXMLDatabase(Settings.titlestxt_path, Settings.db_language, Settings.db_JPtoEN, false, Settings.titlesOverride==1?true:false, true); // open file, reload titles, keep in memory // titles are refreshed in menu.cpp as soon as this function returns */ - if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) { - bgMusic->Play(); - } else { - bgMusic->PlayOggFile(Settings.ogg_path); - } - bgMusic->SetPlayTime(thetimeofbg); - SetVolumeOgg(255*(Settings.volume/100.0)); + if (!strcmp("", Settings.oggload_path) || !strcmp("notset", Settings.ogg_path)) + bgMusic->Play(); + else + bgMusic->PlayOggFile(Settings.ogg_path); + bgMusic->SetPlayTime(thetimeofbg); + SetVolumeOgg(255*(Settings.volume/100.0)); - if (choice == 3) { - Sys_LoadMenu(); // Back to System Menu - } else if (choice == 2) { - Sys_BackToLoader(); - } else { - homo.ResetState(); - } - optionBrowser2.SetState(STATE_DEFAULT); - } - } - } - w.SetEffect(EFFECT_FADE, -20); - while (w.GetEffect()>0) usleep(50); + if (choice == 3) + Sys_LoadMenu(); // Back to System Menu + else if (choice == 2) + Sys_BackToLoader(); + else + homo.ResetState(); + optionBrowser2.SetState(STATE_DEFAULT); + } + } + } + w.SetEffect(EFFECT_FADE, -20); + while (w.GetEffect()>0) usleep(50); - HaltGui(); + HaltGui(); - mainWindow->RemoveAll(); - mainWindow->Append(bgImg); + mainWindow->RemoveAll(); + mainWindow->Append(bgImg); - ResumeGui(); - return retVal; + ResumeGui(); + return retVal; } diff --git a/source/settings/cfg.h b/source/settings/cfg.h index 3e2179e7..5ed47de1 100644 --- a/source/settings/cfg.h +++ b/source/settings/cfg.h @@ -44,10 +44,10 @@ extern "C" { extern char bootDevice[10]; //extern char *cfg_path; - struct CFG { - short widescreen; - char theme_path[100]; - }; + struct CFG { + short widescreen; + char theme_path[100]; + }; struct THEME { @@ -110,8 +110,8 @@ extern "C" { GXColor gametext; short pagesize; -// Toolbar Icons in GameList -/* + // Toolbar Icons in GameList + /* short favorite_x; short favorite_y; short search_x; @@ -127,8 +127,8 @@ extern "C" { short carousel_x; short carousel_y; short sortBarOffset; -*/ -// Toolbar Icons in GameList + */ + // Toolbar Icons in GameList short gamelist_favorite_x; short gamelist_favorite_y; short gamelist_search_x; @@ -145,7 +145,7 @@ extern "C" { short gamelist_carousel_y; short gamelist_dvd_x; short gamelist_dvd_y; -// Toolbar Icons in GameGrid + // Toolbar Icons in GameGrid short gamegrid_favorite_x; short gamegrid_favorite_y; short gamegrid_search_x; @@ -162,7 +162,7 @@ extern "C" { short gamegrid_carousel_y; short gamegrid_dvd_x; short gamegrid_dvd_y; -// Toolbar Icons in GameCarousel + // Toolbar Icons in GameCarousel short gamecarousel_favorite_x; short gamecarousel_favorite_y; short gamecarousel_search_x; @@ -182,246 +182,257 @@ extern "C" { }; - extern struct CFG CFG; - extern struct THEME THEME; - extern u8 ocarinaChoice; - extern u16 playcnt; - extern u8 videoChoice; - extern u8 languageChoice; - extern u8 viChoice; - extern u8 iosChoice; - extern u8 parentalcontrolChoice; - extern u8 fix002; - extern u8 reloadblock; - extern u8 countrystrings; - extern u8 alternatedol; - extern u32 alternatedoloffset; - extern u8 xflip; - extern u8 qboot; - extern u8 sort; - extern u8 fave; - extern u8 wsprompt; - extern u8 keyset; - extern u8 gameDisplay; - extern u16 playcount; - extern u8 favoritevar; - extern char alternatedname[40]; + extern struct CFG CFG; + extern struct THEME THEME; + extern u8 ocarinaChoice; + extern u16 playcnt; + extern u8 videoChoice; + extern u8 languageChoice; + extern u8 viChoice; + extern u8 iosChoice; + extern u8 parentalcontrolChoice; + extern u8 fix002; + extern u8 reloadblock; + extern u8 countrystrings; + extern u8 alternatedol; + extern u32 alternatedoloffset; + extern u8 xflip; + extern u8 qboot; + extern u8 sort; + extern u8 fave; + extern u8 wsprompt; + extern u8 keyset; + extern u8 gameDisplay; + extern u16 playcount; + extern u8 favoritevar; + extern char alternatedname[40]; - struct Game_CFG { - u8 id[8]; - u8 video; - u8 language; - u8 ocarina; - u8 vipatch; - u8 ios; - u8 parentalcontrol; - u8 errorfix002; - u8 iosreloadblock; - u8 loadalternatedol; - u32 alternatedolstart; - u8 patchcountrystrings; - char alternatedolname[40]; - }; - struct Game_NUM { - u8 id[8]; - u8 favorite; - u16 count; - }; + struct Game_CFG { + u8 id[8]; + u8 video; + u8 language; + u8 ocarina; + u8 vipatch; + u8 ios; + u8 parentalcontrol; + u8 errorfix002; + u8 iosreloadblock; + u8 loadalternatedol; + u32 alternatedolstart; + u8 patchcountrystrings; + char alternatedolname[40]; + }; + struct Game_NUM { + u8 id[8]; + u8 favorite; + u16 count; + }; - void CFG_Default(int widescreen); // -1 = non forced mode - void CFG_Load(void); - struct Game_CFG* CFG_get_game_opt(u8 *id); - struct Game_NUM* CFG_get_game_num(u8 *id); - bool CFG_save_game_opt(u8 *id); - bool CFG_save_game_num(u8 *id); - bool CFG_reset_all_playcounters(); - bool CFG_forget_game_opt(u8 *id); - bool CFG_forget_game_num(u8 *id); + void CFG_Default(int widescreen); // -1 = non forced mode + void CFG_Load(void); + struct Game_CFG* CFG_get_game_opt(u8 *id); + struct Game_NUM* CFG_get_game_num(u8 *id); + bool CFG_save_game_opt(u8 *id); + bool CFG_save_game_num(u8 *id); + bool CFG_reset_all_playcounters(); + bool CFG_forget_game_opt(u8 *id); + bool CFG_forget_game_num(u8 *id); - enum { - ConsoleLangDefault=0, - jap, - eng, - ger, - fren, - esp, - it, - dut, - schin, - tchin, - kor, - settings_language_max // always the last entry - }; + enum { + ConsoleLangDefault=0, + jap, + eng, + ger, + fren, + esp, + it, + dut, + schin, + tchin, + kor, + settings_language_max // always the last entry + }; - enum { - systemdefault=0, - discdefault, - patch, - pal50, - pal60, - ntsc, - settings_video_max // always the last entry - }; + enum { + systemdefault=0, + discdefault, + patch, + pal50, + pal60, + ntsc, + settings_video_max // always the last entry + }; - enum { - off=0, - on, - settings_off_on_max // always the last entry - }; - enum { - anti=2, - }; + enum { + off=0, + on, + settings_off_on_max // always the last entry + }; + enum { + //off=0, + //on, + anti=2, + settings_error002_max // always the last entry + }; - enum { - GameID, - GameRegion, - Both, - Neither, - settings_sinfo_max // always the last entry - }; + enum { + wiilight_off=0, + wiilight_on, + wiilight_forInstall, + settings_wiilight_max // always the last entry + }; - enum { - i249=0, - i222, - i223 - }; + enum { + GameID, + GameRegion, + Both, + Neither, + settings_sinfo_max // always the last entry + }; - enum { - ios249=0, - ios222, - settings_cios_max // always the last entry - }; + enum { + i249=0, + i222, + i223, + settings_ios_max // always the last entry + }; - enum { - hr12=0, - hr24, - Off, - settings_clock_max // always the last entry - }; - enum { - all=0, - pcount, - }; + enum { + ios249=0, + ios222, + settings_cios_max // always the last entry + }; - enum { - RumbleOff=0, - RumbleOn, - settings_rumble_max // always the last entry - }; + enum { + hr12=0, + hr24, + Off, + settings_clock_max // always the last entry + }; + enum { + all=0, + pcount, + }; - enum { - TooltipsOff=0, - TooltipsOn, - settings_tooltips_max // always the last entry - }; + enum { + RumbleOff=0, + RumbleOn, + settings_rumble_max // always the last entry + }; - enum { - min3=1, - min5, - min10, - min20, - min30, - min60, - settings_screensaver_max // always the last entry - }; + enum { + TooltipsOff=0, + TooltipsOn, + settings_tooltips_max // always the last entry + }; - enum { - no=0, - yes, - sysmenu, - wtf, - disk3d, - settings_xflip_max // always the last entry - }; - enum { - us=0, - qwerty, - dvorak, - euro, - azerty, - settings_keyset_max // always the last entry - }; - enum { - list, - grid, - carousel, - settings_display_max - }; - enum { - scrollDefault, - scrollMarquee, - settings_scrolleffect_max // always the last entry - }; - struct SSettings { - u8 video; - u8 language; - u8 ocarina; - u8 vpatch; - int ios; - u8 sinfo; - u8 hddinfo; - u8 rumble; - u8 xflip; - int volume; - int sfxvolume; - u8 tooltips; - char unlockCode[20]; - u8 parentalcontrol; - u8 cios; - u8 qboot; - u8 wsprompt; - u8 keyset; - u8 sort; - u8 fave; - u8 wiilight; - u8 gameDisplay; - u8 patchcountrystrings; - u8 screensaver; - short godmode; + enum { + min3=1, + min5, + min10, + min20, + min30, + min60, + settings_screensaver_max // always the last entry + }; + + enum { + no=0, + yes, + sysmenu, + wtf, + disk3d, + settings_xflip_max // always the last entry + }; + enum { + us=0, + qwerty, + dvorak, + euro, + azerty, + settings_keyset_max // always the last entry + }; + enum { + list, + grid, + carousel, + settings_display_max + }; + enum { + scrollDefault, + scrollMarquee, + settings_scrolleffect_max // always the last entry + }; + struct SSettings { + u8 video; + u8 language; + u8 ocarina; + u8 vpatch; + int ios; + u8 sinfo; + u8 hddinfo; + u8 rumble; + u8 xflip; + int volume; + int sfxvolume; + u8 tooltips; + char unlockCode[20]; + u8 parentalcontrol; + u8 cios; + u8 qboot; + u8 wsprompt; + u8 keyset; + u8 sort; + u8 fave; + u8 wiilight; + u8 gameDisplay; + u8 patchcountrystrings; + u8 screensaver; + short godmode; char covers_path[100]; - char covers2d_path[100]; - char theme_path[100]; - char wtheme_path[100]; + char covers2d_path[100]; + char theme_path[100]; + char wtheme_path[100]; char theme_downloadpath[100]; - char disc_path[100]; - char titlestxt_path[100]; - char language_path[100]; - char languagefiles_path[100]; - char oggload_path[100]; - char ogg_path[150]; - char dolpath[150]; - char update_path[150]; - char homebrewapps_path[150]; - char selected_homebrew[200]; - char Cheatcodespath[100]; - char TxtCheatcodespath[100]; - short error002; - u8 titlesOverride; // db_titles - char db_url[200]; - char db_language[20]; - u8 db_JPtoEN; - u8 gridRows; - u8 autonetwork; - u8 discart; - }; + char disc_path[100]; + char titlestxt_path[100]; + char language_path[100]; + char languagefiles_path[100]; + char oggload_path[100]; + char ogg_path[150]; + char dolpath[150]; + char update_path[150]; + char homebrewapps_path[150]; + char selected_homebrew[200]; + char Cheatcodespath[100]; + char TxtCheatcodespath[100]; + short error002; + u8 titlesOverride; // db_titles + char db_url[200]; + char db_language[20]; + u8 db_JPtoEN; + u8 gridRows; + u8 autonetwork; + u8 discart; + }; - void CFG_LoadGlobal(void); - bool cfg_save_global(void); + void CFG_LoadGlobal(void); + bool cfg_save_global(void); void GetLanguageToLangCode(int *langid, char *langcode); - bool OpenXMLDatabase(char* xmlfilepath, char* argdblang, bool argJPtoEN, bool openfile, bool loadtitles, bool freemem); + bool OpenXMLDatabase(char* xmlfilepath, char* argdblang, bool argJPtoEN, bool openfile, bool loadtitles, bool freemem); - char *get_title(struct discHdr *header); + char *get_title(struct discHdr *header); char *cfg_get_title(u8 *id) ; void title_set(char *id, char *title); void titles_default(); - u8 get_block(struct discHdr *header); + u8 get_block(struct discHdr *header); - void CFG_Cleanup(void); + void CFG_Cleanup(void); #ifdef __cplusplus }