aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/qmldesigner/components
diff options
context:
space:
mode:
authorAlessandro Portale <alessandro.portale@qt.io>2020-09-20 23:40:16 +0200
committerAlessandro Portale <alessandro.portale@qt.io>2020-10-08 09:06:02 +0000
commitc68f49fefaab4251c70c4ccaece0dd52993b653a (patch)
tree5308cc8fbf2b502c64a79c7ffcfa42a750b505b0 /src/plugins/qmldesigner/components
parent35bab3a02174c5179b1fe0414fa33b8e7cbe64dd (diff)
Remove unused private functions
As found by Cppcheck. Change-Id: I697ea69992425ff41e35990ad00be312b35ba70a Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/plugins/qmldesigner/components')
-rw-r--r--src/plugins/qmldesigner/components/curveeditor/detail/selector.cpp35
-rw-r--r--src/plugins/qmldesigner/components/curveeditor/detail/selector.h4
2 files changed, 0 insertions, 39 deletions
diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/selector.cpp b/src/plugins/qmldesigner/components/curveeditor/detail/selector.cpp
index 2ed74611e7..dd948a6ac2 100644
--- a/src/plugins/qmldesigner/components/curveeditor/detail/selector.cpp
+++ b/src/plugins/qmldesigner/components/curveeditor/detail/selector.cpp
@@ -136,41 +136,6 @@ void Selector::mouseRelease(QMouseEvent *event, GraphicsScene *scene)
m_rect = QRectF();
}
-bool Selector::isOverMovableItem(const QPointF &pos, GraphicsScene *scene)
-{
- auto intersect = [pos](QGraphicsObject *item) {
- return item->mapRectToScene(item->boundingRect()).contains(pos);
- };
-
- const auto frames = scene->keyframes();
- for (auto *frame : frames) {
- if (intersect(frame))
- return true;
-
- if (auto *leftHandle = frame->leftHandle()) {
- if (intersect(leftHandle))
- return true;
- }
-
- if (auto *rightHandle = frame->rightHandle()) {
- if (intersect(rightHandle))
- return true;
- }
- }
- return false;
-}
-
-bool Selector::isOverSelectedKeyframe(const QPointF &pos, GraphicsScene *scene)
-{
- const auto frames = scene->selectedKeyframes();
- for (auto *frame : frames) {
- QRectF frameRect = frame->mapRectToScene(frame->boundingRect());
- if (frameRect.contains(pos))
- return true;
- }
- return false;
-}
-
bool Selector::select(const SelectionTool &tool, const QPointF &pos, GraphicsScene *scene)
{
auto selectWidthTool = [this,
diff --git a/src/plugins/qmldesigner/components/curveeditor/detail/selector.h b/src/plugins/qmldesigner/components/curveeditor/detail/selector.h
index 5b72243908..68674c838d 100644
--- a/src/plugins/qmldesigner/components/curveeditor/detail/selector.h
+++ b/src/plugins/qmldesigner/components/curveeditor/detail/selector.h
@@ -50,10 +50,6 @@ public:
void mouseRelease(QMouseEvent *event, GraphicsScene *scene);
private:
- bool isOverSelectedKeyframe(const QPointF &pos, GraphicsScene *scene);
-
- bool isOverMovableItem(const QPointF &pos, GraphicsScene *scene);
-
bool select(const SelectionTool &tool, const QPointF &pos, GraphicsScene *scene);
bool pressSelection(SelectionMode mode, const QPointF &pos, GraphicsScene *scene);