Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Ticket #1027 (assigned defect)

Opened 5 months ago

Last modified 3 months ago

SHFileOperation in UserGdi should be SHFileOperationA SHFileOperationW

Reported by: yidabu Assigned to: kris (accepted)
Priority: major Milestone: 1.0
Component: Packaging Version: 0.99.5 Jascha
Keywords: UserGdi triage Cc: yidabu

Description

/**

tango.sys.win32.UserGdi? int SHFileOperation(LPSHFILEOPSTRUCT) should be:

*/

    int SHFileOperationA(LPSHFILEOPSTRUCTA);
    int SHFileOperationW(LPSHFILEOPSTRUCTW);

//tango.sys.win32.Types SHFILEOPSTRUCT shouled be:

struct SHFILEOPSTRUCTA {
	HWND         hwnd;
	UINT         wFunc;
	LPCSTR       pFrom;
	LPCSTR       pTo;
	FILEOP_FLAGS fFlags;
	BOOL         fAnyOperationsAborted;
	PVOID        hNameMappings;
	LPCSTR       lpszProgressTitle;
}
alias SHFILEOPSTRUCTA* LPSHFILEOPSTRUCTA;

struct SHFILEOPSTRUCTW {
	HWND         hwnd;
	UINT         wFunc;
	LPCWSTR      pFrom;
	LPCWSTR      pTo;
	FILEOP_FLAGS fFlags;
	BOOL         fAnyOperationsAborted;
	PVOID        hNameMappings;
	LPCWSTR      lpszProgressTitle;
}
alias SHFILEOPSTRUCTW* LPSHFILEOPSTRUCTW;

and add these to Types.di, for use with SHFileOperation

/** lacks in Tango 
 See_Also:
    SHFILEOPSTRUCT http://msdn2.microsoft.com/en-us/library/bb759795(VS.85).aspx
    SHFileOperation http://msdn2.microsoft.com/en-us/library/bb762164(VS.85).aspx
*/
const FILEOP_FLAGS
	FOF_MULTIDESTFILES        = 0x0001,
	FOF_CONFIRMMOUSE          = 0x0002,
	FOF_SILENT                = 0x0004,
	FOF_RENAMEONCOLLISION     = 0x0008,
	FOF_NOCONFIRMATION        = 0x0010,
	FOF_WANTMAPPINGHANDLE     = 0x0020,
	FOF_ALLOWUNDO             = 0x0040,
	FOF_FILESONLY             = 0x0080,
	FOF_SIMPLEPROGRESS        = 0x0100,
	FOF_NOCONFIRMMKDIR        = 0x0200,
	FOF_NOERRORUI             = 0x0400,
	FOF_NOCOPYSECURITYATTRIBS = 0x0800;

enum : UINT {
	FO_MOVE = 1,
	FO_COPY,
	FO_DELETE,
	FO_RENAME
}

Change History

04/18/08 00:38:10 changed by kris

  • status changed from new to assigned.
  • milestone changed from 0.99.6 to 1.0.

05/24/08 13:29:46 changed by larsivi

  • keywords changed from UserGdi to UserGdi triage.