Changeset 1411


Ignore:
Timestamp:
Mar 29, 2009, 10:33:07 PM (17 years ago)
Author:
Steven Levine
Message:

Rework extended container search to use common logic
Update docs to match code
Shift now reverses configured state of extended container search enable
Backslash optional in not ambiguous

Location:
trunk/dll
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/arccnrs.c

    r1402 r1411  
    7575  08 Mar 09 GKY Additional strings move to PCSZs in init.c
    7676  08 Mar 09 GKY Removed variable aurguments from docopyf and unlinkf (not used)
     77  12 Mar 09 SHL Use common SearchContainer
    7778
    7879***********************************************************************/
     
    22442245    shiftstate = (SHORT1FROMMP(mp1) & (KC_SHIFT | KC_ALT | KC_CTRL));
    22452246    if (SHORT1FROMMP(mp1) & KC_KEYUP)
    2246       return (MRESULT) TRUE;
     2247      return (MRESULT)TRUE;
    22472248    if (SHORT1FROMMP(mp1) & KC_VIRTUALKEY) {
    22482249      switch (SHORT2FROMMP(mp2)) {
     
    22522253      }
    22532254    }
    2254     if (shiftstate || fNoSearch)
    2255       break;
    2256     if (SHORT1FROMMP(mp1) & KC_CHAR) {
    2257 
    2258       ULONG thistime, len;
    2259       SEARCHSTRING srch;
    2260       PCNRITEM pci;
    2261 
    2262       if (!dcd)
    2263         break;
    2264       switch (SHORT1FROMMP(mp2)) {
    2265       case '\x1b':
    2266       case '\r':
    2267       case '\n':
    2268         dcd->lasttime = 0;
    2269         *dcd->szCommonName = 0;
    2270         break;
    2271       default:
    2272         thistime = WinQueryMsgTime(WinQueryAnchorBlock(hwnd));
    2273         if (thistime > dcd->lasttime + 1250)
    2274           *dcd->szCommonName = 0;
    2275         dcd->lasttime = thistime;
    2276         if (SHORT1FROMMP(mp2) == ' ' && !*dcd->szCommonName)
    2277           break;
    2278       KbdRetry:
    2279         len = strlen(dcd->szCommonName);
    2280         if (len >= CCHMAXPATH - 1) {
    2281           *dcd->szCommonName = 0;
    2282           len = 0;
    2283         }
    2284         dcd->szCommonName[len] = toupper(SHORT1FROMMP(mp2));
    2285         dcd->szCommonName[len + 1] = 0;
    2286         memset(&srch, 0, sizeof(SEARCHSTRING));
    2287         srch.cb = (ULONG) sizeof(SEARCHSTRING);
    2288         srch.pszSearch = dcd->szCommonName;
    2289         srch.fsPrefix = TRUE;
    2290         srch.fsCaseSensitive = FALSE;
    2291         srch.usView = CV_ICON;
    2292         pci = WinSendMsg(hwnd,
    2293                          CM_SEARCHSTRING,
    2294                          MPFROMP(&srch), MPFROMLONG(CMA_FIRST));
    2295         if (pci && (INT) pci != -1) {
    2296 
    2297           USHORT attrib = CRA_CURSORED;
    2298 
    2299 
    2300           /* make found item current item */
    2301           if (!stricmp(pci->pszFileName, dcd->szCommonName))
    2302             attrib |= CRA_SELECTED;
    2303           WinSendMsg(hwnd,
    2304                      CM_SETRECORDEMPHASIS,
    2305                      MPFROMP(pci), MPFROM2SHORT(TRUE, attrib));
    2306           /* make sure that record shows in viewport */
    2307           ShowCnrRecord(hwnd, (PMINIRECORDCORE) pci);
    2308           return (MRESULT) TRUE;
    2309         }
    2310         else {
    2311           if (SHORT1FROMMP(mp2) == ' ') {
    2312             dcd->szCommonName[len] = 0;
    2313             break;
    2314           }
    2315           *dcd->szCommonName = 0;
    2316           dcd->lasttime = 0;
    2317           if (len)                      // retry as first letter if no match
    2318             goto KbdRetry;
    2319         }
    2320         break;
    2321       }
    2322     }
    2323     break;
     2255
     2256    if (SearchContainer(hwnd, msg, mp1, mp2))
     2257        return (MRESULT)TRUE;           // Avoid default handler
     2258    break;                              // Let default handler see key too
    23242259
    23252260  case WM_MOUSEMOVE:
  • trunk/dll/dircnrs.c

    r1402 r1411  
    12261226        if ((shiftstate & KC_CTRL) == KC_CTRL)
    12271227          PostMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_MKDIR, 0), MPVOID);
     1228        // Alt-Insert - create file
    12281229        else if ((shiftstate & KC_ALT) == KC_ALT)
    12291230          PostMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_CREATE, 0), MPVOID);
     
    12391240      case VK_HOME:
    12401241        if ((shiftstate & KC_CTRL) == KC_CTRL && dcd) {
    1241 
    12421242          CHAR s[CCHMAXPATH], *p;
    1243 
    12441243          strcpy(s, dcd->directory);
    12451244          p = strchr(s, '\\');
     
    12591258          PostMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_DELETE, 0), MPVOID);
    12601259        break;
    1261       }
    1262     }
    1263     if (shiftstate || fNoSearch)
    1264       break;
    1265     if (SHORT1FROMMP(mp1) & KC_CHAR) {
    1266 
    1267       ULONG thistime, len;
    1268       SEARCHSTRING srch;
    1269       PCNRITEM pci;
    1270 
    1271       if (!dcd)
    1272         break;
    1273       switch (SHORT1FROMMP(mp2)) {
    1274       case '\x1b':
    1275       case '\r':
    1276       case '\n':
    1277         dcd->lasttime = 0;
    1278         *dcd->szCommonName = 0;
    1279         break;
    1280       default:
    1281         thistime = WinQueryMsgTime(WinQueryAnchorBlock(hwnd));
    1282         if (thistime > dcd->lasttime + 1250)
    1283           *dcd->szCommonName = 0;
    1284         dcd->lasttime = thistime;
    1285         if (SHORT1FROMMP(mp2) == ' ' && !dcd->szCommonName)
    1286           break;
    1287       KbdRetry:
    1288         len = strlen(dcd->szCommonName);
    1289         if (len >= CCHMAXPATH - 1) {
    1290           *dcd->szCommonName = 0;
    1291           len = 0;
    1292         }
    1293         dcd->szCommonName[len] = toupper(SHORT1FROMMP(mp2));
    1294         dcd->szCommonName[len + 1] = 0;
    1295         memset(&srch, 0, sizeof(SEARCHSTRING));
    1296         srch.cb = (ULONG) sizeof(SEARCHSTRING);
    1297         srch.pszSearch = (PSZ) dcd->szCommonName;
    1298         srch.fsPrefix = TRUE;
    1299         srch.fsCaseSensitive = FALSE;
    1300         srch.usView = CV_ICON;
    1301         pci = WinSendMsg(hwnd, CM_SEARCHSTRING, MPFROMP(&srch),
    1302                          MPFROMLONG(CMA_FIRST));
    1303         if (pci && (INT) pci != -1) {
    1304 
    1305           USHORT attrib = CRA_CURSORED;
    1306 
    1307           /* make found item current item */
    1308           if (!stricmp(pci->pszFileName, dcd->szCommonName))
    1309             attrib |= CRA_SELECTED;
    1310           WinSendMsg(hwnd, CM_SETRECORDEMPHASIS, MPFROMP(pci),
    1311                      MPFROM2SHORT(TRUE, attrib));
    1312           /* make sure that record shows in viewport */
    1313           ShowCnrRecord(hwnd, (PMINIRECORDCORE) pci);
    1314           return (MRESULT) TRUE;
    1315         }
    1316         else {
    1317           if (SHORT1FROMMP(mp2) == ' ') {
    1318             dcd->szCommonName[len] = 0;
    1319             break;
    1320           }
    1321           *dcd->szCommonName = 0;
    1322           dcd->lasttime = 0;
    1323           if (len)                      // retry as first letter if no match
    1324             goto KbdRetry;
    1325         }
    1326         break;
    1327       }
    1328     }
    1329     break;
     1260      } // switch
     1261    }
     1262
     1263    if (SearchContainer(hwnd, msg, mp1, mp2))
     1264      return (MRESULT)TRUE;             // Avoid default handler
     1265    break;                              // Let default handler see key too
    13301266
    13311267  case WM_MOUSEMOVE:
     
    15071443            if (fSplitStatus && hwndStatus2) {
    15081444              CommaFmtULL(tb, sizeof(tb), pci->cbFile + pci->easize, ' ');
    1509               if (!fMoreButtons) {
    1510                 DateFormat(szDate, pci->date);
     1445              if (!fMoreButtons) {
     1446                DateFormat(szDate, pci->date);
    15111447                sprintf(s, " %s  %s %02u%s%02u%s%02u  [%s]  %s",
    15121448                        tb,
    15131449                        szDate,
    1514                         pci->time.hours,
    1515                         TimeSeparator,
    1516                         pci->time.minutes,
    1517                         TimeSeparator,
     1450                        pci->time.hours,
     1451                        TimeSeparator,
     1452                        pci->time.minutes,
     1453                        TimeSeparator,
    15181454                        pci->time.seconds,
    1519                         pci->pszDispAttr, pci->pszFileName);
    1520               }
     1455                        pci->pszDispAttr, pci->pszFileName);
     1456              }
    15211457              else {
    15221458                *tf = 0;
     
    15331469              WinSetWindowText(hwndStatus2, NullStr);
    15341470            if (fMoreButtons) {
    1535               WinSetWindowText(hwndName, pci->pszFileName);
    1536               DateFormat(szDate, pci->date);
     1471              WinSetWindowText(hwndName, pci->pszFileName);
     1472              DateFormat(szDate, pci->date);
    15371473              sprintf(s, "%s %02u%s%02u%s%02u",
    1538                       szDate,
    1539                       pci->time.hours, TimeSeparator,
    1540                       pci->time.minutes, TimeSeparator,
    1541                       pci->time.seconds);
     1474                      szDate,
     1475                      pci->time.hours, TimeSeparator,
     1476                      pci->time.minutes, TimeSeparator,
     1477                      pci->time.seconds);
    15421478              WinSetWindowText(hwndDate, s);
    15431479              WinSetWindowText(hwndAttr, pci->pszDispAttr);
     
    28352771                Dos_Error(MB_ENTER, rc, HWND_DESKTOP, pszSrcFile, __LINE__,
    28362772                          GetPString(IDS_CANTFINDDIRTEXT),
    2837                           pci->pszFileName);
    2838                 if (!fErrorBeepOff)
     2773                          pci->pszFileName);
     2774                if (!fErrorBeepOff)
    28392775                  DosBeep(250,100);
    28402776                driveserial[toupper(*pci->pszFileName) - 'A'] = -1;
     
    33313267                if (fSplitStatus && hwndStatus2) {
    33323268                  CommaFmtULL(tb, sizeof(tb), pci->cbFile + pci->easize, ' ');
    3333                   if (!fMoreButtons) {
    3334                     CHAR date[11];
    3335 
    3336                     DateFormat(date, pci->date);
     3269                  if (!fMoreButtons) {
     3270                    CHAR date[11];
     3271
     3272                    DateFormat(date, pci->date);
    33373273                    sprintf(s, " %s  %s %02u%s%02u%s%02u  [%s]  %s",
    33383274                            tb, date, pci->time.hours, TimeSeparator,
     
    33523288                  WinSetWindowText(hwndStatus2, s);
    33533289                }
    3354                 if (fMoreButtons) {
    3355                   CHAR szDate[DATE_BUF_BYTES];
    3356 
    3357                   WinSetWindowText(hwndName, pci->pszFileName);
    3358                   DateFormat(szDate, pci->date);
     3290                if (fMoreButtons) {
     3291                  CHAR szDate[DATE_BUF_BYTES];
     3292
     3293                  WinSetWindowText(hwndName, pci->pszFileName);
     3294                  DateFormat(szDate, pci->date);
    33593295                  sprintf(s, "%s %02u%s%02u%s%02u",
    3360                           szDate, pci->time.hours, TimeSeparator, pci->time.minutes,
     3296                          szDate, pci->time.hours, TimeSeparator, pci->time.minutes,
    33613297                          TimeSeparator, pci->time.seconds);
    33623298                  WinSetWindowText(hwndDate, s);
     
    35873523}
    35883524
     3525/**
     3526 * Search container for matching text
     3527 * @return TRUE if key completely handled here
     3528 */
     3529
     3530MRESULT EXPENTRY SearchContainer(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2)
     3531{
     3532  DIRCNRDATA *dcd = INSTDATA(hwnd);
     3533  ULONG thistime;
     3534  UINT len;
     3535  SEARCHSTRING srch;
     3536  PCNRITEM pci;
     3537  USHORT key;
     3538
     3539  if (!dcd)
     3540    return FALSE;
     3541
     3542  // Just to be safe, caller has probably already checked
     3543  if (SHORT1FROMMP(mp1) & KC_KEYUP)
     3544    return FALSE;
     3545
     3546  // Just to be safe, caller has probably already cached
     3547  shiftstate = (SHORT1FROMMP(mp1) & (KC_SHIFT | KC_ALT | KC_CTRL));
     3548
     3549  // If not plain character or suppressed
     3550  // Shift toggles configured setting
     3551  if (shiftstate & (KC_ALT | KC_CTRL) || (shiftstate & KC_SHIFT ? !fNoSearch : fNoSearch))
     3552    return FALSE;
     3553
     3554  if (SHORT1FROMMP(mp1) & KC_VIRTUALKEY) {
     3555    key = SHORT2FROMMP(mp2);
     3556    if (key == VK_BACKSPACE)
     3557      key = '\x8';
     3558    else if (key == VK_ESC)
     3559      key = '\x1b';
     3560    else
     3561      return FALSE;
     3562  }
     3563  else if (SHORT1FROMMP(mp1) & KC_CHAR)
     3564    key = SHORT1FROMMP(mp2);
     3565  else
     3566    return FALSE;
     3567
     3568  thistime = WinQueryMsgTime(WinQueryAnchorBlock(hwnd));
     3569  if (thistime > dcd->lasttime + 1500)
     3570    *dcd->szCommonName = 0;             // 1.5 seconds
     3571  dcd->lasttime = thistime;
     3572
     3573  switch (key) {
     3574  case '\x1b':                  // Esc
     3575    *dcd->szCommonName = 0;
     3576    break;
     3577  default:
     3578    if (key == ' ' && !*dcd->szCommonName)
     3579      break;                    // Let PM see space to allow select toggle
     3580    len = strlen(dcd->szCommonName);
     3581    if (key == '\x8') {
     3582      // Backspace
     3583      if (len) {
     3584        len--;
     3585        dcd->szCommonName[len] = 0;     // Chop
     3586      }
     3587    }
     3588    else {
     3589      if (len >= CCHMAXPATH - 1) {
     3590        if (!fErrorBeepOff)
     3591          DosBeep(250,100);
     3592          // WinAlarm(hwnd,WA_WARNING);
     3593      }
     3594      else {
     3595        dcd->szCommonName[len] = toupper(key);
     3596        dcd->szCommonName[len + 1] = 0;
     3597      }
     3598    }
     3599    // Case insensitive search
     3600    memset(&srch, 0, sizeof(SEARCHSTRING));
     3601    srch.cb = (ULONG) sizeof(SEARCHSTRING);
     3602    srch.pszSearch = (PSZ) dcd->szCommonName;
     3603    srch.fsPrefix = TRUE;
     3604    srch.fsCaseSensitive = FALSE;
     3605    srch.usView = CV_ICON;
     3606    pci = WinSendMsg(hwnd, CM_SEARCHSTRING, MPFROMP(&srch),
     3607                     MPFROMLONG(CMA_FIRST));
     3608    if (pci && (INT) pci != -1) {
     3609      /* Got match make found item current item */
     3610      USHORT attrib = CRA_CURSORED;
     3611      if (!stricmp(pci->pszDisplayName, dcd->szCommonName))
     3612        attrib |= CRA_SELECTED;
     3613      WinSendMsg(hwnd, CM_SETRECORDEMPHASIS, MPFROMP(pci),
     3614                 MPFROM2SHORT(TRUE, attrib));
     3615      /* make sure that record shows in viewport */
     3616      ShowCnrRecord(hwnd, (PMINIRECORDCORE) pci);
     3617      return (MRESULT)TRUE;
     3618    }
     3619    else {
     3620      if (key == ' ')
     3621        return FALSE;                   // Let PM see space to toggle select
     3622      // No match
     3623      // Erase non-matching last character, len is not yet incremented
     3624      dcd->szCommonName[len] = 0;
     3625      if (len == 0 && key != '\\') {
     3626        // Let's see if user forgot leading backslash
     3627        // key = SHORT1FROMMP(mp2);
     3628        if (SearchContainer(hwnd, msg, mp1, MPFROM2SHORT('\\', 0))) {
     3629          if (SearchContainer(hwnd, msg, mp1, mp2))
     3630            return (MRESULT)TRUE;
     3631        }
     3632      }
     3633#if 0 // 15 Mar 09 SHL fixme to not hang
     3634      if (!fErrorBeepOff)
     3635        DosBeep(250,100);
     3636        // WinAlarm(hwnd,WA_WARNING);
     3637#endif
     3638    }
     3639  } // switch
     3640
     3641  return FALSE;                         // Let PM see key
     3642}
     3643
    35893644HWND StartDirCnr(HWND hwndParent, CHAR * directory, HWND hwndRestore,
    35903645                 ULONG flags)
  • trunk/dll/dircnrs.h

    r1403 r1411  
    160160MRESULT EXPENTRY DirObjWndProc(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
    161161
     162MRESULT EXPENTRY SearchContainer(HWND hwnd, ULONG msg, MPARAM mp1, MPARAM mp2);
     163
    162164// 05 Jan 08 SHL fixme for dircnrs.c globals to be here
    163165
  • trunk/dll/ipf/context.ipf

    r1377 r1411  
    1212.* 29 Feb 08 GKY Document unhide menu item
    1313.* 06 Jul 08 GKY Update delete/undelete to include option of using the XWP trashcan
     14.* 13 Mar 09 SHL Update extended container search docs
     15.* 13 Mar 09 SHL Get rid of spurious backslashes in name='..' keywords
    1416.*
    1517.***********************************************************************
     
    6365only one or two types of objects. Items not appearing on the file object menus
    6466are inserted at the relative point they appear in the directory and/or drive menu.
    65 Small icons appear with each entry to indicate which types of objects file :artwork runin name='\bitmaps\file.bmp'.
    66 directory :artwork runin name='\bitmaps\fldr.bmp'. and/or drive :artwork runin name='\bitmaps\drive.bmp'. they are associated with.
     67Small icons appear with each entry to indicate which types of objects file :artwork runin name='bitmaps\file.bmp'.
     68directory :artwork runin name='bitmaps\fldr.bmp'. and/or drive :artwork runin name='bitmaps\drive.bmp'. they are associated with.
    6769(Note that not all commands are available for all objects on all drives;
    6870CD-ROM drives obviously wouldn't allow Delete and Move commands, for
     
    7981and click mouse button one; however, this command allows you to use
    8082wildcards when renaming if you desire.
    81 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     83:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    8284:p.
    8385:artwork name='..\..\bitmaps\copier.bmp' align=center. :artwork name='..\..\bitmaps\mover.bmp' align=center.
     
    8890:link reftype=hd res=91500.Walk Directories:elink. dialog appears to allow
    8991you to select a target directory.
    90 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     92:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    9193:p.
    9294:hp6.Copy and rename:ehp6. and :hp6.Move and rename:ehp6. allow you to
     
    9597like you can from the command line (COPY thisfile.txt *.bak) by using
    9698wildcards in the filename portion of the destination.
    97 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     99:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    98100:p.
    99101:hp6.Copy and preserve:ehp6. and :hp6.Move and preserve:ehp6. are only
     
    101103copy or move the selected files but preserve the directory relationship
    102104of the files. The effect of this can be non-obvious, so use with care.
    103 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     105:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    104106:p.
    105107Let's say you select three files&colon. G&colon.\FOO\BAR\DUDE,
     
    116118several files together into a single file (you get to set the order of
    117119the files to be merged and the name of the file to which they're
    118 merged). :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     120merged). :artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    119121:p.
    120122:hp6.WPS Copy:ehp6. and :hp6.WPS Move:ehp6. work like their standard
     
    123125example, when moving a directory containing a program suite to
    124126maintain the link between program objects and the program executables
    125 in the directory. :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     127in the directory. :artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    126128:p.
    127129:artwork name='..\..\bitmaps\view.bmp' align=center.
     
    131133click on the button to get a list of choices or click elsewhere to get
    132134a default viewing action (noted below).
    133 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     135:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    134136:p.
    135137:hp6.Autoview:ehp6. views objects through the :link reftype=hd
     
    138140object. When you select Autoview, FM/2 guesses whether the file is text
    139141or binary data and views it accordingly.
    140 :artwork runin name='\bitmaps\file.bmp'.
     142:artwork runin name='bitmaps\file.bmp'.
    141143:p.
    142144:hp6.as text:ehp6. causes FM/2 to view the current file object as text,
    143145using the :link reftype=hd res=97000.configured text viewer:elink. or
    144146the internal if none is configured.
    145 :artwork runin name='\bitmaps\file.bmp'.
     147:artwork runin name='bitmaps\file.bmp'.
    146148:p.
    147149:hp6.as binary:ehp6. causes FM/2 to view the current file object as
     
    149151viewer:elink. or the internal if none is configured. Binary data is
    150152usually viewed as a :link reftype=hd res=98800.hex dump:elink..
    151 :artwork runin name='\bitmaps\file.bmp'.
     153:artwork runin name='bitmaps\file.bmp'.
    152154:hp6.as archive:ehp6. causes FM/2 to open the file in the :link reftype=hd
    153 res=90200.Archive Container:elink. :artwork runin name='\bitmaps\file.bmp'.
     155res=90200.Archive Container:elink. :artwork runin name='bitmaps\file.bmp'.
    154156(only works for archive file types where the underlying program (i.e. Infozip for .zip files)
    155157is defined in archiver.bb2 and the program is in the system path.)
    156 :artwork runin name='\bitmaps\file.bmp'.
     158:artwork runin name='bitmaps\file.bmp'.
    157159:p.
    158160:artwork name='..\..\bitmaps\info.bmp' align=center.
     
    175177the Files->View conditional cascade submenu when the current object is a
    176178directory. (Note: Info is the first item on the drives menu)
    177 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     179:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    178180:p.
    179181:hp6.Quick Tree:ehp6. appears in Directory Containers. You can use this
     
    181183Container. Obviously, if there are no subdirectories to select from,
    182184FM/2 will ignore this command except to tell you.
    183 :artwork runin name='\bitmaps\fldr.bmp'.
     185:artwork runin name='bitmaps\fldr.bmp'.
    184186:p.
    185187:hp6.Update objects:ehp6. updates objects by refreshing the information
    186188FM/2 has on them from disk to make sure it's current (an alternative to
    187189rescan for special situations).
    188 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     190:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    189191:p.
    190192:hp6.Hide objects:ehp6. hides objects (removes them from view in the
    191193container) until you rescan, use the :link reftype=hd res=93400.Filter
    192194dialog:elink. or switch directories or use Unhide (see below).
    193 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     195:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    194196:p.
    195197:hp6.Unhide objects:ehp6. unhides objects (restores them from view in the container)
    196198Unhide doesn't unhide items that are filtered by the current mask or attribute filters
    197 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     199:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    198200:p.
    199201:artwork name='..\..\bitmaps\playmm.bmp' align=center.
     
    211213switch. If not, upgrade to a new version of the FM/2 Utilities.
    212214
    213 :artwork runin name='\bitmaps\file.bmp'.
     215:artwork runin name='bitmaps\file.bmp'.
    214216:p.
    215217:artwork name='..\..\bitmaps\edit.bmp' align=center.
     
    219221click on the button to get a list of choices or click elsewhere to get a
    220222default editing action (noted below).
    221 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     223:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    222224:p.
    223225:hp6.Autoedit:ehp6. edits objects through the :link reftype=hd
     
    226228object. When you select Autoedit, FM/2 guesses whether the file is text
    227229or binary data and edits it accordingly.
    228 :artwork runin name='\bitmaps\file.bmp'.
     230:artwork runin name='bitmaps\file.bmp'.
    229231:p.
    230232:hp6.as text:ehp6. causes FM/2 to edit the current file object as text,
    231233using the :link reftype=hd res=97000.configured text editor:elink. or
    232234the internal if none is configured.
    233 :artwork runin name='\bitmaps\file.bmp'.
     235:artwork runin name='bitmaps\file.bmp'.
    234236:p.
    235237:hp6.as binary:ehp6. causes FM/2 to edit the current file object as
     
    238240res=98800.hex dump:elink.. No default binary editor is provided at
    239241this time, but that may change.
    240 :artwork runin name='\bitmaps\file.bmp'.
     242:artwork runin name='bitmaps\file.bmp'.
    241243:p.
    242244Edit :link reftype=hd res=99980.Drive flags:elink. is found on the drives context
    243 menu. :artwork runin name='\bitmaps\drive.bmp'.
     245menu. :artwork runin name='bitmaps\drive.bmp'.
    244246:p.
    245247:artwork name='..\..\bitmaps\attrlist.bmp' align=center.
     
    249251the default for the Files->Edit conditional cascade submenu when a
    250252directory is the current object.
    251 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     253:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    252254:p.
    253255:artwork name='..\..\bitmaps\ea.bmp' align=center.
     
    256258you to view an object's extended attributes (EAs) and to edit and add
    257259text attributes.
    258 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     260:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    259261:p.
    260262:hp6.Subject:ehp6. allows you to give an object a description. This
     
    262264descriptions -- you can see and edit it on the File page of an object's
    263265Settings notebook.
    264 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     266:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    265267:p.
    266268:artwork name='..\..\bitmaps\print.bmp' align=center.
     
    274276Actually, if using the standard WPS, it's recommended that you simply
    275277drag files to the printer object and drop them instead of using this
    276 command. :artwork runin name='\bitmaps\file.bmp'.
     278command. :artwork runin name='bitmaps\file.bmp'.
    277279:p.
    278280:artwork name='..\..\bitmaps\opend.bmp' align=center.
     
    282284click on the button to get a list of choices or click elsewhere to get a
    283285default open action for files is to either run them (executable files) or open them
    284 based on their file association. :artwork runin name='\bitmaps\file.bmp'.
    285 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     286based on their file association. :artwork runin name='bitmaps\file.bmp'.
     287:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    286288:p.
    287289The :hp6.Settings notebook:ehp6. option opens the object's WPS properties notebooks.
    288 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     290:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    289291:p.
    290292Open a directory or drive as a WPS Folder in either :hp6.icon, details or tree:ehp6. view
    291 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     293:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    292294:p.
    293295Open a new FM/2 window (container; the default for directories and drives).
    294 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     296:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    295297:p.
    296298Opening a file's Default view will honor any OS/2 associations that you have
     
    305307with Shadows as the default command. Create shadows appears as a
    306308a top level menu item on the drives object menu.
    307 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     309:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    308310:p.
    309311:hp6.:link reftype=hd res=93600.Shadow:elink.:ehp6. builds WPS shadow
    310312objects on your desktop or :hp6.Shadows in folders:ehp6. for selected
    311 object(s). :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     313object(s). :artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    312314:p.
    313315You can also create :hp6.Real Objects:ehp6. for files
    314 :artwork runin name='\bitmaps\file.bmp'.
     316:artwork runin name='bitmaps\file.bmp'.
    315317:p.
    316318The save lists to clipboard/file submenu allows you to save lists to the clipboard or a file
     
    324326the files over a modem or network. You can save/append the full path names or
    325327just the filenames.
    326 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     328:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    327329:p.
    328330:artwork name='..\..\bitmaps\savelist.bmp' align=center.
     
    331333save selected objects as a list to a text file. Lists can include file
    332334sizes, subjects, etc.
    333 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     335:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    334336:p.
    335337:artwork name='..\..\bitmaps\collect.bmp' align=center.
     
    338340res=90100.Collector:elink. and places the selected files and directories
    339341into it. You can also open the Collector and drag things into it.
    340 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     342:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    341343:p.
    342344:hp6.Collect List in file(s):ehp6. collects the files listed inside the
     
    345347contained in the filenames, enclose the filenames in "quote marks."
    346348Filenames must be full pathnames (d&colon.\path\filename). Directories as
    347 well as files can be Collected. :artwork runin name='\bitmaps\file.bmp'.
     349well as files can be Collected. :artwork runin name='bitmaps\file.bmp'.
    348350:p.
    349351:artwork name='..\..\bitmaps\archive.bmp' align=center.
     
    351353:hp6.:link reftype=hd res=90300.Archive:elink.:ehp6. allows you to build
    352354an archive containing the selected object(s).
    353 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     355:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    354356:p.
    355357:artwork name='..\..\bitmaps\extract.bmp' align=center.
    356358:p.
    357359:hp6.:link reftype=hd res=91000.Extract:elink.:ehp6. allows you to
    358 extract files from selected archives. :artwork runin name='\bitmaps\file.bmp'.
     360extract files from selected archives. :artwork runin name='bitmaps\file.bmp'.
    359361:p.
    360362:hp6.UUDecode:ehp6. decodes files that were encoded with UUEncode, a
    361363common protocol on the Internet. Files created by UUDecoding are
    362 appended if they already exist. :artwork runin name='\bitmaps\file.bmp'.
     364appended if they already exist. :artwork runin name='bitmaps\file.bmp'.
    363365:p.
    364366:artwork name='..\..\bitmaps\delete.bmp' align=center.
     
    373375Xworkplaces/Eworkplace trahshcan from which they may be restorable.:link reftype=hd
    374376res=99950.Delete = move to trashcan:elink.
    375 :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     377:artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    376378:p.
    377379:artwork name='..\..\bitmaps\permdel.bmp' align=center.
     
    386388:link reftype=launch object='CMD.EXE' data='/C HELP UNDELETE'.HELP
    387389UNDELETE:elink. at a command line for more information on enabling
    388 Undelete). :artwork runin name='\bitmaps\file.bmp'. :artwork runin name='\bitmaps\fldr.bmp'.
     390Undelete). :artwork runin name='bitmaps\file.bmp'. :artwork runin name='bitmaps\fldr.bmp'.
    389391:p.
    390392:artwork name='..\..\bitmaps\rescan.bmp' align=center.
     
    394396can cause changes that FM/2 cannot know about automatically. This
    395397command will ensure that your display is current.
    396 :artwork runin name='\bitmaps\drive.bmp'.
     398:artwork runin name='bitmaps\drive.bmp'.
    397399:p.
    398400:hp6.Refresh removable media:ehp6. calls LVM.EXE to find new drives and then
    399401rescans all the drives in the tree container. This item will not appear if
    400402LVM.EXE isn't found in your PATH.
    401 :artwork runin name='\bitmaps\drive.bmp'.
     403:artwork runin name='bitmaps\drive.bmp'.
    402404:p.
    403405:hp6.Expand:ehp6. expands the tree from the point where the context menu
    404406was requested to the bottom of the branch. This isn't the same as clicking
    405407the [+] symbol as it expands :hp1.all:ehp1. branches.
    406 :artwork runin name='\bitmaps\drive.bmp'.
     408:artwork runin name='bitmaps\drive.bmp'.
    407409:p.
    408410:hp6.Collapse:ehp6. collapses the tree from the point where the context
    409411menu was requested to the bottom of the branch. This isn't the same as
    410412clicking the [-] symbol as it collapses :hp1.all:ehp1. branches.
    411 :artwork runin name='\bitmaps\drive.bmp'.
     413:artwork runin name='bitmaps\drive.bmp'.
    412414:p.
    413415:artwork name='..\..\bitmaps\mkdir.bmp' align=center.
     
    417419as a starting point for convenience. Directories may be created many
    418420levels deep in one pass.
    419 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     421:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    420422:p.
    421423The Miscellaneous cascade menu appears on directory and drive context menus
     
    424426:hp6.:link reftype=hd res=95200.Sizes:elink.:ehp6. brings up a dialog
    425427showing how many bytes are in the selected directory and its
    426 subdirectories. :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     428subdirectories. :artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    427429:p.
    428430:hp6.Show all files:ehp6. is a command available on drive and directory objects
     
    430432:link reftype=hd res=98500.See all files:elink. window and shows all
    431433the files in the directory and all its subdirectories.
    432 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
    433 :p.
    434 :artwork name='..\..\bitmaps\find.bmp' align=center.
     434:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
     435:p.
     436:artwork name='bitmaps\find.bmp' align=center.
    435437:p.
    436438:hp6.Seek and scan files:ehp6. is a command available on drive and directory objects
     
    439441the search parameters the drive or directy this is selected from is inserted as the
    440442root for the search.
    441 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     443:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    442444:p.
    443445:hp6.:link reftype=hd res=92500.Undelete Files:elink.:ehp6.
    444 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     446:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    445447:p.
    446448:hp6.Check Disk:ehp6. runs PMCHKDSK.EXE on the selected drive. This
     
    448450only in context menus requested on drives (root directories). Note
    449451that OS/2 cannot correct defects on disks that are in use by the
    450 system or programs (including FM/2). :artwork runin name='\bitmaps\drive.bmp'.
     452system or programs (including FM/2). :artwork runin name='bitmaps\drive.bmp'.
    451453:p.
    452454:hp6.Format Disk:ehp6. runs PMFORMAT.EXE on the selected drive.
    453455:hp8.Formatting a disk will destroy any information already on the
    454456disk.:ehp8. This is available only in context menus requested on drives
    455 (root directories). :artwork runin name='\bitmaps\drive.bmp'.
     457(root directories). :artwork runin name='bitmaps\drive.bmp'.
    456458:p.
    457459:hp6.Partition Disks:ehp6. has four choices for partitioning tools.
     
    467469Disk management. It is a JAVA based program and earily versions only work with JAVA 1.1.8.
    468470FDISKPM is the partition management tool for preLVM systems and should not be used
    469 on LVM based sytems. :artwork runin name='\bitmaps\drive.bmp'.
     471on LVM based sytems. :artwork runin name='bitmaps\drive.bmp'.
    470472:p.
    471473:hp6.Optimize:ehp6. runs a .CMD file with the name <Filesystem>OPT.CMD,
     
    482484FAT optimizer) it's a good idea to back up first. You shouldn't run the
    483485FAT optimizer on compressed drives -- use the utilities that came with
    484 your compression program instead. :artwork runin name='\bitmaps\drive.bmp'.
     486your compression program instead. :artwork runin name='bitmaps\drive.bmp'.
    485487:p.
    486488:hp6.Detach:ehp6. detaches a network drive.
    487 :artwork runin name='\bitmaps\drive.bmp'.
     489:artwork runin name='bitmaps\drive.bmp'.
    488490:p.
    489491:hp6.Eject:ehp6. ejects removable media from drives (for instance,
    490492opens the door of a CD ROM drive).
    491 :artwork runin name='\bitmaps\drive.bmp'.
     493:artwork runin name='bitmaps\drive.bmp'.
    492494:p.
    493495:hp6.Lock:ehp6. locks a removable drive.
    494 :artwork runin name='\bitmaps\drive.bmp'.
     496:artwork runin name='bitmaps\drive.bmp'.
    495497:p.
    496498:hp6.Unlock:ehp6. unlocks a removable drive.
    497 :artwork runin name='\bitmaps\drive.bmp'.
     499:artwork runin name='bitmaps\drive.bmp'.
    498500:p.
    499501:hp6.:link reftype=hd res=90900.Drive Info:elink.:ehp6. is the first menu item on the drives
    500 context menu. :artwork runin name='\bitmaps\drive.bmp'.
     502context menu. :artwork runin name='bitmaps\drive.bmp'.
    501503
    502504:h2 res=93710 name=PANEL_CONTEXTCNR.Context menus affecting containers
     
    786788You can always go directly to UNDELETE.COM if you have the need for more
    787789control. This is provided only for convenience.
    788 :artwork runin name='\bitmaps\fldr.bmp'. :artwork runin name='\bitmaps\drive.bmp'.
     790:artwork runin name='bitmaps\fldr.bmp'. :artwork runin name='bitmaps\drive.bmp'.
    789791.br
    790792
  • trunk/dll/ipf/notebook.ipf

    r1401 r1411  
    1515.* 20 Jul 08 JBS Ticket 114: Support user-selectable env. strings in Tree container.
    1616.* 08 Mar 09 GKY Added option to turn alert and/or error beeps off
     17.* 12 Mar 09 SHL Update container search description
    1718.*
    1819.***********************************************************************
     
    103104use selected object(s) (rather than keying on the current object).
    104105:p.
    105 The :hp6.No container search:ehp6. toggle, if checked, prevents FM/2
     106The :hp6.No extended container search:ehp6. toggle, if checked, prevents FM/2
    106107from performing extended searching in containers -- instead, the
    107108standard OS/2 method is used, where the cursor moves to the nearest
    108109object starting with the depressed letter and the object is selected.
    109 Note that you can get this standard effect with this toggle left on by
    110 pressing the :color fc=default bc=palegray.Shift:color fc=default bc=default. key along with the letter. Container searching
    111 allows you to enter multiple characters which are searched for at the
    112 start of filenames. The record is made the current (cursored) object.
    113 If the record matches all the letters typed exactly, it is also
    114 selected. A pause of more than about two seconds in typing resets the
    115 search string. :hp1.Warning:ehp1.&colon. this doesn't work right on
     110Note that you override the configured value of this feature by
     111pressing the :color fc=default bc=palegray.Shift:color fc=default bc=default.
     112key along with the letter.
     113Extended container searching allows you to enter multiple characters which
     114are searched for at the start of filenames.
     115The record is made the current (cursored) object.
     116The leading backslash can be omitted from directory names where there is no ambiguity.
     117If the record matches all the letters typed exactly, it is also selected.
     118A pause of more than about two seconds in typing resets the search string.
     119The Escape key clears the search string.
     120Backspace deletes the last character from the search string.
     121Space toggles the object selection unless it matches a space in the object name.
     122:hp1.Warning:ehp1.&colon. this doesn't work right on
    116123some versions of Warp, where the OS/2 CM_SEARCHSTRING container
    117124message's behavior is buggy. It's not dangerous, it just doesn't
  • trunk/dll/treecnr.c

    r1407 r1411  
    6464  08 Mar 09 GKY Renamed commafmt.h i18nutil.h
    6565  08 Mar 09 GKY Additional strings move to PCSZs in init.c
     66  12 Mar 09 SHL Use common SearchContainer
    6667  14 Mar 09 GKY Prevent execution of UM_SHOWME while drive scan is occuring
    6768
     
    625626#     endif
    626627      if (StubbyScanCount != 0) { //prevent treeswitch from hanging fm2 during startup GKY 3-14-09
    627         DosSleep(50);
    628         PostMsg(hwndTree, UM_SHOWME, mp1, MPVOID);
     628        DosSleep(50);
     629        PostMsg(hwndTree, UM_SHOWME, mp1, MPVOID);
    629630      }
    630631      dcd = INSTDATA(hwnd);
     
    971972  static APPNOTIFY *apphead = NULL, *apptail = NULL;
    972973  DIRCNRDATA *dcd = INSTDATA(hwnd);
     974  PCNRITEM pci;
    973975
    974976  switch (msg) {
     
    10001002          PostMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_DELETE, 0), MPVOID);
    10011003        break;
    1002       }
    1003     }
    1004     if (shiftstate || fNoSearch)
    1005       break;
    1006     if (SHORT1FROMMP(mp1) & KC_CHAR) {
    1007 
    1008       ULONG thistime, len;
    1009       SEARCHSTRING srch;
    1010       PCNRITEM pci;
    1011 
    1012       if (!dcd)
    1013         break;
    1014       switch (SHORT1FROMMP(mp2)) {
    1015       case '\x1b':
    1016       case '\r':
    1017       case '\n':
    1018         dcd->lasttime = 0;
    1019         *dcd->szCommonName = 0;
    1020         break;
    1021       default:
    1022         thistime = WinQueryMsgTime(WinQueryAnchorBlock(hwnd));
    1023         if (thistime > dcd->lasttime + 1250)
    1024           *dcd->szCommonName = 0;
    1025         dcd->lasttime = thistime;
    1026         if (SHORT1FROMMP(mp2) == ' ' && !*dcd->szCommonName)
    1027           break;
    1028       KbdRetry:
    1029         len = strlen(dcd->szCommonName);
    1030         if (len >= CCHMAXPATH - 1) {
    1031           *dcd->szCommonName = 0;
    1032           len = 0;
    1033         }
    1034         dcd->szCommonName[len] = toupper(SHORT1FROMMP(mp2));
    1035         dcd->szCommonName[len + 1] = 0;
    1036         memset(&srch, 0, sizeof(SEARCHSTRING));
    1037         srch.cb = (ULONG) sizeof(SEARCHSTRING);
    1038         srch.pszSearch = (PSZ) dcd->szCommonName;
    1039         srch.fsPrefix = TRUE;
    1040         srch.fsCaseSensitive = FALSE;
    1041         srch.usView = CV_ICON;
    1042         pci = WinSendMsg(hwnd,
    1043                          CM_SEARCHSTRING,
    1044                          MPFROMP(&srch), MPFROMLONG(CMA_FIRST));
    1045         if (pci && (INT) pci != -1) {
    1046           /* make found item current item */
    1047           WinSendMsg(hwnd,
    1048                      CM_SETRECORDEMPHASIS,
    1049                      MPFROMP(pci), MPFROM2SHORT(TRUE, CRA_CURSORED));
    1050           /* make sure that record shows in viewport */
    1051           ShowCnrRecord(hwnd, (PMINIRECORDCORE) pci);
    1052           return (MRESULT) TRUE;
    1053         }
    1054         else {
    1055           if (SHORT1FROMMP(mp2) == ' ') {
    1056             dcd->szCommonName[len] = 0;
    1057             break;
    1058           }
    1059           *dcd->szCommonName = 0;
    1060           dcd->lasttime = 0;
    1061           if (len)                      // retry as first letter if no match
    1062             goto KbdRetry;
    1063         }
    1064         break;
    1065       }
    1066     }
    1067     break;
     1004      } // switch
     1005    }
     1006
     1007    if (SearchContainer(hwnd, msg, mp1, mp2))
     1008      return (MRESULT)TRUE;             // Avoid default handler
     1009
     1010    break;                              // Let default handler see key
    10681011
    10691012  case WM_MOUSEMOVE:
     
    11271070  case UM_FILESMENU:
    11281071    {
    1129       PCNRITEM pci;
    11301072      HWND menuHwnd = (HWND) 0;
    11311073      FSALLOCATE fsa;
     
    12301172          WinSetWindowText(WinWindowFromID(dcd->hwndFrame,
    12311173                                           MAIN_STATUS), pci->pszFileName);
    1232         if (fMoreButtons && hwndName) {
    1233           CHAR szDate[DATE_BUF_BYTES];
    1234 
    1235           DateFormat(szDate, pci->date);
     1174        if (fMoreButtons && hwndName) {
     1175          CHAR szDate[DATE_BUF_BYTES];
     1176
     1177          DateFormat(szDate, pci->date);
    12361178          WinSetWindowText(hwndName, pci->pszFileName);
    12371179          sprintf(str, "%s %02u%s%02u%s%02u", szDate,
    1238                   pci->time.hours, TimeSeparator,
    1239                   pci->time.minutes, TimeSeparator, pci->time.seconds);
     1180                  pci->time.hours, TimeSeparator,
     1181                  pci->time.minutes, TimeSeparator, pci->time.seconds);
    12401182          WinSetWindowText(hwndDate, str);
    12411183          WinSetWindowText(hwndAttr, pci->pszDispAttr);
     
    18471789                UnFlesh(hwnd, pci);
    18481790                PostMsg(hwnd, UM_RESCAN, MPVOID, MPVOID);
    1849                 if (!fAlertBeepOff)
     1791                if (!fAlertBeepOff)
    18501792                  DosBeep(250, 100);
    18511793              }
     
    19161858          !(pci->flags & RECFLAGS_ENV) && IsFullName(pci->pszFileName)) {
    19171859        if (driveflags[toupper(*pci->pszFileName) - 'A'] & DRIVE_INVALID) {
    1918           if (!fAlertBeepOff)
     1860          if (!fAlertBeepOff)
    19191861            DosBeep(50, 100);
    19201862          if (hwndStatus)
Note: See TracChangeset for help on using the changeset viewer.