mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-03-30 05:05:19 -05:00
impr: Upper case pattern data export options
This commit is contained in:
@@ -1057,11 +1057,16 @@ namespace hex::plugin::builtin::ui {
|
||||
ImGui::SetNextWindowPos(ImGui::GetWindowPos() + ImVec2(startPos.x, ImGui::GetCursorPosY()));
|
||||
if (ImGui::BeginPopup("ExportPatterns")) {
|
||||
for (const auto &formatter : this->m_formatters) {
|
||||
const auto &name = formatter->getName();
|
||||
const auto name = [&]{
|
||||
auto name = formatter->getName();
|
||||
std::transform(name.begin(), name.end(), name.begin(), [](char c){ return char(std::toupper(c)); });
|
||||
|
||||
return name;
|
||||
}();
|
||||
|
||||
const auto &extension = formatter->getFileExtension();
|
||||
|
||||
if (ImGui::MenuItem(name.c_str())) {
|
||||
|
||||
fs::openFileBrowser(fs::DialogMode::Save, { { name.c_str(), extension.c_str() } }, [&](const std::fs::path &path) {
|
||||
auto result = formatter->format(*runtime);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user