Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
89450e7c
Commit
89450e7c
authored
Apr 30, 2004
by
Jon Griffiths
Committed by
Alexandre Julliard
Apr 30, 2004
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Implement VarDateFromUdateEx.
parent
aedfc471
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
5 deletions
+34
-5
oleaut32.spec
dlls/oleaut32/oleaut32.spec
+1
-1
variant.c
dlls/oleaut32/variant.c
+33
-4
No files found.
dlls/oleaut32/oleaut32.spec
View file @
89450e7c
...
...
@@ -311,7 +311,7 @@
316 stdcall VarR4CmpR8(long double)
317 stdcall VarR8Round(double long ptr)
318 stdcall VarCat(ptr ptr ptr)
319 st
ub VarDateFromUdateEx # stdcall
(ptr long long ptr)
319 st
dcall VarDateFromUdateEx
(ptr long long ptr)
320 stdcall -private DllRegisterServer() OLEAUT32_DllRegisterServer
321 stdcall -private DllUnregisterServer() OLEAUT32_DllUnregisterServer
322 stub GetRecordInfoFromGuids # stdcall (ptr long long long ptr ptr)
...
...
dlls/oleaut32/variant.c
View file @
89450e7c
...
...
@@ -1292,12 +1292,13 @@ INT WINAPI VariantTimeToSystemTime(double dateIn, LPSYSTEMTIME lpSt)
}
/***********************************************************************
* VarDateFromUdate
[OLEAUT32.330
]
* VarDateFromUdate
Ex [OLEAUT32.319
]
*
* Convert an unpacked format date and time to a variant VT_DATE.
*
* PARAMS
* pUdateIn [I] Unpacked format date and time to convert
* lcid [I] Locale identifier for the conversion
* dwFlags [I] Flags controlling the conversion (VAR_ flags from "oleauto.h")
* pDateOut [O] Destination for variant VT_DATE.
*
...
...
@@ -1305,17 +1306,20 @@ INT WINAPI VariantTimeToSystemTime(double dateIn, LPSYSTEMTIME lpSt)
* Success: S_OK. *pDateOut contains the converted value.
* Failure: E_INVALIDARG, if pUdateIn cannot be represented in VT_DATE format.
*/
HRESULT
WINAPI
VarDateFromUdate
(
UDATE
*
pUdateIn
,
ULONG
dwFlags
,
DATE
*
pDateOut
)
HRESULT
WINAPI
VarDateFromUdate
Ex
(
UDATE
*
pUdateIn
,
LCID
lcid
,
ULONG
dwFlags
,
DATE
*
pDateOut
)
{
UDATE
ud
;
double
dateVal
;
TRACE
(
"(%p->%d/%d/%d %d:%d:%d:%d %d %d,0x%08lx,%p)
\n
"
,
pUdateIn
,
TRACE
(
"(%p->%d/%d/%d %d:%d:%d:%d %d %d,0x%08lx,
0x%08lx,
%p)
\n
"
,
pUdateIn
,
pUdateIn
->
st
.
wMonth
,
pUdateIn
->
st
.
wDay
,
pUdateIn
->
st
.
wYear
,
pUdateIn
->
st
.
wHour
,
pUdateIn
->
st
.
wMinute
,
pUdateIn
->
st
.
wSecond
,
pUdateIn
->
st
.
wMilliseconds
,
pUdateIn
->
st
.
wDayOfWeek
,
pUdateIn
->
wDayOfYear
,
dwFlags
,
pDateOut
);
pUdateIn
->
wDayOfYear
,
lcid
,
dwFlags
,
pDateOut
);
if
(
lcid
!=
MAKELCID
(
MAKELANGID
(
LANG_ENGLISH
,
SUBLANG_ENGLISH_US
),
SORT_DEFAULT
))
FIXME
(
"lcid possibly not handled, treating as en-us
\n
"
);
memcpy
(
&
ud
,
pUdateIn
,
sizeof
(
ud
));
if
(
dwFlags
&
VAR_VALIDDATE
)
...
...
@@ -1339,6 +1343,31 @@ HRESULT WINAPI VarDateFromUdate(UDATE *pUdateIn, ULONG dwFlags, DATE *pDateOut)
}
/***********************************************************************
* VarDateFromUdate [OLEAUT32.330]
*
* Convert an unpacked format date and time to a variant VT_DATE.
*
* PARAMS
* pUdateIn [I] Unpacked format date and time to convert
* dwFlags [I] Flags controlling the conversion (VAR_ flags from "oleauto.h")
* pDateOut [O] Destination for variant VT_DATE.
*
* RETURNS
* Success: S_OK. *pDateOut contains the converted value.
* Failure: E_INVALIDARG, if pUdateIn cannot be represented in VT_DATE format.
*
* NOTES
* This function uses the United States English locale for the conversion. Use
* VarDateFromUdateEx() for alternate locales.
*/
HRESULT
WINAPI
VarDateFromUdate
(
UDATE
*
pUdateIn
,
ULONG
dwFlags
,
DATE
*
pDateOut
)
{
LCID
lcid
=
MAKELCID
(
MAKELANGID
(
LANG_ENGLISH
,
SUBLANG_ENGLISH_US
),
SORT_DEFAULT
);
return
VarDateFromUdateEx
(
pUdateIn
,
lcid
,
dwFlags
,
pDateOut
);
}
/***********************************************************************
* VarUdateFromDate [OLEAUT32.331]
*
* Convert a variant VT_DATE into an unpacked format date and time.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment