X-Git-Url: https://sigrok.org/gitweb/?p=pulseview.git;a=blobdiff_plain;f=pv%2Fview%2Fheader.h;h=e5cd241f6308bc79a2bc64f6a92b5382eb0993e8;hp=5693a8a0d4f1bfc0d5a16e294d4f6d745e3c1a7b;hb=e3374498baf2b2a05889cab370442ff326b390b3;hpb=a29bb7fb6aa3665c21da1e06a3d3c4ca80f4437f diff --git a/pv/view/header.h b/pv/view/header.h index 5693a8a0..e5cd241f 100644 --- a/pv/view/header.h +++ b/pv/view/header.h @@ -18,14 +18,17 @@ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ -#ifndef PV_VIEW_HEADER_H -#define PV_VIEW_HEADER_H +#ifndef PULSEVIEW_PV_VIEW_HEADER_H +#define PULSEVIEW_PV_VIEW_HEADER_H + +#include #include namespace pv { namespace view { +class Signal; class View; class Header : public QWidget @@ -35,21 +38,38 @@ class Header : public QWidget public: Header(View &parent); +private: + boost::shared_ptr get_mouse_over_signal( + const QPoint &pt); + private: void paintEvent(QPaintEvent *event); private: + void mousePressEvent(QMouseEvent * event); + void mouseMoveEvent(QMouseEvent *event); void leaveEvent(QEvent *event); + void contextMenuEvent(QContextMenuEvent *event); + +private slots: + void on_action_set_name_triggered(); + + void on_action_set_colour_triggered(); + private: View &_view; QPoint _mouse_point; + + boost::shared_ptr _context_signal; + QAction *_action_set_name; + QAction *_action_set_colour; }; } // namespace view } // namespace pv -#endif // PV_VIEW_HEADER_H +#endif // PULSEVIEW_PV_VIEW_HEADER_H