d3d9/tests: Test the presentation parameters after creating a device.
[wine.git] / include / windows.devices.enumeration.idl
blob4f15ac811bcdb00076fd6c8e3af74b6c784879b3
1 /*
2 * Copyright 2021 Gijs Vermeulen
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2.1 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the Free Software
16 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
19 #ifdef __WIDL__
20 #pragma winrt ns_prefix
21 #endif
23 import "inspectable.idl";
24 import "asyncinfo.idl";
25 import "eventtoken.idl";
26 import "windowscontracts.idl";
27 import "windows.storage.streams.idl";
28 import "windows.foundation.idl";
30 namespace Windows.Devices.Enumeration {
31 typedef enum DeviceClass DeviceClass;
32 typedef enum DeviceInformationKind DeviceInformationKind;
33 typedef enum DeviceWatcherStatus DeviceWatcherStatus;
34 typedef enum Panel Panel;
35 typedef enum DeviceAccessStatus DeviceAccessStatus;
37 interface IDeviceInformation;
38 interface IDeviceInformationStatics;
39 interface IDeviceInformationStatics2;
40 interface IDeviceInformationUpdate;
41 interface IEnclosureLocation;
43 runtimeclass DeviceInformation;
44 runtimeclass DeviceInformationCollection;
45 runtimeclass DeviceInformationUpdate;
46 runtimeclass DeviceThumbnail;
47 runtimeclass DeviceWatcher;
48 runtimeclass EnclosureLocation;
49 runtimeclass DeviceAccessChangedEventArgs;
50 runtimeclass DeviceAccessInformation;
52 declare
54 interface Windows.Foundation.Collections.IVectorView<Windows.Devices.Enumeration.DeviceInformation *>;
55 interface Windows.Foundation.Collections.IIterable<Windows.Devices.Enumeration.DeviceInformation *>;
56 interface Windows.Foundation.Collections.IIterator<Windows.Devices.Enumeration.DeviceInformation *>;
57 interface Windows.Foundation.AsyncOperationCompletedHandler<Windows.Devices.Enumeration.DeviceInformation *>;
58 interface Windows.Foundation.AsyncOperationCompletedHandler<Windows.Devices.Enumeration.DeviceInformationCollection *>;
59 interface Windows.Foundation.AsyncOperationCompletedHandler<Windows.Devices.Enumeration.DeviceThumbnail *>;
60 interface Windows.Foundation.Collections.IMapView<HSTRING, IInspectable *>;
61 interface Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformation *>;
62 interface Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformationCollection *>;
63 interface Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceThumbnail *>;
64 interface Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *, IInspectable *>;
65 interface Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *, Windows.Devices.Enumeration.DeviceInformation *>;
66 interface Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *, Windows.Devices.Enumeration.DeviceInformationUpdate *>;
67 interface Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceAccessInformation *, Windows.Devices.Enumeration.DeviceAccessChangedEventArgs *>;
71 namespace Windows.Devices.Enumeration {
72 [contract(Windows.Foundation.UniversalApiContract, 1.0)]
73 enum DeviceClass
75 All = 0,
76 AudioCapture = 1,
77 AudioRender = 2,
78 PortableStorageDevice = 3,
79 VideoCapture = 4,
80 [contract(Windows.Foundation.UniversalApiContract, 1.0)]
81 ImageScanner = 5,
82 [contract(Windows.Foundation.UniversalApiContract, 1.0)]
83 Location = 6,
86 [contract(Windows.Foundation.UniversalApiContract, 1.0)]
87 enum DeviceInformationKind
89 Unknown = 0,
90 DeviceInterface = 1,
91 DeviceContainer = 2,
92 Device = 3,
93 DeviceInterfaceClass = 4,
94 AssociationEndpoint = 5,
95 AssociationEndpointContainer = 6,
96 AssociationEndpointService = 7,
97 [contract(Windows.Foundation.UniversalApiContract, 7.0)]
98 DevicePanel = 8,
101 enum DeviceWatcherStatus
103 Created = 0,
104 Started = 1,
105 EnumerationCompleted = 2,
106 Stopping = 3,
107 Stopped = 4,
108 Aborted = 5,
111 enum Panel
113 Unknown = 0,
114 Front = 1,
115 Back = 2,
116 Top = 3,
117 Bottom = 4,
118 Left = 5,
119 Right = 6,
122 [contract(Windows.Foundation.UniversalApiContract, 1.0)]
123 enum DeviceAccessStatus
125 Unspecified = 0,
126 Allowed = 1,
127 DeniedByUser = 2,
128 DeniedBySystem = 3,
132 exclusiveto(Windows.Devices.Enumeration.DeviceInformation),
133 uuid(aba0fb95-4398-489d-8e44-e6130927011f)
135 interface IDeviceInformation : IInspectable
137 [propget] HRESULT Id([out, retval] HSTRING *value);
138 [propget] HRESULT Name([out, retval] HSTRING *value);
139 [propget] HRESULT IsEnabled([out, retval] boolean *value);
140 [propget] HRESULT IsDefault([out, retval] boolean *value);
141 [propget] HRESULT EnclosureLocation([out, retval] Windows.Devices.Enumeration.EnclosureLocation **value);
142 [propget] HRESULT Properties([out, retval] Windows.Foundation.Collections.IMapView<HSTRING, IInspectable *> **value);
143 HRESULT Update([in] Windows.Devices.Enumeration.DeviceInformationUpdate *info);
144 HRESULT GetThumbnailAsync([out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceThumbnail *> **operation);
145 HRESULT GetGlyphThumbnailAsync([out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceThumbnail *> **operation);
149 exclusiveto(Windows.Devices.Enumeration.DeviceInformationUpdate),
150 uuid(8f315305-d972-44b7-a37e-9e822c78213b)
152 interface IDeviceInformationUpdate : IInspectable
154 [propget] HRESULT Id([out, retval] HSTRING *value);
155 [propget] HRESULT Properties([out, retval] Windows.Foundation.Collections.IMapView<HSTRING, IInspectable *> **value);
159 exclusiveto(Windows.Devices.Enumeration.DeviceWatcher),
160 uuid(c9eab97d-8f6b-4f96-a9f4-abc814e22271),
162 interface IDeviceWatcher : IInspectable
164 [eventadd] HRESULT Added([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *,
165 Windows.Devices.Enumeration.DeviceInformation *> *handler, [out, retval] EventRegistrationToken *token);
166 [eventremove] HRESULT Added([in] EventRegistrationToken token);
167 [eventadd] HRESULT Updated([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *,
168 Windows.Devices.Enumeration.DeviceInformationUpdate *> *handler, [out, retval] EventRegistrationToken *token);
169 [eventremove] HRESULT Updated([in] EventRegistrationToken token);
170 [eventadd] HRESULT Removed([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *,
171 Windows.Devices.Enumeration.DeviceInformationUpdate *> *handler, [out, retval] EventRegistrationToken *token);
172 [eventremove] HRESULT Removed([in] EventRegistrationToken token);
173 [eventadd] HRESULT EnumerationCompleted([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *,
174 IInspectable *> *handler, [out, retval] EventRegistrationToken *token);
175 [eventremove] HRESULT EnumerationCompleted([in] EventRegistrationToken token);
176 [eventadd] HRESULT Stopped([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceWatcher *,
177 IInspectable *> *handler, [out, retval] EventRegistrationToken *token);
178 [eventremove] HRESULT Stopped([in] EventRegistrationToken token);
179 [propget] HRESULT Status([out, retval] Windows.Devices.Enumeration.DeviceWatcherStatus *status);
180 HRESULT Start();
181 HRESULT Stop();
185 exclusiveto(Windows.Devices.Enumeration.EnclosureLocation),
186 uuid(42340a27-5810-459c-aabb-c65e1f813ecf)
188 interface IEnclosureLocation : IInspectable
190 [propget] HRESULT InDock([out, retval] boolean *value);
191 [propget] HRESULT InLid([out, retval] boolean *value);
192 [propget] HRESULT Panel([out, retval] Windows.Devices.Enumeration.Panel *value);
196 contract(Windows.Foundation.UniversalApiContract, 1.0),
197 exclusiveto(Windows.Devices.Enumeration.DeviceInformation),
198 uuid(c17f100e-3a46-4a78-8013-769dc9b97390)
200 interface IDeviceInformationStatics : IInspectable
202 [overload("CreateFromIdAsync")]
203 HRESULT CreateFromIdAsync([in] HSTRING id,
204 [out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformation *> **op);
205 [overload("CreateFromIdAsync")]
206 HRESULT CreateFromIdAsyncAdditionalProperties([in] HSTRING id,
207 [in] Windows.Foundation.Collections.IIterable<HSTRING> *additional_properties,
208 [out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformation *> **op);
209 [overload("FindAllAsync")]
210 HRESULT FindAllAsync([out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformationCollection *> **op);
211 [overload("FindAllAsync"), default_overload]
212 HRESULT FindAllAsyncDeviceClass([in] Windows.Devices.Enumeration.DeviceClass device_class,
213 [out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformationCollection *> **op);
214 [overload("FindAllAsync")]
215 HRESULT FindAllAsyncAqsFilter([in] HSTRING filter,
216 [out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformationCollection *> **op);
217 [overload("FindAllAsync")]
218 HRESULT FindAllAsyncAqsFilterAndAdditionalProperties([in] HSTRING filter,
219 [in] Windows.Foundation.Collections.IIterable<HSTRING> *additional_properties,
220 [out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformationCollection *> **op);
221 [overload("CreateWatcher")]
222 HRESULT CreateWatcher([out, retval] Windows.Devices.Enumeration.DeviceWatcher **watcher);
223 [overload("CreateWatcher"), default_overload]
224 HRESULT CreateWatcherDeviceClass([in] Windows.Devices.Enumeration.DeviceClass device_class,
225 [out, retval] Windows.Devices.Enumeration.DeviceWatcher **watcher);
226 [overload("CreateWatcher")]
227 HRESULT CreateWatcherAqsFilter([in] HSTRING filter, [out, retval] Windows.Devices.Enumeration.DeviceWatcher **watcher);
228 [overload("CreateWatcher")]
229 HRESULT CreateWatcherAqsFilterAndAdditionalProperties([in] HSTRING filter,
230 [in] Windows.Foundation.Collections.IIterable<HSTRING> *additional_properties, [out, retval] Windows.Devices.Enumeration.DeviceWatcher **watcher);
234 contract(Windows.Foundation.UniversalApiContract, 1.0),
235 exclusiveto(Windows.Devices.Enumeration.DeviceInformation),
236 uuid(493b4f34-a84f-45fd-9167-15d1cb1bd1f9)
238 interface IDeviceInformationStatics2 : IInspectable
240 HRESULT GetAqsFilterFromDeviceClass([in] Windows.Devices.Enumeration.DeviceClass device_class, [out, retval] HSTRING *filter);
241 [overload("CreateFromIdAsync")]
242 HRESULT CreateFromIdAsyncWithKindAndAdditionalProperties([in] HSTRING device_id,
243 [in] Windows.Foundation.Collections.IIterable<HSTRING> *additional_properties,
244 [in] Windows.Devices.Enumeration.DeviceInformationKind kind,
245 [out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformation *> **async_operation);
246 [overload("FindAllAsync")]
247 HRESULT FindAllAsyncWithKindAqsFilterAndAdditionalProperties([in] HSTRING filter,
248 [in] Windows.Foundation.Collections.IIterable<HSTRING> *additional_properties,
249 [in] Windows.Devices.Enumeration.DeviceInformationKind kind,
250 [out, retval] Windows.Foundation.IAsyncOperation<Windows.Devices.Enumeration.DeviceInformationCollection *> **async_operation);
251 [overload("CreateWatcher")]
252 HRESULT CreateWatcherWithKindAqsFilterAndAdditionalProperties([in] HSTRING filter,
253 [in] Windows.Foundation.Collections.IIterable<HSTRING> *additional_properties,
254 [in] Windows.Devices.Enumeration.DeviceInformationKind kind,
255 [out, retval] Windows.Devices.Enumeration.DeviceWatcher **watcher);
259 contract(Windows.Foundation.UniversalApiContract, 1.0),
260 exclusiveto(Windows.Devices.Enumeration.DeviceAccessChangedEventArgs),
261 uuid(deda0bcc-4f9d-4f58-9dba-a9bc800408d5)
263 interface IDeviceAccessChangedEventArgs : IInspectable
265 [propget] HRESULT Status([out, retval] Windows.Devices.Enumeration.DeviceAccessStatus *value);
269 contract(Windows.Foundation.UniversalApiContract, 3.0),
270 exclusiveto(Windows.Devices.Enumeration.DeviceAccessChangedEventArgs),
271 uuid(82523262-934b-4b30-a178-adc39f2f2be3)
273 interface IDeviceAccessChangedEventArgs2 : IInspectable
274 requires Windows.Devices.Enumeration.IDeviceAccessChangedEventArgs
276 [propget] HRESULT Id([out, retval] HSTRING *value);
280 contract(Windows.Foundation.UniversalApiContract, 1.0),
281 exclusiveto(Windows.Devices.Enumeration.DeviceAccessInformation),
282 uuid(0baa9a73-6de5-4915-8ddd-9a0554a6f545)
284 interface IDeviceAccessInformation : IInspectable
286 [eventadd] HRESULT AccessChanged([in] Windows.Foundation.TypedEventHandler<Windows.Devices.Enumeration.DeviceAccessInformation *, Windows.Devices.Enumeration.DeviceAccessChangedEventArgs *> *handler, [out, retval] EventRegistrationToken *cookie);
287 [eventremove] HRESULT AccessChanged([in] EventRegistrationToken cookie);
288 [propget] HRESULT CurrentStatus([out, retval] Windows.Devices.Enumeration.DeviceAccessStatus *status);
292 contract(Windows.Foundation.UniversalApiContract, 1.0),
293 exclusiveto(Windows.Devices.Enumeration.DeviceAccessInformation),
294 uuid(574bd3d3-5f30-45cd-8a94-724fe5973084),
296 interface IDeviceAccessInformationStatics : IInspectable
298 HRESULT CreateFromId([in] HSTRING device_id, [out, retval] Windows.Devices.Enumeration.DeviceAccessInformation **value);
299 HRESULT CreateFromDeviceClassId([in] GUID device_class_id, [out, retval] Windows.Devices.Enumeration.DeviceAccessInformation **value);
300 HRESULT CreateFromDeviceClass([in] Windows.Devices.Enumeration.DeviceClass device_class, [out, retval] Windows.Devices.Enumeration.DeviceAccessInformation **value);
304 contract(Windows.Foundation.UniversalApiContract, 1.0),
305 marshaling_behavior(agile),
306 static(Windows.Devices.Enumeration.IDeviceInformationStatics, Windows.Foundation.UniversalApiContract, 1.0),
307 static(Windows.Devices.Enumeration.IDeviceInformationStatics2, Windows.Foundation.UniversalApiContract, 1.0),
308 threading(both)
310 runtimeclass DeviceInformation
312 [default] interface Windows.Devices.Enumeration.IDeviceInformation;
313 [contract(Windows.Foundation.UniversalApiContract, 1.0)] interface Windows.Devices.Enumeration.IDeviceInformation2;
317 contract(Windows.Foundation.UniversalApiContract, 1.0),
318 marshaling_behavior(agile),
320 runtimeclass DeviceInformationCollection
322 [default] interface Windows.Foundation.Collections.IVectorView<Windows.Devices.Enumeration.DeviceInformation *>;
323 interface Windows.Foundation.Collections.IIterable<Windows.Devices.Enumeration.DeviceInformation *>;
327 marshaling_behavior(agile),
329 runtimeclass DeviceInformationUpdate
331 [default] interface Windows.Devices.Enumeration.IDeviceInformationUpdate;
332 interface Windows.Devices.Enumeration.IDeviceInformationUpdate2;
336 marshaling_behavior(agile),
338 runtimeclass DeviceThumbnail
340 [default] interface Windows.Storage.Streams.IRandomAccessStreamWithContentType;
341 interface Windows.Storage.Streams.IContentTypeProvider;
342 interface Windows.Storage.Streams.IRandomAccessStream;
343 interface Windows.Storage.Streams.IOutputStream;
344 interface Windows.Foundation.IClosable;
345 interface Windows.Storage.Streams.IInputStream;
349 marshaling_behavior(agile),
351 runtimeclass DeviceWatcher
353 [default] interface Windows.Devices.Enumeration.IDeviceWatcher;
354 interface Windows.Devices.Enumeration.IDeviceWatcher2;
358 marshaling_behavior(agile)
360 runtimeclass EnclosureLocation
362 [default] interface Windows.Devices.Enumeration.IEnclosureLocation;
366 contract(Windows.Foundation.UniversalApiContract, 1.0),
367 marshaling_behavior(agile)
369 runtimeclass DeviceAccessChangedEventArgs
371 [default] interface Windows.Devices.Enumeration.IDeviceAccessChangedEventArgs;
372 [contract(Windows.Foundation.UniversalApiContract, 3.0)] interface Windows.Devices.Enumeration.IDeviceAccessChangedEventArgs2;
376 contract(Windows.Foundation.UniversalApiContract, 1.0),
377 marshaling_behavior(agile),
378 static(Windows.Devices.Enumeration.IDeviceAccessInformationStatics, Windows.Foundation.UniversalApiContract, 1.0),
379 threading(both)
381 runtimeclass DeviceAccessInformation
383 [default] interface Windows.Devices.Enumeration.IDeviceAccessInformation;