diff options
| author | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2017-08-30 19:22:40 +0200 |
|---|---|---|
| committer | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2017-09-01 02:42:36 +0000 |
| commit | 9507edddf239eb3130535a4d3e0d74b6502ed555 (patch) | |
| tree | 5a248c30bab305c7720c13eb62a41fd289e67cad /examples/opengl/threadedqopenglwidget/main.cpp | |
| parent | 28414f8e3a25f6ac913d14542866a7d1745b4df1 (diff) | |
macOS: Implement QWindow::requestUpdate() in terms of setNeedsDisplay
This is preferable to the timer-based default implementation of
QPlatformWindow, as it gives AppKit more control of when to schedule
the update, and makes sure the update is scheduled along with other
views in the normal display-cycle, reducing the number of push flushes
we do. QtWidgets still need to plumb the update() method to updateRequest
for that to have any real effect though.
In the future we may consider scheduling the update via a display link,
if the window surface is set up for GL, for example.
Ideally we'd also have a platform hook for the repaint() method, so that
we could funnel it through display and get synchronous painting with
AppKit still taking care of drawing and compositing child views.
Change-Id: I136a9afa087b922aad69086548c2aa190ce75b6b
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Diffstat (limited to 'examples/opengl/threadedqopenglwidget/main.cpp')
0 files changed, 0 insertions, 0 deletions
