minor fixes

svn path=/trunk/; revision=19715
This commit is contained in:
Thomas Bluemel 2005-11-28 01:10:49 +00:00
parent ce6ccd9bb5
commit 7c2d655e6c
3 changed files with 181 additions and 154 deletions

View file

@ -1077,16 +1077,18 @@ SecurityPageProc(IN HWND hwndDlg,
IN LPARAM lParam)
{
PSECURITY_PAGE sp;
INT_PTR Ret = FALSE;
sp = (PSECURITY_PAGE)GetWindowLongPtr(hwndDlg,
DWL_USER);
if (sp != NULL || uMsg == WM_INITDIALOG)
{
switch (uMsg)
{
case WM_NOTIFY:
{
NMHDR *pnmh = (NMHDR*)lParam;
sp = (PSECURITY_PAGE)GetWindowLongPtr(hwndDlg,
DWL_USER);
if (sp != NULL)
{
if (pnmh->hwndFrom == sp->hWndPrincipalsList)
{
switch (pnmh->code)
@ -1123,7 +1125,6 @@ SecurityPageProc(IN HWND hwndDlg,
}
}
}
}
break;
}
@ -1135,9 +1136,6 @@ SecurityPageProc(IN HWND hwndDlg,
{
HRESULT hRet;
sp = (PSECURITY_PAGE)GetWindowLongPtr(hwndDlg,
DWL_USER);
hRet = InitializeObjectPicker(sp->ServerName,
&sp->ObjectInfo,
&sp->pDsObjectPicker);
@ -1164,15 +1162,24 @@ SecurityPageProc(IN HWND hwndDlg,
}
break;
}
case IDC_REMOVE_PRINCIPAL:
{
PPRINCIPAL_LISTITEM SelectedPrincipal;
SelectedPrincipal = (PPRINCIPAL_LISTITEM)ListViewGetSelectedItemData(sp->hWndPrincipalsList);
if (SelectedPrincipal != NULL)
{
/* FIXME */
}
break;
}
}
break;
}
case WM_SIZE:
{
sp = (PSECURITY_PAGE)GetWindowLongPtr(hwndDlg,
DWL_USER);
ResizeControls(sp,
(INT)LOWORD(lParam),
(INT)HIWORD(lParam));
@ -1209,6 +1216,10 @@ SecurityPageProc(IN HWND hwndDlg,
DWL_USER,
(DWORD_PTR)sp);
ListView_SetExtendedListViewStyleEx(sp->hWndPrincipalsList,
LVS_EX_FULLROWSELECT,
LVS_EX_FULLROWSELECT);
sp->hiPrincipals = ImageList_LoadBitmap(hDllInstance,
MAKEINTRESOURCE(IDB_USRGRPIMAGES),
16,
@ -1220,9 +1231,6 @@ SecurityPageProc(IN HWND hwndDlg,
/* setup the listview control */
if (sp->hiPrincipals != NULL)
{
ListView_SetExtendedListViewStyleEx(sp->hWndPrincipalsList,
LVS_EX_FULLROWSELECT,
LVS_EX_FULLROWSELECT);
ListView_SetImageList(sp->hWndPrincipalsList,
sp->hiPrincipals,
LVSIL_SMALL);
@ -1283,10 +1291,13 @@ SecurityPageProc(IN HWND hwndDlg,
UpdateControlStates(sp);
}
Ret = TRUE;
break;
}
}
return 0;
}
return Ret;
}

View file

@ -1498,6 +1498,8 @@ CheckListWndProc(IN HWND hwnd,
{
hdc = (wParam != 0 ? (HDC)wParam : BeginPaint(hwnd, &ps));
if (hdc != NULL)
{
PaintControl(infoPtr,
hdc,
&rcUpdate);
@ -1508,6 +1510,7 @@ CheckListWndProc(IN HWND hwnd,
&ps);
}
}
}
break;
}

View file

@ -338,6 +338,19 @@ InvokeObjectPickerDialog(IN IDsObjectPicker *pDsObjectPicker,
}
GlobalUnlock(stm.hGlobal);
if (SUCCEEDED(hRet))
{
/* return S_OK instead of possible other success codes if
everything went well */
hRet = S_OK;
}
}
else
{
/* unable to translate the selection pointer handle, indicate
failure */
hRet = E_FAIL;
}
ReleaseStgMedium(&stm);