X-Git-Url: https://git.cworth.org/git?a=blobdiff_plain;f=gui%2Fmainwindow.h;h=78267efca4c9f5cd98bb4eb0b48a5bc980ae3ceb;hb=1af9409e5ade504829e8d3260921e5905cbf8f11;hp=3bd9edb3640c947f2880a118d577ddb6c5f9ac45;hpb=10bd424f3acbbf4275c160302898018ce795d17d;p=apitrace diff --git a/gui/mainwindow.h b/gui/mainwindow.h index 3bd9edb..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 @@ -43,18 +47,23 @@ public slots: private slots: void callItemSelected(const QModelIndex &index); + void callItemActivated(const QModelIndex &index); 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(); void loadProgess(int percent); void finishedLoadingTrace(); void lookupState(); + void showThumbnails(); + void trim(); void showSettings(); void openHelp(const QUrl &url); void showSurfacesMenu(const QPoint &pos); @@ -64,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); @@ -87,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 @@ -100,6 +113,8 @@ private: ApiTraceFrame *currentFrame() const; ApiTraceCall *currentCall() const; +protected: + virtual void closeEvent(QCloseEvent * event); private: Ui_MainWindow m_ui; @@ -118,7 +133,7 @@ private: ApiTraceEvent *m_stateEvent; - QList m_thumbnails; + ApiTraceEvent *m_trimEvent; Retracer *m_retracer; @@ -129,9 +144,13 @@ private: TraceProcess *m_traceProcess; + TrimProcess *m_trimProcess; + ArgumentsEditor *m_argsEditor; ApiTraceEvent *m_nonDefaultsLookupEvent; + + ProfileDialog* m_profileDialog; };