mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-02 10:00:54 +00:00
Support in the listbox for Screen Readers
(Bug 10477, r=ssu, sr=dveditz, mozilla1.0.1+)
This commit is contained in:
parent
fbfec1dc1c
commit
f6f5e7cbc1
@ -805,6 +805,78 @@ LRESULT CALLBACK DlgProcSetupType(HWND hDlg, UINT msg, WPARAM wParam, LONG lPara
|
||||
return(0);
|
||||
}
|
||||
|
||||
void DrawLBText(LPDRAWITEMSTRUCT lpdis, DWORD dwACFlag)
|
||||
{
|
||||
siC *siCTemp = NULL;
|
||||
TCHAR tchBuffer[MAX_BUF];
|
||||
TEXTMETRIC tm;
|
||||
DWORD y;
|
||||
|
||||
siCTemp = SiCNodeGetObject(lpdis->itemID, FALSE, dwACFlag);
|
||||
if(siCTemp != NULL)
|
||||
{
|
||||
SendMessage(lpdis->hwndItem, LB_GETTEXT, lpdis->itemID, (LPARAM)tchBuffer);
|
||||
|
||||
if((lpdis->itemAction & ODA_FOCUS) && (lpdis->itemState & ODS_SELECTED))
|
||||
{
|
||||
// remove the focus rect on the previous selected item
|
||||
DrawFocusRect(lpdis->hDC, &(lpdis->rcItem));
|
||||
}
|
||||
|
||||
siCTemp = SiCNodeGetObject(lpdis->itemID, FALSE, dwACFlag);
|
||||
if(lpdis->itemAction & ODA_FOCUS)
|
||||
{
|
||||
if((lpdis->itemState & ODS_SELECTED) &&
|
||||
!(lpdis->itemState & ODS_FOCUS))
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
{
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_WINDOWTEXT));
|
||||
SetBkColor(lpdis->hDC, GetSysColor(COLOR_WINDOW));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
{
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_HIGHLIGHTTEXT));
|
||||
SetBkColor(lpdis->hDC, GetSysColor(COLOR_HIGHLIGHT));
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(lpdis->itemAction & ODA_DRAWENTIRE)
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_WINDOWTEXT));
|
||||
}
|
||||
|
||||
// If a screen reader is being used we want to redraw the text whether
|
||||
// it has focus or not because the text changes whenever the checkbox
|
||||
// changes.
|
||||
if( gSystemInfo.bScreenReader || (lpdis->itemAction & (ODA_DRAWENTIRE | ODA_FOCUS)) )
|
||||
{
|
||||
// Display the text associated with the item.
|
||||
GetTextMetrics(lpdis->hDC, &tm);
|
||||
y = (lpdis->rcItem.bottom + lpdis->rcItem.top - tm.tmHeight) / 2;
|
||||
|
||||
ExtTextOut(lpdis->hDC,
|
||||
CX_CHECKBOX + 5,
|
||||
y,
|
||||
ETO_OPAQUE | ETO_CLIPPED,
|
||||
&(lpdis->rcItem),
|
||||
tchBuffer,
|
||||
strlen(tchBuffer),
|
||||
NULL);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void DrawCheck(LPDRAWITEMSTRUCT lpdis, DWORD dwACFlag)
|
||||
{
|
||||
siC *siCTemp = NULL;
|
||||
@ -851,8 +923,19 @@ void DrawCheck(LPDRAWITEMSTRUCT lpdis, DWORD dwACFlag)
|
||||
void lbAddItem(HWND hList, siC *siCComponent)
|
||||
{
|
||||
DWORD dwItem;
|
||||
TCHAR tchBuffer[MAX_BUF];
|
||||
|
||||
lstrcpy(tchBuffer, siCComponent->szDescriptionShort);
|
||||
if(gSystemInfo.bScreenReader)
|
||||
{
|
||||
lstrcat(tchBuffer, " - ");
|
||||
if(!(siCComponent->dwAttributes & SIC_SELECTED))
|
||||
lstrcat(tchBuffer, sgInstallGui.szUnchecked);
|
||||
else
|
||||
lstrcat(tchBuffer, sgInstallGui.szChecked);
|
||||
}
|
||||
dwItem = SendMessage(hList, LB_ADDSTRING, 0, (LPARAM)tchBuffer);
|
||||
|
||||
dwItem = SendMessage(hList, LB_ADDSTRING, 0, (LPARAM)siCComponent->szDescriptionShort);
|
||||
if(siCComponent->dwAttributes & SIC_DISABLED)
|
||||
SendMessage(hList, LB_SETITEMDATA, dwItem, (LPARAM)hbmpBoxCheckedDisabled);
|
||||
else if(siCComponent->dwAttributes & SIC_SELECTED)
|
||||
@ -868,9 +951,12 @@ void InvalidateLBCheckbox(HWND hwndListBox)
|
||||
// retrieve the rectangle of all list items to update.
|
||||
GetClientRect(hwndListBox, &rcCheckArea);
|
||||
|
||||
// set the right coordinate of the rectangle to be the same
|
||||
// as the right edge of the bitmap drawn.
|
||||
rcCheckArea.right = CX_CHECKBOX;
|
||||
// Set the right coordinate of the rectangle to be the same
|
||||
// as the right edge of the bitmap drawn.
|
||||
// But if a screen reader is being used we want to redraw the text
|
||||
// as well as the checkbox so we do not set the right coordinate.
|
||||
if(!gSystemInfo.bScreenReader)
|
||||
rcCheckArea.right = CX_CHECKBOX;
|
||||
|
||||
// It then invalidates the checkbox region to be redrawn.
|
||||
// Invalidating the region sends a WM_DRAWITEM message to
|
||||
@ -893,20 +979,21 @@ void ToggleCheck(HWND hwndListBox, DWORD dwIndex, DWORD dwACFlag)
|
||||
{
|
||||
if(dwAttributes & SIC_SELECTED)
|
||||
{
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, FALSE, FALSE, dwACFlag);
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, FALSE, FALSE, dwACFlag, hwndListBox);
|
||||
|
||||
szToggledReferenceName = SiCNodeGetReferenceName(dwIndex, FALSE, dwACFlag);
|
||||
ResolveDependees(szToggledReferenceName);
|
||||
ResolveDependees(szToggledReferenceName, hwndListBox);
|
||||
}
|
||||
else
|
||||
{
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, FALSE, dwACFlag);
|
||||
bMoreToResolve = ResolveDependencies(dwIndex);
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, FALSE, dwACFlag, hwndListBox);
|
||||
bMoreToResolve = ResolveDependencies(dwIndex, hwndListBox);
|
||||
|
||||
while(bMoreToResolve)
|
||||
bMoreToResolve = ResolveDependencies(-1);
|
||||
bMoreToResolve = ResolveDependencies(-1, hwndListBox);
|
||||
|
||||
szToggledReferenceName = SiCNodeGetReferenceName(dwIndex, FALSE, dwACFlag);
|
||||
ResolveDependees(szToggledReferenceName);
|
||||
ResolveDependees(szToggledReferenceName, hwndListBox);
|
||||
}
|
||||
|
||||
InvalidateLBCheckbox(hwndListBox);
|
||||
@ -936,10 +1023,10 @@ WNDPROC SubclassWindow( HWND hWnd, WNDPROC NewWndProc)
|
||||
// ************************************************************************
|
||||
LRESULT CALLBACK NewListBoxWndProc(HWND hWnd, UINT uMsg, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
DWORD dwPosX;
|
||||
DWORD dwPosY;
|
||||
DWORD dwIndex;
|
||||
|
||||
DWORD dwPosX;
|
||||
DWORD dwPosY;
|
||||
DWORD dwIndex;
|
||||
|
||||
switch(uMsg)
|
||||
{
|
||||
case WM_CHAR:
|
||||
@ -984,8 +1071,6 @@ LRESULT CALLBACK DlgProcSelectComponents(HWND hDlg, UINT msg, WPARAM wParam, LON
|
||||
HWND hwndLBComponents;
|
||||
RECT rDlg;
|
||||
TCHAR tchBuffer[MAX_BUF];
|
||||
TEXTMETRIC tm;
|
||||
DWORD y;
|
||||
LPDRAWITEMSTRUCT lpdis;
|
||||
ULONGLONG ullDSBuf;
|
||||
char szBuf[MAX_BUF];
|
||||
@ -1069,63 +1154,7 @@ LRESULT CALLBACK DlgProcSelectComponents(HWND hDlg, UINT msg, WPARAM wParam, LON
|
||||
if(lpdis->itemID == -1)
|
||||
break;
|
||||
|
||||
SendMessage(lpdis->hwndItem, LB_GETTEXT, lpdis->itemID, (LPARAM)tchBuffer);
|
||||
if((lpdis->itemAction & ODA_FOCUS) && (lpdis->itemState & ODS_SELECTED))
|
||||
{
|
||||
// remove the focus rect on the previous selected item
|
||||
DrawFocusRect(lpdis->hDC, &(lpdis->rcItem));
|
||||
}
|
||||
|
||||
siCTemp = SiCNodeGetObject(lpdis->itemID, FALSE, AC_COMPONENTS);
|
||||
if(lpdis->itemAction & ODA_FOCUS)
|
||||
{
|
||||
if((lpdis->itemState & ODS_SELECTED) &&
|
||||
!(lpdis->itemState & ODS_FOCUS))
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
{
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_WINDOWTEXT));
|
||||
SetBkColor(lpdis->hDC, GetSysColor(COLOR_WINDOW));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
{
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_HIGHLIGHTTEXT));
|
||||
SetBkColor(lpdis->hDC, GetSysColor(COLOR_HIGHLIGHT));
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(lpdis->itemAction & ODA_DRAWENTIRE)
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_WINDOWTEXT));
|
||||
}
|
||||
|
||||
if(lpdis->itemAction & (ODA_DRAWENTIRE | ODA_FOCUS))
|
||||
{
|
||||
// Display the text associated with the item.
|
||||
GetTextMetrics(lpdis->hDC, &tm);
|
||||
y = (lpdis->rcItem.bottom + lpdis->rcItem.top - tm.tmHeight) / 2;
|
||||
|
||||
ExtTextOut(lpdis->hDC,
|
||||
CX_CHECKBOX + 5,
|
||||
y,
|
||||
ETO_OPAQUE | ETO_CLIPPED,
|
||||
&(lpdis->rcItem),
|
||||
tchBuffer,
|
||||
strlen(tchBuffer),
|
||||
NULL);
|
||||
|
||||
}
|
||||
|
||||
DrawLBText(lpdis, AC_COMPONENTS);
|
||||
DrawCheck(lpdis, AC_COMPONENTS);
|
||||
|
||||
// draw the focus rect on the selected item
|
||||
@ -1188,8 +1217,6 @@ LRESULT CALLBACK DlgProcSelectAdditionalComponents(HWND hDlg, UINT msg, WPARAM w
|
||||
HWND hwndLBComponents;
|
||||
RECT rDlg;
|
||||
TCHAR tchBuffer[MAX_BUF];
|
||||
TEXTMETRIC tm;
|
||||
DWORD y;
|
||||
LPDRAWITEMSTRUCT lpdis;
|
||||
ULONGLONG ullDSBuf;
|
||||
char szBuf[MAX_BUF];
|
||||
@ -1273,62 +1300,7 @@ LRESULT CALLBACK DlgProcSelectAdditionalComponents(HWND hDlg, UINT msg, WPARAM w
|
||||
if(lpdis->itemID == -1)
|
||||
break;
|
||||
|
||||
SendMessage(lpdis->hwndItem, LB_GETTEXT, lpdis->itemID, (LPARAM)tchBuffer);
|
||||
if((lpdis->itemAction & ODA_FOCUS) && (lpdis->itemState & ODS_SELECTED))
|
||||
{
|
||||
// remove the focus rect on the previous selected item
|
||||
DrawFocusRect(lpdis->hDC, &(lpdis->rcItem));
|
||||
}
|
||||
|
||||
siCTemp = SiCNodeGetObject(lpdis->itemID, FALSE, AC_ADDITIONAL_COMPONENTS);
|
||||
if(lpdis->itemAction & ODA_FOCUS)
|
||||
{
|
||||
if((lpdis->itemState & ODS_SELECTED) &&
|
||||
!(lpdis->itemState & ODS_FOCUS))
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
{
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_WINDOWTEXT));
|
||||
SetBkColor(lpdis->hDC, GetSysColor(COLOR_WINDOW));
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
{
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_HIGHLIGHTTEXT));
|
||||
SetBkColor(lpdis->hDC, GetSysColor(COLOR_HIGHLIGHT));
|
||||
}
|
||||
}
|
||||
}
|
||||
else if(lpdis->itemAction & ODA_DRAWENTIRE)
|
||||
{
|
||||
if(siCTemp->dwAttributes & SIC_DISABLED)
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_GRAYTEXT));
|
||||
else
|
||||
SetTextColor(lpdis->hDC, GetSysColor(COLOR_WINDOWTEXT));
|
||||
}
|
||||
|
||||
if(lpdis->itemAction & (ODA_DRAWENTIRE | ODA_FOCUS))
|
||||
{
|
||||
// Display the text associated with the item.
|
||||
GetTextMetrics(lpdis->hDC, &tm);
|
||||
y = (lpdis->rcItem.bottom + lpdis->rcItem.top - tm.tmHeight) / 2;
|
||||
|
||||
ExtTextOut(lpdis->hDC,
|
||||
CX_CHECKBOX + 5,
|
||||
y,
|
||||
ETO_OPAQUE | ETO_CLIPPED,
|
||||
&(lpdis->rcItem),
|
||||
tchBuffer,
|
||||
strlen(tchBuffer),
|
||||
NULL);
|
||||
}
|
||||
|
||||
DrawLBText(lpdis, AC_ADDITIONAL_COMPONENTS);
|
||||
DrawCheck(lpdis, AC_ADDITIONAL_COMPONENTS);
|
||||
|
||||
// draw the focus rect on the selected item
|
||||
|
@ -53,6 +53,7 @@ void PaintGradientShade(HWND hWnd, HDC hdc);
|
||||
BOOL BrowseForDirectory(HWND hDlg, char *szCurrDir);
|
||||
LRESULT CALLBACK BrowseHookProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam);
|
||||
void ShowMessage(LPSTR szMessage, BOOL bShow);
|
||||
void DrawLBText(LPDRAWITEMSTRUCT lpdis, DWORD dwACFlag);
|
||||
void DrawCheck(LPDRAWITEMSTRUCT lpdis, DWORD dwACFlag);
|
||||
void InvalidateLBCheckbox(HWND hwndListBox);
|
||||
void ProcessWindowsMessages(void);
|
||||
|
@ -665,6 +665,9 @@ HRESULT Initialize(HINSTANCE hInstance)
|
||||
DeleteInstallLogFile(FILE_INSTALL_STATUS_LOG);
|
||||
LogISTime(W_START);
|
||||
DetermineOSVersionEx();
|
||||
|
||||
SystemParametersInfo(SPI_GETSCREENREADER, 0, &(gSystemInfo.bScreenReader), 0);
|
||||
|
||||
return(0);
|
||||
}
|
||||
|
||||
@ -2841,10 +2844,14 @@ HRESULT SiCNodeGetAttributes(DWORD dwIndex, BOOL bIncludeInvisible, DWORD dwACFl
|
||||
return(-1);
|
||||
}
|
||||
|
||||
void SiCNodeSetAttributes(DWORD dwIndex, DWORD dwAttributes, BOOL bSet, BOOL bIncludeInvisible, DWORD dwACFlag)
|
||||
void SiCNodeSetAttributes(DWORD dwIndex, DWORD dwAttributes, BOOL bSet, BOOL bIncludeInvisible, DWORD dwACFlag, HWND hwndListBox)
|
||||
{
|
||||
DWORD dwCount = 0;
|
||||
siC *siCTemp = siComponents;
|
||||
DWORD dwCount = 0;
|
||||
DWORD dwVisibleIndex = 0;
|
||||
siC *siCTemp = siComponents;
|
||||
|
||||
LPSTR szTmpString;
|
||||
TCHAR tchBuffer[MAX_BUF];
|
||||
|
||||
if(siCTemp != NULL)
|
||||
{
|
||||
@ -2859,9 +2866,29 @@ void SiCNodeSetAttributes(DWORD dwIndex, DWORD dwAttributes, BOOL bSet, BOOL bIn
|
||||
siCTemp->dwAttributes |= dwAttributes;
|
||||
else
|
||||
siCTemp->dwAttributes &= ~dwAttributes;
|
||||
|
||||
if((!(siCTemp->dwAttributes & SIC_INVISIBLE))
|
||||
&& (dwAttributes == SIC_SELECTED)
|
||||
&& gSystemInfo.bScreenReader
|
||||
&& hwndListBox)
|
||||
{
|
||||
szTmpString = SiCNodeGetDescriptionShort(dwVisibleIndex, FALSE, dwACFlag);
|
||||
lstrcpy(tchBuffer, szTmpString);
|
||||
lstrcat(tchBuffer, " - ");
|
||||
if(bSet)
|
||||
lstrcat(tchBuffer, sgInstallGui.szChecked);
|
||||
else
|
||||
lstrcat(tchBuffer, sgInstallGui.szUnchecked);
|
||||
|
||||
//We've got to actually change the text in the listbox for the screen reader to see it.
|
||||
SendMessage(hwndListBox, LB_INSERTSTRING, 0, (LPARAM)tchBuffer);
|
||||
SendMessage(hwndListBox, LB_DELETESTRING, 1, 0);
|
||||
}
|
||||
}
|
||||
|
||||
++dwCount;
|
||||
if(!(siCTemp->dwAttributes & SIC_INVISIBLE))
|
||||
++dwVisibleIndex;
|
||||
}
|
||||
|
||||
siCTemp = siCTemp->Next;
|
||||
@ -2878,9 +2905,29 @@ void SiCNodeSetAttributes(DWORD dwIndex, DWORD dwAttributes, BOOL bSet, BOOL bIn
|
||||
siCTemp->dwAttributes |= dwAttributes;
|
||||
else
|
||||
siCTemp->dwAttributes &= ~dwAttributes;
|
||||
|
||||
if((!(siCTemp->dwAttributes & SIC_INVISIBLE))
|
||||
&& (dwAttributes == SIC_SELECTED)
|
||||
&& gSystemInfo.bScreenReader
|
||||
&& hwndListBox)
|
||||
{
|
||||
szTmpString = SiCNodeGetDescriptionShort(dwVisibleIndex, FALSE, dwACFlag);
|
||||
lstrcpy(tchBuffer, szTmpString);
|
||||
lstrcat(tchBuffer, " - ");
|
||||
if(bSet)
|
||||
lstrcat(tchBuffer, sgInstallGui.szChecked);
|
||||
else
|
||||
lstrcat(tchBuffer, sgInstallGui.szUnchecked);
|
||||
|
||||
//We've got to actually change the text in the listbox for the screen reader to see it.
|
||||
SendMessage(hwndListBox, LB_INSERTSTRING, dwVisibleIndex, (LPARAM)tchBuffer);
|
||||
SendMessage(hwndListBox, LB_DELETESTRING, dwVisibleIndex+1, 0);
|
||||
}
|
||||
}
|
||||
|
||||
++dwCount;
|
||||
if(!(siCTemp->dwAttributes & SIC_INVISIBLE))
|
||||
++dwVisibleIndex;
|
||||
}
|
||||
|
||||
siCTemp = siCTemp->Next;
|
||||
@ -4701,7 +4748,7 @@ void DeInitDSNode(dsN **dsnComponentDSRequirement)
|
||||
DsNodeDelete(dsnComponentDSRequirement);
|
||||
}
|
||||
|
||||
BOOL ResolveComponentDependency(siCD *siCDInDependency)
|
||||
BOOL ResolveComponentDependency(siCD *siCDInDependency, HWND hwndListBox)
|
||||
{
|
||||
int dwIndex;
|
||||
siCD *siCDepTemp = siCDInDependency;
|
||||
@ -4716,7 +4763,7 @@ BOOL ResolveComponentDependency(siCD *siCDInDependency)
|
||||
if(!(dwAttrib & SIC_SELECTED) && !(dwAttrib & SIC_DISABLED))
|
||||
{
|
||||
bMoreToResolve = TRUE;
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, TRUE, AC_ALL);
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, TRUE, AC_ALL, hwndListBox);
|
||||
}
|
||||
}
|
||||
|
||||
@ -4729,7 +4776,7 @@ BOOL ResolveComponentDependency(siCD *siCDInDependency)
|
||||
if(!(dwAttrib & SIC_SELECTED) && !(dwAttrib & SIC_DISABLED))
|
||||
{
|
||||
bMoreToResolve = TRUE;
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, TRUE, AC_ALL);
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, TRUE, AC_ALL, hwndListBox);
|
||||
}
|
||||
}
|
||||
|
||||
@ -4739,7 +4786,7 @@ BOOL ResolveComponentDependency(siCD *siCDInDependency)
|
||||
return(bMoreToResolve);
|
||||
}
|
||||
|
||||
BOOL ResolveDependencies(DWORD dwIndex)
|
||||
BOOL ResolveDependencies(DWORD dwIndex, HWND hwndListBox)
|
||||
{
|
||||
BOOL bMoreToResolve = FALSE;
|
||||
DWORD dwCount = 0;
|
||||
@ -4752,7 +4799,7 @@ BOOL ResolveDependencies(DWORD dwIndex)
|
||||
{
|
||||
if(SiCNodeGetAttributes(dwCount, TRUE, AC_ALL) & SIC_SELECTED)
|
||||
{
|
||||
bMoreToResolve = ResolveComponentDependency(siCTemp->siCDDependencies);
|
||||
bMoreToResolve = ResolveComponentDependency(siCTemp->siCDDependencies, hwndListBox);
|
||||
if(dwIndex == dwCount)
|
||||
{
|
||||
return(bMoreToResolve);
|
||||
@ -4769,7 +4816,7 @@ BOOL ResolveDependencies(DWORD dwIndex)
|
||||
{
|
||||
if(SiCNodeGetAttributes(dwCount, TRUE, AC_ALL) & SIC_SELECTED)
|
||||
{
|
||||
bMoreToResolve = ResolveComponentDependency(siCTemp->siCDDependencies);
|
||||
bMoreToResolve = ResolveComponentDependency(siCTemp->siCDDependencies, hwndListBox);
|
||||
if(dwIndex == dwCount)
|
||||
{
|
||||
return(bMoreToResolve);
|
||||
@ -4835,7 +4882,7 @@ ssi* SsiGetNode(LPSTR szDescription)
|
||||
return(NULL);
|
||||
}
|
||||
|
||||
void ResolveDependees(LPSTR szToggledReferenceName)
|
||||
void ResolveDependees(LPSTR szToggledReferenceName, HWND hwndListBox)
|
||||
{
|
||||
BOOL bAtLeastOneSelected;
|
||||
BOOL bMoreToResolve = FALSE;
|
||||
@ -4859,7 +4906,7 @@ void ResolveDependees(LPSTR szToggledReferenceName)
|
||||
dwAttrib = SiCNodeGetAttributes(dwIndex, TRUE, AC_ALL);
|
||||
if((dwAttrib & SIC_SELECTED) && !(dwAttrib & SIC_DISABLED))
|
||||
{
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, FALSE, TRUE, AC_ALL);
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, FALSE, TRUE, AC_ALL, hwndListBox);
|
||||
bMoreToResolve = TRUE;
|
||||
}
|
||||
}
|
||||
@ -4871,7 +4918,7 @@ void ResolveDependees(LPSTR szToggledReferenceName)
|
||||
dwAttrib = SiCNodeGetAttributes(dwIndex, TRUE, AC_ALL);
|
||||
if(!(dwAttrib & SIC_SELECTED) && !(dwAttrib & SIC_DISABLED))
|
||||
{
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, TRUE, AC_ALL);
|
||||
SiCNodeSetAttributes(dwIndex, SIC_SELECTED, TRUE, TRUE, AC_ALL, hwndListBox);
|
||||
bMoreToResolve = TRUE;
|
||||
}
|
||||
}
|
||||
@ -4882,7 +4929,7 @@ void ResolveDependees(LPSTR szToggledReferenceName)
|
||||
} while((siCTemp != NULL) && (siCTemp != siComponents));
|
||||
|
||||
if(bMoreToResolve == TRUE)
|
||||
ResolveDependees(szToggledReferenceName);
|
||||
ResolveDependees(szToggledReferenceName, hwndListBox);
|
||||
}
|
||||
|
||||
void PrintUsage(void)
|
||||
@ -6221,6 +6268,8 @@ HRESULT ParseInstallIni()
|
||||
GetPrivateProfileString("General", "README", "", sgInstallGui.szReadme_, sizeof(sgInstallGui.szReadme_), szFileIniInstall);
|
||||
GetPrivateProfileString("General", "PAUSE_", "", sgInstallGui.szPause_, sizeof(sgInstallGui.szPause_), szFileIniInstall);
|
||||
GetPrivateProfileString("General", "RESUME_", "", sgInstallGui.szResume_, sizeof(sgInstallGui.szResume_), szFileIniInstall);
|
||||
GetPrivateProfileString("General", "CHECKED", "", sgInstallGui.szChecked, sizeof(sgInstallGui.szChecked), szFileIniInstall);
|
||||
GetPrivateProfileString("General", "UNCHECKED", "", sgInstallGui.szUnchecked, sizeof(sgInstallGui.szUnchecked), szFileIniInstall);
|
||||
|
||||
return(0);
|
||||
}
|
||||
|
@ -61,7 +61,7 @@ siCD *CreateSiCDepNode(void);
|
||||
void SiCDepNodeDelete(siCD *siCDepTemp);
|
||||
void SiCDepNodeInsert(siCD **siCDepHead, siCD *siCDepTemp);
|
||||
HRESULT SiCNodeGetAttributes(DWORD dwIndex, BOOL bIncludeInvisible, DWORD dwACFlag);
|
||||
void SiCNodeSetAttributes(DWORD dwIndex, DWORD dwAttributes, BOOL bSet, BOOL bIncludeInvisible, DWORD dwACFlag);
|
||||
void SiCNodeSetAttributes(DWORD dwIndex, DWORD dwAttributes, BOOL bSet, BOOL bIncludeInvisible, DWORD dwACFlag, HWND hwndListBox);
|
||||
void SiCNodeSetItemsSelected(DWORD dwSetupType);
|
||||
char *SiCNodeGetReferenceName(DWORD dwIndex, BOOL bIncludeInvisible, DWORD dwACFlag);
|
||||
char *SiCNodeGetDescriptionShort(DWORD dwIndex, BOOL bIncludeInvisible, DWORD dwACFlag);
|
||||
@ -76,9 +76,9 @@ void InitSiComponents(char *szFileIni);
|
||||
HRESULT ParseComponentAttributes(char *szBuf, DWORD dwAttributes, BOOL bOverride);
|
||||
void InitSiteSelector(char *szFileIni);
|
||||
void DeInitSiCDependencies(siCD *siCDDependencies);
|
||||
BOOL ResolveDependencies(DWORD dwIndex);
|
||||
BOOL ResolveComponentDependency(siCD *siCDInDependency);
|
||||
void ResolveDependees(LPSTR szToggledDescriptionShort);
|
||||
BOOL ResolveDependencies(DWORD dwIndex, HWND hwndListBox);
|
||||
BOOL ResolveComponentDependency(siCD *siCDInDependency, HWND hwndListBox);
|
||||
void ResolveDependees(LPSTR szToggledDescriptionShort, HWND hwndListBox);
|
||||
BOOL ResolveComponentDependee(siCD *siCDInDependee);
|
||||
void STSetVisibility(st *stSetupType);
|
||||
HRESULT InitSXpcomFile(void);
|
||||
|
@ -515,6 +515,8 @@ typedef struct dlgInstall
|
||||
char szReadme_[MAX_BUF];
|
||||
char szPause_[MAX_BUF];
|
||||
char szResume_[MAX_BUF];
|
||||
char szChecked[MAX_BUF];
|
||||
char szUnchecked[MAX_BUF];
|
||||
} installGui;
|
||||
|
||||
/* structure message stream */
|
||||
@ -543,6 +545,7 @@ struct sSysInfo
|
||||
DWORD dwMemoryAvailablePhysical;
|
||||
DWORD dwScreenX;
|
||||
DWORD dwScreenY;
|
||||
BOOL bScreenReader;
|
||||
};
|
||||
|
||||
typedef struct diskSpaceNode dsN;
|
||||
|
Loading…
Reference in New Issue
Block a user