Skip to content

Commit

Permalink
Merge branch 'master' of gist.github.com:1619170
Browse files Browse the repository at this point in the history
  • Loading branch information
utgarda committed Mar 21, 2012
2 parents b0099ca + bcdd27e commit 1119828
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
8 changes: 4 additions & 4 deletions midi-keyboard-1.coffee
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
colors = [ '#CCDDBB', '#99CC66', '#88AA66', '#AADDCC'
colors = [ '#CCDDBB', '#99CC66', '#88AA66', '#AADDCC'
'#66AAAA', '#559999', '#FFFFDD', '#FF9922'
'#DD8822', '#AACCDD', '#5599CC', '#4477AA' ]
nextSquareHtml = (color) -> """
Expand All @@ -7,6 +7,6 @@ height: 30px; width: 30px; margin: 5px; float: left"></div>"""
grow = (square) ->
square.animate(height: 60, 200).animate height: 30
for c in colors
$(nextSquareHtml c)
.appendTo( $ '#keyboard' )
.click -> grow $(this)
$j(nextSquareHtml c)
.appendTo( $j '#keyboard' )
.click -> grow $j(this)
2 changes: 1 addition & 1 deletion midi-keyboard-2.coffee
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
squares = ( $j(nextSquareHtml c) for c in colors )
for s,i in squares
s.appendTo( $ '#keyboard' ) #assembling the keyboard
s.appendTo( $j '#keyboard' ) #assembling the keyboard
.click ->
grow $j(this), 7
#attach the next one, make it circular
Expand Down
2 changes: 1 addition & 1 deletion midi-keyboard-3.coffee
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ grow = (square, i) ->
if i>0 and not square.is ':animated'
square.animate height: 60, 200,
-> grow square.data('next'), i-1
.animate height: 30
.animate height: 30
2 changes: 1 addition & 1 deletion midi-keyboard.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
<script type="text/coffeescript">
$j = jQuery

colors = [ '#CCDDBB', '#99CC66', '#88AA66', '#AADDCC'
colors = [ '#CCDDBB', '#99CC66', '#88AA66', '#AADDCC'
'#66AAAA', '#559999', '#FFFFDD', '#FF9922'
'#DD8822', '#AACCDD', '#5599CC', '#4477AA' ]

Expand Down
2 changes: 1 addition & 1 deletion tree-frogs.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
div.green-leaf div {border: 1px solid white; height: 38px; width: 38px; position: absolute}
</style>

<div class='green-leaf' style='background: #458008; position: relative; width: 200px; height: 200px' >
<div class='green-leaf' style='background: #458008; position: relative; width: 200px; height: 200px' >
<div id='ani3_bar0' style='background: #FF621D; left: 0; top:0'></div>
<div id='ani3_bar1' style='background: #B1D02C; left: 0; top:160px'></div>
<div id='ani3_bar2' style='background: #D5FA6F; left: 160px; top:160px'></div>
Expand Down

0 comments on commit 1119828

Please sign in to comment.