winrt-Windows.Devices.Adc 2.0.0b2__tar.gz → 2.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/PKG-INFO +5 -1
- winrt_windows_devices_adc-2.1.0/all-requirements.txt +5 -0
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/py.Windows.Devices.Adc.cpp +105 -113
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/pyproject.toml +2 -2
- winrt_windows_devices_adc-2.1.0/pywinrt-version.txt +1 -0
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/requirements.txt +2 -2
- winrt_windows_devices_adc-2.1.0/setup.py +31 -0
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/winrt/_winrt_windows_devices_adc.pyi +6 -6
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/winrt/windows/devices/adc/__init__.py +1 -1
- winrt_windows_devices_adc-2.1.0/winrt/windows/devices/adc/py.typed +0 -0
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/winrt_Windows.Devices.Adc.egg-info/PKG-INFO +5 -1
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/winrt_Windows.Devices.Adc.egg-info/SOURCES.txt +1 -0
- winrt_windows_devices_adc-2.1.0/winrt_Windows.Devices.Adc.egg-info/requires.txt +6 -0
- winrt-Windows.Devices.Adc-2.0.0b2/all-requirements.txt +0 -5
- winrt-Windows.Devices.Adc-2.0.0b2/pywinrt-version.txt +0 -1
- winrt-Windows.Devices.Adc-2.0.0b2/setup.py +0 -16
- winrt-Windows.Devices.Adc-2.0.0b2/winrt_Windows.Devices.Adc.egg-info/requires.txt +0 -6
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/README.md +0 -0
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/setup.cfg +0 -0
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/winrt_Windows.Devices.Adc.egg-info/dependency_links.txt +0 -0
- {winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/winrt_Windows.Devices.Adc.egg-info/top_level.txt +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: winrt-Windows.Devices.Adc
|
|
3
|
-
Version: 2.0
|
|
3
|
+
Version: 2.1.0
|
|
4
4
|
Summary: Python projection of Windows Runtime (WinRT) APIs
|
|
5
5
|
License: MIT
|
|
6
6
|
Project-URL: Documentation, https://pywinrt.readthedocs.io
|
|
@@ -12,7 +12,11 @@ Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
|
12
12
|
Classifier: Intended Audience :: Developers
|
|
13
13
|
Requires-Python: <3.13,>=3.9
|
|
14
14
|
Description-Content-Type: text/markdown
|
|
15
|
+
Requires-Dist: winrt-runtime==2.1.0
|
|
15
16
|
Provides-Extra: all
|
|
17
|
+
Requires-Dist: winrt-Windows.Devices.Adc.Provider[all]==2.1.0; extra == "all"
|
|
18
|
+
Requires-Dist: winrt-Windows.Foundation[all]==2.1.0; extra == "all"
|
|
19
|
+
Requires-Dist: winrt-Windows.Foundation.Collections[all]==2.1.0; extra == "all"
|
|
16
20
|
|
|
17
21
|
<!-- warning: Please don't edit this file. It was automatically generated. -->
|
|
18
22
|
|
{winrt-Windows.Devices.Adc-2.0.0b2 → winrt_windows_devices_adc-2.1.0}/py.Windows.Devices.Adc.cpp
RENAMED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
// WARNING: Please don't edit this file. It was generated by Python/WinRT v2.
|
|
1
|
+
// WARNING: Please don't edit this file. It was generated by Python/WinRT v2.1.0
|
|
2
2
|
|
|
3
3
|
#include "py.Windows.Devices.Adc.h"
|
|
4
4
|
|
|
5
|
-
|
|
6
5
|
namespace py::cpp::Windows::Devices::Adc
|
|
7
6
|
{
|
|
8
7
|
// ----- AdcChannel class --------------------
|
|
@@ -28,14 +27,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
28
27
|
|
|
29
28
|
if (arg_count == 0)
|
|
30
29
|
{
|
|
31
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcChannel", L"Close", 0))
|
|
32
|
-
{
|
|
33
|
-
py::set_arg_count_version_error(0);
|
|
34
|
-
return nullptr;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
30
|
try
|
|
38
31
|
{
|
|
32
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcChannel", L"Close", 0))
|
|
33
|
+
{
|
|
34
|
+
py::set_arg_count_version_error(0);
|
|
35
|
+
return nullptr;
|
|
36
|
+
}
|
|
37
|
+
|
|
39
38
|
self->obj.Close();
|
|
40
39
|
Py_RETURN_NONE;
|
|
41
40
|
}
|
|
@@ -58,14 +57,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
58
57
|
|
|
59
58
|
if (arg_count == 0)
|
|
60
59
|
{
|
|
61
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcChannel", L"ReadRatio", 0))
|
|
62
|
-
{
|
|
63
|
-
py::set_arg_count_version_error(0);
|
|
64
|
-
return nullptr;
|
|
65
|
-
}
|
|
66
|
-
|
|
67
60
|
try
|
|
68
61
|
{
|
|
62
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcChannel", L"ReadRatio", 0))
|
|
63
|
+
{
|
|
64
|
+
py::set_arg_count_version_error(0);
|
|
65
|
+
return nullptr;
|
|
66
|
+
}
|
|
67
|
+
|
|
69
68
|
return py::convert(self->obj.ReadRatio());
|
|
70
69
|
}
|
|
71
70
|
catch (...)
|
|
@@ -87,14 +86,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
87
86
|
|
|
88
87
|
if (arg_count == 0)
|
|
89
88
|
{
|
|
90
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcChannel", L"ReadValue", 0))
|
|
91
|
-
{
|
|
92
|
-
py::set_arg_count_version_error(0);
|
|
93
|
-
return nullptr;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
89
|
try
|
|
97
90
|
{
|
|
91
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcChannel", L"ReadValue", 0))
|
|
92
|
+
{
|
|
93
|
+
py::set_arg_count_version_error(0);
|
|
94
|
+
return nullptr;
|
|
95
|
+
}
|
|
96
|
+
|
|
98
97
|
return py::convert(self->obj.ReadValue());
|
|
99
98
|
}
|
|
100
99
|
catch (...)
|
|
@@ -112,14 +111,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
112
111
|
|
|
113
112
|
static PyObject* AdcChannel_get_Controller(py::wrapper::Windows::Devices::Adc::AdcChannel* self, void* /*unused*/) noexcept
|
|
114
113
|
{
|
|
115
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcChannel", L"Controller"))
|
|
116
|
-
{
|
|
117
|
-
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
118
|
-
return nullptr;
|
|
119
|
-
}
|
|
120
|
-
|
|
121
114
|
try
|
|
122
115
|
{
|
|
116
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcChannel", L"Controller"))
|
|
117
|
+
{
|
|
118
|
+
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
119
|
+
return nullptr;
|
|
120
|
+
}
|
|
121
|
+
|
|
123
122
|
return py::convert(self->obj.Controller());
|
|
124
123
|
}
|
|
125
124
|
catch (...)
|
|
@@ -179,7 +178,7 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
179
178
|
{ "_assign_array_", _assign_array_AdcChannel, METH_O | METH_STATIC, nullptr },
|
|
180
179
|
{ "_from", reinterpret_cast<PyCFunction>(_from_AdcChannel), METH_O | METH_STATIC, nullptr },
|
|
181
180
|
{ "__enter__", reinterpret_cast<PyCFunction>(_enter_AdcChannel), METH_NOARGS, nullptr },
|
|
182
|
-
{ "__exit__",
|
|
181
|
+
{ "__exit__", reinterpret_cast<PyCFunction>(_exit_AdcChannel), METH_VARARGS, nullptr },
|
|
183
182
|
{ }
|
|
184
183
|
};
|
|
185
184
|
|
|
@@ -188,23 +187,20 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
188
187
|
{ }
|
|
189
188
|
};
|
|
190
189
|
|
|
191
|
-
static PyType_Slot _type_slots_AdcChannel[] =
|
|
192
|
-
{
|
|
190
|
+
static PyType_Slot _type_slots_AdcChannel[] = {
|
|
193
191
|
{ Py_tp_new, reinterpret_cast<void*>(_new_AdcChannel) },
|
|
194
192
|
{ Py_tp_dealloc, reinterpret_cast<void*>(_dealloc_AdcChannel) },
|
|
195
193
|
{ Py_tp_methods, reinterpret_cast<void*>(_methods_AdcChannel) },
|
|
196
194
|
{ Py_tp_getset, reinterpret_cast<void*>(_getset_AdcChannel) },
|
|
197
|
-
{ }
|
|
195
|
+
{ }
|
|
198
196
|
};
|
|
199
197
|
|
|
200
|
-
static PyType_Spec type_spec_AdcChannel =
|
|
201
|
-
{
|
|
198
|
+
static PyType_Spec type_spec_AdcChannel = {
|
|
202
199
|
"winrt._winrt_windows_devices_adc.AdcChannel",
|
|
203
200
|
sizeof(py::wrapper::Windows::Devices::Adc::AdcChannel),
|
|
204
201
|
0,
|
|
205
202
|
Py_TPFLAGS_DEFAULT,
|
|
206
|
-
_type_slots_AdcChannel
|
|
207
|
-
};
|
|
203
|
+
_type_slots_AdcChannel};
|
|
208
204
|
|
|
209
205
|
// ----- AdcController class --------------------
|
|
210
206
|
|
|
@@ -229,14 +225,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
229
225
|
|
|
230
226
|
if (arg_count == 1)
|
|
231
227
|
{
|
|
232
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"GetControllersAsync", 1))
|
|
233
|
-
{
|
|
234
|
-
py::set_arg_count_version_error(1);
|
|
235
|
-
return nullptr;
|
|
236
|
-
}
|
|
237
|
-
|
|
238
228
|
try
|
|
239
229
|
{
|
|
230
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"GetControllersAsync", 1))
|
|
231
|
+
{
|
|
232
|
+
py::set_arg_count_version_error(1);
|
|
233
|
+
return nullptr;
|
|
234
|
+
}
|
|
235
|
+
|
|
240
236
|
auto param0 = py::convert_to<winrt::Windows::Devices::Adc::Provider::IAdcProvider>(args, 0);
|
|
241
237
|
|
|
242
238
|
return py::convert(winrt::Windows::Devices::Adc::AdcController::GetControllersAsync(param0));
|
|
@@ -260,14 +256,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
260
256
|
|
|
261
257
|
if (arg_count == 0)
|
|
262
258
|
{
|
|
263
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"GetDefaultAsync", 0))
|
|
264
|
-
{
|
|
265
|
-
py::set_arg_count_version_error(0);
|
|
266
|
-
return nullptr;
|
|
267
|
-
}
|
|
268
|
-
|
|
269
259
|
try
|
|
270
260
|
{
|
|
261
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"GetDefaultAsync", 0))
|
|
262
|
+
{
|
|
263
|
+
py::set_arg_count_version_error(0);
|
|
264
|
+
return nullptr;
|
|
265
|
+
}
|
|
266
|
+
|
|
271
267
|
return py::convert(winrt::Windows::Devices::Adc::AdcController::GetDefaultAsync());
|
|
272
268
|
}
|
|
273
269
|
catch (...)
|
|
@@ -289,14 +285,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
289
285
|
|
|
290
286
|
if (arg_count == 1)
|
|
291
287
|
{
|
|
292
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"IsChannelModeSupported", 1))
|
|
293
|
-
{
|
|
294
|
-
py::set_arg_count_version_error(1);
|
|
295
|
-
return nullptr;
|
|
296
|
-
}
|
|
297
|
-
|
|
298
288
|
try
|
|
299
289
|
{
|
|
290
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"IsChannelModeSupported", 1))
|
|
291
|
+
{
|
|
292
|
+
py::set_arg_count_version_error(1);
|
|
293
|
+
return nullptr;
|
|
294
|
+
}
|
|
295
|
+
|
|
300
296
|
auto param0 = py::convert_to<winrt::Windows::Devices::Adc::AdcChannelMode>(args, 0);
|
|
301
297
|
|
|
302
298
|
return py::convert(self->obj.IsChannelModeSupported(param0));
|
|
@@ -320,14 +316,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
320
316
|
|
|
321
317
|
if (arg_count == 1)
|
|
322
318
|
{
|
|
323
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"OpenChannel", 1))
|
|
324
|
-
{
|
|
325
|
-
py::set_arg_count_version_error(1);
|
|
326
|
-
return nullptr;
|
|
327
|
-
}
|
|
328
|
-
|
|
329
319
|
try
|
|
330
320
|
{
|
|
321
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsMethodPresent(L"Windows.Devices.Adc.AdcController", L"OpenChannel", 1))
|
|
322
|
+
{
|
|
323
|
+
py::set_arg_count_version_error(1);
|
|
324
|
+
return nullptr;
|
|
325
|
+
}
|
|
326
|
+
|
|
331
327
|
auto param0 = py::convert_to<int32_t>(args, 0);
|
|
332
328
|
|
|
333
329
|
return py::convert(self->obj.OpenChannel(param0));
|
|
@@ -347,14 +343,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
347
343
|
|
|
348
344
|
static PyObject* AdcController_get_ChannelMode(py::wrapper::Windows::Devices::Adc::AdcController* self, void* /*unused*/) noexcept
|
|
349
345
|
{
|
|
350
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ChannelMode"))
|
|
351
|
-
{
|
|
352
|
-
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
353
|
-
return nullptr;
|
|
354
|
-
}
|
|
355
|
-
|
|
356
346
|
try
|
|
357
347
|
{
|
|
348
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ChannelMode"))
|
|
349
|
+
{
|
|
350
|
+
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
351
|
+
return nullptr;
|
|
352
|
+
}
|
|
353
|
+
|
|
358
354
|
return py::convert(self->obj.ChannelMode());
|
|
359
355
|
}
|
|
360
356
|
catch (...)
|
|
@@ -366,12 +362,6 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
366
362
|
|
|
367
363
|
static int AdcController_put_ChannelMode(py::wrapper::Windows::Devices::Adc::AdcController* self, PyObject* arg, void* /*unused*/) noexcept
|
|
368
364
|
{
|
|
369
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ChannelMode"))
|
|
370
|
-
{
|
|
371
|
-
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
372
|
-
return -1;
|
|
373
|
-
}
|
|
374
|
-
|
|
375
365
|
if (arg == nullptr)
|
|
376
366
|
{
|
|
377
367
|
PyErr_SetString(PyExc_AttributeError, "can't delete attribute");
|
|
@@ -380,6 +370,12 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
380
370
|
|
|
381
371
|
try
|
|
382
372
|
{
|
|
373
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ChannelMode"))
|
|
374
|
+
{
|
|
375
|
+
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
376
|
+
return -1;
|
|
377
|
+
}
|
|
378
|
+
|
|
383
379
|
auto param0 = py::convert_to<winrt::Windows::Devices::Adc::AdcChannelMode>(arg);
|
|
384
380
|
|
|
385
381
|
self->obj.ChannelMode(param0);
|
|
@@ -394,14 +390,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
394
390
|
|
|
395
391
|
static PyObject* AdcController_get_ChannelCount(py::wrapper::Windows::Devices::Adc::AdcController* self, void* /*unused*/) noexcept
|
|
396
392
|
{
|
|
397
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ChannelCount"))
|
|
398
|
-
{
|
|
399
|
-
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
400
|
-
return nullptr;
|
|
401
|
-
}
|
|
402
|
-
|
|
403
393
|
try
|
|
404
394
|
{
|
|
395
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ChannelCount"))
|
|
396
|
+
{
|
|
397
|
+
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
398
|
+
return nullptr;
|
|
399
|
+
}
|
|
400
|
+
|
|
405
401
|
return py::convert(self->obj.ChannelCount());
|
|
406
402
|
}
|
|
407
403
|
catch (...)
|
|
@@ -413,14 +409,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
413
409
|
|
|
414
410
|
static PyObject* AdcController_get_MaxValue(py::wrapper::Windows::Devices::Adc::AdcController* self, void* /*unused*/) noexcept
|
|
415
411
|
{
|
|
416
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"MaxValue"))
|
|
417
|
-
{
|
|
418
|
-
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
419
|
-
return nullptr;
|
|
420
|
-
}
|
|
421
|
-
|
|
422
412
|
try
|
|
423
413
|
{
|
|
414
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"MaxValue"))
|
|
415
|
+
{
|
|
416
|
+
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
417
|
+
return nullptr;
|
|
418
|
+
}
|
|
419
|
+
|
|
424
420
|
return py::convert(self->obj.MaxValue());
|
|
425
421
|
}
|
|
426
422
|
catch (...)
|
|
@@ -432,14 +428,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
432
428
|
|
|
433
429
|
static PyObject* AdcController_get_MinValue(py::wrapper::Windows::Devices::Adc::AdcController* self, void* /*unused*/) noexcept
|
|
434
430
|
{
|
|
435
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"MinValue"))
|
|
436
|
-
{
|
|
437
|
-
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
438
|
-
return nullptr;
|
|
439
|
-
}
|
|
440
|
-
|
|
441
431
|
try
|
|
442
432
|
{
|
|
433
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"MinValue"))
|
|
434
|
+
{
|
|
435
|
+
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
436
|
+
return nullptr;
|
|
437
|
+
}
|
|
438
|
+
|
|
443
439
|
return py::convert(self->obj.MinValue());
|
|
444
440
|
}
|
|
445
441
|
catch (...)
|
|
@@ -451,14 +447,14 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
451
447
|
|
|
452
448
|
static PyObject* AdcController_get_ResolutionInBits(py::wrapper::Windows::Devices::Adc::AdcController* self, void* /*unused*/) noexcept
|
|
453
449
|
{
|
|
454
|
-
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ResolutionInBits"))
|
|
455
|
-
{
|
|
456
|
-
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
457
|
-
return nullptr;
|
|
458
|
-
}
|
|
459
|
-
|
|
460
450
|
try
|
|
461
451
|
{
|
|
452
|
+
if (!winrt::Windows::Foundation::Metadata::ApiInformation::IsPropertyPresent(L"Windows.Devices.Adc.AdcController", L"ResolutionInBits"))
|
|
453
|
+
{
|
|
454
|
+
PyErr_SetString(PyExc_AttributeError, "property is not available in this version of Windows");
|
|
455
|
+
return nullptr;
|
|
456
|
+
}
|
|
457
|
+
|
|
462
458
|
return py::convert(self->obj.ResolutionInBits());
|
|
463
459
|
}
|
|
464
460
|
catch (...)
|
|
@@ -509,23 +505,20 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
509
505
|
{ }
|
|
510
506
|
};
|
|
511
507
|
|
|
512
|
-
static PyType_Slot _type_slots_AdcController[] =
|
|
513
|
-
{
|
|
508
|
+
static PyType_Slot _type_slots_AdcController[] = {
|
|
514
509
|
{ Py_tp_new, reinterpret_cast<void*>(_new_AdcController) },
|
|
515
510
|
{ Py_tp_dealloc, reinterpret_cast<void*>(_dealloc_AdcController) },
|
|
516
511
|
{ Py_tp_methods, reinterpret_cast<void*>(_methods_AdcController) },
|
|
517
512
|
{ Py_tp_getset, reinterpret_cast<void*>(_getset_AdcController) },
|
|
518
|
-
{ }
|
|
513
|
+
{ }
|
|
519
514
|
};
|
|
520
515
|
|
|
521
|
-
static PyType_Spec type_spec_AdcController =
|
|
522
|
-
{
|
|
516
|
+
static PyType_Spec type_spec_AdcController = {
|
|
523
517
|
"winrt._winrt_windows_devices_adc.AdcController",
|
|
524
518
|
sizeof(py::wrapper::Windows::Devices::Adc::AdcController),
|
|
525
519
|
0,
|
|
526
520
|
Py_TPFLAGS_DEFAULT,
|
|
527
|
-
_type_slots_AdcController
|
|
528
|
-
};
|
|
521
|
+
_type_slots_AdcController};
|
|
529
522
|
|
|
530
523
|
static PyGetSetDef getset_AdcController_Static[] = {
|
|
531
524
|
{ }
|
|
@@ -555,20 +548,19 @@ namespace py::cpp::Windows::Devices::Adc
|
|
|
555
548
|
};
|
|
556
549
|
|
|
557
550
|
// ----- Windows.Devices.Adc Initialization --------------------
|
|
558
|
-
PyDoc_STRVAR(module_doc, "Windows::Devices::Adc");
|
|
559
|
-
|
|
560
551
|
|
|
561
|
-
|
|
562
|
-
= {PyModuleDef_HEAD_INIT,
|
|
563
|
-
"_winrt_windows_devices_adc",
|
|
564
|
-
module_doc,
|
|
565
|
-
0,
|
|
566
|
-
nullptr,
|
|
567
|
-
nullptr,
|
|
568
|
-
nullptr,
|
|
569
|
-
nullptr,
|
|
570
|
-
nullptr};
|
|
552
|
+
PyDoc_STRVAR(module_doc, "Windows.Devices.Adc");
|
|
571
553
|
|
|
554
|
+
static PyModuleDef module_def = {
|
|
555
|
+
PyModuleDef_HEAD_INIT,
|
|
556
|
+
"_winrt_windows_devices_adc",
|
|
557
|
+
module_doc,
|
|
558
|
+
0,
|
|
559
|
+
nullptr,
|
|
560
|
+
nullptr,
|
|
561
|
+
nullptr,
|
|
562
|
+
nullptr,
|
|
563
|
+
nullptr};
|
|
572
564
|
} // py::cpp::Windows::Devices::Adc
|
|
573
565
|
|
|
574
566
|
PyMODINIT_FUNC PyInit__winrt_windows_devices_adc(void) noexcept
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# WARNING: Please don't edit this file. It was automatically generated.
|
|
2
2
|
|
|
3
3
|
[build-system]
|
|
4
|
-
requires = ["setuptools", "
|
|
4
|
+
requires = ["setuptools", "winrt-sdk"]
|
|
5
5
|
build-backend = "setuptools.build_meta"
|
|
6
6
|
|
|
7
7
|
[project]
|
|
@@ -30,7 +30,7 @@ dependencies = { file = "requirements.txt" }
|
|
|
30
30
|
optional-dependencies.all = { file = "all-requirements.txt" }
|
|
31
31
|
|
|
32
32
|
[tool.setuptools.package-data]
|
|
33
|
-
|
|
33
|
+
"*" = ["*.pyi", "py.typed"]
|
|
34
34
|
|
|
35
35
|
[tool.cibuildwheel]
|
|
36
36
|
# use local winrt-sdk build dependency
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
2.1.0
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
# WARNING: Please don't edit this file. It was generated by Python/WinRT v2.
|
|
1
|
+
# WARNING: Please don't edit this file. It was generated by Python/WinRT v2.1.0
|
|
2
2
|
|
|
3
|
-
winrt-runtime==2.
|
|
3
|
+
winrt-runtime==2.1.0
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# WARNING: Please don't edit this file. It was automatically generated.
|
|
2
|
+
|
|
3
|
+
from setuptools import Extension, setup
|
|
4
|
+
from setuptools.command.build_ext import build_ext
|
|
5
|
+
from winrt_sdk import get_include_dirs
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
class build_ext_ex(build_ext):
|
|
9
|
+
def build_extension(self, ext):
|
|
10
|
+
if self.compiler.compiler_type == "msvc":
|
|
11
|
+
ext.extra_compile_args = ["/std:c++20", "/permissive-"]
|
|
12
|
+
elif self.compiler.compiler_type == "mingw32":
|
|
13
|
+
ext.extra_compile_args = ["-std=c++20", "-D_WIN32_WINNT=_WIN32_WINNT_WIN10"]
|
|
14
|
+
ext.extra_link_args = ["-loleaut32"]
|
|
15
|
+
else:
|
|
16
|
+
raise ValueError(f"Unsupported compiler: {self.compiler.compiler_type}")
|
|
17
|
+
|
|
18
|
+
build_ext.build_extension(self, ext)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
setup(
|
|
22
|
+
cmdclass = {'build_ext': build_ext_ex},
|
|
23
|
+
ext_modules=[
|
|
24
|
+
Extension(
|
|
25
|
+
"winrt._winrt_windows_devices_adc",
|
|
26
|
+
sources=["py.Windows.Devices.Adc.cpp"],
|
|
27
|
+
include_dirs=get_include_dirs(),
|
|
28
|
+
libraries=["windowsapp"],
|
|
29
|
+
)
|
|
30
|
+
],
|
|
31
|
+
)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
# WARNING: Please don't edit this file. It was generated by Python/WinRT v2.
|
|
1
|
+
# WARNING: Please don't edit this file. It was generated by Python/WinRT v2.1.0
|
|
2
2
|
|
|
3
3
|
import datetime
|
|
4
4
|
import sys
|
|
@@ -9,9 +9,9 @@ from builtins import property as _property
|
|
|
9
9
|
|
|
10
10
|
import winrt._winrt
|
|
11
11
|
import winrt.system
|
|
12
|
-
import winrt.windows.devices.adc.provider
|
|
13
|
-
import winrt.windows.foundation
|
|
14
|
-
import winrt.windows.foundation.collections
|
|
12
|
+
import winrt.windows.devices.adc.provider as windows_devices_adc_provider
|
|
13
|
+
import winrt.windows.foundation as windows_foundation
|
|
14
|
+
import winrt.windows.foundation.collections as windows_foundation_collections
|
|
15
15
|
|
|
16
16
|
from winrt.windows.devices.adc import AdcChannelMode
|
|
17
17
|
|
|
@@ -31,8 +31,8 @@ class AdcChannel(winrt.system.Object):
|
|
|
31
31
|
|
|
32
32
|
@typing.final
|
|
33
33
|
class AdcController_Static(type):
|
|
34
|
-
def get_controllers_async(cls, provider: typing.Optional[
|
|
35
|
-
def get_default_async(cls) ->
|
|
34
|
+
def get_controllers_async(cls, provider: typing.Optional[windows_devices_adc_provider.IAdcProvider], /) -> windows_foundation.IAsyncOperation[windows_foundation_collections.IVectorView[AdcController]]: ...
|
|
35
|
+
def get_default_async(cls) -> windows_foundation.IAsyncOperation[AdcController]: ...
|
|
36
36
|
|
|
37
37
|
@typing.final
|
|
38
38
|
class AdcController(winrt.system.Object, metaclass=AdcController_Static):
|
|
File without changes
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: winrt-Windows.Devices.Adc
|
|
3
|
-
Version: 2.0
|
|
3
|
+
Version: 2.1.0
|
|
4
4
|
Summary: Python projection of Windows Runtime (WinRT) APIs
|
|
5
5
|
License: MIT
|
|
6
6
|
Project-URL: Documentation, https://pywinrt.readthedocs.io
|
|
@@ -12,7 +12,11 @@ Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
|
12
12
|
Classifier: Intended Audience :: Developers
|
|
13
13
|
Requires-Python: <3.13,>=3.9
|
|
14
14
|
Description-Content-Type: text/markdown
|
|
15
|
+
Requires-Dist: winrt-runtime==2.1.0
|
|
15
16
|
Provides-Extra: all
|
|
17
|
+
Requires-Dist: winrt-Windows.Devices.Adc.Provider[all]==2.1.0; extra == "all"
|
|
18
|
+
Requires-Dist: winrt-Windows.Foundation[all]==2.1.0; extra == "all"
|
|
19
|
+
Requires-Dist: winrt-Windows.Foundation.Collections[all]==2.1.0; extra == "all"
|
|
16
20
|
|
|
17
21
|
<!-- warning: Please don't edit this file. It was automatically generated. -->
|
|
18
22
|
|
|
@@ -7,6 +7,7 @@ requirements.txt
|
|
|
7
7
|
setup.py
|
|
8
8
|
winrt/_winrt_windows_devices_adc.pyi
|
|
9
9
|
winrt/windows/devices/adc/__init__.py
|
|
10
|
+
winrt/windows/devices/adc/py.typed
|
|
10
11
|
winrt_Windows.Devices.Adc.egg-info/PKG-INFO
|
|
11
12
|
winrt_Windows.Devices.Adc.egg-info/SOURCES.txt
|
|
12
13
|
winrt_Windows.Devices.Adc.egg-info/dependency_links.txt
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
2.0.0-beta.2
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
# WARNING: Please don't edit this file. It was automatically generated.
|
|
2
|
-
|
|
3
|
-
from setuptools import Extension, setup
|
|
4
|
-
from winrt_sdk import get_include_dirs
|
|
5
|
-
|
|
6
|
-
setup(
|
|
7
|
-
ext_modules=[
|
|
8
|
-
Extension(
|
|
9
|
-
"winrt._winrt_windows_devices_adc",
|
|
10
|
-
sources=["py.Windows.Devices.Adc.cpp"],
|
|
11
|
-
include_dirs=get_include_dirs(),
|
|
12
|
-
extra_compile_args=["/std:c++20", "/permissive-"],
|
|
13
|
-
libraries=["windowsapp"],
|
|
14
|
-
)
|
|
15
|
-
],
|
|
16
|
-
)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|