Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Gabriel Ivăncescu
wine
Commits
006bc33c
Commit
006bc33c
authored
2 years ago
by
Mohamad Al-Jaf
Committed by
Alexandre Julliard
2 years ago
Browse files
Options
Downloads
Patches
Plain Diff
windows.perception.stub: Add ISpatialSurfaceObserverStatics2 stub interface.
parent
b7d55543
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
dlls/windows.perception.stub/observer.c
+30
-0
30 additions, 0 deletions
dlls/windows.perception.stub/observer.c
dlls/windows.perception.stub/tests/perception.c
+6
-0
6 additions, 0 deletions
dlls/windows.perception.stub/tests/perception.c
with
36 additions
and
0 deletions
dlls/windows.perception.stub/observer.c
+
30
−
0
View file @
006bc33c
...
...
@@ -27,6 +27,7 @@ struct observer
{
IActivationFactory
IActivationFactory_iface
;
ISpatialSurfaceObserverStatics
ISpatialSurfaceObserverStatics_iface
;
ISpatialSurfaceObserverStatics2
ISpatialSurfaceObserverStatics2_iface
;
LONG
ref
;
};
...
...
@@ -58,6 +59,13 @@ static HRESULT WINAPI factory_QueryInterface( IActivationFactory *iface, REFIID
return
S_OK
;
}
if
(
IsEqualGUID
(
iid
,
&
IID_ISpatialSurfaceObserverStatics2
))
{
*
out
=
&
impl
->
ISpatialSurfaceObserverStatics2_iface
;
IInspectable_AddRef
(
*
out
);
return
S_OK
;
}
FIXME
(
"%s not implemented, returning E_NOINTERFACE.
\n
"
,
debugstr_guid
(
iid
)
);
*
out
=
NULL
;
return
E_NOINTERFACE
;
...
...
@@ -137,10 +145,32 @@ static const struct ISpatialSurfaceObserverStaticsVtbl observer_statics_vtbl =
observer_statics_RequestAccessAsync
,
};
DEFINE_IINSPECTABLE
(
observer_statics2
,
ISpatialSurfaceObserverStatics2
,
struct
observer
,
IActivationFactory_iface
)
static
HRESULT
WINAPI
observer_statics2_IsSupported
(
ISpatialSurfaceObserverStatics2
*
iface
,
boolean
*
value
)
{
FIXME
(
"iface %p, value %p stub!
\n
"
,
iface
,
value
);
return
E_NOTIMPL
;
}
static
const
struct
ISpatialSurfaceObserverStatics2Vtbl
observer_statics2_vtbl
=
{
observer_statics2_QueryInterface
,
observer_statics2_AddRef
,
observer_statics2_Release
,
/* IInspectable methods */
observer_statics2_GetIids
,
observer_statics2_GetRuntimeClassName
,
observer_statics2_GetTrustLevel
,
/* ISpatialSurfaceObserverStatics2 methods */
observer_statics2_IsSupported
,
};
static
struct
observer
observer_statics
=
{
{
&
factory_vtbl
},
{
&
observer_statics_vtbl
},
{
&
observer_statics2_vtbl
},
1
,
};
...
...
This diff is collapsed.
Click to expand it.
dlls/windows.perception.stub/tests/perception.c
+
6
−
0
View file @
006bc33c
...
...
@@ -48,6 +48,7 @@ static void check_interface_( unsigned int line, void *obj, const IID *iid )
static
void
test_ObserverStatics
(
void
)
{
static
const
WCHAR
*
observer_statics_name
=
L"Windows.Perception.Spatial.Surfaces.SpatialSurfaceObserver"
;
ISpatialSurfaceObserverStatics2
*
observer_statics2
;
IActivationFactory
*
factory
;
HSTRING
str
;
HRESULT
hr
;
...
...
@@ -70,6 +71,11 @@ static void test_ObserverStatics(void)
check_interface
(
factory
,
&
IID_IAgileObject
);
check_interface
(
factory
,
&
IID_ISpatialSurfaceObserverStatics
);
hr
=
IActivationFactory_QueryInterface
(
factory
,
&
IID_ISpatialSurfaceObserverStatics2
,
(
void
**
)
&
observer_statics2
);
ok
(
hr
==
S_OK
,
"got hr %#lx.
\n
"
,
hr
);
ref
=
ISpatialSurfaceObserverStatics2_Release
(
observer_statics2
);
ok
(
ref
==
2
,
"got ref %ld.
\n
"
,
ref
);
ref
=
IActivationFactory_Release
(
factory
);
ok
(
ref
==
1
,
"got ref %ld.
\n
"
,
ref
);
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment