Skip to content

Commit

Permalink
Remove old ActionGroup/ActionType enums
Browse files Browse the repository at this point in the history
  • Loading branch information
bhennion committed Sep 11, 2023
1 parent d52f82c commit 8dd692b
Show file tree
Hide file tree
Showing 23 changed files with 325 additions and 2,694 deletions.
9 changes: 8 additions & 1 deletion plugins/HighlightPosition/main.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,13 @@ function initUi()
app.registerUi({["menu"] = "Toggle Highlight Position", ["callback"] = "laser", ["accelerator"] = "<Alt>x"});
end

local togglestate = false;

function laser()
app.uiAction({["action"] = "ACTION_HIGHLIGHT_POSITION"})
if toggleState == true then
app.uiAction({["action"] = "ACTION_HIGHLIGHT_POSITION", ["enabled"] = false});
else
app.uiAction({["action"] = "ACTION_HIGHLIGHT_POSITION", ["enabled"] = true});
end
toggleState = not toggleState
end
6 changes: 3 additions & 3 deletions plugins/ToggleGrid/togglegrid.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ local toggleState = false

function toggleGridPaper()
if toggleState == true then
app.uiActionSelected("GROUP_GRID_SNAPPING", "ACTION_GRID_SNAPPING");
app.uiAction({["action"] = "ACTION_GRID_SNAPPING", ["enabled"] = true});
app.changeCurrentPageBackground("graph");
else
app.uiActionSelected("GROUP_GRID_SNAPPING", "ACTION_NONE");
app.uiAction({["action"] = "ACTION_GRID_SNAPPING", ["enabled"] = false});
app.changeCurrentPageBackground("plain");
end
toggleState = not toggleState
end
end

0 comments on commit 8dd692b

Please sign in to comment.