fix(app): the Render quick action reads the project as stored now
The card may predate an edit made in the editor, so the render takes the sequence's current row. Whitespace of a catalog test follows the formatter. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012iLMBNwBE2GnphAsu4cjaC
This commit is contained in:
2 files changed
+12
-4
No files matched your search
@@ -87,10 +87,12 @@ public sealed class LibraryActions(ShellViewModel shell)
|
||||
return;
|
||||
}
|
||||
if (Services.Database is not { } db) return;
|
||||
// The project as stored now: the editor may have changed it since the card was read.
|
||||
var current = await db.Sequences.GetAsync(sequence.Id) ?? sequence;
|
||||
var first = (await db.Frames.ListBySequenceAsync(sequence.Id, -1, 1)).FirstOrDefault();
|
||||
var (w, h) = first is null ? (0, 0) : first.Orientation is >= 5 and <= 8 ? (first.Height, first.Width) : (first.Width, first.Height);
|
||||
var export = Project(sequence.SettingsJson).Export with { Batch = [] };
|
||||
await QueueAsync(ProcessingJobs.Render(sequence, export, w, h));
|
||||
var export = Project(current.SettingsJson).Export with { Batch = [] };
|
||||
await QueueAsync(ProcessingJobs.Render(current, export, w, h));
|
||||
}
|
||||
|
||||
/// <summary>Runs one row action of the sync table on a sequence (the card's Sync, a mass Upload or Download); false when it could not start.</summary>
|
||||
|
||||
Reference in new issue
Block a user