@@ -704,6 +704,22 @@ void KsTraceViewer::_searchItemsMapReduce(int column,
lamSearchReduce(_matchList, m.get());
}
+/**
+ * @brief Color (select) the given row in the table, by using the color of the
+ * Passive marker.
+ *
+ * @param row: The row index. If the Passive marker is selected and the input
+ * value is negative, the Passive marker will be deselected.
+ */
+void KsTraceViewer::passiveMarkerSelectRow(int row)
+{
+ DualMarkerState state = _mState->getState();
+
+ _view.setVisible(false);
+ _model.selectRow(!state, row);
+ _view.setVisible(true);
+}
+
/**
* Get the currently selected row. If no row is selected the function
* returns -1.
@@ -68,6 +68,8 @@ public:
void clearSelection();
+ void passiveMarkerSelectRow(int row);
+
int selectedRow();
void update(KsDataStore *data);
The same method can be used to deselect the Passive marker. Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=202327 Signed-off-by: Yordan Karadzhov <ykaradzhov@vmware.com> --- kernel-shark/src/KsTraceViewer.cpp | 16 ++++++++++++++++ kernel-shark/src/KsTraceViewer.hpp | 2 ++ 2 files changed, 18 insertions(+)