Changeset 460 for trunk/dll/arccnrs.c


Ignore:
Timestamp:
Aug 24, 2006, 7:11:45 AM (19 years ago)
Author:
root
Message:

Integrate John Small's switch list title logic

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/arccnrs.c

    r426 r460  
    2929  31 Jul 06 SHL Lower priority for archives with more than 1000 entries
    3030  02 Aug 06 SHL Add logic to stop processing large archives
     31  23 Aug 06 SHL Integrate John Small's switch list title logic
    3132
    3233***********************************************************************/
     
    13321333        if (mp1)
    13331334          strcpy(dcd->arcname,(CHAR *)mp1);     // Update name on request
    1334         WinSetWindowText(dcd->hwndFrame,"AV/2");
    1335         WinSetWindowText(WinWindowFromID(dcd->hwndFrame,FID_TITLEBAR),dcd->arcname);
    13361335        dcd->ullTotalBytes = dcd->totalfiles =
    13371336          dcd->selectedfiles = dcd->selectedbytes = 0;
     
    34313430  DIRCNRDATA   *dcd;
    34323431  ARC_TYPE     *info = sinfo;
    3433   CHAR          fullname[CCHMAXPATH],*p,temp;
     3432  CHAR          title[MAXNAMEL + 1] = "AV/2 - ";
     3433  CHAR          fullname[CCHMAXPATH + 8], *p, temp;
    34343434  static USHORT idinc = 0;
    34353435
     
    34563456    if (!info)
    34573457      return hwndFrame;
     3458    if (strlen(title) + strlen(fullname) > MAXNAMEL)
     3459    {
     3460        p = title + strlen(title);
     3461        strncpy(p, fullname, MAXNAMEL/2 - 5);
     3462        strcpy(p + MAXNAMEL/2 - 5, "...");
     3463        strcat(title, fullname + strlen(fullname) - (MAXNAMEL/2 - 5));
     3464    }
     3465    else
     3466    {
     3467        strcat(title, fullname);
     3468    }
    34583469    hwndFrame = WinCreateStdWindow(hwndParent,
    34593470                                   WS_VISIBLE,
    34603471                                   &FrameFlags,
    34613472                                   GetPString(IDS_WCARCCONTAINER),
    3462                                    NULL,
     3473                                   title,
    34633474                                   WS_VISIBLE | fwsAnimate,
    34643475                                   FM3ModHandle,
     
    35673578                          QWL_USER,
    35683579                          (PVOID)dcd);
    3569           {
    3570             CHAR s[CCHMAXPATH + 8];
    3571 
    3572             sprintf(s,"AV/2: %s",dcd->arcname);
    3573             WinSetWindowText(hwndFrame,s);
    3574             WinSetWindowText(WinWindowFromID(hwndFrame,FID_TITLEBAR),s);
    3575           }
    35763580          dcd->oldproc = WinSubclassWindow(dcd->hwndCnr,
    35773581                                           (PFNWP)ArcCnrWndProc);
Note: See TracChangeset for help on using the changeset viewer.