1
0
mirror of synced 2025-02-17 18:59:21 +01:00

fix: Bookmark "Open in View" tooltip not being displayed

Fixes #1749
This commit is contained in:
WerWolv 2024-06-09 14:56:40 +02:00
parent fb7d40ddbe
commit 0136877978
2 changed files with 3 additions and 3 deletions

View File

@ -574,7 +574,7 @@ namespace ImGuiExt {
if (IsItemHovered() && (currTime - lastMoveTime) >= 0.5 && hoveredID == lastHoveredID) { if (IsItemHovered() && (currTime - lastMoveTime) >= 0.5 && hoveredID == lastHoveredID) {
if (!std::string_view(text).empty()) { if (!std::string_view(text).empty()) {
const auto width = 300 * hex::ImHexApi::System::getGlobalScale(); const auto width = 300 * hex::ImHexApi::System::getGlobalScale();
ImGui::SetNextWindowSizeConstraints(ImVec2(width, 0), ImVec2(width, FLT_MAX)); ImGui::SetNextWindowSizeConstraints(ImVec2(0, 0), ImVec2(width, FLT_MAX));
if (BeginTooltip()) { if (BeginTooltip()) {
if (isSeparator) if (isSeparator)
SeparatorText(text); SeparatorText(text);

View File

@ -339,7 +339,7 @@ namespace hex::plugin::builtin {
// Draw jump to region button // Draw jump to region button
if (ImGuiExt::DimmedIconButton(ICON_VS_DEBUG_STEP_BACK, ImGui::GetStyleColorVec4(ImGuiCol_Text))) if (ImGuiExt::DimmedIconButton(ICON_VS_DEBUG_STEP_BACK, ImGui::GetStyleColorVec4(ImGuiCol_Text)))
ImHexApi::HexEditor::setSelection(region); ImHexApi::HexEditor::setSelection(region);
ImGuiExt::InfoTooltip("hex.builtin.view.bookmarks.tooltip.jump_to"_lang); ImGui::SetItemTooltip("%s", "hex.builtin.view.bookmarks.tooltip.jump_to"_lang.get().c_str());
ImGui::SameLine(0, 1_scaled); ImGui::SameLine(0, 1_scaled);
@ -358,7 +358,7 @@ namespace hex::plugin::builtin {
} }
}); });
} }
ImGuiExt::InfoTooltip("hex.builtin.view.bookmarks.tooltip.open_in_view"_lang); ImGui::SetItemTooltip("%s", "hex.builtin.view.bookmarks.tooltip.open_in_view"_lang.get().c_str());
} }
ImGui::SetCursorPos(nextPos); ImGui::SetCursorPos(nextPos);