         return
       @sendLog
         loglevel: 'error'
-        message: 'Received commands but there\'s any 2d context attached.'
+        message: 'Received commands but there is not 2d context attached.'
+
+    @inPorts.every.on 'data', (data) =>
+      @every = data
 
     @inPorts.canvas.on 'data', (canvas) =>
       @canvas = canvas

      
    @inPorts.commands.on 'data', (commands, i) =>
      @commands[i] = commands

    # TODO listen for detach / reindex


  parse: (commands) =>
    for command in commands
      for instr, args of command
        if @[instr]?
          @[instr].apply @, [args]

  clear: (rectangle) =>
    if rectangle

  description: 'Draws received drawing commands'
  icon: 'pencil-square'
  constructor: ->
    @every = false
    @canvas = null
    @context = null
    @commands = []
    
    @inPorts =
      tick: new noflo.Port 'bang'
      every: new noflo.Port 'boolean'
      canvas: new noflo.Port 'object'
      commands: new noflo.ArrayPort 'object'

    @outPorts =
      canvas: new noflo.Port 'object'

    @inPorts.tick.on 'data', (tick) =>
      if @context
