diff mbox series

[13/24] kernel-shark: Add new methods to KsPlot::Mark

Message ID 20210201172358.175407-14-y.karadz@gmail.com (mailing list archive)
State Superseded
Headers show
Series Complete the KernelShark v2 transformation | expand

Commit Message

Yordan Karadzhov Feb. 1, 2021, 5:23 p.m. UTC
The new "get" methods are needed by the logic of the GUI.

Signed-off-by: Yordan Karadzhov (VMware) <y.karadz@gmail.com>
---
 src/KsPlotTools.hpp | 12 ++++++++++++
 1 file changed, 12 insertions(+)
diff mbox series

Patch

diff --git a/src/KsPlotTools.hpp b/src/KsPlotTools.hpp
index a9a5ba8..1725926 100644
--- a/src/KsPlotTools.hpp
+++ b/src/KsPlotTools.hpp
@@ -395,12 +395,24 @@  public:
 
 	void setY(int yA, int yB);
 
+	/** Get the Y coordinate of the Mark's CPU point. */
+	int cpuY() const {return _cpu.y();}
+
 	void setCPUY(int yCPU);
 
+	/** Is the CPU point visible. */
+	bool cpuIsVisible() const {return _cpu._visible;}
+
 	void setCPUVisible(bool v);
 
+	/** Get the Y coordinate of the Mark's Task point. */
+	int taskY() const {return _task.y();}
+
 	void setTaskY(int yTask);
 
+	/** Is the Task point visible. */
+	bool taskIsVisible() const {return _task._visible;}
+
 	void setTaskVisible(bool v);
 
 	/** If True, the Mark will be plotted as a dashed line. */