Wire the Remove cutaway button
Clears the cutaway from the shot so it is not cut into the film. The subject stays, so Make cutaway can try again with a different draw.
This commit is contained in:
parent
58ccf6fc6d
commit
4292624eda
1 changed files with 20 additions and 0 deletions
20
script.html
20
script.html
|
|
@ -720,6 +720,26 @@ function wire(locked) {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
|
// Throwing a cutaway away. The picture is drawn from the writer's guess at
|
||||||
|
// what the line is about, so a wrong one is common and there was no way to
|
||||||
|
// get rid of it - only to redraw and hope.
|
||||||
|
[].forEach.call(document.querySelectorAll("[data-brollrm]"), function (b) {
|
||||||
|
b.addEventListener("click", async function () {
|
||||||
|
hideMsg("msg");
|
||||||
|
var idx = parseInt(b.getAttribute("data-brollrm"), 10);
|
||||||
|
b.disabled = true; b.textContent = "Removing…";
|
||||||
|
var r = await api("update_shot", { email: email, project_id: pid,
|
||||||
|
index: idx, broll_clear: true });
|
||||||
|
if (!r.ok) {
|
||||||
|
b.disabled = false; b.textContent = "Remove cutaway";
|
||||||
|
showMsg("msg", r.error || "Could not remove that.");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
showMsg("msg", "Cutaway removed from shot " + idx + ".", "ok");
|
||||||
|
load();
|
||||||
|
});
|
||||||
|
});
|
||||||
|
|
||||||
[].forEach.call(document.querySelectorAll("[data-broll]"), function (b) {
|
[].forEach.call(document.querySelectorAll("[data-broll]"), function (b) {
|
||||||
b.addEventListener("click", async function () {
|
b.addEventListener("click", async function () {
|
||||||
hideMsg("msg");
|
hideMsg("msg");
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue