profile: port context menu to QtQuick

This is for desktop only. We will have to think about what to
do on mobile. Either a "hamburger menu" or a "long click" seem
to be the most reasonable options.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2024-03-03 19:43:22 +01:00
parent b099e17042
commit c1c35ad48b
4 changed files with 84 additions and 15 deletions

View file

@ -307,6 +307,10 @@ void ChartView::setLayerVisibility(size_t z, bool visible)
void ChartView::mousePressEvent(QMouseEvent *event)
{
// Only left-button for drag events.
if (event->button() != Qt::LeftButton)
return event->ignore();
QPointF pos = event->localPos();
for (auto item: dragableItems) {