Changeset 1482 for trunk/dll/mainwnd.c


Ignore:
Timestamp:
Dec 13, 2009, 8:59:47 PM (16 years ago)
Author:
Gregg Young
Message:

Fixed separate parameters; added the ability to set it either globally or for just one app; some files only contain white space changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/dll/mainwnd.c

    r1471 r1482  
    9999  12 Sep 09 GKY Add FM3.INI User ini and system ini to submenu for view ini
    100100  14 Sep 09 SHL Blink thread LEDs when workers busy
     101  13 Dec 09 GKY Fixed separate paramenters. Please note that appname should be used in
     102                profile calls for user settings that work and are setable in more than one
     103                miniapp; FM3Str should be used for setting only relavent to FM/2 or that
     104                aren't user settable; realappname should be used for setting applicable to
     105                one or more miniapp but not to FM/2
    101106
    102107***********************************************************************/
     
    32313236  // Delete saved state if internally saved state
    32323237  fDeleteState = strcmp(pszStateName, PCSZ_FM2TEMPTEXT) == 0;
    3233 
    3234   //size = (ULONG)0;
    32353238  sprintf(szKey, "%sToolbar", szPrefix);
    3236   //if (PrfQueryProfileSize(fmprof, FM3Str, szKey, &size) && size)
    32373239  {
    32383240    if (fToolsChanged)
     
    32433245    PostMsg(hwndToolback, UM_SETUP2, MPVOID, MPVOID);
    32443246  }
    3245   //size = (ULONG)0;
    32463247  sprintf(szKey, "%sTargetDir", szPrefix);
    3247   //if (PrfQueryProfileSize(fmprof, FM3Str, szKey, &size) && size)
    32483248  {
    32493249    PrfQueryProfileString(fmprof, FM3Str, szKey, NULL, targetdir, sizeof(targetdir));
     
    32533253  size = sizeof(SWP);
    32543254  sprintf(szKey, "%sMySizeLastTime", szPrefix);
    3255   if (!PrfQueryProfileData(fmprof,
    3256                            FM3Str,
    3257                            szKey,
    3258                            (PVOID) &swpO,
    3259                            &size) ||
     3255  if (!PrfQueryProfileData(fmprof, FM3Str, szKey, (PVOID) &swpO, &size) ||
    32603256      size != sizeof(SWP) || !swp.cx || !swp.cy)
    32613257  {
     
    33033299  sprintf(szKey, "%sNumDirsLastTime", szPrefix);
    33043300  size = sizeof(ULONG);
    3305   if (PrfQueryProfileData(fmprof,
    3306                           FM3Str, szKey, (PVOID) &numsaves, &size)) {
     3301  if (PrfQueryProfileData(fmprof, FM3Str, szKey, (PVOID) &numsaves, &size)) {
    33073302    if (fDeleteState)
    33083303      PrfWriteProfileData(fmprof, FM3Str, szKey, NULL, 0L);
     
    33683363                strcpy(eos, "Sort");
    33693364                size = sizeof(INT);
    3370                 if (PrfQueryProfileData(fmprof,
    3371                                         FM3Str,
    3372                                         szKey,
    3373                                         (PVOID) &dcd->sortFlags,
     3365                if (PrfQueryProfileData(fmprof, FM3Str, szKey, (PVOID) &dcd->sortFlags,
    33743366                                        &size)) {
    33753367                  if (!dcd->sortFlags)
     
    33783370                size = sizeof(MASK);
    33793371                strcpy(eos, "Filter");
    3380                 if (PrfQueryProfileData(fmprof,
    3381                                         FM3Str,
    3382                                         szKey,
    3383                                         (PVOID) &dcd->mask, &size)) {
     3372                if (PrfQueryProfileData(fmprof, FM3Str, szKey, (PVOID) &dcd->mask, &size)) {
    33843373                  if (*dcd->mask.szMask)
    33853374                    WinSendMsg(WinWindowFromID(hwndC, DIR_CNR),
     
    33903379                if (!noview) {
    33913380                  size = sizeof(ULONG);
    3392                   if (PrfQueryProfileData(fmprof,
    3393                                           FM3Str,
    3394                                           szKey,
    3395                                           (PVOID) &dcd->flWindowAttr,
     3381                  if (PrfQueryProfileData(fmprof, FM3Str, szKey, (PVOID) &dcd->flWindowAttr,
    33963382                                          &size)) {
    33973383
     
    47324718            sprintf(szKey, "%s.NumDirsLastTime", szStateName);
    47334719            size = sizeof(ULONG);
    4734             if (!PrfQueryProfileData(fmprof,
    4735                                      FM3Str,
    4736                                      szKey,
    4737                                      (PVOID)&numsaves,
    4738                                      &size)) {
     4720            if (!PrfQueryProfileData(fmprof, FM3Str, szKey, (PVOID) &numsaves, &size)) {
    47394721              saymsg(MB_ENTER | MB_ICONASTERISK, hwnd,
    47404722                     GetPString(IDS_WARNINGTEXT),
     
    57255707
    57265708    size = sizeof(BOOL);
    5727     if (PrfQueryProfileData(fmprof,
    5728                             FM3Str,
    5729                             "MenuInvisible", &temp, &size) && size && temp)
     5709    if (PrfQueryProfileData(fmprof, FM3Str, "MenuInvisible", &temp, &size) &&
     5710        size && temp)
    57305711      WinSendMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_HIDEMENU, 0), MPVOID);
    57315712    size = sizeof(BOOL);
    5732     if (PrfQueryProfileData(fmprof,
    5733                             FM3Str, "FreeTree", &temp, &size) && size && temp)
     5713    if (PrfQueryProfileData(fmprof, FM3Str, "FreeTree", &temp, &size) &&
     5714        size && temp)
    57345715      WinSendMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_FREETREE, 0), MPVOID);
    57355716    size = sizeof(BOOL);
    5736     if (PrfQueryProfileData(fmprof,
    5737                             FM3Str,
    5738                             "AutoTile", &temp, &size) && size && !temp)
     5717    if (PrfQueryProfileData(fmprof, FM3Str, "AutoTile", &temp, &size) &&
     5718        size && !temp)
    57395719      WinSendMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_AUTOTILE, 0), MPVOID);
    57405720    size = sizeof(BOOL);
    5741     if (PrfQueryProfileData(fmprof,
    5742                             FM3Str, "Toolbar", &temp, &size) && size && !temp)
     5721    if (PrfQueryProfileData(fmprof, appname, "Toolbar", &temp, &size) && size && !temp)
    57435722      WinSendMsg(hwnd, WM_COMMAND, MPFROM2SHORT(IDM_TOOLBAR, 0), MPVOID);
    57445723
Note: See TracChangeset for help on using the changeset viewer.