X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;f=gui%2Fmainwindow.h;h=78267efca4c9f5cd98bb4eb0b48a5bc980ae3ceb;hb=1af9409e5ade504829e8d3260921e5905cbf8f11;hp=d65aa0e84749ea6df648d2b9f2a79ff628e0565a;hpb=97ac28e65ca20b5649552597afaeee1d67766f6a;p=apitrace diff --git a/gui/mainwindow.h b/gui/mainwindow.h index d65aa0e..78267ef 100644 --- a/gui/mainwindow.h +++ b/gui/mainwindow.h @@ -29,8 +29,12 @@ class Retracer; class SearchWidget; class ShadersSourceWidget; class TraceProcess; +class TrimProcess; +class ProfileDialog; class VertexDataInterpreter; +namespace trace { struct Profile; } + class MainWindow : public QMainWindow { Q_OBJECT @@ -47,9 +51,11 @@ private slots: void createTrace(); void openTrace(); void replayStart(); + void replayProfile(); void replayStop(); - void replayFinished(const QString &output); + void replayFinished(const QString &message); void replayStateFound(ApiTraceState *state); + void replayProfileFound(trace::Profile *state); void replayThumbnailsFound(const QList &thumbnails); void replayError(const QString &msg); void startedLoadingTrace(); @@ -57,6 +63,7 @@ private slots: void finishedLoadingTrace(); void lookupState(); void showThumbnails(); + void trim(); void showSettings(); void openHelp(const QUrl &url); void showSurfacesMenu(const QPoint &pos); @@ -66,6 +73,8 @@ private slots: void slotJumpTo(int callNum); void createdTrace(const QString &path); void traceError(const QString &msg); + void createdTrim(const QString &path); + void trimError(const QString &msg); void slotSearch(); void slotSearchNext(const QString &str, Qt::CaseSensitivity sensitivity); void slotSearchPrev(const QString &str, Qt::CaseSensitivity sensitivity); @@ -89,8 +98,10 @@ private slots: private: void initObjects(); void initConnections(); + void updateActionsState(bool traceLoaded, bool stopped = true); void newTraceFile(const QString &fileName); void replayTrace(bool dumpState, bool dumpThumbnails); + void trimEvent(); void fillStateForFrame(); /* there's a difference between selected frame/call and @@ -102,6 +113,8 @@ private: ApiTraceFrame *currentFrame() const; ApiTraceCall *currentCall() const; +protected: + virtual void closeEvent(QCloseEvent * event); private: Ui_MainWindow m_ui; @@ -120,6 +133,8 @@ private: ApiTraceEvent *m_stateEvent; + ApiTraceEvent *m_trimEvent; + Retracer *m_retracer; VertexDataInterpreter *m_vdataInterpreter; @@ -129,9 +144,13 @@ private: TraceProcess *m_traceProcess; + TrimProcess *m_trimProcess; + ArgumentsEditor *m_argsEditor; ApiTraceEvent *m_nonDefaultsLookupEvent; + + ProfileDialog* m_profileDialog; };