f601660 scrrun: Added DateLastModified property for IFile.
svn path=/trunk/; revision=74845
return SetFileAttributesW(This->path, pfa) ? S_OK : create_error(GetLastError());
}
return SetFileAttributesW(This->path, pfa) ? S_OK : create_error(GetLastError());
}
+static HRESULT get_date_from_filetime(const FILETIME *ft, DATE *date)
+{
+ FILETIME ftlocal;
+ SYSTEMTIME st;
+
+ if (!date)
+ return E_POINTER;
+
+ FileTimeToLocalFileTime(ft, &ftlocal);
+ FileTimeToSystemTime(&ftlocal, &st);
+ SystemTimeToVariantTime(&st, date);
+
+ return S_OK;
+}
+
static HRESULT WINAPI file_get_DateCreated(IFile *iface, DATE *pdate)
{
struct file *This = impl_from_IFile(iface);
static HRESULT WINAPI file_get_DateCreated(IFile *iface, DATE *pdate)
{
struct file *This = impl_from_IFile(iface);
-static HRESULT WINAPI file_get_DateLastModified(IFile *iface, DATE *pdate)
+static HRESULT WINAPI file_get_DateLastModified(IFile *iface, DATE *date)
{
struct file *This = impl_from_IFile(iface);
{
struct file *This = impl_from_IFile(iface);
- FIXME("(%p)->(%p)\n", This, pdate);
- return E_NOTIMPL;
+ WIN32_FILE_ATTRIBUTE_DATA attrs;
+
+ TRACE("(%p)->(%p)\n", This, date);
+
+ if (GetFileAttributesExW(This->path, GetFileExInfoStandard, &attrs))
+ return get_date_from_filetime(&attrs.ftLastWriteTime, date);
+
+ return E_FAIL;
}
static HRESULT WINAPI file_get_DateLastAccessed(IFile *iface, DATE *pdate)
}
static HRESULT WINAPI file_get_DateLastAccessed(IFile *iface, DATE *pdate)
reactos/dll/win32/rsaenh # Synced to WineStaging-2.9
reactos/dll/win32/sccbase # Synced to WineStaging-1.9.11
reactos/dll/win32/schannel # Synced to WineStaging-1.9.11
reactos/dll/win32/rsaenh # Synced to WineStaging-2.9
reactos/dll/win32/sccbase # Synced to WineStaging-1.9.11
reactos/dll/win32/schannel # Synced to WineStaging-1.9.11
-reactos/dll/win32/scrrun # Synced to WineStaging-2.2
+reactos/dll/win32/scrrun # Synced to WineStaging-2.9
reactos/dll/win32/secur32 # Forked
reactos/dll/win32/security # Forked (different .spec)
reactos/dll/win32/sensapi # Synced to WineStaging-1.9.11
reactos/dll/win32/secur32 # Forked
reactos/dll/win32/security # Forked (different .spec)
reactos/dll/win32/sensapi # Synced to WineStaging-1.9.11