macOS: Explicitly mark NSView as needing display when unhiding it
AppKit doesn't do this automatically for us, and since we may have decided to not draw anything when the view was not exposed, we need to inform clients that its time to draw something now. Pick-to: 6.5 Change-Id: Ib2dd969632898ba5640d6848356acd1b97da652d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Doris Verria <doris.verria@qt.io> (cherry picked from commit ea0b99c0064806397081a6f19a2af56abea726de) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
74b93a3410
commit
b80262055c
@ -346,6 +346,10 @@ void QCocoaWindow::setVisible(bool visible)
|
||||
// Make the NSView visible first, before showing the NSWindow (in case of top level windows)
|
||||
m_view.hidden = NO;
|
||||
|
||||
// Explicitly mark the view as needing display, as we may
|
||||
// not have drawn anything to the view when it was hidden.
|
||||
[m_view setNeedsDisplay:YES];
|
||||
|
||||
if (isContentView()) {
|
||||
QWindowSystemInterface::flushWindowSystemEvents(QEventLoop::ExcludeUserInputEvents);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user