Members of the KDE Community are recommended to subscribe to the kde-community mailing list at https://mail.kde.org/mailman/listinfo/kde-community to allow them to participate in important discussions and receive other important announcements

Commit 79762b5d authored by Jean-Baptiste Mardelle's avatar Jean-Baptiste Mardelle

Fix incoherent snapping

parent e0fbd33f
Pipeline #1615 passed with stage
in 14 minutes and 17 seconds
......@@ -2157,7 +2157,7 @@ void MainWindow::slotSwitchSnap()
{
KdenliveSettings::setSnaptopoints(!KdenliveSettings::snaptopoints());
m_buttonSnap->setChecked(KdenliveSettings::snaptopoints());
getMainTimeline()->controller()->snapChanged(KdenliveSettings::snaptopoints());
getMainTimeline()->controller()->snapChanged();
}
void MainWindow::slotSwitchAutomaticTransition()
......
......@@ -85,7 +85,7 @@ Rectangle {
}
onInPointChanged: {
if (parentTrack && parentTrack.isAudio) {
if (parentTrack && parentTrack.isAudio && thumbsLoader.item) {
thumbsLoader.item.reload()
}
}
......
......@@ -271,11 +271,6 @@ bool TimelineController::snap()
return KdenliveSettings::snaptopoints();
}
void TimelineController::snapChanged(bool snap)
{
m_root->setProperty("snapping", snap ? 10 / std::sqrt(m_scale) : -1);
}
bool TimelineController::ripple()
{
return false;
......
......@@ -56,6 +56,7 @@ class TimelineController : public QObject
Q_PROPERTY(int seekPosition READ seekPosition WRITE setSeekPosition NOTIFY seekPositionChanged)
Q_PROPERTY(bool ripple READ ripple NOTIFY rippleChanged)
Q_PROPERTY(bool scrub READ scrub NOTIFY scrubChanged)
Q_PROPERTY(bool snap READ snap NOTIFY snapChanged)
Q_PROPERTY(bool showThumbnails READ showThumbnails NOTIFY showThumbnailsChanged)
Q_PROPERTY(bool showMarkers READ showMarkers NOTIFY showMarkersChanged)
Q_PROPERTY(bool showAudioThumbnails READ showAudioThumbnails NOTIFY showAudioThumbnailsChanged)
......@@ -334,10 +335,6 @@ public:
*/
void seekToMouse();
/* @brief User enabled / disabled snapping, update timeline behavior
*/
void snapChanged(bool snap);
/* @brief Returns a list of all luma files used in the project
*/
QStringList extractCompositionLumas() const;
......@@ -503,6 +500,9 @@ signals:
/* @brief emitted when timeline selection changes, true if a clip is selected
*/
void timelineClipSelected(bool);
/* @brief User enabled / disabled snapping, update timeline behavior
*/
void snapChanged();
Q_INVOKABLE void ungrabHack();
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment