Corrected an issue introduced in version 8.3.471 when trying to fix

some of the "select" command syntax;  the code change caused the
"select top cell" command to behave the same as "select cell".
There was no specific code for handling "top", so now there is.
This commit is contained in:
Tim Edwards 2024-05-12 15:54:40 -04:00
parent f0c3ec33d6
commit e4c28ef3bf
2 changed files with 6 additions and 4 deletions

View File

@ -1 +1 @@
8.3.481
8.3.482

View File

@ -855,7 +855,7 @@ CmdSelect(w, cmd)
bool layerspec;
bool degenerate;
bool doat = FALSE;
bool more = FALSE, less = FALSE, samePlace = TRUE;
bool more = FALSE, less = FALSE, samePlace = TRUE, dotop = FALSE;
unsigned char labelpolicy = SEL_DO_LABELS;
#ifdef MAGIC_WRAPPER
char *tclstr;
@ -942,6 +942,7 @@ CmdSelect(w, cmd)
"cell", strlen(cmd->tx_argv[2])))
{
isqual = 1;
dotop = TRUE;
optionArgs = &cmd->tx_argv[2];
}
}
@ -1614,9 +1615,10 @@ Okay:
use = DBSelectCell(scx.scx_use, lastUse, &lastIndices,
&scx.scx_area, crec->dbw_bitmask, &trans, &p, &tpath);
/* Use the window's root cell if nothing else is found. */
/* Use the window's root cell if nothing else is found, */
/* or if the command was "select top cell". */
if (use == NULL)
if ((dotop == TRUE) || (use == NULL))
{
use = lastUse = scx.scx_use;
p.p_x = scx.scx_use->cu_xlo;