]> git.cworth.org Git - apitrace/blobdiff - gui/mainwindow.cpp
Make the details view a bit clearer.
[apitrace] / gui / mainwindow.cpp
index 28dd6281a92602bb8dd44521e8cc83b8ad789331..13ff529f9a01fb51f0de5635fd7b3fc78798b00f 100644 (file)
@@ -97,6 +97,10 @@ void MainWindow::callItemSelected(const QModelIndex &index)
 
     if (event && event->type() == ApiTraceEvent::Call) {
         ApiTraceCall *call = static_cast<ApiTraceCall*>(event);
+        m_ui.detailsDock->setWindowTitle(
+            tr("Details View. Frame %1, Call %2")
+            .arg(call->parentFrame() ? call->parentFrame()->number : 0)
+            .arg(call->index()));
         m_ui.detailsWebView->setHtml(call->toHtml());
         m_ui.detailsDock->show();
         if (call->hasBinaryData()) {
@@ -760,7 +764,7 @@ void MainWindow::initConnections()
     connect(m_ui.actionOptions, SIGNAL(triggered()),
             this, SLOT(showSettings()));
 
-    connect(m_ui.callView, SIGNAL(activated(const QModelIndex &)),
+    connect(m_ui.callView->selectionModel(), SIGNAL(currentChanged(const QModelIndex &, const QModelIndex &)),
             this, SLOT(callItemSelected(const QModelIndex &)));
     connect(m_ui.callView, SIGNAL(customContextMenuRequested(QPoint)),
             this, SLOT(customContextMenuRequested(QPoint)));
@@ -798,7 +802,7 @@ void MainWindow::initConnections()
     connect(m_ui.actionShowErrorsDock, SIGNAL(triggered(bool)),
             m_ui.errorsDock, SLOT(setVisible(bool)));
     connect(m_ui.errorsTreeWidget,
-            SIGNAL(currentItemChanged(QTreeWidgetItem*, QTreeWidgetItem*)),
+            SIGNAL(itemActivated(QTreeWidgetItem*, int)),
             this, SLOT(slotErrorSelected(QTreeWidgetItem*)));
 }