Sha256: 8355391cfbcc979736c7ce7dc3989fda956ba5878acce67c81757689a83bcad7
Contents?: true
Size: 446 Bytes
Versions: 6
Compression:
Stored size: 446 Bytes
Contents
# A button that counts how often it is clicked. # This is implemented as a subclass of Button, # to take advantage of the already existing functionality there. class window.CounterButton extends Button constructor: -> super # Counts how often this button has been clicked so far. @click_count = 0 # We override the event handler for the 'clicked' event here. container_clicked: => @fire_event 'clicked', ++@click_count
Version data entries
6 entries across 6 versions & 1 rubygems