Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
f16960ae
Commit
f16960ae
authored
Nov 18, 2014
by
Nikolay Sivov
Committed by
Alexandre Julliard
Nov 19, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dwrite: Implement GetLastWriteTime() for local stream.
parent
65644170
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
10 deletions
+23
-10
font.c
dlls/dwrite/font.c
+16
-10
font.c
dlls/dwrite/tests/font.c
+7
-0
No files found.
dlls/dwrite/font.c
View file @
f16960ae
...
...
@@ -1973,11 +1973,17 @@ HRESULT create_fontface(DWRITE_FONT_FACE_TYPE facetype, UINT32 files_number, IDW
}
/* IDWriteLocalFontFileLoader and its required IDWriteFontFileStream */
struct
local_refkey
{
FILETIME
writetime
;
WCHAR
name
[
1
];
};
struct
local_cached_stream
{
struct
list
entry
;
IDWriteFontFileStream
*
stream
;
void
*
key
;
struct
local_refkey
*
key
;
UINT32
key_size
;
};
...
...
@@ -1990,12 +1996,6 @@ struct dwrite_localfontfilestream
HANDLE
handle
;
};
struct
local_refkey
{
FILETIME
writetime
;
WCHAR
name
[
1
];
};
struct
dwrite_localfontfileloader
{
IDWriteLocalFontFileLoader
IDWriteLocalFontFileLoader_iface
;
LONG
ref
;
...
...
@@ -2106,9 +2106,15 @@ static HRESULT WINAPI localfontfilestream_GetFileSize(IDWriteFontFileStream *ifa
static
HRESULT
WINAPI
localfontfilestream_GetLastWriteTime
(
IDWriteFontFileStream
*
iface
,
UINT64
*
last_writetime
)
{
struct
dwrite_localfontfilestream
*
This
=
impl_from_IDWriteFontFileStream
(
iface
);
FIXME
(
"(%p)->(%p): stub
\n
"
,
This
,
last_writetime
);
*
last_writetime
=
0
;
return
E_NOTIMPL
;
ULARGE_INTEGER
li
;
TRACE
(
"(%p)->(%p)
\n
"
,
This
,
last_writetime
);
li
.
LowPart
=
This
->
entry
->
key
->
writetime
.
dwLowDateTime
;
li
.
HighPart
=
This
->
entry
->
key
->
writetime
.
dwHighDateTime
;
*
last_writetime
=
li
.
QuadPart
;
return
S_OK
;
}
static
const
IDWriteFontFileStreamVtbl
localfontfilestreamvtbl
=
...
...
dlls/dwrite/tests/font.c
View file @
f16960ae
...
...
@@ -2362,6 +2362,7 @@ static void test_CreateStreamFromKey(void)
IDWriteFontFileLoader
*
loader
;
IDWriteFactory
*
factory
;
IDWriteFontFile
*
file
;
UINT64
writetime
;
void
*
key
;
UINT32
size
;
HRESULT
hr
;
...
...
@@ -2398,6 +2399,12 @@ static void test_CreateStreamFromKey(void)
hr
=
IDWriteLocalFontFileLoader_CreateStreamFromKey
(
localloader
,
key
,
size
,
&
stream
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
EXPECT_REF
(
stream
,
1
);
writetime
=
0
;
hr
=
IDWriteFontFileStream_GetLastWriteTime
(
stream
,
&
writetime
);
ok
(
hr
==
S_OK
,
"got 0x%08x
\n
"
,
hr
);
ok
(
writetime
!=
0
,
"got %08x%08x
\n
"
,
(
UINT
)(
writetime
>>
32
),
(
UINT
)
writetime
);
IDWriteFontFileStream_Release
(
stream
);
IDWriteLocalFontFileLoader_Release
(
localloader
);
...
...
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