Created
June 16, 2020 00:40
-
-
Save janily/33f26758fb05f2feb5c992a95d4104f4 to your computer and use it in GitHub Desktop.
get selection position
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var selectedLayers = context.selection; | |
| for (var i = 0, n = selectedLayers.count(); i < n; i++) { | |
| var layer = selectedLayers[i]; | |
| console.log(layer.frame().x()); | |
| console.log(layer.frame().y()); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment