mirror of
https://github.com/reactos/reactos.git
synced 2025-07-27 21:22:24 +00:00
Shell Folders: Reject invalid characters (#2328)
Reject invalid input filename characters by using shell32!SHLimitInputEdit function and IItemNameLimits interface. Improve SHLimitInputEdit to sanitize paste. CORE-11701
This commit is contained in:
parent
0a7a747d87
commit
bc1519dd87
7 changed files with 219 additions and 10 deletions
|
@ -1989,9 +1989,13 @@ LRESULT CDefView::OnNotify(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL &bHandl
|
|||
m_pSFParent->GetAttributesOf(1, &pidl, &dwAttr);
|
||||
if (SFGAO_CANRENAME & dwAttr)
|
||||
{
|
||||
HWND hEdit = reinterpret_cast<HWND>(m_ListView.SendMessage(LVM_GETEDITCONTROL));
|
||||
SHLimitInputEdit(hEdit, m_pSFParent);
|
||||
|
||||
m_isEditing = TRUE;
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue