Hello everyone, it is possible to create a shortcut that has these two actions, "expand folder and lock the other layers", I created these shortcuts but separated and I already tried to use the history but it didn't work.
Please save the code below in a .jsfl file and test it. If it works, you can place this file in the commands folder and assign a shortcut to it.
var dom = fl.getDocumentDOM();
var tl = dom.getTimeline();
var currentLayerIndex = tl.currentLayer;
var currentLayer = tl.layers[currentLayerIndex];
if (currentLayer.layerType === "folder")
{
tl.expandFolder(true);
tl.setLayerProperty("locked", true, "all");
tl.setLayerProperty("locked", false);
}
I need these two actions to be in the same shortcut, I tried saving the action and converting it to the command, but it didn't work. I don't have that knowledge in JSFL.