1 /***************************************************************************
2 * Copyright (C) 2011 by Till Theato (root@ttill.de) *
3 * This file is part of Kdenlive (www.kdenlive.org). *
5 * Kdenlive is free software: you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation, either version 2 of the License, or *
8 * (at your option) any later version. *
10 * Kdenlive is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
15 * You should have received a copy of the GNU General Public License *
16 * along with Kdenlive. If not, see <http://www.gnu.org/licenses/>. *
17 ***************************************************************************/
25 #include <QAbstractGraphicsShapeItem>
27 class BPointItem : public QAbstractGraphicsShapeItem
30 BPointItem(BPoint point, QGraphicsItem* parent = 0);
33 void setPoint(BPoint point);
35 enum { Type = UserType + 11 };
36 virtual int type() const;
38 virtual QRectF boundingRect() const;
39 virtual void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget = 0);
42 virtual void mousePressEvent(QGraphicsSceneMouseEvent *event);
43 virtual void mouseMoveEvent(QGraphicsSceneMouseEvent *event);
44 virtual void mouseReleaseEvent(QGraphicsSceneMouseEvent *event);
45 virtual void hoverMoveEvent(QGraphicsSceneHoverEvent *event);
51 /** @brief Gets The action mode for the area @param pos +- 4. */
52 int getSelection(QPointF pos);