mirror of
https://github.com/DarkStore-3DS/DarkStore.git
synced 2026-07-05 16:49:10 +00:00
See desc for more.
- Added option, to have a 400x214px custom Image as the Background on a UniStore. - Added a header bar on almost all menus. - Added GUI Settings.
This commit is contained in:
@@ -53,7 +53,7 @@ void Overlays::ShowCredits() {
|
||||
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 214, 400, 1, BAR_OUTL_COLOR);
|
||||
Gui::DrawStringCentered(0, 217, 0.6f, TEXT_COLOR, Lang::get("CURRENT_VERSION") + std::string(V_STRING), 390);
|
||||
Gui::DrawStringCentered(0, 218, 0.6f, TEXT_COLOR, Lang::get("CURRENT_VERSION") + std::string(V_STRING), 390);
|
||||
|
||||
GFX::DrawBottom();
|
||||
GFX::DrawSprite(sprites_universal_core_idx, 0, 26);
|
||||
|
||||
@@ -42,7 +42,7 @@ static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
/*
|
||||
Select a Directory.
|
||||
*/
|
||||
std::string Overlays::SelectDir(const std::string &oldDir, const std::string &msg) {
|
||||
std::string Overlays::SelectDir(const std::string &oldDir, const std::string &msg, const std::unique_ptr<Store> &store) {
|
||||
std::string currentPath = oldDir;
|
||||
bool dirChanged = true;
|
||||
int selection = 0, sPos = 0;
|
||||
@@ -68,7 +68,16 @@ std::string Overlays::SelectDir(const std::string &oldDir, const std::string &ms
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
if (store && config->usebg() && store->customBG()) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
}
|
||||
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, msg, 380);
|
||||
|
||||
Gui::Draw_Rect(0, 215, 400, 25, BAR_COLOR);
|
||||
@@ -142,7 +151,7 @@ std::string Overlays::SelectDir(const std::string &oldDir, const std::string &ms
|
||||
}
|
||||
|
||||
if (hidKeysDown() & KEY_TOUCH) {
|
||||
for (int i = 0; i < 6; i++) {
|
||||
for (int i = 0; i < 7; i++) {
|
||||
if (touching(touch, mainButtons[i])) {
|
||||
if (i + sPos < (int)dirContents.size()) {
|
||||
if (dirContents[i + sPos].isDirectory) {
|
||||
|
||||
@@ -51,7 +51,7 @@ static const std::vector<Structs::ButtonPos> mainButtons = {
|
||||
|
||||
Can be skipped with `B`.
|
||||
*/
|
||||
void Overlays::SelectLanguage() {
|
||||
void Overlays::SelectLanguage(const std::unique_ptr<Store> &store) {
|
||||
bool doOut = false;
|
||||
int selection = 0, sPos = 0;
|
||||
|
||||
@@ -61,7 +61,16 @@ void Overlays::SelectLanguage() {
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
if (store && config->usebg() && store->customBG()) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
}
|
||||
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, Lang::get("SELECT_LANG"));
|
||||
GFX::DrawBottom();
|
||||
|
||||
|
||||
@@ -104,7 +104,7 @@ static bool DownloadStore(bool Cam = true) {
|
||||
bool doSheet = false;
|
||||
std::string file = "";
|
||||
|
||||
const std::string URL = Cam ? QR_Scanner::GetQRURL() : Input::setkbdString(150, Lang::get("ENTER_URL"));
|
||||
const std::string URL = Cam ? QR_Scanner::GetQRURL() : Input::setkbdString(150, Lang::get("ENTER_URL"), { });
|
||||
if (URL != "") doSheet = DownloadUniStore(URL, -1, file, true);
|
||||
|
||||
if (doSheet) {
|
||||
@@ -178,7 +178,16 @@ void Overlays::SelectStore(std::unique_ptr<Store> &store, std::vector<std::uniqu
|
||||
C2D_TargetClear(Top, TRANSPARENT);
|
||||
C2D_TargetClear(Bottom, TRANSPARENT);
|
||||
|
||||
GFX::DrawTop();
|
||||
if (store && config->usebg() && store->customBG()) {
|
||||
Gui::ScreenDraw(Top);
|
||||
Gui::Draw_Rect(0, 0, 400, 25, BAR_COLOR);
|
||||
Gui::Draw_Rect(0, 25, 400, 1, BAR_OUTL_COLOR);
|
||||
C2D_DrawImageAt(store->GetStoreImg(), 0, 26, 0.5f, nullptr);
|
||||
|
||||
} else {
|
||||
GFX::DrawTop();
|
||||
}
|
||||
|
||||
Gui::DrawStringCentered(0, 1, 0.7f, TEXT_COLOR, Lang::get("SELECT_UNISTORE_2"), 390);
|
||||
|
||||
if (info.size() > 0) {
|
||||
|
||||
Reference in New Issue
Block a user