adding quad trees for collisions

adding quad trees for collisions

--- src/quad_tree.coffee
+++ src/quad_tree.coffee
@@ -1,142 +1,146 @@
-(window.QuadTree = (I) ->
-    I ||= {}
-
-    $.reverseMerge I,
-      bounds:
-        x: 0
-        y: 0
-        width: 480
-        height: 320
-      maxDepth: 4
-      maxChildren: 5
+((window) ->
+
+  QuadTree = (I) ->
+      I ||= {}

-    root = Node(I.bounds, I.maxDepth, I.maxChildren)
-
-    self =
-      clear: -> root.clear()
-
-      insert: (obj) ->
-        if obj instanceOf Array
-          obj.each (item) ->
-            root.insert(item)
+      $.reverseMerge I,
+        bounds:
+          x: 0
+          y: 0
+          width: 480
+          height: 320
+        maxDepth: 4
+        maxChildren: 5
+
+      root = Node(I.bounds, I.maxDepth, I.maxChildren)
+
+      self =
+        clear: -> root.clear()
+
+        insert: (obj) ->
+          if obj instanceOf Array
+            obj.each (item) ->
+              root.insert(item)
+          else
+            root.insert(obj)
+
+        retrieve: (item) -> root.retrieve(item).copy()
+
+      self
+
+    window.Node = (I) ->
+      I ||= {}
+
+      $.reverseMerge I,
+        bounds:
+          x: 0
+          y: 0
+          width: 120
+          height: 80
+        children: []
+        depth: 0
+        maxChildren: 5
+        nodes: []
+
+      TOP_LEFT = 0
+      TOP_RIGHT = 1
+      BOTTOM_LEFT = 2
+      BOTTOM_RIGHT = 3
+
+      findIndex = (item) ->
+        bounds = I.bounds
+        left = (if (item.x > bounds.x + bounds.width / 2) then false else true)
+        top = (if (item.y > bounds.y + bounds.height / 2) then false else true)
+
+        index = TOP_LEFT
+
+        if left
+          if !top
+            index = BOTTOM_LEFT
         else
-          root.insert(obj)
-
-      retrieve: (item) -> root.retrieve(item).copy()
+          if top
+            index = TOP_RIGHT
+          else
+            index = BOTTOM_RIGHT

-    self
-
-  window.Node = (I) ->
-    I ||= {}
-
-    $.reverseMerge I,
-      bounds:
-        x: 0
-        y: 0
-        width: 120
-        height: 80
-      children: []
-      depth: 0
-      maxChildren: 5
-      nodes: []
+        return index
+
+      self =
+        clear: ->
+          I.children.clear()
+
+          I.nodes.invoke('clear')
+
+          I.nodes.clear()

-    TOP_LEFT = 0
-    TOP_RIGHT = 1
-    BOTTOM_LEFT = 2
-    BOTTOM_RIGHT = 3
+        insert: (item) ->
+          index = findIndex(item)
+
+          if I.nodes.length
+            return I.nodes[index].insert(item)
+
+          I.children.push(item)
+
+          if (I.depth >= I.maxDepth) && (I.children.length > I.maxChildren)
+            self.subdivide()
+
+            I.children.each (child) ->
+              self.insert(child)
+
+            I.children.clear()
+
+        retrieve: (item) ->
+          if I.nodes.length
+            index = findIndex(item)

-    findIndex = (item) ->
-      bounds = I.bounds
-      left = (if (item.x > bounds.x + bounds.width / 2) then false else true)
-      top = (if (item.y > bounds.y + bounds.height / 2) then false else true)
+            return I.nodes[index].retrieve(item)
+
+          return I.children
+
+        subdivide: ->
+          depth = I.depth + 1

-      index = TOP_LEFT
+          b_x = I.bounds.x
+          b_y = I.bounds.y
+
+          b_w_h = (I.bounds.width / 2).floor()
+          b_h_h = (I.bounds.height / 2).floor()
+          bx_b_w_h = b_x + b_w_h
+          by_b_h_h = b_y + b_h_h
+
+          I.nodes[TOP_LEFT] = Node
+            bounds:
+              x: b_x
+              y: b_y
+              width: b_w_h
+              height: b_h_h
+            depth: depth
+
+          I.nodes[TOP_RIGHT] = Node
+            bounds:
+              x: bx_b_w_h
+              y: b_y
+              width: b_w_h
+              height: b_h_h
+            depth: depth
+
+          I.nodes[BOTTOM_LEFT] = Node
+            bounds:
+              x: b_x
+              y: by_b_h_h
+              width: b_w_h
+              height: b_h_h
+            depth: depth
+
+          I.nodes[BOTTOM_RIGHT] = Node
+            bounds:
+              x: bx_b_w_h
+              y: by_b_h_h
+              width: b_w_h
+              height: b_h_h
+            depth: depth

-      if left
-        if !top
-          index = BOTTOM_LEFT
-      else
-        if top
-          index = TOP_RIGHT
-        else
-          index = BOTTOM_RIGHT
+      self

-      return index
-
-    self =
-      clear: ->
-        I.children.clear()
-
-        I.nodes.invoke('clear')
-
-        I.nodes.clear()
-
-      insert: (item) ->
-        index = findIndex(item)
-
-        if I.nodes.length
-          return I.nodes[index].insert(item)
-
-        I.children.push(item)
-
-        if (I.depth >= I.maxDepth) && (I.children.length > I.maxChildren)
-          self.subdivide()
-
-          I.children.each (child) ->
-            self.insert(child)
-
-          I.children.clear()
-
-      retrieve: (item) ->
-        if I.nodes.length
-          index = findIndex(item)
-
-          return I.nodes[index].retrieve(item)
-
-        return I.children
-
-      subdivide: ->
-        depth = I.depth + 1
-
-        b_x = I.bounds.x
-        b_y = I.bounds.y
-
-        b_w_h = (I.bounds.width / 2).floor()
-        b_h_h = (I.bounds.height / 2).floor()
-        bx_b_w_h = b_x + b_w_h
-        by_b_h_h = b_y + b_h_h
-
-        I.nodes[TOP_LEFT] = Node
-          bounds:
-            x: b_x
-            y: b_y
-            width: b_w_h
-            height: b_h_h
-          depth: depth
-
-        I.nodes[TOP_RIGHT] = Node
-          bounds:
-            x: bx_b_w_h
-            y: b_y
-            width: b_w_h
-            height: b_h_h
-          depth: depth
-
-        I.nodes[BOTTOM_LEFT] = Node
-          bounds:
-            x: b_x
-            y: by_b_h_h
-            width: b_w_h
-            height: b_h_h
-          depth: depth
-
-        I.nodes[BOTTOM_RIGHT] = Node
-          bounds:
-            x: bx_b_w_h
-            y: by_b_h_h
-            width: b_w_h
-            height: b_h_h
-          depth: depth
-
-    self
-)()+  window.QuadTree = QuadTree
+(window))


FIX error in query getElementById

FIX error in query getElementById

--- src/quo.query.coffee
+++ src/quo.query.coffee
@@ -12,7 +12,7 @@
             elements = domain.getElementsByClassName selector.replace(".", "")
         else if TAG_SELECTOR.test(selector)
             elements = domain.getElementsByTagName(selector)
-        else if ID_SELECTOR.test(selector) and domain isnt document
+        else if ID_SELECTOR.test(selector) and domain is document
             elements = domain.getElementById selector.replace("#", "")
             unless elements then elements = []
         else


implement get/set selection without rangy

--- src/selection.coffee
+++ src/selection.coffee
@@ -6,6 +6,7 @@

   constructor: (@editor) ->
     @range = null
+    @nativeSelection = @editor.contentWindow.getSelection()
     this.initListeners()

   initListeners: ->
@@ -34,27 +35,15 @@
     this.update()
     return @range

-  getNative: ->
-    rangySel = rangy.getSelection(@editor.contentWindow)
-    selection = window.getSelection()
-    return null unless rangySel.anchorNode? and rangySel.focusNode? and @editor.root.contains(rangySel.anchorNode) and @editor.root.contains(rangySel.focusNode)
-    if !rangySel.isBackwards()
-      [anchorNode, anchorOffset, focusNode, focusOffset] = [rangySel.anchorNode, rangySel.anchorOffset, rangySel.focusNode, rangySel.focusOffset]
+  getRange: ->
+    return null unless @nativeSelection.rangeCount > 0
+    nativeRange = @nativeSelection.getRangeAt(0)
+    start = new Scribe.Position(@editor, nativeRange.startContainer, nativeRange.startOffset)
+    end = new Scribe.Position(@editor, nativeRange.endContainer, nativeRange.endOffset)
+    if nativeRange.compareBoundaryPoints(Range.START_TO_END, nativeRange) < 1
+      return new Scribe.Range(@editor, start, end)
     else
-      [focusNode, focusOffset, anchorNode, anchorOffset] = [rangySel.anchorNode, rangySel.anchorOffset, rangySel.focusNode, rangySel.focusOffset]
-    return {
-      anchorNode    : anchorNode
-      anchorOffset  : anchorOffset
-      focusNode     : focusNode
-      focusOffset   : focusOffset
-    }
-
-  getRange: ->
-    nativeSel = this.getNative()
-    return null unless nativeSel?
-    start = new Scribe.Position(@editor, nativeSel.anchorNode, nativeSel.anchorOffset)
-    end = new Scribe.Position(@editor, nativeSel.focusNode, nativeSel.focusOffset)
-    return new Scribe.Range(@editor, start, end)
+      return new Scribe.Range(@editor, end, start)

   preserve: (fn) ->
     this.update(true)
@@ -103,20 +92,15 @@
     )

   setRange: (@range, silent = false) ->
-    rangySel = rangy.getSelection(@editor.contentWindow)
+    @nativeSelection.removeAllRanges()
     if @range?
-      rangySelRange = @range.getRangy()
-      rangySel.setSingleRange(rangySelRange)
-    else
-      rangySel.removeAllRanges()
+      nativeRange = @editor.root.ownerDocument.createRange()
+      [startNode, startOffset] = Scribe.DOM.findDeepestNode(@range.start.leafNode, @range.start.offset)
+      nativeRange.setStart(startNode, startOffset)
+      [endNode, endOffset] = Scribe.DOM.findDeepestNode(@range.end.leafNode, @range.end.offset)
+      nativeRange.setEnd(endNode, endOffset)
+      @nativeSelection.addRange(nativeRange)
     @editor.emit(Scribe.Editor.events.SELECTION_CHANGE, @range) unless silent
-
-  setRangeNative: (nativeSel) ->
-    rangySel = rangy.getSelection(@editor.contentWindow)
-    range = rangy.createRangyRange(@editor.contentWindow)
-    range.setStart(nativeSel.anchorNode, nativeSel.anchorOffset)
-    range.setEnd(nativeSel.focusNode, nativeSel.focusOffset)
-    rangySel.setSingleRange(range)

   update: (silent = false) ->
     range = this.getRange()


Tutorial tweaks

Tutorial tweaks

--- app/lib/tutorial_steps.coffee
+++ app/lib/tutorial_steps.coffee
@@ -51,7 +51,7 @@
     number: 5
     header: translate 'span', 'tutorial.identify.header'
     details: translate 'span', 'tutorial.identify.details'
-    attachment: 'left top .current 1 0.5'
+    attachment: 'left center .primary 0.7 center'
     block: '.annotation, .controls:first'
     className: 'arrow-left'
     onEnter: ->
@@ -70,7 +70,7 @@
     number: 6
     header: translate 'span', 'tutorial.mark.header'
     details: translate 'span', 'tutorial.mark.details'
-    attachment: 'left top .current 1 0.52'
+    attachment: 'left center .primary 0.7 center'
     block: '.controls:first'
     className: 'arrow-left'
     onEnter: (tutorial) ->
@@ -78,9 +78,10 @@
       ctx = canvas.getContext('2d')
       img = new Image()
       img.onload = (e) =>
-        canvas.width = img.width
-        canvas.height = img.height
-        ctx.drawImage(img, 0, 0, img.width, img.height)
+        viewportSize = 441
+        canvas.width = viewportSize
+        canvas.height = viewportSize
+        ctx.drawImage img, 0, 0, viewportSize, viewportSize
       img.src = $('.current .image img').attr('src')
     next:
       'mouseup .annotation': (e, tutorial, step) ->
@@ -90,7 +91,7 @@
   good_job: new Step
     header: translate 'span', 'tutorial.good_job.header'
     details: translate 'span', 'tutorial.good_job.details'
-    attachment: 'left top .current 1 0.52'
+    attachment: 'left center .primary 0.7 center'
     block: '.controls'
     className: 'arrow-left'
     next: 'training'
@@ -98,7 +99,7 @@
   try_again: new Step
     header: translate 'span', 'tutorial.try_again.header'
     details: translate 'span', 'tutorial.try_again.details'
-    attachment: 'left top .current 1 0.44'
+    attachment: 'left center .primary 0.7 center'
     className: 'arrow-left'
     blocks: '.controls:first'
     next:


Tutorial button color experiment

Tutorial button color experiment

--- app/lib/tutorial_steps.coffee
+++ app/lib/tutorial_steps.coffee
@@ -38,6 +38,13 @@
     nextOn: click: 'button[value="likeAntelopeDeer"]'
     attachment: x: 'right', margin: 10, to: 'button[name="characteristic"][value="like"]', at: x: 'left'
     className: 'arrow right'
+
+    onEnter: ->
+      @toHighlight = $('button[value="like"][name="characteristic"], [button[value="likeAntelopeDeer"][name="characteristic-value"]')
+      @toHighlight.css 'background-color': '#490'
+
+    onExit: ->
+      @toHighlight.css 'background-color': ''

   new Step
     header: inline translate 'classify.tutorial.chooseSolidHeader'


Removed Renderer.* shortcats support

Removed Renderer.* shortcats support

--- index.coffee
+++ index.coffee
@@ -628,7 +628,7 @@

 		rendererCtor = Renderer[elem.name.split('.')[0]]
 		if rendererCtor?
-			r = "new #{elem.name}(_c, #{json})\n"
+			r = "new Renderer.#{elem.name}(_c, #{json})\n"
 		else
 			r = "Renderer.Component.getCloneFunction(#{elem.name}, '#{elem.name}')(_c, #{json})\n"
 		if visibleId


Fix bugs

Fix bugs

--- index.coffee
+++ index.coffee
@@ -112,7 +112,7 @@
   track_strategy(context, 'ask_for_acres')
   acres = parseInt context.text.replace(/[\+|\s|\D|\,]/g, '')
   if valid_number(acres) and hammurabi.is_valid_acre(context)
-    console.log("Setting acres: #{acres}")
+    context.text = ''
     context.game_responses.acres = acres
     return no

@@ -126,7 +126,7 @@
   track_strategy(context, 'ask_for_feed')
   feed = parseInt context.text.replace(/[\+|\s|\-|\D|\,]/g, '')
   if valid_number(feed) and hammurabi.is_valid_feed(context)
-    console.log("Setting feed: #{feed}")
+    context.text = ''
     context.game_responses.feed = feed
     return no

@@ -139,7 +139,7 @@
   track_strategy(context, 'ask_for_seed')
   seed = parseInt context.text.replace(/[\+|\s|\-|\D|\,]/g, '')
   if valid_number(seed) and  hammurabi.is_valid_seed(context)
-    console.log("Setting seed: #{seed}")
+    context.text = ''
     context.game_responses.seed = seed
     return no

@@ -194,6 +194,7 @@
   if !context.game_status.ended or !context.game_status.starved
     context.game_responses = {}
     show_game_status(context)
+    ask_for_acres(context)
     return no

   if context.game_status.starved


oh wtf j and k were flipped, yo

oh wtf j and k were flipped, yo

--- index.coffee
+++ index.coffee
@@ -53,8 +53,8 @@

 screen.key ['escape', 'q', 'C-c'], (ch, key) -> process.exit(0)

-screen.key ['j'], (ch, key) -> icon.top += 10
-screen.key ['k'], (ch, key) -> icon.top -= 10
+screen.key ['j'], (ch, key) -> icon.top -= 10
+screen.key ['k'], (ch, key) -> icon.top += 10

 mapScale = .1


`=== this` binding bug fixed

`=== this` binding bug fixed

--- index.coffee
+++ index.coffee
@@ -224,8 +224,11 @@
 				hash += ".#{id}"
 		else
 			text += "#{elem[0]}"
-			hash += "$#{args.length}"
-			args.push elem[0]
+			if elem[0] is "'this'"
+				hash += "this"
+			else
+				hash += "$#{args.length}"
+				args.push elem[0]

 	hash = hash.trim()
 	text = text.trim()
@@ -510,10 +513,8 @@

 	codes

-# console.log module.exports """
-# // ab
-
+# console.log module.exports("""
 # Item {
-# 	id: a
+# 	width: parent.width === this
 # }
-# """#, 'view'
+# """)._neftMain#, 'view'


Trim the value we get back from commit

Trim the value we get back from commit

Shells love newlines

--- index.coffee
+++ index.coffee
@@ -53,7 +53,7 @@
         if err
           done err, null
         else
-          done err, result
+          done err, result.trim()

   # Determine whether the repo is currently in a detached head state
   # This happens when you checkout, for example, a commit hash


autocomplete trigger on down key

autocomplete trigger on down key

git-svn-id: 00f01ee4f729ccc52c3e336777c3e81b5adc88db@249854 ef392f78-ee14-0410-84e5-9db46baae5bb

--- app/scripts/directives.coffee
+++ app/scripts/directives.coffee
@@ -544,7 +544,7 @@

-korpApp.directive "autoc", ($q, $http, lexicons) ->
+korpApp.directive "autoc", ($q, $http, $timeout, lexicons) ->
     replace: true
     restrict: "E"
     scope:
@@ -573,6 +573,7 @@
             </script>

<input
+                    id="korpAutocompleteInput"
                     autofocus
                     type="text"
                     ng-model="textInField"
@@ -581,7 +582,9 @@
                     typeahead-template-url="lemgramautocomplete.html"
                     typeahead-loading="isLoading"
                     typeahead-on-select="selectedItem($item, $model, $label)"
-                    placeholder="{{placeholderToString(placeholder)}}">

+                    placeholder="{{placeholderToString(placeholder)}}"
+                    typeahead-click-open
+                    typeahead-is-open="typeaheadIsOpen">

@@ -678,6 +681,22 @@
                         a.sense.length - b.sense.length
                 deferred.resolve data
             return deferred.promise
+
+
+
+korpApp.directive "typeaheadClickOpen", ($parse, $timeout)->
+    dir =
+        restrict: "A"
+        require: "ngModel"
+        link: ($scope, elem, attrs)->
+            triggerFunc = (event)->
+                if event.keyCode is 40 and not $scope.typeaheadIsOpen
+                    ctrl = elem.controller 'ngModel'
+                    prev = ctrl.$modelValue || ''
+                    if prev
+                        ctrl.$setViewValue ''
+                        $timeout -> ctrl.$setViewValue "#{prev}"
+            elem.bind 'keyup', triggerFunc


add first animal descriptions (some a bit long)

--- app/translations/en_us.coffee
+++ app/translations/en_us.coffee
@@ -196,7 +196,7 @@
     beaver:
       label: 'Beaver'
       description: '''
-        Describe Beaver
+        Usually brown with large sharp front teeth, front feet has claws, back feet are webbed, round body, and a large flat tail. As the second largest rodent in the world, beavers are semi-aquatic and primarily nocturnal. They are known for building dams, canals, and lodges out of tree limbs and branches for homes.
     '''

     bike:
@@ -214,61 +214,61 @@
     chipmunk:
       label: 'Chipmunk'
       description: '''
-        Describe Chipmunk
+        A small member of the squirrel family that use their cheek pouches to carry various foods of nuts, berries, seeds, etc into their burrow or nest to store their food. These have smaller less bushy tails than a typical squirrel and sport signature white and brown stripes around their eye and going down their back. Typically brown or tan in color.
     '''

     coyote:
       label: 'Coyote'
       description: '''
-        Describe Coyote
+        Commonly brown and tan in color, this member of the dog family is smaller than wolves and have occasionally been called prairie wolves or brush wolves due to their wolf like appearance. Although, they differ from wolves with their pointed snouts, slender body, and tall, pointy ears. In the fall and winter they form packs for more effective hunting. Humans should not fear urban coyotes, but take precautions not to feed the animals and keep small pets indoors.
     '''

     deer:
       label: 'Deer'
       description: '''
-        Describe Deer
+        A fairly big, tan animal that is in the same family as moose and reindeer. They have large ears and short fluffy tails. The males are called bucks while females are called does and the young are called fawns. Some males may have antlers depending on the time of the year.
     '''

     domCat:
       label: 'Cat, Domestic'
       description: '''
-        Describe Cat, Domestic
+        A common household pet with a small build, long tails, and small pointed ears. This animals come in a variety of color, patterns (spotted or stripes), and breeds.
     '''

     domDog:
       label: 'Dog, Domestic'
       description: '''
-        Describe Dog, Domestic
+        A common household pet related to wolves, foxes, and jackals, but come in a variety of colors, sizes, patterns, and breeds. Dogs communicate in many different ways; such as scent, facial expressions, body position, and movement.
     '''

     flyingSquirrel:
       label: 'Squirrel, Flying'
       description: '''
-        Describe Squirrel, Flying
+        A member of the squirrel family, this animal has large, dark eyes, loose skin between the front and back legs, clawed feet, and a long, bushy tail with dark fur on top and light below. It travels from tree to tree by launching itself and spreading its limbs so it can glide, while using its legs to steer and its tail to brake when it reaches its destination.
     '''

     foxSquirrel:
       label: 'Squirrel, Fox'
       description: '''
-        Describe Squirrel, Fox
+        The largest species of tree squirrel in North America, they look like a larger typical squirrel with an orange tone to their fur. They can be around 2 feet in length and weight 1 - 2 lbs. It spends most time in forging food  and roaming around fields.
     '''

     grayFox:
       label: 'Fox, Gray'
       description: '''
-        Describe Fox, Gray
+        A small to medium sized animal with gray coat on its back and head with light fur on its chest and belly. They have a signature black tipped, bushy tail and band of black fur from the inner corner of their eyes around the bottom of their snout. They are tree climbers, typically sleep during the day at very rocky locations, and are active during the night.
     '''

     graySquirrel:
       label: 'Squirrel, Gray'
       description: '''
-        Describe Squirrel, Gray
+        Small squirrels that are gray-brown all over their bodies except the white patch along their belly. This animals diet consists of acorns, hickory nuts, maple, walnuts, etc.
     '''

     horse:
       label: 'Horse'
       description: '''
-        Describe Horse
+        A large, muscular animal with a mane of hair along the back of the head and neck. These animals have hooves and a long tail of hair. Males are called stallions, females are mares, and young ones are called foals. Domesticated these animals are used for transportation and competitive sports.
     '''

     human:
@@ -286,13 +286,13 @@
     mink:
       label: 'Mink'
       description: '''
-        Describe Mink
+        Related to otters, weasels, and ferrets, Minks have pointed snouts with dark eyes. They also have clawed feet with webbing and bodies covered in thick brown fur that sheds water quickly. These animals live in semi aquatic habitats.
     '''

     mouse:
       label: 'Mouse'
       description: '''
-        Describe Mouse
+        A very small animal with a long snout, big round ears, and a long hairless tail. This animal can be found in and around grasslands and homes.
     '''

     mower:
@@ -304,13 +304,13 @@
     muskrat:
       label: 'Muskrat'
       description: '''
-        Describe Muskrat
+        This animal normally has brown fur and a black tail with small dark eyes. The furless, scaly tail is half of its total length. When it walks, the tail creates a trail. Their front paws are clawed while in the rear they are semi-webbed clawed feet.
     '''

     opossum:
       label: 'Opossum'
       description: '''
-        Describe Opossum
+        Adept tree climbers with their clawed feet and opposable big toe on rear paw. This animal known for playing dead has a white face with a pink nose,  black eyes, black ears, long tail and long, gray fur on their body.
     '''

     otherVehicle:
@@ -322,43 +322,43 @@
     rabbit:
       label: 'Rabbit'
       description: '''
-        Describe Rabbit
+        Rabbits we see in urban settings have large, dark eyes, long ears pointed upwards, and brown fur with a short, fluffy, white tail.
     '''

     raccoon:
       label: 'Raccoon'
       description: '''
-        Describe Raccoon
+        This brown-gray furry animal looks like it’s wearing a bandit mask with the black patches around its eyes on its white face. Another notable features are its finger like clawed toes and its black-ringed tail with long fur. Raccoons are nocturnal and often seen foraging for food in trash bins.
     '''

     rat:
       label: 'Rat'
       description: '''
-        Describe Rat
+        A large mouse like critter with a pointy nose, round ears, and a long, hairless, pinkish tail. Many people think they only roam the subway and sewers, but its not uncommon to see then running across the street above ground.
     '''

     redFox:
       label: 'Fox, Red'
       description: '''
-        Describe Fox, Red
+        An animal with orange brownish fur along its head and back with and white fur on its belly and typically at the tip of its bushy tail. It’s tail helps it balance just like a cat’s. Some have black fur on the back of its ears and legs. They often hunt for food but can adapt to eating garbage and pet food.
     '''

     skunk:
       label: 'Skunk'
       description: '''
-        Describe Skunk
+        An animal, well known for its stinky spray towards predators, has black with white stripe patterns. It has a single thin, white stripe down the middle of its face and two, thicker white stripes originated at the top of its head running down either side of the back into its thick, bushy tail.
     '''

     woodChuck:
       label: 'Wood Chuck'
       description: '''
-        Describe Wood Chuck
+        This animal is also known as a groundhog. It has a brown furry coat, clawed feets, small eyes and ears, and a short, flat tail.
     '''

     melanisticGraySquirrel:
       label: 'Squirrel, Melanistic Gray'
       description: '''
-        Describe Squirrel, Melanistic Gray
+        Is an animal that has a color morph to change its fur from gray to black. You may occasionally see them during the color changing process, they will appear to be brown and black patchy.
     '''


content edits from LPZ

content edits from LPZ

--- app/translations/en_us.coffee
+++ app/translations/en_us.coffee
@@ -16,11 +16,13 @@

Chicago
 Wildlife Watch

     "
     content: '''
-      Chicago Wildlife Watch is a collaboration between the Lincoln Park Zoo and the Adler Planetarium, born of the desire to get everyone involved in the scientific process. The project aims to achieve a greater understanding of how our urban development affects local biodiversity. Anyone can participate and help us learn about this great city we live in!
+      To find out which animals live in Chicago, we’ve collected more than 1 million photos of wildlife from the Loop to the burbs. To ID them, though, we need your help!
+
+      Chicago Wildlife Watch, developed by Lincoln Park Zoo and the Adler Planetarium, lets everyone help us understand how animals—from coyotes to chipmunks—share this great city.
     '''
     action: 'Get Started'
     currentStatus: '0 classifications by 0 volunteers'
-    preFooterText: "Chicago Wildlife Watch is a collaboration between Lincoln Park Zoo, the Adler Planetarium, and the Zooniverse. Maybe another line about Chicago to pad this out."
+    preFooterText: "Chicago Wildlife Watch is a collaboration between Lincoln Park Zoo, the Adler Planetarium and the Zooniverse."

     stats:
       header: "CHICAGO WILDLIFE WATCH Classification Statistics"
@@ -37,7 +39,7 @@
     question: "Would you like to view Curated or Uncurated data?"
     notification: "These images have been taken by cameras in public spaces"
     description: """
-      If you are using the Chicago Urban Wildlife Watch for educational purposes or with young children, you might want to use our 'Curated' dataset option.  The images in this data set are much more likely to contain an animal, but still require additional classifications to confirm the animal type. For a younger audience, or for a situation where classification time is limited, this may provide a more engaging experience.
+      If you are using Chicago Wildlife Watch for educational purposes or with young children, you might want to use our 'Curated' dataset option.  The images in this data set are much more likely to contain an animal but still require additional classifications to confirm the animal type. For a younger audience, or for a situation where classification time is limited, this may provide a more engaging experience.
     """

   siteIntro:
@@ -55,7 +57,7 @@
       content: "If you need to delete any of your existing marks while viewing an image, simply find your animal in the list below the image and click the 'X' icon"
     s5:
       title: "That's it!"
-      content: "That's it! You may catchup on project updates either on the blog or through speaking with other volunteers. If you need additional help using the interface, click Tutorial within the list of links below the Finish button."
+      content: "That's it! You may catch up on project updates either on the blog or through speaking with other volunteers. If you need additional help using the interface, click Tutorial within the list of links below the Finish button."

   classify:
     deleteAnnotation: 'Delete'
@@ -148,7 +150,7 @@

       confirmWildebeestHeader: 'Looks Good!'
       confirmWildebeest: '''
-        By comparing the animal to the photos here and reading the description below, we can confirm that this is indeed a Gray Squirrel.
+        By comparing the animal to the photos here and reading the description below, we can confirm that this is indeed a gray Squirrel.
         You can flip through the photos to see examples of the animal from multiple angles using the bullets on the right.
       '''

@@ -211,13 +213,13 @@
     beaver:
       label: 'Beaver'
       description: '''
-        This animal is usually brown with large sharp front teeth, clawed front feet, webbed back feet, a round body, and a large flat tail. As the second largest rodent in the world, beavers are semi-aquatic and primarily nocturnal.
+        This animal is usually brown with large sharp front teeth, clawed front feet webbed back feet, a round body and a large flat tail. As the second largest rodent in the world, beavers are semi-aquatic and primarily nocturnal.
       '''

     bike:
       label: 'Bike'
       description: '''
-        N/A. Identifying the frequency of bikes helps us understand  the the impact of human activity on the animal population in this urban habitat.
+        N/A. Identifying the frequency of bikes helps us understand the impact of human activity on the animal population in this urban habitat.
       '''

     car:
@@ -229,13 +231,13 @@
     chipmunk:
       label: 'Chipmunk'
       description: '''
-        A small member of the squirrel family that use their cheek pouches to carry various nuts, berries and seeds into their burrow or nest to store their food. They have smaller, less bushy tails than a typical squirrel and sport signature white and brown stripes around their eye and going down their back. Typically brown or tan in color.
+        A small member of the squirrel family that use its cheek pouch to carry various nuts, berries and seeds into its burrow or nest to store their food. They have smaller, less bushy tails than a typical squirrel and sport signature white-and-brown stripes around their eye and going down their back. Typically brown or tan in color.
       '''

     coyote:
       label: 'Coyote'
       description: '''
-        Commonly brown and tan in color, this member of the dog family is smaller than a wolf. They have occasionally been called prairie wolves or brush wolves due to their wolf like appearance, but they differ from wolves with their pointed snouts, slender body, and tall, pointy ears. In the fall and winter, they form packs for more effective hunting.
+        Commonly brown and tan in color, this member of the dog family is smaller than a wolf. They have occasionally been called prairie wolves or brush wolves due to their wolf-like appearance, but they differ from wolves with their pointed snouts, slender body and tall, pointy ears. In the fall and winter, they form packs for more effective hunting.
       '''

     deer:
@@ -247,13 +249,13 @@
     domCat:
       label: 'Cat, Domestic'
       description: '''
-        A common household pet with a small build, a long tail, and small pointed ears. This animal comes in a variety of color, patterns (spotted or stripes), and breeds.
+        A common household pet with a small build, a long tail and small pointed ears. This animal comes in a variety of color, patterns (spotted or stripes), and breeds.
       '''

     domDog:
       label: 'Dog, Domestic'
       description: '''
-        A common household pet related to wolves, foxes, and jackals. This animal comes in a variety of colors, sizes, patterns, and breeds.
+        A common household pet related to wolves, foxes and jackals. This animal comes in a variety of colors, sizes, patterns and breeds.
       '''

     flyingSquirrel:
@@ -265,13 +267,13 @@
     foxSquirrel:
       label: 'Squirrel, Fox'
       description: '''
-        The largest species of tree squirrel in North America, they look like a larger typical squirrel with an orange tone to their fur. They can be around 2 feet in length and weight 1 - 2 lbs. It spends most of its time forging food and roaming around fields.
+        The largest species of tree squirrel in North America, they look like a larger typical squirrel with an orange tone to their fur. They can be around 2 feet in length and weight 1 - 2 lbs. It spends most of its time forging for food and roaming around fields.
       '''

     grayFox:
       label: 'Fox, Gray'
       description: '''
-        A small to medium sized animal with a gray coat on its back and head with light fur on its chest and belly. They have a signature black tipped, bushy tail and a band of black fur from the inner corner of their eyes around the bottom of their snout. They are tree climbers, typically sleep during the day at very rocky locations, and are active during the night.
+        A small to medium-sized animal with a gray coat on its back and head with light fur on its chest and belly. They have a signature black-tipped, bushy tail and a band of black fur from the inner corner of their eyes around the bottom of their snout. They are tree climbers, typically sleep during the day at very rocky locations and are active during the night.
       '''

     graySquirrel:
@@ -301,13 +303,13 @@
     mink:
       label: 'Mink'
       description: '''
-        Related to otters, weasels, and ferrets, Minks have pointed snouts with dark eyes. They also have clawed feet with webbing and bodies covered in thick brown fur that sheds water quickly. These animals live in semi aquatic habitats.
+        Related to otters, weasels and ferrets, minks have pointed snouts with dark eyes. They also have clawed feet with webbing and bodies covered in thick brown fur that sheds water quickly. These animals live in semi-aquatic habitats.
       '''

     mouse:
       label: 'Mouse'
       description: '''
-        A very small animal with a long snout, big round ears, and a long hairless tail. This animal can be found in and around grasslands and homes.
+        A very small animal with a long snout, big round ears and a long hairless tail. This animal can be found in and around grasslands and homes.
       '''

     mower:
@@ -325,7 +327,7 @@
     opossum:
       label: 'Opossum'
       description: '''
-        Adept tree climbers with their clawed feet and opposable big toe on rear paw. This animal is known for playing dead and has a white face with a pink nose, black eyes, black ears, long tail and long, gray fur on their body.
+        Adept tree climbers with their clawed feet and opposable big toe on rear paw. This animal is known for playing dead and has a white face with a pink nose, black eyes, black ears, long tail and long, gray fur on its body.
       '''

     otherVehicle:
@@ -337,31 +339,31 @@
     rabbit:
       label: 'Rabbit'
       description: '''
-        Rabbits we see in urban settings have large, dark eyes, long ears pointed upwards, and brown fur with a short, fluffy, white tail.
+        Rabbits we see in urban settings have large, dark eyes, long ears pointed upwards and brown fur with a short, fluffy, white tail.
       '''

     raccoon:
       label: 'Raccoon'
       description: '''
-        This brown-gray furry animal looks like it is wearing a bandit mask with the black patches around its eyes on its white face. Another notable features are its finger like clawed toes and its black-ringed tail with long fur. Raccoons are nocturnal and often seen foraging for food in trash bins.
+        This brown-gray furry animal looks like it is wearing a bandit mask with the black patches around its eyes on its white face. Another notable features are its finger-like clawed toes and its black-ringed tail with long fur. Raccoons are nocturnal and often seen foraging for food in trash bins.
       '''

     rat:
       label: 'Rat'
       description: '''
-        A large mouse-like critter with a pointy nose, round ears, and a long, hairless, pinkish tail. Many people think they only roam the subway and sewers, but it is not uncommon to see then running across the street above ground.
+        A large mouse-like critter with a pointy nose, round ears and a long, hairless, pinkish tail. Many people think they only roam the subway and sewers, but it is not uncommon to see then running across the street above ground.
       '''

     redFox:
       label: 'Fox, Red'
       description: '''
-        An animal with orange brownish fur along its head and back with and white fur on its belly and typically at the tip of its bushy tail. Its tail helps it balance just like a cat’s. Some have black fur on the back of its ears and legs.
+        An animal with orange brownish fur along its head and back and white fur on its belly and typically at the tip of its bushy tail. Its tail helps it balance just like a cat’s. Some have black fur on the back of their ears and legs.
       '''

     skunk:
       label: 'Skunk'
       description: '''
-        An animal well known for its stinky spray towards predators and black coat with white stripe patterns. It has a single thin, white stripe down the middle of its face and two, thicker white stripes originated at the top of its head running down either side of the back into its thick, bushy tail.
+        An animal well known for its stinky spray towards predators and black coat with white stripe patterns. It has a single thin, white stripe down the middle of its face and two thicker white stripes originating at the top of its head running down either side of the back into its thick, bushy tail.
       '''

     woodChuck:
@@ -373,7 +375,7 @@
     melanisticGraySquirrel:
       label: 'Squirrel, Melanistic Gray'
       description: '''
-        This animal has a color morph to change its fur from gray to black. You may occasionally see them during the color changing process when they will appear to be brown and black patchy.
+        This animal has a color morph to change its fur from gray to black. You may occasionally see them during the color-changing process when they will appear to be patchy brown and black.
       '''

   differences:
@@ -627,7 +629,7 @@
           Cities can be hostile places for wildlife, with threats coming from habitat destruction, roads and traffic, humans, pets and large numbers of invasive species. However, with proper management, urban areas can house a number of important wildlife species, including carnivores and small mammals.

-          To assess the biodiversity of the greater Chicagoland area, Lincoln Park Zoo’s Urban Wildlife Institute has established monitoring stations within city parks, forest preserves, golf courses and cemeteries in parts of Cook, Lake, DuPage and Will counties including downtown Chicago. Motion-triggered cameras are deployed four times per year at more than 100 sites to determine which species are present and to assess spatial and long-term patterns in wildlife communities.
+          To assess the biodiversity of the greater Chicagoland area, Lincoln Park Zoo’s Urban Wildlife Institute has established monitoring stations within city parks, forest preserves, golf courses and cemeteries in parts of Cook, Lake, DuPage and Will Counties including downtown Chicago. Motion-triggered cameras are deployed four times per year at more than 100 sites to determine which species are present and to assess spatial and long-term patterns in wildlife communities.

           Knowing where Chicago’s urban wildlife is located will help us to better conserve it. This knowledge will pave the way for future studies on the behavior and ecology of specific urban species, helping stakeholders to better manage wildlife conflict.
@@ -644,11 +646,11 @@
         Finding out where certain species are most likely to occur allows us to target conservation and management efforts to ensure we can coexist with our wildlife neighbors.

How are they doing?

-
While we can’t directly measure populations with the data from our cameras, we can get a sense of which species are most common, and which may be in decline.
+
While we can’t directly measure populations with the data from our cameras, we can get a sense of which species are most common and which may be in decline.
         This can help us make recommendations about how to improve conditions for the species that are in trouble.

How do they compete?

-
We know almost nothing about how species in urban areas might compete with one another, engage in predator-prey dynamics, or avoid each other.
+
We know almost nothing about how species in urban areas might compete with one another, engage in predator-prey dynamics or avoid each other.
         Preliminary results indicate that the normal community interactions we observe in natural systems don’t apply to urban areas, where entirely new dynamics seem to be in place.
         By evaluating our camera images, we can begin to assemble the first complete picture of an urban ecosystem, including how all the species interact.

@@ -695,7 +697,7 @@
         header: "Lincoln Park Zoo"
         p: """

-          Lincoln Park Zoo is a world of wildlife in the shadow of skyscrapers. Located within a verdant park just minutes north of Chicago, the zoo has been a natural, free oasis for generations of animal lovers, who visit the zoo to hear a lion’s roar echo off nearby apartment buildings, see gorillas climb trees as the Willis Tower looms in the distance, or forget where they are as they immerse themselves in tropical rainforests, dry-thorn forests or spacious savannas.

+          Lincoln Park Zoo is a world of wildlife in the shadow of skyscrapers. Located within a verdant park just minutes north of Chicago, the zoo has been a natural, free oasis for generations of animal lovers, who visit the zoo to hear a lion’s roar echo off nearby apartment buildings, see gorillas climb trees as the Willis Tower looms in the distance or forget where they are as they immerse themselves in tropical rainforests, dry-thorn forests or spacious savannas.

           Lincoln Park Zoo is dedicated to connecting people with nature by providing a free, family-oriented wildlife experience in the heart of Chicago and by advancing the highest quality of animal care, education, science and conservation.
         """
@@ -740,7 +742,7 @@
           name: 'Heath Van Singel'
           image: 'http://placehold.it/100'
           description: '''
-
Heath is the UX/UI Designer for projects at the Zooniverse where he works to craft thoughtful and engaging user experiences. Apart from design Heath also enjoys illustration, a good sci-fi or fantasy novel, and trips back to Michigan.

+
Heath is the UX/UI Designer for projects at the Zooniverse, where he works to craft thoughtful and engaging user experiences. Apart from design Heath also enjoys illustration, a good sci-fi or fantasy novel, and trips back to Michigan.

           '''

         weiksnar:
@@ -748,22 +750,22 @@
           image: 'images/about/team/michael.jpg'
           description: '''

Alex currently works as a front-end developer for the Zooniverse out of the Adler Planetarium. He spends his time building rich and engaging user interfaces for the web.
-           Alex previously attended University of Miami, where he studied Psychology, Biology, and English.
+           Alex previously attended University of Miami, where he studied psychology, biology and English.

           '''

         whyte:
-          name: 'Laura Whyte'
+          name: 'Dr. Laura Whyte'
           title: 'Director of Citizen Science at Adler Planetarium'
           image: 'http://placehold.it/100'
           description: '''
-
The citizen science department at the Adler Planetarium is home to a development team who design and build Zooniverse websites - the worlds largest and most successful collection of citizen science projects. This team, who bring expertise in technology, education, science outreach and research, reach beyond the internet into the local community through school visits, youth programs and hack days events. As former astronomer, high school teacher, museum educator, and web developer, Dr. Whyte leads these initiatives and the opportunity they bring to engage a wider Chicago audience in actively doing science.

+
The citizen science department at the Adler Planetarium is home to a development team who design and build Zooniverse websites - the worlds largest and most successful collection of citizen science projects. This team, who bring expertise in technology, education, science outreach and research, reach beyond the internet into the local community through school visits, youth programs and hack days events. As former astronomer, high school teacher, museum educator, and web developer, Laura leads these initiatives and the opportunity they bring to engage a wider Chicago audience in actively doing science.

           '''
     connect:
       header: "Connect"
       action: "Get Started"
       social: """
-        Follow the Adler Planetarium [Blog / Twitter] and Lincoln Park Zoo Urban Wildlife Institute [Blog / Twitter] to keep current with the latest findings!
+        Follow the Adler Planetarium [Blog / Twitter] and Lincoln Park Zoo Urban Wildlife Institute [Blog / Twitter] to keep current with the latest findings!
       """

   education:
@@ -772,18 +774,17 @@
       nav: "Overview"
       header: "Can I use Chicago Wildlife Watch in the classroom?"
       p: """
-        Absolutely! Chicago Wildlife Watch, just like all the Zooniverse projects, offers a unique opportunity to explore real scientific data, while making a contribution to cutting edge research. We would like to stress that as each image is marked by the volunteers, it really does not matter if your students don't mark all the features. That being said, the task itself is simple enough that we believe most people can take part and make a worthwhile contribution regardless of age.
+        Absolutely! Chicago Wildlife Watch, just like all the Zooniverse projects, offers a unique opportunity to explore real scientific data while making a contribution to cutting-edge research. We would like to stress that as each image is marked by the volunteers, it really does not matter if your students don't mark all the features. That being said, the task itself is simple enough that we believe most people can take part and make a worthwhile contribution regardless of age.
       """
     resources:
       nav: "Resources"
       header: "What resources are there to support use in the classroom?"
       content: """
-
Over the Summer of 2014, teen interns at Adler Planetarium developed a floor activity to bring awareness to the fact that nature is everywhere and we live in nature. A Lesson plan for this activity can be found on ZooTeach

+
Over the summer of 2014, teen interns at Adler Planetarium developed a floor activity to bring awareness to the fact that nature is everywhere and we live in nature. A Lesson plan for this activity can be found on ZooTeach

Videos are also a great tool to introduce students to Chicago Wildlife Watch. Here are a couple of our favorites:

-
Bill Nye: The Science Guy - Biodiversity

 TropicMind.com: Ecosystem and Food Chain (aimed for younger children)

@@ -794,7 +795,7 @@
       nav: "Partner Resouces"
       header: "Partner resources"
       content: """
-
Please visit Lincoln Park Zoo's Educator's Resources  webpage to access curriculum guides, Zoo field trip and self-tour information, accessibility  kits, and links to several multi-media apps.
+
Please visit Lincoln Park Zoo's Educator's Resources  webpage to access curriculum guides, zoo field trip and self-tour information, accessibility  kits and links to several multi-media apps.

The Adler Planetarium is dedicated to helping the public experience science and discover the universe through field trips, school partnerships, child and teen programming. See the Teach and Learn section of the Adler's website for details.
@@ -804,5 +805,5 @@
     aside:
       content: """

Connect with Education

-
The Chicago Wildlife Watch blog, as well as the partner Facebook pages below, are great places to keep up to date with the latests science results, but there is also a Zooniverse Education Blog as well as a @ZooTeach Twitter feed. The Urban Wildlife Institute also has a twitter account, @LPZ_UWI that you can follow for more information on their work.

+
The Chicago Wildlife Watch blog, as well as the partner Facebook pages below, are great places to keep up to date with the latest science results, but there is also a Zooniverse Education Blog as well as a @ZooTeach Twitter feed. The Urban Wildlife Institute also has a Twitter account, @LPZ_UWI, that you can follow for more information on their work.

       """


Remove debug output

Remove debug output

--- apps/client-cli/engine.coffee
+++ apps/client-cli/engine.coffee
@@ -22,30 +22,19 @@
     if method is 'GET' and postData
       options.path += '?' + postData

-    #console.log """
-    #    client.send
-    #      method: #{options.method}
-    #      path: #{options.path}
-    #      data: #{postData}
-    #  """
-
     if method is 'POST' or method is 'PUT'
       options.headers =
         'Content-Type': 'application/x-www-form-urlencoded'
         'Content-Length': postData.length

-    console.log 'options: ', options
-
     request = http.request options, (result) =>
-      console.log 'req status: ' + result.statusCode
-      console.log 'req headers: ' + JSON.stringify result.headers
       fullResponse = ""
       result.setEncoding 'utf8'
       result.on 'data', (chunk) -> fullResponse += chunk
       result.on 'end', -> callback JSON.parse fullResponse

     request.on 'error', (e) ->
-      console.log "client.send error: ", e
+      console.log "\n\nclient.send error: ", e

     if method is 'POST' or method is 'PUT'
       request.write postData


Invoke callback

Invoke callback

--- workers/social/lib/social/models/collaboration.coffee
+++ workers/social/lib/social/models/collaboration.coffee
@@ -83,6 +83,8 @@

       notifyByUsernames options.target, 'CollaborationInvitation', data

+      callback()
+

   @kick = secure (client, workspaceId, target, callback) ->


social: instead of message use Module

social: instead of message use Module

--- workers/social/lib/social/models/rewards/index.coffee
+++ workers/social/lib/social/models/rewards/index.coffee
@@ -7,7 +7,7 @@
 async       = require 'async'
 KONFIG      = require 'koding-config-manager'

-module.exports = class JReward extends jraphical.Message
+module.exports = class JReward extends jraphical.Module

   { Relationship } = jraphical


Removendo o +1 no contador...

Removendo o +1 no contador...

--- recipes/copa2014/assets/counter.coffee
+++ recipes/copa2014/assets/counter.coffee
@@ -9,7 +9,7 @@
     t = new Date()
     c = new Date(2014, 5, 12, 0, 0, 0)
     h = ""
-    e = String(Math.round(Math.abs((t.getTime() - c.getTime()) / (24 * 60 * 60 * 1000))) + 1)
+    e = String(Math.round(Math.abs((t.getTime() - c.getTime()) / (24 * 60 * 60 * 1000))))
     a = (e).split("")

     i = 0
@@ -20,6 +20,6 @@
     if t.getTime() < c.getTime()
       if parseInt(e) > 1
         r.innerHTML = "Faltam " + h + " dias para a Copa"
-      else r.innerHTML = "Amanhã começa a Copa!"  if parseInt(e) is 1
+      else r.innerHTML = "Amanhã começa a Copa!"  if parseInt(e) is 1
     return


fallback to firstName lastName when particle parser drops data on the floor #313

--- resource/translators/translator.coffee
+++ resource/translators/translator.coffee
@@ -358,8 +358,8 @@
         name = (part.replace(/,/g, '{,}') for part in name).join(', ')

         if fallback
-          name = (part.replace(/,!/g, ',').replace(/,/g, '{,}') for part in [creator.firstName + ' ' + creator.lastName] when part).join(' ')
-          name = @enc_latex({value: name}).replace(/ and /g, ' {and} ')
+          name = (part.replace(/,!/g, ',') for part in [creator.firstName + ' ' + creator.lastName] when part).join(' ')
+          name = @enc_latex({value: name}).replace(/ and /g, ' {and} ').replace(/,/g, '{,}')

       else
         continue


Activity: prevent going to top when show previous comments link clicked

--- client/Social/Activity/views/comments/view.coffee
+++ client/Social/Activity/views/comments/view.coffee
@@ -29,7 +29,9 @@
       .on 'RemoveReply', @controller.lazyBound 'removeItem', null

-  listPreviousReplies: ->
+  listPreviousReplies: (event) ->
+
+    KD.utils.stopDOMEvent event

     @emit 'AsyncJobStarted'


ComputeController: Disable reinit if machine.provider is aws.

--- client/app/lib/providers/computecontroller.coffee
+++ client/app/lib/providers/computecontroller.coffee
@@ -477,9 +477,9 @@
       destroy machine

-  reinit: (machine, snapshotId)->
-
-    return if methodNotSupportedBy machine
+  reinit: (machine, snapshotId) ->
+
+    return  if methodNotSupportedBy(machine) or machine.provider is 'aws'

     startReinit = =>


(test: invalid card details) - alignment problem solved

--- client/test/lib/pricing/invalidCardDetails.coffee
+++ client/test/lib/pricing/invalidCardDetails.coffee
@@ -1,12 +1,12 @@
 helpers = require '../helpers/helpers.js'
 assert  = require 'assert'

-upgradePlanLink 	  = '.avatararea-popup .kdview [href="/Pricing"]'
-upgradePlanButton	  = '.kdmodal-inner .green'
-upgradePlanName     = '.plan-name'
-tooltipValidation   = '.kdtooltip'
+upgradePlanLink   = '.avatararea-popup .kdview [href="/Pricing"]'
+upgradePlanButton = '.kdmodal-inner .green'
+upgradePlanName   = '.plan-name'
+tooltipValidation = '.kdtooltip'

-freePlanSelector    = '.single-plan.free.current'
+freePlanSelector  = '.single-plan.free.current'

 module.exports =
@@ -76,7 +76,7 @@
       .element 'css selector', freePlanSelector, (result) ->
         if result.status is 0
           helpers.selectPlan(browser, 'developer')
-          .waitForElementVisible       upgradePlanName, 10000
+          .waitForElementVisible      upgradePlanName, 10000
           .assert.containsText        upgradePlanName, 'Developer Plan'
           .assert.containsText        '.cardmonth .exp-date', 'Exp. Date'
           .setValue                   cardMonthInputField, '88'


Made method private

Made method private

--- core/app/backbone/factlink/text_input_view.coffee
+++ core/app/backbone/factlink/text_input_view.coffee
@@ -1,7 +1,7 @@
 Backbone.Factlink ||= {}
 class Backbone.Factlink.TextInputView extends Backbone.Marionette.ItemView
   events:
-    'keydown .typeahead': 'parseKeyDown'
+    'keydown .typeahead': '_parseKeyDown'
     'keyup .typeahead': '_updateModel'
     'input .typeahead': '_updateModel'

@@ -23,7 +23,7 @@
   focusInput: ->
     _.defer => @ui.inputField.focus()

-  parseKeyDown: (e) ->
+  _parseKeyDown: (e) ->
     eventHandled = false
     switch e.keyCode
       when 13 then @trigger 'return'


Create new project when state doesn't return a Project

--- src/atom.coffee
+++ src/atom.coffee
@@ -120,11 +120,10 @@

   deserializeProject: ->
     Project = require './project'
-    state = @getWindowState()
-    @project = state.get('project')
-    unless @project?
+    @project = @getWindowState('project')
+    unless @project instanceof Project
       @project = new Project(path: @getLoadSettings().initialPath)
-      state.set('project', @project)
+      @setWindowState('project', @project)

   deserializeRootView: ->
     RootView = require './root-view'


:art:

:art:

--- src/atom.coffee
+++ src/atom.coffee
@@ -724,7 +724,7 @@
   assert: (condition, message, metadata) ->
     return true if condition

-    error = new Error("Assertion failed: " + message)
+    error = new Error("Assertion failed: #{message}")
     Error.captureStackTrace(error, @assert)

     if metadata?


Fix cursor position.

Fix cursor position.

--- src/base.coffee
+++ src/base.coffee
@@ -79,14 +79,18 @@
 Generator::templateAndOpen = (template, filepath) ->
 	filepath = template  unless filepath
 	@stopIfExists filepath
+
 	contents = @process template
+
 	curpos = undefined
 	if contents.indexOf '®' isnt -1
 		curpos = @getCursorPosition contents
 		contents = contents.replace /®/, ''

 	@write filepath, contents
-	@openInEditor filepath, curpos
+
+	process.nextTick =>
+		@openInEditor filepath, curpos

 ###
 Finds “cursor” position in template: line and column of “®” symbol.


Fix cell value

Fix cell value

--- src/cell.coffee
+++ src/cell.coffee
@@ -46,10 +46,10 @@
 		"value":
 			get: ->
 				switch @_.type
-					when null,undefined
+					when "s"
+						@workbook._.sst.get(@_.value)
+					else
 						@_.value
-					else
-						@workbook._.sst.get(@_.value)

 			set: (val) ->
 				switch typeof val


Use correct error variable names

Use correct error variable names

--- src/cson.coffee
+++ src/cson.coffee
@@ -92,14 +92,14 @@
     parseObject(objectPath, fs.readFileSync(objectPath, {encoding: 'utf8'}))

   readObject: (objectPath, callback) ->
-    fs.readFile objectPath, {encoding: 'utf8'}, (err, contents) =>
+    fs.readFile objectPath, {encoding: 'utf8'}, (error, contents) =>
       if error?
         callback?(error)
       else
         try
           callback?(null, parseObject(objectPath, contents))
-        catch err
-          callback?(err)
+        catch parseError
+          callback?(parseError)

   writeObjectSync: (objectPath, object) ->
     if path.extname(objectPath) is '.cson'


extract beaches, vineyards and parks

extract beaches, vineyards and parks

--- src/data.coffee
+++ src/data.coffee
@@ -108,6 +108,7 @@

 landuseType = (o) ->
   switch o.tags.natural
+    when 'beach'        then return 'beach'
     when 'heath'        then return 'heath'
     when 'rock'         then return 'rock'
     when 'scrub'        then return 'scrub'
@@ -125,6 +126,10 @@
     when 'orchard'      then return 'orchard'
     when 'quarry'       then return 'quarry'
     when 'residential'  then return 'residential'
+    when 'vineyard'     then return 'vineyard'
+
+  switch o.tags.leisure
+    when 'park'         then return 'park'

 query = (bbox) ->
@@ -143,6 +148,8 @@
     'relation["landuse"~""]'
     'way["natural"~""]'
     'relation["natural"~""]'
+    'way["leisure"="park"]'
+    'relation["leisure"="park"]'
   ]
   overpassBbox = [bbox[1], bbox[0], bbox[3], bbox[2]]
   item = (f) -> "#{f}(#{overpassBbox});"


rename draw-world

rename draw-world

--- src/draw.coffee
+++ src/draw.coffee
@@ -14,7 +14,7 @@
       dict['d'] = path
       SVG.path dict

-  draw_child = (world) ->
+  draw_world = (world) ->
     SVG.g {
       class: ['draw_child', "#{world}"]
       transform: world.bind -> world.get('transform')
@@ -28,7 +28,4 @@
     class: 'svg_grid'
     width: grid_size
     height: grid_size
-  }, _.flatten [
-    world.map_child (section) ->
-      section.map_child draw_child
-  ]
+  }, world.map_child draw_world


Nest draw-path

Nest draw-path

--- src/draw.coffee
+++ src/draw.coffee
@@ -21,5 +21,6 @@
     height: grid_size
   }, _.flatten [
     world.get('grid').map draw_path
-    world.get('turtles').get('children').map draw_path
+    world.get('turtles').get('children').map (label, world) ->
+      draw_path(label,world)
   ]


Defer heavy requires until they are used

--- src/file.coffee
+++ src/file.coffee
@@ -4,8 +4,8 @@
 _ = require 'underscore-plus'
 {Emitter} = require 'emissary'
 fs = require 'fs-plus'
-Q = require 'q'
-runas = require 'runas'
+Q = null # Defer until used
+runas = null # Defer until used

 Directory = null
 PathWatcher = require './main'
@@ -123,6 +123,7 @@
     if not @exists()
       promise = Q(null)
     else if not @cachedContents? or flushCache
+      Q ?= require 'q'
       deferred = Q.defer()
       promise = deferred.promise
       content = []
@@ -167,6 +168,7 @@
       fs.writeFileSync(filePath, text)
     catch error
       if error.code is 'EACCES' and process.platform is 'darwin'
+        runas ?= require 'runas'
         # Use dd to read from stdin and write to filePath, same thing could be
         # done with tee but it would also copy the file to stdout.
         unless runas('/bin/dd', ["of=#{filePath}"], stdin: text, admin: true) is 0


fix glitch associated with disappearing cannonball while multiple enemies are present

--- src/game.coffee
+++ src/game.coffee
@@ -170,6 +170,7 @@
     @updateEnemies()
     @updateProjectiles()
     @handleCollisions()
+    @randomAddEnemy()

   render: ->
     @renderBackground()
@@ -212,23 +213,27 @@
   handleCollisions: ->
     for projectile of @projectiles
       for enemy of @enemies
-        if @isCollision @projectiles[projectile], @enemies[enemy]
+		# this first antecident fixes a glitch
+        if (@projectiles[projectile] != undefined) and (@isCollision @projectiles[projectile], @enemies[enemy])
           @killEnemy @enemies[enemy]
           @removeProjectile @projectiles[projectile]
-          @addEnemy()

   killEnemy: (enemy)->
     @enemies.splice @enemies.indexOf(enemy), 1

   addEnemy: ->
-    @enemies = [@randomEnemyType()]
+    @enemies[@enemies.length] = @randomEnemyType() #problem

   randomEnemyType: ->
     type = Math.floor(Math.random() * 2)
     switch type
       when 0 then return new Enemy @
       when 1 then return new BounceEnemy @
-
+
+  randomAddEnemy: ->
+    if (1 == Math.floor(Math.random() * 100))
+     @addEnemy()
+
   isCollision: (entity1, entity2)->
     points = []
     points.push x: entity1.x + 0.15*entity1.width, y: entity1.y + 0.15*entity1.height


heap optimizations

heap optimizations

--- src/heap.coffee
+++ src/heap.coffee
@@ -4,10 +4,11 @@
   nodes: null
   length: 0
   constructor: (options)->
-    if !options?
-      options = {}
-    @nodes = options.nodes || []
-    @heapify()
+    #if !options?
+      #options = {}
+    #@nodes = options.nodes || []
+    #@heapify()
+    @nodes = []

   pop: ()->
     if @length > 0
@@ -23,21 +24,23 @@
     if content
       length = @length++
       nodes = @nodes
-      nodes[length] =
+      #objects can onyl be part of one heap at a time, bad things happen otherwise
+      content._heapNode = nodes[length] =
         content: content
         value: value
+        index: length
       @bubbleUp(length)

   update: (content, value)->
-    if content?
+    if content? && content._heapNode?
       nodes = @nodes
-      for i, node of nodes
-        if content == node.content
-          break
+      swap = content._heapNode

-      swap = node
+      i = swap.index
       nodes[i] = nodes[0]
+      nodes[i].index = i
       nodes[0] = swap
+      nodes[0].index = 0
       swap.value = value

       sift = 0
@@ -54,7 +57,9 @@
       if nodes[parent].value > nodes[last].value
         swap = nodes[parent]
         nodes[parent] = nodes[last]
+        nodes[parent].index = parent
         nodes[last] = swap
+        nodes[last].index = last
       last = parent

   siftDown: (i)->
@@ -70,16 +75,20 @@
         lesser = if nodes[left].value > nodes[right].value then right else left
         if node.value > nodes[lesser].value
           nodes[i] = nodes[lesser]
+          nodes[i].index = i
           nodes[lesser] = node
+          nodes[lesser].index = lesser
           return lesser
       else if node.value > nodes[left].value
         nodes[i] = nodes[left]
+        nodes[i].index = i
         nodes[left] = node
+        nodes[left].index = left
         return left
     return null

-  heapify: ()->
-    for i in [0..@nodes.length-1]
-      @siftDown(i)
+#  heapify: ()->
+#    for i in [0..@nodes.length-1]
+#      @siftDown(i)

 module.exports = Heap


Added a listener ID for the hear listener

--- src/mail.coffee
+++ src/mail.coffee
@@ -93,5 +93,5 @@
     robot.enter (res) ->
         DeliverMail res

-    robot.hear /./i, (res) ->
+    robot.hear /./i, id: "mail.listen", (res) ->
         DeliverMail res


Update color when the hex <input>’s text is edited

All changes:

- Added a handler for `input` events on the hex input
- Extracted an `updateHexText` function from `redrawSwatch` so that the text is not updated after being changed by the user
- Extracted an `updateSliderCounters` function from `redrawSwatch` to prepare for allowing slider counters to be edited directly
- Extracted a constant `sameColorSquareSize` instead of repeating the value `8` in three places

--- src/main.coffee
+++ src/main.coffee
@@ -62,6 +62,7 @@

 size = 400
+sameColorSquareSize = 8

 height = size
 width = size
@@ -371,11 +372,17 @@
   d3.select('table.sliders .swatch').style {
     'background-color': hex
   }
-  d3.select('#picker .hex').attr 'value', hex
+  updateSliderCounters()
+
+updateSliderCounters = ->
   d3.select('#picker .counter-hue').text        H.toFixed 2
   d3.select('#picker .counter-saturation').text S.toFixed 2
   d3.select('#picker .counter-lightness').text  L.toFixed 2

+updateHexText = ->
+  hex = $.husl.toHex H, S, L
+  d3.select('#picker .hex').property 'value', hex
+

 foreground = makeForeground()
 background = makeBackground()
@@ -407,6 +414,7 @@
   foreground.redraw()
   redrawSliderPositions()
   redrawSwatch()
+  updateHexText()

 sliderHue = d3.slider()
   .min(0)
@@ -415,6 +423,7 @@
     H = value
     foreground.redraw()
     redrawSwatch()
+    updateHexText()

 sliderSaturation = d3.slider()
   .min(0)
@@ -423,6 +432,7 @@
     S = value
     foreground.redraw()
     redrawSwatch()
+    updateHexText()

 sliderLightness = d3.slider()
   .min(0)
@@ -430,16 +440,30 @@
   .on 'slide', (e, value) ->
     L = value
     background.redraw()
-    redrawCanvas(8)
+    redrawCanvas(sameColorSquareSize)
     foreground.redraw()
     redrawSwatch()
+    updateHexText()

 d3.select("#picker div.control-hue").call(sliderHue)
 d3.select("#picker div.control-saturation").call(sliderSaturation)
 d3.select("#picker div.control-lightness").call(sliderLightness)

+stringIsValidHex = (string) ->
+  string.match(/#?[0-9a-f]{6}/)
+
+d3.select("#picker .hex").on 'input', ->
+  if stringIsValidHex(@value)
+    [H, S, L] = $.husl.fromHex @value
+    background.redraw()
+    redrawCanvas(sameColorSquareSize)
+    foreground.redraw()
+    redrawSliderPositions()
+    redrawSwatch()
+
 background.redraw()
-redrawCanvas(8)
+redrawCanvas(sameColorSquareSize)
 foreground.redraw()
 redrawSliderPositions()
 redrawSwatch()
+updateHexText()


Correctly handle WebSocket send errors.

Correctly handle WebSocket send errors.

--- src/main.coffee
+++ src/main.coffee
@@ -167,7 +167,11 @@
       return
     jsonRpc.on 'data', (data) ->
       if socket.readyState is socket.OPEN
-        socket.send JSON.stringify data
+        socket.send (JSON.stringify data), (error) ->
+          if error
+            console.error '[WARN] WebSocket send', error
+            connection.close()
+          return
       return

     socket.on 'error', (error) ->


Make methods private

Make methods private

--- src/pane.coffee
+++ src/pane.coffee
@@ -111,15 +111,15 @@
     else
       @activateItemAtIndex(@items.length - 1)

-  # Public: Returns the index of the current active item.
+  # Returns the index of the current active item.
   getActiveItemIndex: ->
     @items.indexOf(@activeItem)

-  # Public: Makes the item at the given index active.
+  # Makes the item at the given index active.
   activateItemAtIndex: (index) ->
     @activateItem(@itemAtIndex(index))

-  # Public: Makes the given item active, adding the item if necessary.
+  # Makes the given item active, adding the item if necessary.
   activateItem: (item) ->
     if item?
       @addItem(item)


add fixme note

add fixme note

--- app/assets/javascripts/trade/controllers/sandbox_shipments_controller.js.coffee
+++ app/assets/javascripts/trade/controllers/sandbox_shipments_controller.js.coffee
@@ -130,7 +130,7 @@
           shipment.get('_destroyed') == true
           ).forEach (shipment) ->
           shipment.deleteRecord()
-        @get('store').commit()
+        @get('store').commit() #FIXME: IE doesn't call buildURL in rest adapter
         @clearModifiedFlags()
         @transitionToParentController()
         location.reload()


payments: code cleanup

payments: code cleanup

--- client/landing/app/Applications/Groups.kdapplication/Views/groupcreation.coffee
+++ client/landing/app/Applications/Groups.kdapplication/Views/groupcreation.coffee
@@ -59,13 +59,13 @@
     loader.show()

     vmController = KD.getSingleton('vmController')
-    vmController.fetchVMPlans (err, plans)=>
+    vmController.fetchVMPlans (err, plans) =>

       loader.destroy()
       @buttons.next.show()

       @plans = plans
-      {descriptions, hostTypes} = vmController.sanitizeVMPlansForInputs plans
+      { descriptions, hostTypes } = vmController.sanitizeVMPlansForInputs plans

       @addSubView @typeSelector = new KDFormViewWithFields
         cssClass         : "type-selector"


Give focus to search view

Give focus to search view

--- core/app/backbone/views/fact_relations/auto_complete_fact_relations_view.coffee
+++ core/app/backbone/views/fact_relations/auto_complete_fact_relations_view.coffee
@@ -24,8 +24,10 @@
       filtered_search_collection: new FilteredFactRelationSearchResults
       placeholder: 'Search..'

-    @listenTo @_text_input_view, 'focus', @focus
     @listenTo @model, 'change', @queryChanges
+
+  onRender: ->
+    _.defer => @_text_input_view.focusInput()

   addCurrent: ->
     selected_fact_attributes = @_search_list_view.currentActiveModel().attributes
@@ -48,9 +50,6 @@
     @disableSubmit()
     @trigger 'createFactRelation', fact_relation, => @enableSubmit()

-  focus: ->
-    mp_track "Evidence: Search focus"
-
   reset: ->
     @model.set text: ''


Italian translation is now 100% complete and tested.

La traduzione italiana adesso è completa al 100% e testata.

  validation
    package.json validation
      ✓ loads package.json
      ✓ checks locale options list in configSchema in package.json
    cson file validation
      checking template/settings.cson `controls.*._id` according atom config-schema.js
fetching https://raw.githubusercontent.com/atom/atom/v1.22.0-beta0/src/config-schema.js...
        ✓ fetches descriptive part of config-schema.js then compares keys of settings.cson with it (503ms)
      checking each cson files of all locales
        checking locale it
          checking "it/menu_darwin.cson"
            ✓ has no error loading cson
            ✓ has consistent flatten keys with template
            ✓ has no special char in values of cson
          checking "it/menu_linux.cson"
            ✓ has no error loading cson
            ✓ has consistent flatten keys with template
            ✓ has no special char in values of cson
            ✓ has valid hotkey hints if required
          checking "it/menu_win32.cson"
            ✓ has no error loading cson
            ✓ has consistent flatten keys with template
            ✓ has no special char in values of cson
            ✓ has valid hotkey hints if required
          checking "it/context.cson"
            ✓ has no error loading cson
            ✓ has consistent flatten keys with template
            ✓ has no special char in values of cson
          checking "it/settings.cson"
            ✓ has no error loading cson
            ✓ has consistent flatten keys with template
            ✓ has no special char in values of cson
          checking "it/about.cson"
            ✓ has no error loading cson
            ✓ has consistent flatten keys with template
            ✓ has no special char in values of cson
          checking "it/welcome.cson"
            ✓ has no error loading cson
            ✓ has consistent flatten keys with template
            ✓ has no special char in values of cson

  26 passing (576ms)

--- def/it/settings.cson
+++ def/it/settings.cson
@@ -80,15 +80,14 @@
     controls: [
       {
         _id: 'core.allowPendingPaneItems'
-        title: "Allow Pending PaneItems"
-        desc: "Allow items to be previewed without adding them to a pane
-               permanently, such as when single clicking files in the tree view."
+        title: "Consenti Anteprima degli Oggetti dei Pannelli"
+        desc: "Consenti agli oggetti di essere visionati senza dover essere aggiunti
+               permanentemente ad un pannello, come accade per i file della visualizzazione ad albero (es. singolo click)."
       }
       {
         _id: 'core.audioBeep'
-        title: "Audio Beep"
-        desc: "Trigger the system's beep sound when certain actions cannot be
-               executed or there are no results."
+        title: "Beep Sonoro"
+        desc: "Emetti un suono di sistema quando certe azioni falliscono o sono infruttuose."
       }
       {
         _id: 'core.automaticallyUpdate'
@@ -97,13 +96,13 @@
       }
       {
         _id: 'core.autoHideMenuBar'
-        title: "Auto Hide Menu Bar"
-        desc: "Automatically hide the menu bar and toggle it by pressing Alt. This is only supported on Windows & Linux."
+        title: "Nascondi Automaticamente la Barra dei Menu"
+        desc: "Nascondi in automatico la barra dei menu e commutala premendo il tasto 'Alt'. Funzionalità esclusiva di Windows e Linux."
       }
       {
         _id: 'core.closeDeletedFileTabs'
-        title: "Close Deleted File Tabs"
-        desc: "Close corresponding editors when a file is deleted outside Atom."
+        title: "Chiudi Schede dei File Eliminati"
+        desc: "Chiudi gli editor corrispondenti quando un file viene cancellato da fuori Atom."
       }
       {
         _id: 'core.closeEmptyWindows'
@@ -112,293 +111,289 @@
       }
       {
         _id: 'core.destroyEmptyPanes'
-        title: "Destroy Empty Panes"
-        desc: "When the last tab of a pane is closed, remove that pane as well."
+        title: "Distruggi i Pannelli Vuoti"
+        desc: "Quando l'ultima scheda di un pannello viene chiusa, rimuovi anche il pannello stesso."
       }
       {
         _id: 'core.excludeVcsIgnoredPaths'
-        title: "Exclude VCS Ignored Paths"
-        desc: "Files and directories ignored by the current project's VCS system will be ignored by some packages, such as the fuzzy finder and find and replace. For example, projects using Git have these paths defined in the .gitignore file. Individual packages might have additional config settings for ignoring VCS ignored files and folders."
+        title: "Escludi i Percorsi Ignorati dal VCS"
+        desc: "File e directory ignorati dal VCS saranno ignorati anche da alcuni pacchetti, come il 'fuzzy finder' e 'cerca e sostituisci'. Ad esempio, i progetti che usano Git usano i percorsi del file '.gitignore'. I pacchetti individuali possono avere configurazioni proprie addizionali per ignorare i percorsi di VCS."
       }
       {
         _id: 'core.fileEncoding'
-        title: "File Encoding"
-        desc: "Default character set encoding to use when reading and writing files."
+        title: "Codifica dei File"
+        desc: "Codifica di default per la lettura/scrittura dei file."
       }
       {
         _id: 'core.fileSystemWatcher'
-        title: "File System Watcher"
-        desc: "Choose the underlying implementation used to watch for filesystem changes. Emulating changes will miss any events caused by applications other than Atom, but may help prevent crashes or freezes."
+        title: "Osservatore del File System"
+        desc: "Scegli l'implementazione usata sotto il cofano per monitorare i cambiamenti dei file. L'emulazione ignora i cambiamenti effettuati all'esterno di Atom, ma può prevenire crash e blocchi."
         select:
-          native: "Native operating system APIs"
-          atom: "Emulated with Atom events"
+          native: "APIs native del Sistema Operativo"
+          atom: "Emulazione con Eventi Atom"
       }
       {
         _id: 'core.followSymlinks'
-        title: "Follow Symlinks"
-        desc: "Follow symbolic links when searching files and when opening files with the fuzzy finder."
+        title: "Segui Collegamenti Simbolici"
+        desc: "Segui i collegamenti simbolici durante l'accesso ai files e quando si aprono i file con il fuzzy finder."
       }
       {
         _id: 'core.ignoredNames'
-        title: "Ignored Names"
-        desc: "List of glob patterns. Files and directories matching these patterns will be ignored by some packages, such as the fuzzy finder and tree view. Individual packages might have additional config settings for ignoring names."
+        title: "Nomi Ignorati"
+        desc: "Lista dei glob patterns. File e cartelle che corrispondono a questi modelli saranno ignorati da alcuni pacchetti, come il 'fuzzy finder' e la visuale ad albero. I pacchetti individuali potrebbero avere ulteriori settaggi per ignorare i nomi."
       }
       {
         _id: 'core.openEmptyEditorOnStart'
-        title: "Open Empty Editor On Start"
-        desc: "Automatically open an empty editor on startup."
+        title: "Apri un Editor Vuoto all'Avvio"
+        desc: "Apri automaticamente un nuovo editor senza testo all'avvio."
       }
       {
         _id: 'core.packagesWithKeymapsDisabled'
-        title: "Packages With Keymaps Disabled"
+        title: "Pacchetti Con Mappe Caratteri Disabilitate"
       }
       {
         _id: 'core.projectHome'
-        title: "Project Home"
-        desc: "The directory where projects are assumed to be located. Packages created using the Package Generator will be stored here by default."
+        title: "Home dei Progetti"
+        desc: "La directory in cui si presume che i progetti si trovino. I pacchetti creati utilizzando il generatore di pacchetti verranno archiviati per impostazione predefinita."
       }
       {
         _id: 'core.reopenProjectMenuCount'
-        title: "Reopen Project Menu Count"
-        desc: "How many recent projects to show in the Reopen Project menu."
+        title: "Dimensione del Menu Riapri Progetti"
+        desc: "Numero di progetti recenti da visualizzare nel menu Riapri progetto."
       }
       {
         _id: 'core.restorePreviousWindowsOnStart'
         title: "Restore Previous Windows On Start"
-        desc: "When checked restores the last state of all Atom windows when started from the icon or atom by itself from the command line; otherwise a blank environment is loaded."
+        desc: "Quando selezionato, ripristina l'ultimo stato di tutte le finestre di Atom se avviato dall'icona o con il solo atom dalla linea di comando; in caso contrario viene caricato l'ambiente vuoto."
         select:
           no: "no"
-          yes: "yes"
-          always: "always"
+          yes: "si"
+          always: "sempre"
       }
       {
         _id: 'core.telemetryConsent'
-        title: "Send Telemetry to the Atom Team"
-        desc: "Allow usage statistics and exception reports to be sent to the Atom team to help improve the product."
+        title: "Invia la Telemetria al Team di Atom"
+        desc: "Consenti alle statistiche d'uso e alle segnalazioni di errore di pervenire al team di Atom al fine di migliorare il prodotto."
         select:
-          limited: "Allow limited anonymous usage stats, exception and crash reporting"
-          no: "Do not send any telemetry data"
-          undecided: "Undecided (Atom will ask again next time it is launched)"
+          limited: "Consenti statistiche d'uso anonime e limitate, e riferisci eccezioni e crash"
+          no: "Non inviare nessun dato telemetrico"
+          undecided: "Non deciso (Atom chiederà ancora al prossimo avvio)"
       }
       {
         _id: 'core.titleBar'
-        title: "Title Bar"
-        desc: "Experimental: A custom title bar adapts to theme colors. Choosing custom-inset adds a bit more padding. The title bar can also be completely hidden.
Note: Switching to a custom or hidden title bar will compromise some functionality.
This setting will require a relaunch of Atom to take effect."
+        title: "Barra del Titolo"
+        desc: "Sperimentale: Una barra del titolo personalizzata si adatta ai colori del tema. Scegliendo personalizzata-rientrata si aggiunge un po più di spazio interno. La barra del titolo può anche essere celata completamente.
Nota: Passare ad una barra personalizzata o celata comprometterà alcune funzionalità.
Questa impostazione richiederà un riavvio di Atom per avere effetto."
         select:
-          native: "native"
-          custom: "custom"
-          "custom-inset": "custom-inset"
-          hidden: "hidden"
+          native: "nativa"
+          custom: "personalizzata"
+          "custom-inset": "personalizzata-rientrata"
+          hidden: "celata"
       }
       {
         _id: 'core.useProxySettingsWhenCallingApm'
-        title: "Use Proxy Settings When Calling APM"
-        desc: "Use detected proxy settings when calling the apm command-line tool."
+        title: "Usa le Impostazioni del Proxy all'Invocazione di APM"
+        desc: "Quando viene chiamato lo strumento a linea di comando apm, usa le impostazioni rilevate per il proxy."
       }
       {
         _id: 'core.versionPinnedPackages'
-        title: "Version Pinned Packages"
-        desc: "List of names of installed packages which are not automatically updated."
+        title: "Pacchetti con Versione Bloccata"
+        desc: "Lista dei nomi dei pacchetti installati che non saranno aggiornati automaticamente."
       }
       {
         _id: 'core.useCustomTitleBar'
-        title: "Use Custom Title Bar"
-        desc: "Use custom, theme-aware title bar.
Note: This currently does not include a proxy icon.
This setting will require a relaunch of Atom to take effect."
+        title: "Usa la Barra del Titolo Personalizzata"
+        desc: "Usa una barra del titolo personalizzata in base al tema.
Nota: Questa non comprende ancora l'icona del proxy.
Questa impostazione avrà effetto dopo il riavvio di Atom."
       }
       {
         _id: 'core.warnOnLargeFileLimit'
-        title: "Warn On Large File Limit"
-        desc: "Warn before opening files larger than this number of megabytes."
+        title: "Avvisa Al Limite dei File Grandi"
+        desc: "Avvisa prima di aprire file più pesanti di questa quantità di Mb."
       }
       {
         _id: 'editor.atomicSoftTabs'
-        title: "Atomic Soft Tabs"
-        desc: "Skip over tab-length runs of leading whitespace when moving the cursor."
+        title: "Tabulazioni Software Atomiche"
+        desc: "Salta le serie di spazi equivalenti ad una tabulazione durante lo scorrimento."
       }
       {
         _id: 'editor.autoIndent'
-        title: "Auto Indent"
-        desc: "Automatically indent the cursor when inserting a newline."
+        title: "Indentazione Automatica"
+        desc: "Fai rientrare automaticamente il cursore durante la modifica."
       }
       {
         _id: 'editor.autoIndentOnPaste'
-        title: "Auto Indent On Paste"
-        desc: "Automatically indent pasted text based on the indentation of the previous line."
+        title: "Indentazione Automatica Dopo il Copy-Paste"
+        desc: "Indenta automaticamente il testo incollato basandoti sul rientro della linea precedente."
       }
       {
         _id: 'editor.backUpBeforeSaving'
-        title: "Back Up Before Saving"
-        desc: ""
+        title: "Backup Prima di Salvare"
+        desc: "(non è una cattiva idea)"
       }
       {
         _id: 'editor.confirmCheckoutHeadRevision'
-        title: "Confirm Checkout HEAD Revision"
-        desc: "Show confirmation dialog when checking out the HEAD revision and discarding changes to current file since last commit."
+        title: "Conferma Revisione al Checkout dell'HEAD"
+        desc: "Mostra un dialogo di conferma quando si fa il checkout dalla revisione dell'HEAD e si stanno per scartare le modifiche dell'ultimo commit."
       }
       {
         _id: 'editor.fontFamily'
-        title: "Font Family"
-        desc: "The name of the font family used for editor text."
+        title: "Famiglia dei Caratteri"
+        desc: "Il nome della famiglia di caratteri usata dal testo dell'editor."
       }
       {
         _id: 'editor.fontSize'
-        title: "Font Size"
-        desc: "Height in pixels of editor text."
+        title: "Grandezza dei Caratteri"
+        desc: "Altezza in pixel del testo dell'editor."
       }
       {
         _id: 'editor.invisibles.cr'
-        title: "Invisibles Cr"
-        desc: "Character used to render carriage return characters
-               (for Microsoft-style line endings) when the Show
-               Invisibles setting is enabled."
+        title: "Cr Invisibili"
+        desc: "Carattere usato per mostrare i caratteri di ritorno a capo
+               (ritorno stile Microsoft) quando Mostra
+               Invisibili è abilitata."
       }
       {
         _id: 'editor.invisibles.eol'
-        title: "Invisibles Eol"
-        desc: "Character used to render newline characters (\n) when the
-               Show Invisibles setting is enabled."
+        title: "Eol Invisibili"
+        desc: "Caratteri usati per mostrare i caratteri di nuova linea (\n) quando
+               Mostra Invisibili è abilitata."
       }
       {
         _id: 'editor.invisibles.space'
-        title: "Invisibles Space"
-        desc: "Character used to render leading and trailing space characters
-               when the Show Invisibles setting is enabled."
+        title: "Spazi Invisibili"
+        desc: "Caratteri usati per mostrare i caratteri di spazio iniziale e finale
+               quando Mostra Invisibili è abilitato."
       }
       {
         _id: 'editor.invisibles.tab'
-        title: "Invisibles Tab"
-        desc: "Character used to render hard tab characters (\t) when the
-               Show Invisibles setting is enabled."
+        title: "Tabulazioni Invisibili"
+        desc: "Caratteri usati per mostrare i caratteri di tabulazione forzata (\t) quando
+               Mostra Invisibili è abilitata."
       }
       {
         _id: 'editor.lineHeight'
-        title: "Line Height"
-        desc: "Height of editor lines, as a multiplier of font size."
+        title: "Altezza Linea"
+        desc: "Altezza delle linee dell'editor, come moltiplicatore della grandezza dei caratteri."
       }
       {
         _id: 'editor.maxScreenLineLength'
-        title: "Max Screen Line Length"
-        desc: "Defines the maximum width of the editor window before soft wrapping is enforced, in number of characters."
+        title: "Altezza Massima della Linea dello Schermo"
+        desc: "Definisce la larghezza massima della finestra dell'editor prima che il wrapping software venga imposto, e si esprime come numero di caratteri."
       }
       {
         _id: 'editor.nonWordCharacters'
-        title: "Non Word Characters"
-        desc: "A string of non-word characters to define word boundaries."
+        title: "Caratteri Non Lessicali"
+        desc: "Una stringa di caratteri che non fanno parte di nessuna parola, per definire i limiti delle parole stesse."
       }
       {
         _id: 'editor.preferredLineLength'
-        title: "Preferred Line Length"
-        desc: "Identifies the length of a line which is used when wrapping text
-               with the Soft Wrap At Preferred Line Length setting
-               enabled, in number of characters."
+        title: "Lunghezza Preferita della Linea"
+        desc: "Identifica la lunghezza di una linea che viene utilizzata quando si fa il wrapping del testo
+			   con l'impostazione Wrapping Software Alla Lunghezza Linea Preferita
+               attiva, in numero di caratteri."
       }
       {
         _id: 'editor.scrollPastEnd'
-        title: "Scroll Past End"
-        desc: "Allow the editor to be scrolled past the end of the last line."
+        title: "Scrolla Oltre la Fine"
+        desc: "Consenti all'editor di venire scrollato oltre la fine del documento."
       }
       {
         _id: 'editor.scrollSensitivity'
-        title: "Scroll Sensitivity"
-        desc: "Determines how fast the editor scrolls when using a mouse or
-               trackpad."
+        title: "Sensibilità dello Scrolling"
+        desc: "Determina quanto viene scrollato velocemente l'editor quando si usa un mouse o un trackpad."
       }
       {
         _id: 'editor.showCursorOnSelection'
-        title: "Show Cursor On Selection"
-        desc: "Show cursor while there is a selection."
+        title: "Mostra Cursore Sulla Selezione"
+        desc: "Mostra il cursore quando ci si trova in una selezione."
       }
       {
         _id: 'editor.showIndentGuide'
-        title: "Show Indent Guide"
-        desc: "Show indentation indicators in the editor."
+        title: "Mostra Guida Indentazione"
+        desc: "Mostra indicatori del rientro nell'editor."
       }
       {
         _id: 'editor.showInvisibles'
-        title: "Show Invisibles"
-        desc: "Render placeholders for invisible characters, such as tabs,
-               spaces and newlines."
+        title: "Mostra Invisibili"
+        desc: "Mostra dei segnaposto per i caratteri invisibili, come tabulazioni,
+               spazi e caratteri di nuova linea (a capo)."
       }
       {
         _id: 'editor.showLineNumbers'
-        title: "Show Line Numbers"
-        desc: "Show line numbers in the editor's gutter."
+        title: "Mostra Numeri di Linea"
+        desc: "Mostra i numeri di linea al bordo dell'editor."
       }
       {
         _id: 'editor.softTabs'
-        title: "Soft Tabs"
-        desc: "If the Tab Type config setting is set to \"auto\"
-               and autodetection of tab type from buffer content fails, then
-               this config setting determines whether a soft tab or a hard tab
-               will be inserted when the Tab key is pressed."
+        title: "Tabulazioni Software"
+        desc: "Se il Tipo di Tabulazione è impostato su \"auto\"
+               è il rilevamento del tipo di tabulazione del contenuto fallisce, allora
+               questa impostazione determina quando viene usata la tabulazione software o quella rigida
+               alla pressione del tasto Tab."
       }
       {
         _id: 'editor.softWrap'
-        title: "Soft Wrap"
-        desc: "Wraps lines that exceed the width of the window. When
-               Soft Wrap At Preferred Line Length is set, it will
-               wrap to the number of characters defined by the Preferred
-               Line Length setting."
+        title: "Wrapping Software"
+        desc: "Manda a capo le linee che eccedono la dimensione della finestra. Quando
+               Wrapping Software Alla Lunghezza Linea Preferita è impostato,
+               andrà a capo secondo l'impostazione Lunghezza Linea Preferita."
       }
       {
         _id: 'editor.softWrapAtPreferredLineLength'
-        title: "Soft Wrap At Preferred Line Length"
-        desc: "Instead of wrapping lines to the window's width, wrap lines to
-               the number of characters defined by the Preferred Line
-               Length setting. This will only take effect when the soft
-               wrap config setting is enabled globally or for the current
-               language. Note: If you want to hide the wrap
-               guide (the vertical line) you can disable the
-               wrap-guide package."
+        title: "Wrapping Software Alla Lunghezza Linea Preferita"
+        desc: "Invece di andare a capo alla larghezza delle finestra, va a capo
+               al numero di caratteri definito dall'impostazione Lunghezza Linea Preferita.
+               Questo avrà effetto solo se il wrapping software è attivo globalmente o per il linguaggio attuale.
+               Nota: Se vuoi nascondere la guida per il wrapping (la linea verticale) puoi
+               disattivare il pacchetto wrap-guide."
       }
       {
         _id: 'editor.softWrapHangingIndent'
-        title: "Soft Wrap Hanging Indent"
-        desc: "When soft wrap is enabled, defines length of additional
-               indentation applied to wrapped lines, in number of characters."
+        title: "Fai il Wrapping Software dell'Indentazione Pendente"
+        desc: "Quando il wrapping software è attivo, definisce la lunghezza
+               del rientro applicato alle linee ripiegate, in numero di caratteri."
       }
       {
         _id: 'editor.tabLength'
-        title: "Tab Length"
-        desc: "Number of spaces used to represent a tab."
+        title: "Lunghezza Tabulazione"
+        desc: "Numero di spazi che rappresenta una tabulazione."
       }
       {
         _id: 'editor.tabType'
-        title: "Tab Type"
-        desc: "Determine character inserted when Tab key is pressed. Possible
-               values: \"auto\", \"soft\" and \"hard\". When set to \"soft\" or
-               \"hard\", soft tabs (spaces) or hard tabs (tab characters) are
-               used. When set to \"auto\", the editor auto-detects the tab type
-               based on the contents of the buffer (it uses the first leading
-               whitespace on a non-comment line), or uses the value of the Soft
-               Tabs config setting if auto-detection fails."
+        title: "Tipo di Tabulazione"
+        desc: "Determina il carattere inserito quando il tasto Tab viene premuto. Possibili
+               valori: \"auto\", \"soft\" e \"hard\". Quando impostato su \"soft\" o su
+               \"hard\", vengono utilizzate tabulazioni software (spazi) o tabulazioni rigide (caratteri di tabulazione).
+               Quando impostato su \"auto\", l'editor deduce automaticamente il tipo di tabulazione
+               basandosi sul contenuto della memoria temporanea (usa il primo spazio bianco iniziale
+               rispetto ad una linea che non è un commento), o usa il valore dell'impostazione
+               Tabulazione Software se il rilevamento fallisce."
       }
       {
         _id: 'editor.undoGroupingInterval'
-        title: "Undo Grouping Interval"
-        desc: "Time interval in milliseconds within which text editing
-               operations will be grouped together in the undo history."
+        title: "Intervallo di Raggruppamento degli Annullamenti"
+        desc: "Invervallo di tempo in millisecondi nel quale le operazioni di annullamento
+        vengono raggruppate assieme nella cronologia."
       }
       {
         _id: 'editor.zoomFontWhenCtrlScrolling'
-        title: "Zoom Font When Ctrl Scrolling"
-        desc: "Change the editor font size when pressing the Ctrl key and
-               scrolling the mouse up/down."
+        title: "Ingrandisci il Testo allo Scrolling con Ctrl pressato"
+        desc: "Cambia la dimensione del testo quando si preme il tasto Ctrl e
+               si scrolla verso sopra/sotto."
       }
       {
         _id: 'system.windows.file-handler'
-        title: "Register as file handler"
-        desc: "Show Atom in the \"Open with\" application list for easy association with file types."
+        title: "Registra come gestore di file"
+        desc: "Mostra Atom nella lista di applicazioni \"Apri con\" per facilitare l'associazione con i tipi di file."
       }
       {
         _id: 'system.windows.shell-menu-files'
-        title: "Show in file context menus"
-        desc: "Add \"Open with Atom\" to the File Explorer context menu for files."
+        title: "Mostra nel menu contestuale dei file"
+        desc: "Aggiungi \"Apri con Atom\" al menu contestuale dei file di File Explorer."
       }
       {
         _id: 'system.windows.shell-menu-folders'
-        title: "Show in folder context menus"
-        desc: "Add \"Open with Atom\" to the File Explorer context menu for folders."
+        title: "Mostra nel menu contestuale delle cartelle"
+        desc: "Aggiungi \"Apri con Atom\" al menu contestuale delle cartelle di File Explorer."
       }
     ]
   }


About translation

About translation

--- def/pt-br/about.cson
+++ def/pt-br/about.cson
@@ -1,12 +1,12 @@
 About:
-  tabTitle: "About"
-  releaseNotes: "Release Notes"
-  newUpdate: "New Update"
-  automaticDownloadUpdates: "Automatic download updates"
-  restartInstall: "Restart and install"
-  license: "License"
-  termsOfUse: "Terms of Use"
-  with: " with "
-  by: " by "
-  andTheAwesome: "And the awesome "
-  atomCommunity: "Atom Community"
+  tabTitle: "Sobre"
+  releaseNotes: "Notas de lançamento"
+  newUpdate: "Nova atualização"
+  automaticDownloadUpdates: "Baixar automaticamente as atualizações"
+  restartInstall: "Reiniciar e instalar"
+  license: "Licença"
+  termsOfUse: "Termos de uso"
+  with: " com "
+  by: " por "
+  andTheAwesome: "E o incrível "
+  atomCommunity: "Comunidade do Atom"


indent (at least in dfns)

indent (at least in dfns)

--- client/codemirror-apl-mode.coffee
+++ client/codemirror-apl-mode.coffee
@@ -46,7 +46,7 @@
 idiomsRE = ///^(?:#{idioms.sort((x, y) -> y.length - x.length).map(escIdiom).join '|'})///i

 CodeMirror.defineMIME 'text/apl', 'apl'
-CodeMirror.defineMode 'apl', -> # https://codemirror.net/doc/manual.html#modeapi
+CodeMirror.defineMode 'apl', (config) -> # https://codemirror.net/doc/manual.html#modeapi
   startState: -> isHeader: 1, stack: '', dfnDepth: 0
   token: (stream, state) ->
     if state.isHeader
@@ -93,3 +93,5 @@
         else if state.dfnDepth || state.vars && x in state.vars then 'apl-var'
         else 'apl-glb'
       else 'apl-err'
+
+  indent: (state, textAfter) -> config.indentUnit * (state.dfnDepth - /^\s*\}/.test textAfter)