add "update" after binding creation in xinit.c, to avoid incomplete initialization of event binding if xschem called with non-existent file
This commit is contained in:
parent
205bda387a
commit
4f8120cd2d
|
|
@ -1227,21 +1227,25 @@ int callback(int event, int mx, int my, KeySym key,
|
|||
{
|
||||
if(xctx->semaphore >= 2) break;
|
||||
tcleval("xschem new_window");
|
||||
break;
|
||||
}
|
||||
if(key=='N' && state==(ShiftMask|Mod1Mask) ) /* Empty symbol in new window */
|
||||
{
|
||||
if(xctx->semaphore >= 2) break;
|
||||
tcleval("xschem new_symbol_window");
|
||||
break;
|
||||
}
|
||||
if(key=='n' && state==ControlMask) /* New schematic */
|
||||
{
|
||||
if(xctx->semaphore >= 2) break;
|
||||
tcleval("xschem clear SCHEMATIC");
|
||||
break;
|
||||
}
|
||||
if(key=='N' && state==(ShiftMask|ControlMask) ) /* New symbol */
|
||||
{
|
||||
if(xctx->semaphore >= 2) break;
|
||||
tcleval("xschem clear SYMBOL");
|
||||
break;
|
||||
}
|
||||
if(key=='n' && state==0) /* hierarchical netlist */
|
||||
{
|
||||
|
|
|
|||
|
|
@ -163,6 +163,7 @@ int xschem(ClientData clientdata, Tcl_Interp *interp, int argc, const char * arg
|
|||
cmd_found = 1;
|
||||
callback( atoi(argv[2]), atoi(argv[3]), atoi(argv[4]), (KeySym)atol(argv[5]),
|
||||
atoi(argv[6]), atoi(argv[7]), atoi(argv[8]) );
|
||||
dbg(2, "callback %s %s %s %s %s %s %s\n", argv[2], argv[3], argv[4], argv[5], argv[6], argv[7], argv[8]);
|
||||
Tcl_ResetResult(interp);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -1549,7 +1549,7 @@ int Tcl_AppInit(Tcl_Interp *inter)
|
|||
/* Completing tk windows creation (see xschem.tcl, build_windows) and event binding */
|
||||
/* *AFTER* X initialization done */
|
||||
/* */
|
||||
if(has_x) tcleval("build_windows");
|
||||
if(has_x) tcleval("build_windows; update");
|
||||
|
||||
fullscreen=atoi(tclgetvar("fullscreen"));
|
||||
if(fullscreen) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue