// WARNING: Please don't edit this file. It was generated by C++/WinRT v2.0.240405.15 #pragma once #ifndef WINRT_Microsoft_Windows_BadgeNotifications_H #define WINRT_Microsoft_Windows_BadgeNotifications_H #include "winrt/base.h" static_assert(winrt::check_version(CPPWINRT_VERSION, "2.0.240405.15"), "Mismatched C++/WinRT headers."); #define CPPWINRT_VERSION "2.0.240405.15" #include "winrt/impl/Microsoft.Windows.BadgeNotifications.2.h" namespace winrt::impl { template auto consume_Microsoft_Windows_BadgeNotifications_IBadgeNotificationManager::SetBadgeAsCount(uint32_t notificationCount) const { check_hresult(WINRT_IMPL_SHIM(winrt::Microsoft::Windows::BadgeNotifications::IBadgeNotificationManager)->SetBadgeAsCount(notificationCount)); } template auto consume_Microsoft_Windows_BadgeNotifications_IBadgeNotificationManager::SetBadgeAsGlyph(winrt::Microsoft::Windows::BadgeNotifications::BadgeNotificationGlyph const& glyphValue) const { check_hresult(WINRT_IMPL_SHIM(winrt::Microsoft::Windows::BadgeNotifications::IBadgeNotificationManager)->SetBadgeAsGlyph(static_cast(glyphValue))); } template auto consume_Microsoft_Windows_BadgeNotifications_IBadgeNotificationManager::ClearBadge() const { check_hresult(WINRT_IMPL_SHIM(winrt::Microsoft::Windows::BadgeNotifications::IBadgeNotificationManager)->ClearBadge()); } template auto consume_Microsoft_Windows_BadgeNotifications_IBadgeNotificationManagerStatics::Current() const { void* value{}; check_hresult(WINRT_IMPL_SHIM(winrt::Microsoft::Windows::BadgeNotifications::IBadgeNotificationManagerStatics)->get_Current(&value)); return winrt::Microsoft::Windows::BadgeNotifications::BadgeNotificationManager{ value, take_ownership_from_abi }; } #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall SetBadgeAsCount(uint32_t notificationCount) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().SetBadgeAsCount(notificationCount); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall SetBadgeAsGlyph(int32_t glyphValue) noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().SetBadgeAsGlyph(*reinterpret_cast(&glyphValue)); return 0; } catch (...) { return to_hresult(); } int32_t __stdcall ClearBadge() noexcept final try { typename D::abi_guard guard(this->shim()); this->shim().ClearBadge(); return 0; } catch (...) { return to_hresult(); } }; #endif #ifndef WINRT_LEAN_AND_MEAN template struct produce : produce_base { int32_t __stdcall get_Current(void** value) noexcept final try { clear_abi(value); typename D::abi_guard guard(this->shim()); *value = detach_from(this->shim().Current()); return 0; } catch (...) { return to_hresult(); } }; #endif } WINRT_EXPORT namespace winrt::Microsoft::Windows::BadgeNotifications { inline auto BadgeNotificationManager::Current() { return impl::call_factory_cast([](IBadgeNotificationManagerStatics const& f) { return f.Current(); }); } } namespace std { #ifndef WINRT_LEAN_AND_MEAN template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; template<> struct hash : winrt::impl::hash_base {}; #endif #ifdef __cpp_lib_format #endif } #endif