Changeset 954 for trunk/dll/treecnr.c


Ignore:
Timestamp:
Feb 16, 2008, 4:58:43 AM (17 years ago)
Author:
Steven Levine
Message:

Rework ResizeChildren to resize drive tree correctly
Avoid trap in TreeCnrWndProc WM_SAVEAPPLICATION

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/treecnr.c

    r953 r954  
    4545  10 Jan 08 SHL Sync with CfgDlgProc mods
    4646  15 Feb 08 SHL Sync with settings menu rework
     47  15 Feb 08 SHL Avoid death if tree container 0 width
    4748
    4849***********************************************************************/
     
    28282829      if (!(swp.fl & (SWP_MINIMIZE | SWP_MAXIMIZE | SWP_HIDE))) {
    28292830        WinQueryWindowPos(dcd->hwndParent, &swpP);
    2830         ratio = (swpP.cx * 100) / swp.cx;
    2831         if (ratio > 0)
    2832           PrfWriteProfileData(fmprof, appname, "TreeWindowRatio",
    2833                               &ratio, sizeof(INT));
     2831        if (swp.cx) {
     2832          ratio = (swpP.cx * 100) / swp.cx;
     2833          if (ratio > 0)
     2834            PrfWriteProfileData(fmprof, appname, "TreeWindowRatio",
     2835                                &ratio, sizeof(INT));
     2836        }
    28342837      }
    28352838    }
Note: See TracChangeset for help on using the changeset viewer.