mirror of
https://github.com/reactos/reactos.git
synced 2024-12-28 10:04:49 +00:00
Do not change flags unless necessary. https://bugs.winehq.org/show_bug.cgi?id=54567 CORE-17064
This commit is contained in:
parent
f4bb0ae376
commit
2284aa6e8b
1 changed files with 22 additions and 6 deletions
|
@ -89,9 +89,11 @@ static void COMDLG32_FR_HandleWMCommand(HWND hDlgWnd, COMDLG32_FR_Data *pData, i
|
|||
{
|
||||
DWORD flag;
|
||||
|
||||
#ifndef __REACTOS__
|
||||
pData->user_fr.fra->Flags &= ~FR_MASK; /* Clear return flags */
|
||||
if(pData->fr.Flags & FR_WINE_REPLACE) /* Replace always goes down... */
|
||||
pData->user_fr.fra->Flags |= FR_DOWN;
|
||||
#endif
|
||||
|
||||
if(NotifyCode == BN_CLICKED)
|
||||
{
|
||||
|
@ -100,6 +102,11 @@ static void COMDLG32_FR_HandleWMCommand(HWND hDlgWnd, COMDLG32_FR_Data *pData, i
|
|||
case IDOK: /* Find Next */
|
||||
if(GetDlgItemTextA(hDlgWnd, edt1, pData->fr.lpstrFindWhat, pData->fr.wFindWhatLen) > 0)
|
||||
{
|
||||
#ifdef __REACTOS__
|
||||
pData->user_fr.fra->Flags &= ~FR_MASK; /* Clear return flags */
|
||||
if(pData->fr.Flags & FR_WINE_REPLACE) /* Replace always goes down... */
|
||||
pData->user_fr.fra->Flags |= FR_DOWN;
|
||||
#endif
|
||||
pData->user_fr.fra->Flags |= COMDLG32_FR_GetFlags(hDlgWnd) | FR_FINDNEXT;
|
||||
if(pData->fr.Flags & FR_WINE_UNICODE)
|
||||
{
|
||||
|
@ -116,6 +123,11 @@ static void COMDLG32_FR_HandleWMCommand(HWND hDlgWnd, COMDLG32_FR_Data *pData, i
|
|||
break;
|
||||
|
||||
case IDCANCEL:
|
||||
#ifdef __REACTOS__
|
||||
pData->user_fr.fra->Flags &= ~FR_MASK; /* Clear return flags */
|
||||
if(pData->fr.Flags & FR_WINE_REPLACE) /* Replace always goes down... */
|
||||
pData->user_fr.fra->Flags |= FR_DOWN;
|
||||
#endif
|
||||
pData->user_fr.fra->Flags |= COMDLG32_FR_GetFlags(hDlgWnd) | FR_DIALOGTERM;
|
||||
SendMessageA(pData->fr.hwndOwner, FindReplaceMessage, 0, (LPARAM)pData->user_fr.fra);
|
||||
DestroyWindow(hDlgWnd);
|
||||
|
@ -133,6 +145,11 @@ Replace:
|
|||
{
|
||||
pData->fr.lpstrReplaceWith[0] = 0; /* In case the next GetDlgItemText Fails */
|
||||
GetDlgItemTextA(hDlgWnd, edt2, pData->fr.lpstrReplaceWith, pData->fr.wReplaceWithLen);
|
||||
#ifdef __REACTOS__
|
||||
pData->user_fr.fra->Flags &= ~FR_MASK; /* Clear return flags */
|
||||
if(pData->fr.Flags & FR_WINE_REPLACE) /* Replace always goes down... */
|
||||
pData->user_fr.fra->Flags |= FR_DOWN;
|
||||
#endif
|
||||
pData->user_fr.fra->Flags |= COMDLG32_FR_GetFlags(hDlgWnd) | flag;
|
||||
if(pData->fr.Flags & FR_WINE_UNICODE)
|
||||
{
|
||||
|
@ -153,6 +170,11 @@ Replace:
|
|||
break;
|
||||
|
||||
case pshHelp:
|
||||
#ifdef __REACTOS__
|
||||
pData->user_fr.fra->Flags &= ~FR_MASK; /* Clear return flags */
|
||||
if(pData->fr.Flags & FR_WINE_REPLACE) /* Replace always goes down... */
|
||||
pData->user_fr.fra->Flags |= FR_DOWN;
|
||||
#endif
|
||||
pData->user_fr.fra->Flags |= COMDLG32_FR_GetFlags(hDlgWnd);
|
||||
SendMessageA(pData->fr.hwndOwner, HelpMessage, (WPARAM)hDlgWnd, (LPARAM)pData->user_fr.fra);
|
||||
break;
|
||||
|
@ -168,12 +190,6 @@ Replace:
|
|||
EnableWindow(GetDlgItem(hDlgWnd, psh2), enable);
|
||||
}
|
||||
}
|
||||
#ifdef __REACTOS__
|
||||
else if (NotifyCode == EN_KILLFOCUS && Id == edt1)
|
||||
{
|
||||
pData->user_fr.fra->Flags |= COMDLG32_FR_GetFlags(hDlgWnd);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
/***********************************************************************
|
||||
|
|
Loading…
Reference in a new issue