Mikołaj Zalewski : shell32: Use SHELL_ConfirmDialogW when deleting multiple files.
Alexandre Julliard
julliard at wine.codeweavers.com
Tue Jun 20 05:23:15 CDT 2006
Module: wine
Branch: refs/heads/master
Commit: 529346e8f4c3c2d73466681ebe0a898d1d695a2c
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=529346e8f4c3c2d73466681ebe0a898d1d695a2c
Author: Mikołaj Zalewski <mikolaj at zalewski.pl>
Date: Tue Jun 20 09:47:11 2006 +0200
shell32: Use SHELL_ConfirmDialogW when deleting multiple files.
---
dlls/shell32/shell32_main.h | 2 +-
dlls/shell32/shfldr_fs.c | 7 ++++---
2 files changed, 5 insertions(+), 4 deletions(-)
diff --git a/dlls/shell32/shell32_main.h b/dlls/shell32/shell32_main.h
index 7ead345..32d002f 100644
--- a/dlls/shell32/shell32_main.h
+++ b/dlls/shell32/shell32_main.h
@@ -149,7 +149,7 @@ #define ASK_OVERWRITE_FILE 5
BOOL SHELL_DeleteDirectoryW(LPCWSTR pwszDir, BOOL bShowUI);
BOOL SHELL_DeleteFileW(LPCWSTR pwszFile, BOOL bShowUI);
-BOOL SHELL_ConfirmDialog(int nKindOfDialog, LPCSTR szDir);
+BOOL SHELL_ConfirmDialogW(int nKindOfDialog, LPCWSTR szDir);
/* 16-bit functions */
void WINAPI DragAcceptFiles16(HWND16 hWnd, BOOL16 b);
diff --git a/dlls/shell32/shfldr_fs.c b/dlls/shell32/shfldr_fs.c
index 1ac8d0f..d683007 100644
--- a/dlls/shell32/shfldr_fs.c
+++ b/dlls/shell32/shfldr_fs.c
@@ -1172,10 +1172,11 @@ ISFHelper_fnDeleteItems (ISFHelper * ifa
/* deleting multiple items so give a slightly different warning */
if (cidl != 1) {
- char tmp[8];
+ WCHAR tmp[8];
+ static const WCHAR format[] = {'%','d',0};
- snprintf (tmp, sizeof (tmp), "%d", cidl);
- if (!SHELL_ConfirmDialog(ASK_DELETE_MULTIPLE_ITEM, tmp))
+ wnsprintfW (tmp, sizeof(tmp)/sizeof(tmp[0]), format, cidl);
+ if (!SHELL_ConfirmDialogW(ASK_DELETE_MULTIPLE_ITEM, tmp))
return E_FAIL;
bConfirm = FALSE;
}
More information about the wine-cvs
mailing list