mirror of
https://github.com/wiidev/usbloadergx.git
synced 2024-11-29 06:34:17 +01:00
fix code dumps when loading without a SD card
add screenshot shit to gameinfo window
This commit is contained in:
parent
cb628348d6
commit
5d19915af8
@ -2,8 +2,8 @@
|
|||||||
<app version="1">
|
<app version="1">
|
||||||
<name> USB Loader GX</name>
|
<name> USB Loader GX</name>
|
||||||
<coder>USB Loader GX Team</coder>
|
<coder>USB Loader GX Team</coder>
|
||||||
<version>1.0 r871</version>
|
<version>1.0 r872</version>
|
||||||
<release_date>200912192124</release_date>
|
<release_date>200912200514</release_date>
|
||||||
<short_description>Loads games from USB-devices</short_description>
|
<short_description>Loads games from USB-devices</short_description>
|
||||||
<long_description>USB Loader GX is a libwiigui based USB iso loader with a wii-like GUI. You can install games to your HDDs and boot them with shorter loading times.
|
<long_description>USB Loader GX is a libwiigui based USB iso loader with a wii-like GUI. You can install games to your HDDs and boot them with shorter loading times.
|
||||||
The interactive GUI is completely controllable with WiiMote, Classic Controller or GC Controller.
|
The interactive GUI is completely controllable with WiiMote, Classic Controller or GC Controller.
|
||||||
|
@ -105,7 +105,7 @@ int MenuCheck() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (ret2 >= 0 || load_from_fs != PART_FS_WBFS) {
|
if ((ret2 >= 0 || load_from_fs != PART_FS_WBFS) && isInserted(bootDevice)) {
|
||||||
cfg_save_global();
|
cfg_save_global();
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -138,7 +138,7 @@ int MenuCheck() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// open database if needed, load titles if needed
|
// open database if needed, load titles if needed
|
||||||
OpenXMLDatabase(Settings.titlestxt_path,Settings.db_language, Settings.db_JPtoEN, true, Settings.titlesOverride==1?true:false, true);
|
if(isInserted(bootDevice))OpenXMLDatabase(Settings.titlestxt_path,Settings.db_language, Settings.db_JPtoEN, true, Settings.titlesOverride==1?true:false, true);
|
||||||
|
|
||||||
// titles.txt loaded after database to override database titles with custom titles
|
// titles.txt loaded after database to override database titles with custom titles
|
||||||
//snprintf(pathname, sizeof(pathname), "%stitles.txt", Settings.titlestxt_path);
|
//snprintf(pathname, sizeof(pathname), "%stitles.txt", Settings.titlestxt_path);
|
||||||
|
@ -1227,6 +1227,7 @@ int MenuDiscList() {
|
|||||||
case 'W':
|
case 'W':
|
||||||
sprintf(gameregion,"NTSC T");
|
sprintf(gameregion,"NTSC T");
|
||||||
break;
|
break;
|
||||||
|
default:
|
||||||
case 'K':
|
case 'K':
|
||||||
sprintf(gameregion,"NTSC K");
|
sprintf(gameregion,"NTSC K");
|
||||||
break;
|
break;
|
||||||
|
@ -113,7 +113,7 @@ int MenuFormat() {
|
|||||||
menu = MENU_DISCLIST;
|
menu = MENU_DISCLIST;
|
||||||
|
|
||||||
Settings.partition = ret;
|
Settings.partition = ret;
|
||||||
cfg_save_global();
|
if(isInserted(bootDevice))cfg_save_global();
|
||||||
} else {
|
} else {
|
||||||
sprintf(text, "%s %d : %.2fGB",tr("Partition"), ret+1, entry->size * (partitions.sector_size / GB_SIZE));
|
sprintf(text, "%s %d : %.2fGB",tr("Partition"), ret+1, entry->size * (partitions.sector_size / GB_SIZE));
|
||||||
choice = WindowPrompt( tr("Do you want to format:"), text,tr("Yes"),tr("No"));
|
choice = WindowPrompt( tr("Do you want to format:"), text,tr("Yes"),tr("No"));
|
||||||
|
@ -18,6 +18,7 @@
|
|||||||
#include "prompts/PromptWindows.h"
|
#include "prompts/PromptWindows.h"
|
||||||
#include "gameinfo.h"
|
#include "gameinfo.h"
|
||||||
#include "usbloader/getentries.h"
|
#include "usbloader/getentries.h"
|
||||||
|
#include "../gecko.h"
|
||||||
|
|
||||||
|
|
||||||
/*** Extern variables ***/
|
/*** Extern variables ***/
|
||||||
@ -779,6 +780,14 @@ int showGameInfo(char *ID) {
|
|||||||
gameinfoWindow.Append(wiitdb3Txt);
|
gameinfoWindow.Append(wiitdb3Txt);
|
||||||
|
|
||||||
gameinfoWindow.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 100);
|
gameinfoWindow.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_IN, 100);
|
||||||
|
|
||||||
|
GuiTrigger trigZ;
|
||||||
|
trigZ.SetButtonOnlyTrigger(-1, WPAD_NUNCHUK_BUTTON_Z | WPAD_CLASSIC_BUTTON_ZL, PAD_TRIGGER_Z);
|
||||||
|
|
||||||
|
GuiButton screenShotBtn(0,0);
|
||||||
|
screenShotBtn.SetPosition(0,0);
|
||||||
|
screenShotBtn.SetTrigger(&trigZ);
|
||||||
|
gameinfoWindow.Append(&screenShotBtn);
|
||||||
HaltGui();
|
HaltGui();
|
||||||
//mainWindow->SetState(STATE_DISABLED);
|
//mainWindow->SetState(STATE_DISABLED);
|
||||||
mainWindow->Append(&gameinfoWindow);
|
mainWindow->Append(&gameinfoWindow);
|
||||||
@ -806,13 +815,15 @@ int showGameInfo(char *ID) {
|
|||||||
HaltGui();
|
HaltGui();
|
||||||
gameinfoWindow2.Remove(&nextBtn);
|
gameinfoWindow2.Remove(&nextBtn);
|
||||||
gameinfoWindow2.Remove(&backBtn);
|
gameinfoWindow2.Remove(&backBtn);
|
||||||
gameinfoWindow2.Remove(&homeBtn);
|
gameinfoWindow2.Remove(&homeBtn);
|
||||||
gameinfoWindow2.SetVisible(false);
|
gameinfoWindow2.Remove(&screenShotBtn);
|
||||||
|
gameinfoWindow2.SetVisible(false);
|
||||||
gameinfoWindow.SetVisible(true);
|
gameinfoWindow.SetVisible(true);
|
||||||
gameinfoWindow.Append(&backBtn);
|
gameinfoWindow.Append(&backBtn);
|
||||||
gameinfoWindow.Append(&nextBtn);
|
gameinfoWindow.Append(&nextBtn);
|
||||||
gameinfoWindow.Append(&homeBtn);
|
gameinfoWindow.Append(&homeBtn);
|
||||||
mainWindow->Remove(&gameinfoWindow2);
|
gameinfoWindow.Append(&screenShotBtn);
|
||||||
|
mainWindow->Remove(&gameinfoWindow2);
|
||||||
ResumeGui();
|
ResumeGui();
|
||||||
page=1;
|
page=1;
|
||||||
}
|
}
|
||||||
@ -823,27 +834,31 @@ int showGameInfo(char *ID) {
|
|||||||
HaltGui();
|
HaltGui();
|
||||||
gameinfoWindow.Remove(&nextBtn);
|
gameinfoWindow.Remove(&nextBtn);
|
||||||
gameinfoWindow.Remove(&backBtn);
|
gameinfoWindow.Remove(&backBtn);
|
||||||
gameinfoWindow.Remove(&homeBtn);
|
gameinfoWindow.Remove(&homeBtn);
|
||||||
gameinfoWindow.SetVisible(false);
|
gameinfoWindow.Remove(&screenShotBtn);
|
||||||
|
gameinfoWindow.SetVisible(false);
|
||||||
gameinfoWindow2.SetVisible(true);
|
gameinfoWindow2.SetVisible(true);
|
||||||
coverImg->SetPosition(15,30);
|
coverImg->SetPosition(15,30);
|
||||||
gameinfoWindow2.Append(&nextBtn);
|
gameinfoWindow2.Append(&nextBtn);
|
||||||
gameinfoWindow2.Append(&backBtn);
|
gameinfoWindow2.Append(&backBtn);
|
||||||
gameinfoWindow2.Append(&homeBtn);
|
gameinfoWindow2.Append(&homeBtn);
|
||||||
mainWindow->Append(&gameinfoWindow2);
|
gameinfoWindow2.Append(&screenShotBtn);
|
||||||
|
mainWindow->Append(&gameinfoWindow2);
|
||||||
ResumeGui();
|
ResumeGui();
|
||||||
page=2;
|
page=2;
|
||||||
} else {
|
} else {
|
||||||
HaltGui();
|
HaltGui();
|
||||||
gameinfoWindow2.Remove(&nextBtn);
|
gameinfoWindow2.Remove(&nextBtn);
|
||||||
gameinfoWindow2.Remove(&backBtn);
|
gameinfoWindow2.Remove(&backBtn);
|
||||||
gameinfoWindow2.Remove(&homeBtn);
|
gameinfoWindow2.Remove(&homeBtn);
|
||||||
gameinfoWindow2.SetVisible(false);
|
gameinfoWindow2.Remove(&screenShotBtn);
|
||||||
|
gameinfoWindow2.SetVisible(false);
|
||||||
gameinfoWindow.SetVisible(true);
|
gameinfoWindow.SetVisible(true);
|
||||||
gameinfoWindow.Append(&backBtn);
|
gameinfoWindow.Append(&backBtn);
|
||||||
gameinfoWindow.Append(&nextBtn);
|
gameinfoWindow.Append(&nextBtn);
|
||||||
gameinfoWindow.Append(&homeBtn);
|
gameinfoWindow.Append(&homeBtn);
|
||||||
mainWindow->Remove(&gameinfoWindow2);
|
gameinfoWindow.Append(&screenShotBtn);
|
||||||
|
mainWindow->Remove(&gameinfoWindow2);
|
||||||
ResumeGui();
|
ResumeGui();
|
||||||
page=1;
|
page=1;
|
||||||
}
|
}
|
||||||
@ -901,6 +916,12 @@ int showGameInfo(char *ID) {
|
|||||||
}
|
}
|
||||||
urlBtn.ResetState();
|
urlBtn.ResetState();
|
||||||
}
|
}
|
||||||
|
else if (screenShotBtn.GetState() == STATE_CLICKED) {
|
||||||
|
gprintf("\n\tscreenShotBtn clicked");
|
||||||
|
screenShotBtn.ResetState();
|
||||||
|
ScreenShot();
|
||||||
|
gprintf("...It's easy, mmmmmmKay");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (page==1) {
|
if (page==1) {
|
||||||
gameinfoWindow.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 100);
|
gameinfoWindow.SetEffect(EFFECT_SLIDE_LEFT | EFFECT_SLIDE_OUT, 100);
|
||||||
|
Loading…
Reference in New Issue
Block a user