| 244 | } |
| 245 | |
| 246 | void Viewport::paintCursors(QPainter &p) |
| 247 | { |
| 248 | const QRect xrect = _view.get_view_rect(); |
| 249 | auto &cursor_list = _view.get_cursorList(); |
| 250 | |
| 251 | if (_view.cursors_shown() && _type == TIME_VIEW) { |
| 252 | |
| 253 | for (auto cursor : cursor_list) { |
| 254 | const int64_t cursorX = _view.index2pixel(cursor->index()); |
| 255 | if (xrect.contains(_view.hover_point().x(), _view.hover_point().y()) && |
| 256 | qAbs(cursorX - _view.hover_point().x()) <= HitCursorMargin) |
| 257 | cursor->paint(p, xrect, 1, _view.session().is_stopped_status()); |
| 258 | else |
| 259 | cursor->paint(p, xrect, 0, _view.session().is_stopped_status()); |
| 260 | } |
| 261 | } |
| 262 | } |
| 263 | |
| 264 | void Viewport::paintSignals(QPainter &p, QColor fore, QColor back) |
| 265 | { |
nothing calls this directly
no test coverage detected