@@ -1046,7 +1046,7 @@ def Transform_Triggered(self, action, clip_ids):
1046
1046
# Clear transform
1047
1047
self .window .TransformSignal .emit ("" )
1048
1048
1049
- def Show_Waveform_Triggered (self , clip_ids ):
1049
+ def Show_Waveform_Triggered (self , clip_ids , transaction_id = None ):
1050
1050
"""Show a waveform for all selected clips"""
1051
1051
1052
1052
# Group clip IDs under each File ID
@@ -1062,7 +1062,7 @@ def Show_Waveform_Triggered(self, clip_ids):
1062
1062
files [file_id ].append (clip .data .get ("id" ))
1063
1063
1064
1064
# Get audio data for all "selected" files/clips
1065
- get_audio_data (files )
1065
+ get_audio_data (files , transaction_id = transaction_id )
1066
1066
1067
1067
def Hide_Waveform_Triggered (self , clip_ids ):
1068
1068
"""Hide the waveform for the selected clip"""
@@ -1117,6 +1117,10 @@ def Split_Audio_Triggered(self, action, clip_ids):
1117
1117
# Get translation method
1118
1118
_ = get_app ()._tr
1119
1119
1120
+ # Group transactions
1121
+ tid = self .get_uuid ()
1122
+ get_app ().updates .transaction_id = tid
1123
+
1120
1124
# Loop through each selected clip
1121
1125
for clip_id in clip_ids :
1122
1126
@@ -1179,7 +1183,7 @@ def Split_Audio_Triggered(self, action, clip_ids):
1179
1183
1180
1184
# Generate waveform for new clip
1181
1185
log .info ("Generate waveform for split audio track clip id: %s" % clip .id )
1182
- self .Show_Waveform_Triggered ([clip .id ])
1186
+ self .Show_Waveform_Triggered ([clip .id ], transaction_id = tid )
1183
1187
1184
1188
if action == MENU_SPLIT_AUDIO_MULTIPLE :
1185
1189
# Get # of channels on clip
@@ -1232,7 +1236,7 @@ def Split_Audio_Triggered(self, action, clip_ids):
1232
1236
1233
1237
# Generate waveform for new clip
1234
1238
log .info ("Generate waveform for split audio track clip ids: %s" % str (separate_clip_ids ))
1235
- self .Show_Waveform_Triggered (separate_clip_ids )
1239
+ self .Show_Waveform_Triggered (separate_clip_ids , transaction_id = tid )
1236
1240
1237
1241
for clip_id in clip_ids :
1238
1242
@@ -1248,9 +1252,12 @@ def Split_Audio_Triggered(self, action, clip_ids):
1248
1252
clip .data ["has_audio" ] = {"Points" : [p_object ]}
1249
1253
1250
1254
# Save filter on original clip
1251
- self .update_clip_data (clip .data , only_basic_props = False , ignore_reader = True )
1255
+ self .update_clip_data (clip .data , only_basic_props = False , ignore_reader = True , transaction_id = tid )
1252
1256
clip .save ()
1253
1257
1258
+ # Clear transaction
1259
+ get_app ().updates .transaction_id = None
1260
+
1254
1261
def Layout_Triggered (self , action , clip_ids ):
1255
1262
"""Callback for the layout context menus"""
1256
1263
log .debug (action )
0 commit comments