Fix Clip Creation Quantization in Song Editor (#7763)

Previously, clicking on a track or dragging in a sample would always create a clip on the closest/previous bar, no matter what the Song Editor's snap size was. This fixes that issue by using the Song Editor's quantization when placing new clips, so for example if the snap size is 1/4 bar, the clip will be added at the closest/previous 1/4 bar mark.
This commit is contained in:
regulus79
2025-04-19 15:08:15 -04:00
committed by GitHub
parent d06c5941f2
commit cb8badc0bb
4 changed files with 8 additions and 6 deletions

View File

@@ -70,7 +70,7 @@ public:
TimePos( const bar_t bar, const tick_t ticks );
TimePos( const tick_t ticks = 0 );
TimePos quantize(float) const;
TimePos quantize(float bars, bool forceRoundDown = false) const;
TimePos toAbsoluteBar() const { return getBar() * s_ticksPerBar; }
TimePos& operator+=(const TimePos& time)