Land "Additions Window" for the Mac installer. [b=21039]

This commit is contained in:
sgehani%netscape.com 2000-05-16 03:57:46 +00:00
Родитель 6eb96c8643
Коммит 59d27bc698
8 изменённых файлов: 544 добавлений и 31 удалений

Двоичные данные
xpinstall/wizard/mac/rsrc/MIWCommon.rsrc

Двоичный файл не отображается.

Просмотреть файл

@ -26,23 +26,494 @@
/*-----------------------------------------------------------*
* Additions Window
*-----------------------------------------------------------*/
static int rowToComp[kMaxComponents];
static int numRows = 0;
static Boolean bFirstDraw = true;
void
ShowAdditionsWin(void)
{
Str255 next, back;
Str255 compDescTitle;
StringPtr selCompMsg;
Handle listBoxRect;
Rect dataBounds, listBoxFrame, viewRect;
short reserr;
int totalRows = 0, i, instChoice;
Point cSize;
Boolean bCellSelected;
GrafPtr oldPort;
GetPort(&oldPort);
SetPort(gWPtr);
gCurrWin = kAdditionsID;
/* gControls->aw = (CompWin *) NewPtrClear(sizeof(CompWin)); */
GetIndString(next, rStringList, sNextBtn);
GetIndString(back, rStringList, sBackBtn);
// get controls
listBoxRect = Get1Resource('RECT', rCompListBox);
reserr = ResError();
if (reserr == noErr && listBoxRect != NULL)
{
HLock((Handle)listBoxRect);
SetRect(&gControls->aw->compListBox, ((Rect*)*listBoxRect)->left,
((Rect*)*listBoxRect)->top,
((Rect*)*listBoxRect)->right,
((Rect*)*listBoxRect)->bottom);
HUnlock((Handle)listBoxRect);
}
else
{
ErrorHandler();
return;
}
gControls->aw->compDescBox = NULL;
gControls->aw->compDescBox = GetNewControl(rCompDescBox, gWPtr);
if (!gControls->aw->compDescBox)
{
ErrorHandler();
return;
}
gControls->aw->compListBox.right -= kScrollBarWidth;
instChoice = gControls->opt->instChoice-1;
for (i=0; i<kMaxComponents; i++)
{
if (totalRows >= gControls->cfg->numComps)
break;
if (!gControls->cfg->comp[i].invisible && gControls->cfg->comp[i].additional &&
(gControls->cfg->st[instChoice].comp[i] == kInSetupType))
totalRows++;
}
SetRect(&dataBounds, 0, 0, 1, totalRows);
SetPt( &cSize, 0, 0);
gControls->aw->compList = LNew((const Rect*)&gControls->aw->compListBox, (const Rect*)&dataBounds,
cSize, rCheckboxLDEF, gWPtr, true, false, false, true);
(*gControls->aw->compList)->selFlags = 68; /* NOTE: 64 (aka lExtendDrag) + 4 (aka lUseSense) = 68 */
HLock((Handle)gControls->aw->compDescBox);
SetRect(&viewRect, (*gControls->aw->compDescBox)->contrlRect.left,
(*gControls->aw->compDescBox)->contrlRect.top,
(*gControls->aw->compDescBox)->contrlRect.right,
(*gControls->aw->compDescBox)->contrlRect.bottom);
HUnlock((Handle)gControls->aw->compDescBox);
viewRect.top += kInterWidgetPad;
SetRect(&viewRect, viewRect.left + kTxtRectPad,
viewRect.top + kTxtRectPad,
viewRect.right - kTxtRectPad,
viewRect.bottom - kTxtRectPad);
TextFont(applFont);
TextSize(9);
gControls->aw->compDescTxt = TENew(&viewRect, &viewRect);
TextFont(systemFont);
TextSize(12);
// populate controls
bCellSelected = AddPopulateCompInfo();
// show controls
GetIndString(compDescTitle, rStringList, sCompDescTitle);
SetControlTitle(gControls->aw->compDescBox, compDescTitle);
MoveTo( gControls->aw->compListBox.left, gControls->aw->compListBox.top - kInterWidgetPad);
HLock(gControls->cfg->selCompMsg);
selCompMsg = CToPascal(*gControls->cfg->selAddMsg);
if (selCompMsg)
DrawString( selCompMsg );
HUnlock(gControls->cfg->selCompMsg);
SetRect(&listBoxFrame, gControls->aw->compListBox.left,
--gControls->aw->compListBox.top,
gControls->aw->compListBox.right += kScrollBarWidth,
++gControls->aw->compListBox.bottom);
FrameRect(&listBoxFrame);
ShowNavButtons( back, next );
if (bCellSelected)
AddSetOptInfo(true);
else
DrawDiskSpaceMsgs( gControls->opt->vRefNum );
// default highlight first row
AddInitRowHighlight(0);
SetPort(oldPort);
}
Boolean
AddPopulateCompInfo()
{
int i;
char *currDesc;
Point currCell;
Boolean bCellSelected = false;
int nextRow = 0;
for (i=0; i<gControls->cfg->numComps; i++)
{
if (!gControls->cfg->comp[i].invisible && gControls->cfg->comp[i].additional)
{
HLock(gControls->cfg->comp[i].shortDesc);
currDesc = *gControls->cfg->comp[i].shortDesc;
SetPt(&currCell, 0, nextRow);
rowToComp[nextRow++] = i;
LSetCell( currDesc, strlen(currDesc), currCell, gControls->aw->compList);
HUnlock(gControls->cfg->comp[i].shortDesc);
if (gControls->cfg->comp[i].selected == true)
{
LSetSelect(true, currCell, gControls->aw->compList);
bCellSelected = true;
}
}
}
numRows = nextRow;
return bCellSelected;
}
void
InAdditionsContent(EventRecord* evt, WindowPtr wCurrPtr)
{
Point localPt;
Rect r, currCellRect, checkbox;
ControlPartCode part;
int i;
Cell currCell;
UInt8 hiliteVal;
PixPatHandle ppH;
GrafPtr oldPort;
GetPort(&oldPort);
SetPort(wCurrPtr);
localPt = evt->where;
GlobalToLocal( &localPt);
/* Mouse Up */
if ((evt->what == mouseUp) && (PtInRect( localPt, &gControls->aw->compListBox)))
{
LClick(localPt, evt->modifiers, gControls->aw->compList);
/* invert the checkbox rect */
for (i=0; i<numRows; i++)
{
SetPt(&currCell, 0, i);
LRect(&currCellRect, currCell, gControls->aw->compList);
if (PtInRect(localPt, &currCellRect))
{
SetRect(&checkbox, currCellRect.left+4, currCellRect.top+2,
currCellRect.left+16, currCellRect.top+14);
INVERT_HIGHLIGHT(&checkbox);
break;
}
}
AddSetOptInfo(false);
}
/* Mouse Down */
if ((evt->what == mouseDown) && (PtInRect( localPt, &gControls->aw->compListBox)))
{
/* show depressed button state */
for (i=0; i<numRows; i++)
{
SetPt(&currCell, 0, i);
LRect(&currCellRect, currCell, gControls->aw->compList);
if (PtInRect(localPt, &currCellRect))
{
SetRect(&checkbox, currCellRect.left+4, currCellRect.top+2,
currCellRect.left+16, currCellRect.top+14);
ppH = GetPixPat(rGrayPixPattern);
FillCRect(&checkbox, ppH);
FrameRect(&checkbox);
if (gControls->cfg->comp[rowToComp[i]].selected)
{
/* draw check mark */
MoveTo(checkbox.left+1, checkbox.top+1);
LineTo(checkbox.right-2, checkbox.bottom-2);
MoveTo(checkbox.right-2, checkbox.top+1);
LineTo(checkbox.left+1, checkbox.bottom-2);
}
/* create 3D depression */
MoveTo(checkbox.left+1, checkbox.top+1);
LineTo(checkbox.left+1, checkbox.bottom-1);
MoveTo(checkbox.left+1, checkbox.top+1);
LineTo(checkbox.right-1, checkbox.top+1);
ForeColor(whiteColor);
MoveTo(checkbox.right-1, checkbox.top+1);
LineTo(checkbox.right-1, checkbox.bottom-1);
MoveTo(checkbox.left+1, checkbox.bottom-1);
LineTo(checkbox.right-1, checkbox.bottom-1);
ForeColor(blackColor);
if (ppH)
DisposePixPat(ppH);
break;
}
}
}
HLock((Handle)gControls->backB);
r = (**(gControls->backB)).contrlRect;
HUnlock((Handle)gControls->backB);
if (PtInRect( localPt, &r))
{
/* reset all rows to be not highlighted */
for (i=1; i<numRows; i++)
gControls->cfg->comp[rowToComp[i]].highlighted = false;
part = TrackControl(gControls->backB, evt->where, NULL);
if (part)
{
/* extra handling since we used DrawString for static text msg
* and framed our own listbox etc.
*/
gControls->aw->compListBox.top = 0;
EraseRect(&gControls->aw->compListBox);
ClearDiskSpaceMsgs();
KillControls(gWPtr);
ShowComponentsWin();
return;
}
}
HLock((Handle)gControls->nextB);
r = (**(gControls->nextB)).contrlRect;
HUnlock((Handle)gControls->nextB);
if (PtInRect( localPt, &r))
{
/* reset all rows to be not highlighted */
for (i=0; i<numRows; i++)
gControls->cfg->comp[rowToComp[i]].highlighted = false;
part = TrackControl(gControls->nextB, evt->where, NULL);
if (part)
{
gControls->aw->compListBox.top = 0;
EraseRect(&gControls->aw->compListBox);
ClearDiskSpaceMsgs();
KillControls(gWPtr);
ShowTerminalWin();
return;
}
}
SetPort(oldPort);
}
void
UpdateAdditionsWin(void)
{
Rect r;
Cell c;
int i;
GrafPtr oldPort;
GetPort(&oldPort);
SetPort(gWPtr);
MoveTo( gControls->aw->compListBox.left, gControls->aw->compListBox.top - kInterWidgetPad + 1);
HLock(gControls->cfg->selAddMsg);
DrawString( CToPascal(*gControls->cfg->selAddMsg));
HUnlock(gControls->cfg->selAddMsg);
LUpdate( (*gControls->aw->compList)->port->visRgn, gControls->aw->compList);
FrameRect(&gControls->aw->compListBox);
SetPt(&c, 0, 0);
if (LGetSelect(true, &c, gControls->aw->compList))
{
HLock((Handle)gControls->aw->compDescTxt);
SetRect(&r, (*gControls->aw->compDescTxt)->viewRect.left,
(*gControls->aw->compDescTxt)->viewRect.top,
(*gControls->aw->compDescTxt)->viewRect.right,
(*gControls->aw->compDescTxt)->viewRect.bottom);
HUnlock((Handle)gControls->aw->compDescTxt);
TEUpdate(&r, gControls->aw->compDescTxt);
}
DrawDiskSpaceMsgs( gControls->opt->vRefNum );
for (i = 0; i < numRows; i++)
{
if (gControls->cfg->comp[rowToComp[i]].highlighted)
{
AddInitRowHighlight(i);
break;
}
}
SetPort(oldPort);
}
void
MouseMovedInAdditionsWin(EventRecord *evt)
{
Point localPt;
GrafPtr oldPort;
GetPort(&oldPort);
if (gWPtr)
SetPort(gWPtr);
localPt = evt->where;
GlobalToLocal( &localPt );
/* if within list box rect */
if (PtInRect( localPt, &((*gControls->aw->compList)->rView) ))
{
AddUpdateRowHighlight(localPt);
}
SetPort(oldPort);
}
short
AddGetCompRow(int compIdx)
{
short i = kInvalidCompIdx;
for (i=0; i<numRows; i++)
{
if (rowToComp[i] == compIdx)
break;
}
return i;
}
void
AddSetOptInfo(Boolean bDrawingWindow)
{
Cell currCell;
int row, beingSelected;
Boolean setSelected;
// so we must determine the row clicked and resolve its dependees
// bumping up their ref counts if this row is selected
// and down if this row is unselected
if (!bDrawingWindow)
{
currCell = LLastClick(gControls->aw->compList);
row = currCell.v;
// toggle from on to off or vice versa
if (gControls->cfg->comp[rowToComp[row]].selected)
beingSelected = kNotSelected;
else
beingSelected = kSelected;
ResolveDependees(rowToComp[row], beingSelected);
}
// then update the UI
for (row = 0; row < numRows; row++)
{
SetPt(&currCell, 0, row);
if (gControls->cfg->comp[rowToComp[row]].selected == kSelected)
setSelected = true;
else
setSelected = false;
LSetSelect(setSelected, currCell, gControls->aw->compList);
}
ClearDiskSpaceMsgs();
DrawDiskSpaceMsgs( gControls->opt->vRefNum );
}
void
AddInitRowHighlight(int row)
{
Cell hlCell;
Rect hlCellRect;
UInt8 hiliteVal;
int i = 0;
/* reset all highlighted markers */
for (i=0; i<numRows; i++)
{
gControls->cfg->comp[rowToComp[i]].highlighted = false;
}
/* highlight and set marker for row to init */
SetPt(&hlCell, 0, row);
LRect(&hlCellRect, hlCell, gControls->aw->compList);
INVERT_HIGHLIGHT(&hlCellRect);
AddUpdateLongDesc(row);
gControls->cfg->comp[rowToComp[row]].highlighted = true;
}
void
AddUpdateRowHighlight(Point localPt)
{
int i, j;
Rect currCellRect, oldCellRect;
Cell currCell, oldCell;
UInt8 hiliteVal;
for (i=0; i<numRows; i++)
{
/* note: numComps above includes invisible components */
SetPt(&currCell, 0, i);
LRect(&currCellRect, currCell, gControls->aw->compList);
/* mouse move landed over this cell */
if (PtInRect( localPt, &currCellRect ))
{
if (!gControls->cfg->comp[rowToComp[i]].highlighted)
{
/* highlight this cell */
INVERT_HIGHLIGHT(&currCellRect);
AddUpdateLongDesc(i);
/* unhighlight old one */
for (j=0; j<numRows; j++)
{
if (gControls->cfg->comp[rowToComp[j]].highlighted)
{
SetPt(&oldCell, 0, j);
LRect(&oldCellRect, oldCell, gControls->aw->compList);
INVERT_HIGHLIGHT(&oldCellRect);
gControls->cfg->comp[rowToComp[j]].highlighted = false;
}
}
/* mark this row highlighted to prevent incorrect inversion */
gControls->cfg->comp[rowToComp[i]].highlighted = true;
}
}
}
}
void
AddUpdateLongDesc(int row)
{
Rect viewRect;
HLock((Handle)gControls->aw->compDescBox);
SetRect(&viewRect, (*gControls->aw->compDescBox)->contrlRect.left,
(*gControls->aw->compDescBox)->contrlRect.top,
(*gControls->aw->compDescBox)->contrlRect.right,
(*gControls->aw->compDescBox)->contrlRect.bottom);
HUnlock((Handle)gControls->aw->compDescBox);
viewRect.top += kInterWidgetPad;
SetRect(&viewRect, viewRect.left + kTxtRectPad,
viewRect.top + kTxtRectPad,
viewRect.right - kTxtRectPad,
viewRect.bottom - kTxtRectPad);
EraseRect(&viewRect);
HLock(gControls->cfg->comp[rowToComp[row]].longDesc);
TESetText( *gControls->cfg->comp[rowToComp[row]].longDesc,
strlen(*gControls->cfg->comp[rowToComp[row]].longDesc), gControls->aw->compDescTxt );
TEUpdate( &viewRect, gControls->aw->compDescTxt );
HUnlock(gControls->cfg->comp[rowToComp[row]].longDesc);
}
void

Просмотреть файл

@ -26,12 +26,6 @@
/*-----------------------------------------------------------*
* Components Window
*-----------------------------------------------------------*/
#define INVERT_HIGHLIGHT(_rectPtr) \
hiliteVal = LMGetHiliteMode(); \
BitClr(&hiliteVal, pHiliteBit); \
LMSetHiliteMode(hiliteVal); \
InvertRect(_rectPtr);
static int rowToComp[kMaxComponents];
static int numRows = 0;
@ -91,7 +85,8 @@ ShowComponentsWin(void)
{
if (totalRows >= gControls->cfg->numComps)
break;
if (!gControls->cfg->comp[i].invisible && (gControls->cfg->st[instChoice].comp[i] == kInSetupType))
if (!gControls->cfg->comp[i].invisible && !gControls->cfg->comp[i].additional &&
(gControls->cfg->st[instChoice].comp[i] == kInSetupType))
totalRows++;
}
@ -152,7 +147,7 @@ ShowComponentsWin(void)
}
Boolean
PopulateCompInfo(void)
PopulateCompInfo()
{
int i;
char *currDesc;
@ -162,7 +157,7 @@ PopulateCompInfo(void)
for (i=0; i<gControls->cfg->numComps; i++)
{
if (gControls->cfg->comp[i].invisible == false)
if (!gControls->cfg->comp[i].invisible && !gControls->cfg->comp[i].additional)
{
HLock(gControls->cfg->comp[i].shortDesc);
currDesc = *gControls->cfg->comp[i].shortDesc;
@ -353,7 +348,7 @@ InComponentsContent(EventRecord* evt, WindowPtr wCurrPtr)
ClearDiskSpaceMsgs();
KillControls(gWPtr);
ShowTerminalWin();
ShowAdditionsWin();
return;
}
}

Просмотреть файл

@ -37,7 +37,10 @@ void HandleNextEvent(EventRecord* nextEvt)
case mouseUp:
if (gCurrWin == kComponentsID)
InComponentsContent(nextEvt, gWPtr);
else if (gCurrWin == kAdditionsID)
InAdditionsContent(nextEvt, gWPtr);
break;
case keyDown:
HandleKeyDown(nextEvt);
@ -144,15 +147,15 @@ void HandleKeyDown(EventRecord* evt)
case kComponentsID:
ClearDiskSpaceMsgs();
KillControls(gWPtr);
// if additions exist // XXX_ADD
// show additions dialog
// else
if (gControls->cfg->bAdditionsExist)
ShowAdditionsWin();
else
ShowTerminalWin();
return;
case kAdditionsID:
KillControls(gWPtr);
// reinit top of listbox
// erase any thing and clear disk space msgs
// XXX reinit top of listbox
ClearDiskSpaceMsgs();
ShowTerminalWin();
return;
case kTerminalID:
@ -335,7 +338,11 @@ void HandleOSEvt(EventRecord* evt)
switch(gCurrWin)
{
case kComponentsID:
MouseMovedInComponentsWin(evt);
MouseMovedInComponentsWin(evt);
break;
case kAdditionsID:
MouseMovedInAdditionsWin(evt);
break;
default:
break;
}

Просмотреть файл

@ -212,6 +212,7 @@ InitControlsObject(void)
gControls->ww = (WelcWin *) NewPtrClear(sizeof(WelcWin));
gControls->stw = (SetupTypeWin *) NewPtrClear(sizeof(SetupTypeWin));
gControls->cw = (CompWin *) NewPtrClear(sizeof(CompWin));
gControls->aw = (CompWin *) NewPtrClear(sizeof(CompWin));
gControls->tw = (TermWin*) NewPtrClear(sizeof(TermWin));
if (!gControls->lw || !gControls->ww || !gControls->stw ||

Просмотреть файл

@ -98,7 +98,13 @@ if (err) \
| (unsigned long)((_src2char & 0x000000FF) << 16) \
| (unsigned long)((_src3char & 0x000000FF) << 8) \
| (unsigned long)((_src4char & 0x000000FF)))))
#define INVERT_HIGHLIGHT(_rectPtr) \
hiliteVal = LMGetHiliteMode(); \
BitClr(&hiliteVal, pHiliteBit); \
LMSetHiliteMode(hiliteVal); \
InvertRect(_rectPtr);
#define NUM_WINS 5
#define kLicenseID 0 /* window object ids */
@ -284,6 +290,7 @@ if (err) \
#define sC 20
#define sCompDlg 21
#define sAddDlg 48
#define sComponent 22
#define sArchive 23
#define sInstSize 24
@ -311,7 +318,8 @@ if (err) \
#define sSELECTED 28
#define sINVISIBLE 29
#define sLAUNCHAPP 30 /* end parse keys */
#define sLAUNCHAPP 30
#define sADDITIONAL 47 /* end parse keys */
#define eParseFailed 501 /* errors */
@ -337,6 +345,7 @@ typedef struct InstComp {
Boolean selected;
Boolean invisible;
Boolean launchapp;
Boolean additional;
/* dependees */
Handle depName[kMaxComponents];
@ -401,6 +410,7 @@ typedef struct Config {
short numComps;
Handle selCompMsg;
Handle selAddMsg;
Boolean bAdditionsExist;
InstComp comp[kMaxComponents];
/* TerminalWin */
@ -503,11 +513,12 @@ typedef struct InstWiz {
Options *opt;
/* Window control-holding abstractions */
LicWin *lw;
WelcWin *ww;
SetupTypeWin *stw;
CompWin *cw;
TermWin *tw;
LicWin *lw; /* LicenseWin */
WelcWin *ww; /* WelcomeWin */
SetupTypeWin *stw; /* SetupTypeWin */
CompWin *cw; /* ComponentsWin */
CompWin *aw; /* AdditionsWin */
TermWin *tw; /* TerminalWin */
/* General wizard controls */
ControlHandle backB;
@ -548,7 +559,6 @@ void MakeMenus(void);
void MainEventLoop(void);
void ErrorHandler(void);
void Shutdown(void);
void EssentialFiles2Components(char *filename);
/*-----------------------------------------------------------*
* Parser
@ -645,6 +655,8 @@ short pstrcmp(unsigned char*, unsigned char*);
unsigned char* pstrcpy(unsigned char*, unsigned char*);
unsigned char* pstrcat(unsigned char*, unsigned char*);
void InSetupTypeContent(EventRecord *, WindowPtr);
Boolean LegacyFileCheck(short, long);
int CompareVersion(Handle, Handle);
void EnableSetupTypeWin(void);
void DisableSetupTypeWin(void);
@ -663,8 +675,6 @@ void UpdateRowHighlight(Point);
void UpdateLongDesc(int);
void ResolveDependees(int, int);
void UpdateRefCount(int, int);
Boolean LegacyFileCheck(short, long);
int CompareVersion(Handle, Handle);
void EnableComponentsWin(void);
void DisableComponentsWin(void);
@ -672,8 +682,15 @@ void DisableComponentsWin(void);
* AdditionsWin
*-----------------------------------------------------------*/
void ShowAdditionsWin(void);
Boolean AddPopulateCompInfo(void);
void InAdditionsContent(EventRecord*, WindowPtr);
void UpdateAdditionsWin(void);
void MouseMovedInAdditionsWin(EventRecord *);
short AddGetCompRow(int);
void AddSetOptInfo(Boolean);
void AddInitRowHighlight(int);
void AddUpdateRowHighlight(Point);
void AddUpdateLongDesc(int);
void EnableAdditionsWin(void);
void DisableAdditionsWin(void);

Просмотреть файл

@ -249,7 +249,12 @@ PopulateCompWinKeys(char *cfgText)
/* ComponentsWin: components and their descriptions, and other properties */
gControls->cfg->selCompMsg = NewHandleClear(kValueMaxLen);
FillKeyValueUsingResID(sCompDlg, sMsg0, gControls->cfg->selCompMsg, cfgText);
/* AdditionsWin: additional components */
gControls->cfg->selAddMsg = NewHandleClear(kValueMaxLen);
FillKeyValueUsingResID(sAddDlg, sMsg0, gControls->cfg->selAddMsg, cfgText);
gControls->cfg->bAdditionsExist = false;
gControls->cfg->numComps = 0;
for (i=0; i<kMaxComponents; i++)
{
@ -357,7 +362,7 @@ PopulateCompWinKeys(char *cfgText)
if (currKey)
DisposePtr(currKey);
/* attributes (SELECTED|INVISIBLE|LAUNCHAPP) */
/* attributes (SELECTED|INVISIBLE|LAUNCHAPP|ADDITIONAL) */
GetIndString(pkey, rParseKeys, sAttributes);
currKey = PascalToC(pkey);
Handle attrValH = NewHandleClear(255);
@ -401,6 +406,18 @@ PopulateCompWinKeys(char *cfgText)
gControls->cfg->comp[i].launchapp = false;
if (attrType)
DisposePtr(attrType);
GetIndString(pkey, rParseKeys, sADDITIONAL);
attrType = PascalToC(pkey);
if (NULL != strstr(*attrValH, attrType))
{
gControls->cfg->comp[i].additional = true;
gControls->cfg->bAdditionsExist = true; /* doesn't matter if set multiple times */
}
else
gControls->cfg->comp[i].additional = false;
if (attrType)
DisposePtr(attrType);
HUnlock(attrValH);
}

Просмотреть файл

@ -269,7 +269,12 @@ InTerminalContent(EventRecord* evt, WindowPtr wCurrPtr)
/* treat last setup type selection as custom */
if (gControls->opt->instChoice == gControls->cfg->numSetupTypes)
ShowComponentsWin();
{
if (gControls->cfg->bAdditionsExist)
ShowAdditionsWin();
else
ShowComponentsWin();
}
else
ShowSetupTypeWin();
return;