Skip to content

Commit 85c579d

Browse files
committed
Fixed dict update
1 parent 5f2453b commit 85c579d

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

src/windows/models/properties_model.py

+9-2
Original file line numberDiff line numberDiff line change
@@ -201,7 +201,7 @@ def remove_keyframe(self, item):
201201

202202
if property_key in clip_data: # Update clip attribute
203203
log.debug("remove keyframe: %s" % clip_data)
204-
204+
205205
# Determine type of keyframe (normal or color)
206206
keyframe_list = []
207207
if property_type == "color":
@@ -237,6 +237,8 @@ def remove_keyframe(self, item):
237237

238238
# Reduce # of clip properties we are saving (performance boost)
239239
clip_data = {property_key: clip_data[property_key]}
240+
if object_id is not None:
241+
clip_data = {'objects': {object_id: clip_data}}
240242

241243
# Save changes
242244
if clip_updated:
@@ -350,7 +352,9 @@ def color_update(self, item, new_color, interpolation=-1, interpolation_details=
350352

351353
# Reduce # of clip properties we are saving (performance boost)
352354
clip_data = {property_key: clip_data[property_key]}
353-
355+
if object_id is not None:
356+
clip_data = {'objects': {object_id: clip_data}}
357+
354358
# Save changes
355359
if clip_updated:
356360
# Save
@@ -550,6 +554,9 @@ def value_updated(self, item, interpolation=-1, value=None, interpolation_detail
550554

551555
# Reduce # of clip properties we are saving (performance boost)
552556
clip_data = {property_key: clip_data.get(property_key)}
557+
558+
if object_id is not None:
559+
clip_data = {'objects': {object_id: clip_data}}
553560

554561
# Save changes
555562
if clip_updated:

0 commit comments

Comments
 (0)