Show "Paste to N" on every selection, disabled until something is copied

It appeared only once settings had been copied this session, so with an
empty clipboard nothing on the selection bar said pasting onto a
selection was possible. It is one of the things a selection can have
done to it, like filing it in a collection, and now sits with them
beside Presets.
This commit is contained in:
2026-09-22 21:37:41 -04:00
parent 9ebaa15099
commit 2be80d4203
+21 -22
View File
@@ -4536,15 +4536,30 @@ export component LibraryGrid inherits Rectangle {
}
}
// TRACES: FR-DEV-6
// Paste the copied edit onto the selection. One of the things a
// selection can have done to it, like filing it in a collection,
// so it is on the bar whenever there is a selection — disabled
// until something has been copied in develop. Hidden until then,
// it was a feature nobody could find (FR-UI-4).
//
// The count is in the label rather than in a confirmation: this
// writes to every selected image, and "Paste to 40" said before
// the click is worth more than a dialogue asking the same
// question after it.
if !root.ranging && root.selected-count > 0: Button {
text: "Paste to " + root.selected-count;
enabled: root.settings-armed;
y: (parent.height - self.height) / 2;
clicked => { root.paste-settings-to-selection(); }
}
// TRACES: FR-DEV-6
// The saved settings, beside the copied ones.
//
// Gated on the selection alone, unlike the paste after it: that
// button needs a clipboard *this session*, where the preset list
// is whatever the photographer saved last month. Requiring an
// armed clipboard here would hide the saved presets behind an
// unrelated action — which is the shape of bug that makes a
// feature only its author knows about (FR-UI-4).
// Enabled on the selection alone, unlike the paste before it:
// that needs a clipboard *this session*, where the preset list is
// whatever the photographer saved last month.
if !root.ranging && root.selected-count > 0: Button {
text: "Presets";
y: (parent.height - self.height) / 2;
@@ -4560,22 +4575,6 @@ export component LibraryGrid inherits Rectangle {
clicked => { root.merge-selection(); }
}
// TRACES: FR-DEV-6
// Batch-apply the copied settings. Shown only with both a
// selection and a clipboard, because it is meaningless without
// either — and because a permanently visible button that is
// usually disabled teaches the user to stop reading this bar.
//
// The count is in the label rather than in a confirmation: this
// writes to every selected image, and "Paste to 40" said before
// the click is worth more than a dialogue asking the same
// question after it.
if !root.ranging && root.selected-count > 0 && root.settings-armed: Button {
text: "Paste to " + root.selected-count;
y: (parent.height - self.height) / 2;
clicked => { root.paste-settings-to-selection(); }
}
// Removing from a collection is only meaningful while the grid is
// scoped to one. Offering it unscoped would invite the reading
// "remove from the library", which nothing here does.