Updated theme, new translated strings, adjust left side split-screen x position. (#156)

* Add a new ThemeEntryID for split-screen and selected items and modify the theme.

* Adjust the position of the left side split-screen in the filebrowser menu.

* Add new strings and update Korean and Japanese translations.

* fix ja.json.

---------

Co-authored-by: ITotalJustice <47043333+ITotalJustice@users.noreply.github.com>
This commit is contained in:
Yorunokyujitsu
2025-06-01 02:02:53 +09:00
committed by GitHub
parent ec93dd5a7d
commit fd765aa8c8
24 changed files with 691 additions and 278 deletions

View File

@@ -561,7 +561,7 @@ void FsView::SetSide(ViewSide side) {
if (m_menu->IsSplitScreen()) {
if (m_side == ViewSide::Left) {
this->SetW(pos.w / 2 - pos.x / 2);
this->SetX(pos.x / 2);
this->SetX(pos.x / 2 + 20.f);
} else if (m_side == ViewSide::Right) {
this->SetW(pos.w / 2 - pos.x / 2);
this->SetX(pos.x / 2 + SCREEN_WIDTH / 2);
@@ -571,7 +571,7 @@ void FsView::SetSide(ViewSide side) {
v.w -= v.x / 2;
if (m_side == ViewSide::Left) {
v.x = v.x / 2;
v.x = v.x / 2 + 20.f;
} else if (m_side == ViewSide::Right) {
v.x = v.x / 2 + SCREEN_WIDTH / 2;
}
@@ -784,7 +784,7 @@ void FsView::UnzipFiles(fs::FsPath dir_path) {
App::PushErrorBox(rc, "Extract failed!"_i18n);
if (R_SUCCEEDED(rc)) {
App::Notify("Extract success!");
App::Notify("Extract success!"_i18n);
}
Scan(m_path);
@@ -915,7 +915,7 @@ void FsView::ZipFiles(fs::FsPath zip_out) {
App::PushErrorBox(rc, "Compress failed!"_i18n);
if (R_SUCCEEDED(rc)) {
App::Notify("Compress success!");
App::Notify("Compress success!"_i18n);
}
Scan(m_path);
@@ -1944,9 +1944,9 @@ void Menu::Draw(NVGcontext* vg, Theme* theme) {
view_right->Draw(vg, theme);
if (view == view_left) {
gfx::drawRect(vg, view_right->GetPos(), nvgRGBA(0, 0, 0, 180), 5);
gfx::drawRect(vg, view_right->GetPos(), theme->GetColour(ThemeEntryID_FOCUS), 5);
} else {
gfx::drawRect(vg, view_left->GetPos(), nvgRGBA(0, 0, 0, 180), 5);
gfx::drawRect(vg, view_left->GetPos(), theme->GetColour(ThemeEntryID_FOCUS), 5);
}
gfx::drawRect(vg, SCREEN_WIDTH/2, GetY(), 1, GetH(), theme->GetColour(ThemeEntryID_LINE));

View File

@@ -960,7 +960,7 @@ void Menu::Draw(NVGcontext* vg, Theme* theme) {
DrawEntry(vg, theme, m_layout.Get(), v, selected, e.image, e.GetName(), e.GetAuthor(), e.GetDisplayVersion());
if (e.selected) {
gfx::drawRect(vg, v, nvgRGBA(0, 0, 0, 180), 5);
gfx::drawRect(vg, v, theme->GetColour(ThemeEntryID_FOCUS), 5);
gfx::drawText(vg, x + w / 2, y + h / 2, 24.f, "\uE14B", nullptr, NVG_ALIGN_CENTER | NVG_ALIGN_MIDDLE, theme->GetColour(ThemeEntryID_TEXT_SELECTED));
}
});

View File

@@ -664,7 +664,7 @@ Result Menu::GcMount() {
auto source = std::make_shared<GcSource>(m_entries[m_entry_index], m_fs.get());
return yati::InstallFromCollections(pbox, source, source->m_collections, source->m_config);
}, [this](Result rc){
App::PushErrorBox(rc, "Gc install failed"_i18n);
App::PushErrorBox(rc, "Gc install failed!"_i18n);
if (R_SUCCEEDED(rc)) {
App::Notify("Gc install success!"_i18n);

View File

@@ -118,12 +118,12 @@ Menu::Menu(u32 flags) : MenuBase{"Irs"_i18n, flags} {
is_negative_image_used_str.emplace_back("Negative image"_i18n);
SidebarEntryArray::Items format_str;
format_str.emplace_back("320x240"_i18n);
format_str.emplace_back("160x120"_i18n);
format_str.emplace_back("80x60"_i18n);
format_str.emplace_back("320\u00D7240");
format_str.emplace_back("160\u00D7120");
format_str.emplace_back("80\u00D760");
if (hosversionAtLeast(4,0,0)) {
format_str.emplace_back("40x30"_i18n);
format_str.emplace_back("20x15"_i18n);
format_str.emplace_back("40\u00D730");
format_str.emplace_back("20\u00D715");
}
options->Add(std::make_shared<SidebarEntryArray>("Controller"_i18n, controller_str, [this](s64& index){

View File

@@ -127,7 +127,7 @@ void Menu::Update(Controller* controller, TouchInfo* touch) {
R_SUCCEED();
}, [this](Result rc){
App::PushErrorBox(rc, "USB install failed"_i18n);
App::PushErrorBox(rc, "USB install failed!"_i18n);
if (R_SUCCEEDED(rc)) {
App::Notify("Usb install success!"_i18n);