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
d2d225f6
Commit
d2d225f6
authored
May 22, 2012
by
Vincent Povirk
Committed by
Alexandre Julliard
May 23, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
propsys: Implement IPropertyStore::GetCount.
parent
51ab8139
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
7 deletions
+24
-7
propstore.c
dlls/propsys/propstore.c
+19
-2
propstore.c
dlls/propsys/tests/propstore.c
+5
-5
No files found.
dlls/propsys/propstore.c
View file @
d2d225f6
...
...
@@ -133,8 +133,24 @@ static ULONG WINAPI PropertyStore_Release(IPropertyStoreCache *iface)
static
HRESULT
WINAPI
PropertyStore_GetCount
(
IPropertyStoreCache
*
iface
,
DWORD
*
cProps
)
{
FIXME
(
"%p,%p: stub
\n
"
,
iface
,
cProps
);
return
E_NOTIMPL
;
PropertyStore
*
This
=
impl_from_IPropertyStoreCache
(
iface
);
propstore_format
*
format
;
TRACE
(
"%p,%p
\n
"
,
iface
,
cProps
);
if
(
!
cProps
)
return
E_POINTER
;
*
cProps
=
0
;
EnterCriticalSection
(
&
This
->
lock
);
LIST_FOR_EACH_ENTRY
(
format
,
&
This
->
formats
,
propstore_format
,
entry
)
*
cProps
+=
format
->
count
;
LeaveCriticalSection
(
&
This
->
lock
);
return
S_OK
;
}
static
HRESULT
WINAPI
PropertyStore_GetAt
(
IPropertyStoreCache
*
iface
,
...
...
@@ -201,6 +217,7 @@ static HRESULT PropertyStore_LookupValue(PropertyStore *This, REFPROPERTYKEY key
value
->
pid
=
key
->
pid
;
list_add_tail
(
&
format
->
values
,
&
value
->
entry
);
format
->
count
++
;
}
*
result
=
value
;
...
...
dlls/propsys/tests/propstore.c
View file @
d2d225f6
...
...
@@ -55,11 +55,11 @@ static void test_inmemorystore(void)
}
hr
=
IPropertyStoreCache_GetCount
(
propcache
,
NULL
);
todo_wine
ok
(
hr
==
E_POINTER
,
"GetCount failed, hr=%x
\n
"
,
hr
);
ok
(
hr
==
E_POINTER
,
"GetCount failed, hr=%x
\n
"
,
hr
);
hr
=
IPropertyStoreCache_GetCount
(
propcache
,
&
count
);
todo_wine
ok
(
hr
==
S_OK
,
"GetCount failed, hr=%x
\n
"
,
hr
);
todo_wine
ok
(
count
==
0
,
"GetCount returned %i, expected 0
\n
"
,
count
);
ok
(
hr
==
S_OK
,
"GetCount failed, hr=%x
\n
"
,
hr
);
ok
(
count
==
0
,
"GetCount returned %i, expected 0
\n
"
,
count
);
hr
=
IPropertyStoreCache_Commit
(
propcache
);
ok
(
hr
==
S_OK
,
"Commit failed, hr=%x
\n
"
,
hr
);
...
...
@@ -91,8 +91,8 @@ static void test_inmemorystore(void)
ok
(
hr
==
S_OK
,
"SetValue failed, hr=%x
\n
"
,
hr
);
hr
=
IPropertyStoreCache_GetCount
(
propcache
,
&
count
);
todo_wine
ok
(
hr
==
S_OK
,
"GetCount failed, hr=%x
\n
"
,
hr
);
todo_wine
ok
(
count
==
1
,
"GetCount returned %i, expected 0
\n
"
,
count
);
ok
(
hr
==
S_OK
,
"GetCount failed, hr=%x
\n
"
,
hr
);
ok
(
count
==
1
,
"GetCount returned %i, expected 0
\n
"
,
count
);
memset
(
&
pkey
,
0
,
sizeof
(
pkey
));
...
...
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