Fix wxOverlay when used with a TLW under wxMSW
Correctly position the overlay window over the TLW's client area.
This commit is contained in:
parent
c0140d12c9
commit
e79466f02b
1 changed files with 3 additions and 2 deletions
|
|
@ -99,8 +99,9 @@ void wxOverlayImpl::Init(wxDC* dc, int , int , int , int )
|
|||
|
||||
m_window = dc->GetWindow();
|
||||
|
||||
m_rect.SetSize(m_window->GetClientSize());
|
||||
m_rect.SetPosition(m_window->GetScreenPosition());
|
||||
// The rectangle must be in screen coordinates
|
||||
m_rect = m_window->GetClientRect();
|
||||
m_window->ClientToScreen(&m_rect.x, &m_rect.y);
|
||||
|
||||
m_bitmap.CreateWithLogicalSize(m_rect.GetSize(), m_window->GetDPIScaleFactor());
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue