summaryrefslogtreecommitdiff
path: root/ext/tk/lib/tkentry.rb
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-02-28 06:53:33 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-02-28 06:53:33 +0000
commite88d2cec1f896a5f23550dcdd5d1f7994e687b79 (patch)
tree21caf0873cd632bd6beb8d91fc1da15d29aca427 /ext/tk/lib/tkentry.rb
parent3fc04d9361549d5bb15f869c22d7ce9591a0ac8c (diff)
* eval.c (rb_mod_include): load modules in argument order.
* st.c (st_init_table_with_size): num_bins should be prime numbers (no decrement). * st.c (rehash): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/lib/tkentry.rb')
-rw-r--r--ext/tk/lib/tkentry.rb16
1 files changed, 12 insertions, 4 deletions
diff --git a/ext/tk/lib/tkentry.rb b/ext/tk/lib/tkentry.rb
index 7af3f267484..f301bbdaced 100644
--- a/ext/tk/lib/tkentry.rb
+++ b/ext/tk/lib/tkentry.rb
@@ -55,8 +55,12 @@ class TkEntry<TkLabel
end
end
- def create_self
- tk_call 'entry', @path
+ def create_self(keys)
+ if keys and keys != None
+ tk_call 'entry', @path, *hash_kv(keys)
+ else
+ tk_call 'entry', @path
+ end
end
def bbox(index)
@@ -191,8 +195,12 @@ class TkSpinbox<TkEntry
WidgetClassName
end
- def create_self
- tk_call 'spinbox', @path
+ def create_self(keys)
+ if keys and keys != None
+ tk_call 'spinbox', @path, *hash_kv(keys)
+ else
+ tk_call 'spinbox', @path
+ end
end
def identify(x, y)