Sha256: a1748271fbe197fce6540985792eb7cf55d46ba3412b07cc13fc1db9cf315af4
Contents?: true
Size: 548 Bytes
Versions: 8
Compression:
Stored size: 548 Bytes
Contents
module RubyToBlock module Block class HardwareOnButtonDownOrUp < CharacterEvent include HardwareOperation blocknize '^\s*' + CHAR_RE + 'on\(:button_(down|up),' + DIO_PIN_RE + '\)\s+' + 'do\s*$', statement: true, indent: true def self.process_match_data(md, context) md2 = regexp.match(md[type]) add_character_event_blocks(context, md2[1], new(fields: { PIN: md2[3], DOU: md2[2] })) true end end end end
Version data entries
8 entries across 8 versions & 1 rubygems