lang: Added German translation, improved language handling

This commit is contained in:
WerWolv
2021-03-03 22:26:17 +01:00
parent 188723e888
commit 4a908a314f
23 changed files with 539 additions and 54 deletions

View File

@@ -7,7 +7,7 @@
namespace hex {
ViewBookmarks::ViewBookmarks() : View("hex.view.bookmarks.name"_lang) {
ViewBookmarks::ViewBookmarks() : View("hex.view.bookmarks.name") {
View::subscribeEvent(Events::AddBookmark, [](auto userData) {
auto bookmark = std::any_cast<ImHexApi::Bookmarks::Entry>(userData);
bookmark.comment.resize(0xF'FFFF);
@@ -44,7 +44,7 @@ namespace hex {
}
void ViewBookmarks::drawContent() {
if (ImGui::Begin("hex.view.bookmarks.name"_lang, &this->getWindowOpenState())) {
if (ImGui::Begin(View::toWindowName("hex.view.bookmarks.name").c_str(), &this->getWindowOpenState())) {
if (ImGui::BeginChild("##scrolling")) {
auto &bookmarks = ImHexApi::Bookmarks::getEntries();