Ignore:
Timestamp:
May 18, 2008, 4:37:11 PM (16 years ago)
Author:
dai_9181
Message:

ProjectInfo構造体のpWindowInfoメンバをwindowInfosメンバに置き換えた。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ab5.0/abdev/abdev/Rad_UndoRedo.cpp

    r475 r609  
    77    extern MDIINFO MdiInfo[MAX_WNDNUM];
    88    extern PROJECTINFO ProjectInfo;
    9     int i,WndInfoNum;
     9    int i;
    1010    DWORD dw;
    1111    char *temporary;
     
    2121    pUndoState->NowPos=i;
    2222
    23     WndInfoNum=GetWndInfoNum(MdiInfo[WndNum].path);
     23    WINDOW_INFO *pWindowInfo = GetWndInfo(MdiInfo[WndNum].path);
     24    int WndInfoNum = GetWndInfoNum(MdiInfo[WndNum].path);
    2425    switch(pUndoState->Command[pUndoState->NowPos]){
    2526        case RAD_UNDO_INSERTITEM:
     
    4445                names=(RAD_UNDOSTATE_NAME *)pUndoState->lpdwData[pUndoState->NowPos];
    4546
    46                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].name;
    47                 ProjectInfo.pWindowInfo[WndInfoNum].name=names->name;
     47                temporary=pWindowInfo->name;
     48                pWindowInfo->name=names->name;
    4849                names->name=temporary;
    4950                GlobalFree(MdiInfo[WndNum].path);
    50                 MdiInfo[WndNum].path=(char *)GlobalAlloc(GMEM_FIXED,lstrlen(ProjectInfo.pWindowInfo[WndInfoNum].name)+1);
    51                 lstrcpy(MdiInfo[WndNum].path,ProjectInfo.pWindowInfo[WndInfoNum].name);
    52 
    53                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].HandleName;
    54                 ProjectInfo.pWindowInfo[WndInfoNum].HandleName=names->HandleName;
     51                MdiInfo[WndNum].path=(char *)GlobalAlloc(GMEM_FIXED,lstrlen(pWindowInfo->name)+1);
     52                lstrcpy(MdiInfo[WndNum].path,pWindowInfo->name);
     53
     54                temporary=pWindowInfo->HandleName;
     55                pWindowInfo->HandleName=names->HandleName;
    5556                names->HandleName=temporary;
    5657
    57                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].CallBackName;
    58                 ProjectInfo.pWindowInfo[WndInfoNum].CallBackName=names->CallBackName;
     58                temporary=pWindowInfo->CallBackName;
     59                pWindowInfo->CallBackName=names->CallBackName;
    5960                names->CallBackName=temporary;
    6061            }
    6162            else{
    62                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName;
    63                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     63                temporary=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName;
     64                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    6465                pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    6566            }
     
    6970        case RAD_UNDO_CAPTION:
    7071            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    71                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].caption;
    72                 ProjectInfo.pWindowInfo[WndInfoNum].caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     72                temporary=pWindowInfo->caption;
     73                pWindowInfo->caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    7374                pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    7475            }
    7576            else{
    76                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption;
    77                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     77                temporary=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption;
     78                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    7879                pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    7980            }
    8081            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    8182                ChangePropertyWindow(WndNum,WndInfoNum);
    82             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     83            DrawRadWindow(WndNum,pWindowInfo);
    8384            break;
    8485        case RAD_UNDO_FONT:
    8586            LOGFONT *pLogFont,lf;
    8687            pLogFont=(LOGFONT *)pUndoState->lpdwData[pUndoState->NowPos];
    87             lf=ProjectInfo.pWindowInfo[WndInfoNum].LogFont;
    88             ProjectInfo.pWindowInfo[WndInfoNum].LogFont=*pLogFont;
     88            lf=pWindowInfo->LogFont;
     89            pWindowInfo->LogFont=*pLogFont;
    8990            *pLogFont=lf;
    9091            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    9192                ChangePropertyWindow(WndNum,WndInfoNum);
    92             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     93            DrawRadWindow(WndNum,pWindowInfo);
    9394            break;
    9495        case RAD_UNDO_BGCOLOR:
    95             dw=ProjectInfo.pWindowInfo[WndInfoNum].bgColor;
    96             ProjectInfo.pWindowInfo[WndInfoNum].bgColor=pUndoState->lpdwData[pUndoState->NowPos];
     96            dw=pWindowInfo->bgColor;
     97            pWindowInfo->bgColor=pUndoState->lpdwData[pUndoState->NowPos];
    9798            pUndoState->lpdwData[pUndoState->NowPos]=dw;
    9899            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    99100                ChangePropertyWindow(WndNum,WndInfoNum);
    100             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     101            DrawRadWindow(WndNum,pWindowInfo);
    101102            break;
    102103        case RAD_UNDO_WINDOWMENU:
    103             temporary=ProjectInfo.pWindowInfo[WndInfoNum].MenuID;
    104             ProjectInfo.pWindowInfo[WndInfoNum].MenuID=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     104            temporary=pWindowInfo->MenuID;
     105            pWindowInfo->MenuID=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    105106            pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    106107            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
     
    108109            break;
    109110        case RAD_UNDO_ICONRES:
    110             temporary=ProjectInfo.pWindowInfo[WndInfoNum].IconResName;
    111             ProjectInfo.pWindowInfo[WndInfoNum].IconResName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     111            temporary=pWindowInfo->IconResName;
     112            pWindowInfo->IconResName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    112113            pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    113114            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
     
    116117        case RAD_UNDO_STYLE:
    117118            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    118                 dw=ProjectInfo.pWindowInfo[WndInfoNum].style;
    119                 ProjectInfo.pWindowInfo[WndInfoNum].style=pUndoState->lpdwData[pUndoState->NowPos];
    120                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    121             }
    122             else{
    123                 dw=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style;
    124                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style=pUndoState->lpdwData[pUndoState->NowPos];
    125                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    126             }
    127             if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    128                 ChangePropertyWindow(WndNum,WndInfoNum);
    129             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     119                dw=pWindowInfo->style;
     120                pWindowInfo->style=pUndoState->lpdwData[pUndoState->NowPos];
     121                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     122            }
     123            else{
     124                dw=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style;
     125                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style=pUndoState->lpdwData[pUndoState->NowPos];
     126                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     127            }
     128            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
     129                ChangePropertyWindow(WndNum,WndInfoNum);
     130            DrawRadWindow(WndNum,pWindowInfo);
    130131            break;
    131132        case RAD_UNDO_EXSTYLE:
    132133            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    133                 dw=ProjectInfo.pWindowInfo[WndInfoNum].ExStyle;
    134                 ProjectInfo.pWindowInfo[WndInfoNum].ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
    135                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    136             }
    137             else{
    138                 dw=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle;
    139                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
    140                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    141             }
    142             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     134                dw=pWindowInfo->ExStyle;
     135                pWindowInfo->ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
     136                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     137            }
     138            else{
     139                dw=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle;
     140                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
     141                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     142            }
     143            DrawRadWindow(WndNum,pWindowInfo);
    143144            break;
    144145        case RAD_UNDO_POSITION:
     
    146147            pReadPointAndSize=(POINTANDSIZE *)pUndoState->lpdwData[pUndoState->NowPos];
    147148            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    148                 PointAndSize.size=ProjectInfo.pWindowInfo[WndInfoNum].size;
    149                 ProjectInfo.pWindowInfo[WndInfoNum].size=pReadPointAndSize->size;
    150             }
    151             else{
    152                 PointAndSize.pos=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos;
    153                 PointAndSize.size=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size;
    154                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos=pReadPointAndSize->pos;
    155                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size=pReadPointAndSize->size;
     149                PointAndSize.size=pWindowInfo->size;
     150                pWindowInfo->size=pReadPointAndSize->size;
     151            }
     152            else{
     153                PointAndSize.pos=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos;
     154                PointAndSize.size=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size;
     155                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos=pReadPointAndSize->pos;
     156                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size=pReadPointAndSize->size;
    156157            }
    157158            *pReadPointAndSize=PointAndSize;
    158             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     159            DrawRadWindow(WndNum,pWindowInfo);
    159160            SetStatusText(NULL);
    160161
     
    166167            pImageCtrlInfo=(IMAGECTRLINFO *)pUndoState->lpdwData[pUndoState->NowPos];
    167168
    168             dw=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type;
    169             ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type=pImageCtrlInfo->type;
     169            dw=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type;
     170            pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type=pImageCtrlInfo->type;
    170171            pImageCtrlInfo->type=dw;
    171172
    172             dw=(DWORD)ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path;
    173             ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path=pImageCtrlInfo->path;
     173            dw=(DWORD)pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path;
     174            pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path=pImageCtrlInfo->path;
    174175            pImageCtrlInfo->path=(char *)dw;
    175176
    176177            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    177178                ChangePropertyWindow(WndNum,WndInfoNum);
    178             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     179            DrawRadWindow(WndNum,pWindowInfo);
    179180            break;
    180181        case RAD_UNDO_TYPE:
    181             dw=ProjectInfo.pWindowInfo[WndInfoNum].type;
    182             ProjectInfo.pWindowInfo[WndInfoNum].type=pUndoState->lpdwData[pUndoState->NowPos];
     182            dw=pWindowInfo->type;
     183            pWindowInfo->type=pUndoState->lpdwData[pUndoState->NowPos];
    183184            pUndoState->lpdwData[pUndoState->NowPos]=dw;
    184185            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
     
    195196    extern MDIINFO MdiInfo[MAX_WNDNUM];
    196197    extern PROJECTINFO ProjectInfo;
    197     int WndInfoNum;
    198198    DWORD dw;
    199199    char *temporary;
     
    208208    }
    209209
    210     WndInfoNum=GetWndInfoNum(MdiInfo[WndNum].path);
     210    WINDOW_INFO *pWindowInfo = GetWndInfo(MdiInfo[WndNum].path);
     211    int WndInfoNum = GetWndInfoNum(MdiInfo[WndNum].path);
    211212    switch(pUndoState->Command[pUndoState->NowPos]){
    212213        case RAD_UNDO_INSERTITEM:
     
    229230                names=(RAD_UNDOSTATE_NAME *)pUndoState->lpdwData[pUndoState->NowPos];
    230231
    231                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].name;
    232                 ProjectInfo.pWindowInfo[WndInfoNum].name=names->name;
     232                temporary=pWindowInfo->name;
     233                pWindowInfo->name=names->name;
    233234                names->name=temporary;
    234235                GlobalFree(MdiInfo[WndNum].path);
    235                 MdiInfo[WndNum].path=(char *)GlobalAlloc(GMEM_FIXED,lstrlen(ProjectInfo.pWindowInfo[WndInfoNum].name)+1);
    236                 lstrcpy(MdiInfo[WndNum].path,ProjectInfo.pWindowInfo[WndInfoNum].name);
    237 
    238                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].HandleName;
    239                 ProjectInfo.pWindowInfo[WndInfoNum].HandleName=names->HandleName;
     236                MdiInfo[WndNum].path=(char *)GlobalAlloc(GMEM_FIXED,lstrlen(pWindowInfo->name)+1);
     237                lstrcpy(MdiInfo[WndNum].path,pWindowInfo->name);
     238
     239                temporary=pWindowInfo->HandleName;
     240                pWindowInfo->HandleName=names->HandleName;
    240241                names->HandleName=temporary;
    241242
    242                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].CallBackName;
    243                 ProjectInfo.pWindowInfo[WndInfoNum].CallBackName=names->CallBackName;
     243                temporary=pWindowInfo->CallBackName;
     244                pWindowInfo->CallBackName=names->CallBackName;
    244245                names->CallBackName=temporary;
    245246            }
    246247            else{
    247                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName;
    248                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     248                temporary=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName;
     249                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].IdName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    249250                pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    250251            }
     
    254255        case RAD_UNDO_CAPTION:
    255256            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    256                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].caption;
    257                 ProjectInfo.pWindowInfo[WndInfoNum].caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     257                temporary=pWindowInfo->caption;
     258                pWindowInfo->caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    258259                pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    259260            }
    260261            else{
    261                 temporary=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption;
    262                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     262                temporary=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption;
     263                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].caption=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    263264                pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    264265            }
    265266            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    266267                ChangePropertyWindow(WndNum,WndInfoNum);
    267             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     268            DrawRadWindow(WndNum,pWindowInfo);
    268269            break;
    269270        case RAD_UNDO_FONT:
    270271            LOGFONT *pLogFont,lf;
    271272            pLogFont=(LOGFONT *)pUndoState->lpdwData[pUndoState->NowPos];
    272             lf=ProjectInfo.pWindowInfo[WndInfoNum].LogFont;
    273             ProjectInfo.pWindowInfo[WndInfoNum].LogFont=*pLogFont;
     273            lf=pWindowInfo->LogFont;
     274            pWindowInfo->LogFont=*pLogFont;
    274275            *pLogFont=lf;
    275276            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    276277                ChangePropertyWindow(WndNum,WndInfoNum);
    277             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     278            DrawRadWindow(WndNum,pWindowInfo);
    278279            break;
    279280        case RAD_UNDO_BGCOLOR:
    280             dw=ProjectInfo.pWindowInfo[WndInfoNum].bgColor;
    281             ProjectInfo.pWindowInfo[WndInfoNum].bgColor=pUndoState->lpdwData[pUndoState->NowPos];
     281            dw=pWindowInfo->bgColor;
     282            pWindowInfo->bgColor=pUndoState->lpdwData[pUndoState->NowPos];
    282283            pUndoState->lpdwData[pUndoState->NowPos]=dw;
    283284            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    284285                ChangePropertyWindow(WndNum,WndInfoNum);
    285             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     286            DrawRadWindow(WndNum,pWindowInfo);
    286287            break;
    287288        case RAD_UNDO_WINDOWMENU:
    288             temporary=ProjectInfo.pWindowInfo[WndInfoNum].MenuID;
    289             ProjectInfo.pWindowInfo[WndInfoNum].MenuID=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     289            temporary=pWindowInfo->MenuID;
     290            pWindowInfo->MenuID=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    290291            pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    291292            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
     
    293294            break;
    294295        case RAD_UNDO_ICONRES:
    295             temporary=ProjectInfo.pWindowInfo[WndInfoNum].IconResName;
    296             ProjectInfo.pWindowInfo[WndInfoNum].IconResName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
     296            temporary=pWindowInfo->IconResName;
     297            pWindowInfo->IconResName=(char *)pUndoState->lpdwData[pUndoState->NowPos];
    297298            pUndoState->lpdwData[pUndoState->NowPos]=(DWORD)temporary;
    298299            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
     
    301302        case RAD_UNDO_STYLE:
    302303            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    303                 dw=ProjectInfo.pWindowInfo[WndInfoNum].style;
    304                 ProjectInfo.pWindowInfo[WndInfoNum].style=pUndoState->lpdwData[pUndoState->NowPos];
    305                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    306             }
    307             else{
    308                 dw=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style;
    309                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style=pUndoState->lpdwData[pUndoState->NowPos];
    310                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    311             }
    312             if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    313                 ChangePropertyWindow(WndNum,WndInfoNum);
    314             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     304                dw=pWindowInfo->style;
     305                pWindowInfo->style=pUndoState->lpdwData[pUndoState->NowPos];
     306                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     307            }
     308            else{
     309                dw=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style;
     310                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].style=pUndoState->lpdwData[pUndoState->NowPos];
     311                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     312            }
     313            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
     314                ChangePropertyWindow(WndNum,WndInfoNum);
     315            DrawRadWindow(WndNum,pWindowInfo);
    315316            break;
    316317        case RAD_UNDO_EXSTYLE:
    317318            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    318                 dw=ProjectInfo.pWindowInfo[WndInfoNum].ExStyle;
    319                 ProjectInfo.pWindowInfo[WndInfoNum].ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
    320                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    321             }
    322             else{
    323                 dw=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle;
    324                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
    325                 pUndoState->lpdwData[pUndoState->NowPos]=dw;
    326             }
    327             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     319                dw=pWindowInfo->ExStyle;
     320                pWindowInfo->ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
     321                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     322            }
     323            else{
     324                dw=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle;
     325                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ExStyle=pUndoState->lpdwData[pUndoState->NowPos];
     326                pUndoState->lpdwData[pUndoState->NowPos]=dw;
     327            }
     328            DrawRadWindow(WndNum,pWindowInfo);
    328329            break;
    329330        case RAD_UNDO_POSITION:
     
    331332            pReadPointAndSize=(POINTANDSIZE *)pUndoState->lpdwData[pUndoState->NowPos];
    332333            if(pUndoState->SelectItemNum[pUndoState->NowPos]==SELECT_WINDOW){
    333                 PointAndSize.size=ProjectInfo.pWindowInfo[WndInfoNum].size;
    334                 ProjectInfo.pWindowInfo[WndInfoNum].size=pReadPointAndSize->size;
    335             }
    336             else{
    337                 PointAndSize.pos=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos;
    338                 PointAndSize.size=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size;
    339                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos=pReadPointAndSize->pos;
    340                 ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size=pReadPointAndSize->size;
     334                PointAndSize.size=pWindowInfo->size;
     335                pWindowInfo->size=pReadPointAndSize->size;
     336            }
     337            else{
     338                PointAndSize.pos=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos;
     339                PointAndSize.size=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size;
     340                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].pos=pReadPointAndSize->pos;
     341                pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].size=pReadPointAndSize->size;
    341342            }
    342343            *pReadPointAndSize=PointAndSize;
    343             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     344            DrawRadWindow(WndNum,pWindowInfo);
    344345            SetStatusText(NULL);
    345346
     
    351352            pImageCtrlInfo=(IMAGECTRLINFO *)pUndoState->lpdwData[pUndoState->NowPos];
    352353
    353             dw=ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type;
    354             ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type=pImageCtrlInfo->type;
     354            dw=pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type;
     355            pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.type=pImageCtrlInfo->type;
    355356            pImageCtrlInfo->type=dw;
    356357
    357             dw=(DWORD)ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path;
    358             ProjectInfo.pWindowInfo[WndInfoNum].pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path=pImageCtrlInfo->path;
     358            dw=(DWORD)pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path;
     359            pWindowInfo->pChildInfo[pUndoState->SelectItemNum[pUndoState->NowPos]].ImageCtrlInfo.path=pImageCtrlInfo->path;
    359360            pImageCtrlInfo->path=(char *)dw;
    360361
    361362            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
    362363                ChangePropertyWindow(WndNum,WndInfoNum);
    363             DrawRadWindow(WndNum,&ProjectInfo.pWindowInfo[WndInfoNum]);
     364            DrawRadWindow(WndNum,pWindowInfo);
    364365            break;
    365366        case RAD_UNDO_TYPE:
    366             dw=ProjectInfo.pWindowInfo[WndInfoNum].type;
    367             ProjectInfo.pWindowInfo[WndInfoNum].type=pUndoState->lpdwData[pUndoState->NowPos];
     367            dw=pWindowInfo->type;
     368            pWindowInfo->type=pUndoState->lpdwData[pUndoState->NowPos];
    368369            pUndoState->lpdwData[pUndoState->NowPos]=dw;
    369370            if(pUndoState->SelectItemNum[pUndoState->NowPos]==MdiInfo[WndNum].MdiRadInfo->SelectingItem[0])
Note: See TracChangeset for help on using the changeset viewer.