mirror of
https://github.com/wiidev/usbloadergx.git
synced 2024-12-18 16:01:58 +01:00
*Fixed issue 373, issue 383 and issue 385
*Hopefully fixed issue 380
This commit is contained in:
parent
a5ec5c9d63
commit
b3d51aa75f
@ -76,7 +76,7 @@ snprintf(LANGUAGE.Display, sizeof(LANGUAGE.Display), "Display");
|
||||
snprintf(LANGUAGE.Doyouwanttoformat, sizeof(LANGUAGE.Doyouwanttoformat), "Do you want to format:");
|
||||
snprintf(LANGUAGE.Doyoureallywanttodelete, sizeof(LANGUAGE.Doyoureallywanttodelete), "Do you really want to delete:");
|
||||
snprintf(LANGUAGE.Doyouwanttoretryfor30secs, sizeof(LANGUAGE.Doyouwanttoretryfor30secs), "Do you want to retry for 30 secs?");
|
||||
snprintf(LANGUAGE.Doyouwanttoupdate, sizeof(LANGUAGE.Doyouwanttoupdate), "Do you want to update");
|
||||
snprintf(LANGUAGE.Doyouwanttoupdate, sizeof(LANGUAGE.Doyouwanttoupdate), "How do you want to update?");
|
||||
snprintf(LANGUAGE.Downloadingfile, sizeof(LANGUAGE.Downloadingfile), "Downloading file");
|
||||
snprintf(LANGUAGE.DownloadBoxartimage, sizeof(LANGUAGE.DownloadBoxartimage), "Download Boxart image?");
|
||||
snprintf(LANGUAGE.Downloadfinished, sizeof(LANGUAGE.Downloadfinished), "Download finished");
|
||||
@ -212,6 +212,8 @@ snprintf(LANGUAGE.Uninstall, sizeof(LANGUAGE.Uninstall), "Uninstall");
|
||||
snprintf(LANGUAGE.Updatepath, sizeof(LANGUAGE.Updatepath), "Updatepath");
|
||||
snprintf(LANGUAGE.Updatepathchanged, sizeof(LANGUAGE.Updatepathchanged), "Updatepath changed.");
|
||||
snprintf(LANGUAGE.Updatefailed, sizeof(LANGUAGE.Updatefailed), "Update failed");
|
||||
snprintf(LANGUAGE.Updatedol, sizeof(LANGUAGE.Updatedol), "Update DOL");
|
||||
snprintf(LANGUAGE.Updateall, sizeof(LANGUAGE.Updateall), "Update All");
|
||||
snprintf(LANGUAGE.USBLoaderisprotected, sizeof(LANGUAGE.USBLoaderisprotected), "USB Loader GX is protected");
|
||||
snprintf(LANGUAGE.USBDevicenotfound, sizeof(LANGUAGE.USBDevicenotfound), "USB Device not found");
|
||||
snprintf(LANGUAGE.VideoMode, sizeof(LANGUAGE.VideoMode), "Video Mode");
|
||||
@ -958,6 +960,14 @@ void language_set(char *name, char *val)
|
||||
strcopy(LANGUAGE.Updatefailed, val, sizeof(LANGUAGE.Updatefailed));
|
||||
return;
|
||||
}
|
||||
if (strcmp(name, "Updatedol") == 0) {
|
||||
strcopy(LANGUAGE.Updatedol, val, sizeof(LANGUAGE.Updatedol));
|
||||
return;
|
||||
}
|
||||
if (strcmp(name, "Updateall") == 0) {
|
||||
strcopy(LANGUAGE.Updateall, val, sizeof(LANGUAGE.Updateall));
|
||||
return;
|
||||
}
|
||||
if (strcmp(name, "USBLoaderisprotected") == 0) {
|
||||
strcopy(LANGUAGE.USBLoaderisprotected, val, sizeof(LANGUAGE.USBLoaderisprotected));
|
||||
return;
|
||||
|
@ -198,6 +198,8 @@ struct LANGUAGE
|
||||
char Updatepath[50];
|
||||
char Updatepathchanged[50];
|
||||
char Updatefailed[40];
|
||||
char Updatedol[40];
|
||||
char Updateall[40];
|
||||
char VideoMode[50];
|
||||
char VIDTVPatch[50];
|
||||
char Volume[50];
|
||||
|
@ -215,7 +215,7 @@ static void WindowCredits(void * ptr)
|
||||
snprintf(SvnRev, 10, "Rev%s", SVN_REV);
|
||||
|
||||
txt[i] = new GuiText(SvnRev, 18, (GXColor){255, 255, 255, 255});
|
||||
txt[i]->SetAlignment(ALIGN_RIGHT, ALIGN_TOP); txt[i]->SetPosition(0,y); i++; y+=34;
|
||||
txt[i]->SetAlignment(ALIGN_RIGHT, ALIGN_TOP); txt[i]->SetPosition(-30,y); i++; y+=34;
|
||||
|
||||
txt[i] = new GuiText("USB Loader GX", 24, (GXColor){255, 255, 255, 255});
|
||||
txt[i]->SetAlignment(ALIGN_CENTRE, ALIGN_TOP); txt[i]->SetPosition(0,y); i++; y+=26;
|
||||
@ -2356,8 +2356,8 @@ ProgressUpdateWindow()
|
||||
|
||||
if(revnumber > currentrev) {
|
||||
sprintf(msg, "Rev%i %s.", revnumber, LANGUAGE.available);
|
||||
int choice = WindowPrompt(msg, LANGUAGE.Doyouwanttoupdate, LANGUAGE.Yes, LANGUAGE.No, 0, 0);
|
||||
if(choice == 1) {
|
||||
int choice = WindowPrompt(msg, LANGUAGE.Doyouwanttoupdate, LANGUAGE.Updatedol, LANGUAGE.Updateall, LANGUAGE.No, 0);
|
||||
if(choice == 1 || choice == 2) {
|
||||
titleTxt.SetTextf("%s USB Loader GX", LANGUAGE.updating);
|
||||
msgTxt.SetPosition(0,100);
|
||||
promptWindow.Append(&progressbarEmptyImg);
|
||||
@ -2409,6 +2409,7 @@ ProgressUpdateWindow()
|
||||
//rename new to old
|
||||
rename(dolpath, dolpathsuccess);
|
||||
|
||||
if(choice == 2) {
|
||||
//get the icon.png and the meta.xml
|
||||
char xmliconpath[150];
|
||||
file = downloadfile("http://www.techjawa.com/usbloadergx/meta.file");
|
||||
@ -2428,6 +2429,7 @@ ProgressUpdateWindow()
|
||||
free(file.data);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
failed = -1;
|
||||
}
|
||||
@ -2446,6 +2448,7 @@ ProgressUpdateWindow()
|
||||
|
||||
if(!failed && ret >= 0) {
|
||||
WindowPrompt(LANGUAGE.Successfullyupdated , LANGUAGE.Restarting, LANGUAGE.ok, 0, 0, 0);
|
||||
ExitApp();
|
||||
if (*((u32*) 0x80001800)) exit(0);
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
}
|
||||
@ -3376,10 +3379,12 @@ static int MenuDiscList()
|
||||
|
||||
if(choice == 3)
|
||||
{
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0); // Back to System Menu
|
||||
}
|
||||
else if (choice == 2)
|
||||
{
|
||||
ExitApp();
|
||||
if (*((u32*) 0x80001800)) exit(0);
|
||||
// Channel Version
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
@ -4232,6 +4237,7 @@ static int MenuFormat()
|
||||
choice = WindowPrompt (LANGUAGE.ReturntoWiiMenu,LANGUAGE.Areyousure,LANGUAGE.Yes,LANGUAGE.No,0,0);
|
||||
if(choice == 1)
|
||||
{
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
}
|
||||
}
|
||||
@ -5123,6 +5129,7 @@ static int MenuSettings()
|
||||
mainWindow->Remove(&page2Btn);
|
||||
mainWindow->Remove(&tabBtn);
|
||||
mainWindow->Remove(&page3Btn);
|
||||
w.Remove(btnLogo);
|
||||
w.Remove(&backBtn);
|
||||
w.Remove(&lockBtn);
|
||||
w.Remove(&updateBtn);
|
||||
@ -5138,6 +5145,7 @@ static int MenuSettings()
|
||||
w.Append(&backBtn);
|
||||
w.Append(&lockBtn);
|
||||
w.Append(&updateBtn);
|
||||
w.Append(btnLogo);
|
||||
} else {
|
||||
WindowPrompt(LANGUAGE.NoSDcardinserted, LANGUAGE.InsertaSDCardtousethatoption, LANGUAGE.ok, 0,0,0);
|
||||
}
|
||||
@ -5228,10 +5236,12 @@ static int MenuSettings()
|
||||
|
||||
if(choice == 3)
|
||||
{
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0); // Back to System Menu
|
||||
}
|
||||
else if (choice == 2)
|
||||
{
|
||||
ExitApp();
|
||||
if (*((u32*) 0x80001800)) exit(0);
|
||||
// Channel Version
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
@ -5585,6 +5595,7 @@ static int MenuCheck()
|
||||
} else if(ret2 == 2) {
|
||||
Settings.cios = ios222;
|
||||
} else {
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
}
|
||||
//shutdown WiiMote before IOS Reload
|
||||
@ -5604,6 +5615,7 @@ static int MenuCheck()
|
||||
SDCard_Init();
|
||||
WindowPrompt (LANGUAGE.Error,LANGUAGE.USBDevicenotfound, LANGUAGE.ok, 0,0,0);
|
||||
SDCard_deInit();
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
} else {
|
||||
PAD_Init();
|
||||
@ -5618,6 +5630,7 @@ static int MenuCheck()
|
||||
SDCard_Init();
|
||||
WindowPrompt (LANGUAGE.Error,LANGUAGE.CouldnotinitializeDIPmodule,LANGUAGE.ok, 0,0,0);
|
||||
SDCard_deInit();
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
}
|
||||
|
||||
@ -5631,6 +5644,7 @@ static int MenuCheck()
|
||||
SDCard_deInit();
|
||||
if(choice == 0)
|
||||
{
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
|
||||
} else {
|
||||
@ -5641,6 +5655,7 @@ static int MenuCheck()
|
||||
SDCard_Init();
|
||||
WindowPrompt (LANGUAGE.Nopartitionsfound,0, LANGUAGE.Restart, 0,0,0);
|
||||
SDCard_deInit();
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
|
||||
}
|
||||
@ -6479,6 +6494,7 @@ int MainMenu(int menu)
|
||||
ret = Disc_WiiBoot(videoselected, cheat, vipatch);
|
||||
if (ret < 0) {
|
||||
printf("%s (ret = %d)\n",LANGUAGE.Error, ret);
|
||||
ExitApp();
|
||||
SYS_ResetSystem(SYS_RETURNTOMENU, 0, 0);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user