mirror of
https://github.com/alesimula/Murine-launcher.git
synced 2026-10-28 09:43:42 +00:00
WEBSITE - WIP - icon shapes - track global shape changes for undo / redo
This commit is contained in:
1 parent
e2ac7d2380
commit
3a2918dfa0
2 files changed
+3
-2
No files matched your search
+1
-1
@@ -5,7 +5,7 @@ description: >-
|
||||
url: "https://alesimula.github.io"
|
||||
baseurl: ""
|
||||
|
||||
version: "1.0.42" #Website version - increase to invalidate cached resources
|
||||
version: "1.0.43" #Website version - increase to invalidate cached resources
|
||||
github_repo: "alesimula/Murine-launcher"
|
||||
icon_url: "https://raw.githubusercontent.com/alesimula/Murine-launcher/refs/heads/main/image/app_icon/icon_browser_fullsize.svg"
|
||||
icon_freeform_url: "https://raw.githubusercontent.com/alesimula/Murine-launcher/refs/heads/main/image/app_icon/icon_freeform.svg"
|
||||
|
||||
@@ -1146,7 +1146,8 @@
|
||||
if (!drag) return;
|
||||
if (drag.kind === 'point' && (drag.start || drag.pending) && !drag.moved) selectOnly(drag.i); // a tap: just this corner
|
||||
// A press that changed nothing (a tap, or a drag back to where it started) leaves no undo step behind.
|
||||
if (undo.length && JSON.stringify(JSON.parse(undo[undo.length - 1]).shapes) === JSON.stringify(shapes)) {
|
||||
const top = undo.length && JSON.parse(undo[undo.length - 1]); // the shapes and the Global transform (see snapshot)
|
||||
if (top && JSON.stringify([top.shapes, top.whole ?? null]) === JSON.stringify([shapes, whole])) {
|
||||
undo.pop(); redo.push(...drag.redoKept);
|
||||
}
|
||||
drag = null; render();
|
||||
|
||||
Reference in new issue
Block a user