summaryrefslogtreecommitdiff
path: root/ext/tk/lib/tkextlib/tile/tseparator.rb
diff options
context:
space:
mode:
Diffstat (limited to 'ext/tk/lib/tkextlib/tile/tseparator.rb')
-rw-r--r--ext/tk/lib/tkextlib/tile/tseparator.rb9
1 files changed, 5 insertions, 4 deletions
diff --git a/ext/tk/lib/tkextlib/tile/tseparator.rb b/ext/tk/lib/tkextlib/tile/tseparator.rb
index 30fae2c525..ffd2f6f89f 100644
--- a/ext/tk/lib/tkextlib/tile/tseparator.rb
+++ b/ext/tk/lib/tkextlib/tile/tseparator.rb
@@ -13,9 +13,6 @@ module Tk
end
end
-Tk.__set_toplevel_aliases__(:Ttk, Tk::Tile::Separator, :TkSeparator)
-
-
class Tk::Tile::TSeparator < TkWindow
include Tk::Tile::TileWidget
@@ -25,9 +22,13 @@ class Tk::Tile::TSeparator < TkWindow
TkCommandNames = ['::tseparator'.freeze].freeze
end
WidgetClassName = 'TSeparator'.freeze
- WidgetClassNames[WidgetClassName] = self
+ WidgetClassNames[WidgetClassName] ||= self
def self.style(*args)
[self::WidgetClassName, *(args.map!{|a| _get_eval_string(a)})].join('.')
end
end
+
+#Tk.__set_toplevel_aliases__(:Ttk, Tk::Tile::Separator, :TkSeparator)
+Tk.__set_loaded_toplevel_aliases__('tkextlib/tile/tseparator.rb',
+ :Ttk, Tk::Tile::Separator, :TkSeparator)