summaryrefslogtreecommitdiff
path: root/ext
diff options
context:
space:
mode:
Diffstat (limited to 'ext')
-rw-r--r--ext/.cvsignore1
-rw-r--r--ext/Win32API/Win32API.c6
-rw-r--r--ext/Win32API/extconf.rb2
-rw-r--r--ext/curses/.cvsignore1
-rw-r--r--ext/curses/curses.c8
-rw-r--r--ext/curses/extconf.rb4
-rw-r--r--ext/dbm/.cvsignore1
-rw-r--r--ext/etc/.cvsignore1
-rw-r--r--ext/extmk.rb.in34
-rw-r--r--ext/fcntl/.cvsignore1
-rw-r--r--ext/gdbm/.cvsignore1
-rw-r--r--ext/md5/.cvsignore1
-rw-r--r--ext/nkf/.cvsignore1
-rw-r--r--ext/pty/.cvsignore1
-rw-r--r--ext/pty/extconf.rb16
-rw-r--r--ext/readline/.cvsignore1
-rw-r--r--ext/sdbm/.cvsignore1
-rw-r--r--ext/sdbm/_sdbm.c4
-rw-r--r--ext/socket/.cvsignore1
-rw-r--r--ext/tcltklib/.cvsignore1
-rw-r--r--ext/tk/.cvsignore1
-rw-r--r--ext/tk/lib/tk.rb143
-rw-r--r--ext/tk/lib/tkcanvas.rb8
-rw-r--r--ext/tk/lib/tkentry.rb2
-rw-r--r--ext/tk/lib/tktext.rb8
-rw-r--r--ext/tk/lib/tkvirtevent.rb33
26 files changed, 215 insertions, 67 deletions
diff --git a/ext/.cvsignore b/ext/.cvsignore
new file mode 100644
index 0000000000..d8b8a61d92
--- /dev/null
+++ b/ext/.cvsignore
@@ -0,0 +1 @@
+extmk.rb
diff --git a/ext/Win32API/Win32API.c b/ext/Win32API/Win32API.c
index dcfdd7caab..0ee28f05ac 100644
--- a/ext/Win32API/Win32API.c
+++ b/ext/Win32API/Win32API.c
@@ -305,9 +305,3 @@ Init_Win32API()
rb_define_method(cWin32API, "call", Win32API_Call, -1);
rb_define_alias(cWin32API, "Call", "call");
}
-
-void
-Init_win32api()
-{
- Init_Win32API();
-}
diff --git a/ext/Win32API/extconf.rb b/ext/Win32API/extconf.rb
index f8d78e1465..5e42f62558 100644
--- a/ext/Win32API/extconf.rb
+++ b/ext/Win32API/extconf.rb
@@ -1,6 +1,6 @@
case RUBY_PLATFORM
when /cygwin/,/mingw/
- $CFLAGS = "-fno-defer-pop"
+ $CFLAGS = "-fno-defer-pop -fno-omit-frame-pointer"
create_makefile("Win32API")
when /win32/
create_makefile("Win32API")
diff --git a/ext/curses/.cvsignore b/ext/curses/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/curses/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/curses/curses.c b/ext/curses/curses.c
index db620654bd..4a8c46f483 100644
--- a/ext/curses/curses.c
+++ b/ext/curses/curses.c
@@ -16,16 +16,16 @@
# include <curses_colr/curses.h>
# else
# include <curses.h>
-# if (defined(__bsdi__) || defined(__NetBSD__)) && !defined(_maxx)
+# if (defined(__bsdi__) || defined(__NetBSD__) || defined(__APPLE__) ) && !defined(_maxx)
# define _maxx maxx
# endif
-# if (defined(__bsdi__) || defined(__NetBSD__)) && !defined(_maxy)
+# if (defined(__bsdi__) || defined(__NetBSD__) || defined(__APPLE__)) && !defined(_maxy)
# define _maxy maxy
# endif
-# if (defined(__bsdi__) || defined(__NetBSD__)) && !defined(_begx)
+# if (defined(__bsdi__) || defined(__NetBSD__) || defined(__APPLE__)) && !defined(_begx)
# define _begx begx
# endif
-# if (defined(__bsdi__) || defined(__NetBSD__)) && !defined(_begy)
+# if (defined(__bsdi__) || defined(__NetBSD__) || defined(__APPLE__)) && !defined(_begy)
# define _begy begy
# endif
# endif
diff --git a/ext/curses/extconf.rb b/ext/curses/extconf.rb
index 5c6881164a..c16ab00f28 100644
--- a/ext/curses/extconf.rb
+++ b/ext/curses/extconf.rb
@@ -1,5 +1,9 @@
require 'mkmf'
+dir_config('curses')
+dir_config('ncurses')
+dir_config('termcap')
+
make=false
have_library("mytinfo", "tgetent") if /bow/ =~ RUBY_PLATFORM
if have_header("ncurses.h") and have_library("ncurses", "initscr")
diff --git a/ext/dbm/.cvsignore b/ext/dbm/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/dbm/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/etc/.cvsignore b/ext/etc/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/etc/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/extmk.rb.in b/ext/extmk.rb.in
index 92d11d0f6e..a369933a14 100644
--- a/ext/extmk.rb.in
+++ b/ext/extmk.rb.in
@@ -370,13 +370,15 @@ def create_makefile(target)
if $configure_args['--enable-shared'] or "@LIBRUBY@" != "@LIBRUBY_A@"
$libs = "@LIBRUBYARG@ " + $libs
- $LIBPATH |= [$topdir]
+ $LIBPATH.unshift $topdir
end
defflag = ''
if RUBY_PLATFORM =~ /cygwin|mingw/ and not $static
- open(target + '.def', 'wb') do |f|
- f.print "EXPORTS\n", "Init_", target, "\n"
+ if not File.exist? target + '.def'
+ open(target + '.def', 'wb') do |f|
+ f.print "EXPORTS\n", "Init_", target, "\n"
+ end
end
defflag = "--def=" + target + ".def"
end
@@ -492,19 +494,43 @@ EOS
mfile.puts "
.c.@OBJEXT@:
$(CC) $(CFLAGS) $(CPPFLAGS) -c $<
+
+.cc.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $<
+.cpp.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $<
+.cxx.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $<
+.C.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $<
"
elsif /nmake/i =~ $make
mfile.print "
{$(srcdir)}.c{}.@OBJEXT@:
$(CC) -I. -I$(<D) $(CFLAGS) $(CPPFLAGS) -c $(<:/=\\)
-
.c.@OBJEXT@:
$(CC) $(CFLAGS) $(CPPFLAGS) -c $(<:/=\\)
+
+{$(srcdir)}.cc{}.@OBJEXT@:
+ $(CXX) -I. -I$(<D) $(CXXFLAGS) $(CPPFLAGS) -c $(<:/=\\)
+.cc.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(<:/=\\)
+{$(srcdir)}.cpp{}.@OBJEXT@:
+ $(CXX) -I. -I$(<D) $(CXXFLAGS) $(CPPFLAGS) -c $(<:/=\\)
+.cpp.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(<:/=\\)
+{$(srcdir)}.cxx{}.@OBJEXT@:
+ $(CXX) -I. -I$(<D) $(CXXFLAGS) $(CPPFLAGS) -c $(<:/=\\)
+.cxx.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(<:/=\\)
"
else
mfile.print "
.c.@OBJEXT@:
$(CC) $(CFLAGS) $(CPPFLAGS) -c $(subst /,\\\\,$<)
+
+.cc.@OBJEXT@ .cpp.@OBJEXT@ .cxx.@OBJEXT@ .C.@OBJEXT@:
+ $(CXX) $(CXXFLAGS) $(CPPFLAGS) -c $(subst /,\\\\,$<)
"
end
diff --git a/ext/fcntl/.cvsignore b/ext/fcntl/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/fcntl/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/gdbm/.cvsignore b/ext/gdbm/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/gdbm/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/md5/.cvsignore b/ext/md5/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/md5/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/nkf/.cvsignore b/ext/nkf/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/nkf/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/pty/.cvsignore b/ext/pty/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/pty/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/pty/extconf.rb b/ext/pty/extconf.rb
index 4df2011eb5..ba2b44c70b 100644
--- a/ext/pty/extconf.rb
+++ b/ext/pty/extconf.rb
@@ -1,10 +1,12 @@
require 'mkmf'
-have_header("sys/stropts.h")
-have_func("setresuid")
-$CFLAGS << "-DHAVE_DEV_PTMX" if /cygwin/ === RUBY_PLATFORM
-if have_func("openpty") or
- have_func("_getpty") or
- have_func("ioctl")
- create_makefile('pty')
+if /mswin32|mingw/ !~ RUBY_PLATFORM
+ have_header("sys/stropts.h")
+ have_func("setresuid")
+ $CFLAGS << "-DHAVE_DEV_PTMX" if /cygwin/ === RUBY_PLATFORM
+ if have_func("openpty") or
+ have_func("_getpty") or
+ have_func("ioctl")
+ create_makefile('pty')
+ end
end
diff --git a/ext/readline/.cvsignore b/ext/readline/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/readline/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/sdbm/.cvsignore b/ext/sdbm/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/sdbm/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/sdbm/_sdbm.c b/ext/sdbm/_sdbm.c
index 7a31472930..92c96f26d0 100644
--- a/ext/sdbm/_sdbm.c
+++ b/ext/sdbm/_sdbm.c
@@ -103,11 +103,9 @@ static int duppair proto((char *, datum));
/*
* externals
*/
-#ifndef sun
-#ifndef MSDOS
+#if !defined(sun) && !defined(MSDOS) && !defined(_WIN32)
extern int errno;
#endif
-#endif
/*
* forward
diff --git a/ext/socket/.cvsignore b/ext/socket/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/socket/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/tcltklib/.cvsignore b/ext/tcltklib/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/tcltklib/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/tk/.cvsignore b/ext/tk/.cvsignore
new file mode 100644
index 0000000000..f3c7a7c5da
--- /dev/null
+++ b/ext/tk/.cvsignore
@@ -0,0 +1 @@
+Makefile
diff --git a/ext/tk/lib/tk.rb b/ext/tk/lib/tk.rb
index a088d5c493..59d78da5d2 100644
--- a/ext/tk/lib/tk.rb
+++ b/ext/tk/lib/tk.rb
@@ -351,7 +351,7 @@ module TkComm
end
if context.kind_of? Array
context = context.collect{|ev|
- if context.kind_of? TkVirtualEvent
+ if ev.kind_of? TkVirtualEvent
ev.path
else
ev
@@ -397,8 +397,18 @@ module TkComm
end
}
else
- tk_split_list(tk_call(*what)).collect{|seq|
- seq[1..-2].gsub(/></,',')
+ tk_split_simplelist(tk_call(*what)).collect!{|seq|
+ l = seq.scan(/<*[^<>]+>*/).collect!{|subseq|
+ case (subseq)
+ when /^<<[^<>]+>>$/
+ TkVirtualEvent.getobj(subseq[1..-2])
+ when /^<[^<>]+>$/
+ subseq[1..-2]
+ else
+ subseq.split('')
+ end
+ }.flatten
+ (l.size == 1) ? l[0] : l
}
end
end
@@ -651,12 +661,76 @@ module TkCore
end
end
+module TkPackage
+ include TkCore
+ extend TkPackage
+
+ def forget(package)
+ tk_call('package', 'forget', package)
+ nil
+ end
+
+ def names
+ tk_split_simplelist(tk_call('package', 'names'))
+ end
+
+ def provide(package, version=nil)
+ if version
+ tk_call('package', 'provide', package, version)
+ nil
+ else
+ tk_call('package', 'provide', package)
+ end
+ end
+
+ def present(package, version=None)
+ tk_call('package', 'present', package, version)
+ end
+
+ def present_exact(package, version)
+ tk_call('package', 'present', '-exact', package, version)
+ end
+
+ def require(package, version=None)
+ tk_call('package', 'require', package, version)
+ end
+
+ def require_exact(package, version)
+ tk_call('package', 'require', '-exact', package, version)
+ end
+
+ def versions(package)
+ tk_split_simplelist(tk_call('package', 'versions', package))
+ end
+
+ def vcompare(version1, version2)
+ Integer(tk_call('package', 'vcompare', version1, version2))
+ end
+
+ def vsatisfies(version1, version2)
+ bool(tk_call('package', 'vsatisfies', version1, version2))
+ end
+end
+
module Tk
include TkCore
extend Tk
TCL_VERSION = INTERP._invoke("info", "tclversion")
TK_VERSION = INTERP._invoke("set", "tk_version")
+
+ TCL_PATCHLEVEL = INTERP._invoke("info", "patchlevel")
+ TK_PATCHLEVEL = INTERP._invoke("set", "tk_patchLevel")
+
+ TCL_LIBRARY = INTERP._invoke("set", "tcl_library")
+ TK_LIBRARY = INTERP._invoke("set", "tk_library")
+ LIBRARY = INTERP._invoke("info", "library")
+
+ TCL_PACKAGE_PATH = INTERP._invoke("set", "tcl_pkgPath")
+ AUTO_PATH = tk_split_simplelist(INTERP._invoke("set", "auto_path"))
+
+ PLATFORM = Hash[*tk_split_simplelist(INTERP._eval('array get tcl_platform'))]
+
JAPANIZED_TK = (INTERP._invoke("info", "commands", "kanji") != "")
def root
@@ -680,6 +754,10 @@ module Tk
tk_tcl2ruby(tk_call('focus', '-lastfor', win))
end
+ def Tk.strictMotif(bool=None)
+ bool(tk_call('set', 'tk_strictMotif', bool))
+ end
+
def Tk.show_kinsoku(mode='both')
begin
if /^8\.*/ === TK_VERSION && JAPANIZED_TK
@@ -710,11 +788,11 @@ module Tk
end
end
- def toUTF8(str,encoding)
+ def Tk.toUTF8(str,encoding)
INTERP._toUTF8(str,encoding)
end
- def fromUTF8(str,encoding)
+ def Tk.fromUTF8(str,encoding)
INTERP._fromUTF8(str,encoding)
end
@@ -978,6 +1056,12 @@ class TkBindTag
BTagID_TBL[id]? BTagID_TBL[id]: id
end
+ ALL = self.new
+ ALL.instance_eval {
+ @id = 'all'
+ BTagID_TBL[@id] = self
+ }
+
def initialize(*args)
@id = Tk_BINDTAG_ID[0]
Tk_BINDTAG_ID[0] = Tk_BINDTAG_ID[0].succ
@@ -995,20 +1079,11 @@ class TkBindTag
end
class TkBindTagAll<TkBindTag
- BindTagALL = []
def TkBindTagAll.new(*args)
- if BindTagALL[0]
- BindTagALL[0].bind(*args) if args != []
- else
- new = super()
- BindTagALL[0] = new
- end
- BindTagALL[0]
- end
+ $stderr.puts "Warning: TkBindTagALL is obsolete. Use TkBindTag::ALL\n"
- def initialize(*args)
- @id = 'all'
- BindTagALL[0].bind(*args) if args != []
+ TkBindTag::ALL.bind(*args) if args != []
+ TkBindTag::ALL
end
end
@@ -1446,7 +1521,7 @@ module TkXIM
end
def useinputmethods(value=nil)
- TkXIM.useinputmethods(self, value=nil)
+ TkXIM.useinputmethods(self, value)
end
def imconfigure(window, slot, value=None)
@@ -2370,7 +2445,7 @@ class TkWindow<TkObject
def grid_propagate(mode=nil)
if mode
- tk_call('grid', 'propagate', epath, bool)
+ tk_call('grid', 'propagate', epath, mode)
else
bool(tk_call('grid', 'propagate', epath))
end
@@ -2507,7 +2582,7 @@ class TkWindow<TkObject
def bindtags(taglist=nil)
if taglist
- fail unless taglist.kind_of? Array
+ fail ArgumentError unless taglist.kind_of? Array
tk_call('bindtags', path, taglist)
else
list(tk_call('bindtags', path)).collect{|tag|
@@ -2708,8 +2783,16 @@ class TkScale<TkWindow
tk_call 'scale', path
end
- def get
- number(tk_send('get'))
+ def get(x=None, y=None)
+ number(tk_send('get', x, y))
+ end
+
+ def coords(val=None)
+ tk_split_list(tk_send('coords', val))
+ end
+
+ def identify(x, y)
+ tk_send('identify', x, y)
end
def set(val)
@@ -2744,8 +2827,8 @@ class TkScrollbar<TkWindow
number(tk_send('fraction', x, y))
end
- def identify(x=None, y=None)
- tk_send('fraction', x, y)
+ def identify(x, y)
+ tk_send('identify', x, y)
end
def get
@@ -2760,6 +2843,10 @@ class TkScrollbar<TkWindow
def set(first, last)
tk_send "set", first, last
end
+
+ def activate(element=None)
+ tk_send('activate', element)
+ end
end
class TkTextWin<TkWindow
@@ -3033,12 +3120,12 @@ class TkMenu<TkWindow
tk_send 'invoke', index
end
def insert(index, type, keys=nil)
- tk_send 'add', index, type, *hash_kv(keys)
+ tk_send 'insert', index, type, *hash_kv(keys)
end
def delete(index, last=None)
tk_send 'delete', index, last
end
- def popup(x, y, index=nil)
+ def popup(x, y, index=None)
tk_call 'tk_popup', path, x, y, index
end
def post(x, y)
@@ -3128,12 +3215,12 @@ class TkMenu<TkWindow
end
class TkMenuClone<TkMenu
- def initialize(parent, type=nil)
+ def initialize(parent, type=None)
unless parent.kind_of?(TkMenu)
fail ArgumentError, "parent must be TkMenu"
end
@parent = parent
- install_win(@parent)
+ install_win(@parent.path)
tk_call @parent.path, 'clone', @path, type
end
end
diff --git a/ext/tk/lib/tkcanvas.rb b/ext/tk/lib/tkcanvas.rb
index ff06e9305a..9b323e9cbb 100644
--- a/ext/tk/lib/tkcanvas.rb
+++ b/ext/tk/lib/tkcanvas.rb
@@ -172,7 +172,7 @@ class TkCanvas<TkWindow
end
def bbox(tagOrId, *tags)
- list(tk_send('bbox', tagid(tagOrId), *tags))
+ list(tk_send('bbox', tagid(tagOrId), *tags.collect{|t| tagid(t)}))
end
def itembind(tag, context, cmd=Proc.new, args=nil)
@@ -207,7 +207,7 @@ class TkCanvas<TkWindow
end
def delete(*args)
- tk_send 'delete', *args
+ tk_send 'delete', *args.collect{|t| tagid(t)}
end
alias remove delete
@@ -375,7 +375,7 @@ class TkCanvas<TkWindow
end
def lower(tag, below=None)
- tk_send 'lower', tagid(tag), below
+ tk_send 'lower', tagid(tag), tagid(below)
end
def move(tag, x, y)
@@ -387,7 +387,7 @@ class TkCanvas<TkWindow
end
def raise(tag, above=None)
- tk_send 'raise', tagid(tag), above
+ tk_send 'raise', tagid(tag), tagid(above)
end
def scale(tag, x, y, xs, ys)
diff --git a/ext/tk/lib/tkentry.rb b/ext/tk/lib/tkentry.rb
index 6b25be376b..7af3f26748 100644
--- a/ext/tk/lib/tkentry.rb
+++ b/ext/tk/lib/tkentry.rb
@@ -136,7 +136,7 @@ class TkEntry<TkLabel
tk_send 'selection', 'from', index
end
def selection_present()
- tk_send('selection', 'present') == 1
+ bool(tk_send('selection', 'present'))
end
def selection_range(s, e)
tk_send 'selection', 'range', s, e
diff --git a/ext/tk/lib/tktext.rb b/ext/tk/lib/tktext.rb
index bb3d537bc4..51b5d82b60 100644
--- a/ext/tk/lib/tktext.rb
+++ b/ext/tk/lib/tktext.rb
@@ -189,6 +189,14 @@ class TkText<TkTextWin
}
end
+ def mark_next(index)
+ tagid2obj(tk_send('mark', 'next', index))
+ end
+
+ def mark_previous(index)
+ tagid2obj(tk_send('mark', 'previous', index))
+ end
+
def window_names
tk_send('window', 'names').collect{|elt|
tagid2obj(elt)
diff --git a/ext/tk/lib/tkvirtevent.rb b/ext/tk/lib/tkvirtevent.rb
index b31b99062f..d3721e362e 100644
--- a/ext/tk/lib/tkvirtevent.rb
+++ b/ext/tk/lib/tkvirtevent.rb
@@ -7,12 +7,27 @@ require 'tk'
class TkVirtualEvent<TkObject
extend Tk
- TkVirturlEventID = [0]
- TkVirturlEventTBL = {}
+ TkVirtualEventID = [0]
+ TkVirtualEventTBL = {}
+
+ class PreDefVirtEvent<self
+ def initialize(event)
+ @path = @id = event
+ TkVirtualEvent::TkVirtualEventTBL[@id] = self
+ end
+ end
def TkVirtualEvent.getobj(event)
- obj = TkVirturlEventTBL[event]
- obj ? obj : event
+ obj = TkVirtualEventTBL[event]
+ if obj
+ obj
+ else
+ if tk_call('event', 'info').index("<#{event}>")
+ PreDefVirtEvent.new(event)
+ else
+ fail ArgumentError, "undefined virtual event '<#{event}>'"
+ end
+ end
end
def TkVirtualEvent.info
@@ -22,8 +37,8 @@ class TkVirtualEvent<TkObject
end
def initialize(*sequences)
- @path = @id = format("<VirtEvent%.4d>", TkVirturlEventID[0])
- TkVirturlEventID[0] += 1
+ @path = @id = format("<VirtEvent%.4d>", TkVirtualEventID[0])
+ TkVirtualEventID[0] += 1
add(*sequences)
end
@@ -31,7 +46,7 @@ class TkVirtualEvent<TkObject
if sequences != []
tk_call('event', 'add', "<#{@id}>",
*(sequences.collect{|seq| "<#{tk_event_sequence(seq)}>"}) )
- TkVirturlEventTBL[@id] = self
+ TkVirtualEventTBL[@id] = self
end
self
end
@@ -39,11 +54,11 @@ class TkVirtualEvent<TkObject
def delete(*sequences)
if sequences == []
tk_call('event', 'delete', "<#{@id}>")
- TkVirturlEventTBL[@id] = nil
+ TkVirtualEventTBL[@id] = nil
else
tk_call('event', 'delete', "<#{@id}>",
*(sequences.collect{|seq| "<#{tk_event_sequence(seq)}>"}) )
- TkVirturlEventTBL[@id] = nil if info == []
+ TkVirtualEventTBL[@id] = nil if info == []
end
self
end