Showing the changes to interface/src/scripting/TestScriptingInterface.cpp (1 of 2 files). Show all
Unified · Split
| @@ -134,3 +134,9 @@ void TestScriptingInterface::startTraceEvent(QString name) { · 133 unmodified lines | ||
| 134 | 134 | void TestScriptingInterface::endTraceEvent(QString name) { |
| 135 | 135 | tracing::traceEvent(trace_test(), name, tracing::DurationEnd); |
| 136 | 136 | } |
| 137 | + | |
| 138 | +void TestScriptingInterface::profileRange(const QString& name, QScriptValue fn) { | |
| 139 | + PROFILE_RANGE(script, name); | |
| 140 | + fn.call(); | |
| 141 | +} | |
| 142 | + | |