MCPcopy Create free account
hub / github.com/XorTroll/Goldleaf / optsIcon_DefaultKey

Method optsIcon_DefaultKey

Goldleaf/source/ui/ui_AccountLayout.cpp:92–98  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

90 }
91
92 void AccountLayout::optsIcon_DefaultKey() {
93 const auto base_icon_path = GLEAF_PATH_USER_DATA_DIR "/" + util::FormatHex128(acc::GetSelectedUser()) + ".jpg";
94 auto sd_exp = fs::GetSdCardExplorer();
95 const auto icon_path = sd_exp->MakeAbsolute(base_icon_path);
96 const auto p_icon_path = sd_exp->MakeAbsolutePresentable(base_icon_path);
97 g_MainApplication->DisplayDialog(cfg::Strings.GetString(216), cfg::Strings.GetString(217) + "\n\'" + p_icon_path + "\'", { cfg::Strings.GetString(234) }, false, pu::sdl2::TextureHandle::New(pu::ui::render::LoadImageFromFile(icon_path)));
98 }
99
100 void AccountLayout::optsDelete_DefaultKey() {
101 const auto option = g_MainApplication->DisplayDialog(cfg::Strings.GetString(216), cfg::Strings.GetString(218), { cfg::Strings.GetString(111), cfg::Strings.GetString(18) }, true);

Callers

nothing calls this directly

Calls 6

GetSelectedUserFunction · 0.85
GetSdCardExplorerFunction · 0.85
MakeAbsoluteMethod · 0.80
DisplayDialogMethod · 0.80
FormatHex128Function · 0.50

Tested by

no test coverage detected