1# 2# tkextlib/iwidgets/pushbutton.rb 3# by Hidetoshi NAGAI (nagai@ai.kyutech.ac.jp) 4# 5 6require 'tk' 7require 'tkextlib/iwidgets.rb' 8 9module Tk 10 module Iwidgets 11 class Pushbutton < Tk::Itk::Widget 12 end 13 end 14end 15 16class Tk::Iwidgets::Pushbutton 17 TkCommandNames = ['::iwidgets::pushbutton'.freeze].freeze 18 WidgetClassName = 'Pushbutton'.freeze 19 WidgetClassNames[WidgetClassName] ||= self 20 21 def __boolval_optkeys 22 super() << 'defaultring' 23 end 24 private :__boolval_optkeys 25 26 def invoke 27 tk_call_without_enc(@path, 'invoke') 28 self 29 end 30 31 def flash 32 tk_call_without_enc(@path, 'flash') 33 self 34 end 35end 36