mirror of
https://github.com/ocornut/imgui.git
synced 2024-12-05 06:57:13 +08:00
Backends: OSX: fixed ImGui_ImplOSX_GetWindowSize and ConvertNSRect. (#6009)
This commit is contained in:
parent
90de839445
commit
16aaf60697
@ -816,7 +816,7 @@ struct ImGuiViewportDataOSX
|
||||
|
||||
static void ConvertNSRect(NSScreen* screen, NSRect* r)
|
||||
{
|
||||
r->origin.y = CGDisplayPixelsHigh(kCGDirectMainDisplay) - r->origin.y - r->size.height;
|
||||
r->origin.y = screen.frame.size.height - r->origin.y - r->size.height;
|
||||
}
|
||||
|
||||
static void ImGui_ImplOSX_CreateWindow(ImGuiViewport* viewport)
|
||||
@ -924,7 +924,7 @@ static ImVec2 ImGui_ImplOSX_GetWindowSize(ImGuiViewport* viewport)
|
||||
|
||||
NSWindow* window = data->Window;
|
||||
NSSize size = window.contentLayoutRect.size;
|
||||
return ImVec2(size.width, size.width);
|
||||
return ImVec2(size.width, size.height);
|
||||
}
|
||||
|
||||
static void ImGui_ImplOSX_SetWindowSize(ImGuiViewport* viewport, ImVec2 size)
|
||||
|
@ -144,6 +144,11 @@ Other changes:
|
||||
- Misc: fixed compile-time detection of SSE features on MSVC 32-bits builds. (#5943) [@TheMostDiligent]
|
||||
- Backends: Allegro5: restoring using al_draw_indexed_prim() when Allegro version is >= 5.2.5. (#5937) [@Espyo]
|
||||
|
||||
Docking+Viewports Branch:
|
||||
|
||||
- Backends: OSX: fixed typo in ImGui_ImplOSX_GetWindowSize that would cause issues when resiing
|
||||
from OS decorations, if they are enabled on secondary viewports. (#6009) [@sivu]
|
||||
|
||||
|
||||
-----------------------------------------------------------------------
|
||||
VERSION 1.89.1 (Released 2022-11-24)
|
||||
|
Loading…
Reference in New Issue
Block a user