| In: |
tk/lib/tk/bindtag.rb
|
| Parent: | Object |
| BTagID_TBL | = | TkCore::INTERP.create_table |
| BTagID_TBL = {} | ||
| Tk_BINDTAG_ID | = | ["btag".freeze, "00000".taint].freeze |
| ALL | = | self.new_by_name('all') |
# File tk/lib/tk/bindtag.rb, line 15 def TkBindTag.id2obj(id) BTagID_TBL[id]? BTagID_TBL[id]: id end
# File tk/lib/tk/bindtag.rb, line 28 def initialize(*args, &b) @id = Tk_BINDTAG_ID.join('') Tk_BINDTAG_ID[1].succ! BTagID_TBL[@id] = self bind(*args, &b) if args != [] end
# File tk/lib/tk/bindtag.rb, line 19 def TkBindTag.new_by_name(name, *args, &b) return BTagID_TBL[name] if BTagID_TBL[name] self.new(*args, &b).instance_eval{ BTagID_TBL.delete @id @id = name BTagID_TBL[@id] = self } end