aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/qmldesigner/components/timelineeditor/timelinegraphicslayout.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/plugins/qmldesigner/components/timelineeditor/timelinegraphicslayout.cpp')
-rw-r--r--src/plugins/qmldesigner/components/timelineeditor/timelinegraphicslayout.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/plugins/qmldesigner/components/timelineeditor/timelinegraphicslayout.cpp b/src/plugins/qmldesigner/components/timelineeditor/timelinegraphicslayout.cpp
index a0f0eedf29..007e8ae571 100644
--- a/src/plugins/qmldesigner/components/timelineeditor/timelinegraphicslayout.cpp
+++ b/src/plugins/qmldesigner/components/timelineeditor/timelinegraphicslayout.cpp
@@ -63,6 +63,11 @@ TimelineGraphicsLayout::TimelineGraphicsLayout(TimelineGraphicsScene *scene, Tim
TimelineGraphicsLayout::~TimelineGraphicsLayout() = default;
+int TimelineGraphicsLayout::zoom() const
+{
+ return m_rulerItem->zoom();
+}
+
double TimelineGraphicsLayout::rulerWidth() const
{
return m_rulerItem->preferredWidth();
@@ -133,12 +138,12 @@ void TimelineGraphicsLayout::setTimeline(const QmlTimeline &timeline)
if (auto *scene = timelineScene())
if (auto *view = scene->timelineView())
if (!timeline.isValid() && view->isAttached())
- emit scaleFactorChanged(0);
+ emit zoomChanged(0);
}
-void TimelineGraphicsLayout::setRulerScaleFactor(int factor)
+void TimelineGraphicsLayout::setZoom(int factor)
{
- m_rulerItem->setRulerScaleFactor(factor);
+ m_rulerItem->setZoom(factor);
}
void TimelineGraphicsLayout::invalidate()