1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

*** empty log message ***

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@170 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
matz 1998-04-16 10:39:21 +00:00
parent ddd90c76e1
commit d5db6fd46e
5 changed files with 11 additions and 19 deletions

View file

@ -33,23 +33,13 @@ int *tclDummyMathPtr = (int *) matherr;
/*---- module TclTkLib ----*/
static VALUE thread_safe = Qnil;
/* execute Tk_MainLoop */
static VALUE
lib_mainloop(VALUE self)
{
int old_trapflg;
int flags = RTEST(thread_safe)?TCL_DONT_WAIT:0;
DUMP1("start Tk_Mainloop");
while (Tk_GetNumMainWindows() > 0) {
old_trapflg = trap_immediate;
trap_immediate = 1;
Tcl_DoOneEvent(flags);
trap_immediate = old_trapflg;
CHECK_INTS;
flags = (thread_safe == 0 || thread_safe == Qnil)?0:TCL_DONT_WAIT;
Tcl_DoOneEvent(0);
}
DUMP1("stop Tk_Mainloop");
@ -210,8 +200,6 @@ void Init_tcltklib()
/* from Tk_Main() */
DUMP1("Tcl_FindExecutable");
Tcl_FindExecutable(RSTRING(rb_argv0)->ptr);
rb_define_variable("$tk_thread_safe", &thread_safe);
}
/* eof */