Sha256: 4d45ac35d28bfd2a95d647c2e659b0f79c584f33ca1d559e937570dd5b9d3860
Contents?: true
Size: 638 Bytes
Versions: 2
Compression:
Stored size: 638 Bytes
Contents
# frozen_string_literal: true require 'glimmer-dsl-libui' include Glimmer data = [ %w[cat meow delete], %w[dog woof delete], %w[chicken cock-a-doodle-doo delete], %w[hourse neigh delete], %w[cow moo delete] ] window('Animal sounds', 300, 200) { horizontal_box { table { text_column('Animal') text_column('Description') button_column('Action') { on_clicked do |row| data.delete_at(row) # automatically deletes actual table row due to implicit data-binding end } cell_rows data # implicit data-binding } } on_closing do puts 'Bye Bye' end }.show
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
glimmer-dsl-libui-0.0.23 | examples/basic_table_button.rb |
glimmer-dsl-libui-0.0.22 | examples/basic_table_button.rb |