Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update the win32 metadata to version 34.0.8 #2067

Merged
merged 6 commits into from Sep 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Binary file modified crates/libs/metadata/default/Windows.Win32.Interop.winmd
Binary file not shown.
Binary file modified crates/libs/metadata/default/Windows.Win32.winmd
Binary file not shown.
2 changes: 1 addition & 1 deletion crates/libs/metadata/default/readme.md
Expand Up @@ -4,7 +4,7 @@ dependent crate or workspace has an empty or non-existent `.windows/winmd` direc

## Windows.Win32.winmd
- Source: https://www.nuget.org/packages/Microsoft.Windows.SDK.Win32Metadata/
- Version: 33.0.18-preview
- Version: 34.0.8-preview

## Windows.winmd
- Source: https://www.nuget.org/packages/Microsoft.Windows.SDK.Contracts
Expand Down
@@ -1,7 +1,7 @@
#[cfg_attr(windows, link(name = "windows"))]
extern "system" {
#[doc = "*Required features: `\"Win32_Graphics_DirectWrite\"`*"]
pub fn DWriteCreateFactory(factorytype: DWRITE_FACTORY_TYPE, iid: *const ::windows_sys::core::GUID, factory: *mut ::windows_sys::core::IUnknown) -> ::windows_sys::core::HRESULT;
pub fn DWriteCreateFactory(factorytype: DWRITE_FACTORY_TYPE, iid: *const ::windows_sys::core::GUID, factory: *mut *mut ::core::ffi::c_void) -> ::windows_sys::core::HRESULT;
}
pub type IDWriteAsyncResult = *mut ::core::ffi::c_void;
pub type IDWriteBitmapRenderTarget = *mut ::core::ffi::c_void;
Expand Down
5 changes: 3 additions & 2 deletions crates/libs/sys/src/Windows/Win32/Networking/Ldap/mod.rs
Expand Up @@ -2,8 +2,9 @@
extern "cdecl" {
#[doc = "*Required features: `\"Win32_Networking_Ldap\"`*"]
pub fn LdapGetLastError() -> u32;
#[doc = "*Required features: `\"Win32_Networking_Ldap\"`*"]
pub fn LdapMapErrorToWin32(ldaperror: u32) -> u32;
#[doc = "*Required features: `\"Win32_Networking_Ldap\"`, `\"Win32_Foundation\"`*"]
#[cfg(feature = "Win32_Foundation")]
pub fn LdapMapErrorToWin32(ldaperror: LDAP_RETCODE) -> super::super::Foundation::WIN32_ERROR;
#[doc = "*Required features: `\"Win32_Networking_Ldap\"`*"]
pub fn LdapUTF8ToUnicode(lpsrcstr: ::windows_sys::core::PCSTR, cchsrc: i32, lpdeststr: ::windows_sys::core::PWSTR, cchdest: i32) -> i32;
#[doc = "*Required features: `\"Win32_Networking_Ldap\"`*"]
Expand Down
44 changes: 21 additions & 23 deletions crates/libs/sys/src/Windows/Win32/System/Wmi/mod.rs
Expand Up @@ -227,6 +227,10 @@ pub const WBEMS_DISPID_OBJECT_PUT: u32 = 4u32;
pub const WBEMS_DISPID_OBJECT_READY: u32 = 1u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEMS_DISPID_PROGRESS: u32 = 3u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_INFINITE: i32 = -1i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_NO_WAIT: i32 = 0i32;
pub const WMIExtension: ::windows_sys::core::GUID = ::windows_sys::core::GUID { data1: 4036451070, data2: 23679, data3: 4562, data4: [139, 116, 0, 16, 75, 42, 251, 65] };
pub const WbemAdministrativeLocator: ::windows_sys::core::GUID = ::windows_sys::core::GUID { data1: 3414513100, data2: 37160, data3: 4561, data4: [173, 155, 0, 192, 79, 216, 253, 255] };
pub const WbemAuthenticatedLocator: ::windows_sys::core::GUID = ::windows_sys::core::GUID { data1: 3440919350, data2: 37160, data3: 4561, data4: [173, 155, 0, 192, 79, 216, 253, 255] };
Expand Down Expand Up @@ -1087,39 +1091,39 @@ pub const WBEM_FLAVOR_AMENDED: WBEM_FLAVOR_TYPE = 128i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAVOR_MASK_AMENDED: WBEM_FLAVOR_TYPE = 128i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub type WBEM_GENERIC_FLAG_TYPE = i32;
pub type WBEM_GENERIC_FLAG_TYPE = u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_RETURN_IMMEDIATELY: WBEM_GENERIC_FLAG_TYPE = 16i32;
pub const WBEM_FLAG_RETURN_IMMEDIATELY: WBEM_GENERIC_FLAG_TYPE = 16u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_RETURN_WBEM_COMPLETE: WBEM_GENERIC_FLAG_TYPE = 0i32;
pub const WBEM_FLAG_RETURN_WBEM_COMPLETE: WBEM_GENERIC_FLAG_TYPE = 0u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_BIDIRECTIONAL: WBEM_GENERIC_FLAG_TYPE = 0i32;
pub const WBEM_FLAG_BIDIRECTIONAL: WBEM_GENERIC_FLAG_TYPE = 0u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_FORWARD_ONLY: WBEM_GENERIC_FLAG_TYPE = 32i32;
pub const WBEM_FLAG_FORWARD_ONLY: WBEM_GENERIC_FLAG_TYPE = 32u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_NO_ERROR_OBJECT: WBEM_GENERIC_FLAG_TYPE = 64i32;
pub const WBEM_FLAG_NO_ERROR_OBJECT: WBEM_GENERIC_FLAG_TYPE = 64u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_RETURN_ERROR_OBJECT: WBEM_GENERIC_FLAG_TYPE = 0i32;
pub const WBEM_FLAG_RETURN_ERROR_OBJECT: WBEM_GENERIC_FLAG_TYPE = 0u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_SEND_STATUS: WBEM_GENERIC_FLAG_TYPE = 128i32;
pub const WBEM_FLAG_SEND_STATUS: WBEM_GENERIC_FLAG_TYPE = 128u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_DONT_SEND_STATUS: WBEM_GENERIC_FLAG_TYPE = 0i32;
pub const WBEM_FLAG_DONT_SEND_STATUS: WBEM_GENERIC_FLAG_TYPE = 0u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_ENSURE_LOCATABLE: WBEM_GENERIC_FLAG_TYPE = 256i32;
pub const WBEM_FLAG_ENSURE_LOCATABLE: WBEM_GENERIC_FLAG_TYPE = 256u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_DIRECT_READ: WBEM_GENERIC_FLAG_TYPE = 512i32;
pub const WBEM_FLAG_DIRECT_READ: WBEM_GENERIC_FLAG_TYPE = 512u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_SEND_ONLY_SELECTED: WBEM_GENERIC_FLAG_TYPE = 0i32;
pub const WBEM_FLAG_SEND_ONLY_SELECTED: WBEM_GENERIC_FLAG_TYPE = 0u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_RETURN_WHEN_COMPLETE: WBEM_GENERIC_FLAG_TYPE = 0i32;
pub const WBEM_RETURN_WHEN_COMPLETE: WBEM_GENERIC_FLAG_TYPE = 0u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_RETURN_IMMEDIATELY: WBEM_GENERIC_FLAG_TYPE = 16i32;
pub const WBEM_RETURN_IMMEDIATELY: WBEM_GENERIC_FLAG_TYPE = 16u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_MASK_RESERVED_FLAGS: WBEM_GENERIC_FLAG_TYPE = 126976i32;
pub const WBEM_MASK_RESERVED_FLAGS: WBEM_GENERIC_FLAG_TYPE = 126976u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_USE_AMENDED_QUALIFIERS: WBEM_GENERIC_FLAG_TYPE = 131072i32;
pub const WBEM_FLAG_USE_AMENDED_QUALIFIERS: WBEM_GENERIC_FLAG_TYPE = 131072u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_STRONG_VALIDATION: WBEM_GENERIC_FLAG_TYPE = 1048576i32;
pub const WBEM_FLAG_STRONG_VALIDATION: WBEM_GENERIC_FLAG_TYPE = 1048576u32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub type WBEM_GENUS_TYPE = i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
Expand Down Expand Up @@ -1309,12 +1313,6 @@ pub type WBEM_TEXT_FLAG_TYPE = i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_NO_FLAVORS: WBEM_TEXT_FLAG_TYPE = 1i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub type WBEM_TIMEOUT_TYPE = i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_NO_WAIT: WBEM_TIMEOUT_TYPE = 0i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_INFINITE: WBEM_TIMEOUT_TYPE = -1i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub type WBEM_UNSECAPP_FLAG_TYPE = i32;
#[doc = "*Required features: `\"Win32_System_Wmi\"`*"]
pub const WBEM_FLAG_UNSECAPP_DEFAULT_CHECK_ACCESS: WBEM_UNSECAPP_FLAG_TYPE = 0i32;
Expand Down
@@ -1,12 +1,15 @@
#[doc = "*Required features: `\"Win32_Graphics_DirectWrite\"`*"]
#[inline]
pub unsafe fn DWriteCreateFactory(factorytype: DWRITE_FACTORY_TYPE, iid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> {
pub unsafe fn DWriteCreateFactory<T>(factorytype: DWRITE_FACTORY_TYPE) -> ::windows::core::Result<T>
where
T: ::windows::core::Interface,
{
#[cfg_attr(windows, link(name = "windows"))]
extern "system" {
fn DWriteCreateFactory(factorytype: DWRITE_FACTORY_TYPE, iid: *const ::windows::core::GUID, factory: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT;
}
let mut result__ = ::core::mem::MaybeUninit::zeroed();
DWriteCreateFactory(factorytype, ::core::mem::transmute(iid), ::core::mem::transmute(result__.as_mut_ptr())).from_abi::<::windows::core::IUnknown>(result__)
let mut result__ = ::core::option::Option::None;
DWriteCreateFactory(factorytype, &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__)
}
#[doc = "*Required features: `\"Win32_Graphics_DirectWrite\"`*"]
#[repr(transparent)]
Expand Down
7 changes: 4 additions & 3 deletions crates/libs/windows/src/Windows/Win32/Networking/Ldap/mod.rs
Expand Up @@ -7,12 +7,13 @@ pub unsafe fn LdapGetLastError() -> u32 {
}
LdapGetLastError()
}
#[doc = "*Required features: `\"Win32_Networking_Ldap\"`*"]
#[doc = "*Required features: `\"Win32_Networking_Ldap\"`, `\"Win32_Foundation\"`*"]
#[cfg(feature = "Win32_Foundation")]
#[inline]
pub unsafe fn LdapMapErrorToWin32(ldaperror: u32) -> u32 {
pub unsafe fn LdapMapErrorToWin32(ldaperror: LDAP_RETCODE) -> super::super::Foundation::WIN32_ERROR {
#[cfg_attr(windows, link(name = "windows"))]
extern "cdecl" {
fn LdapMapErrorToWin32(ldaperror: u32) -> u32;
fn LdapMapErrorToWin32(ldaperror: LDAP_RETCODE) -> super::super::Foundation::WIN32_ERROR;
}
LdapMapErrorToWin32(ldaperror)
}
Expand Down
28 changes: 0 additions & 28 deletions crates/libs/windows/src/Windows/Win32/System/Ole/mod.rs
Expand Up @@ -17617,34 +17617,6 @@ impl ::core::fmt::Debug for PICTYPE {
f.debug_tuple("PICTYPE").field(&self.0).finish()
}
}
impl ::core::ops::BitOr for PICTYPE {
type Output = Self;
fn bitor(self, other: Self) -> Self {
Self(self.0 | other.0)
}
}
impl ::core::ops::BitAnd for PICTYPE {
type Output = Self;
fn bitand(self, other: Self) -> Self {
Self(self.0 & other.0)
}
}
impl ::core::ops::BitOrAssign for PICTYPE {
fn bitor_assign(&mut self, other: Self) {
self.0.bitor_assign(other.0)
}
}
impl ::core::ops::BitAndAssign for PICTYPE {
fn bitand_assign(&mut self, other: Self) {
self.0.bitand_assign(other.0)
}
}
impl ::core::ops::Not for PICTYPE {
type Output = Self;
fn not(self) -> Self {
Self(self.0.not())
}
}
#[doc = "*Required features: `\"Win32_System_Ole\"`*"]
#[repr(transparent)]
#[derive(::core::cmp::PartialEq, ::core::cmp::Eq)]
Expand Down
4 changes: 2 additions & 2 deletions crates/libs/windows/src/Windows/Win32/System/Wmi/impl.rs
Expand Up @@ -4666,7 +4666,7 @@ pub trait IWbemServices_Impl: Sized {
fn DeleteInstanceAsync(&self, strobjectpath: &::windows::core::BSTR, lflags: i32, pctx: &::core::option::Option<IWbemContext>, presponsehandler: &::core::option::Option<IWbemObjectSink>) -> ::windows::core::Result<()>;
fn CreateInstanceEnum(&self, strfilter: &::windows::core::BSTR, lflags: i32, pctx: &::core::option::Option<IWbemContext>) -> ::windows::core::Result<IEnumWbemClassObject>;
fn CreateInstanceEnumAsync(&self, strfilter: &::windows::core::BSTR, lflags: i32, pctx: &::core::option::Option<IWbemContext>, presponsehandler: &::core::option::Option<IWbemObjectSink>) -> ::windows::core::Result<()>;
fn ExecQuery(&self, strquerylanguage: &::windows::core::BSTR, strquery: &::windows::core::BSTR, lflags: i32, pctx: &::core::option::Option<IWbemContext>) -> ::windows::core::Result<IEnumWbemClassObject>;
fn ExecQuery(&self, strquerylanguage: &::windows::core::BSTR, strquery: &::windows::core::BSTR, lflags: WBEM_GENERIC_FLAG_TYPE, pctx: &::core::option::Option<IWbemContext>) -> ::windows::core::Result<IEnumWbemClassObject>;
fn ExecQueryAsync(&self, strquerylanguage: &::windows::core::BSTR, strquery: &::windows::core::BSTR, lflags: i32, pctx: &::core::option::Option<IWbemContext>, presponsehandler: &::core::option::Option<IWbemObjectSink>) -> ::windows::core::Result<()>;
fn ExecNotificationQuery(&self, strquerylanguage: &::windows::core::BSTR, strquery: &::windows::core::BSTR, lflags: i32, pctx: &::core::option::Option<IWbemContext>) -> ::windows::core::Result<IEnumWbemClassObject>;
fn ExecNotificationQueryAsync(&self, strquerylanguage: &::windows::core::BSTR, strquery: &::windows::core::BSTR, lflags: i32, pctx: &::core::option::Option<IWbemContext>, presponsehandler: &::core::option::Option<IWbemObjectSink>) -> ::windows::core::Result<()>;
Expand Down Expand Up @@ -4779,7 +4779,7 @@ impl IWbemServices_Vtbl {
let this = (*this).get_impl();
this.CreateInstanceEnumAsync(::core::mem::transmute(&strfilter), ::core::mem::transmute_copy(&lflags), ::core::mem::transmute(&pctx), ::core::mem::transmute(&presponsehandler)).into()
}
unsafe extern "system" fn ExecQuery<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IWbemServices_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, strquerylanguage: ::core::mem::ManuallyDrop<::windows::core::BSTR>, strquery: ::core::mem::ManuallyDrop<::windows::core::BSTR>, lflags: i32, pctx: *mut ::core::ffi::c_void, ppenum: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
unsafe extern "system" fn ExecQuery<Identity: ::windows::core::IUnknownImpl<Impl = Impl>, Impl: IWbemServices_Impl, const OFFSET: isize>(this: *mut ::core::ffi::c_void, strquerylanguage: ::core::mem::ManuallyDrop<::windows::core::BSTR>, strquery: ::core::mem::ManuallyDrop<::windows::core::BSTR>, lflags: WBEM_GENERIC_FLAG_TYPE, pctx: *mut ::core::ffi::c_void, ppenum: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT {
let this = (this as *const *const ()).offset(OFFSET) as *const Identity;
let this = (*this).get_impl();
match this.ExecQuery(::core::mem::transmute(&strquerylanguage), ::core::mem::transmute(&strquery), ::core::mem::transmute_copy(&lflags), ::core::mem::transmute(&pctx)) {
Expand Down