diff options
| -rw-r--r-- | src/Presentation.qml | 5 | ||||
| -rw-r--r-- | src/Slide.qml | 14 | ||||
| -rw-r--r-- | tools/printslides/slideview.cpp | 1 |
3 files changed, 20 insertions, 0 deletions
diff --git a/src/Presentation.qml b/src/Presentation.qml index e988354..086e907 100644 --- a/src/Presentation.qml +++ b/src/Presentation.qml @@ -50,6 +50,7 @@ Item { property int currentSlide; property bool showNotes: false; + property bool allowDelay: true; property color titleColor: textColor; property color textColor: "black" @@ -90,6 +91,10 @@ Item { root._userNum = 0 if (_faded) return + if (root.slides[currentSlide].delayPoints) { + if (root.slides[currentSlide]._advance()) + return; + } if (root.currentSlide + 1 < root.slides.length) { var from = slides[currentSlide] var to = slides[currentSlide + 1] diff --git a/src/Slide.qml b/src/Slide.qml index eff235c..c440cfb 100644 --- a/src/Slide.qml +++ b/src/Slide.qml @@ -52,6 +52,19 @@ Item { property bool isSlide: true; + property bool delayPoints: false; + property int _pointCounter: 0; + function _advance() { + if (!parent.allowDelay) + return false; + + _pointCounter = _pointCounter + 1; + if (_pointCounter < content.length) + return true; + _pointCounter = 0; + return false; + } + property string title; property variant content: [] property string centeredText @@ -149,6 +162,7 @@ Item { height: text.height + (nextIndentLevel == 0 ? 1 : 0.3) * slide.baseFontSize * slide.bulletSpacing x: slide.baseFontSize * indentLevel + visible: (!slide.parent.allowDelay || !delayPoints) || index <= _pointCounter Rectangle { id: dot diff --git a/tools/printslides/slideview.cpp b/tools/printslides/slideview.cpp index 66ba760..e7dc3aa 100644 --- a/tools/printslides/slideview.cpp +++ b/tools/printslides/slideview.cpp @@ -63,6 +63,7 @@ void SlideView::updateStatus(QQuickView::Status status) { } else qDebug() << "Found qml Presentation as rootObject"; + ri->setProperty("allowDelay", QVariant(false));//Disable partial reveals on slide pages QList<QVariant> slides = ri->property("slides").toList(); m_slidesLeft = slides.size(); qDebug() << "SlideCount: " << m_slidesLeft; |
