]> git.cworth.org Git - apitrace/blobdiff - gui/retracer.cpp
Reduce the size of ApiTraceCall, ApiTraceEvent and ApiTraceFrame
[apitrace] / gui / retracer.cpp
index 027cf5f40652d5da7d54696c84499c5715eb315f..500d859aa3f6d73011acc0bbaabd38a58ed19287 100644 (file)
@@ -9,7 +9,7 @@
 
 Retracer::Retracer(QObject *parent)
     : QThread(parent),
-      m_benchmarking(true),
+      m_benchmarking(false),
       m_doubleBuffered(true),
       m_captureState(false),
       m_captureCall(0)
@@ -98,8 +98,8 @@ void Retracer::run()
             this, SIGNAL(finished(const QString&)));
     connect(retrace, SIGNAL(error(const QString&)),
             this, SIGNAL(error(const QString&)));
-    connect(retrace, SIGNAL(foundState(const ApiTraceState&)),
-            this, SIGNAL(foundState(const ApiTraceState&)));
+    connect(retrace, SIGNAL(foundState(ApiTraceState*)),
+            this, SIGNAL(foundState(ApiTraceState*)));
     connect(retrace, SIGNAL(retraceErrors(const QList<RetraceError>&)),
             this, SIGNAL(retraceErrors(const QList<RetraceError>&)));
 
@@ -122,6 +122,8 @@ void RetraceProcess::start()
 
     if (m_doubleBuffered) {
         arguments << QLatin1String("-db");
+    } else {
+        arguments << QLatin1String("-sb");
     }
 
     if (m_captureState) {
@@ -153,7 +155,7 @@ void RetraceProcess::replayFinished()
     if (m_captureState) {
         bool ok = false;
         QVariantMap parsedJson = m_jsonParser->parse(output, &ok).toMap();
-        ApiTraceState state(parsedJson);
+        ApiTraceState *state = new ApiTraceState(parsedJson);
         emit foundState(state);
         msg = tr("State fetched.");
     } else {