Sha256: c882be41fc7bbd4dbd31996aa46ace484696ddc68aae4752b2e5dd64c55f953f
Contents?: true
Size: 571 Bytes
Versions: 6
Compression:
Stored size: 571 Bytes
Contents
require_relative '../../helper' describe Tk::Bind do entry = Tk::Entry.new entry.pack entry.focus it 'should bind a block' do foo = false entry.bind('f'){ foo = true } Tk.interp.do_events_until{ Tk::Event.generate(entry, 'f') foo } foo.should == true end it 'should return the bound proc' do entry.bind('f').should == ' ::RubyFFI::event 0 f %# %b %c %d %f %h %i %k %m %o %p %s %t %w %x %y %A %B %D %E %K %N %P %R %S %T %W %X %Y ' end it 'should list the sequences bound' do entry.bind.should == ['f'] end end
Version data entries
6 entries across 6 versions & 1 rubygems