summaryrefslogtreecommitdiff
path: root/ext/tk/lib/tkentry.rb
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-06-13 09:51:02 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2000-06-13 09:51:02 +0000
commit1b47fa1097c709be518a5071a7ec0e5271d45a00 (patch)
tree62f7220ccb1211efc9e1bc9b69c28448173c03bf /ext/tk/lib/tkentry.rb
parent1c940e6cdd3e59430d57a42a9d5989bc5ad85270 (diff)
2000-06-13
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_4@751 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/tk/lib/tkentry.rb')
-rw-r--r--ext/tk/lib/tkentry.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/ext/tk/lib/tkentry.rb b/ext/tk/lib/tkentry.rb
index f35d2eef00..5207d9b895 100644
--- a/ext/tk/lib/tkentry.rb
+++ b/ext/tk/lib/tkentry.rb
@@ -59,6 +59,14 @@ class TkEntry<TkLabel
tk_send 'selection', 'to', index
end
+ def validate
+ if tk_send('validate') == '0'
+ false
+ else
+ true
+ end
+ end
+
def value
tk_send 'get'
end