Commit 6c5ad852 authored by 神楽坂玲奈's avatar 神楽坂玲奈

event bind

parent 8e6b9fc6
...@@ -51,9 +51,9 @@ class CardUsage extends Spine.Model ...@@ -51,9 +51,9 @@ class CardUsage extends Spine.Model
class Deck extends Spine.Controller class Deck extends Spine.Controller
events: events:
'mouseenter .card': 'show', 'mouseover .card_usage': 'show',
'click .card': 'add', 'click .card_usage': 'add',
'contextmenu .card': 'minus' 'contextmenu .card_usage': 'minus'
key: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789*-=" key: "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789*-="
constructor: -> constructor: ->
......
...@@ -138,9 +138,9 @@ ...@@ -138,9 +138,9 @@
__extends(Deck, _super); __extends(Deck, _super);
Deck.prototype.events = { Deck.prototype.events = {
'mouseenter .card': 'show', 'mouseover .card_usage': 'show',
'click .card': 'add', 'click .card_usage': 'add',
'contextmenu .card': 'minus' 'contextmenu .card_usage': 'minus'
}; };
Deck.prototype.key = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789*-="; Deck.prototype.key = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789*-=";
......
...@@ -66,7 +66,7 @@ ...@@ -66,7 +66,7 @@
</script> </script>
<script id="card_usage_template" type="text/x-jquery-tmpl"> <script id="card_usage_template" type="text/x-jquery-tmpl">
<p id="deck_{{if side}}side{{else}}main{{/if}}_${card_id}"> <p class="card_usage">
<span class="card ${$data.card().card_type.join(' ')}">${$data.card().name}</span> <span class="card ${$data.card().card_type.join(' ')}">${$data.card().name}</span>
<i>${count}</i> <i>${count}</i>
</p> </p>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment