diff --git a/extras/menus/xMenu/include/common.h b/extras/menus/xMenu/include/common.h index 48fb9928e..cc5560808 100644 --- a/extras/menus/xMenu/include/common.h +++ b/extras/menus/xMenu/include/common.h @@ -23,7 +23,7 @@ namespace common{ extern void deleteData(); extern Image* getBG(); extern Image* getNoIcon(); - extern void printText(float x, float y, const char *text); + extern void printText(float x, float y, const char *text, u32 color = WHITE_COLOR); extern void flip(); } diff --git a/extras/menus/xMenu/src/common.cpp b/extras/menus/xMenu/src/common.cpp index 9750ed5b5..1c199a300 100644 --- a/extras/menus/xMenu/src/common.cpp +++ b/extras/menus/xMenu/src/common.cpp @@ -38,8 +38,8 @@ Image* common::getNoIcon(){ return noicon; } -void common::printText(float x, float y, const char *text){ - printTextScreen(x, y, text, WHITE_COLOR); +void common::printText(float x, float y, const char *text, u32 color){ + printTextScreen(x, y, text, color); } void common::flip(){ diff --git a/extras/menus/xMenu/src/menu.cpp b/extras/menus/xMenu/src/menu.cpp index 04eccd197..aade553b7 100644 --- a/extras/menus/xMenu/src/menu.cpp +++ b/extras/menus/xMenu/src/menu.cpp @@ -12,14 +12,15 @@ ARKConfig* ark_config = &_ark_conf; static SEConfig _se_conf; SEConfig* se_config = &_se_conf; -static string ark_version; +string ark_version; -static std::string toggle = "LT - Menu"; +static std::string toggle = "Triangle -> Options Menu"; Menu::Menu(){ this->readEbootList("ms0:/PSP/GAME/"); this->readEbootList("ms0:/PSP/APPS/"); + this->readEbootList("ef0:/PSP/GAME/"); this->index = 0; this->start = 0; this->txt = NULL; @@ -130,9 +131,9 @@ void Menu::draw(){ // draw all image stuff for (int i=this->start; istart+3, (int)eboots.size()); i++){ - int offset = 8 + (90 * (i-this->start)); + int offset = (82 * (i-this->start)); blitAlphaImageToScreen(0, 0, eboots[i]->getIcon()->imageWidth, \ - eboots[i]->getIcon()->imageHeight, eboots[i]->getIcon(), 10, offset+8); + eboots[i]->getIcon()->imageHeight, eboots[i]->getIcon(), 10, offset); if (i == this->index){ static u32 alpha = 0; static u32 delta = 5; @@ -149,18 +150,15 @@ void Menu::draw(){ // draw all text stuff for (int i=this->start; istart+3, (int)eboots.size()); i++){ - int offset = 8 + (90 * (i-this->start)); + int offset = (82 * (i-this->start)); if (i == this->index) this->txt->draw(offset); else common::printText(200, offset+30, eboots[i]->getName().c_str()); } - // draw ARK version and info - common::printText(2, 2, ark_version.c_str()); - // draw help text - common::printText(RIGHT-toggle.length()-10, BOTTOM, toggle.c_str()); + common::printText(475-8*toggle.length(), 2, toggle.c_str()); } diff --git a/extras/menus/xMenu/src/submenu.cpp b/extras/menus/xMenu/src/submenu.cpp index 549dba4b4..abf3e3497 100644 --- a/extras/menus/xMenu/src/submenu.cpp +++ b/extras/menus/xMenu/src/submenu.cpp @@ -31,6 +31,8 @@ static t_conf config; extern SEConfig* se_config; extern ARKConfig* ark_config; +extern string ark_version; + /* static char* OPTIONS[] = { (char*)"Disabled", @@ -91,6 +93,9 @@ void SubMenu::updateScreen(){ // menu window fillScreenRect(color, x, y, w, h); + // draw ARK version and info + common::printText(x + ((w-8*ark_version.size())/2), y+5, ark_version.c_str()); + // menu items int cur_x; int cur_y = y + (h-(10*n))/2; @@ -130,7 +135,7 @@ void SubMenu::run() { switch (index){ case 0: changeMsCacheSetting(); getItems(); break; case 1: rebootMenu(); break; - case 2: sceKernelExitGame(); break; + case 2: menu->fadeOut(); sceKernelExitGame(); break; } } else if (control.up()){