*probably fix the bug that caused WiiTDB.zip to not update the full

gamelist.
*rearrange the Gui_Numpad so it doesnt look like a 4yr old made it :)
*remove redundant setPostion and setAlignment in Gui_Numpad
*remove old comments
This commit is contained in:
giantpune 2009-12-11 23:07:27 +00:00
parent f364aaa964
commit 8732c83f11
7 changed files with 22 additions and 31 deletions

View File

@ -2,8 +2,8 @@
<app version="1">
<name> USB Loader GX</name>
<coder>USB Loader GX Team</coder>
<version>1.0 r856</version>
<release_date>200912110630</release_date>
<version>1.0 r857</version>
<release_date>200912112033</release_date>
<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.
The interactive GUI is completely controllable with WiiMote, Classic Controller or GC Controller.

View File

@ -21,8 +21,8 @@
GuiNumpad::GuiNumpad(char * t, u32 max)
{
width = 540;
height = 400;
width = 400;
height = 370;
selectable = true;
focus = 0; // allow focus
alignmentHor = ALIGN_CENTRE;
@ -61,20 +61,16 @@ GuiNumpad::GuiNumpad(char * t, u32 max)
keyBackOverImg = new GuiImage(keyMediumOver);
keyBackText = new GuiText("Back", 20, (GXColor){0, 0, 0, 0xff});
keyBack = new GuiButton(keyBackImg, keyBackOverImg, 0, 3, 11*42+40, 0*42+120, trigA, keySoundOver, keySoundClick,1);
keyBack = new GuiButton(keyBackImg, keyBackOverImg, ALIGN_CENTRE, ALIGN_MIDDLE, 90, 80, trigA, keySoundOver, keySoundClick,1);
keyBack->SetLabel(keyBackText);
keyBack->SetTrigger(trigB);
keyBack->SetAlignment(ALIGN_CENTRE, ALIGN_MIDDLE);
keyBack->SetPosition(50, 80);
this->Append(keyBack);
keyClearImg = new GuiImage(keyMedium);
keyClearOverImg = new GuiImage(keyMediumOver);
keyClearText = new GuiText("Clear", 20, (GXColor){0, 0, 0, 0xff});
keyClear = new GuiButton(keyClearImg, keyClearOverImg, 0, 3, (10*42+40), 4*42+120, trigA, keySoundOver, keySoundClick,1);
keyClear = new GuiButton(keyClearImg, keyClearOverImg, ALIGN_CENTRE, ALIGN_MIDDLE, -90, 80, trigA, keySoundOver, keySoundClick,1);
keyClear->SetLabel(keyClearText);
keyClear->SetAlignment(ALIGN_CENTRE, ALIGN_MIDDLE);
keyClear->SetPosition(-130, 80);
this->Append(keyClear);
char txt[2] = { 0, 0 };
@ -82,20 +78,19 @@ GuiNumpad::GuiNumpad(char * t, u32 max)
{
if (keys[i] != '\0')
{
int col = i % 3;
int row = i / 3;
keyImg[i] = new GuiImage(keyMedium);
keyImgOver[i] = new GuiImage(keyMediumOver);
txt[0] = keys[i];
keyTxt[i] = new GuiText(txt, 20, (GXColor){0, 0, 0, 0xff});
keyTxt[i]->SetAlignment(ALIGN_CENTRE, ALIGN_BOTTOM);
keyTxt[i]->SetPosition(0, -10);
keyBtn[i]= new GuiButton(keyImg[i], keyImgOver[i], 0, 3, (42+21*i+40), i*42+120, trigA, keySoundOver, keySoundClick, 1);
keyBtn[i]= new GuiButton(keyImg[i], keyImgOver[i], ALIGN_CENTRE, ALIGN_MIDDLE, -90 + 90 * col, -70 + 50 * row, trigA, keySoundOver, keySoundClick, 1);
keyBtn[i]->SetLabel(keyTxt[i]);
keyBtn[i]->SetAlignment(ALIGN_CENTRE, ALIGN_MIDDLE);
int col = i % 3;
int row = i / 3;
keyBtn[i]->SetPosition(-130 + 90 * col, -70 + 50 * row);
this->Append(keyBtn[i]);
}
}

View File

@ -18,7 +18,7 @@
#include <wiiuse/wpad.h>
#include <debug.h>
extern "C" { //not sure if this is in the libogc that the buildbot is using so it isnt used yet
extern "C" {
extern void __exception_setreload(int t);
}
@ -179,21 +179,20 @@ void InitTextVideo () {
int
main(int argc, char *argv[]) {
setlocale(LC_ALL, "en.UTF-8");
geckoinit = InitGecko();
if (hbcStubAvailable()) {
if (hbcStubAvailable() || geckoinit) {
InitTextVideo();
}
// DEBUG_Init(GDBSTUB_DEVICE_USB, 1);
//_break();
// __exception_setreload(5);//auto reset is code dump nobody gives us codedump info anyways.
setlocale(LC_ALL, "en.UTF-8");
geckoinit = InitGecko();
if (geckoinit)InitTextVideo();
gprintf("\x1b[2J");
gprintf("------------------");
__exception_setreload(5);//auto reset code dump nobody gives us codedump info anyways.
gprintf("\n\n------------------");
gprintf("\nUSB Loader GX rev%s",GetRev());
gprintf("\nmain(%d", argc);
for (int i=0;i<argc;i++)

View File

@ -46,7 +46,7 @@ void rockout(int f = 0);
***************************************************************************/
int MenuDiscList() {
gprintf("\nMenuDiscList()");//testing out the gecko stuff. this shouldn't break anything, but we'll see
gprintf("\nMenuDiscList()");
int startat = 0;
int offset = 0;
int datag = 0;
@ -68,7 +68,6 @@ int MenuDiscList() {
f32 freespace, used, size = 0.0;
wchar_t searchChar;
//SCREENSAVER
//WPad_SetIdleTime(300); //needs the time in seconds
int check = 0; //to skip the first cycle when wiimote isn't completely connected
datagB=0;

View File

@ -77,7 +77,6 @@ int OnScreenNumpad(char * var, u32 maxlen) {
GuiSound btnSoundOver(button_over_pcm, button_over_pcm_size, Settings.sfxvolume);
// because destroy GuiSound must wait while sound playing is finished, we use a global sound
if(!btnClick2) btnClick2=new GuiSound(button_click2_pcm, button_click2_pcm_size,Settings.sfxvolume);
// GuiSound btnClick(button_click2_pcm, button_click2_pcm_size, Settings.sfxvolume);
char imgPath[100];
snprintf(imgPath, sizeof(imgPath), "%sbutton_dialogue_box.png", CFG.theme_path);
@ -94,7 +93,7 @@ int OnScreenNumpad(char * var, u32 maxlen) {
okBtnTxt.SetWidescreen(CFG.widescreen);
okBtnImg.SetWidescreen(CFG.widescreen);
}
GuiButton okBtn(&okBtnImg,&okBtnImg, 0, 4, 5, 15, &trigA, &btnSoundOver, btnClick2,1);
GuiButton okBtn(&okBtnImg,&okBtnImg, 0, 4, 5, -15, &trigA, &btnSoundOver, btnClick2,1);
okBtn.SetLabel(&okBtnTxt);
GuiText cancelBtnTxt(tr("Cancel"), 22, THEME.prompttext);
GuiImage cancelBtnImg(&btnOutline);
@ -102,7 +101,7 @@ int OnScreenNumpad(char * var, u32 maxlen) {
cancelBtnTxt.SetWidescreen(CFG.widescreen);
cancelBtnImg.SetWidescreen(CFG.widescreen);
}
GuiButton cancelBtn(&cancelBtnImg,&cancelBtnImg, 1, 4, -5, 15, &trigA, &btnSoundOver, btnClick2,1);
GuiButton cancelBtn(&cancelBtnImg,&cancelBtnImg, 1, 4, -5, -15, &trigA, &btnSoundOver, btnClick2,1);
cancelBtn.SetLabel(&cancelBtnTxt);
cancelBtn.SetTrigger(&trigB);

View File

@ -507,7 +507,7 @@ int __Menu_GetGameList(int t, wchar_t* gameFilter, discHdr ** PgameList, u32 *Pg
}
/* Other parental control method */
if (Settings.parentalcontrol == 0 && Settings.parental.is_unlocked == 0 && Settings.parental.enabled == 1)
if (Settings.parentalcontrol == 0 && Settings.parental.is_unlocked == 0 && Settings.parental.enabled == 1&& t==0)
{
// Check game rating in WiiTDB, since the default Wii parental control setting is enabled
s32 rating = GetRatingForGame((char *) header->id);

View File

@ -944,7 +944,6 @@ s32 getIOSrev(u64 req)
out:
gprintf(" = %d",ret);
return ret;
// TITLE_ID(0x00000001,0x000000de)
}