mirror of
https://github.com/overte-org/overte.git
synced 2025-04-19 15:43:50 +02:00
handle minimize case
This commit is contained in:
parent
2a03cf1bab
commit
a5eb5d6515
2 changed files with 5 additions and 1 deletions
|
@ -19,6 +19,10 @@ GLCanvas::GLCanvas() : QGLWidget(QGLFormat(QGL::NoDepthBuffer)),
|
|||
{
|
||||
}
|
||||
|
||||
bool GLCanvas::isThrottleRendering() const {
|
||||
return _throttleRendering || Application::getInstance()->getWindow()->isMinimized();
|
||||
}
|
||||
|
||||
void GLCanvas::initializeGL() {
|
||||
Application::getInstance()->initializeGL();
|
||||
setAttribute(Qt::WA_AcceptTouchEvents);
|
||||
|
|
|
@ -17,7 +17,7 @@ class GLCanvas : public QGLWidget {
|
|||
Q_OBJECT
|
||||
public:
|
||||
GLCanvas();
|
||||
bool isThrottleRendering() const { return _throttleRendering; }
|
||||
bool isThrottleRendering() const;
|
||||
protected:
|
||||
|
||||
QTimer _frameTimer;
|
||||
|
|
Loading…
Reference in a new issue