Added functionality

lib
- Save
- DoAction
- ApplyDataset
- GetLayer(s)

main
- do actions from commandline

Improved test cases!
This commit is contained in:
Unknown
2018-03-08 11:38:00 -05:00
parent 36ccc26243
commit 9cbf0e9b92
9 changed files with 339 additions and 34 deletions

15
scripts/applyDataset.jsx Normal file
View File

@@ -0,0 +1,15 @@
var saveFile = File(arguments[0]);
if(saveFile.exists)
saveFile.remove();
var idAply = charIDToTypeID("Aply");
var desc1 = new ActionDescriptor();
var idnull = charIDToTypeID("null");
var ref1 = new ActionReference();
var iddataSetClass = stringIDToTypeID("dataSetClass");
ref1.putName(iddataSetClass, arguments[1]);
desc1.putReference(idnull, ref1);
executeAction(idAply, desc1, DialogModes.NO);
saveFile.encoding = "UTF8";
saveFile.open("e", "TEXT", "????");
saveFile.writeln("done!");
saveFile.close();