mirror of
https://github.com/WerWolv/ImHex.git
synced 2026-03-30 21:05:56 -05:00
fix: Make title bar backdrop stay where it is on resize
This commit is contained in:
@@ -41,9 +41,9 @@ namespace hex::plugin::builtin {
|
||||
if (!s_showTitlebarBackDrop)
|
||||
return;
|
||||
|
||||
const auto size = ImHexApi::System::getMainWindowSize();
|
||||
const auto pos = ImHexApi::System::getMainWindowPosition() - ImVec2(0, size.y / 2 - 20_scaled);
|
||||
ImGui::GetWindowDrawList()->AddShadowCircle(pos, size.x / 4, ImGui::GetColorU32(ImGuiCol_ButtonActive, 0.8), size.x / 4, ImVec2());
|
||||
const auto diameter = 800_scaled;
|
||||
const auto pos = ImHexApi::System::getMainWindowPosition() - ImVec2(0, diameter / 2);
|
||||
ImGui::GetWindowDrawList()->AddShadowCircle(pos, diameter / 2, ImGui::GetColorU32(ImGuiCol_ButtonActive, 0.8), diameter / 4, ImVec2());
|
||||
}
|
||||
|
||||
void createNestedMenu(std::span<const UnlocalizedString> menuItems, const char *icon, const Shortcut &shortcut, View *view, const ContentRegistry::Interface::impl::MenuCallback &callback, const ContentRegistry::Interface::impl::EnabledCallback &enabledCallback, const ContentRegistry::Interface::impl::SelectedCallback &selectedCallback) {
|
||||
|
||||
Reference in New Issue
Block a user