Showing the changes to libraries/script-engine/src/RecordingScriptingInterface.cpp (1 of 45 files). Show all
Unified · Split
| @@ -14,6 +14,7 @@ · 13 unmodified lines | ||
| 14 | 14 | #include <QtScript/QScriptValue> |
| 15 | 15 | #include <QtWidgets/QFileDialog> |
| 16 | 16 | |
| 17 | +#include <shared/QtHelpers.h> | |
| 17 | 18 | #include <AssetClient.h> |
| 18 | 19 | #include <AssetUpload.h> |
| 19 | 20 | #include <BuildInfo.h> |
| @@ -98,7 +99,7 @@ void RecordingScriptingInterface::loadRecording(const QString& url, QScriptValue · 78 unmodified lines | ||
| 98 | 99 | |
| 99 | 100 | void RecordingScriptingInterface::startPlaying() { |
| 100 | 101 | if (QThread::currentThread() != thread()) { |
| 101 | − QMetaObject::invokeMethod(this, "startPlaying", Qt::BlockingQueuedConnection); | |
| 102 | + hifi::qt::blockingInvokeMethod(this, "startPlaying"); | |
| 102 | 103 | return; |
| 103 | 104 | } |
| 104 | 105 | |
| @@ -115,7 +116,7 @@ void RecordingScriptingInterface::setPlayerAudioOffset(float audioOffset) { · 10 unmodified lines | ||
| 115 | 116 | |
| 116 | 117 | void RecordingScriptingInterface::setPlayerTime(float time) { |
| 117 | 118 | if (QThread::currentThread() != thread()) { |
| 118 | − QMetaObject::invokeMethod(this, "setPlayerTime", Qt::BlockingQueuedConnection, Q_ARG(float, time)); | |
| 119 | + hifi::qt::blockingInvokeMethod(this, "setPlayerTime", Q_ARG(float, time)); | |
| 119 | 120 | return; |
| 120 | 121 | } |
| 121 | 122 | _player->seek(time); |
| @@ -147,7 +148,7 @@ void RecordingScriptingInterface::setPlayerUseSkeletonModel(bool useSkeletonMode · 25 unmodified lines | ||
| 147 | 148 | |
| 148 | 149 | void RecordingScriptingInterface::pausePlayer() { |
| 149 | 150 | if (QThread::currentThread() != thread()) { |
| 150 | − QMetaObject::invokeMethod(this, "pausePlayer", Qt::BlockingQueuedConnection); | |
| 151 | + hifi::qt::blockingInvokeMethod(this, "pausePlayer"); | |
| 151 | 152 | return; |
| 152 | 153 | } |
| 153 | 154 | _player->pause(); |
| @@ -155,7 +156,7 @@ void RecordingScriptingInterface::pausePlayer() { · 1 unmodified line | ||
| 155 | 156 | |
| 156 | 157 | void RecordingScriptingInterface::stopPlaying() { |
| 157 | 158 | if (QThread::currentThread() != thread()) { |
| 158 | − QMetaObject::invokeMethod(this, "stopPlaying", Qt::BlockingQueuedConnection); | |
| 159 | + hifi::qt::blockingInvokeMethod(this, "stopPlaying"); | |
| 159 | 160 | return; |
| 160 | 161 | } |
| 161 | 162 | _player->stop(); |
| @@ -176,7 +177,7 @@ void RecordingScriptingInterface::startRecording() { · 14 unmodified lines | ||
| 176 | 177 | } |
| 177 | 178 | |
| 178 | 179 | if (QThread::currentThread() != thread()) { |
| 179 | − QMetaObject::invokeMethod(this, "startRecording", Qt::BlockingQueuedConnection); | |
| 180 | + hifi::qt::blockingInvokeMethod(this, "startRecording"); | |
| 180 | 181 | return; |
| 181 | 182 | } |
| 182 | 183 | |
| @@ -199,7 +200,7 @@ QString RecordingScriptingInterface::getDefaultRecordingSaveDirectory() { · 16 unmodified lines | ||
| 199 | 200 | |
| 200 | 201 | void RecordingScriptingInterface::saveRecording(const QString& filename) { |
| 201 | 202 | if (QThread::currentThread() != thread()) { |
| 202 | − QMetaObject::invokeMethod(this, "saveRecording", Qt::BlockingQueuedConnection, | |
| 203 | + hifi::qt::blockingInvokeMethod(this, "saveRecording", | |
| 203 | 204 | Q_ARG(QString, filename)); |
| 204 | 205 | return; |
| 205 | 206 | } |
| @@ -220,7 +221,7 @@ bool RecordingScriptingInterface::saveRecordingToAsset(QScriptValue getClipAtpUr · 14 unmodified lines | ||
| 220 | 221 | |
| 221 | 222 | if (QThread::currentThread() != thread()) { |
| 222 | 223 | bool result; |
| 223 | − QMetaObject::invokeMethod(this, "saveRecordingToAsset", Qt::BlockingQueuedConnection, | |
| 224 | + hifi::qt::blockingInvokeMethod(this, "saveRecordingToAsset", | |
| 224 | 225 | Q_RETURN_ARG(bool, result), |
| 225 | 226 | Q_ARG(QScriptValue, getClipAtpUrl)); |
| 226 | 227 | return result; |
| @@ -257,7 +258,7 @@ bool RecordingScriptingInterface::saveRecordingToAsset(QScriptValue getClipAtpUr · 30 unmodified lines | ||
| 257 | 258 | |
| 258 | 259 | void RecordingScriptingInterface::loadLastRecording() { |
| 259 | 260 | if (QThread::currentThread() != thread()) { |
| 260 | − QMetaObject::invokeMethod(this, "loadLastRecording", Qt::BlockingQueuedConnection); | |
| 261 | + hifi::qt::blockingInvokeMethod(this, "loadLastRecording"); | |
| 261 | 262 | return; |
| 262 | 263 | } |
| 263 | 264 | |