The safety layer: two presses for anything you cannot take back
Claude-Session: https://claude.ai/code/session_01Ms2FbjQy31TVf3CEvQhGM8
This commit is contained in:
@@ -251,11 +251,16 @@ SettingsPage {
|
||||
|
||||
width: parent.width
|
||||
label: String(jobRow.modelData.name ?? "Untitled")
|
||||
detail: String(jobRow.modelData.printer ?? "") + " · "
|
||||
// Armed, the row makes the Hold/Cancel distinction the service
|
||||
// was built around: holding keeps the job, cancelling throws it
|
||||
// away and the document has to be sent from the app again.
|
||||
detail: cancelJob.armed
|
||||
? "The job is thrown away — printing it means sending it from the app again. Hold keeps it in the queue instead."
|
||||
: String(jobRow.modelData.printer ?? "") + " · "
|
||||
+ String(jobRow.modelData.state ?? "")
|
||||
+ (Number(jobRow.modelData.pages ?? 0) > 0
|
||||
? " · " + jobRow.modelData.pages + " pages" : "")
|
||||
controlWidth: 175
|
||||
controlWidth: 265
|
||||
divider: jobRow.index < Printers.jobs.length - 1
|
||||
|
||||
Row {
|
||||
@@ -275,11 +280,18 @@ SettingsPage {
|
||||
: Printers.hold(Number(jobRow.modelData.id))
|
||||
}
|
||||
|
||||
SettingsButton {
|
||||
ConfirmAction {
|
||||
id: cancelJob
|
||||
|
||||
anchors.verticalCenter: parent.verticalCenter
|
||||
text: "Cancel"
|
||||
actionId: "cancel-job:" + String(jobRow.modelData.id ?? "")
|
||||
armText: "Cancel…"
|
||||
confirmText: "Cancel it"
|
||||
// Not "Keep": the job is not being kept in a drawer, it
|
||||
// carries on out of the printer.
|
||||
cancelText: "Keep printing"
|
||||
enabled: !Printers.busy
|
||||
onClicked: Printers.cancel(Number(jobRow.modelData.id))
|
||||
onConfirmed: Printers.cancel(Number(jobRow.modelData.id))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user