summaryrefslogtreecommitdiff
path: root/src/Commands.vala
diff options
context:
space:
mode:
Diffstat (limited to 'src/Commands.vala')
-rw-r--r--src/Commands.vala10
1 files changed, 9 insertions, 1 deletions
diff --git a/src/Commands.vala b/src/Commands.vala
index 0ad8ecb..04b771c 100644
--- a/src/Commands.vala
+++ b/src/Commands.vala
@@ -211,7 +211,7 @@ public abstract class GenericPhotoTransformationCommand : SingleDataSourceComman
base(photo, name, explanation);
}
- ~GenericPhotoTransformationState() {
+ ~GenericPhotoTransformationCommand() {
if (original_state != null)
original_state.broken.disconnect(on_state_broken);
@@ -795,8 +795,16 @@ public class StraightenCommand : GenericPhotoTransformationCommand {
}
public override void execute_on_photo(Photo photo) {
+ // thaw collection so both alterations are signalled at the same time
+ DataCollection? collection = photo.get_membership();
+ if (collection != null)
+ collection.freeze_notifications();
+
photo.set_straighten(theta);
photo.set_crop(crop);
+
+ if (collection != null)
+ collection.thaw_notifications();
}
}