diff --git a/dlls/shell32/shfldr_unixfs.c b/dlls/shell32/shfldr_unixfs.c index f586605f20d..034db114a7f 100644 --- a/dlls/shell32/shfldr_unixfs.c +++ b/dlls/shell32/shfldr_unixfs.c @@ -1455,8 +1455,45 @@ static HRESULT WINAPI UnixFolder_ISFHelper_DeleteItems(ISFHelper* iface, UINT ci static HRESULT WINAPI UnixFolder_ISFHelper_CopyItems(ISFHelper* iface, IShellFolder *psfFrom, UINT cidl, LPCITEMIDLIST *apidl) { - FIXME("stub\n"); - return E_NOTIMPL; + UnixFolder *This = ADJUST_THIS(UnixFolder, ISFHelper, iface); + DWORD dwAttributes; + UINT i; + HRESULT hr; + char szAbsoluteDst[FILENAME_MAX], *pszRelativeDst; + + TRACE("(iface=%p, psfFrom=%p, cidl=%d, apidl=%p): semi-stub\n", iface, psfFrom, cidl, apidl); + + if (!psfFrom || !cidl || !apidl) + return E_INVALIDARG; + + /* All source items have to be filesystem items. */ + dwAttributes = SFGAO_FILESYSTEM; + hr = IShellFolder_GetAttributesOf(psfFrom, cidl, apidl, &dwAttributes); + if (FAILED(hr) || !(dwAttributes & SFGAO_FILESYSTEM)) + return E_INVALIDARG; + + lstrcpyA(szAbsoluteDst, This->m_pszPath); + pszRelativeDst = szAbsoluteDst + strlen(szAbsoluteDst); + + for (i=0; i