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
Function::property = (prop, desc) -> | |
Object.defineProperty @prototype, prop, desc | |
class testLayer extends Layer | |
constructor: (options = {}) -> | |
super options | |
@property 'angle', | |
get: -> @_angle | |
set: (angle) -> |
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
# Copied mostly from the framer source which at this time is here https://github.com/koenbok/Framer/blob/master/framer/VideoLayer.coffee | |
class AudioLayer extends Layer | |
constructor: (options={}) -> | |
super options | |
@player = document.createElement("audio") | |
@player.setAttribute("preload", "auto") |
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
class InputTextLayer extends Framer.Layer | |
constructor: (options) -> | |
super options | |
@ignoreEvents = false | |
@input = document.createElement("input") | |
_.extend @input.style, |
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
sips -Z 640 640 *.JPG |
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
// this script moves the selected object it's given distances (command ') | |
var input = [doc askForUserInput:"Transform (X,Y)" initialValue:0]; | |
var flags = [NSEvent modifierFlags]; | |
// should validate the input here | |
var x_delta = eval(input.split(",")[0]); | |
var y_delta = eval(input.split(",")[1]); |
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
// this script moves the selected object it's given distances (command ') | |
// var levels = dialog(" ", 0, "Transform'" + [layer name] + "'(x,y)"); | |
var levels = dialog(" ", 0, "Transform Object (x,y)"); | |
/** | |
* Open a dialog for user input | |
* @param {string} msg The dialog message | |
* @param {mixed} given String or number - the given input value | |
* @param {string} title The dialog title | |
* @return {string} The value the user entered in the dialog |