From 2d4fd783bd7f808dc9c718092f45b8b25c0de327 Mon Sep 17 00:00:00 2001 From: Zach Pomerantz Date: Tue, 10 May 2016 16:09:04 -0700 Subject: [PATCH] Rename Paint/Idle events to Present --- interface/src/Application.cpp | 4 ++-- interface/src/Application.h | 4 ++-- libraries/plugins/src/plugins/DisplayPlugin.cpp | 2 +- libraries/plugins/src/plugins/DisplayPlugin.h | 2 +- 4 files changed, 6 insertions(+), 6 deletions(-) diff --git a/interface/src/Application.cpp b/interface/src/Application.cpp index 4ae206795d..3ba362e56d 100644 --- a/interface/src/Application.cpp +++ b/interface/src/Application.cpp @@ -1786,9 +1786,9 @@ bool Application::event(QEvent* event) { return false; } - if ((int)event->type() == (int)Idle) { + if ((int)event->type() == (int)Present) { idle(); - removePostedEvents(this, Idle); // clear pending idles so we don't clog the pipes + removePostedEvents(this, Present); // clear pending presents so we don't clog the pipes return true; } else if ((int)event->type() == (int)Paint) { paintGL(); diff --git a/interface/src/Application.h b/interface/src/Application.h index e13dffbcf1..0d88352b2f 100644 --- a/interface/src/Application.h +++ b/interface/src/Application.h @@ -95,8 +95,8 @@ class Application : public QApplication, public AbstractViewStateInterface, publ public: enum Event { - Idle = DisplayPlugin::Paint, - Paint = Idle + 1, + Present = DisplayPlugin::Present, + Paint = Present + 1, Lambda = Paint + 1 }; diff --git a/libraries/plugins/src/plugins/DisplayPlugin.cpp b/libraries/plugins/src/plugins/DisplayPlugin.cpp index 430da00061..a217041f4e 100644 --- a/libraries/plugins/src/plugins/DisplayPlugin.cpp +++ b/libraries/plugins/src/plugins/DisplayPlugin.cpp @@ -41,5 +41,5 @@ void DisplayPlugin::incrementPresentCount() { ++_presentedFrameIndex; // Alert the app that it needs to paint a new presentation frame - qApp->postEvent(qApp, new QEvent(static_cast(Paint)), Qt::HighEventPriority); + qApp->postEvent(qApp, new QEvent(static_cast(Present)), Qt::HighEventPriority); } diff --git a/libraries/plugins/src/plugins/DisplayPlugin.h b/libraries/plugins/src/plugins/DisplayPlugin.h index 3a668f27d7..41f380aa86 100644 --- a/libraries/plugins/src/plugins/DisplayPlugin.h +++ b/libraries/plugins/src/plugins/DisplayPlugin.h @@ -61,7 +61,7 @@ class DisplayPlugin : public Plugin { using Parent = Plugin; public: enum Event { - Paint = QEvent::User + 1 + Present = QEvent::User + 1 }; bool activate() override;