4PointCutting: Add crossfade not only on first destination track but on all.

This commit is contained in:
Ludwig Frühschütz 2020-02-02 00:21:41 +01:00
parent 11af6dda0a
commit df9ea26ba6

View File

@ -177,6 +177,13 @@ reaper.Main_OnCommand(40058, 0) -- paste item
--reaper.Main_OnCommand( reaper.NamedCommandLookup('_SWS_AWPASTE'), 0 ) -- SWS Paste
-- Crossfade (only with SWS extensions, "fill gaps")
if sws_present then
-- select track with selected items
local selected_items_count = reaper.CountSelectedMediaItems(0)
for i = 0, selected_items_count - 1 do
local item = reaper.GetSelectedMediaItem(0, i)
local track = reaper.GetMediaItem_Track(item)
reaper.SetTrackSelected(track, true)
end
reaper.Main_OnCommand( 40290, 0 ) -- set time selection to selected items
reaper.Main_OnCommand( 40320, 0 ) -- nudge left edge of time selection left
reaper.Main_OnCommand( 40323, 0 ) -- nudge right edge of time selection right