Update indentation, no code changes.

svn path=/trunk/; revision=26419
This commit is contained in:
Eric Kohl 2007-04-19 07:10:37 +00:00
parent 627d3f8c10
commit b7e4d48a47
2 changed files with 49 additions and 57 deletions

View file

@ -281,16 +281,12 @@ KeybHardwareProc(IN HWND hwndDlg,
switch(uMsg) switch(uMsg)
{ {
case WM_INITDIALOG: case WM_INITDIALOG:
{ /* Create the hardware page */
/* create the hardware page */
DeviceCreateHardwarePageEx(hwndDlg, DeviceCreateHardwarePageEx(hwndDlg,
Guids, Guids,
sizeof(Guids) / sizeof(Guids[0]), sizeof(Guids) / sizeof(Guids[0]),
HWPD_STANDARDLIST); HWPD_STANDARDLIST);
break; break;
}
} }
return FALSE; return FALSE;

View file

@ -52,77 +52,73 @@ APPLET Applets[NUM_APPLETS] =
VOID VOID
InitPropSheetPage(PROPSHEETPAGE *psp, WORD idDlg, DLGPROC DlgProc) InitPropSheetPage(PROPSHEETPAGE *psp, WORD idDlg, DLGPROC DlgProc)
{ {
ZeroMemory(psp, sizeof(PROPSHEETPAGE)); ZeroMemory(psp, sizeof(PROPSHEETPAGE));
psp->dwSize = sizeof(PROPSHEETPAGE); psp->dwSize = sizeof(PROPSHEETPAGE);
psp->dwFlags = PSP_DEFAULT; psp->dwFlags = PSP_DEFAULT;
psp->hInstance = hApplet; psp->hInstance = hApplet;
psp->pszTemplate = MAKEINTRESOURCE(idDlg); psp->pszTemplate = MAKEINTRESOURCE(idDlg);
psp->pfnDlgProc = DlgProc; psp->pfnDlgProc = DlgProc;
} }
/* Control Panel Callback */ /* Control Panel Callback */
LONG CALLBACK LONG CALLBACK
CPlApplet(HWND hwndCpl, CPlApplet(HWND hwndCpl,
UINT uMsg, UINT uMsg,
LPARAM lParam1, LPARAM lParam1,
LPARAM lParam2) LPARAM lParam2)
{ {
switch(uMsg) switch(uMsg)
{
case CPL_INIT:
return TRUE;
case CPL_GETCOUNT:
return NUM_APPLETS;
case CPL_INQUIRE:
{ {
CPLINFO *CPlInfo = (CPLINFO*)lParam2; case CPL_INIT:
UINT uAppIndex = (UINT)lParam1; return TRUE;
CPlInfo->lData = lParam1; case CPL_GETCOUNT:
CPlInfo->idIcon = Applets[uAppIndex].idIcon; return NUM_APPLETS;
CPlInfo->idName = Applets[uAppIndex].idName;
CPlInfo->idInfo = Applets[uAppIndex].idDescription; case CPL_INQUIRE:
break; {
CPLINFO *CPlInfo = (CPLINFO*)lParam2;
UINT uAppIndex = (UINT)lParam1;
CPlInfo->lData = lParam1;
CPlInfo->idIcon = Applets[uAppIndex].idIcon;
CPlInfo->idName = Applets[uAppIndex].idName;
CPlInfo->idInfo = Applets[uAppIndex].idDescription;
break;
}
case CPL_DBLCLK:
{
UINT uAppIndex = (UINT)lParam1;
Applets[uAppIndex].AppletProc(hwndCpl, uMsg, lParam1, lParam2);
break;
}
} }
case CPL_DBLCLK: return FALSE;
{
UINT uAppIndex = (UINT)lParam1;
Applets[uAppIndex].AppletProc(hwndCpl, uMsg, lParam1, lParam2);
break;
}
}
return FALSE;
} }
BOOL STDCALL BOOL STDCALL
DllMain(HINSTANCE hinstDLL, DllMain(HINSTANCE hinstDLL,
DWORD dwReason, DWORD dwReason,
LPVOID lpReserved) LPVOID lpReserved)
{ {
INITCOMMONCONTROLSEX InitControls; INITCOMMONCONTROLSEX InitControls;
UNREFERENCED_PARAMETER(lpReserved); UNREFERENCED_PARAMETER(lpReserved);
switch(dwReason) switch(dwReason)
{ {
case DLL_PROCESS_ATTACH: case DLL_PROCESS_ATTACH:
case DLL_THREAD_ATTACH: InitControls.dwSize = sizeof(INITCOMMONCONTROLSEX);
InitControls.dwICC = ICC_LISTVIEW_CLASSES | ICC_UPDOWN_CLASS | ICC_BAR_CLASSES;
InitCommonControlsEx(&InitControls);
hApplet = hinstDLL;
break;
}
InitControls.dwSize = sizeof(INITCOMMONCONTROLSEX); return TRUE;
InitControls.dwICC = ICC_LISTVIEW_CLASSES | ICC_UPDOWN_CLASS | ICC_BAR_CLASSES;
InitCommonControlsEx(&InitControls);
hApplet = hinstDLL;
break;
}
return TRUE;
} }