mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-02-07 04:10:08 +00:00
ScopedThreadDPIAwarenessSetter: Allow null constructor argument
This commit is contained in:
parent
c2ba24b4d0
commit
40368666db
1 changed files with 2 additions and 3 deletions
|
|
@ -501,7 +501,7 @@ private:
|
|||
|
||||
ScopedThreadDPIAwarenessSetter::ScopedThreadDPIAwarenessSetter (void* nativeWindow)
|
||||
{
|
||||
pimpl = std::make_unique<NativeImpl> ((HWND) nativeWindow);
|
||||
pimpl = nativeWindow != nullptr ? std::make_unique<NativeImpl> ((HWND) nativeWindow) : nullptr;
|
||||
}
|
||||
|
||||
ScopedThreadDPIAwarenessSetter::~ScopedThreadDPIAwarenessSetter() = default;
|
||||
|
|
@ -4315,6 +4315,7 @@ private:
|
|||
if (! hasMoved) flags |= SWP_NOMOVE;
|
||||
if (! hasResized) flags |= SWP_NOSIZE;
|
||||
|
||||
ScopedThreadDPIAwarenessSetter setter { hwnd };
|
||||
SetWindowPos (hwnd,
|
||||
nullptr,
|
||||
newBounds.getX(),
|
||||
|
|
@ -4324,9 +4325,7 @@ private:
|
|||
flags);
|
||||
|
||||
if (hasResized && isValidPeer (this))
|
||||
{
|
||||
repaintNowIfTransparent();
|
||||
}
|
||||
}
|
||||
|
||||
bool sendInputAttemptWhenModalMessage()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue