diff --git a/Libraries/tdlib b/Libraries/tdlib index 0da5c72f83..8921c22f0f 160000 --- a/Libraries/tdlib +++ b/Libraries/tdlib @@ -1 +1 @@ -Subproject commit 0da5c72f8365fb4857096e716d53175ddbdf5a15 +Subproject commit 8921c22f0f85b3cb0b56303f9cba81ba8549f4e8 diff --git a/Libraries/tgcalls b/Libraries/tgcalls index c89f009c29..24876ebca7 160000 --- a/Libraries/tgcalls +++ b/Libraries/tgcalls @@ -1 +1 @@ -Subproject commit c89f009c29e7142f1935383a978f2ad7c46da4d1 +Subproject commit 24876ebca7da10f92dc972225734337f9e793054 diff --git a/Telegram.Generators/SchemaGenerator.cs b/Telegram.Generators/SchemaGenerator.cs index 58e14fcbf9..0b18e064e3 100644 --- a/Telegram.Generators/SchemaGenerator.cs +++ b/Telegram.Generators/SchemaGenerator.cs @@ -957,7 +957,7 @@ public bool Read() var temp = _index + 1; while (temp < _lines.Length && _lines[temp].StartsWith("//")) { - Value += " " + _lines[temp].Substring(2); + Value += " " + _lines[temp].Substring(2).TrimStart('-'); temp++; } diff --git a/Telegram.Msix/Package.appxmanifest b/Telegram.Msix/Package.appxmanifest index 5caf6f6c13..52ee94c59b 100644 --- a/Telegram.Msix/Package.appxmanifest +++ b/Telegram.Msix/Package.appxmanifest @@ -1,6 +1,6 @@  - + Unigram—Telegram for Windows diff --git a/Telegram.Native.Calls/PropertySheet.props b/Telegram.Native.Calls/PropertySheet.props index 6f01d65af7..c2b5c1f86f 100644 --- a/Telegram.Native.Calls/PropertySheet.props +++ b/Telegram.Native.Calls/PropertySheet.props @@ -5,12 +5,10 @@ - WEBRTC_DISABLE_H265;_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;NDEBUG;NVALGRIND;DYNAMIC_ANNOTATIONS_ENABLED=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;WEBRTC_VIDEO_CAPTURE_WINRT;%(PreprocessorDefinitions) - WEBRTC_DISABLE_H265;_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;_USING_V110_SDK71_;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;_DEBUG;DYNAMIC_ANNOTATIONS_ENABLED=1;_HAS_ITERATOR_DEBUGGING=0;WEBRTC_ENABLE_PROTOBUF=1;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;WEBRTC_VIDEO_CAPTURE_WINRT;GOOGLE_PROTOBUF_NO_RTTI;GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER;%(PreprocessorDefinitions) - WEBRTC_DISABLE_H265;_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;NDEBUG;NVALGRIND;DYNAMIC_ANNOTATIONS_ENABLED=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;WEBRTC_VIDEO_CAPTURE_WINRT;%(PreprocessorDefinitions) - WEBRTC_DISABLE_H265;_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;_USING_V110_SDK71_;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;_DEBUG;DYNAMIC_ANNOTATIONS_ENABLED=1;_HAS_ITERATOR_DEBUGGING=0;WEBRTC_ENABLE_PROTOBUF=1;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;WEBRTC_VIDEO_CAPTURE_WINRT;GOOGLE_PROTOBUF_NO_RTTI;GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER;%(PreprocessorDefinitions) - WEBRTC_DISABLE_H265;_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;_USING_V110_SDK71_;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;NDEBUG;NVALGRIND;DYNAMIC_ANNOTATIONS_ENABLED=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_ARCH_ARM64;WEBRTC_HAS_NEON;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;%(PreprocessorDefinitions) - WEBRTC_DISABLE_H265;_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;_USING_V110_SDK71_;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;_DEBUG;DYNAMIC_ANNOTATIONS_ENABLED=1;_HAS_ITERATOR_DEBUGGING=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_ARCH_ARM64;WEBRTC_HAS_NEON;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;%(PreprocessorDefinitions) + USE_AURA=1;_CRT_NONSTDC_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_NONE;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_NI;_WIN32_WINNT=0x0A00;WINVER=0x0A00;NDEBUG;NVALGRIND;DYNAMIC_ANNOTATIONS_ENABLED=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_STRICT_FIELD_TRIALS=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;WEBRTC_VIDEO_CAPTURE_WINRT;RTC_ENABLE_VP9;WEBRTC_HAVE_SCTP;RTC_DISABLE_METRICS;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;_ENABLE_EXTENDED_ALIGNED_STORAGE;LIBYUV_DISABLE_NEON;LIBYUV_DISABLE_LSX;LIBYUV_DISABLE_LASX;%(PreprocessorDefinitions) + USE_AURA=1;_CRT_NONSTDC_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_NONE;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_NI;_WIN32_WINNT=0x0A00;WINVER=0x0A00;_DEBUG;DYNAMIC_ANNOTATIONS_ENABLED=1;_HAS_ITERATOR_DEBUGGING=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_STRICT_FIELD_TRIALS=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;WEBRTC_VIDEO_CAPTURE_WINRT;RTC_ENABLE_VP9;WEBRTC_HAVE_SCTP;RTC_DISABLE_METRICS;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;_ENABLE_EXTENDED_ALIGNED_STORAGE;LIBYUV_DISABLE_NEON;LIBYUV_DISABLE_LSX;LIBYUV_DISABLE_LASX;%(PreprocessorDefinitions) + USE_AURA=1;_CRT_NONSTDC_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_NONE;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_NI;_WIN32_WINNT=0x0A00;WINVER=0x0A00;NDEBUG;NVALGRIND;DYNAMIC_ANNOTATIONS_ENABLED=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_STRICT_FIELD_TRIALS=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;WEBRTC_VIDEO_CAPTURE_WINRT;RTC_ENABLE_VP9;WEBRTC_HAVE_SCTP;RTC_DISABLE_METRICS;WEBRTC_ARCH_ARM64;WEBRTC_HAS_NEON;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;_ENABLE_EXTENDED_ALIGNED_STORAGE;LIBYUV_DISABLE_LSX;LIBYUV_DISABLE_LASX;%(PreprocessorDefinitions) + USE_AURA=1;_CRT_NONSTDC_NO_WARNINGS;_WINSOCK_DEPRECATED_NO_WARNINGS;_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_NONE;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_NI;_WIN32_WINNT=0x0A00;WINVER=0x0A00;_DEBUG;DYNAMIC_ANNOTATIONS_ENABLED=1;_HAS_ITERATOR_DEBUGGING=0;WEBRTC_ENABLE_PROTOBUF=0;WEBRTC_STRICT_FIELD_TRIALS=0;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;WEBRTC_VIDEO_CAPTURE_WINRT;RTC_ENABLE_VP9;WEBRTC_HAVE_SCTP;RTC_DISABLE_METRICS;WEBRTC_ARCH_ARM64;WEBRTC_HAS_NEON;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;_ENABLE_EXTENDED_ALIGNED_STORAGE;LIBYUV_DISABLE_LSX;LIBYUV_DISABLE_LASX;%(PreprocessorDefinitions) C:\webrtc\src;C:\webrtc\src\third_party\abseil-cpp;C:\webrtc\src\third_party\libyuv\include;%(AdditionalIncludeDirectories) diff --git a/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj b/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj index ef89b9ca0f..cb43b6c84c 100644 --- a/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj +++ b/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj @@ -27,12 +27,6 @@ true true - - - avcodec.lib;avformat.lib;avutil.lib;swscale.lib;%(AdditionalDependencies) - Mfplat.dll;MFReadWrite.dll;%(DelayLoadDLLs) - - @@ -63,8 +57,6 @@ DynamicLibrary v145 - v141 - v142 Unicode false @@ -84,23 +76,6 @@ - - - - - - - - - - - - - - - - - @@ -112,51 +87,20 @@ $(IntDir)pch.pch Level4 %(AdditionalOptions) /bigobj - - - /DWINRT_NO_MAKE_DETECTION %(AdditionalOptions) 4996 _WINRT_DLL;WIN32_LEAN_AND_MEAN;WINRT_LEAN_AND_MEAN;_SILENCE_CXX17_RESULT_OF_DEPRECATION_WARNING;_SILENCE_ALL_CXX20_DEPRECATION_WARNINGS;_USE_MATH_DEFINES;TGCALLS_UWP_DESKTOP;%(PreprocessorDefinitions) $(WindowsSDK_WindowsMetadata);$(AdditionalUsingDirectories) - .\rnnoise\include;..\Libraries\tgcalls\tgcalls;..\Libraries\tgcalls;C:\webrtc\src;C:\webrtc\src\third_party\abseil-cpp;C:\webrtc\src\third_party\libyuv\include;%(AdditionalIncludeDirectories) - .\rnnoise\include;..\Libraries\tgcalls\tgcalls;..\Libraries\tgcalls;C:\webrtc\src;C:\webrtc\src\third_party\abseil-cpp;C:\webrtc\src\third_party\libyuv\include;%(AdditionalIncludeDirectories) - false - false + .\rnnoise\include;..\Libraries\tgcalls\tgcalls;..\Libraries\tgcalls;C:\webrtc\src;C:\webrtc\src\third_party\abseil-cpp;C:\webrtc\src\third_party\libyuv\include;%(AdditionalIncludeDirectories) stdcpp20 stdc17 - Console false VoipManager.def - ole32.lib;oleaut32.lib;Kernel32.lib;mfreadwrite.lib;mfplat.lib;mfuuid.lib;%(AdditionalDependencies) - - - - - _DEBUG;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;_USING_V110_SDK71_;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;_DEBUG;DYNAMIC_ANNOTATIONS_ENABLED=1;_HAS_ITERATOR_DEBUGGING=0;WEBRTC_ENABLE_PROTOBUF=1;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_ARCH_ARM64;WEBRTC_HAS_NEON;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;GOOGLE_PROTOBUF_NO_RTTI;GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER;%(PreprocessorDefinitions) - $(WebRTC_Root);$(WebRTC_Output)\$(Platform)\$(Configuration)\gen;$(WebRTC_Root)\third_party\abseil-cpp;$(WebRTC_Root)\third_party\libyuv\include;$(WebRTC_Root)\third_party\protobuf\src;$(WebRTC_Output)\$(Platform)\$(Configuration)\gen\protoc_out;$(WebRTC_Root)\third_party\protobuf\src;%(AdditionalIncludeDirectories);.\rnnoise\include;..\Libraries\tgcalls\tgcalls;..\Libraries\tgcalls;%(AdditionalIncludeDirectories) - - - $(WebRTC_Output)\$(Platform)\$(Configuration)\obj;%(AdditionalLibraryDirectories) - - - - - NDEBUG;USE_AURA=1;_HAS_EXCEPTIONS=0;__STD_C;_CRT_RAND_S;_CRT_SECURE_NO_DEPRECATE;_SCL_SECURE_NO_DEPRECATE;_ATL_NO_OPENGL;_WINDOWS;CERT_CHAIN_PARA_HAS_EXTRA_FIELDS;PSAPI_VERSION=2;WIN32;_SECURE_ATL;_USING_V110_SDK71_;WINUWP;__WRL_NO_DEFAULT_LIB__;WINAPI_FAMILY=WINAPI_FAMILY_PC_APP;WIN10=_WIN32_WINNT_WIN10;WIN32_LEAN_AND_MEAN;NOMINMAX;_UNICODE;UNICODE;NTDDI_VERSION=NTDDI_WIN10_RS2;_WIN32_WINNT=0x0A00;WINVER=0x0A00;NDEBUG;NVALGRIND;DYNAMIC_ANNOTATIONS_ENABLED=0;WEBRTC_ENABLE_PROTOBUF=1;WEBRTC_INCLUDE_INTERNAL_AUDIO_DEVICE;RTC_ENABLE_VP9;HAVE_SCTP;WEBRTC_ARCH_ARM64;WEBRTC_HAS_NEON;WEBRTC_LIBRARY_IMPL;WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS=0;WEBRTC_WIN;ABSL_ALLOCATOR_NOTHROW=1;HAVE_SCTP;GOOGLE_PROTOBUF_NO_RTTI;GOOGLE_PROTOBUF_NO_STATIC_INITIALIZER;%(PreprocessorDefinitions) - $(WebRTC_Root);$(WebRTC_Output)\$(Platform)\$(Configuration)\gen;$(WebRTC_Root)\third_party\abseil-cpp;$(WebRTC_Root)\third_party\libyuv\include;$(WebRTC_Root)\third_party\protobuf\src;$(WebRTC_Output)\$(Platform)\$(Configuration)\gen\protoc_out;$(WebRTC_Root)\third_party\protobuf\src;%(AdditionalIncludeDirectories) - - - true - true - $(WebRTC_Output)\$(Platform)\$(Configuration)\obj;%(AdditionalLibraryDirectories) - %(AdditionalLibraryDirectories) - libcmt + avcodec.lib;avformat.lib;avutil.lib;swscale.lib;ole32.lib;oleaut32.lib;Kernel32.lib;mfreadwrite.lib;mfplat.lib;mfuuid.lib;%(AdditionalDependencies) + Mfplat.dll;MFReadWrite.dll;%(DelayLoadDLLs) - - .\rnnoise\include;..\Libraries\tgcalls\tgcalls;..\Libraries\tgcalls;%(AdditionalIncludeDirectories) - @@ -169,7 +113,6 @@ - @@ -180,7 +123,6 @@ - BroadcastTimeRequestedEventArgs.idl @@ -328,9 +270,6 @@ NotUsing - - NotUsing - NotUsing @@ -358,9 +297,6 @@ NotUsing - - NotUsing - NotUsing diff --git a/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj.filters b/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj.filters index fa0b1e9f08..a21542d4db 100644 --- a/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj.filters +++ b/Telegram.Native.Calls/Telegram.Native.Calls.vcxproj.filters @@ -177,15 +177,9 @@ - - tgcalls\v2 - tgcalls\v2 - - tgcalls\v2 - @@ -407,15 +401,9 @@ - - tgcalls\v2 - tgcalls\v2 - - tgcalls\v2 - diff --git a/Telegram.Native/GarbageCollectionMonitor.cpp b/Telegram.Native/GarbageCollectionMonitor.cpp new file mode 100644 index 0000000000..d77367e4d4 --- /dev/null +++ b/Telegram.Native/GarbageCollectionMonitor.cpp @@ -0,0 +1,352 @@ +#include "pch.h" +#include "GarbageCollectionMonitor.h" +#if __has_include("GarbageCollectionMonitor.g.cpp") +#include "GarbageCollectionMonitor.g.cpp" +#endif + +#include + +namespace winrt::Telegram::Native::implementation +{ + std::mutex GarbageCollectionMonitor::s_syncLock; + std::unordered_map GarbageCollectionMonitor::s_windowStates; + std::thread GarbageCollectionMonitor::s_monitorThread; + std::atomic GarbageCollectionMonitor::s_xamlCollectionRequested{ false }; + std::atomic GarbageCollectionMonitor::s_lastCollectionTicks{ 0 }; + std::atomic GarbageCollectionMonitor::s_requested{ 0 }; + std::atomic GarbageCollectionMonitor::s_count{ 0 }; + CollectCallback GarbageCollectionMonitor::s_collectCallback; + DispatcherQueue GarbageCollectionMonitor::s_dispatcher{ nullptr }; + + GarbageCollectionMonitor::TimeSpan GarbageCollectionMonitor::InactivityTimeout{ 2000 }; + GarbageCollectionMonitor::TimeSpan GarbageCollectionMonitor::DebounceDelay{ 500 }; + GarbageCollectionMonitor::TimeSpan GarbageCollectionMonitor::CheckIntervalActive{ 250 }; + GarbageCollectionMonitor::TimeSpan GarbageCollectionMonitor::CheckIntervalInactive{ 1000 }; + + void GarbageCollectionMonitor::Initialize(CollectCallback collectCallback, bool disableGcCollect, bool disablePressure) + { + if (s_collectCallback) + { + return; + } + + s_collectCallback = std::move(collectCallback); + s_dispatcher = DispatcherQueue::GetForCurrentThread(); + s_monitorThread = std::thread(MonitorThreadProc); + + auto mrt100 = GetModuleHandle(L"mrt100_app.dll"); + if (mrt100) + { + if (disableGcCollect) + { + s_RhCollect = reinterpret_cast(GetProcAddress(mrt100, "RhCollect")); + } + + if (disablePressure) + { + s_RhGetCurrentObjSize = reinterpret_cast(GetProcAddress(mrt100, "RhGetCurrentObjSize")); + } + + if (s_RhCollect || s_RhGetCurrentObjSize) + { + DetourTransactionBegin(); + DetourUpdateThread(GetCurrentThread()); + + if (s_RhGetCurrentObjSize) + { + DetourAttach(reinterpret_cast(&s_RhGetCurrentObjSize), GarbageCollectionMonitor::RhGetCurrentObjSize); + } + + if (s_RhCollect) + { + DetourAttach(reinterpret_cast(&s_RhCollect), GarbageCollectionMonitor::RhCollect); + } + + DetourTransactionCommit(); + + if (s_RhCollect) + { + s_suspending = Application::Current().Suspending(winrt::auto_revoke, &GarbageCollectionMonitor::OnSuspending); + s_resuming = Application::Current().Resuming(winrt::auto_revoke, &GarbageCollectionMonitor::OnResuming); + } + } + } + } + + void GarbageCollectionMonitor::MonitorThreadProc() + { + while (true) + { + // Determine check interval based on window activity + bool anyWindowActive = IsAnyWindowActive(); + TimeSpan checkInterval = anyWindowActive ? CheckIntervalActive : CheckIntervalInactive; + + std::this_thread::sleep_for(checkInterval); + + TryTriggerCollection(); + } + } + + void GarbageCollectionMonitor::StartMonitoring(CoreWindow const& window) + { + void* windowKey = winrt::get_abi(window); + WindowState* state = nullptr; + bool isNewWindow = false; + + { + std::lock_guard lock(s_syncLock); + auto it = s_windowStates.find(windowKey); + if (it != s_windowStates.end()) + { + // Already monitoring this window + return; + } + + auto [insertIt, inserted] = s_windowStates.emplace(windowKey, WindowState(window)); + state = &insertIt->second; + isNewWindow = inserted; + } + + if (isNewWindow && state) + { + state->ActivatedToken = window.Activated([state](CoreWindow const&, WindowActivatedEventArgs const& args) + { + state->IsWindowActive.store(args.WindowActivationState() != CoreWindowActivationState::Deactivated, + std::memory_order_relaxed); + }); + + state->ClosedToken = window.Closed([window](CoreWindow const&, CoreWindowEventArgs const&) + { + StopMonitoring(window); + }); + + state->IsWindowActive.store(true, std::memory_order_relaxed); + } + } + + void GarbageCollectionMonitor::StopMonitoring(CoreWindow const& window) + { + void* windowKey = winrt::get_abi(window); + WindowState state; + bool found = false; + + { + std::lock_guard lock(s_syncLock); + auto it = s_windowStates.find(windowKey); + if (it == s_windowStates.end()) + { + return; + } + + state = std::move(it->second); + s_windowStates.erase(it); + found = true; + } + + if (found && state.Window) + { + if (state.ActivatedToken) + { + state.Window.Activated(state.ActivatedToken); + } + if (state.ClosedToken) + { + state.Window.Closed(state.ClosedToken); + } + } + } + + void GarbageCollectionMonitor::DisconnectUnusedReferenceSources() + { + s_requested.fetch_add(1, std::memory_order_relaxed); + + auto usageLevel = MemoryManager::AppMemoryUsageLevel(); + if (usageLevel == AppMemoryUsageLevel::High || usageLevel == AppMemoryUsageLevel::OverLimit) + { + int64_t currentTicks = static_cast(GetTickCount64()); + s_lastCollectionTicks.store(currentTicks, std::memory_order_relaxed); + + int32_t count = s_count.fetch_add(1, std::memory_order_relaxed) + 1; + LOGGER_INFO(L"{}/{}", count, s_requested.load(std::memory_order_relaxed)); + + if (s_dispatcher) + { + s_dispatcher.TryEnqueue(Collect); + } + } + else + { + s_xamlCollectionRequested.store(true, std::memory_order_relaxed); + } + } + + bool GarbageCollectionMonitor::IsAnyWindowActive() + { + std::lock_guard lock(s_syncLock); + for (auto const& [key, state] : s_windowStates) + { + if (state.IsWindowActive.load(std::memory_order_relaxed)) + { + return true; + } + } + return false; + } + + void GarbageCollectionMonitor::TryTriggerCollection() + { + if (!s_xamlCollectionRequested.load(std::memory_order_relaxed)) + { + return; + } + + int64_t currentTicks = static_cast(GetTickCount64()); + int64_t lastCollectionTicks = s_lastCollectionTicks.load(std::memory_order_relaxed); + int64_t timeSinceLastCollection = currentTicks - lastCollectionTicks; + + if (timeSinceLastCollection < static_cast(DebounceDelay.count())) + { + return; + } + + bool anyWindowActive = IsAnyWindowActive(); + if (anyWindowActive) + { + uint32_t lastInputTime = NativeUtils::GetLastInputTime(); + uint32_t timeSinceInput = currentTicks >= lastInputTime + ? static_cast(currentTicks - lastInputTime) + : 0; // Handle wraparound conservatively + + if (timeSinceInput < static_cast(InactivityTimeout.count())) + { + return; // User is still active + } + } + else + { + if (timeSinceLastCollection < static_cast(InactivityTimeout.count())) + { + return; + } + } + + s_lastCollectionTicks.store(currentTicks, std::memory_order_relaxed); + s_xamlCollectionRequested.store(false, std::memory_order_relaxed); + + int32_t count = s_count.fetch_add(1, std::memory_order_relaxed) + 1; + LOGGER_INFO(L"{}/{}", count, s_requested.load(std::memory_order_relaxed)); + + if (s_dispatcher) + { + s_dispatcher.TryEnqueue(Collect); + } + } + + void GarbageCollectionMonitor::Collect() + { + if (s_collectCallback) + { + Detour(true); + try + { + s_collectCallback(); + } + catch (...) + { + // Swallow exceptions to prevent crashes + } + Detour(false); + } + } + + hstring GarbageCollectionMonitor::Debug() + { + bool xamlRequested = s_xamlCollectionRequested.load(std::memory_order_relaxed); + int32_t count = s_count.load(std::memory_order_relaxed); + int32_t requested = s_requested.load(std::memory_order_relaxed); + + return hstring(std::format(L" {}/{}{}", count, requested, xamlRequested ? L"*" : L"")); + } + + PFN_RhGetCurrentObjSize GarbageCollectionMonitor::s_RhGetCurrentObjSize; + PFN_RhCollect GarbageCollectionMonitor::s_RhCollect; + + Application::Suspending_revoker GarbageCollectionMonitor::s_suspending = {}; + Application::Resuming_revoker GarbageCollectionMonitor::s_resuming = {}; + + std::mutex GarbageCollectionMonitor::s_collectLock; + bool GarbageCollectionMonitor::s_collect = false; + bool GarbageCollectionMonitor::s_suspended = false; + + void GarbageCollectionMonitor::Detour(bool value) + { + std::lock_guard const guard(s_collectLock); + + if (value == s_collect || s_suspended || !s_RhCollect) + { + return; + } + + s_collect = value; + + auto mrt100 = GetModuleHandle(L"mrt100_app.dll"); + if (mrt100 && s_RhCollect) + { + DetourTransactionBegin(); + DetourUpdateThread(GetCurrentThread()); + + if (value) + { + DetourDetach(reinterpret_cast(&s_RhCollect), GarbageCollectionMonitor::RhCollect); + } + else + { + DetourAttach(reinterpret_cast(&s_RhCollect), GarbageCollectionMonitor::RhCollect); + } + + DetourTransactionCommit(); + } + } + + void GarbageCollectionMonitor::OnSuspending(winrt::Windows::Foundation::IInspectable const& sender, winrt::Windows::ApplicationModel::SuspendingEventArgs const& e) + { + std::lock_guard const guard(s_collectLock); + + if (s_suspended || !s_RhCollect) + { + return; + } + + s_suspended = true; + + auto mrt100 = GetModuleHandle(L"mrt100_app.dll"); + if (mrt100 && s_RhCollect) + { + DetourTransactionBegin(); + DetourUpdateThread(GetCurrentThread()); + DetourDetach(reinterpret_cast(&s_RhCollect), GarbageCollectionMonitor::RhCollect); + DetourTransactionCommit(); + } + } + + void GarbageCollectionMonitor::OnResuming(winrt::Windows::Foundation::IInspectable const& sender, winrt::Windows::Foundation::IInspectable const& e) + { + std::lock_guard const guard(s_collectLock); + + if (!s_suspended || !s_RhCollect) + { + return; + } + + s_suspended = false; + + auto mrt100 = GetModuleHandle(L"mrt100_app.dll"); + if (mrt100 && s_RhCollect) + { + DetourTransactionBegin(); + DetourUpdateThread(GetCurrentThread()); + DetourAttach(reinterpret_cast(&s_RhCollect), GarbageCollectionMonitor::RhCollect); + DetourTransactionCommit(); + } + } +} diff --git a/Telegram.Native/GarbageCollectionMonitor.h b/Telegram.Native/GarbageCollectionMonitor.h new file mode 100644 index 0000000000..0b4fdc63d4 --- /dev/null +++ b/Telegram.Native/GarbageCollectionMonitor.h @@ -0,0 +1,152 @@ +#pragma once + +#include "GarbageCollectionMonitor.g.h" + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +using PFN_RhGetCurrentObjSize = INT64(__fastcall*)(); +using PFN_RhCollect = void(__fastcall*)(int generation, int mode); + +using namespace winrt::Windows::UI::Xaml; +using namespace winrt::Windows::Foundation; +using namespace winrt::Windows::UI::Core; +using namespace winrt::Windows::System; + +template +inline void post_to_threadpool(Func&& func) +{ + auto* heapFunc = new std::decay_t(std::forward(func)); + + PTP_WORK work = CreateThreadpoolWork( + [](PTP_CALLBACK_INSTANCE, PVOID context, PTP_WORK) { + std::unique_ptr> funcPtr( + static_cast*>(context) + ); + (*funcPtr)(); + }, + heapFunc, + nullptr + ); + + SubmitThreadpoolWork(work); + CloseThreadpoolWork(work); +} + +namespace winrt::Telegram::Native::implementation +{ + struct GarbageCollectionMonitor : GarbageCollectionMonitorT + { + using TimeSpan = std::chrono::milliseconds; + static TimeSpan InactivityTimeout; + static TimeSpan DebounceDelay; + static TimeSpan CheckIntervalActive; + static TimeSpan CheckIntervalInactive; + + static void Initialize(CollectCallback collectCallback, bool disableGcCollect, bool disablePressure); + static void StartMonitoring(CoreWindow const& window); + static void StopMonitoring(CoreWindow const& window); + static void DisconnectUnusedReferenceSources(); + static hstring Debug(); + + private: + struct WindowState + { + CoreWindow Window{ nullptr }; + std::atomic IsWindowActive{ false }; + event_token ActivatedToken{}; + event_token ClosedToken{}; + + WindowState() = default; + explicit WindowState(CoreWindow const& window) + : Window(window), IsWindowActive(false) + { + } + + WindowState(WindowState&& other) noexcept + : Window(std::move(other.Window)) + , IsWindowActive(other.IsWindowActive.load(std::memory_order_relaxed)) + , ActivatedToken(other.ActivatedToken) + , ClosedToken(other.ClosedToken) + { + other.Window = nullptr; + other.ActivatedToken = {}; + other.ClosedToken = {}; + } + + WindowState& operator=(WindowState&& other) noexcept + { + if (this != &other) + { + Window = std::move(other.Window); + IsWindowActive.store(other.IsWindowActive.load(std::memory_order_relaxed), std::memory_order_relaxed); + ActivatedToken = other.ActivatedToken; + ClosedToken = other.ClosedToken; + + other.Window = nullptr; + other.ActivatedToken = {}; + other.ClosedToken = {}; + } + return *this; + } + + WindowState(const WindowState&) = delete; + WindowState& operator=(const WindowState&) = delete; + }; + + static void MonitorThreadProc(); + static bool IsAnyWindowActive(); + static void TryTriggerCollection(); + static void Collect(); + static void Detour(bool value); + + static std::mutex s_syncLock; + static std::unordered_map s_windowStates; + static std::thread s_monitorThread; + static std::atomic s_xamlCollectionRequested; + static std::atomic s_lastCollectionTicks; + static std::atomic s_requested; + static std::atomic s_count; + static CollectCallback s_collectCallback; + static DispatcherQueue s_dispatcher; + + static Application::Suspending_revoker s_suspending; + static Application::Resuming_revoker s_resuming; + + static PFN_RhGetCurrentObjSize s_RhGetCurrentObjSize; + static PFN_RhCollect s_RhCollect; + + static std::mutex s_collectLock; + static bool s_collect; + static bool s_suspended; + + static INT64 RhGetCurrentObjSize() + { + return 0x7FFFFFFFFFFFFFFF; + } + + static void RhCollect(int generation, int mode) + { + post_to_threadpool([&]() { DisconnectUnusedReferenceSources(); }); + } + + static void OnSuspending(winrt::Windows::Foundation::IInspectable const& sender, winrt::Windows::ApplicationModel::SuspendingEventArgs const& e); + static void OnResuming(winrt::Windows::Foundation::IInspectable const& sender, winrt::Windows::Foundation::IInspectable const& e); + }; +} + +namespace winrt::Telegram::Native::factory_implementation +{ + struct GarbageCollectionMonitor : GarbageCollectionMonitorT + { + }; +} diff --git a/Telegram.Native/GarbageCollectionMonitor.idl b/Telegram.Native/GarbageCollectionMonitor.idl new file mode 100644 index 0000000000..c413d82402 --- /dev/null +++ b/Telegram.Native/GarbageCollectionMonitor.idl @@ -0,0 +1,14 @@ +namespace Telegram.Native +{ + delegate void CollectCallback(); + + [default_interface] + runtimeclass GarbageCollectionMonitor + { + static void Initialize(CollectCallback collectCallback, Boolean disableGcCollect, Boolean disablePressure); + static void StartMonitoring(Windows.UI.Core.CoreWindow window); + static void StopMonitoring(Windows.UI.Core.CoreWindow window); + static void DisconnectUnusedReferenceSources(); + static String Debug(); + } +} diff --git a/Telegram.Native/NativeUtils.cpp b/Telegram.Native/NativeUtils.cpp index 89b59d9d72..ea1c59982f 100644 --- a/Telegram.Native/NativeUtils.cpp +++ b/Telegram.Native/NativeUtils.cpp @@ -29,13 +29,7 @@ using namespace winrt::Windows::Foundation::Collections; namespace winrt::Telegram::Native::implementation { FatalErrorCallback NativeUtils::Callback; - - PFN_RhGetCurrentObjSize NativeUtils::s_RhGetCurrentObjSize; - PFN_RhCollect NativeUtils::s_RhCollect; - - CollectCallback NativeUtils::s_collectCallback; - std::mutex NativeUtils::s_collectLock; - bool NativeUtils::s_collect = false; + LogCallback NativeUtils::s_logCallback; void NativeUtils::SetFatalErrorCallback(FatalErrorCallback callback) { @@ -54,77 +48,16 @@ namespace winrt::Telegram::Native::implementation } } - void NativeUtils::SetCollectCallback(CollectCallback callback, bool disableGcCollect, bool disablePressure) + void NativeUtils::SetLogCallback(LogCallback callback) { - std::lock_guard const guard(s_collectLock); - - if (s_collectCallback) - { - return; - } - - s_collectCallback = callback; - - auto mrt100 = GetModuleHandle(L"mrt100_app.dll"); - if (mrt100) - { - if (disableGcCollect) - { - s_RhCollect = reinterpret_cast(GetProcAddress(mrt100, "RhCollect")); - } - - if (disablePressure) - { - s_RhGetCurrentObjSize = reinterpret_cast(GetProcAddress(mrt100, "RhGetCurrentObjSize")); - } - - if (s_RhCollect || s_RhGetCurrentObjSize) - { - DetourTransactionBegin(); - DetourUpdateThread(GetCurrentThread()); - - if (s_RhGetCurrentObjSize) - { - DetourAttach(reinterpret_cast(&s_RhGetCurrentObjSize), NativeUtils::RhGetCurrentObjSize); - } - - if (s_RhCollect) - { - DetourAttach(reinterpret_cast(&s_RhCollect), NativeUtils::RhCollect); - } - - DetourTransactionCommit(); - } - } + s_logCallback = callback; } - void NativeUtils::Collect(bool value) + void NativeUtils::Log(int32_t level, hstring message, hstring member, hstring filePath, int32_t line) { - std::lock_guard const guard(s_collectLock); - - if (value == s_collect || !s_RhCollect) + if (s_logCallback) { - return; - } - - s_collect = value; - - auto mrt100 = GetModuleHandle(L"mrt100_app.dll"); - if (mrt100 && s_RhCollect) - { - DetourTransactionBegin(); - DetourUpdateThread(GetCurrentThread()); - - if (value) - { - DetourDetach(reinterpret_cast(&s_RhCollect), NativeUtils::RhCollect); - } - else - { - DetourAttach(reinterpret_cast(&s_RhCollect), NativeUtils::RhCollect); - } - - DetourTransactionCommit(); + s_logCallback(level, message, member, filePath, line); } } diff --git a/Telegram.Native/NativeUtils.h b/Telegram.Native/NativeUtils.h index 4f91a41bf7..b3c12d1a0f 100644 --- a/Telegram.Native/NativeUtils.h +++ b/Telegram.Native/NativeUtils.h @@ -15,10 +15,7 @@ #include typedef void (*td_log_message_callback_ptr)(int verbosity_level, const char* message); - using PFN_td_set_log_message_callback = WINUSERAPI void(WINAPI*)(int max_verbosity_level, td_log_message_callback_ptr callback); -using PFN_RhGetCurrentObjSize = WINUSERAPI INT64(WINAPI*)(); -using PFN_RhCollect = WINUSERAPI void(WINAPI*)(int generation, int mode); using namespace winrt::Windows::Foundation::Collections; using namespace winrt::Windows::UI::Text; @@ -26,26 +23,6 @@ using namespace winrt::Windows::UI::Xaml; using namespace winrt::Windows::UI::Xaml::Media; using namespace winrt::Windows::UI::Xaml::Core::Direct; -template -inline void post_to_threadpool(Func&& func) -{ - auto* heapFunc = new std::decay_t(std::forward(func)); - - PTP_WORK work = CreateThreadpoolWork( - [](PTP_CALLBACK_INSTANCE, PVOID context, PTP_WORK) { - std::unique_ptr> funcPtr( - static_cast*>(context) - ); - (*funcPtr)(); - }, - heapFunc, - nullptr - ); - - SubmitThreadpoolWork(work); - CloseThreadpoolWork(work); -} - namespace winrt::Telegram::Native::implementation { struct NativeUtils : NativeUtilsT @@ -88,28 +65,18 @@ namespace winrt::Telegram::Native::implementation static int32_t GetScaleForCurrentView(); static void SetFatalErrorCallback(FatalErrorCallback action); - static void SetCollectCallback(CollectCallback action, bool disableGcCollect, bool disablePressure); + static void SetLogCallback(LogCallback action); static void LogMessageCallback(int verbosity_level, const char* message); static winrt::Telegram::Native::FatalError GetStowedException(); static winrt::Telegram::Native::FatalError GetBackTrace(hstring type, hstring message); + static void Log(int32_t level, hstring message, hstring member, hstring filePath, int32_t line); + static hstring GetLogMessage(int64_t format, int64_t args); static void Crash(); - static bool Collect() - { - std::lock_guard const guard(s_collectLock); - return s_collect; - } - - static void Collect(bool value); - static FatalErrorCallback Callback; - static CollectCallback s_collectCallback; - - static PFN_RhGetCurrentObjSize s_RhGetCurrentObjSize; - static PFN_RhCollect s_RhCollect; private: static winrt::Telegram::Native::FatalError GetStowedException2(STOWED_EXCEPTION_INFORMATION_V2* stowed); @@ -120,25 +87,7 @@ namespace winrt::Telegram::Native::implementation static ULONGLONG FileTimeToSeconds(FILETIME& ft); static bool IsFileReadableInternal(hstring path, int64_t* fileSize, int64_t* fileTime); - static std::mutex s_collectLock; - static bool s_collect; - - static INT64 RhGetCurrentObjSize() - { - return 0x7FFFFFFFFFFFFFFF; - } - - static void RhCollect(int generation, int mode) - { - if ((generation == 2 && mode == 6)) - { - s_RhCollect(generation, mode); - } - else - { - post_to_threadpool([&]() { s_collectCallback(generation, mode); }); - } - } + static LogCallback s_logCallback; }; } // namespace winrt::Telegram::Native::implementation diff --git a/Telegram.Native/NativeUtils.idl b/Telegram.Native/NativeUtils.idl index 5b0d7b9f40..ec208e5f2e 100644 --- a/Telegram.Native/NativeUtils.idl +++ b/Telegram.Native/NativeUtils.idl @@ -5,6 +5,8 @@ namespace Telegram.Native delegate void FatalErrorCallback(FatalError error); delegate void CollectCallback(Int32 generation, Int32 mode); + delegate void LogCallback(Int32 level, String message, String member, String filePath, Int32 line); + enum TextDirectionality { Neutral, @@ -72,7 +74,8 @@ namespace Telegram.Native static Int32 GetScaleForCurrentView(); static void SetFatalErrorCallback(FatalErrorCallback action); - static void SetCollectCallback(CollectCallback action, Boolean disableGcCollect, Boolean disablePressure); + static void SetLogCallback(LogCallback callback); + static void Log(Int32 level, String message, String member, String filePath, Int32 line); static FatalError GetStowedException(); static FatalError GetBackTrace(String type, String message); @@ -80,6 +83,5 @@ namespace Telegram.Native static String GetLogMessage(Int64 format, Int64 args); static void Crash(); - static Boolean Collect; } } // namespace Telegram.Native diff --git a/Telegram.Native/PlaceholderImageHelper.cpp b/Telegram.Native/PlaceholderImageHelper.cpp index 63a6c3206b..8a9de66a04 100644 --- a/Telegram.Native/PlaceholderImageHelper.cpp +++ b/Telegram.Native/PlaceholderImageHelper.cpp @@ -1150,6 +1150,7 @@ namespace winrt::Telegram::Native::implementation )); ReturnDefaultIfFailed(result, textFormat->SetTextAlignment(DWRITE_TEXT_ALIGNMENT_LEADING)); ReturnDefaultIfFailed(result, textFormat->SetParagraphAlignment(DWRITE_PARAGRAPH_ALIGNMENT_NEAR)); + ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(DWRITE_WORD_WRAPPING_EMERGENCY_BREAK)); winrt::com_ptr textLayout; ReturnDefaultIfFailed(result, m_dwriteFactory->CreateTextLayout( @@ -1231,11 +1232,11 @@ namespace winrt::Telegram::Native::implementation ReturnDefaultIfFailed(result, textFormat->SetTextAlignment(DWRITE_TEXT_ALIGNMENT_LEADING)); ReturnDefaultIfFailed(result, textFormat->SetParagraphAlignment(DWRITE_PARAGRAPH_ALIGNMENT_NEAR)); ReturnDefaultIfFailed(result, textFormat->SetReadingDirection(rtl ? DWRITE_READING_DIRECTION_RIGHT_TO_LEFT : DWRITE_READING_DIRECTION_LEFT_TO_RIGHT)); - ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(wrap ? DWRITE_WORD_WRAPPING_WRAP : DWRITE_WORD_WRAPPING_NO_WRAP)); + ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(wrap ? DWRITE_WORD_WRAPPING_EMERGENCY_BREAK : DWRITE_WORD_WRAPPING_NO_WRAP)); if (wrap) { - ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(DWRITE_WORD_WRAPPING_WRAP)); + ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(DWRITE_WORD_WRAPPING_EMERGENCY_BREAK)); } else { @@ -1347,7 +1348,7 @@ namespace winrt::Telegram::Native::implementation ReturnDefaultIfFailed(result, textFormat->SetTextAlignment(DWRITE_TEXT_ALIGNMENT_LEADING)); ReturnDefaultIfFailed(result, textFormat->SetParagraphAlignment(DWRITE_PARAGRAPH_ALIGNMENT_NEAR)); ReturnDefaultIfFailed(result, textFormat->SetReadingDirection(rtl ? DWRITE_READING_DIRECTION_RIGHT_TO_LEFT : DWRITE_READING_DIRECTION_LEFT_TO_RIGHT)); - //ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(wrap ? DWRITE_WORD_WRAPPING_WRAP : DWRITE_WORD_WRAPPING_NO_WRAP)); + ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(DWRITE_WORD_WRAPPING_EMERGENCY_BREAK)); winrt::com_ptr textLayout; ReturnDefaultIfFailed(result, m_dwriteFactory->CreateTextLayout( @@ -1419,6 +1420,7 @@ namespace winrt::Telegram::Native::implementation ReturnDefaultIfFailed(result, textFormat->SetTextAlignment(DWRITE_TEXT_ALIGNMENT_LEADING)); ReturnDefaultIfFailed(result, textFormat->SetParagraphAlignment(DWRITE_PARAGRAPH_ALIGNMENT_NEAR)); ReturnDefaultIfFailed(result, textFormat->SetReadingDirection(rtl ? DWRITE_READING_DIRECTION_RIGHT_TO_LEFT : DWRITE_READING_DIRECTION_LEFT_TO_RIGHT)); + ReturnDefaultIfFailed(result, textFormat->SetWordWrapping(DWRITE_WORD_WRAPPING_EMERGENCY_BREAK)); winrt::com_ptr textLayout; ReturnDefaultIfFailed(result, m_dwriteFactory->CreateTextLayout( diff --git a/Telegram.Native/Telegram.Native.vcxproj b/Telegram.Native/Telegram.Native.vcxproj index 9b0b755ded..50f48b5569 100644 --- a/Telegram.Native/Telegram.Native.vcxproj +++ b/Telegram.Native/Telegram.Native.vcxproj @@ -355,6 +355,10 @@ FreeformGradientSurface.idl Code + + GarbageCollectionMonitor.idl + Code + @@ -1033,6 +1037,10 @@ FreeformGradientSurface.idl Code + + GarbageCollectionMonitor.idl + Code + @@ -1192,6 +1200,9 @@ Designer + + Designer + diff --git a/Telegram.Native/Telegram.Native.vcxproj.filters b/Telegram.Native/Telegram.Native.vcxproj.filters index 4cb5e41a3f..4a5bbc35c8 100644 --- a/Telegram.Native/Telegram.Native.vcxproj.filters +++ b/Telegram.Native/Telegram.Native.vcxproj.filters @@ -1192,5 +1192,6 @@ Controls + \ No newline at end of file diff --git a/Telegram.Native/VideoAnimation.cpp b/Telegram.Native/VideoAnimation.cpp index e8bfadb0b8..7bd377cb42 100644 --- a/Telegram.Native/VideoAnimation.cpp +++ b/Telegram.Native/VideoAnimation.cpp @@ -301,18 +301,21 @@ namespace winrt::Telegram::Native::implementation info->pixelHeight = info->video_dec_ctx->height; info->rotation = get_stream_rotation(info->video_stream); - double framerate = 0.0; - if (info->video_stream->avg_frame_rate.num && - info->video_stream->avg_frame_rate.den) + auto framerate = 30.0; + + AVStream* video_stream = info->video_stream; + if (video_stream->avg_frame_rate.den && video_stream->avg_frame_rate.num) { - framerate = av_q2d(info->video_stream->avg_frame_rate); + framerate = av_q2d(video_stream->avg_frame_rate); } - else if (info->video_stream->r_frame_rate.num && - info->video_stream->r_frame_rate.den) + else if (video_stream->r_frame_rate.den && video_stream->r_frame_rate.num) { - framerate = av_q2d(info->video_stream->r_frame_rate); + framerate = av_q2d(video_stream->r_frame_rate); } + //auto guess = av_guess_frame_rate(info->fmt_ctx, info->video_stream, NULL); + //auto framerate = av_q2d(guess); + info->dropper = FrameDropper(framerate, limitFps ? 30.0 : 60.0); info->framerate = info->dropper.frame_rate(); } diff --git a/Telegram.Native/VideoAnimation.h b/Telegram.Native/VideoAnimation.h index 782374612b..08fe7a5e7e 100644 --- a/Telegram.Native/VideoAnimation.h +++ b/Telegram.Native/VideoAnimation.h @@ -93,18 +93,20 @@ namespace winrt::Telegram::Native::implementation bool should_display_frame() { + if (source_fps <= target_fps) + { + return true; + } + + frame_count++; + if (use_clean_division) { - // Clean modulo-based dropping - frame_count++; return (frame_count % preferred_divisor) == 0; } else { - // Fractional dropping for better frame rate - frame_count++; int64_t expected = (frame_count * target_fps) / source_fps; - if (frames_displayed < expected) { frames_displayed++; diff --git a/Telegram.Native/pch.h b/Telegram.Native/pch.h index ef936868d1..18eea86fbf 100644 --- a/Telegram.Native/pch.h +++ b/Telegram.Native/pch.h @@ -27,4 +27,15 @@ #define DebugMessage(x) #else #define DebugMessage(x) OutputDebugString(x) -#endif \ No newline at end of file +#endif + +#define LOGGER_ASSERT(...) \ + NativeUtils::Log(0, hstring(std::format(__VA_ARGS__)), winrt::to_hstring(std::string(__FUNCTION__)), winrt::to_hstring(__FILE__), __LINE__) +#define LOGGER_DEBUG(...) \ + NativeUtils::Log(4, hstring(std::format(__VA_ARGS__)), winrt::to_hstring(std::string(__FUNCTION__)), winrt::to_hstring(__FILE__), __LINE__) +#define LOGGER_WARNING(...) \ + NativeUtils::Log(2, hstring(std::format(__VA_ARGS__)), winrt::to_hstring(std::string(__FUNCTION__)), winrt::to_hstring(__FILE__), __LINE__) +#define LOGGER_ERROR(...) \ + NativeUtils::Log(1, hstring(std::format(__VA_ARGS__)), winrt::to_hstring(std::string(__FUNCTION__)), winrt::to_hstring(__FILE__), __LINE__) +#define LOGGER_INFO(...) \ + NativeUtils::Log(3, hstring(std::format(__VA_ARGS__)), winrt::to_hstring(std::string(__FUNCTION__)), winrt::to_hstring(__FILE__), __LINE__) diff --git a/Telegram/App.xaml.cs b/Telegram/App.xaml.cs index 7ef278fdcb..bf7591eaac 100644 --- a/Telegram/App.xaml.cs +++ b/Telegram/App.xaml.cs @@ -8,6 +8,7 @@ using System; using System.Threading.Tasks; using Telegram.Common; +using Telegram.Native; using Telegram.Navigation; using Telegram.Navigation.Services; using Telegram.Services; @@ -71,6 +72,7 @@ public App() TypeCrosserGenerator.Generate(); SettingsService.Current.Initialize(); + GarbageCollectionMonitor.Initialize(GC.Collect, SettingsService.Current.Diagnostics.DisableXamlGcCollect, SettingsService.Current.Diagnostics.DisableMemoryPressure); WatchDog.Initialize(); LifetimeService.Initialize(); @@ -177,7 +179,7 @@ public override async void OnStart(StartKind startKind, IActivatedEventArgs args { WindowContext.Current.Activate(args, navigation, state); - _ = Task.Run(() => OnStartSync(startKind, navigation, update)); + _ = Task.Run(() => OnStartSync(startKind, update)); if (startKind != StartKind.Launch && WindowContext.Current.IsInMainView) { @@ -238,7 +240,7 @@ protected override INavigationService CreateNavigationService(ISession session, return new TLNavigationService(session, window, frame, id); } - private async void OnStartSync(StartKind startKind, INavigationService navigation, ICloudUpdateService updateService = null) + private async void OnStartSync(StartKind startKind, ICloudUpdateService updateService = null) { await RequestExtendedExecutionSessionAsync(); await Toast.RegisterBackgroundTasks(); @@ -257,7 +259,7 @@ private async void OnStartSync(StartKind startKind, INavigationService navigatio if (Constants.RELEASE && startKind == StartKind.Launch) { - if (await CloudUpdateService.LaunchAsync(navigation, true)) + if (await CloudUpdateService.LaunchAsync(true)) { return; } @@ -330,7 +332,7 @@ public override void OnResuming(object s, object e, AppExecutionState previousEx // #2034: Will this work? No one knows. SettingsService.Current.Appearance.UpdateNightMode(null); - OnStartSync(StartKind.Activate, WindowContext.Current.GetNavigationService()); + OnStartSync(StartKind.Activate); } public override Task OnSuspendingAsync(object s, SuspendingEventArgs e) @@ -362,16 +364,16 @@ public override ViewModelBase ViewModelForPage(UIElement page, ISession session) UserAffiliatePage => session.Resolve(), // SupergroupChooseMemberPopup => session.Resolve(), - SupergroupAdministratorsPage supergroupAdministrators => session.Resolve(supergroupAdministrators), - SupergroupBannedPage supergroupBanned => session.Resolve(supergroupBanned), + SupergroupAdministratorsPage supergroupAdministrators => session.Resolve(supergroupAdministrators), + SupergroupBannedPage supergroupBanned => session.Resolve(supergroupBanned), SupergroupEditAdministratorPopup supergroupEditAdministrator => session.Resolve(supergroupEditAdministrator), SupergroupEditLinkedChatPage supergroupEditLinkedChat => session.Resolve(supergroupEditLinkedChat), SupergroupEditRestrictedPopup supergroupEditRestricted => session.Resolve(supergroupEditRestricted), SupergroupEditStickerSetPopup => session.Resolve(), SupergroupEditTypePage supergroupEditType => session.Resolve(supergroupEditType), SupergroupEditPage supergroupEdit => session.Resolve(supergroupEdit), - SupergroupMembersPage supergroupMembers => session.Resolve(supergroupMembers), - SupergroupPermissionsPage supergroupPermissions => session.Resolve(supergroupPermissions), + SupergroupMembersPage supergroupMembers => session.Resolve(supergroupMembers), + SupergroupPermissionsPage supergroupPermissions => session.Resolve(supergroupPermissions), SupergroupTopicsPage => session.Resolve(), SupergroupDirectMessagesPage => session.Resolve(), SupergroupReactionsPopup => session.Resolve(), diff --git a/Telegram/Assets/Animations/DisableSharing.tgs b/Telegram/Assets/Animations/DisableSharing.tgs new file mode 100644 index 0000000000..70ace96393 Binary files /dev/null and b/Telegram/Assets/Animations/DisableSharing.tgs differ diff --git a/Telegram/Assets/Animations/GiftCrafting.tgs b/Telegram/Assets/Animations/GiftCrafting.tgs new file mode 100644 index 0000000000..7bcdbda3b2 Binary files /dev/null and b/Telegram/Assets/Animations/GiftCrafting.tgs differ diff --git a/Telegram/Assets/Animations/GiftCraftingFailed.tgs b/Telegram/Assets/Animations/GiftCraftingFailed.tgs new file mode 100644 index 0000000000..a64ab0a7ff Binary files /dev/null and b/Telegram/Assets/Animations/GiftCraftingFailed.tgs differ diff --git a/Telegram/Assets/Fonts/Telegram.json b/Telegram/Assets/Fonts/Telegram.json index 23c05df8ab..07dd08708a 100644 --- a/Telegram/Assets/Fonts/Telegram.json +++ b/Telegram/Assets/Fonts/Telegram.json @@ -2,9 +2,49 @@ "metadata": { "name": "Telegram", "lastOpened": 0, - "created": 1765801099959 + "created": 1775735043932 }, "iconSets": [ + { + "selection": [ + { + "order": 1019, + "id": 0, + "name": "anvil_50", + "prevSize": 32, + "code": 60152, + "tempChar": "" + } + ], + "id": 14, + "metadata": { + "name": "Special", + "importSize": { + "width": 50, + "height": 50 + } + }, + "height": 1024, + "prevSize": 32, + "icons": [ + { + "id": 0, + "paths": [ + "M368.556 628.701v-131.156c0-8.837-7.162-15.999-15.999-15.999h-271.104c-8.837-0.002-16.003 7.16-16.003 15.995 0 3.602 1.214 7.098 3.447 9.925 33.969 42.945 71.26 75.117 111.879 96.514 42.246 22.254 95.289 37.36 159.127 45.314l4.809 0.582c11.7 1.389 22.311-6.971 23.697-18.672l0.111-1.249 0.037-1.253zM413.796 481.546h423.377c8.837 0 16.001 7.162 16.001 15.999v38.369c0.004 8.249-6.265 15.149-14.475 15.935-38.146 3.68-70.601 15.538-97.364 35.57-45.13 33.782-59.759 62.235-60.652 112.808-0.543 30.822 13.957 60.5 43.502 89.033l2.032 1.95c4.27 4.030 6.689 9.642 6.689 15.514v42.697c0 11.782-9.552 21.334-21.332 21.334h-292.444c-11.782 0-21.332-9.552-21.332-21.334v-38.713c0-7.764 4.221-14.914 11.016-18.668 24.383-13.455 36.577-34.251 36.577-62.398 0-28.897-12.855-49.578-38.564-62.040-5.519-2.658-9.021-8.241-9.030-14.365v-155.691c0-8.837 7.162-15.999 15.999-15.999zM382.31 308.507l-8.573-35.77c-2.746-11.457 4.315-22.97 15.774-25.717l0.854-0.186 400.087-78.718c21.076-4.147 41.679 9.041 46.739 29.917 4.813 19.859-7.385 39.857-27.242 44.672l-0.678 0.156-401.973 81.58c-10.91 2.214-21.619-4.327-24.713-14.899l-0.274-1.034zM270.338 435.874l69.919-17.707c19.677-4.987 31.764-24.779 27.214-44.56l-22.563-98.040c-2.341-10.177-6.531-19.835-12.362-28.496l-3.353-4.946c-40.489-59.272-69.812-86.417-87.982-81.426-18.549 5.095-31.791 44.601-39.728 118.515l-0.32 3.017c-0.978 9.394-0.389 18.889 1.744 28.090l22.631 97.614c4.657 20.087 24.713 32.596 44.8 27.939z" + ], + "attrs": [], + "isMulticolor": false, + "isMulticolor2": false, + "grid": 0, + "tags": [ + "anvil_50" + ], + "colorPermutations": {} + } + ], + "invisible": false, + "colorThemes": [] + }, { "selection": [ { @@ -13,7 +53,7 @@ "name": "ic_fluent_chat_add_32_filled", "prevSize": 32, "code": 60135, - "tempChar": "" + "tempChar": "" } ], "id": 13, @@ -54,7 +94,7 @@ "name": "tl_fluent_rewind_5_24_regular", "prevSize": 32, "code": 59953, - "tempChar": "" + "tempChar": "" }, { "order": 791, @@ -62,7 +102,7 @@ "name": "tl_fluent_rewind_25_24_regular", "prevSize": 32, "code": 59954, - "tempChar": "" + "tempChar": "" } ], "id": 12, @@ -124,7 +164,7 @@ "name": "tl_fluent_fragment_14_regular", "prevSize": 32, "code": 60030, - "tempChar": "" + "tempChar": "" }, { "order": 714, @@ -132,7 +172,7 @@ "name": "LockClosedFilled14px", "prevSize": 32, "code": 59916, - "tempChar": "" + "tempChar": "" } ], "id": 11, @@ -183,12 +223,12 @@ { "selection": [ { - "order": 0, + "order": 1025, "id": 16, "name": "ic_fluent_checkmark_12_filled", "prevSize": 32, - "code": 60111, - "tempChar": "" + "code": 60159, + "tempChar": "" }, { "order": 961, @@ -196,7 +236,7 @@ "name": "tl_fluent_add_square_12_filled", "prevSize": 32, "code": 60097, - "tempChar": "" + "tempChar": "" }, { "order": 960, @@ -204,7 +244,7 @@ "name": "template_12pt", "prevSize": 32, "code": 60096, - "tempChar": "" + "tempChar": "" }, { "order": 951, @@ -212,7 +252,7 @@ "name": "ic_fluent_chevron_right_12_filled", "prevSize": 32, "code": 60089, - "tempChar": "" + "tempChar": "" }, { "order": 861, @@ -220,7 +260,7 @@ "name": "tl_fluent_boosted_12_regular", "prevSize": 32, "code": 60010, - "tempChar": "" + "tempChar": "" }, { "order": 862, @@ -228,7 +268,7 @@ "name": "tl_fluent_boosted_2_12_regular", "prevSize": 32, "code": 60011, - "tempChar": "" + "tempChar": "" }, { "order": 848, @@ -236,7 +276,7 @@ "name": "ic_fluent_lock_closed_12_filled", "prevSize": 32, "code": 59869, - "tempChar": "" + "tempChar": "" }, { "order": 840, @@ -244,7 +284,7 @@ "name": "ic_fluent_eye_12_regular", "prevSize": 32, "code": 63373, - "tempChar": "" + "tempChar": "" }, { "order": 839, @@ -252,7 +292,7 @@ "name": "ic_fluent_dismiss_12_regular", "prevSize": 32, "code": 59540, - "tempChar": "" + "tempChar": "" }, { "order": 795, @@ -260,7 +300,7 @@ "name": "ic_fluent_arrow_clockwise_12_filled", "prevSize": 32, "code": 59957, - "tempChar": "" + "tempChar": "" }, { "order": 794, @@ -268,7 +308,7 @@ "name": "ic_fluent_play_12_filled", "prevSize": 32, "code": 59958, - "tempChar": "" + "tempChar": "" }, { "order": 761, @@ -276,7 +316,7 @@ "name": "tl_fluent_expired_12_regular", "prevSize": 32, "code": 59877, - "tempChar": "" + "tempChar": "" }, { "order": 709, @@ -284,7 +324,7 @@ "name": "Clock12px", "prevSize": 32, "code": 59910, - "tempChar": "" + "tempChar": "" }, { "order": 708, @@ -292,7 +332,7 @@ "name": "State12px", "prevSize": 32, "code": 59911, - "tempChar": "" + "tempChar": "" }, { "order": 705, @@ -300,7 +340,7 @@ "name": "Reply12px", "prevSize": 32, "code": 59906, - "tempChar": "" + "tempChar": "" }, { "order": 706, @@ -308,7 +348,7 @@ "name": "ic_fluent_eye_12_filled", "prevSize": 32, "code": 59907, - "tempChar": "" + "tempChar": "" }, { "order": 707, @@ -316,7 +356,7 @@ "name": "ic_fluent_pin_12_filled", "prevSize": 32, "code": 59909, - "tempChar": "" + "tempChar": "" } ], "id": 10, @@ -333,7 +373,7 @@ { "id": 16, "paths": [ - "M512 170.667c235.641 0 426.667 191.025 426.667 426.667s-191.025 426.667-426.667 426.667c-235.641 0-426.667-191.025-426.667-426.667s191.025-426.667 426.667-426.667zM712.834 460.5c-16.662-16.662-43.672-16.662-60.334 0l-183.166 183.167-97.833-97.834c-16.662-16.662-43.672-16.662-60.334 0s-16.662 43.672 0 60.334l128 128c16.662 16.663 43.672 16.663 60.334 0l213.333-213.333c16.663-16.662 16.663-43.672 0-60.334z" + "M833.277 273.471c25.696 24.27 26.857 64.776 2.585 90.473l-362.667 384c-11.872 12.57-28.326 19.802-45.615 20.050s-33.942-6.513-46.169-18.739l-192-192c-24.993-24.993-24.993-65.516 0-90.51s65.516-24.993 90.51 0l145.434 145.434 317.449-336.123c24.27-25.696 64.776-26.854 90.473-2.585z" ], "attrs": [ {} @@ -599,13 +639,21 @@ }, { "selection": [ + { + "order": 1024, + "id": 50, + "name": "ic_fluent_person_tag_24_filled", + "prevSize": 32, + "code": 60157, + "tempChar": "" + }, { "order": 1010, "id": 49, "name": "ic_fluent_chat_empty_24_regular", "prevSize": 32, "code": 60142, - "tempChar": "" + "tempChar": "" }, { "order": 1009, @@ -613,7 +661,7 @@ "name": "ic_fluent_chat_dismiss_24_regular", "prevSize": 32, "code": 60143, - "tempChar": "" + "tempChar": "" }, { "order": 1008, @@ -621,7 +669,7 @@ "name": "ic_fluent_chat_add_24_regular", "prevSize": 32, "code": 60144, - "tempChar": "" + "tempChar": "" }, { "order": 991, @@ -629,7 +677,7 @@ "name": "ic_fluent_previous_24_filled", "prevSize": 32, "code": 60124, - "tempChar": "" + "tempChar": "" }, { "order": 990, @@ -637,7 +685,7 @@ "name": "ic_fluent_next_24_filled", "prevSize": 32, "code": 60125, - "tempChar": "" + "tempChar": "" }, { "order": 953, @@ -645,7 +693,7 @@ "name": "ic_fluent_gift_24_regular", "prevSize": 32, "code": 60091, - "tempChar": "" + "tempChar": "" }, { "order": 952, @@ -653,7 +701,7 @@ "name": "ic_fluent_chat_24_regular", "prevSize": 32, "code": 60090, - "tempChar": "" + "tempChar": "" }, { "order": 923, @@ -661,7 +709,7 @@ "name": "ic_fluent_dismiss_circle_24_filled", "prevSize": 32, "code": 59891, - "tempChar": "" + "tempChar": "" }, { "order": 922, @@ -669,7 +717,7 @@ "name": "ic_fluent_checkmark_circle_24_filled", "prevSize": 32, "code": 59892, - "tempChar": "" + "tempChar": "" }, { "order": 919, @@ -677,7 +725,7 @@ "name": "ic_fluent_delete_24_filled", "prevSize": 32, "code": 60064, - "tempChar": "" + "tempChar": "" }, { "order": 910, @@ -685,7 +733,7 @@ "name": "ic_fluent_settings_24_filled1", "prevSize": 32, "code": 60054, - "tempChar": "" + "tempChar": "" }, { "order": 909, @@ -693,7 +741,7 @@ "name": "ic_fluent_arrow_minimize_24_filled", "prevSize": 32, "code": 60052, - "tempChar": "" + "tempChar": "" }, { "order": 908, @@ -701,7 +749,7 @@ "name": "ic_fluent_arrow_maximize_24_filled", "prevSize": 32, "code": 60053, - "tempChar": "" + "tempChar": "" }, { "order": 902, @@ -709,7 +757,7 @@ "name": "ic_fluent_mic_off_24_filled", "prevSize": 32, "code": 60051, - "tempChar": "" + "tempChar": "" }, { "order": 846, @@ -717,7 +765,7 @@ "name": "tl_fluent_reply_another_chat_24_regular", "prevSize": 32, "code": 60000, - "tempChar": "" + "tempChar": "" }, { "order": 845, @@ -725,7 +773,7 @@ "name": "ic_fluent_call_24_filled2", "prevSize": 32, "code": 59999, - "tempChar": "" + "tempChar": "" }, { "order": 844, @@ -733,7 +781,7 @@ "name": "ic_fluent_share_screen_start_24_filled", "prevSize": 32, "code": 59998, - "tempChar": "" + "tempChar": "" }, { "order": 843, @@ -741,7 +789,7 @@ "name": "ic_fluent_call_end_24_filled", "prevSize": 32, "code": 59997, - "tempChar": "" + "tempChar": "" }, { "order": 842, @@ -749,7 +797,7 @@ "name": "tl_fluent_arrow_download_24_filled", "prevSize": 32, "code": 59996, - "tempChar": "" + "tempChar": "" }, { "order": 822, @@ -757,7 +805,7 @@ "name": "ic_fluent_edit_24_regular", "prevSize": 32, "code": 59979, - "tempChar": "" + "tempChar": "" }, { "order": 820, @@ -765,7 +813,7 @@ "name": "ic_fluent_link_24_regular", "prevSize": 32, "code": 59977, - "tempChar": "" + "tempChar": "" }, { "order": 821, @@ -773,7 +821,7 @@ "name": "tl_fluent_arrow_reply_24_regular", "prevSize": 32, "code": 59978, - "tempChar": "" + "tempChar": "" }, { "order": 798, @@ -781,7 +829,7 @@ "name": "tl_fluent_boost_24_filled", "prevSize": 32, "code": 59962, - "tempChar": "" + "tempChar": "" }, { "order": 755, @@ -789,7 +837,7 @@ "name": "ic_fluent_call_24_filled1", "prevSize": 32, "code": 59675, - "tempChar": "" + "tempChar": "" }, { "order": 754, @@ -797,7 +845,7 @@ "name": "ic_fluent_video_24_filled", "prevSize": 32, "code": 59678, - "tempChar": "" + "tempChar": "" }, { "order": 746, @@ -805,7 +853,7 @@ "name": "ic_fluent_play_24_filled", "prevSize": 32, "code": 59927, - "tempChar": "" + "tempChar": "" }, { "order": 745, @@ -813,7 +861,7 @@ "name": "ic_fluent_pause_24_filled", "prevSize": 32, "code": 59928, - "tempChar": "" + "tempChar": "" }, { "order": 742, @@ -821,7 +869,7 @@ "name": "ic_fluent_color_24_filled", "prevSize": 32, "code": 59931, - "tempChar": "" + "tempChar": "" }, { "order": 741, @@ -829,7 +877,7 @@ "name": "ic_fluent_image_24_filled", "prevSize": 32, "code": 59933, - "tempChar": "" + "tempChar": "" }, { "order": 740, @@ -837,7 +885,7 @@ "name": "ic_fluent_lock_closed_24_filled", "prevSize": 32, "code": 59934, - "tempChar": "" + "tempChar": "" }, { "order": 739, @@ -845,7 +893,7 @@ "name": "ic_fluent_dismiss_24_filled", "prevSize": 32, "code": 59935, - "tempChar": "" + "tempChar": "" }, { "order": 738, @@ -853,7 +901,7 @@ "name": "ic_fluent_checkmark_24_filled", "prevSize": 32, "code": 59936, - "tempChar": "" + "tempChar": "" }, { "order": 737, @@ -861,7 +909,7 @@ "name": "ic_fluent_fire_24_filled", "prevSize": 32, "code": 59937, - "tempChar": "" + "tempChar": "" }, { "order": 736, @@ -869,7 +917,7 @@ "name": "ic_fluent_document_24_filled", "prevSize": 32, "code": 59932, - "tempChar": "" + "tempChar": "" }, { "order": 684, @@ -877,7 +925,7 @@ "name": "ic_fluent_my_location_24_regular", "prevSize": 32, "code": 59888, - "tempChar": "" + "tempChar": "" }, { "order": 670, @@ -885,7 +933,7 @@ "name": "ic_fluent_mic_24_regular", "prevSize": 32, "code": 59876, - "tempChar": "" + "tempChar": "" }, { "order": 667, @@ -893,7 +941,7 @@ "name": "ic_fluent_gif_24_regular", "prevSize": 32, "code": 59873, - "tempChar": "" + "tempChar": "" }, { "order": 668, @@ -901,7 +949,7 @@ "name": "ic_fluent_sticker_24_regular", "prevSize": 32, "code": 59874, - "tempChar": "" + "tempChar": "" }, { "order": 669, @@ -909,7 +957,7 @@ "name": "ic_fluent_emoji_24_regular", "prevSize": 32, "code": 59875, - "tempChar": "" + "tempChar": "" }, { "order": 665, @@ -917,7 +965,7 @@ "name": "ic_fluent_alert_off_24_regular", "prevSize": 32, "code": 59870, - "tempChar": "" + "tempChar": "" }, { "order": 666, @@ -925,7 +973,7 @@ "name": "ic_fluent_alert_24_regular1", "prevSize": 32, "code": 59871, - "tempChar": "" + "tempChar": "" }, { "order": 664, @@ -933,7 +981,7 @@ "name": "videomsg", "prevSize": 32, "code": 59872, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -949,7 +997,7 @@ "name": "bot_command", "prevSize": 32, "code": 59868, - "tempChar": "" + "tempChar": "" }, { "order": 660, @@ -957,7 +1005,7 @@ "name": "ic_fluent_timer_24_regular", "prevSize": 32, "code": 59867, - "tempChar": "" + "tempChar": "" }, { "order": 659, @@ -965,7 +1013,7 @@ "name": "ic_fluent_calendar_clock_24_regular", "prevSize": 32, "code": 59866, - "tempChar": "" + "tempChar": "" }, { "order": 657, @@ -973,7 +1021,7 @@ "name": "bot_keyboard", "prevSize": 32, "code": 59861, - "tempChar": "" + "tempChar": "" }, { "order": 654, @@ -981,7 +1029,7 @@ "name": "cam_filled", "prevSize": 32, "code": 59862, - "tempChar": "" + "tempChar": "" }, { "order": 658, @@ -989,7 +1037,7 @@ "name": "mic_filled", "prevSize": 32, "code": 59863, - "tempChar": "" + "tempChar": "" }, { "order": 656, @@ -997,7 +1045,7 @@ "name": "ic_fluent_attach_24_regular", "prevSize": 32, "code": 59864, - "tempChar": "" + "tempChar": "" } ], "id": 9, @@ -1011,6 +1059,21 @@ "height": 1024, "prevSize": 32, "icons": [ + { + "id": 50, + "paths": [ + "M469.338 597.342v125.222c0 33.489 13.167 65.617 36.634 89.506l96.273 98.010c-50.338 19.123-108.971 28.642-175.561 28.642-145.963 0-253.609-45.743-319.408-138.091-14.164-19.878-21.775-43.678-21.775-68.087v-39.249c0-52.996 42.959-95.953 95.952-95.953h287.886zM640.017 298.875c0-117.821-95.514-213.333-213.333-213.333-117.822 0-213.335 95.513-213.335 213.333s95.513 213.334 213.335 213.334c117.82 0 213.333-95.513 213.333-213.334zM707.081 955.917l-170.671-173.747c-15.646-15.923-24.405-37.325-24.405-59.605v-125.291c0-47.019 38.217-85.137 85.393-85.167l124.463-0.090c22.519-0.017 44.139 8.828 60.16 24.606l173.892 171.268c33.664 33.161 33.899 87.262 0.516 120.687l-127.684 127.855c-33.604 33.647-88.333 33.417-121.664-0.516zM639.846 682.679c23.531 0 42.611-19.106 42.611-42.667 0-23.565-19.081-42.667-42.611-42.667-23.535 0-42.611 19.102-42.611 42.667 0 23.561 19.076 42.667 42.611 42.667z" + ], + "attrs": [ + {} + ], + "isMulticolor": false, + "isMulticolor2": false, + "grid": 0, + "tags": [ + "ic_fluent_person_tag_24_filled" + ] + }, { "id": 49, "paths": [ @@ -1793,7 +1856,7 @@ "name": "Premium-Status", "prevSize": 32, "code": 59889, - "tempChar": "" + "tempChar": "" } ], "id": 8, @@ -1838,7 +1901,7 @@ 60152, 60153 ], - "tempChar": "" + "tempChar": "" }, { "order": 1018, @@ -1852,7 +1915,7 @@ 60156, 60157 ], - "tempChar": "" + "tempChar": "" }, { "order": 1014, @@ -1860,7 +1923,7 @@ "name": "ic_fluent_chevron_left_16_regular", "prevSize": 32, "code": 60146, - "tempChar": "" + "tempChar": "" }, { "order": 1013, @@ -1868,7 +1931,7 @@ "name": "ic_fluent_chevron_up_16_regular", "prevSize": 32, "code": 60147, - "tempChar": "" + "tempChar": "" }, { "order": 1012, @@ -1876,7 +1939,7 @@ "name": "ic_fluent_chevron_right_16_regular", "prevSize": 32, "code": 60148, - "tempChar": "" + "tempChar": "" }, { "order": 1004, @@ -1884,7 +1947,7 @@ "name": "ic_fluent_dismiss_16_filled", "prevSize": 32, "code": 60138, - "tempChar": "" + "tempChar": "" }, { "order": 992, @@ -1892,7 +1955,7 @@ "name": "ic_fluent_music_note_2_16_filled", "prevSize": 32, "code": 60126, - "tempChar": "" + "tempChar": "" }, { "order": 981, @@ -1900,7 +1963,7 @@ "name": "ic_fluent_add_square_16_filled", "prevSize": 32, "code": 60114, - "tempChar": "" + "tempChar": "" }, { "order": 980, @@ -1908,7 +1971,7 @@ "name": "tl_fluent_checkmark_square_16_filled", "prevSize": 32, "code": 60115, - "tempChar": "" + "tempChar": "" }, { "order": 979, @@ -1916,7 +1979,7 @@ "name": "tl_fluent_dismiss_square_16_filled", "prevSize": 32, "code": 60116, - "tempChar": "" + "tempChar": "" }, { "order": 977, @@ -1924,7 +1987,7 @@ "name": "tl_fluent_checkmark_empty_16_filled", "prevSize": 32, "code": 60112, - "tempChar": "" + "tempChar": "" }, { "order": 976, @@ -1932,7 +1995,7 @@ "name": "ic_fluent_checkmark_circle_16_filled", "prevSize": 32, "code": 60111, - "tempChar": "" + "tempChar": "" }, { "order": 965, @@ -1940,7 +2003,7 @@ "name": "ic_fluent_window_16_filled", "prevSize": 32, "code": 60101, - "tempChar": "" + "tempChar": "" }, { "order": 948, @@ -1948,7 +2011,7 @@ "name": "ic_fluent_mic_off_16_filled", "prevSize": 32, "code": 60087, - "tempChar": "" + "tempChar": "" }, { "order": 947, @@ -1956,7 +2019,7 @@ "name": "ic_fluent_mic_16_filled", "prevSize": 32, "code": 60088, - "tempChar": "" + "tempChar": "" }, { "order": 911, @@ -1964,7 +2027,7 @@ "name": "ic_fluent_copy_16_filled", "prevSize": 32, "code": 60055, - "tempChar": "" + "tempChar": "" }, { "order": 893, @@ -1972,7 +2035,7 @@ "name": "ic_fluent_pin_16_filled", "prevSize": 32, "code": 60042, - "tempChar": "" + "tempChar": "" }, { "order": 838, @@ -1980,7 +2043,7 @@ "name": "ic_fluent_code_16_filled", "prevSize": 32, "code": 59994, - "tempChar": "" + "tempChar": "" }, { "order": 824, @@ -1988,7 +2051,7 @@ "name": "ic_fluent_arrow_right_16_filled", "prevSize": 32, "code": 59981, - "tempChar": "" + "tempChar": "" }, { "order": 823, @@ -1996,7 +2059,7 @@ "name": "ic_fluent_chat_empty_16_filled", "prevSize": 32, "code": 59980, - "tempChar": "" + "tempChar": "" }, { "order": 813, @@ -2004,7 +2067,7 @@ "name": "ic_fluent_megaphone_16_filled", "prevSize": 32, "code": 59975, - "tempChar": "" + "tempChar": "" }, { "order": 814, @@ -2012,7 +2075,7 @@ "name": "ic_fluent_person_16_filled", "prevSize": 32, "code": 59976, - "tempChar": "" + "tempChar": "" }, { "order": 819, @@ -2020,7 +2083,7 @@ "name": "tl_fluent_quote_block_16_filled", "prevSize": 32, "code": 59905, - "tempChar": "" + "tempChar": "" }, { "order": 818, @@ -2028,7 +2091,7 @@ "name": "ic_fluent_code_block_16_filled", "prevSize": 32, "code": 59965, - "tempChar": "" + "tempChar": "" }, { "order": 817, @@ -2036,7 +2099,7 @@ "name": "ic_fluent_person_circle_16_filled", "prevSize": 32, "code": 59942, - "tempChar": "" + "tempChar": "" }, { "order": 816, @@ -2044,7 +2107,7 @@ "name": "ic_fluent_people_16_filled", "prevSize": 32, "code": 59943, - "tempChar": "" + "tempChar": "" }, { "order": 815, @@ -2052,7 +2115,7 @@ "name": "ic_fluent_star_16_filled", "prevSize": 32, "code": 59939, - "tempChar": "" + "tempChar": "" }, { "order": 756, @@ -2060,7 +2123,7 @@ "name": "ic_fluent_arrow_down_left_16_regular", "prevSize": 32, "code": 59688, - "tempChar": "" + "tempChar": "" }, { "order": 728, @@ -2068,7 +2131,7 @@ "name": "ic_fluent_chevron_down_16_regular", "prevSize": 32, "code": 59926, - "tempChar": "" + "tempChar": "" }, { "order": 699, @@ -2076,7 +2139,7 @@ "name": "ic_fluent_number_symbol_16_filled", "prevSize": 32, "code": 59899, - "tempChar": "" + "tempChar": "" }, { "order": 631, @@ -2084,7 +2147,7 @@ "name": "ic_fluent_lock_closed_16_filled1", "prevSize": 32, "code": 59838, - "tempChar": "" + "tempChar": "" }, { "order": 623, @@ -2092,7 +2155,7 @@ "name": "ic_fluent_arrow_up_right_16_regular", "prevSize": 32, "code": 59831, - "tempChar": "" + "tempChar": "" }, { "order": 610, @@ -2100,7 +2163,7 @@ "name": "ic_fluent_window_16_regular", "prevSize": 32, "code": 59818, - "tempChar": "" + "tempChar": "" }, { "order": 611, @@ -2108,7 +2171,7 @@ "name": "ic_fluent_payment_16_regular", "prevSize": 32, "code": 59819, - "tempChar": "" + "tempChar": "" }, { "order": 591, @@ -2116,7 +2179,7 @@ "name": "ic_fluent_compose_16_regular", "prevSize": 32, "code": 59798, - "tempChar": "" + "tempChar": "" } ], "id": 7, @@ -2683,7 +2746,7 @@ "name": "device_android", "prevSize": 32, "code": 59756, - "tempChar": "" + "tempChar": "" }, { "order": 499, @@ -2691,7 +2754,7 @@ "name": "device_chrome", "prevSize": 32, "code": 59757, - "tempChar": "" + "tempChar": "" }, { "order": 500, @@ -2699,7 +2762,7 @@ "name": "device_edge", "prevSize": 32, "code": 59758, - "tempChar": "" + "tempChar": "" }, { "order": 501, @@ -2707,7 +2770,7 @@ "name": "device_firefox", "prevSize": 32, "code": 59759, - "tempChar": "" + "tempChar": "" }, { "order": 502, @@ -2715,7 +2778,7 @@ "name": "device_ipad", "prevSize": 32, "code": 59760, - "tempChar": "" + "tempChar": "" }, { "order": 503, @@ -2723,7 +2786,7 @@ "name": "device_iphone", "prevSize": 32, "code": 59761, - "tempChar": "" + "tempChar": "" }, { "order": 504, @@ -2731,7 +2794,7 @@ "name": "device_linux", "prevSize": 32, "code": 59762, - "tempChar": "" + "tempChar": "" }, { "order": 505, @@ -2739,7 +2802,7 @@ "name": "device_mac", "prevSize": 32, "code": 59763, - "tempChar": "" + "tempChar": "" }, { "order": 506, @@ -2747,7 +2810,7 @@ "name": "device_safari", "prevSize": 32, "code": 59764, - "tempChar": "" + "tempChar": "" }, { "order": 507, @@ -2755,7 +2818,7 @@ "name": "device_ubuntu", "prevSize": 32, "code": 59766, - "tempChar": "" + "tempChar": "" }, { "order": 508, @@ -2763,7 +2826,7 @@ "name": "device_windows", "prevSize": 32, "code": 59767, - "tempChar": "" + "tempChar": "" } ], "id": 6, @@ -2938,13 +3001,53 @@ }, { "selection": [ + { + "order": 1027, + "id": 340, + "name": "ic_fluent_mention_20_filled", + "prevSize": 32, + "code": 60160, + "tempChar": "" + }, + { + "order": 1026, + "id": 339, + "name": "ic_fluent_poll_20_filled", + "prevSize": 32, + "code": 60161, + "tempChar": "" + }, + { + "order": 1023, + "id": 338, + "name": "ic_fluent_person_tag_20_regular", + "prevSize": 32, + "code": 60158, + "tempChar": "" + }, + { + "order": 1021, + "id": 337, + "name": "ic_fluent_arrow_download_off_20_regular", + "prevSize": 32, + "code": 60153, + "tempChar": "" + }, + { + "order": 1020, + "id": 336, + "name": "ic_fluent_camera_off_20_regular", + "prevSize": 32, + "code": 60155, + "tempChar": "" + }, { "order": 1016, "id": 335, "name": "ic_fluent_arrow_trending_lines_20_regular", "prevSize": 32, "code": 60150, - "tempChar": "" + "tempChar": "" }, { "order": 1000, @@ -2952,7 +3055,7 @@ "name": "ic_fluent_skip_forward_10_20_regular", "prevSize": 32, "code": 60133, - "tempChar": "" + "tempChar": "" }, { "order": 999, @@ -2960,7 +3063,7 @@ "name": "ic_fluent_skip_back_10_20_regular", "prevSize": 32, "code": 60134, - "tempChar": "" + "tempChar": "" }, { "order": 998, @@ -2968,7 +3071,7 @@ "name": "ic_fluent_dismiss_20_filled", "prevSize": 32, "code": 60132, - "tempChar": "" + "tempChar": "" }, { "order": 997, @@ -2976,7 +3079,7 @@ "name": "ic_fluent_call_end_20_filled", "prevSize": 32, "code": 60131, - "tempChar": "" + "tempChar": "" }, { "order": 996, @@ -2984,7 +3087,7 @@ "name": "ic_fluent_chat_off_20_regular", "prevSize": 32, "code": 60130, - "tempChar": "" + "tempChar": "" }, { "order": 993, @@ -2992,7 +3095,7 @@ "name": "ic_fluent_notepad_edit_20_regular", "prevSize": 32, "code": 60127, - "tempChar": "" + "tempChar": "" }, { "order": 988, @@ -3000,7 +3103,7 @@ "name": "ic_fluent_image_20_filled", "prevSize": 32, "code": 60122, - "tempChar": "" + "tempChar": "" }, { "order": 987, @@ -3008,7 +3111,7 @@ "name": "ic_fluent_warning_20_filled", "prevSize": 32, "code": 60121, - "tempChar": "" + "tempChar": "" }, { "order": 986, @@ -3016,7 +3119,7 @@ "name": "ic_fluent_gift_20_regular", "prevSize": 32, "code": 60120, - "tempChar": "" + "tempChar": "" }, { "order": 982, @@ -3024,7 +3127,7 @@ "name": "ic_fluent_scan_text_20_regular", "prevSize": 32, "code": 60118, - "tempChar": "" + "tempChar": "" }, { "order": 978, @@ -3032,7 +3135,7 @@ "name": "ic_fluent_key_20_regular", "prevSize": 32, "code": 60113, - "tempChar": "" + "tempChar": "" }, { "order": 973, @@ -3040,7 +3143,7 @@ "name": "ic_fluent_checkmark_circle_20_filled", "prevSize": 32, "code": 60108, - "tempChar": "" + "tempChar": "" }, { "order": 972, @@ -3048,7 +3151,7 @@ "name": "ic_fluent_dismiss_circle_20_filled", "prevSize": 32, "code": 60109, - "tempChar": "" + "tempChar": "" }, { "order": 971, @@ -3056,7 +3159,7 @@ "name": "ic_fluent_chevron_circle_down_20_regular", "prevSize": 32, "code": 60107, - "tempChar": "" + "tempChar": "" }, { "order": 970, @@ -3064,7 +3167,7 @@ "name": "ic_fluent_qr_code_20_regular", "prevSize": 32, "code": 60106, - "tempChar": "" + "tempChar": "" }, { "order": 967, @@ -3072,7 +3175,7 @@ "name": "ic_fluent_text_quote_20_regular", "prevSize": 32, "code": 60103, - "tempChar": "" + "tempChar": "" }, { "order": 966, @@ -3080,7 +3183,7 @@ "name": "tl_fluent_reply_another_chat_20_filled", "prevSize": 32, "code": 60102, - "tempChar": "" + "tempChar": "" }, { "order": 962, @@ -3088,7 +3191,7 @@ "name": "ic_fluent_calendar_20_regular", "prevSize": 32, "code": 60098, - "tempChar": "" + "tempChar": "" }, { "order": 959, @@ -3096,7 +3199,7 @@ "name": "ic_fluent_checkmark_square_20_filled", "prevSize": 32, "code": 60095, - "tempChar": "" + "tempChar": "" }, { "order": 958, @@ -3104,7 +3207,7 @@ "name": "ic_fluent_checkmark_square_20_regular", "prevSize": 32, "code": 60094, - "tempChar": "" + "tempChar": "" }, { "order": 956, @@ -3112,7 +3215,7 @@ "name": "ic_fluent_crop_20_regular", "prevSize": 32, "code": 60092, - "tempChar": "" + "tempChar": "" }, { "order": 950, @@ -3120,7 +3223,7 @@ "name": "ic_fluent_add_20_regular", "prevSize": 32, "code": 60086, - "tempChar": "" + "tempChar": "" }, { "order": 949, @@ -3128,7 +3231,7 @@ "name": "tl_fluent_navigation_menu_20_regular", "prevSize": 32, "code": 60085, - "tempChar": "" + "tempChar": "" }, { "order": 944, @@ -3136,7 +3239,7 @@ "name": "ic_fluent_tag_20_regular", "prevSize": 32, "code": 60084, - "tempChar": "" + "tempChar": "" }, { "order": 943, @@ -3144,7 +3247,7 @@ "name": "tl_fluent_crown_off_20_filled", "prevSize": 32, "code": 60081, - "tempChar": "" + "tempChar": "" }, { "order": 942, @@ -3152,7 +3255,7 @@ "name": "ic_fluent_tag_off_20_filled", "prevSize": 32, "code": 60082, - "tempChar": "" + "tempChar": "" }, { "order": 941, @@ -3160,7 +3263,7 @@ "name": "ic_fluent_crown_20_filled", "prevSize": 32, "code": 60083, - "tempChar": "" + "tempChar": "" }, { "order": 934, @@ -3168,7 +3271,7 @@ "name": "ic_fluent_call_add_20_regular", "prevSize": 32, "code": 60074, - "tempChar": "" + "tempChar": "" }, { "order": 933, @@ -3176,7 +3279,7 @@ "name": "ic_fluent_text_font_20_regular", "prevSize": 32, "code": 60073, - "tempChar": "" + "tempChar": "" }, { "order": 932, @@ -3184,7 +3287,7 @@ "name": "ic_fluent_hourglass_20_regular", "prevSize": 32, "code": 60072, - "tempChar": "" + "tempChar": "" }, { "order": 931, @@ -3192,7 +3295,7 @@ "name": "ic_fluent_thumb_like_20_regular", "prevSize": 32, "code": 60071, - "tempChar": "" + "tempChar": "" }, { "order": 930, @@ -3200,7 +3303,7 @@ "name": "ic_fluent_connected_20_regular", "prevSize": 32, "code": 60070, - "tempChar": "" + "tempChar": "" }, { "order": 928, @@ -3208,7 +3311,7 @@ "name": "ic_fluent_home_add_20_regular", "prevSize": 32, "code": 60068, - "tempChar": "" + "tempChar": "" }, { "order": 927, @@ -3216,7 +3319,7 @@ "name": "ic_fluent_lock_closed_20_regular", "prevSize": 32, "code": 60067, - "tempChar": "" + "tempChar": "" }, { "order": 916, @@ -3224,7 +3327,7 @@ "name": "ic_fluent_ticket_diagonal_20_regular", "prevSize": 32, "code": 60061, - "tempChar": "" + "tempChar": "" }, { "order": 915, @@ -3232,7 +3335,7 @@ "name": "ic_fluent_add_circle_20_filled", "prevSize": 32, "code": 60060, - "tempChar": "" + "tempChar": "" }, { "order": 914, @@ -3240,7 +3343,7 @@ "name": "ic_fluent_copy_20_filled", "prevSize": 32, "code": 60059, - "tempChar": "" + "tempChar": "" }, { "order": 913, @@ -3248,7 +3351,7 @@ "name": "ic_fluent_mic_off_20_filled", "prevSize": 32, "code": 60056, - "tempChar": "" + "tempChar": "" }, { "order": 912, @@ -3256,7 +3359,7 @@ "name": "ic_fluent_mic_20_filled", "prevSize": 32, "code": 60058, - "tempChar": "" + "tempChar": "" }, { "order": 900, @@ -3264,7 +3367,7 @@ "name": "ic_fluent_camera_add_20_filled", "prevSize": 32, "code": 60050, - "tempChar": "" + "tempChar": "" }, { "order": 898, @@ -3272,7 +3375,7 @@ "name": "ic_fluent_chat_sparkle_20_filled", "prevSize": 32, "code": 60048, - "tempChar": "" + "tempChar": "" }, { "order": 896, @@ -3280,7 +3383,7 @@ "name": "ic_fluent_info_20_regular", "prevSize": 32, "code": 60044, - "tempChar": "" + "tempChar": "" }, { "order": 894, @@ -3288,7 +3391,7 @@ "name": "ic_fluent_checkmark_starburst_20_regular", "prevSize": 32, "code": 60043, - "tempChar": "" + "tempChar": "" }, { "order": 892, @@ -3296,7 +3399,7 @@ "name": "ic_fluent_resize_20_regular", "prevSize": 32, "code": 60041, - "tempChar": "" + "tempChar": "" }, { "order": 891, @@ -3304,7 +3407,7 @@ "name": "ic_fluent_megaphone_off_20_regular", "prevSize": 32, "code": 60040, - "tempChar": "" + "tempChar": "" }, { "order": 889, @@ -3312,7 +3415,7 @@ "name": "ic_fluent_building_shop_20_filled", "prevSize": 32, "code": 60038, - "tempChar": "" + "tempChar": "" }, { "order": 888, @@ -3320,7 +3423,7 @@ "name": "ic_fluent_link_add_20_regular", "prevSize": 32, "code": 60037, - "tempChar": "" + "tempChar": "" }, { "order": 887, @@ -3328,7 +3431,7 @@ "name": "ic_fluent_food_cake_20_regular", "prevSize": 32, "code": 60036, - "tempChar": "" + "tempChar": "" }, { "order": 879, @@ -3336,7 +3439,7 @@ "name": "ic_fluent_hand_wave_20_filled", "prevSize": 32, "code": 60027, - "tempChar": "" + "tempChar": "" }, { "order": 878, @@ -3344,7 +3447,7 @@ "name": "ic_fluent_location_20_filled", "prevSize": 32, "code": 60026, - "tempChar": "" + "tempChar": "" }, { "order": 876, @@ -3352,7 +3455,7 @@ "name": "ic_fluent_bot_20_filled", "prevSize": 32, "code": 60023, - "tempChar": "" + "tempChar": "" }, { "order": 875, @@ -3360,7 +3463,7 @@ "name": "ic_fluent_megaphone_20_filled", "prevSize": 32, "code": 60024, - "tempChar": "" + "tempChar": "" }, { "order": 872, @@ -3368,7 +3471,7 @@ "name": "ic_fluent_hand_wave_20_regular", "prevSize": 32, "code": 60020, - "tempChar": "" + "tempChar": "" }, { "order": 873, @@ -3376,7 +3479,7 @@ "name": "ic_fluent_chat_arrow_back_20_regular", "prevSize": 32, "code": 60021, - "tempChar": "" + "tempChar": "" }, { "order": 870, @@ -3384,7 +3487,7 @@ "name": "ic_fluent_image_multiple_20_regular", "prevSize": 32, "code": 60018, - "tempChar": "" + "tempChar": "" }, { "order": 869, @@ -3392,7 +3495,7 @@ "name": "ic_fluent_image_sparkle_20_regular", "prevSize": 32, "code": 60017, - "tempChar": "" + "tempChar": "" }, { "order": 867, @@ -3400,7 +3503,7 @@ "name": "ic_fluent_emoji_sparkle_20_regular", "prevSize": 32, "code": 60015, - "tempChar": "" + "tempChar": "" }, { "order": 866, @@ -3408,7 +3511,7 @@ "name": "ic_fluent_hand_open_heart_20_regular", "prevSize": 32, "code": 60016, - "tempChar": "" + "tempChar": "" }, { "order": 865, @@ -3416,7 +3519,7 @@ "name": "ic_fluent_chat_settings_20_filled", "prevSize": 32, "code": 60014, - "tempChar": "" + "tempChar": "" }, { "order": 863, @@ -3424,7 +3527,7 @@ "name": "ic_fluent_chat_lock_20_filled", "prevSize": 32, "code": 60012, - "tempChar": "" + "tempChar": "" }, { "order": 860, @@ -3432,7 +3535,7 @@ "name": "ic_fluent_hand_open_heart_20_filled", "prevSize": 32, "code": 60009, - "tempChar": "" + "tempChar": "" }, { "order": 859, @@ -3440,7 +3543,7 @@ "name": "ic_fluent_tag_20_filled", "prevSize": 32, "code": 60008, - "tempChar": "" + "tempChar": "" }, { "order": 858, @@ -3448,7 +3551,7 @@ "name": "ic_fluent_apps_list_detail_20_regular", "prevSize": 32, "code": 60007, - "tempChar": "" + "tempChar": "" }, { "order": 857, @@ -3459,7 +3562,7 @@ "codes": [ 60003 ], - "tempChar": "" + "tempChar": "" }, { "order": 856, @@ -3467,7 +3570,7 @@ "name": "tl_fluent_tag_edit_20_regular", "prevSize": 32, "code": 60004, - "tempChar": "" + "tempChar": "" }, { "order": 855, @@ -3475,7 +3578,7 @@ "name": "ic_fluent_tag_search_20_regular", "prevSize": 32, "code": 60005, - "tempChar": "" + "tempChar": "" }, { "order": 854, @@ -3483,7 +3586,7 @@ "name": "ic_fluent_tag_off_20_regular", "prevSize": 32, "code": 60006, - "tempChar": "" + "tempChar": "" }, { "order": 841, @@ -3491,7 +3594,7 @@ "name": "ic_fluent_arrow_rotate_counterclockwise_20_regular", "prevSize": 32, "code": 59995, - "tempChar": "" + "tempChar": "" }, { "order": 837, @@ -3499,7 +3602,7 @@ "name": "ic_fluent_more_horizontal_20_filled", "prevSize": 32, "code": 59993, - "tempChar": "" + "tempChar": "" }, { "order": 835, @@ -3507,7 +3610,7 @@ "name": "ic_fluent_search_20_filled", "prevSize": 32, "code": 59992, - "tempChar": "" + "tempChar": "" }, { "order": 834, @@ -3515,7 +3618,7 @@ "name": "ic_fluent_arrow_exit_20_filled", "prevSize": 32, "code": 59990, - "tempChar": "" + "tempChar": "" }, { "order": 833, @@ -3523,7 +3626,7 @@ "name": "ic_fluent_arrow_enter_20_filled", "prevSize": 32, "code": 59991, - "tempChar": "" + "tempChar": "" }, { "order": 832, @@ -3531,7 +3634,7 @@ "name": "ic_fluent_edit_20_filled", "prevSize": 32, "code": 59989, - "tempChar": "" + "tempChar": "" }, { "order": 831, @@ -3539,7 +3642,7 @@ "name": "ic_fluent_call_20_filled", "prevSize": 32, "code": 59986, - "tempChar": "" + "tempChar": "" }, { "order": 830, @@ -3547,7 +3650,7 @@ "name": "ic_fluent_alert_off_20_filled", "prevSize": 32, "code": 59987, - "tempChar": "" + "tempChar": "" }, { "order": 829, @@ -3555,7 +3658,7 @@ "name": "ic_fluent_alert_20_filled", "prevSize": 32, "code": 59988, - "tempChar": "" + "tempChar": "" }, { "order": 828, @@ -3563,7 +3666,7 @@ "name": "ic_fluent_wallpaper_20_filled", "prevSize": 32, "code": 59984, - "tempChar": "" + "tempChar": "" }, { "order": 827, @@ -3571,7 +3674,7 @@ "name": "ic_fluent_paint_brush_20_filled", "prevSize": 32, "code": 59985, - "tempChar": "" + "tempChar": "" }, { "order": 825, @@ -3579,7 +3682,7 @@ "name": "ic_fluent_dismiss_circle_20_regular", "prevSize": 32, "code": 59982, - "tempChar": "" + "tempChar": "" }, { "order": 805, @@ -3587,7 +3690,7 @@ "name": "ic_fluent_person_delete_20_filled", "prevSize": 32, "code": 59968, - "tempChar": "" + "tempChar": "" }, { "order": 806, @@ -3595,7 +3698,7 @@ "name": "ic_fluent_person_question_mark_20_filled", "prevSize": 32, "code": 59969, - "tempChar": "" + "tempChar": "" }, { "order": 796, @@ -3603,7 +3706,7 @@ "name": "ic_fluent_wallet_20_regular", "prevSize": 32, "code": 59960, - "tempChar": "" + "tempChar": "" }, { "order": 792, @@ -3611,7 +3714,7 @@ "name": "ic_fluent_clock_20_filled", "prevSize": 32, "code": 59955, - "tempChar": "" + "tempChar": "" }, { "order": 793, @@ -3619,7 +3722,7 @@ "name": "ic_fluent_clock_20_regular1", "prevSize": 32, "code": 59956, - "tempChar": "" + "tempChar": "" }, { "order": 789, @@ -3627,7 +3730,7 @@ "name": "ic_fluent_speaker_2_20_filled", "prevSize": 32, "code": 59950, - "tempChar": "" + "tempChar": "" }, { "order": 788, @@ -3635,7 +3738,7 @@ "name": "ic_fluent_speaker_1_20_filled", "prevSize": 32, "code": 59951, - "tempChar": "" + "tempChar": "" }, { "order": 787, @@ -3643,7 +3746,7 @@ "name": "ic_fluent_speaker_mute_20_filled", "prevSize": 32, "code": 59952, - "tempChar": "" + "tempChar": "" }, { "order": 779, @@ -3651,7 +3754,7 @@ "name": "tl_fluent_stories_pinned_20_regular", "prevSize": 32, "code": 59820, - "tempChar": "" + "tempChar": "" }, { "order": 778, @@ -3659,7 +3762,7 @@ "name": "tl_fluent_stories_pinned_off_20_regular", "prevSize": 32, "code": 59858, - "tempChar": "" + "tempChar": "" }, { "order": 777, @@ -3667,7 +3770,7 @@ "name": "ic_fluent_multiplier_2x_20_filled", "prevSize": 32, "code": 59834, - "tempChar": "" + "tempChar": "" }, { "order": 776, @@ -3675,7 +3778,7 @@ "name": "ic_fluent_heart_20_filled", "prevSize": 32, "code": 59830, - "tempChar": "" + "tempChar": "" }, { "order": 775, @@ -3683,7 +3786,7 @@ "name": "ic_fluent_sticker_20_filled", "prevSize": 32, "code": 59821, - "tempChar": "" + "tempChar": "" }, { "order": 774, @@ -3691,7 +3794,7 @@ "name": "ic_fluent_play_circle_20_filled", "prevSize": 32, "code": 59822, - "tempChar": "" + "tempChar": "" }, { "order": 773, @@ -3699,7 +3802,7 @@ "name": "ic_fluent_megaphone_off_20_filled", "prevSize": 32, "code": 59823, - "tempChar": "" + "tempChar": "" }, { "order": 772, @@ -3707,7 +3810,7 @@ "name": "ic_fluent_chat_empty_20_filled", "prevSize": 32, "code": 59824, - "tempChar": "" + "tempChar": "" }, { "order": 771, @@ -3715,7 +3818,7 @@ "name": "ic_fluent_emoji_20_filled", "prevSize": 32, "code": 59825, - "tempChar": "" + "tempChar": "" }, { "order": 770, @@ -3723,7 +3826,7 @@ "name": "ic_fluent_translate_20_filled", "prevSize": 32, "code": 59826, - "tempChar": "" + "tempChar": "" }, { "order": 769, @@ -3731,7 +3834,7 @@ "name": "ic_fluent_top_speed_20_filled", "prevSize": 32, "code": 59827, - "tempChar": "" + "tempChar": "" }, { "order": 768, @@ -3739,7 +3842,7 @@ "name": "ic_fluent_document_20_filled", "prevSize": 32, "code": 59828, - "tempChar": "" + "tempChar": "" }, { "order": 765, @@ -3747,7 +3850,7 @@ "name": "ic_fluent_lock_closed_20_filled", "prevSize": 32, "code": 59941, - "tempChar": "" + "tempChar": "" }, { "order": 762, @@ -3755,7 +3858,7 @@ "name": "ic_fluent_error_circle_20_regular", "prevSize": 32, "code": 59938, - "tempChar": "" + "tempChar": "" }, { "order": 758, @@ -3763,7 +3866,7 @@ "name": "ic_fluent_more_horizontal_20_regular", "prevSize": 32, "code": 59154, - "tempChar": "" + "tempChar": "" }, { "order": 744, @@ -3771,7 +3874,7 @@ "name": "ic_fluent_picture_in_picture_exit_20_regular", "prevSize": 32, "code": 59693, - "tempChar": "" + "tempChar": "" }, { "order": 743, @@ -3779,7 +3882,7 @@ "name": "ic_fluent_picture_in_picture_enter_20_regular", "prevSize": 32, "code": 59692, - "tempChar": "" + "tempChar": "" }, { "order": 727, @@ -3787,7 +3890,7 @@ "name": "ic_fluent_arrow_repeat_all_20_regular", "prevSize": 32, "code": 59924, - "tempChar": "" + "tempChar": "" }, { "order": 726, @@ -3795,7 +3898,7 @@ "name": "ic_fluent_arrow_repeat_1_20_regular", "prevSize": 32, "code": 59925, - "tempChar": "" + "tempChar": "" }, { "order": 723, @@ -3803,7 +3906,7 @@ "name": "ic_fluent_speaker_0_20_regular", "prevSize": 32, "code": 59921, - "tempChar": "" + "tempChar": "" }, { "order": 724, @@ -3811,7 +3914,7 @@ "name": "ic_fluent_speaker_3_20_regular", "prevSize": 32, "code": 59922, - "tempChar": "" + "tempChar": "" }, { "order": 721, @@ -3819,7 +3922,7 @@ "name": "ic_fluent_chat_multiple_20_filled", "prevSize": 32, "code": 59917, - "tempChar": "" + "tempChar": "" }, { "order": 720, @@ -3827,7 +3930,7 @@ "name": "ic_fluent_archive_20_filled", "prevSize": 32, "code": 59918, - "tempChar": "" + "tempChar": "" }, { "order": 719, @@ -3835,7 +3938,7 @@ "name": "ic_fluent_bookmark_20_filled", "prevSize": 32, "code": 59919, - "tempChar": "" + "tempChar": "" }, { "order": 718, @@ -3843,7 +3946,7 @@ "name": "ic_fluent_history_20_regular", "prevSize": 32, "code": 59780, - "tempChar": "" + "tempChar": "" }, { "order": 716, @@ -3851,7 +3954,7 @@ "name": "PersonCircleOnline", "prevSize": 32, "code": 59778, - "tempChar": "" + "tempChar": "" }, { "order": 715, @@ -3859,7 +3962,7 @@ "name": "ic_fluent_arrow_sync_20_regular", "prevSize": 32, "code": 59777, - "tempChar": "" + "tempChar": "" }, { "order": 712, @@ -3867,7 +3970,7 @@ "name": "ic_fluent_slide_text_20_regular", "prevSize": 32, "code": 59914, - "tempChar": "" + "tempChar": "" }, { "order": 711, @@ -3875,7 +3978,7 @@ "name": "ic_fluent_arrow_reset_20_regular", "prevSize": 32, "code": 59913, - "tempChar": "" + "tempChar": "" }, { "order": 710, @@ -3883,7 +3986,7 @@ "name": "ic_fluent_chat_add_20_regular", "prevSize": 32, "code": 59912, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -3899,7 +4002,7 @@ "name": "ic_fluent_arrow_upload_20_regular", "prevSize": 32, "code": 59904, - "tempChar": "" + "tempChar": "" }, { "order": 702, @@ -3907,7 +4010,7 @@ "name": "ic_fluent_camera_sparkles_20_regular", "prevSize": 32, "code": 59902, - "tempChar": "" + "tempChar": "" }, { "order": 701, @@ -3915,7 +4018,7 @@ "name": "ic_fluent_camera_add_20_regular", "prevSize": 32, "code": 59901, - "tempChar": "" + "tempChar": "" }, { "order": 700, @@ -3923,7 +4026,7 @@ "name": "ic_fluent_play_circle_20_regular", "prevSize": 32, "code": 59900, - "tempChar": "" + "tempChar": "" }, { "order": 698, @@ -3931,7 +4034,7 @@ "name": "ic_fluent_shield_task_20_regular", "prevSize": 32, "code": 59897, - "tempChar": "" + "tempChar": "" }, { "order": 693, @@ -3939,7 +4042,7 @@ "name": "ic_fluent_re_order_dots_vertical_20_regular", "prevSize": 32, "code": 59894, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -3963,7 +4066,7 @@ "name": "ic_fluent_mention_20_regular", "prevSize": 32, "code": 59890, - "tempChar": "" + "tempChar": "" }, { "order": 683, @@ -3971,7 +4074,7 @@ "name": "ic_fluent_my_location_20_regular", "prevSize": 32, "code": 59887, - "tempChar": "" + "tempChar": "" }, { "order": 682, @@ -3979,7 +4082,7 @@ "name": "ic_fluent_weather_sunny_20_regular", "prevSize": 32, "code": 59886, - "tempChar": "" + "tempChar": "" }, { "order": 678, @@ -3987,7 +4090,7 @@ "name": "ic_fluent_emoji_edit_20_regular", "prevSize": 32, "code": 59884, - "tempChar": "" + "tempChar": "" }, { "order": 679, @@ -3995,7 +4098,7 @@ "name": "ic_fluent_emoji_add_20_regular", "prevSize": 32, "code": 59885, - "tempChar": "" + "tempChar": "" }, { "order": 677, @@ -4003,7 +4106,7 @@ "name": "ic_fluent_text_font_size_20_regular", "prevSize": 32, "code": 59883, - "tempChar": "" + "tempChar": "" }, { "order": 676, @@ -4011,7 +4114,7 @@ "name": "ic_fluent_shapes_20_regular", "prevSize": 32, "code": 59880, - "tempChar": "" + "tempChar": "" }, { "order": 675, @@ -4019,7 +4122,7 @@ "name": "ic_fluent_weather_moon_20_regular", "prevSize": 32, "code": 59882, - "tempChar": "" + "tempChar": "" }, { "order": 674, @@ -4027,7 +4130,7 @@ "name": "ic_fluent_wallpaper_20_regular", "prevSize": 32, "code": 59879, - "tempChar": "" + "tempChar": "" }, { "order": 673, @@ -4035,7 +4138,7 @@ "name": "ic_fluent_arrow_sort_20_regular", "prevSize": 32, "code": 59878, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -4059,7 +4162,7 @@ "name": "ic_fluent_chat_20_regular", "prevSize": 32, "code": 59839, - "tempChar": "" + "tempChar": "" }, { "order": 624, @@ -4067,7 +4170,7 @@ "name": "ic_fluent_person_20_filled", "prevSize": 32, "code": 59832, - "tempChar": "" + "tempChar": "" }, { "order": 625, @@ -4075,7 +4178,7 @@ "name": "ic_fluent_people_20_filled", "prevSize": 32, "code": 59833, - "tempChar": "" + "tempChar": "" }, { "order": 995, @@ -4083,7 +4186,7 @@ "name": "ic_fluent_chat_20_filled1", "prevSize": 32, "code": 60129, - "tempChar": "" + "tempChar": "" }, { "order": 627, @@ -4091,7 +4194,7 @@ "name": "ic_fluent_pin_20_filled", "prevSize": 32, "code": 59835, - "tempChar": "" + "tempChar": "" }, { "order": 628, @@ -4099,7 +4202,7 @@ "name": "ic_fluent_link_20_filled", "prevSize": 32, "code": 59836, - "tempChar": "" + "tempChar": "" }, { "order": 629, @@ -4107,7 +4210,7 @@ "name": "ic_fluent_folder_20_filled", "prevSize": 32, "code": 59837, - "tempChar": "" + "tempChar": "" }, { "order": 609, @@ -4115,7 +4218,7 @@ "name": "ic_fluent_person_available_20_regular", "prevSize": 32, "code": 59816, - "tempChar": "" + "tempChar": "" }, { "order": 608, @@ -4123,7 +4226,7 @@ "name": "ic_fluent_person_circle_20_regular", "prevSize": 32, "code": 59817, - "tempChar": "" + "tempChar": "" }, { "order": 607, @@ -4131,7 +4234,7 @@ "name": "ic_fluent_eye_off_20_regular", "prevSize": 32, "code": 59814, - "tempChar": "" + "tempChar": "" }, { "order": 606, @@ -4139,7 +4242,7 @@ "name": "ic_fluent_eye_20_regular", "prevSize": 32, "code": 59815, - "tempChar": "" + "tempChar": "" }, { "order": 605, @@ -4147,7 +4250,7 @@ "name": "ic_fluent_speaker_off_20_regular1", "prevSize": 32, "code": 59813, - "tempChar": "" + "tempChar": "" }, { "order": 604, @@ -4155,7 +4258,7 @@ "name": "ic_fluent_alert_on_20_regular", "prevSize": 32, "code": 59812, - "tempChar": "" + "tempChar": "" }, { "order": 598, @@ -4163,7 +4266,7 @@ "name": "ic_fluent_alert_snooze_20_regular", "prevSize": 32, "code": 59804, - "tempChar": "" + "tempChar": "" }, { "order": 597, @@ -4171,7 +4274,7 @@ "name": "ic_fluent_music_note_2_20_regular", "prevSize": 32, "code": 59805, - "tempChar": "" + "tempChar": "" }, { "order": 596, @@ -4179,7 +4282,7 @@ "name": "ic_fluent_music_note_off_2_20_regular", "prevSize": 32, "code": 59806, - "tempChar": "" + "tempChar": "" }, { "order": 594, @@ -4187,7 +4290,7 @@ "name": "ic_fluent_arrow_exit_20_regular", "prevSize": 32, "code": 59801, - "tempChar": "" + "tempChar": "" }, { "order": 595, @@ -4195,7 +4298,7 @@ "name": "ic_fluent_arrow_enter_20_regular", "prevSize": 32, "code": 59803, - "tempChar": "" + "tempChar": "" }, { "order": 593, @@ -4203,7 +4306,7 @@ "name": "ic_fluent_heart_12_filled", "prevSize": 32, "code": 59800, - "tempChar": "" + "tempChar": "" }, { "order": 588, @@ -4211,7 +4314,7 @@ "name": "ic_fluent_compose_20_regular", "prevSize": 32, "code": 59796, - "tempChar": "" + "tempChar": "" }, { "order": 587, @@ -4219,7 +4322,7 @@ "name": "ic_fluent_chat_multiple_20_regular", "prevSize": 32, "code": 59794, - "tempChar": "" + "tempChar": "" }, { "order": 534, @@ -4227,7 +4330,7 @@ "name": "ic_fluent_live_20_regular", "prevSize": 32, "code": 59789, - "tempChar": "" + "tempChar": "" }, { "order": 533, @@ -4235,7 +4338,7 @@ "name": "ic_fluent_dialpad_20_regular", "prevSize": 32, "code": 59788, - "tempChar": "" + "tempChar": "" }, { "order": 532, @@ -4243,7 +4346,7 @@ "name": "ic_fluent_hand_right_20_regular", "prevSize": 32, "code": 59787, - "tempChar": "" + "tempChar": "" }, { "order": 531, @@ -4251,7 +4354,7 @@ "name": "ic_fluent_folder_add_20_regular", "prevSize": 32, "code": 59786, - "tempChar": "" + "tempChar": "" }, { "order": 530, @@ -4259,7 +4362,7 @@ "name": "ic_fluent_arrow_trending_20_regular", "prevSize": 32, "code": 59785, - "tempChar": "" + "tempChar": "" }, { "order": 529, @@ -4267,7 +4370,7 @@ "name": "ic_fluent_subtract_circle_20_filled", "prevSize": 32, "code": 59784, - "tempChar": "" + "tempChar": "" }, { "order": 528, @@ -4275,7 +4378,7 @@ "name": "ic_fluent_heart_20_regular1", "prevSize": 32, "code": 59783, - "tempChar": "" + "tempChar": "" }, { "order": 526, @@ -4283,7 +4386,7 @@ "name": "ic_fluent_heart_16_filled", "prevSize": 32, "code": 59781, - "tempChar": "" + "tempChar": "" }, { "order": 527, @@ -4291,7 +4394,7 @@ "name": "ic_fluent_mention_16_regular", "prevSize": 32, "code": 59782, - "tempChar": "" + "tempChar": "" }, { "order": 520, @@ -4299,7 +4402,7 @@ "name": "ic_fluent_window_new_20_regular", "prevSize": 32, "code": 59775, - "tempChar": "" + "tempChar": "" }, { "order": 519, @@ -4307,7 +4410,7 @@ "name": "ic_fluent_checkmark_circle_20_regular", "prevSize": 32, "code": 59774, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -4323,7 +4426,7 @@ "name": "ic_fluent_translate_20_regular", "prevSize": 32, "code": 59773, - "tempChar": "" + "tempChar": "" }, { "order": 516, @@ -4331,7 +4434,7 @@ "name": "Pin", "prevSize": 32, "code": 59771, - "tempChar": "" + "tempChar": "" }, { "order": 515, @@ -4339,7 +4442,7 @@ "name": "Verified", "prevSize": 32, "code": 59770, - "tempChar": "" + "tempChar": "" }, { "order": 514, @@ -4347,7 +4450,7 @@ "name": "Speaker-Mute", "prevSize": 32, "code": 59769, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -4363,7 +4466,7 @@ "name": "ic_fluent_paint_brush_20_regular", "prevSize": 32, "code": 59662, - "tempChar": "" + "tempChar": "" }, { "order": 495, @@ -4371,7 +4474,7 @@ "name": "ic_fluent_top_speed_20_regular", "prevSize": 32, "code": 59661, - "tempChar": "" + "tempChar": "" }, { "order": 490, @@ -4379,7 +4482,7 @@ "name": "ic_fluent_checkmark_20_regular", "prevSize": 32, "code": 59643, - "tempChar": "" + "tempChar": "" }, { "order": 488, @@ -4387,7 +4490,7 @@ "name": "ic_fluent_zoom_out_20_regular", "prevSize": 32, "code": 59754, - "tempChar": "" + "tempChar": "" }, { "order": 487, @@ -4395,7 +4498,7 @@ "name": "ic_fluent_zoom_in_20_regular", "prevSize": 32, "code": 59753, - "tempChar": "" + "tempChar": "" }, { "order": 486, @@ -4403,7 +4506,7 @@ "name": "ic_fluent_stack_20_regular", "prevSize": 32, "code": 59660, - "tempChar": "" + "tempChar": "" }, { "order": 482, @@ -4411,7 +4514,7 @@ "name": "ic_fluent_dock_panel_right_20_filled", "prevSize": 32, "code": 59751, - "tempChar": "" + "tempChar": "" }, { "order": 483, @@ -4419,7 +4522,7 @@ "name": "ic_fluent_dock_panel_right_20_regular", "prevSize": 32, "code": 59752, - "tempChar": "" + "tempChar": "" }, { "order": 481, @@ -4427,7 +4530,7 @@ "name": "ic_fluent_arrow_clockwise_20_regular", "prevSize": 32, "code": 59180, - "tempChar": "" + "tempChar": "" }, { "order": 920, @@ -4435,7 +4538,7 @@ "name": "ic_fluent_arrow_minimize_20_regular", "prevSize": 32, "code": 59749, - "tempChar": "" + "tempChar": "" }, { "order": 921, @@ -4443,7 +4546,7 @@ "name": "ic_fluent_arrow_maximize_20_regular", "prevSize": 32, "code": 59750, - "tempChar": "" + "tempChar": "" }, { "order": 476, @@ -4451,7 +4554,7 @@ "name": "ic_fluent_video_off_20_filled", "prevSize": 32, "code": 59747, - "tempChar": "" + "tempChar": "" }, { "order": 475, @@ -4459,7 +4562,7 @@ "name": "ic_fluent_video_20_filled", "prevSize": 32, "code": 59748, - "tempChar": "" + "tempChar": "" }, { "order": 473, @@ -4467,7 +4570,7 @@ "name": "ic_fluent_share_screen_stop_20_filled", "prevSize": 32, "code": 59733, - "tempChar": "" + "tempChar": "" }, { "order": 474, @@ -4475,7 +4578,7 @@ "name": "ic_fluent_share_screen_start_20_filled", "prevSize": 32, "code": 59734, - "tempChar": "" + "tempChar": "" }, { "order": 417, @@ -4483,7 +4586,7 @@ "name": "uniE930", "prevSize": 32, "code": 59696, - "tempChar": "" + "tempChar": "" }, { "order": 416, @@ -4491,7 +4594,7 @@ "name": "uniE92E", "prevSize": 32, "code": 59694, - "tempChar": "" + "tempChar": "" }, { "order": 415, @@ -4499,7 +4602,7 @@ "name": "uniE92F", "prevSize": 32, "code": 59695, - "tempChar": "" + "tempChar": "" }, { "order": 412, @@ -4507,7 +4610,7 @@ "name": "uniE910", "prevSize": 32, "code": 59664, - "tempChar": "" + "tempChar": "" }, { "order": 411, @@ -4515,7 +4618,7 @@ "name": "uniE915", "prevSize": 32, "code": 59669, - "tempChar": "" + "tempChar": "" }, { "order": 408, @@ -4523,7 +4626,7 @@ "name": "uniE90F", "prevSize": 32, "code": 59663, - "tempChar": "" + "tempChar": "" }, { "order": 407, @@ -4531,7 +4634,7 @@ "name": "uniE905", "prevSize": 32, "code": 59653, - "tempChar": "" + "tempChar": "" }, { "order": 406, @@ -4539,7 +4642,7 @@ "name": "uniE904", "prevSize": 32, "code": 59652, - "tempChar": "" + "tempChar": "" }, { "order": 405, @@ -4547,7 +4650,7 @@ "name": "uniE903", "prevSize": 32, "code": 59651, - "tempChar": "" + "tempChar": "" }, { "order": 404, @@ -4555,7 +4658,7 @@ "name": "uniE901", "prevSize": 32, "code": 59649, - "tempChar": "" + "tempChar": "" }, { "order": 400, @@ -4563,7 +4666,7 @@ "name": "uniE99A", "prevSize": 32, "code": 59802, - "tempChar": "" + "tempChar": "" }, { "order": 401, @@ -4571,7 +4674,7 @@ "name": "uniE783", "prevSize": 32, "code": 59267, - "tempChar": "" + "tempChar": "" }, { "order": 399, @@ -4579,7 +4682,7 @@ "name": "uniE919", "prevSize": 32, "code": 59673, - "tempChar": "" + "tempChar": "" }, { "order": 398, @@ -4587,7 +4690,7 @@ "name": "uniF12E", "prevSize": 32, "code": 61742, - "tempChar": "" + "tempChar": "" }, { "order": 390, @@ -4595,7 +4698,7 @@ "name": "uniF122", "prevSize": 32, "code": 61730, - "tempChar": "" + "tempChar": "" }, { "order": 386, @@ -4603,7 +4706,7 @@ "name": "ic_fluent_speaker_1_20_regular", "prevSize": 32, "code": 59795, - "tempChar": "" + "tempChar": "" }, { "order": 387, @@ -4611,7 +4714,7 @@ "name": "ic_fluent_speaker_2_20_regular", "prevSize": 32, "code": 59797, - "tempChar": "" + "tempChar": "" }, { "order": 382, @@ -4619,7 +4722,7 @@ "name": "uniEC42", "prevSize": 32, "code": 60482, - "tempChar": "" + "tempChar": "" }, { "order": 383, @@ -4627,7 +4730,7 @@ "name": "ic_fluent_add_circle_20_regular", "prevSize": 32, "code": 61796, - "tempChar": "" + "tempChar": "" }, { "order": 384, @@ -4635,7 +4738,7 @@ "name": "ic_fluent_subtract_circle_20_regular", "prevSize": 32, "code": 61798, - "tempChar": "" + "tempChar": "" }, { "order": 378, @@ -4643,7 +4746,7 @@ "name": "uniE72A", "prevSize": 32, "code": 59178, - "tempChar": "" + "tempChar": "" }, { "order": 377, @@ -4651,7 +4754,7 @@ "name": "uniE897", "prevSize": 32, "code": 59543, - "tempChar": "" + "tempChar": "" }, { "order": 372, @@ -4659,7 +4762,7 @@ "name": "uniE7AC", "prevSize": 32, "code": 59308, - "tempChar": "" + "tempChar": "" }, { "order": 373, @@ -4667,7 +4770,7 @@ "name": "uniE91D", "prevSize": 32, "code": 59677, - "tempChar": "" + "tempChar": "" }, { "order": 374, @@ -4675,7 +4778,7 @@ "name": "uniE93D", "prevSize": 32, "code": 59709, - "tempChar": "" + "tempChar": "" }, { "order": 371, @@ -4683,7 +4786,7 @@ "name": "uniEA1A", "prevSize": 32, "code": 59930, - "tempChar": "" + "tempChar": "" }, { "order": 264, @@ -4691,7 +4794,7 @@ "name": "uniE0E2", "prevSize": 32, "code": 57570, - "tempChar": "" + "tempChar": "" }, { "order": 265, @@ -4699,7 +4802,7 @@ "name": "uniE0E3", "prevSize": 32, "code": 57571, - "tempChar": "" + "tempChar": "" }, { "order": 266, @@ -4707,7 +4810,7 @@ "name": "uniE0E4", "prevSize": 32, "code": 57572, - "tempChar": "" + "tempChar": "" }, { "order": 267, @@ -4715,7 +4818,7 @@ "name": "uniE0E5", "prevSize": 32, "code": 57573, - "tempChar": "" + "tempChar": "" }, { "order": 268, @@ -4723,7 +4826,7 @@ "name": "uniE001", "prevSize": 32, "code": 57345, - "tempChar": "" + "tempChar": "" }, { "order": 269, @@ -4731,7 +4834,7 @@ "name": "uniE1C4", "prevSize": 32, "code": 57796, - "tempChar": "" + "tempChar": "" }, { "order": 270, @@ -4739,7 +4842,7 @@ "name": "uniE2B1", "prevSize": 32, "code": 58033, - "tempChar": "" + "tempChar": "" }, { "order": 271, @@ -4747,7 +4850,7 @@ "name": "uniE7A6", "prevSize": 32, "code": 59302, - "tempChar": "" + "tempChar": "" }, { "order": 272, @@ -4755,7 +4858,7 @@ "name": "uniE7A7", "prevSize": 32, "code": 59303, - "tempChar": "" + "tempChar": "" }, { "order": 273, @@ -4763,7 +4866,7 @@ "name": "uniE7A8", "prevSize": 32, "code": 59304, - "tempChar": "" + "tempChar": "" }, { "order": 274, @@ -4771,7 +4874,7 @@ "name": "ic_fluent_archive_20_regular", "prevSize": 32, "code": 59320, - "tempChar": "" + "tempChar": "" }, { "order": 275, @@ -4779,7 +4882,7 @@ "name": "uniE7C3", "prevSize": 32, "code": 59331, - "tempChar": "" + "tempChar": "" }, { "order": 276, @@ -4787,7 +4890,7 @@ "name": "uniE7ED", "prevSize": 32, "code": 59373, - "tempChar": "" + "tempChar": "" }, { "order": 277, @@ -4795,7 +4898,7 @@ "name": "ic_fluent_chat_empty_20_regular", "prevSize": 32, "code": 59581, - "tempChar": "" + "tempChar": "" }, { "order": 278, @@ -4803,7 +4906,7 @@ "name": "uniE8C6", "prevSize": 32, "code": 59590, - "tempChar": "" + "tempChar": "" }, { "order": 279, @@ -4811,7 +4914,7 @@ "name": "uniE8C8", "prevSize": 32, "code": 59592, - "tempChar": "" + "tempChar": "" }, { "order": 280, @@ -4819,7 +4922,7 @@ "name": "uniE8CB", "prevSize": 32, "code": 59595, - "tempChar": "" + "tempChar": "" }, { "order": 281, @@ -4827,7 +4930,7 @@ "name": "uniE8D2", "prevSize": 32, "code": 59602, - "tempChar": "" + "tempChar": "" }, { "order": 282, @@ -4835,7 +4938,7 @@ "name": "uniE8D6", "prevSize": 32, "code": 59606, - "tempChar": "" + "tempChar": "" }, { "order": 283, @@ -4843,7 +4946,7 @@ "name": "uniE8D9", "prevSize": 32, "code": 59609, - "tempChar": "" + "tempChar": "" }, { "order": 284, @@ -4851,7 +4954,7 @@ "name": "uniE8DB", "prevSize": 32, "code": 59611, - "tempChar": "" + "tempChar": "" }, { "order": 285, @@ -4859,7 +4962,7 @@ "name": "uniE8DC", "prevSize": 32, "code": 59612, - "tempChar": "" + "tempChar": "" }, { "order": 286, @@ -4867,7 +4970,7 @@ "name": "uniE8DD", "prevSize": 32, "code": 59613, - "tempChar": "" + "tempChar": "" }, { "order": 287, @@ -4875,7 +4978,7 @@ "name": "uniE8DE", "prevSize": 32, "code": 59614, - "tempChar": "" + "tempChar": "" }, { "order": 288, @@ -4883,7 +4986,7 @@ "name": "uniE8FA", "prevSize": 32, "code": 59642, - "tempChar": "" + "tempChar": "" }, { "order": 289, @@ -4891,7 +4994,7 @@ "name": "uniE9CE", "prevSize": 32, "code": 59854, - "tempChar": "" + "tempChar": "" }, { "order": 290, @@ -4899,7 +5002,7 @@ "name": "uniE9D9", "prevSize": 32, "code": 59865, - "tempChar": "" + "tempChar": "" }, { "order": 291, @@ -4907,7 +5010,7 @@ "name": "uniE9E9", "prevSize": 32, "code": 59881, - "tempChar": "" + "tempChar": "" }, { "order": 292, @@ -4915,7 +5018,7 @@ "name": "uniE10B", "prevSize": 32, "code": 57611, - "tempChar": "" + "tempChar": "" }, { "order": 511, @@ -4923,7 +5026,7 @@ "name": "uniE10C", "prevSize": 32, "code": 57612, - "tempChar": "" + "tempChar": "" }, { "order": 294, @@ -4931,7 +5034,7 @@ "name": "uniE71B", "prevSize": 32, "code": 59163, - "tempChar": "" + "tempChar": "" }, { "order": 295, @@ -4939,7 +5042,7 @@ "name": "uniE71F", "prevSize": 32, "code": 59167, - "tempChar": "" + "tempChar": "" }, { "order": 296, @@ -4947,7 +5050,7 @@ "name": "uniE72B", "prevSize": 32, "code": 59179, - "tempChar": "" + "tempChar": "" }, { "order": 298, @@ -4955,7 +5058,7 @@ "name": "uniE72E", "prevSize": 32, "code": 59182, - "tempChar": "" + "tempChar": "" }, { "order": 299, @@ -4963,7 +5066,7 @@ "name": "uniE73E", "prevSize": 32, "code": 59198, - "tempChar": "" + "tempChar": "" }, { "order": 300, @@ -4971,7 +5074,7 @@ "name": "uniE74B", "prevSize": 32, "code": 59211, - "tempChar": "" + "tempChar": "" }, { "order": 301, @@ -4979,7 +5082,7 @@ "name": "uniE74D", "prevSize": 32, "code": 59213, - "tempChar": "" + "tempChar": "" }, { "order": 302, @@ -4987,7 +5090,7 @@ "name": "uniE75C", "prevSize": 32, "code": 59228, - "tempChar": "" + "tempChar": "" }, { "order": 303, @@ -4995,7 +5098,7 @@ "name": "uniE76E", "prevSize": 32, "code": 59246, - "tempChar": "" + "tempChar": "" }, { "order": 304, @@ -5003,7 +5106,7 @@ "name": "uniE77A", "prevSize": 32, "code": 59258, - "tempChar": "" + "tempChar": "" }, { "order": 305, @@ -5011,7 +5114,7 @@ "name": "uniE77B", "prevSize": 32, "code": 59259, - "tempChar": "" + "tempChar": "" }, { "order": 306, @@ -5019,7 +5122,7 @@ "name": "uniE77F", "prevSize": 32, "code": 59263, - "tempChar": "" + "tempChar": "" }, { "order": 307, @@ -5027,7 +5130,7 @@ "name": "uniE81C", "prevSize": 32, "code": 59420, - "tempChar": "" + "tempChar": "" }, { "order": 308, @@ -5035,7 +5138,7 @@ "name": "tl_fluent_chat_unread_20_regular", "prevSize": 32, "code": 59676, - "tempChar": "", + "tempChar": "", "codes": [ 59676 ] @@ -5046,7 +5149,7 @@ "name": "uniE91F", "prevSize": 32, "code": 59679, - "tempChar": "" + "tempChar": "" }, { "order": 310, @@ -5054,7 +5157,7 @@ "name": "uniE92B", "prevSize": 32, "code": 59691, - "tempChar": "" + "tempChar": "" }, { "order": 311, @@ -5062,7 +5165,7 @@ "name": "uniE104", "prevSize": 32, "code": 57604, - "tempChar": "" + "tempChar": "" }, { "order": 312, @@ -5070,7 +5173,7 @@ "name": "uniE118", "prevSize": 32, "code": 57624, - "tempChar": "" + "tempChar": "" }, { "order": 313, @@ -5078,7 +5181,7 @@ "name": "uniE168", "prevSize": 32, "code": 57704, - "tempChar": "" + "tempChar": "" }, { "order": 314, @@ -5086,7 +5189,7 @@ "name": "uniE192", "prevSize": 32, "code": 57746, - "tempChar": "" + "tempChar": "" }, { "order": 316, @@ -5094,7 +5197,7 @@ "name": "uniE610", "prevSize": 32, "code": 58896, - "tempChar": "" + "tempChar": "" }, { "order": 317, @@ -5102,7 +5205,7 @@ "name": "ic_fluent_navigation_20_regular", "prevSize": 32, "code": 59136, - "tempChar": "" + "tempChar": "" }, { "order": 318, @@ -5110,7 +5213,7 @@ "name": "uniE710", "prevSize": 32, "code": 59152, - "tempChar": "" + "tempChar": "" }, { "order": 319, @@ -5118,7 +5221,7 @@ "name": "uniE711", "prevSize": 32, "code": 59153, - "tempChar": "" + "tempChar": "" }, { "order": 320, @@ -5126,7 +5229,7 @@ "name": "uniE713", "prevSize": 32, "code": 59155, - "tempChar": "" + "tempChar": "" }, { "order": 321, @@ -5134,7 +5237,7 @@ "name": "uniE714", "prevSize": 32, "code": 59156, - "tempChar": "" + "tempChar": "" }, { "order": 322, @@ -5142,7 +5245,7 @@ "name": "uniE716", "prevSize": 32, "code": 59158, - "tempChar": "" + "tempChar": "" }, { "order": 323, @@ -5150,7 +5253,7 @@ "name": "uniE717", "prevSize": 32, "code": 59159, - "tempChar": "" + "tempChar": "" }, { "order": 324, @@ -5158,7 +5261,7 @@ "name": "uniE720", "prevSize": 32, "code": 59168, - "tempChar": "" + "tempChar": "" }, { "order": 325, @@ -5166,7 +5269,7 @@ "name": "uniE721", "prevSize": 32, "code": 59169, - "tempChar": "" + "tempChar": "" }, { "order": 326, @@ -5174,7 +5277,7 @@ "name": "uniE722", "prevSize": 32, "code": 59170, - "tempChar": "" + "tempChar": "" }, { "order": 327, @@ -5182,7 +5285,7 @@ "name": "uniE730", "prevSize": 32, "code": 59184, - "tempChar": "" + "tempChar": "" }, { "order": 328, @@ -5190,7 +5293,7 @@ "name": "uniE734", "prevSize": 32, "code": 59188, - "tempChar": "" + "tempChar": "" }, { "order": 329, @@ -5198,7 +5301,7 @@ "name": "uniE735", "prevSize": 32, "code": 59189, - "tempChar": "" + "tempChar": "" }, { "order": 330, @@ -5206,7 +5309,7 @@ "name": "uniE762", "prevSize": 32, "code": 59234, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -5230,7 +5333,7 @@ "name": "uniE774", "prevSize": 32, "code": 59252, - "tempChar": "" + "tempChar": "" }, { "order": 334, @@ -5238,7 +5341,7 @@ "name": "uniE785", "prevSize": 32, "code": 59269, - "tempChar": "" + "tempChar": "" }, { "order": 335, @@ -5246,7 +5349,7 @@ "name": "uniE787", "prevSize": 32, "code": 59271, - "tempChar": "" + "tempChar": "" }, { "order": 336, @@ -5254,7 +5357,7 @@ "name": "uniE789", "prevSize": 32, "code": 59273, - "tempChar": "" + "tempChar": "" }, { "order": 337, @@ -5262,7 +5365,7 @@ "name": "uniE792", "prevSize": 32, "code": 59282, - "tempChar": "" + "tempChar": "" }, { "order": 338, @@ -5270,7 +5373,7 @@ "name": "uniE825", "prevSize": 32, "code": 59429, - "tempChar": "" + "tempChar": "" }, { "order": 339, @@ -5278,7 +5381,7 @@ "name": "uniE838", "prevSize": 32, "code": 59448, - "tempChar": "" + "tempChar": "" }, { "order": 340, @@ -5286,7 +5389,7 @@ "name": "uniE840", "prevSize": 32, "code": 59456, - "tempChar": "" + "tempChar": "" }, { "order": 341, @@ -5294,7 +5397,7 @@ "name": "uniE892", "prevSize": 32, "code": 59538, - "tempChar": "" + "tempChar": "" }, { "order": 342, @@ -5302,7 +5405,7 @@ "name": "uniE893", "prevSize": 32, "code": 59539, - "tempChar": "" + "tempChar": "" }, { "order": 343, @@ -5310,7 +5413,7 @@ "name": "uniE902", "prevSize": 32, "code": 59650, - "tempChar": "" + "tempChar": "" }, { "order": 344, @@ -5318,7 +5421,7 @@ "name": "uniE907", "prevSize": 32, "code": 59655, - "tempChar": "" + "tempChar": "" }, { "order": 345, @@ -5326,7 +5429,7 @@ "name": "uniE909", "prevSize": 32, "code": 59657, - "tempChar": "" + "tempChar": "" }, { "order": 346, @@ -5334,7 +5437,7 @@ "name": "uniEA19", "prevSize": 32, "code": 59929, - "tempChar": "" + "tempChar": "" }, { "order": 347, @@ -5342,7 +5445,7 @@ "name": "uniE916", "prevSize": 32, "code": 59670, - "tempChar": "" + "tempChar": "" }, { "order": 348, @@ -5350,7 +5453,7 @@ "name": "uniE917", "prevSize": 32, "code": 59671, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -5366,7 +5469,7 @@ "name": "uniE929", "prevSize": 32, "code": 59689, - "tempChar": "" + "tempChar": "" }, { "order": 351, @@ -5374,7 +5477,7 @@ "name": "uniE932", "prevSize": 32, "code": 59698, - "tempChar": "" + "tempChar": "" }, { "order": 352, @@ -5382,7 +5485,7 @@ "name": "uniE943", "prevSize": 32, "code": 59715, - "tempChar": "" + "tempChar": "" }, { "order": 385, @@ -5390,7 +5493,7 @@ "name": "ic_fluent_speaker_off_20_regular", "prevSize": 32, "code": 59215, - "tempChar": "" + "tempChar": "" }, { "order": 353, @@ -5398,7 +5501,7 @@ "name": "uniE946", "prevSize": 32, "code": 59718, - "tempChar": "" + "tempChar": "" }, { "order": 354, @@ -5406,7 +5509,7 @@ "name": "uniE975", "prevSize": 32, "code": 59765, - "tempChar": "" + "tempChar": "" }, { "order": 355, @@ -5414,7 +5517,7 @@ "name": "uniEA8F", "prevSize": 32, "code": 60047, - "tempChar": "" + "tempChar": "" }, { "order": 356, @@ -5422,7 +5525,7 @@ "name": "uniEA37", "prevSize": 32, "code": 59959, - "tempChar": "" + "tempChar": "" }, { "order": 357, @@ -5430,7 +5533,7 @@ "name": "uniEA80", "prevSize": 32, "code": 60032, - "tempChar": "" + "tempChar": "" }, { "order": 358, @@ -5438,7 +5541,7 @@ "name": "uniEA99", "prevSize": 32, "code": 60057, - "tempChar": "" + "tempChar": "" }, { "order": 359, @@ -5446,7 +5549,7 @@ "name": "uniEB05", "prevSize": 32, "code": 60165, - "tempChar": "" + "tempChar": "" }, { "order": 360, @@ -5454,7 +5557,7 @@ "name": "uniEB9F", "prevSize": 32, "code": 60319, - "tempChar": "" + "tempChar": "" }, { "order": 361, @@ -5462,7 +5565,7 @@ "name": "uniEC61", "prevSize": 32, "code": 60513, - "tempChar": "" + "tempChar": "" }, { "order": 362, @@ -5470,7 +5573,7 @@ "name": "uniED15", "prevSize": 32, "code": 60693, - "tempChar": "" + "tempChar": "" }, { "order": 363, @@ -5478,7 +5581,7 @@ "name": "uniEE56", "prevSize": 32, "code": 61014, - "tempChar": "" + "tempChar": "" }, { "order": 364, @@ -5486,7 +5589,7 @@ "name": "uniF0E3", "prevSize": 32, "code": 61667, - "tempChar": "" + "tempChar": "" }, { "order": 365, @@ -5494,7 +5597,7 @@ "name": "uniF3B1", "prevSize": 32, "code": 62385, - "tempChar": "" + "tempChar": "" }, { "order": 366, @@ -5502,7 +5605,7 @@ "name": "uniF4A9", "prevSize": 32, "code": 62633, - "tempChar": "" + "tempChar": "" }, { "order": 367, @@ -5510,7 +5613,7 @@ "name": "uniF4AA", "prevSize": 32, "code": 62634, - "tempChar": "" + "tempChar": "" }, { "order": 368, @@ -5518,7 +5621,7 @@ "name": "uniF12B", "prevSize": 32, "code": 61739, - "tempChar": "" + "tempChar": "" }, { "order": 369, @@ -5526,7 +5629,7 @@ "name": "uniF61B", "prevSize": 32, "code": 63003, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -5548,6 +5651,81 @@ "height": 1024, "prevSize": 32, "icons": [ + { + "id": 340, + "paths": [ + "M512 102.4c226.212 0 409.595 183.39 409.6 409.6 0 126.73-76.17 204.749-166.4 204.749-52.588 0-100.357-26.542-131.098-73.748-31.944 44.268-80.236 73.8-137.702 73.8-104.733 0-179.2-97.956-179.2-204.8s74.467-204.8 179.2-204.8c39.158 0 74.066 13.719 102.451 36.45 1.014-20.301 17.797-36.45 38.349-36.45 21.207 0 38.4 17.192 38.4 38.4v166.4c0 95.089 51.82 127.944 89.6 127.949 37.78 0 89.6-32.855 89.6-127.949-0.005-183.795-149.002-332.8-332.8-332.8-183.796 0-332.793 149.005-332.8 332.8 0.007 183.793 149.004 332.8 332.8 332.8 34.575 0 67.907-5.335 99.251-15.15 15.299-4.787 32.256-1.531 43.597 9.8 19.343 19.338 13.911 51.942-11.996 60.703-41.088 13.885-85.079 21.448-130.852 21.448-226.212 0-409.593-183.388-409.6-409.6 0.007-226.21 183.388-409.6 409.6-409.6zM486.4 384c-50.791 0-102.4 51.044-102.4 128 0 76.954 51.609 128 102.4 128s102.4-51.046 102.4-128c0-76.956-51.61-128-102.4-128z" + ], + "attrs": [ + {} + ], + "isMulticolor": false, + "isMulticolor2": false, + "grid": 0, + "tags": [ + "ic_fluent_mention_20_filled" + ] + }, + { + "id": 339, + "paths": [ + "M512 102.4c-56.554 0-102.4 45.846-102.4 102.4v614.4c0 56.556 45.846 102.4 102.4 102.4 56.556 0 102.4-45.844 102.4-102.4v-614.4c0-56.554-45.844-102.4-102.4-102.4zM204.8 512c-56.554 0-102.4 45.844-102.4 102.4v204.8c0 56.556 45.846 102.4 102.4 102.4s102.4-45.844 102.4-102.4v-204.8c0-56.556-45.846-102.4-102.4-102.4zM819.2 307.2c-56.556 0-102.4 45.846-102.4 102.4v409.6c0 56.556 45.844 102.4 102.4 102.4s102.4-45.844 102.4-102.4v-409.6c0-56.554-45.844-102.4-102.4-102.4z" + ], + "attrs": [ + {} + ], + "isMulticolor": false, + "isMulticolor2": false, + "grid": 0, + "tags": [ + "ic_fluent_poll_20_filled" + ] + }, + { + "id": 338, + "paths": [ + "M256.001 307.2c0-113.108 91.693-204.8 204.802-204.8s204.803 91.692 204.803 204.8c0 61.168-26.819 116.073-69.335 153.6h-6.799c-41.129 0-77.75 19.319-101.306 49.388-8.951 1.195-18.084 1.812-27.362 1.812-113.108 0-204.802-91.692-204.802-204.8zM460.803 153.6c-84.832 0-153.601 68.769-153.601 153.6s68.769 153.6 153.601 153.6c84.831 0 153.603-68.769 153.603-153.6s-68.772-153.6-153.603-153.6zM463.506 563.2h-258.259c-56.606 0-102.847 45.409-102.847 102.4 0 86.589 42.64 151.875 109.313 194.386 65.637 41.851 154.126 61.614 249.090 61.614 41.124 0 81.032-3.707 118.397-11.305l-43.699-44.6c-23.765 3.118-48.766 4.705-74.698 4.705-88.838 0-166.75-18.637-221.563-53.586-53.778-34.289-85.639-84.204-85.639-151.214 0-28.329 22.93-51.2 51.647-51.2h255.549v-24.776c0-9.057 0.933-17.894 2.71-26.424zM511.997 736.804c0 20.27 7.939 39.736 22.116 54.205l155.346 158.592c29.686 30.3 78.198 31.012 108.754 1.592l150.866-145.27c31.104-29.952 31.698-79.611 1.316-110.3l-159.104-160.717c-14.515-14.659-34.278-22.907-54.892-22.907h-147.108c-42.691 0-77.295 34.657-77.295 77.404v147.4zM652.805 691.2c-21.207 0-38.4-17.193-38.4-38.4s17.193-38.4 38.4-38.4c21.207 0 38.4 17.193 38.4 38.4s-17.193 38.4-38.4 38.4z" + ], + "attrs": [ + {} + ], + "isMulticolor": false, + "isMulticolor2": false, + "grid": 0, + "tags": [ + "ic_fluent_person_tag_20_regular" + ] + }, + { + "id": 337, + "paths": [ + "M146.102 109.898c-9.997-9.998-26.206-9.998-36.204 0s-9.998 26.206 0 36.204l376.368 376.369-0.071 209.024-186.652-186.414-3.548-2.959c-9.982-6.907-23.776-5.908-32.656 2.985-9.991 10.004-9.979 26.214 0.026 36.204l228.18 227.937c4.68 6.047 12.012 9.948 20.253 9.948l5.428-0.502c4.792-0.957 9.364-3.297 13.071-7.014l122.476-122.701 225.121 225.126c9.999 9.994 26.209 9.994 36.209 0 9.994-9.999 9.994-26.209 0-36.209l-768.003-767.997zM616.515 652.718l-79.119 79.186 0.051-158.249 79.068 79.063zM725.11 616.509l-36.224-36.219 35.154-35.185c8.878-8.893 22.671-9.892 32.655-2.99l3.548 2.959c8.893 8.878 9.897 22.671 2.995 32.655l-2.959 3.548-35.169 35.231zM486.316 377.715l51.182 51.183 0.102-300.84-0.41-4.602c-2.166-11.943-12.616-21.005-25.185-21.005-14.136 0-25.601 11.454-25.605 25.592l-0.084 249.673zM793.6 870.339c14.136 0 25.6 11.459 25.6 25.6 0 12.564-9.057 23.020-20.997 25.185l-4.603 0.415h-563.2c-14.138 0-25.6-11.464-25.6-25.6 0-12.57 9.056-23.020 20.998-25.19l4.602-0.41h563.2z" + ], + "attrs": [ + {} + ], + "isMulticolor": false, + "isMulticolor2": false, + "grid": 0, + "tags": [ + "ic_fluent_arrow_download_off_20_regular" + ] + }, + { + "id": 336, + "paths": [ + "M179.283 215.487l-69.385-69.386c-9.998-9.997-9.998-26.206 0-36.204s26.206-9.998 36.204 0l768.003 767.997c9.994 9.999 9.994 26.209 0 36.209-9.999 9.994-26.209 9.994-36.209 0l-48.655-48.66c-11.244 3.226-23.122 4.956-35.405 4.956h-563.198c-70.692 0-128-57.308-128-128v-409.631c0-52.429 31.521-97.495 76.646-117.282zM782.996 819.2l-145.413-145.413c-34.678 26.962-78.259 43.013-125.586 43.013-113.108 0-204.8-91.689-204.8-204.8 0-47.327 16.054-90.905 43.014-125.585l-129.774-129.774c-37.594 4.989-66.599 37.172-66.599 76.129v409.631c0 42.414 34.384 76.8 76.8 76.8h552.359zM601.001 637.204l-214.205-214.205c-17.882 25.11-28.399 55.827-28.399 89 0 84.833 68.769 153.6 153.6 153.6 33.176 0 63.89-10.516 89.004-28.396zM432.019 323.406l40.197 40.197c12.688-3.393 26.023-5.201 39.781-5.201 84.831 0 153.598 68.769 153.598 153.598 0 13.757-1.807 27.095-5.202 39.782l40.197 40.197c10.435-24.571 16.205-51.599 16.205-79.98 0-113.106-91.689-204.798-204.798-204.798-28.378 0-55.407 5.771-79.978 16.205zM870.636 742.4c0 6.057-0.696 11.95-2.022 17.597l39.711 39.711c8.648-17.239 13.512-36.705 13.512-57.308v-409.631c0-70.692-57.303-128-128-128h-86.523l-29.947-59.909c-13.010-26.022-39.603-42.46-68.695-42.46h-192.729c-29.033 0-55.584 16.372-68.621 42.313l-30.182 60.056h-3.757l40.418 40.419c0.742-1.046 1.411-2.156 1.998-3.323l37.27-74.16c4.346-8.647 13.196-14.105 22.874-14.105h192.729c9.697 0 18.56 5.479 22.897 14.153l37.023 74.062c4.337 8.674 13.199 14.154 22.897 14.154h102.349c42.419 0 76.8 34.384 76.8 76.8v409.631z" + ], + "attrs": [ + {} + ], + "isMulticolor": false, + "isMulticolor2": false, + "grid": 0, + "tags": [ + "ic_fluent_camera_off_20_regular" + ] + }, { "id": 335, "paths": [ @@ -6907,7 +7085,9 @@ "paths": [ "M480.688 219.629c-86.817-87.69-227.271-88.117-313.713-0.805s-86.020 229.178 0.797 316.867l321.377 324.613c13.33 13.46 34.945 13.46 48.272 0l319.708-322.734c86.241-87.595 85.97-229.064-0.865-316.77-86.973-87.848-227.492-88.274-314.086-0.807l-30.536 30.901-30.953-31.264z" ], - "attrs": [], + "attrs": [ + {} + ], "isMulticolor": false, "isMulticolor2": false, "grid": 0, @@ -10269,7 +10449,7 @@ "name": "AirplaneFilled24", "prevSize": 32, "code": 59857, - "tempChar": "" + "tempChar": "" }, { "order": 647, @@ -10277,7 +10457,7 @@ "name": "ic_fluent_clipboard_text_ltr_24_filled", "prevSize": 32, "code": 59855, - "tempChar": "" + "tempChar": "" }, { "order": 648, @@ -10285,7 +10465,7 @@ "name": "ic_fluent_clipboard_text_ltr_24_regular", "prevSize": 32, "code": 59856, - "tempChar": "" + "tempChar": "" }, { "order": 644, @@ -10296,7 +10476,7 @@ "codes": [ 59840 ], - "tempChar": "" + "tempChar": "" }, { "order": 645, @@ -10307,7 +10487,7 @@ "codes": [ 59841 ], - "tempChar": "" + "tempChar": "" }, { "order": 642, @@ -10315,7 +10495,7 @@ "name": "ic_fluent_paint_brush_24_filled", "prevSize": 32, "code": 59842, - "tempChar": "" + "tempChar": "" }, { "order": 643, @@ -10323,7 +10503,7 @@ "name": "ic_fluent_paint_brush_24_regular", "prevSize": 32, "code": 59843, - "tempChar": "" + "tempChar": "" }, { "order": 640, @@ -10331,7 +10511,7 @@ "name": "ic_fluent_music_note_1_24_filled", "prevSize": 32, "code": 59844, - "tempChar": "" + "tempChar": "" }, { "order": 641, @@ -10339,7 +10519,7 @@ "name": "ic_fluent_music_note_1_24_regular", "prevSize": 32, "code": 59845, - "tempChar": "" + "tempChar": "" }, { "order": 638, @@ -10347,7 +10527,7 @@ "name": "ic_fluent_thumb_like_24_filled", "prevSize": 32, "code": 59846, - "tempChar": "" + "tempChar": "" }, { "order": 639, @@ -10355,7 +10535,7 @@ "name": "ic_fluent_thumb_like_24_regular", "prevSize": 32, "code": 59847, - "tempChar": "" + "tempChar": "" }, { "order": 636, @@ -10363,7 +10543,7 @@ "name": "ic_fluent_lightbulb_24_filled", "prevSize": 32, "code": 59848, - "tempChar": "" + "tempChar": "" }, { "order": 637, @@ -10371,7 +10551,7 @@ "name": "ic_fluent_lightbulb_24_regular", "prevSize": 32, "code": 59849, - "tempChar": "" + "tempChar": "" }, { "order": 634, @@ -10379,7 +10559,7 @@ "name": "ic_fluent_money_24_filled", "prevSize": 32, "code": 59850, - "tempChar": "" + "tempChar": "" }, { "order": 635, @@ -10387,7 +10567,7 @@ "name": "ic_fluent_money_24_regular", "prevSize": 32, "code": 59851, - "tempChar": "" + "tempChar": "" }, { "order": 632, @@ -10395,7 +10575,7 @@ "name": "ic_fluent_book_open_24_filled", "prevSize": 32, "code": 59852, - "tempChar": "" + "tempChar": "" }, { "order": 633, @@ -10403,7 +10583,7 @@ "name": "ic_fluent_book_open_24_regular", "prevSize": 32, "code": 59853, - "tempChar": "" + "tempChar": "" }, { "order": 589, @@ -10411,7 +10591,7 @@ "name": "mask_filled_1", "prevSize": 32, "code": 59716, - "tempChar": "" + "tempChar": "" }, { "order": 590, @@ -10419,7 +10599,7 @@ "name": "mask_outline_1", "prevSize": 32, "code": 59717, - "tempChar": "" + "tempChar": "" }, { "order": 583, @@ -10427,7 +10607,7 @@ "name": "ic_fluent_folder_24_filled", "prevSize": 32, "code": 59745, - "tempChar": "" + "tempChar": "" }, { "order": 584, @@ -10435,7 +10615,7 @@ "name": "ic_fluent_folder_24_regular", "prevSize": 32, "code": 59746, - "tempChar": "" + "tempChar": "" }, { "order": 581, @@ -10443,7 +10623,7 @@ "name": "ic_fluent_person_24_filled", "prevSize": 32, "code": 59743, - "tempChar": "" + "tempChar": "" }, { "order": 582, @@ -10451,7 +10631,7 @@ "name": "ic_fluent_person_24_regular", "prevSize": 32, "code": 59744, - "tempChar": "" + "tempChar": "" }, { "order": 579, @@ -10459,7 +10639,7 @@ "name": "ic_fluent_people_24_filled", "prevSize": 32, "code": 59741, - "tempChar": "" + "tempChar": "" }, { "order": 580, @@ -10467,7 +10647,7 @@ "name": "ic_fluent_people_24_regular", "prevSize": 32, "code": 59742, - "tempChar": "" + "tempChar": "" }, { "order": 577, @@ -10475,7 +10655,7 @@ "name": "ic_fluent_megaphone_24_filled", "prevSize": 32, "code": 59739, - "tempChar": "" + "tempChar": "" }, { "order": 578, @@ -10483,7 +10663,7 @@ "name": "ic_fluent_megaphone_24_regular", "prevSize": 32, "code": 59740, - "tempChar": "" + "tempChar": "" }, { "order": 575, @@ -10491,7 +10671,7 @@ "name": "ic_fluent_bot_24_filled", "prevSize": 32, "code": 59737, - "tempChar": "" + "tempChar": "" }, { "order": 576, @@ -10499,7 +10679,7 @@ "name": "ic_fluent_bot_24_regular", "prevSize": 32, "code": 59738, - "tempChar": "" + "tempChar": "" }, { "order": 573, @@ -10507,7 +10687,7 @@ "name": "ic_fluent_alert_24_filled", "prevSize": 32, "code": 59735, - "tempChar": "" + "tempChar": "" }, { "order": 574, @@ -10515,7 +10695,7 @@ "name": "ic_fluent_alert_24_regular", "prevSize": 32, "code": 59736, - "tempChar": "" + "tempChar": "" }, { "order": 571, @@ -10523,7 +10703,7 @@ "name": "ic_fluent_chat_multiple_24_filled", "prevSize": 32, "code": 59731, - "tempChar": "" + "tempChar": "" }, { "order": 572, @@ -10531,7 +10711,7 @@ "name": "ic_fluent_chat_multiple_24_regular", "prevSize": 32, "code": 59732, - "tempChar": "" + "tempChar": "" }, { "order": 569, @@ -10539,7 +10719,7 @@ "name": "ic_fluent_briefcase_24_filled", "prevSize": 32, "code": 59729, - "tempChar": "" + "tempChar": "" }, { "order": 570, @@ -10547,7 +10727,7 @@ "name": "ic_fluent_briefcase_24_regular", "prevSize": 32, "code": 59730, - "tempChar": "" + "tempChar": "" }, { "order": 567, @@ -10555,7 +10735,7 @@ "name": "ic_fluent_airplane_24_filled", "prevSize": 32, "code": 59727, - "tempChar": "" + "tempChar": "" }, { "order": 568, @@ -10563,7 +10743,7 @@ "name": "ic_fluent_airplane_24_regular", "prevSize": 32, "code": 59728, - "tempChar": "" + "tempChar": "" }, { "order": 565, @@ -10571,7 +10751,7 @@ "name": "ic_fluent_arrow_trending_lines_24_filled", "prevSize": 32, "code": 59725, - "tempChar": "" + "tempChar": "" }, { "order": 566, @@ -10579,7 +10759,7 @@ "name": "ic_fluent_arrow_trending_lines_24_regular", "prevSize": 32, "code": 59726, - "tempChar": "" + "tempChar": "" }, { "order": 563, @@ -10587,7 +10767,7 @@ "name": "ic_fluent_hat_graduation_24_filled", "prevSize": 32, "code": 59723, - "tempChar": "" + "tempChar": "" }, { "order": 564, @@ -10595,7 +10775,7 @@ "name": "ic_fluent_hat_graduation_24_regular", "prevSize": 32, "code": 59724, - "tempChar": "" + "tempChar": "" }, { "order": 561, @@ -10603,7 +10783,7 @@ "name": "ic_fluent_sport_soccer_24_filled", "prevSize": 32, "code": 59721, - "tempChar": "" + "tempChar": "" }, { "order": 562, @@ -10611,7 +10791,7 @@ "name": "ic_fluent_sport_soccer_24_regular", "prevSize": 32, "code": 59722, - "tempChar": "" + "tempChar": "" }, { "order": 559, @@ -10619,7 +10799,7 @@ "name": "ic_fluent_drink_wine_24_filled", "prevSize": 32, "code": 59719, - "tempChar": "" + "tempChar": "" }, { "order": 560, @@ -10627,7 +10807,7 @@ "name": "ic_fluent_drink_wine_24_regular", "prevSize": 32, "code": 59720, - "tempChar": "" + "tempChar": "" }, { "order": 555, @@ -10635,7 +10815,7 @@ "name": "ic_fluent_heart_24_filled", "prevSize": 32, "code": 59713, - "tempChar": "" + "tempChar": "" }, { "order": 556, @@ -10643,7 +10823,7 @@ "name": "ic_fluent_heart_24_regular", "prevSize": 32, "code": 59714, - "tempChar": "" + "tempChar": "" }, { "order": 553, @@ -10651,7 +10831,7 @@ "name": "ic_fluent_home_24_filled", "prevSize": 32, "code": 59708, - "tempChar": "" + "tempChar": "" }, { "order": 554, @@ -10659,7 +10839,7 @@ "name": "ic_fluent_home_24_regular", "prevSize": 32, "code": 59712, - "tempChar": "" + "tempChar": "" }, { "order": 551, @@ -10667,7 +10847,7 @@ "name": "ic_fluent_games_24_filled", "prevSize": 32, "code": 59706, - "tempChar": "" + "tempChar": "" }, { "order": 552, @@ -10675,7 +10855,7 @@ "name": "ic_fluent_games_24_regular", "prevSize": 32, "code": 59707, - "tempChar": "" + "tempChar": "" }, { "order": 549, @@ -10683,7 +10863,7 @@ "name": "ic_fluent_leaf_one_24_filled", "prevSize": 32, "code": 59704, - "tempChar": "" + "tempChar": "" }, { "order": 550, @@ -10691,7 +10871,7 @@ "name": "ic_fluent_leaf_one_24_regular", "prevSize": 32, "code": 59705, - "tempChar": "" + "tempChar": "" }, { "order": 547, @@ -10699,7 +10879,7 @@ "name": "ic_fluent_star_24_filled", "prevSize": 32, "code": 59702, - "tempChar": "" + "tempChar": "" }, { "order": 548, @@ -10707,7 +10887,7 @@ "name": "ic_fluent_star_24_regular", "prevSize": 32, "code": 59703, - "tempChar": "" + "tempChar": "" }, { "order": 545, @@ -10715,7 +10895,7 @@ "name": "ic_fluent_trophy_24_filled", "prevSize": 32, "code": 59700, - "tempChar": "" + "tempChar": "" }, { "order": 546, @@ -10723,7 +10903,7 @@ "name": "ic_fluent_trophy_24_regular", "prevSize": 32, "code": 59701, - "tempChar": "" + "tempChar": "" }, { "order": 543, @@ -10731,7 +10911,7 @@ "name": "ic_fluent_animal_cat_24_filled", "prevSize": 32, "code": 59697, - "tempChar": "" + "tempChar": "" }, { "order": 544, @@ -10739,7 +10919,7 @@ "name": "ic_fluent_animal_cat_24_regular", "prevSize": 32, "code": 59699, - "tempChar": "" + "tempChar": "" }, { "order": 541, @@ -10747,7 +10927,7 @@ "name": "ic_fluent_call_24_filled", "prevSize": 32, "code": 59792, - "tempChar": "" + "tempChar": "" }, { "order": 542, @@ -10755,7 +10935,7 @@ "name": "ic_fluent_call_24_regular", "prevSize": 32, "code": 59793, - "tempChar": "" + "tempChar": "" }, { "order": 539, @@ -10763,7 +10943,7 @@ "name": "ic_fluent_settings_24_filled", "prevSize": 32, "code": 59790, - "tempChar": "" + "tempChar": "" }, { "order": 540, @@ -10771,7 +10951,7 @@ "name": "ic_fluent_settings_24_regular", "prevSize": 32, "code": 59791, - "tempChar": "" + "tempChar": "" } ], "id": 5, @@ -11682,7 +11862,7 @@ "name": "ic_fluent_clock_20_regular", "prevSize": 32, "code": 59665, - "tempChar": "" + "tempChar": "" }, { "order": 423, @@ -11690,7 +11870,7 @@ "name": "ic_fluent_emoji_20_regular", "prevSize": 32, "code": 59680, - "tempChar": "" + "tempChar": "" }, { "order": 424, @@ -11698,7 +11878,7 @@ "name": "ic_fluent_animal_cat_20_regular", "prevSize": 32, "code": 59681, - "tempChar": "" + "tempChar": "" }, { "order": 421, @@ -11706,7 +11886,7 @@ "name": "ic_fluent_food_pizza_20_regular", "prevSize": 32, "code": 59682, - "tempChar": "" + "tempChar": "" }, { "order": 420, @@ -11714,7 +11894,7 @@ "name": "ic_fluent_sport_soccer_20_regular", "prevSize": 32, "code": 59683, - "tempChar": "" + "tempChar": "" }, { "order": 425, @@ -11722,7 +11902,7 @@ "name": "ic_fluent_vehicle_car_20_regular", "prevSize": 32, "code": 59684, - "tempChar": "" + "tempChar": "" }, { "order": 419, @@ -11730,7 +11910,7 @@ "name": "ic_fluent_lightbulb_filament_20_regular", "prevSize": 32, "code": 59685, - "tempChar": "" + "tempChar": "" }, { "order": 418, @@ -11738,7 +11918,7 @@ "name": "ic_fluent_symbols_20_regular", "prevSize": 32, "code": 59686, - "tempChar": "" + "tempChar": "" }, { "order": 422, @@ -11746,7 +11926,7 @@ "name": "ic_fluent_flag_20_regular", "prevSize": 32, "code": 59687, - "tempChar": "" + "tempChar": "" } ], "id": 3, @@ -11907,13 +12087,21 @@ }, { "selection": [ + { + "order": 1022, + "id": 188, + "name": "tl_fluent_arrow_forward_off_20_regular", + "prevSize": 32, + "code": 60156, + "tempChar": "" + }, { "order": 1015, "id": 187, "name": "tl_fluent_key_add_20_regular", "prevSize": 32, "code": 60149, - "tempChar": "" + "tempChar": "" }, { "order": 1011, @@ -11921,7 +12109,7 @@ "name": "tl_fluent_passkey_20_regular", "prevSize": 32, "code": 60145, - "tempChar": "" + "tempChar": "" }, { "order": 1005, @@ -11929,7 +12117,7 @@ "name": "tl_fluent_crown_1_18_filled", "prevSize": 32, "code": 60139, - "tempChar": "" + "tempChar": "" }, { "order": 1006, @@ -11937,7 +12125,7 @@ "name": "tl_fluent_crown_2_18_filled", "prevSize": 32, "code": 60140, - "tempChar": "" + "tempChar": "" }, { "order": 1007, @@ -11945,7 +12133,7 @@ "name": "tl_fluent_crown_3_18_filled", "prevSize": 32, "code": 60141, - "tempChar": "" + "tempChar": "" }, { "order": 1003, @@ -11953,7 +12141,7 @@ "name": "tl_fluent_view_once_20_filled", "prevSize": 32, "code": 60137, - "tempChar": "" + "tempChar": "" }, { "order": 1002, @@ -11961,7 +12149,7 @@ "name": "tl_fluent_send_plane_24_filled", "prevSize": 32, "code": 60136, - "tempChar": "" + "tempChar": "" }, { "order": 994, @@ -11969,7 +12157,7 @@ "name": "tl_fluent_food_cake_add_20_regular", "prevSize": 32, "code": 60128, - "tempChar": "" + "tempChar": "" }, { "order": 989, @@ -11977,7 +12165,7 @@ "name": "tl_fluent_arrow_sync_horizontal_20_regular", "prevSize": 32, "code": 60123, - "tempChar": "" + "tempChar": "" }, { "order": 985, @@ -11990,7 +12178,7 @@ 60120, 60121 ], - "tempChar": "" + "tempChar": "" }, { "order": 984, @@ -11998,7 +12186,7 @@ "name": "tl_fluent_autodelete_20_filled", "prevSize": 32, "code": 60117, - "tempChar": "" + "tempChar": "" }, { "order": 974, @@ -12006,7 +12194,7 @@ "name": "tl_fluent_chat_dollar_24_regular", "prevSize": 32, "code": 60110, - "tempChar": "" + "tempChar": "" }, { "order": 969, @@ -12014,7 +12202,7 @@ "name": "tl_fluent_open_with_20_regular", "prevSize": 32, "code": 60104, - "tempChar": "" + "tempChar": "" }, { "order": 968, @@ -12022,7 +12210,7 @@ "name": "tl_fluent_copy_20_regular", "prevSize": 32, "code": 60105, - "tempChar": "" + "tempChar": "" }, { "order": 964, @@ -12030,7 +12218,7 @@ "name": "tl_fluent_poll_undo_20_regular", "prevSize": 32, "code": 60100, - "tempChar": "" + "tempChar": "" }, { "order": 963, @@ -12038,7 +12226,7 @@ "name": "tl_copy_as_path_20_regular", "prevSize": 32, "code": 60099, - "tempChar": "" + "tempChar": "" }, { "order": 957, @@ -12046,7 +12234,7 @@ "name": "tl_fluent_diamond_20_regular", "prevSize": 32, "code": 60093, - "tempChar": "" + "tempChar": "" }, { "order": 935, @@ -12054,7 +12242,7 @@ "name": "tl_fluent_number_symbol_arrow_up_16_regular", "prevSize": 32, "code": 60075, - "tempChar": "" + "tempChar": "" }, { "order": 936, @@ -12062,7 +12250,7 @@ "name": "tl_fluent_number_symbol_arrow_up_20_regular", "prevSize": 32, "code": 60076, - "tempChar": "" + "tempChar": "" }, { "order": 937, @@ -12070,7 +12258,7 @@ "name": "tl_fluent_dollar_arrow_up_16_regular", "prevSize": 32, "code": 60077, - "tempChar": "" + "tempChar": "" }, { "order": 938, @@ -12078,7 +12266,7 @@ "name": "tl_fluent_dollar_arrow_up_20_regular", "prevSize": 32, "code": 60078, - "tempChar": "" + "tempChar": "" }, { "order": 939, @@ -12086,7 +12274,7 @@ "name": "tl_fluent_calendar_arrow_up_16_regular", "prevSize": 32, "code": 60079, - "tempChar": "" + "tempChar": "" }, { "order": 940, @@ -12094,7 +12282,7 @@ "name": "tl_fluent_calendar_arrow_up_20_regular", "prevSize": 32, "code": 60080, - "tempChar": "" + "tempChar": "" }, { "order": 929, @@ -12102,7 +12290,7 @@ "name": "tl_fluent_home_dismiss_20_regular", "prevSize": 32, "code": 60069, - "tempChar": "" + "tempChar": "" }, { "order": 926, @@ -12110,7 +12298,7 @@ "name": "tl_fluent_chat_stars_20_filled", "prevSize": 32, "code": 59772, - "tempChar": "" + "tempChar": "" }, { "order": 925, @@ -12118,7 +12306,7 @@ "name": "tl_fluent_spoiler_20_regular", "prevSize": 32, "code": 60065, - "tempChar": "" + "tempChar": "" }, { "order": 924, @@ -12126,7 +12314,7 @@ "name": "tl_fluent_media_spoiler_20_regular", "prevSize": 32, "code": 60066, - "tempChar": "" + "tempChar": "" }, { "order": 918, @@ -12134,7 +12322,7 @@ "name": "tl_fluent_clock_arrow_forward_20_regular", "prevSize": 32, "code": 60063, - "tempChar": "" + "tempChar": "" }, { "order": 917, @@ -12142,7 +12330,7 @@ "name": "tl_fluent_clock_edit_20_regular", "prevSize": 32, "code": 60062, - "tempChar": "" + "tempChar": "" }, { "order": 899, @@ -12150,7 +12338,7 @@ "name": "ic_fluent_person_add_20_regular", "prevSize": 32, "code": 60049, - "tempChar": "" + "tempChar": "" }, { "order": 897, @@ -12158,7 +12346,7 @@ "name": "tl_fluent_fragment_20_filled", "prevSize": 32, "code": 60046, - "tempChar": "" + "tempChar": "" }, { "order": 895, @@ -12166,7 +12354,7 @@ "name": "tl_fluent_coin_20_regular", "prevSize": 32, "code": 60045, - "tempChar": "" + "tempChar": "" }, { "order": 890, @@ -12174,7 +12362,7 @@ "name": "Premium-1", "prevSize": 32, "code": 60039, - "tempChar": "" + "tempChar": "" }, { "order": 886, @@ -12182,7 +12370,7 @@ "name": "tl_fluent_chat_link_20_filled", "prevSize": 32, "code": 60035, - "tempChar": "" + "tempChar": "" }, { "order": 885, @@ -12190,7 +12378,7 @@ "name": "tl_fluent_chat_info_20_filled", "prevSize": 32, "code": 60034, - "tempChar": "" + "tempChar": "" }, { "order": 884, @@ -12198,7 +12386,7 @@ "name": "tl_fluent_fifty_fifty_20_regular", "prevSize": 32, "code": 60031, - "tempChar": "" + "tempChar": "" }, { "order": 883, @@ -12206,7 +12394,7 @@ "name": "tl_fluent_ton_coin_20_regular", "prevSize": 32, "code": 60033, - "tempChar": "" + "tempChar": "" }, { "order": 881, @@ -12214,7 +12402,7 @@ "name": "tl_fluent_arrow_reply_20_filled", "prevSize": 32, "code": 60028, - "tempChar": "" + "tempChar": "" }, { "order": 880, @@ -12222,7 +12410,7 @@ "name": "tl_fluent_chat_snooze_20_filled", "prevSize": 32, "code": 60029, - "tempChar": "" + "tempChar": "" }, { "order": 877, @@ -12230,7 +12418,7 @@ "name": "tl_fluent_chat_unread_20_filled", "prevSize": 32, "code": 60025, - "tempChar": "" + "tempChar": "" }, { "order": 874, @@ -12238,7 +12426,7 @@ "name": "tl_fluent_chat_snooze_20_regular", "prevSize": 32, "code": 60022, - "tempChar": "" + "tempChar": "" }, { "order": 871, @@ -12251,7 +12439,7 @@ 60020, 60021 ], - "tempChar": "" + "tempChar": "" }, { "order": 864, @@ -12259,7 +12447,7 @@ "name": "tl_fluent_last_seen_20_filled", "prevSize": 32, "code": 60013, - "tempChar": "" + "tempChar": "" }, { "order": 853, @@ -12267,7 +12455,7 @@ "name": "tl_fluent_my_notes_20_filled", "prevSize": 32, "code": 60001, - "tempChar": "" + "tempChar": "" }, { "order": 852, @@ -12275,7 +12463,7 @@ "name": "tl_fluent_author_hidden_20_filled", "prevSize": 32, "code": 60002, - "tempChar": "" + "tempChar": "" }, { "order": 847, @@ -12283,7 +12471,7 @@ "name": "tl_fluent_view_once_20_regular", "prevSize": 32, "code": 59672, - "tempChar": "" + "tempChar": "" }, { "order": 836, @@ -12291,7 +12479,7 @@ "name": "tl_fluent_videochat_20_filled", "prevSize": 32, "code": 59983, - "tempChar": "" + "tempChar": "" }, { "order": 810, @@ -12299,7 +12487,7 @@ "name": "tl_fluent_move_down_20_regular", "prevSize": 32, "code": 59971, - "tempChar": "" + "tempChar": "" }, { "order": 811, @@ -12307,7 +12495,7 @@ "name": "tl_fluent_move_up_20_regular", "prevSize": 32, "code": 59972, - "tempChar": "" + "tempChar": "" }, { "order": 809, @@ -12315,7 +12503,7 @@ "name": "tl_fluent_enlarge_20_regular", "prevSize": 32, "code": 59973, - "tempChar": "" + "tempChar": "" }, { "order": 808, @@ -12323,7 +12511,7 @@ "name": "tl_fluent_shrink_20_regular", "prevSize": 32, "code": 59974, - "tempChar": "" + "tempChar": "" }, { "order": 807, @@ -12331,7 +12519,7 @@ "name": "tl_fluent_id_rectangle_20_regular", "prevSize": 32, "code": 59970, - "tempChar": "" + "tempChar": "" }, { "order": 804, @@ -12339,7 +12527,7 @@ "name": "tl_fluent_reply_another_chat_20_regular", "prevSize": 32, "code": 59967, - "tempChar": "" + "tempChar": "" }, { "order": 803, @@ -12347,7 +12535,7 @@ "name": "tl_fluent_quote_block_20_regular", "prevSize": 32, "code": 59966, - "tempChar": "" + "tempChar": "" }, { "order": 800, @@ -12355,7 +12543,7 @@ "name": "tl_fluent_text_quote_20_regular", "prevSize": 32, "code": 59964, - "tempChar": "", + "tempChar": "", "codes": [ 59964 ] @@ -12366,7 +12554,7 @@ "name": "tl_fluent_boost_20_regular", "prevSize": 32, "code": 59961, - "tempChar": "" + "tempChar": "" }, { "order": 785, @@ -12374,7 +12562,7 @@ "name": "tl_fluent_stories_off_20_regular", "prevSize": 32, "code": 59949, - "tempChar": "" + "tempChar": "" }, { "order": 784, @@ -12382,7 +12570,7 @@ "name": "tl_fluent_stealth_20_filled", "prevSize": 32, "code": 59948, - "tempChar": "" + "tempChar": "" }, { "order": 783, @@ -12390,7 +12578,7 @@ "name": "tl_fluent_stealth_20_regular", "prevSize": 32, "code": 59944, - "tempChar": "" + "tempChar": "" }, { "order": 782, @@ -12398,7 +12586,7 @@ "name": "tl_fluent_stealth_locked_20_regular", "prevSize": 32, "code": 59945, - "tempChar": "" + "tempChar": "" }, { "order": 781, @@ -12406,7 +12594,7 @@ "name": "tl_fluent_eye_on_20_regular", "prevSize": 32, "code": 59946, - "tempChar": "" + "tempChar": "" }, { "order": 780, @@ -12414,7 +12602,7 @@ "name": "tl_fluent_save_locked_20_regular", "prevSize": 32, "code": 59947, - "tempChar": "" + "tempChar": "" }, { "order": 764, @@ -12422,7 +12610,7 @@ "name": "tl_fluent_unarchive_20_regular", "prevSize": 32, "code": 59940, - "tempChar": "" + "tempChar": "" }, { "order": 759, @@ -12433,7 +12621,7 @@ "codes": [ 59859 ], - "tempChar": "" + "tempChar": "" }, { "order": 757, @@ -12441,7 +12629,7 @@ "name": "Arrow", "prevSize": 32, "code": 59710, - "tempChar": "" + "tempChar": "" }, { "order": 753, @@ -12449,7 +12637,7 @@ "name": "tl_fluent_arrow_forward_20_filled", "prevSize": 32, "code": 59668, - "tempChar": "" + "tempChar": "" }, { "order": 752, @@ -12457,7 +12645,7 @@ "name": "tl_fluent_arrow_forward_20_regular", "prevSize": 32, "code": 59181, - "tempChar": "" + "tempChar": "" }, { "order": 751, @@ -12465,7 +12653,7 @@ "name": "tl_fluent_arrow_reply_20_regular", "prevSize": 32, "code": 57928, - "tempChar": "" + "tempChar": "" }, { "order": 749, @@ -12473,7 +12661,7 @@ "name": "VoiceRecognition1", "prevSize": 32, "code": 59667, - "tempChar": "" + "tempChar": "" }, { "order": 750, @@ -12481,7 +12669,7 @@ "name": "VoiceRecognition2", "prevSize": 32, "code": 59659, - "tempChar": "" + "tempChar": "" }, { "order": 725, @@ -12489,7 +12677,7 @@ "name": "ic_fluent_speed_template_20_regular", "prevSize": 32, "code": 59923, - "tempChar": "" + "tempChar": "" }, { "order": 722, @@ -12497,7 +12685,7 @@ "name": "ic_fluent_folder_arrow_download_20_regular", "prevSize": 32, "code": 59920, - "tempChar": "" + "tempChar": "" }, { "order": 717, @@ -12505,7 +12693,7 @@ "name": "ShieldStar", "prevSize": 32, "code": 59779, - "tempChar": "" + "tempChar": "" }, { "order": 713, @@ -12513,7 +12701,7 @@ "name": "bot_command_0", "prevSize": 32, "code": 59915, - "tempChar": "" + "tempChar": "" }, { "order": 696, @@ -12524,7 +12712,7 @@ "codes": [ 59895 ], - "tempChar": "" + "tempChar": "" }, { "order": 697, @@ -12532,7 +12720,7 @@ "name": "link_1", "prevSize": 32, "code": 59896, - "tempChar": "" + "tempChar": "" }, { "order": 692, @@ -12547,7 +12735,7 @@ 59896, 59897 ], - "tempChar": "" + "tempChar": "" }, { "order": 691, @@ -12562,7 +12750,7 @@ 59901, 59902 ], - "tempChar": "" + "tempChar": "" }, { "order": 690, @@ -12577,7 +12765,7 @@ 59906, 59907 ], - "tempChar": "" + "tempChar": "" }, { "order": 689, @@ -12592,7 +12780,7 @@ 59911, 59912 ], - "tempChar": "" + "tempChar": "" }, { "order": 652, @@ -12600,7 +12788,7 @@ "name": "gift_premium", "prevSize": 32, "code": 59860, - "tempChar": "" + "tempChar": "" }, { "order": 630, @@ -12608,7 +12796,7 @@ "name": "Circle", "prevSize": 32, "code": 59963, - "tempChar": "" + "tempChar": "" }, { "order": 621, @@ -12616,7 +12804,7 @@ "name": "Premium", "prevSize": 32, "code": 59829, - "tempChar": "" + "tempChar": "" }, { "order": 603, @@ -12624,7 +12812,7 @@ "name": "ic_fluent_clock_alarm_hour_20_regular", "prevSize": 32, "code": 59811, - "tempChar": "" + "tempChar": "" }, { "order": 601, @@ -12632,7 +12820,7 @@ "name": "never", "prevSize": 32, "code": 59807, - "tempChar": "" + "tempChar": "" }, { "order": 599, @@ -12640,7 +12828,7 @@ "name": "day", "prevSize": 32, "code": 59808, - "tempChar": "" + "tempChar": "" }, { "order": 602, @@ -12648,7 +12836,7 @@ "name": "week", "prevSize": 32, "code": 59809, - "tempChar": "" + "tempChar": "" }, { "order": 600, @@ -12656,7 +12844,7 @@ "name": "month", "prevSize": 32, "code": 59810, - "tempChar": "" + "tempChar": "" }, { "order": 592, @@ -12664,7 +12852,7 @@ "name": "mask_outline_2", "prevSize": 32, "code": 59799, - "tempChar": "" + "tempChar": "" }, { "order": 521, @@ -12672,7 +12860,7 @@ "name": "Reactions", "prevSize": 32, "code": 59776, - "tempChar": "" + "tempChar": "" }, { "order": 513, @@ -12680,7 +12868,7 @@ "name": "ic_fluent_dismiss_24_regular", "prevSize": 32, "code": 59768, - "tempChar": "" + "tempChar": "" }, { "order": 497, @@ -12688,7 +12876,7 @@ "name": "Seen", "prevSize": 32, "code": 59755, - "tempChar": "" + "tempChar": "" }, { "order": 494, @@ -12696,7 +12884,7 @@ "name": "ArrowDownSmall", "prevSize": 32, "code": 60892, - "tempChar": "" + "tempChar": "" }, { "order": 492, @@ -12704,7 +12892,7 @@ "name": "ArrowLeftSmall", "prevSize": 32, "code": 60889, - "tempChar": "" + "tempChar": "" }, { "order": 491, @@ -12712,7 +12900,7 @@ "name": "ArrowRightSmall", "prevSize": 32, "code": 60890, - "tempChar": "" + "tempChar": "" }, { "order": 493, @@ -12720,7 +12908,7 @@ "name": "ArrowUpSmall", "prevSize": 32, "code": 60891, - "tempChar": "" + "tempChar": "" }, { "order": 489, @@ -12728,7 +12916,7 @@ "name": "DismissSmall", "prevSize": 32, "code": 57610, - "tempChar": "" + "tempChar": "" }, { "order": 403, @@ -12736,7 +12924,7 @@ "name": "tl_fluent_videochat_20_regular", "prevSize": 32, "code": 59648, - "tempChar": "" + "tempChar": "" }, { "order": 397, @@ -12744,7 +12932,7 @@ "name": "ic_fluent_play_20_regular", "prevSize": 32, "code": 59240, - "tempChar": "" + "tempChar": "" }, { "order": 394, @@ -12752,7 +12940,7 @@ "name": "uniE769", "prevSize": 32, "code": 59241, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -12824,7 +13012,7 @@ "name": "CancelSmall", "prevSize": 32, "code": 59711, - "tempChar": "" + "tempChar": "" }, { "order": 237, @@ -12832,7 +13020,7 @@ "name": "DownloadSmall", "prevSize": 32, "code": 59690, - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -12912,7 +13100,7 @@ "prevSize": 32, "code": 58880, "name": "uniE600", - "tempChar": "" + "tempChar": "" }, { "id": 9, @@ -12921,7 +13109,7 @@ "prevSize": 32, "code": 58881, "name": "uniE601", - "tempChar": "" + "tempChar": "" }, { "id": 10, @@ -12930,7 +13118,7 @@ "prevSize": 32, "code": 58882, "name": "uniE602", - "tempChar": "" + "tempChar": "" }, { "id": 11, @@ -12939,7 +13127,7 @@ "prevSize": 32, "code": 58883, "name": "uniE603", - "tempChar": "" + "tempChar": "" }, { "id": 12, @@ -12975,7 +13163,7 @@ "prevSize": 32, "code": 58885, "name": "uniE60B", - "tempChar": "" + "tempChar": "" }, { "id": 16, @@ -12984,7 +13172,7 @@ "prevSize": 32, "code": 58892, "name": "uniE60C", - "tempChar": "" + "tempChar": "" }, { "order": 235, @@ -12992,7 +13180,7 @@ "name": "Trending", "prevSize": 32, "code": 58893, - "tempChar": "" + "tempChar": "" }, { "id": 18, @@ -13036,7 +13224,7 @@ "prevSize": 32, "code": 58894, "name": "uniE611", - "tempChar": "" + "tempChar": "" }, { "id": 23, @@ -13045,7 +13233,7 @@ "prevSize": 32, "code": 58898, "name": "uniE612", - "tempChar": "" + "tempChar": "" }, { "order": 0, @@ -13143,7 +13331,7 @@ "prevSize": 32, "code": 59654, "name": "uniE906", - "tempChar": "" + "tempChar": "" }, { "id": 34, @@ -13161,7 +13349,7 @@ "prevSize": 32, "code": 59656, "name": "uniE908", - "tempChar": "" + "tempChar": "" }, { "id": 36, @@ -13179,7 +13367,7 @@ "prevSize": 32, "code": 59658, "name": "uniE90A", - "tempChar": "" + "tempChar": "" }, { "id": 38, @@ -13251,7 +13439,7 @@ "prevSize": 32, "code": 59666, "name": "uniE912", - "tempChar": "" + "tempChar": "" }, { "id": 46, @@ -13323,7 +13511,7 @@ "prevSize": 32, "code": 59674, "name": "uniE91A", - "tempChar": "" + "tempChar": "" }, { "id": 55, @@ -13359,7 +13547,7 @@ "prevSize": 32, "code": 942080, "name": "uE6000", - "tempChar": "" + "tempChar": "" } ], "id": 2, @@ -13373,6 +13561,23 @@ "height": 1024, "prevSize": 32, "icons": [ + { + "id": 188, + "paths": [ + "M109.898 109.903c9.997-9.997 26.203-9.997 36.2 0l768.002 767.998c9.994 9.999 9.994 26.204 0 36.204-9.999 9.994-26.204 9.994-36.204 0l-195.599-195.599-104.648 98.248c-19.062 17.93-48.932 16.819-66.751-2.099-8.203-8.719-12.793-20.275-12.8-32.302v-116.301c-135.154 4.7-227.313 47.191-282.65 123.054l-17.2 26.598c-9.303 15.908-29.887 21.852-46.35 12.498-10.978-6.226-16.976-17.654-17.2-29.097v-26.301c1.867-129.014 31.988-231.014 94.25-302.050 32.864-37.488 73.715-65.169 121.9-83.7l-240.95-240.95c-9.997-9.997-9.997-26.203 0-36.2zM391.098 427.303c-51.613 15.688-92.501 41.667-123.65 77.2-46.851 53.454-74.674 131.754-80.5 237.902 72.489-86.804 186.822-128 336.752-128 14.126 0.010 25.6 11.464 25.6 25.6v133.146l96.799-90.849-255-254.999z", + "M545.295 194.903c11.924 0.001 23.588 4.551 32.353 12.8l288.051 269.85c16.492 15.521 19.594 40.3 7.946 59.203-0.599 0.968-1.275 1.915-1.997 2.796l-3.599 4.454c-0.707 0.855-1.495 1.638-2.304 2.396l-108.749 102.001-36.198-36.198 106.798-100.198-278.298-260.702v132.7c-0.010 14.127-11.474 25.59-25.6 25.6-1.823 0-3.651 0.034-5.453 0.050l-48.849-48.85c9.388-0.834 18.962-1.516 28.7-1.9v-116.8c0.005-26.083 21.122-47.197 47.198-47.2z" + ], + "attrs": [ + {}, + {} + ], + "grid": 0, + "tags": [ + "tl_fluent_arrow_forward_off_20_regular" + ], + "isMulticolor": false, + "isMulticolor2": false + }, { "id": 187, "paths": [ @@ -15991,7 +16196,7 @@ "metadata": { "fontFamily": "Telegram", "majorVersion": 2, - "minorVersion": 172 + "minorVersion": 177 }, "metrics": { "emSize": 1024, @@ -16017,7 +16222,7 @@ }, "historySize": 100, "quickUsageToken": { - "Telegram": "M2JjNDFmYzAzMCMxNzY2NTY3OTkyI1VTUEptTDBIdmxxSjNzbGpJL2FJZjdZZ0taZENidlNxSWlKMkxFL2x3REE5" + "Telegram": "N2RlODUzNmU3MyMxNzc1NzM1MTYyI2hSNDlqMUFGTGkwSUxrRGZkL3ZmN21zMXVWc2hES052RjBPZnJrZ2dsYWQw" }, "gridSize": 16 }, diff --git a/Telegram/Assets/Fonts/Telegram.ttf b/Telegram/Assets/Fonts/Telegram.ttf index 9c89a0ab64..dce250f392 100644 Binary files a/Telegram/Assets/Fonts/Telegram.ttf and b/Telegram/Assets/Fonts/Telegram.ttf differ diff --git a/Telegram/Assets/Icons/PollSelect.cs b/Telegram/Assets/Icons/PollSelect.cs new file mode 100644 index 0000000000..f440220716 --- /dev/null +++ b/Telegram/Assets/Icons/PollSelect.cs @@ -0,0 +1,1101 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// +// LottieGen version: +// 8.1.240821-rc.1+f962c65f63 +// +// Command: +// LottieGen -DisableTranslationOptimizer -GenerateColorBindings -Language CSharp -MinimumUapVersion 8 -Namespace Telegram.Assets.Icons -Public -WinUIVersion 2.7 -InputFile PollSelect.json +// +// Input file: +// PollSelect.json (3697 bytes created 16:54+04:00 Apr 8 2026) +// +// LottieGen source: +// http://aka.ms/Lottie +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ +// ___________________________________________________________ +// | Object stats | UAP v15 count | UAP v7 count | +// |__________________________|_______________|______________| +// | All CompositionObjects | 73 | 77 | +// |--------------------------+---------------+--------------| +// | Expression animators | 4 | 5 | +// | KeyFrame animators | 2 | 2 | +// | Reference parameters | 4 | 5 | +// | Expression operations | 12 | 12 | +// |--------------------------+---------------+--------------| +// | Animated brushes | 3 | 3 | +// | Animated gradient stops | - | - | +// | ExpressionAnimations | 4 | 5 | +// | PathKeyFrameAnimations | - | - | +// |--------------------------+---------------+--------------| +// | ContainerVisuals | 1 | 1 | +// | ShapeVisuals | 1 | 1 | +// |--------------------------+---------------+--------------| +// | ContainerShapes | 14 | 14 | +// | CompositionSpriteShapes | 3 | 3 | +// |--------------------------+---------------+--------------| +// | Brushes | 3 | 3 | +// | Gradient stops | - | - | +// | CompositionVisualSurface | - | - | +// ----------------------------------------------------------- +using Microsoft.Graphics.Canvas.Geometry; +using System; +using System.Collections.Generic; +using System.Numerics; +using Windows.Graphics; +using Windows.UI; +using Windows.UI.Composition; + +namespace Telegram.Assets.Icons +{ + // Name: Comp 2 + // Frame rate: 100 fps + // Frame count: 33 + // Duration: 330.0 mS + // ___________________________________________________________ + // | Theme property | Accessor | Type | Default value | + // |________________|______________|_______|_________________| + // | #FF0000 | Color_FF0000 | Color | #FFFF0000 Red | + // | #FFFFFF | Color_FFFFFF | Color | #FFFFFFFF White | + // ----------------------------------------------------------- + public sealed class PollSelect + : Microsoft.UI.Xaml.Controls.IAnimatedVisualSource + , Microsoft.UI.Xaml.Controls.IAnimatedVisualSource2 + { + // Animation duration: 0.330 seconds. + internal const long c_durationTicks = 2500000; + + // Theme property: Color_FF0000. + internal static readonly Color c_themeColor_FF0000 = Color.FromArgb(0xFF, 0xFF, 0x00, 0x00); + + // Theme property: Color_FFFFFF. + internal static readonly Color c_themeColor_FFFFFF = Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF); + + CompositionPropertySet _themeProperties; + Color _themeColor_FF0000 = c_themeColor_FF0000; + Color _themeColor_FFFFFF = c_themeColor_FFFFFF; + + // Theme properties. + public Color Color_FF0000 + { + get => _themeColor_FF0000; + set + { + _themeColor_FF0000 = value; + if (_themeProperties != null) + { + _themeProperties.InsertVector4("Color_FF0000", ColorAsVector4((Color)_themeColor_FF0000)); + } + } + } + + public Color Color_FFFFFF + { + get => _themeColor_FFFFFF; + set + { + _themeColor_FFFFFF = value; + if (_themeProperties != null) + { + _themeProperties.InsertVector4("Color_FFFFFF", ColorAsVector4((Color)_themeColor_FFFFFF)); + } + } + } + + static Vector4 ColorAsVector4(Color color) => new Vector4(color.R, color.G, color.B, color.A); + + CompositionPropertySet EnsureThemeProperties(Compositor compositor) + { + if (_themeProperties == null) + { + _themeProperties = compositor.CreatePropertySet(); + _themeProperties.InsertVector4("Color_FF0000", ColorAsVector4((Color)Color_FF0000)); + _themeProperties.InsertVector4("Color_FFFFFF", ColorAsVector4((Color)Color_FFFFFF)); + } + return _themeProperties; + } + + public Microsoft.UI.Xaml.Controls.IAnimatedVisual TryCreateAnimatedVisual(Compositor compositor) + { + object ignored = null; + return TryCreateAnimatedVisual(compositor, out ignored); + } + + public Microsoft.UI.Xaml.Controls.IAnimatedVisual TryCreateAnimatedVisual(Compositor compositor, out object diagnostics) + { + diagnostics = null; + EnsureThemeProperties(compositor); + + if (PollSelect_AnimatedVisual_UAPv15.IsRuntimeCompatible()) + { + var res = + new PollSelect_AnimatedVisual_UAPv15( + compositor, + _themeProperties + ); + return res; + } + + if (PollSelect_AnimatedVisual_UAPv7.IsRuntimeCompatible()) + { + var res = + new PollSelect_AnimatedVisual_UAPv7( + compositor, + _themeProperties + ); + return res; + } + + return null; + } + + /// + /// Gets the number of frames in the animation. + /// + public double FrameCount => 33d; + + /// + /// Gets the frame rate of the animation. + /// + public double Framerate => 100d; + + /// + /// Gets the duration of the animation. + /// + public TimeSpan Duration => TimeSpan.FromTicks(2500000); + + /// + /// Converts a zero-based frame number to the corresponding progress value denoting the + /// start of the frame. + /// + public double FrameToProgress(double frameNumber) + { + return frameNumber / 33d; + } + + /// + /// Returns a map from marker names to corresponding progress values. + /// + public IReadOnlyDictionary Markers => + new Dictionary + { + }; + + /// + /// Sets the color property with the given name, or does nothing if no such property + /// exists. + /// + public void SetColorProperty(string propertyName, Color value) + { + if (propertyName == "Color_FF0000") + { + _themeColor_FF0000 = value; + } + else if (propertyName == "Color_FFFFFF") + { + _themeColor_FFFFFF = value; + } + else + { + return; + } + + if (_themeProperties != null) + { + _themeProperties.InsertVector4(propertyName, ColorAsVector4(value)); + } + } + + /// + /// Sets the scalar property with the given name, or does nothing if no such property + /// exists. + /// + public void SetScalarProperty(string propertyName, double value) + { + } + + sealed class PollSelect_AnimatedVisual_UAPv15 + : Microsoft.UI.Xaml.Controls.IAnimatedVisual + { + const long c_durationTicks = 2500000; + readonly Compositor _c; + readonly ExpressionAnimation _reusableExpressionAnimation; + readonly CompositionPropertySet _themeProperties; + AnimationController _animationController_0; + ContainerVisual _root; + StepEasingFunction _holdThenStepEasingFunction; + StepEasingFunction _stepThenHoldEasingFunction; + + void BindProperty( + CompositionObject target, + string animatedPropertyName, + string expression, + string referenceParameterName, + CompositionObject referencedObject) + { + _reusableExpressionAnimation.ClearAllParameters(); + _reusableExpressionAnimation.Expression = expression; + _reusableExpressionAnimation.SetReferenceParameter(referenceParameterName, referencedObject); + target.StartAnimation(animatedPropertyName, _reusableExpressionAnimation); + } + + ScalarKeyFrameAnimation CreateScalarKeyFrameAnimation(float initialProgress, float initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateScalarKeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + Vector2KeyFrameAnimation CreateVector2KeyFrameAnimation(float initialProgress, Vector2 initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateVector2KeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + AnimationController AnimationController_0() + { + var result = _animationController_0 = _c.CreateAnimationController(); + result.Pause(); + BindProperty(result, "Progress", "_.Progress", "_", _root); + return result; + } + + // - - - - - - - Layer aggregator + // - - - - ShapeGroup: Vector 1 + // - - Path 1 + CanvasGeometry Geometry() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.BeginFigure(new Vector2(4.5F, -3F)); + builder.AddLine(new Vector2(-1.31799996F, 3F)); + builder.AddLine(new Vector2(-4.5F, 0F)); + builder.EndFigure(CanvasFigureLoop.Open); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape Layer + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Color bound to theme property value: Color_FF0000 + CompositionColorBrush ThemeColor_Color_FF0000_0() + { + var result = _c.CreateColorBrush(); + BindProperty(result, "Color", "ColorRGB(_theme.Color_FF0000.W,_theme.Color_FF0000.X,_theme.Color_FF0000.Y,_theme.Color_FF0000.Z)", "_theme", _themeProperties); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: accent + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Color bound to theme property value: Color_FF0000 + CompositionColorBrush ThemeColor_Color_FF0000_1() + { + var result = _c.CreateColorBrush(); + BindProperty(result, "Color", "ColorRGB(_theme.Color_FF0000.W,_theme.Color_FF0000.X,_theme.Color_FF0000.Y,_theme.Color_FF0000.Z)", "_theme", _themeProperties); + return result; + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Vector 1 + // Path 1 + // Color bound to theme property value: Color_FFFFFF + CompositionColorBrush ThemeColor_Color_FFFFFF() + { + var result = _c.CreateColorBrush(); + BindProperty(result, "Color", "ColorRGB(_theme.Color_FFFFFF.W,_theme.Color_FFFFFF.X,_theme.Color_FFFFFF.Y,_theme.Color_FFFFFF.Z)", "_theme", _themeProperties); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_00() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + // Transforms: Shape Layer + result.Shapes.Add(ContainerShape_01()); + return result; + } + + // - Layer aggregator + // Transforms for Shape Layer + CompositionContainerShape ContainerShape_01() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(12F, 12F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_02()); + return result; + } + + // - - Layer aggregator + // Transforms: Shape Layer + CompositionContainerShape ContainerShape_02() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Rectangle 1 + result.Shapes.Add(ContainerShape_03()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Shape Layer + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_03() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_04()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Shape Layer + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_04() + { + var result = _c.CreateContainerShape(); + // Rectangle Path 1 + result.Shapes.Add(SpriteShape_0()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_05() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + // Transforms: accent + result.Shapes.Add(ContainerShape_06()); + return result; + } + + // - Layer aggregator + // Transforms for accent + CompositionContainerShape ContainerShape_06() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(12F, 12F); + result.RotationAngleInDegrees = 0F; + result.Shapes.Add(ContainerShape_07()); + result.StartAnimation("Scale", ScaleVector2Animation(), AnimationController_0()); + return result; + } + + // - - Layer aggregator + // Transforms: accent + CompositionContainerShape ContainerShape_07() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Rectangle 1 + result.Shapes.Add(ContainerShape_08()); + return result; + } + + // - - - Layer aggregator + // - Transforms: accent + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_08() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_09()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: accent + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_09() + { + var result = _c.CreateContainerShape(); + // Rectangle Path 1 + result.Shapes.Add(SpriteShape_1()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_10() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_11()); + return result; + } + + // - Layer aggregator + CompositionContainerShape ContainerShape_11() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Vector 1 + result.Shapes.Add(ContainerShape_12()); + return result; + } + + // - - Layer aggregator + // ShapeGroup: Vector 1 + CompositionContainerShape ContainerShape_12() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(12F, 12F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_13()); + return result; + } + + // - - - Layer aggregator + // ShapeGroup: Vector 1 + CompositionContainerShape ContainerShape_13() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_2()); + return result; + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Vector 1 + // Path 1 + CompositionPathGeometry PathGeometry() + { + var result = _c.CreatePathGeometry(new CompositionPath(Geometry())); + result.TrimEnd = 1F; + result.TrimOffset = 0F; + result.StartAnimation("TrimStart", TrimStartScalarAnimation_1_to_0(), _animationController_0); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape Layer + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Rectangle Path 1.RectangleGeometry + CompositionRoundedRectangleGeometry RoundedRectangle_18p5_0() + { + var result = _c.CreateRoundedRectangleGeometry(); + result.CornerRadius = new Vector2(3.5F, 3.5F); + result.Offset = new Vector2(-9.25F, -9.25F); + result.Size = new Vector2(18.5F, 18.5F); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: accent + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Rectangle Path 1.RectangleGeometry + CompositionRoundedRectangleGeometry RoundedRectangle_18p5_1() + { + var result = _c.CreateRoundedRectangleGeometry(); + result.CornerRadius = new Vector2(3.5F, 3.5F); + result.Offset = new Vector2(-9.25F, -9.25F); + result.Size = new Vector2(18.5F, 18.5F); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Shape Layer + // - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + CompositionSpriteShape SpriteShape_0() + { + var result = _c.CreateSpriteShape(RoundedRectangle_18p5_0()); + result.StrokeBrush = ThemeColor_Color_FF0000_0(); + result.StrokeDashOffset = 0F; + result.StrokeMiterLimit = 2F; + result.StrokeThickness = 1.5F; + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: accent + // - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + CompositionSpriteShape SpriteShape_1() + { + var result = _c.CreateSpriteShape(RoundedRectangle_18p5_1()); + result.FillBrush = ThemeColor_Color_FF0000_1(); + return result; + } + + // - - - - Layer aggregator + // - ShapeGroup: Vector 1 + // Path 1 + CompositionSpriteShape SpriteShape_2() + { + var result = _c.CreateSpriteShape(PathGeometry()); + result.StrokeBrush = ThemeColor_Color_FFFFFF(); + result.StrokeDashCap = CompositionStrokeCap.Round; + result.StrokeDashOffset = 0F; + result.StrokeStartCap = CompositionStrokeCap.Round; + result.StrokeEndCap = CompositionStrokeCap.Round; + result.StrokeLineJoin = CompositionStrokeLineJoin.Round; + result.StrokeMiterLimit = 2F; + result.StrokeThickness = 1.5F; + return result; + } + + // The root of the composition. + ContainerVisual Root() + { + var result = _root = _c.CreateContainerVisual(); + var propertySet = result.Properties; + propertySet.InsertScalar("Progress", 0F); + // Layer aggregator + result.Children.InsertAtTop(ShapeVisual_0()); + return result; + } + + // - - - - - - Layer aggregator + // - - - ShapeGroup: Vector 1 + // - Path 1 + // TrimStart + ScalarKeyFrameAnimation TrimStartScalarAnimation_1_to_0() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, _stepThenHoldEasingFunction); + // Frame 15. + result.InsertKeyFrame(0.454545468F, 1F, _holdThenStepEasingFunction); + // Frame 32. + result.InsertKeyFrame(0.969696999F, 0F, _c.CreateCubicBezierEasingFunction(new Vector2(0.600000024F, 0F), new Vector2(0.400000006F, 1F))); + return result; + } + + // Layer aggregator + ShapeVisual ShapeVisual_0() + { + var result = _c.CreateShapeVisual(); + result.Size = new Vector2(24F, 24F); + var shapes = result.Shapes; + shapes.Add(ContainerShape_00()); + shapes.Add(ContainerShape_05()); + shapes.Add(ContainerShape_10()); + return result; + } + + StepEasingFunction HoldThenStepEasingFunction() + { + var result = _holdThenStepEasingFunction = _c.CreateStepEasingFunction(); + result.FinalStep = 1; + result.IsFinalStepSingleFrame = true; + result.StepCount = 1; + return result; + } + + StepEasingFunction StepThenHoldEasingFunction() + { + var result = _stepThenHoldEasingFunction = _c.CreateStepEasingFunction(); + result.FinalStep = 1; + result.IsInitialStepSingleFrame = true; + result.StepCount = 1; + return result; + } + + // - - Layer aggregator + // Transforms: accent + // Scale + Vector2KeyFrameAnimation ScaleVector2Animation() + { + // Frame 0. + var result = CreateVector2KeyFrameAnimation(0F, new Vector2(0F, 0F), StepThenHoldEasingFunction()); + // Frame 2. + result.InsertKeyFrame(0.0606060624F, new Vector2(0F, 0F), HoldThenStepEasingFunction()); + // Frame 32. + result.InsertKeyFrame(0.969696999F, new Vector2(1F, 1F), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + internal PollSelect_AnimatedVisual_UAPv15( + Compositor compositor, + CompositionPropertySet themeProperties + ) + { + _c = compositor; + _themeProperties = themeProperties; + _reusableExpressionAnimation = compositor.CreateExpressionAnimation(); + Root(); + } + + public Visual RootVisual => _root; + public TimeSpan Duration => TimeSpan.FromTicks(c_durationTicks); + public Vector2 Size => new Vector2(24F, 24F); + void IDisposable.Dispose() => _root?.Dispose(); + + internal static bool IsRuntimeCompatible() + { + return Windows.Foundation.Metadata.ApiInformation.IsApiContractPresent("Windows.Foundation.UniversalApiContract", 15); + } + } + + sealed class PollSelect_AnimatedVisual_UAPv7 + : Microsoft.UI.Xaml.Controls.IAnimatedVisual + { + const long c_durationTicks = 2500000; + readonly Compositor _c; + readonly ExpressionAnimation _reusableExpressionAnimation; + readonly CompositionPropertySet _themeProperties; + ContainerVisual _root; + StepEasingFunction _holdThenStepEasingFunction; + StepEasingFunction _stepThenHoldEasingFunction; + + void BindProperty( + CompositionObject target, + string animatedPropertyName, + string expression, + string referenceParameterName, + CompositionObject referencedObject) + { + _reusableExpressionAnimation.ClearAllParameters(); + _reusableExpressionAnimation.Expression = expression; + _reusableExpressionAnimation.SetReferenceParameter(referenceParameterName, referencedObject); + target.StartAnimation(animatedPropertyName, _reusableExpressionAnimation); + } + + ScalarKeyFrameAnimation CreateScalarKeyFrameAnimation(float initialProgress, float initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateScalarKeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + Vector2KeyFrameAnimation CreateVector2KeyFrameAnimation(float initialProgress, Vector2 initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateVector2KeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + // - - - - - - - Layer aggregator + // - - - - ShapeGroup: Vector 1 + // - - Path 1 + CanvasGeometry Geometry() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.BeginFigure(new Vector2(4.5F, -3F)); + builder.AddLine(new Vector2(-1.31799996F, 3F)); + builder.AddLine(new Vector2(-4.5F, 0F)); + builder.EndFigure(CanvasFigureLoop.Open); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape Layer + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Color bound to theme property value: Color_FF0000 + CompositionColorBrush ThemeColor_Color_FF0000_0() + { + var result = _c.CreateColorBrush(); + BindProperty(result, "Color", "ColorRGB(_theme.Color_FF0000.W,_theme.Color_FF0000.X,_theme.Color_FF0000.Y,_theme.Color_FF0000.Z)", "_theme", _themeProperties); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: accent + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Color bound to theme property value: Color_FF0000 + CompositionColorBrush ThemeColor_Color_FF0000_1() + { + var result = _c.CreateColorBrush(); + BindProperty(result, "Color", "ColorRGB(_theme.Color_FF0000.W,_theme.Color_FF0000.X,_theme.Color_FF0000.Y,_theme.Color_FF0000.Z)", "_theme", _themeProperties); + return result; + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Vector 1 + // Path 1 + // Color bound to theme property value: Color_FFFFFF + CompositionColorBrush ThemeColor_Color_FFFFFF() + { + var result = _c.CreateColorBrush(); + BindProperty(result, "Color", "ColorRGB(_theme.Color_FFFFFF.W,_theme.Color_FFFFFF.X,_theme.Color_FFFFFF.Y,_theme.Color_FFFFFF.Z)", "_theme", _themeProperties); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_00() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + // Transforms: Shape Layer + result.Shapes.Add(ContainerShape_01()); + return result; + } + + // - Layer aggregator + // Transforms for Shape Layer + CompositionContainerShape ContainerShape_01() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(12F, 12F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_02()); + return result; + } + + // - - Layer aggregator + // Transforms: Shape Layer + CompositionContainerShape ContainerShape_02() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Rectangle 1 + result.Shapes.Add(ContainerShape_03()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Shape Layer + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_03() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_04()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Shape Layer + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_04() + { + var result = _c.CreateContainerShape(); + // Rectangle Path 1 + result.Shapes.Add(SpriteShape_0()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_05() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + // Transforms: accent + result.Shapes.Add(ContainerShape_06()); + return result; + } + + // - Layer aggregator + // Transforms for accent + CompositionContainerShape ContainerShape_06() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(12F, 12F); + result.RotationAngleInDegrees = 0F; + result.Shapes.Add(ContainerShape_07()); + result.StartAnimation("Scale", ScaleVector2Animation()); + var controller = result.TryGetAnimationController("Scale"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + return result; + } + + // - - Layer aggregator + // Transforms: accent + CompositionContainerShape ContainerShape_07() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Rectangle 1 + result.Shapes.Add(ContainerShape_08()); + return result; + } + + // - - - Layer aggregator + // - Transforms: accent + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_08() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_09()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: accent + // ShapeGroup: Rectangle 1 + CompositionContainerShape ContainerShape_09() + { + var result = _c.CreateContainerShape(); + // Rectangle Path 1 + result.Shapes.Add(SpriteShape_1()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_10() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_11()); + return result; + } + + // - Layer aggregator + CompositionContainerShape ContainerShape_11() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Vector 1 + result.Shapes.Add(ContainerShape_12()); + return result; + } + + // - - Layer aggregator + // ShapeGroup: Vector 1 + CompositionContainerShape ContainerShape_12() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(12F, 12F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_13()); + return result; + } + + // - - - Layer aggregator + // ShapeGroup: Vector 1 + CompositionContainerShape ContainerShape_13() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_2()); + return result; + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Vector 1 + // Path 1 + CompositionPathGeometry PathGeometry() + { + var result = _c.CreatePathGeometry(new CompositionPath(Geometry())); + result.TrimEnd = 1F; + result.TrimOffset = 0F; + result.StartAnimation("TrimStart", TrimStartScalarAnimation_1_to_0()); + var controller = result.TryGetAnimationController("TrimStart"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape Layer + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Rectangle Path 1.RectangleGeometry + CompositionRoundedRectangleGeometry RoundedRectangle_18p5_0() + { + var result = _c.CreateRoundedRectangleGeometry(); + result.CornerRadius = new Vector2(3.5F, 3.5F); + result.Offset = new Vector2(-9.25F, -9.25F); + result.Size = new Vector2(18.5F, 18.5F); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: accent + // - - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + // Rectangle Path 1.RectangleGeometry + CompositionRoundedRectangleGeometry RoundedRectangle_18p5_1() + { + var result = _c.CreateRoundedRectangleGeometry(); + result.CornerRadius = new Vector2(3.5F, 3.5F); + result.Offset = new Vector2(-9.25F, -9.25F); + result.Size = new Vector2(18.5F, 18.5F); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Shape Layer + // - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + CompositionSpriteShape SpriteShape_0() + { + var result = _c.CreateSpriteShape(RoundedRectangle_18p5_0()); + result.StrokeBrush = ThemeColor_Color_FF0000_0(); + result.StrokeDashOffset = 0F; + result.StrokeMiterLimit = 2F; + result.StrokeThickness = 1.5F; + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: accent + // - ShapeGroup: Rectangle 1 + // Rectangle Path 1 + CompositionSpriteShape SpriteShape_1() + { + var result = _c.CreateSpriteShape(RoundedRectangle_18p5_1()); + result.FillBrush = ThemeColor_Color_FF0000_1(); + return result; + } + + // - - - - Layer aggregator + // - ShapeGroup: Vector 1 + // Path 1 + CompositionSpriteShape SpriteShape_2() + { + var result = _c.CreateSpriteShape(PathGeometry()); + result.StrokeBrush = ThemeColor_Color_FFFFFF(); + result.StrokeDashCap = CompositionStrokeCap.Round; + result.StrokeDashOffset = 0F; + result.StrokeStartCap = CompositionStrokeCap.Round; + result.StrokeEndCap = CompositionStrokeCap.Round; + result.StrokeLineJoin = CompositionStrokeLineJoin.Round; + result.StrokeMiterLimit = 2F; + result.StrokeThickness = 1.5F; + return result; + } + + // The root of the composition. + ContainerVisual Root() + { + var result = _root = _c.CreateContainerVisual(); + var propertySet = result.Properties; + propertySet.InsertScalar("Progress", 0F); + // Layer aggregator + result.Children.InsertAtTop(ShapeVisual_0()); + return result; + } + + // - - - - - - Layer aggregator + // - - - ShapeGroup: Vector 1 + // - Path 1 + // TrimStart + ScalarKeyFrameAnimation TrimStartScalarAnimation_1_to_0() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, _stepThenHoldEasingFunction); + // Frame 15. + result.InsertKeyFrame(0.454545468F, 1F, _holdThenStepEasingFunction); + // Frame 32. + result.InsertKeyFrame(0.969696999F, 0F, _c.CreateCubicBezierEasingFunction(new Vector2(0.600000024F, 0F), new Vector2(0.400000006F, 1F))); + return result; + } + + // Layer aggregator + ShapeVisual ShapeVisual_0() + { + var result = _c.CreateShapeVisual(); + result.Size = new Vector2(24F, 24F); + var shapes = result.Shapes; + shapes.Add(ContainerShape_00()); + shapes.Add(ContainerShape_05()); + shapes.Add(ContainerShape_10()); + return result; + } + + StepEasingFunction HoldThenStepEasingFunction() + { + var result = _holdThenStepEasingFunction = _c.CreateStepEasingFunction(); + result.FinalStep = 1; + result.IsFinalStepSingleFrame = true; + result.StepCount = 1; + return result; + } + + StepEasingFunction StepThenHoldEasingFunction() + { + var result = _stepThenHoldEasingFunction = _c.CreateStepEasingFunction(); + result.FinalStep = 1; + result.IsInitialStepSingleFrame = true; + result.StepCount = 1; + return result; + } + + // - - Layer aggregator + // Transforms: accent + // Scale + Vector2KeyFrameAnimation ScaleVector2Animation() + { + // Frame 0. + var result = CreateVector2KeyFrameAnimation(0F, new Vector2(0F, 0F), StepThenHoldEasingFunction()); + // Frame 2. + result.InsertKeyFrame(0.0606060624F, new Vector2(0F, 0F), HoldThenStepEasingFunction()); + // Frame 32. + result.InsertKeyFrame(0.969696999F, new Vector2(1F, 1F), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + internal PollSelect_AnimatedVisual_UAPv7( + Compositor compositor, + CompositionPropertySet themeProperties + ) + { + _c = compositor; + _themeProperties = themeProperties; + _reusableExpressionAnimation = compositor.CreateExpressionAnimation(); + Root(); + } + + public Visual RootVisual => _root; + public TimeSpan Duration => TimeSpan.FromTicks(c_durationTicks); + public Vector2 Size => new Vector2(24F, 24F); + void IDisposable.Dispose() => _root?.Dispose(); + + internal static bool IsRuntimeCompatible() + { + return Windows.Foundation.Metadata.ApiInformation.IsApiContractPresent("Windows.Foundation.UniversalApiContract", 7); + } + } + } +} diff --git a/Telegram/Assets/Icons/Tips.cs b/Telegram/Assets/Icons/Tips.cs new file mode 100644 index 0000000000..d384961989 --- /dev/null +++ b/Telegram/Assets/Icons/Tips.cs @@ -0,0 +1,3042 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// +// LottieGen version: +// 8.1.240821-rc.1+f962c65f63 +// +// Command: +// LottieGen -DisableTranslationOptimizer -Language CSharp -Namespace Telegram.Assets.Icons -Public -WinUIVersion 2.8 -InputFile Tips.json +// +// Input file: +// Tips.json (12729 bytes created 15:23+04:00 Jan 9 2026) +// +// LottieGen source: +// http://aka.ms/Lottie +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ +// ___________________________________________________________ +// | Object stats | UAP v15 count | UAP v7 count | +// |__________________________|_______________|______________| +// | All CompositionObjects | 634 | 686 | +// |--------------------------+---------------+--------------| +// | Expression animators | 1 | 14 | +// | KeyFrame animators | 14 | 14 | +// | Reference parameters | 1 | 14 | +// | Expression operations | 0 | 0 | +// |--------------------------+---------------+--------------| +// | Animated brushes | 2 | 2 | +// | Animated gradient stops | - | - | +// | ExpressionAnimations | 1 | 14 | +// | PathKeyFrameAnimations | - | - | +// |--------------------------+---------------+--------------| +// | ContainerVisuals | 1 | 1 | +// | ShapeVisuals | 1 | 1 | +// |--------------------------+---------------+--------------| +// | ContainerShapes | 24 | 24 | +// | CompositionSpriteShapes | 5 | 5 | +// |--------------------------+---------------+--------------| +// | Brushes | 5 | 5 | +// | Gradient stops | 4 | 4 | +// | CompositionVisualSurface | - | - | +// ----------------------------------------------------------- +using Microsoft.Graphics.Canvas.Geometry; +using System; +using System.Collections.Generic; +using System.Numerics; +using Windows.Graphics; +using Windows.UI; +using Windows.UI.Composition; + +namespace Telegram.Assets.Icons +{ + // Name: u_username + // Frame rate: 60 fps + // Frame count: 30 + // Duration: 500.0 mS + public sealed partial class Tips + : Microsoft.UI.Xaml.Controls.IAnimatedVisualSource + , Microsoft.UI.Xaml.Controls.IAnimatedVisualSource2 + { + // Animation duration: 0.500 seconds. + internal const long c_durationTicks = 5000000; + + public Microsoft.UI.Xaml.Controls.IAnimatedVisual TryCreateAnimatedVisual(Compositor compositor) + { + object ignored = null; + return TryCreateAnimatedVisual(compositor, out ignored); + } + + public Microsoft.UI.Xaml.Controls.IAnimatedVisual TryCreateAnimatedVisual(Compositor compositor, out object diagnostics) + { + diagnostics = null; + + if (Tips_AnimatedVisual_UAPv15.IsRuntimeCompatible()) + { + var res = + new Tips_AnimatedVisual_UAPv15( + compositor + ); + res.CreateAnimations(); + return res; + } + + if (Tips_AnimatedVisual_UAPv7.IsRuntimeCompatible()) + { + var res = + new Tips_AnimatedVisual_UAPv7( + compositor + ); + res.CreateAnimations(); + return res; + } + + return null; + } + + /// + /// Gets the number of frames in the animation. + /// + public double FrameCount => 30d; + + /// + /// Gets the frame rate of the animation. + /// + public double Framerate => 60d; + + /// + /// Gets the duration of the animation. + /// + public TimeSpan Duration => TimeSpan.FromTicks(5000000); + + /// + /// Converts a zero-based frame number to the corresponding progress value denoting the + /// start of the frame. + /// + public double FrameToProgress(double frameNumber) + { + return frameNumber / 30d; + } + + /// + /// Returns a map from marker names to corresponding progress values. + /// + public IReadOnlyDictionary Markers => + new Dictionary + { + { "NormalToPointerOver_Start", 0.0 }, + { "NormalToPointerOver_End", 1 }, + }; + + /// + /// Sets the color property with the given name, or does nothing if no such property + /// exists. + /// + public void SetColorProperty(string propertyName, Color value) + { + } + + /// + /// Sets the scalar property with the given name, or does nothing if no such property + /// exists. + /// + public void SetScalarProperty(string propertyName, double value) + { + } + + sealed partial class Tips_AnimatedVisual_UAPv15 + : Microsoft.UI.Xaml.Controls.IAnimatedVisual + , Microsoft.UI.Xaml.Controls.IAnimatedVisual2 + { + const long c_durationTicks = 5000000; + readonly Compositor _c; + readonly ExpressionAnimation _reusableExpressionAnimation; + AnimationController _animationController_0; + CompositionColorBrush _animatedColorBrush_TransparentWhite_to_White; + CompositionColorBrush _animatedColorBrush_White_to_TransparentWhite; + CompositionContainerShape _containerShape_00; + CompositionContainerShape _containerShape_05; + CompositionContainerShape _containerShape_10; + CompositionContainerShape _containerShape_14; + CompositionContainerShape _containerShape_19; + CompositionContainerShape _containerShape_20; + ContainerVisual _root; + StepEasingFunction _holdThenStepEasingFunction; + + void BindProperty( + CompositionObject target, + string animatedPropertyName, + string expression, + string referenceParameterName, + CompositionObject referencedObject) + { + _reusableExpressionAnimation.ClearAllParameters(); + _reusableExpressionAnimation.Expression = expression; + _reusableExpressionAnimation.SetReferenceParameter(referenceParameterName, referencedObject); + target.StartAnimation(animatedPropertyName, _reusableExpressionAnimation); + } + + ColorKeyFrameAnimation CreateColorKeyFrameAnimation(float initialProgress, Color initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateColorKeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InterpolationColorSpace = CompositionColorSpace.Rgb; + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + ScalarKeyFrameAnimation CreateScalarKeyFrameAnimation(float initialProgress, float initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateScalarKeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + AnimationController AnimationController_0() + { + if (_animationController_0 != null) { return _animationController_0; } + var result = _animationController_0 = _c.CreateAnimationController(); + result.Pause(); + BindProperty(_animationController_0, "Progress", "_.Progress", "_", _root); + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Shape + // - - - - ShapeGroup: Shape + // - - Path 1 + CanvasGeometry Geometry_0() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(2.68899989F, 0.104999997F)); + builder.AddLine(new Vector2(3.07200003F, -1.5F)); + builder.AddLine(new Vector2(-3.07200003F, -1.5F)); + builder.AddLine(new Vector2(-2.68899989F, 0.104999997F)); + builder.AddLine(new Vector2(-2.65199995F, 0.238999993F)); + builder.AddCubicBezier(new Vector2(-2.41100001F, 0.984000027F), new Vector2(-1.69400001F, 1.5F), new Vector2(-0.875F, 1.5F)); + builder.AddLine(new Vector2(0.874000013F, 1.5F)); + builder.AddLine(new Vector2(1.01800001F, 1.495F)); + builder.AddCubicBezier(new Vector2(1.82299995F, 1.43499994F), new Vector2(2.50500011F, 0.875999987F), new Vector2(2.68899989F, 0.104999997F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Shape + // - - - - ShapeGroup: Shape + // - - Path 1 + CanvasGeometry Geometry_1() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(6F, -0.200000003F)); + builder.AddCubicBezier(new Vector2(6F, -3.40300012F), new Vector2(3.31399989F, -6F), new Vector2(0F, -6F)); + builder.AddCubicBezier(new Vector2(-3.24699998F, -6F), new Vector2(-5.89300013F, -3.50600004F), new Vector2(-5.99700022F, -0.391000003F)); + builder.AddLine(new Vector2(-6F, -0.200000003F)); + builder.AddLine(new Vector2(-5.99499989F, 0.0390000008F)); + builder.AddCubicBezier(new Vector2(-5.92700005F, 1.62399995F), new Vector2(-5.18499994F, 3.08200002F), new Vector2(-3.79500008F, 4.39400005F)); + builder.AddCubicBezier(new Vector2(-3.71000004F, 4.47399998F), new Vector2(-3.65100002F, 4.57700014F), new Vector2(-3.62400007F, 4.68900013F)); + builder.AddLine(new Vector2(-3.31100011F, 6F)); + builder.AddLine(new Vector2(3.31100011F, 6F)); + builder.AddLine(new Vector2(3.625F, 4.6880002F)); + builder.AddLine(new Vector2(3.65100002F, 4.60699987F)); + builder.AddCubicBezier(new Vector2(3.68300009F, 4.52699995F), new Vector2(3.73200011F, 4.454F), new Vector2(3.796F, 4.39400005F)); + builder.AddCubicBezier(new Vector2(5.25500011F, 3.01600003F), new Vector2(6F, 1.477F), new Vector2(6F, -0.200000003F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - Layer aggregator + // - - - - ShapeGroup: Subtract + // - - Path 1 + CanvasGeometry Geometry_2() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(0.5F, -2.50099993F)); + builder.AddCubicBezier(new Vector2(0.5F, -2.77699995F), new Vector2(0.275999993F, -3.00099993F), new Vector2(0F, -3.00099993F)); + builder.AddCubicBezier(new Vector2(-0.275999993F, -3.00099993F), new Vector2(-0.5F, -2.77699995F), new Vector2(-0.5F, -2.50099993F)); + builder.AddLine(new Vector2(-0.5F, 2.00099993F)); + builder.AddLine(new Vector2(-3.31100011F, 2.00099993F)); + builder.AddLine(new Vector2(-3.07200003F, 3.00099993F)); + builder.AddLine(new Vector2(3.07299995F, 3.00099993F)); + builder.AddLine(new Vector2(3.31100011F, 2.00099993F)); + builder.AddLine(new Vector2(0.5F, 2.00099993F)); + builder.AddLine(new Vector2(0.5F, -2.50099993F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Subtract + // - - - - ShapeGroup: Subtract + CanvasGeometry Geometry_3() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(0.501999974F, -1.00100005F)); + builder.AddCubicBezier(new Vector2(0.501999974F, -1.27699995F), new Vector2(0.277999997F, -1.50100005F), new Vector2(0.00200000009F, -1.50100005F)); + builder.AddCubicBezier(new Vector2(-0.273999989F, -1.50100005F), new Vector2(-0.497999996F, -1.27699995F), new Vector2(-0.497999996F, -1.00100005F)); + builder.AddLine(new Vector2(-0.497999996F, 0.00100000005F)); + builder.AddCubicBezier(new Vector2(-0.497999996F, 0.27700001F), new Vector2(-0.273999989F, 0.500999987F), new Vector2(0.00200000009F, 0.500999987F)); + builder.AddCubicBezier(new Vector2(0.277999997F, 0.500999987F), new Vector2(0.501999974F, 0.27700001F), new Vector2(0.501999974F, 0.00100000005F)); + builder.AddLine(new Vector2(0.501999974F, -1.00100005F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(2.65799999F, -0.254999995F), new Vector2(2.34100008F, -0.254999995F), new Vector2(2.14599991F, -0.0599999987F)); + builder.AddLine(new Vector2(1.43799996F, 0.648000002F)); + builder.AddCubicBezier(new Vector2(1.24300003F, 0.842999995F), new Vector2(1.24300003F, 1.15999997F), new Vector2(1.43799996F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(1.63300002F, 1.54999995F), new Vector2(1.95000005F, 1.54999995F), new Vector2(2.14499998F, 1.35500002F)); + builder.AddLine(new Vector2(2.85299993F, 0.647000015F)); + builder.AddCubicBezier(new Vector2(3.0480001F, 0.451999992F), new Vector2(3.0480001F, 0.135000005F), new Vector2(2.85299993F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(-2.14499998F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-2.33999991F, -0.254999995F), new Vector2(-2.65799999F, -0.254999995F), new Vector2(-2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-3.0480001F, 0.135000005F), new Vector2(-3.0480001F, 0.451999992F), new Vector2(-2.85299993F, 0.647000015F)); + builder.AddLine(new Vector2(-2.14400005F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.949F, 1.54999995F), new Vector2(-1.63199997F, 1.54999995F), new Vector2(-1.43700004F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.24199998F, 1.15999997F), new Vector2(-1.24199998F, 0.842999995F), new Vector2(-1.43700004F, 0.648000002F)); + builder.AddLine(new Vector2(-2.14499998F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Subtract 2 + // - - - - ShapeGroup: Subtract + CanvasGeometry Geometry_4() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(0.501999974F, -1.00100005F)); + builder.AddCubicBezier(new Vector2(0.501999974F, -1.27699995F), new Vector2(0.277999997F, -1.50100005F), new Vector2(0.00200000009F, -1.50100005F)); + builder.AddCubicBezier(new Vector2(-0.273999989F, -1.50100005F), new Vector2(-0.497999996F, -1.27699995F), new Vector2(-0.497999996F, -1.00100005F)); + builder.AddLine(new Vector2(-0.497999996F, 0.00100000005F)); + builder.AddCubicBezier(new Vector2(-0.497999996F, 0.27700001F), new Vector2(-0.273999989F, 0.500999987F), new Vector2(0.00200000009F, 0.500999987F)); + builder.AddCubicBezier(new Vector2(0.277999997F, 0.500999987F), new Vector2(0.501999974F, 0.27700001F), new Vector2(0.501999974F, 0.00100000005F)); + builder.AddLine(new Vector2(0.501999974F, -1.00100005F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(2.65799999F, -0.254999995F), new Vector2(2.34100008F, -0.254999995F), new Vector2(2.14599991F, -0.0599999987F)); + builder.AddLine(new Vector2(1.43799996F, 0.648000002F)); + builder.AddCubicBezier(new Vector2(1.24300003F, 0.842999995F), new Vector2(1.24300003F, 1.15999997F), new Vector2(1.43799996F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(1.63300002F, 1.54999995F), new Vector2(1.95000005F, 1.54999995F), new Vector2(2.14499998F, 1.35500002F)); + builder.AddLine(new Vector2(2.85299993F, 0.647000015F)); + builder.AddCubicBezier(new Vector2(3.0480001F, 0.451999992F), new Vector2(3.0480001F, 0.135000005F), new Vector2(2.85299993F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(-2.14499998F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-2.33999991F, -0.254999995F), new Vector2(-2.65799999F, -0.254999995F), new Vector2(-2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-3.0480001F, 0.135000005F), new Vector2(-3.0480001F, 0.451999992F), new Vector2(-2.85299993F, 0.647000015F)); + builder.AddLine(new Vector2(-2.14400005F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.949F, 1.54999995F), new Vector2(-1.63199997F, 1.54999995F), new Vector2(-1.43700004F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.24199998F, 1.15999997F), new Vector2(-1.24199998F, 0.842999995F), new Vector2(-1.43700004F, 0.648000002F)); + builder.AddLine(new Vector2(-2.14499998F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Subtract 2 + // - - - ShapeGroup: Subtract + // Color + ColorKeyFrameAnimation ColorAnimation_TransparentWhite_to_White() + { + // Frame 0. + var result = CreateColorKeyFrameAnimation(0F, Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF), HoldThenStepEasingFunction()); + // Frame 24. + // White + result.InsertKeyFrame(0.800000012F, Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Subtract + // - - - ShapeGroup: Subtract + // Color + ColorKeyFrameAnimation ColorAnimation_White_to_TransparentWhite() + { + // Frame 0. + var result = CreateColorKeyFrameAnimation(0F, Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF), HoldThenStepEasingFunction()); + // Frame 10. + // TransparentWhite + result.InsertKeyFrame(0.333333343F, Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + // Frame 24. + // TransparentWhite + result.InsertKeyFrame(0.800000012F, Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract 2 + // - - ShapeGroup: Subtract + CompositionColorBrush AnimatedColorBrush_TransparentWhite_to_White() + { + if (_animatedColorBrush_TransparentWhite_to_White != null) { return _animatedColorBrush_TransparentWhite_to_White; } + var result = _animatedColorBrush_TransparentWhite_to_White = _c.CreateColorBrush(); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract + // - - ShapeGroup: Subtract + CompositionColorBrush AnimatedColorBrush_White_to_TransparentWhite() + { + if (_animatedColorBrush_White_to_TransparentWhite != null) { return _animatedColorBrush_White_to_TransparentWhite; } + var result = _animatedColorBrush_White_to_TransparentWhite = _c.CreateColorBrush(); + return result; + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Subtract + // Path 1 + CompositionColorBrush ColorBrush_White() + { + return _c.CreateColorBrush(Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 0 + CompositionColorGradientStop GradientStop_0_AlmostKhaki_FFF8DA79_0() + { + return _c.CreateColorGradientStop(0F, Color.FromArgb(0xFF, 0xF8, 0xDA, 0x79)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 0 + CompositionColorGradientStop GradientStop_0_AlmostKhaki_FFF8DA79_1() + { + return _c.CreateColorGradientStop(0F, Color.FromArgb(0xFF, 0xF8, 0xDA, 0x79)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 1 + CompositionColorGradientStop GradientStop_1_AlmostSandyBrown_FFEDBB43_0() + { + return _c.CreateColorGradientStop(1F, Color.FromArgb(0xFF, 0xED, 0xBB, 0x43)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 1 + CompositionColorGradientStop GradientStop_1_AlmostSandyBrown_FFEDBB43_1() + { + return _c.CreateColorGradientStop(1F, Color.FromArgb(0xFF, 0xED, 0xBB, 0x43)); + } + + // Layer aggregator + CompositionContainerShape ContainerShape_00() + { + if (_containerShape_00 != null) { return _containerShape_00; } + var result = _containerShape_00 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Shape + result.Shapes.Add(ContainerShape_01()); + return result; + } + + // - Layer aggregator + // Transforms for Shape + CompositionContainerShape ContainerShape_01() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0.00499999989F, 45.0149994F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_02()); + return result; + } + + // - - Layer aggregator + // Transforms: Shape + CompositionContainerShape ContainerShape_02() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Shape + result.Shapes.Add(ContainerShape_03()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_03() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_04()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_04() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_0()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_05() + { + if (_containerShape_05 != null) { return _containerShape_05; } + var result = _containerShape_05 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Shape + result.Shapes.Add(ContainerShape_06()); + return result; + } + + // - Layer aggregator + // Transforms for Shape + CompositionContainerShape ContainerShape_06() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, -39.9850006F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_07()); + return result; + } + + // - - Layer aggregator + // Transforms: Shape + CompositionContainerShape ContainerShape_07() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Shape + result.Shapes.Add(ContainerShape_08()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_08() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_09()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_09() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_1()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_10() + { + if (_containerShape_10 != null) { return _containerShape_10; } + var result = _containerShape_10 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + result.Shapes.Add(ContainerShape_11()); + return result; + } + + // - Layer aggregator + CompositionContainerShape ContainerShape_11() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Subtract + result.Shapes.Add(ContainerShape_12()); + return result; + } + + // - - Layer aggregator + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_12() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_13()); + return result; + } + + // - - - Layer aggregator + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_13() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_2()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_14() + { + if (_containerShape_14 != null) { return _containerShape_14; } + var result = _containerShape_14 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Subtract + result.Shapes.Add(ContainerShape_15()); + return result; + } + + // - Layer aggregator + // Transforms for Subtract + CompositionContainerShape ContainerShape_15() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 16F); + result.Offset = new Vector2(-0.023F, -44.9510002F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_16()); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract + CompositionContainerShape ContainerShape_16() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Subtract + result.Shapes.Add(ContainerShape_17()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Subtract + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_17() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_18()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Subtract + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_18() + { + var result = _c.CreateContainerShape(); + result.Shapes.Add(SpriteShape_3()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_19() + { + if (_containerShape_19 != null) { return _containerShape_19; } + var result = _containerShape_19 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Subtract 2 + result.Shapes.Add(ContainerShape_20()); + return result; + } + + // - Layer aggregator + // Transforms for Subtract 2 + CompositionContainerShape ContainerShape_20() + { + if (_containerShape_20 != null) { return _containerShape_20; } + var result = _containerShape_20 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 16F); + result.Offset = new Vector2(-0.023F, -44.9510002F); + result.RotationAngleInDegrees = 0F; + result.Shapes.Add(ContainerShape_21()); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract 2 + CompositionContainerShape ContainerShape_21() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Subtract + result.Shapes.Add(ContainerShape_22()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Subtract 2 + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_22() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_23()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Subtract 2 + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_23() + { + var result = _c.CreateContainerShape(); + result.Shapes.Add(SpriteShape_4()); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionLinearGradientBrush LinearGradientBrush_0() + { + var result = _c.CreateLinearGradientBrush(); + var colorStops = result.ColorStops; + colorStops.Add(GradientStop_0_AlmostKhaki_FFF8DA79_0()); + colorStops.Add(GradientStop_1_AlmostSandyBrown_FFEDBB43_0()); + result.MappingMode = CompositionMappingMode.Absolute; + result.StartPoint = new Vector2(0F, -1.5F); + result.EndPoint = new Vector2(0F, 1.5F); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionLinearGradientBrush LinearGradientBrush_1() + { + var result = _c.CreateLinearGradientBrush(); + var colorStops = result.ColorStops; + colorStops.Add(GradientStop_0_AlmostKhaki_FFF8DA79_1()); + colorStops.Add(GradientStop_1_AlmostSandyBrown_FFEDBB43_1()); + result.MappingMode = CompositionMappingMode.Absolute; + result.StartPoint = new Vector2(0F, -6F); + result.EndPoint = new Vector2(0F, 6F); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionPathGeometry PathGeometry_0() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_0())); + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionPathGeometry PathGeometry_1() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_1())); + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Subtract + // Path 1 + CompositionPathGeometry PathGeometry_2() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_2())); + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract + // - - ShapeGroup: Subtract + CompositionPathGeometry PathGeometry_3() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_3())); + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract 2 + // - - ShapeGroup: Subtract + CompositionPathGeometry PathGeometry_4() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_4())); + } + + // - - - - - Layer aggregator + // - - - Transforms: Shape + // - ShapeGroup: Shape + // Path 1 + CompositionSpriteShape SpriteShape_0() + { + var result = _c.CreateSpriteShape(PathGeometry_0()); + result.FillBrush = LinearGradientBrush_0(); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Shape + // - ShapeGroup: Shape + // Path 1 + CompositionSpriteShape SpriteShape_1() + { + var result = _c.CreateSpriteShape(PathGeometry_1()); + result.FillBrush = LinearGradientBrush_1(); + return result; + } + + // - - - - Layer aggregator + // - ShapeGroup: Subtract + // Path 1 + CompositionSpriteShape SpriteShape_2() + { + var result = _c.CreateSpriteShape(PathGeometry_2()); + result.FillBrush = ColorBrush_White(); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Subtract + // - ShapeGroup: Subtract + CompositionSpriteShape SpriteShape_3() + { + var result = _c.CreateSpriteShape(PathGeometry_3()); + result.FillBrush = AnimatedColorBrush_White_to_TransparentWhite(); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Subtract 2 + // - ShapeGroup: Subtract + CompositionSpriteShape SpriteShape_4() + { + var result = _c.CreateSpriteShape(PathGeometry_4()); + result.FillBrush = AnimatedColorBrush_TransparentWhite_to_White(); + return result; + } + + // The root of the composition. + ContainerVisual Root() + { + if (_root != null) { return _root; } + var result = _root = _c.CreateContainerVisual(); + var propertySet = result.Properties; + propertySet.InsertScalar("Progress", 0F); + // Layer aggregator + result.Children.InsertAtTop(ShapeVisual_0()); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract 2 + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_0_to_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 0F, HoldThenStepEasingFunction()); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_0() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_2() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_3() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_4() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract 2 + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_0_to_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 0F, HoldThenStepEasingFunction()); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_0() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_2() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_3() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_4() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // Layer aggregator + ShapeVisual ShapeVisual_0() + { + var result = _c.CreateShapeVisual(); + result.Size = new Vector2(200F, 200F); + var shapes = result.Shapes; + shapes.Add(ContainerShape_00()); + shapes.Add(ContainerShape_05()); + shapes.Add(ContainerShape_10()); + shapes.Add(ContainerShape_14()); + shapes.Add(ContainerShape_19()); + return result; + } + + StepEasingFunction HoldThenStepEasingFunction() + { + if (_holdThenStepEasingFunction != null) { return _holdThenStepEasingFunction; } + var result = _holdThenStepEasingFunction = _c.CreateStepEasingFunction(); + result.FinalStep = 1; + result.IsFinalStepSingleFrame = true; + result.StepCount = 1; + return result; + } + + internal Tips_AnimatedVisual_UAPv15( + Compositor compositor + ) + { + _c = compositor; + _reusableExpressionAnimation = compositor.CreateExpressionAnimation(); + Root(); + } + + public Visual RootVisual => _root; + public TimeSpan Duration => TimeSpan.FromTicks(c_durationTicks); + public Vector2 Size => new Vector2(200F, 200F); + void IDisposable.Dispose() => _root?.Dispose(); + + public void CreateAnimations() + { + _animatedColorBrush_TransparentWhite_to_White.StartAnimation("Color", ColorAnimation_TransparentWhite_to_White(), AnimationController_0()); + _animatedColorBrush_White_to_TransparentWhite.StartAnimation("Color", ColorAnimation_White_to_TransparentWhite(), AnimationController_0()); + _containerShape_00.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_0(), AnimationController_0()); + _containerShape_00.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_0(), AnimationController_0()); + _containerShape_05.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_1(), AnimationController_0()); + _containerShape_05.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_1(), AnimationController_0()); + _containerShape_10.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_2(), AnimationController_0()); + _containerShape_10.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_2(), AnimationController_0()); + _containerShape_14.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_3(), AnimationController_0()); + _containerShape_14.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_3(), AnimationController_0()); + _containerShape_19.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_4(), AnimationController_0()); + _containerShape_19.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_4(), AnimationController_0()); + _containerShape_20.StartAnimation("Scale.X", ScaleXScalarAnimation_0_to_1(), AnimationController_0()); + _containerShape_20.StartAnimation("Scale.Y", ScaleYScalarAnimation_0_to_1(), AnimationController_0()); + } + + public void DestroyAnimations() + { + _animatedColorBrush_TransparentWhite_to_White.StopAnimation("Color"); + _animatedColorBrush_White_to_TransparentWhite.StopAnimation("Color"); + _containerShape_00.StopAnimation("Scale.X"); + _containerShape_00.StopAnimation("Scale.Y"); + _containerShape_05.StopAnimation("Scale.X"); + _containerShape_05.StopAnimation("Scale.Y"); + _containerShape_10.StopAnimation("Scale.X"); + _containerShape_10.StopAnimation("Scale.Y"); + _containerShape_14.StopAnimation("Scale.X"); + _containerShape_14.StopAnimation("Scale.Y"); + _containerShape_19.StopAnimation("Scale.X"); + _containerShape_19.StopAnimation("Scale.Y"); + _containerShape_20.StopAnimation("Scale.X"); + _containerShape_20.StopAnimation("Scale.Y"); + } + + internal static bool IsRuntimeCompatible() + { + return Windows.Foundation.Metadata.ApiInformation.IsApiContractPresent("Windows.Foundation.UniversalApiContract", 15); + } + } + + sealed partial class Tips_AnimatedVisual_UAPv7 + : Microsoft.UI.Xaml.Controls.IAnimatedVisual + , Microsoft.UI.Xaml.Controls.IAnimatedVisual2 + { + const long c_durationTicks = 5000000; + readonly Compositor _c; + readonly ExpressionAnimation _reusableExpressionAnimation; + CompositionColorBrush _animatedColorBrush_TransparentWhite_to_White; + CompositionColorBrush _animatedColorBrush_White_to_TransparentWhite; + CompositionContainerShape _containerShape_00; + CompositionContainerShape _containerShape_05; + CompositionContainerShape _containerShape_10; + CompositionContainerShape _containerShape_14; + CompositionContainerShape _containerShape_19; + CompositionContainerShape _containerShape_20; + ContainerVisual _root; + StepEasingFunction _holdThenStepEasingFunction; + + void BindProperty( + CompositionObject target, + string animatedPropertyName, + string expression, + string referenceParameterName, + CompositionObject referencedObject) + { + _reusableExpressionAnimation.ClearAllParameters(); + _reusableExpressionAnimation.Expression = expression; + _reusableExpressionAnimation.SetReferenceParameter(referenceParameterName, referencedObject); + target.StartAnimation(animatedPropertyName, _reusableExpressionAnimation); + } + + ColorKeyFrameAnimation CreateColorKeyFrameAnimation(float initialProgress, Color initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateColorKeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InterpolationColorSpace = CompositionColorSpace.Rgb; + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + ScalarKeyFrameAnimation CreateScalarKeyFrameAnimation(float initialProgress, float initialValue, CompositionEasingFunction initialEasingFunction) + { + var result = _c.CreateScalarKeyFrameAnimation(); + result.Duration = TimeSpan.FromTicks(c_durationTicks); + result.InsertKeyFrame(initialProgress, initialValue, initialEasingFunction); + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Shape + // - - - - ShapeGroup: Shape + // - - Path 1 + CanvasGeometry Geometry_0() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(2.68899989F, 0.104999997F)); + builder.AddLine(new Vector2(3.07200003F, -1.5F)); + builder.AddLine(new Vector2(-3.07200003F, -1.5F)); + builder.AddLine(new Vector2(-2.68899989F, 0.104999997F)); + builder.AddLine(new Vector2(-2.65199995F, 0.238999993F)); + builder.AddCubicBezier(new Vector2(-2.41100001F, 0.984000027F), new Vector2(-1.69400001F, 1.5F), new Vector2(-0.875F, 1.5F)); + builder.AddLine(new Vector2(0.874000013F, 1.5F)); + builder.AddLine(new Vector2(1.01800001F, 1.495F)); + builder.AddCubicBezier(new Vector2(1.82299995F, 1.43499994F), new Vector2(2.50500011F, 0.875999987F), new Vector2(2.68899989F, 0.104999997F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Shape + // - - - - ShapeGroup: Shape + // - - Path 1 + CanvasGeometry Geometry_1() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(6F, -0.200000003F)); + builder.AddCubicBezier(new Vector2(6F, -3.40300012F), new Vector2(3.31399989F, -6F), new Vector2(0F, -6F)); + builder.AddCubicBezier(new Vector2(-3.24699998F, -6F), new Vector2(-5.89300013F, -3.50600004F), new Vector2(-5.99700022F, -0.391000003F)); + builder.AddLine(new Vector2(-6F, -0.200000003F)); + builder.AddLine(new Vector2(-5.99499989F, 0.0390000008F)); + builder.AddCubicBezier(new Vector2(-5.92700005F, 1.62399995F), new Vector2(-5.18499994F, 3.08200002F), new Vector2(-3.79500008F, 4.39400005F)); + builder.AddCubicBezier(new Vector2(-3.71000004F, 4.47399998F), new Vector2(-3.65100002F, 4.57700014F), new Vector2(-3.62400007F, 4.68900013F)); + builder.AddLine(new Vector2(-3.31100011F, 6F)); + builder.AddLine(new Vector2(3.31100011F, 6F)); + builder.AddLine(new Vector2(3.625F, 4.6880002F)); + builder.AddLine(new Vector2(3.65100002F, 4.60699987F)); + builder.AddCubicBezier(new Vector2(3.68300009F, 4.52699995F), new Vector2(3.73200011F, 4.454F), new Vector2(3.796F, 4.39400005F)); + builder.AddCubicBezier(new Vector2(5.25500011F, 3.01600003F), new Vector2(6F, 1.477F), new Vector2(6F, -0.200000003F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - Layer aggregator + // - - - - ShapeGroup: Subtract + // - - Path 1 + CanvasGeometry Geometry_2() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(0.5F, -2.50099993F)); + builder.AddCubicBezier(new Vector2(0.5F, -2.77699995F), new Vector2(0.275999993F, -3.00099993F), new Vector2(0F, -3.00099993F)); + builder.AddCubicBezier(new Vector2(-0.275999993F, -3.00099993F), new Vector2(-0.5F, -2.77699995F), new Vector2(-0.5F, -2.50099993F)); + builder.AddLine(new Vector2(-0.5F, 2.00099993F)); + builder.AddLine(new Vector2(-3.31100011F, 2.00099993F)); + builder.AddLine(new Vector2(-3.07200003F, 3.00099993F)); + builder.AddLine(new Vector2(3.07299995F, 3.00099993F)); + builder.AddLine(new Vector2(3.31100011F, 2.00099993F)); + builder.AddLine(new Vector2(0.5F, 2.00099993F)); + builder.AddLine(new Vector2(0.5F, -2.50099993F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Subtract + // - - - - ShapeGroup: Subtract + CanvasGeometry Geometry_3() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(0.501999974F, -1.00100005F)); + builder.AddCubicBezier(new Vector2(0.501999974F, -1.27699995F), new Vector2(0.277999997F, -1.50100005F), new Vector2(0.00200000009F, -1.50100005F)); + builder.AddCubicBezier(new Vector2(-0.273999989F, -1.50100005F), new Vector2(-0.497999996F, -1.27699995F), new Vector2(-0.497999996F, -1.00100005F)); + builder.AddLine(new Vector2(-0.497999996F, 0.00100000005F)); + builder.AddCubicBezier(new Vector2(-0.497999996F, 0.27700001F), new Vector2(-0.273999989F, 0.500999987F), new Vector2(0.00200000009F, 0.500999987F)); + builder.AddCubicBezier(new Vector2(0.277999997F, 0.500999987F), new Vector2(0.501999974F, 0.27700001F), new Vector2(0.501999974F, 0.00100000005F)); + builder.AddLine(new Vector2(0.501999974F, -1.00100005F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(2.65799999F, -0.254999995F), new Vector2(2.34100008F, -0.254999995F), new Vector2(2.14599991F, -0.0599999987F)); + builder.AddLine(new Vector2(1.43799996F, 0.648000002F)); + builder.AddCubicBezier(new Vector2(1.24300003F, 0.842999995F), new Vector2(1.24300003F, 1.15999997F), new Vector2(1.43799996F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(1.63300002F, 1.54999995F), new Vector2(1.95000005F, 1.54999995F), new Vector2(2.14499998F, 1.35500002F)); + builder.AddLine(new Vector2(2.85299993F, 0.647000015F)); + builder.AddCubicBezier(new Vector2(3.0480001F, 0.451999992F), new Vector2(3.0480001F, 0.135000005F), new Vector2(2.85299993F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(-2.14499998F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-2.33999991F, -0.254999995F), new Vector2(-2.65799999F, -0.254999995F), new Vector2(-2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-3.0480001F, 0.135000005F), new Vector2(-3.0480001F, 0.451999992F), new Vector2(-2.85299993F, 0.647000015F)); + builder.AddLine(new Vector2(-2.14400005F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.949F, 1.54999995F), new Vector2(-1.63199997F, 1.54999995F), new Vector2(-1.43700004F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.24199998F, 1.15999997F), new Vector2(-1.24199998F, 0.842999995F), new Vector2(-1.43700004F, 0.648000002F)); + builder.AddLine(new Vector2(-2.14499998F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - - Layer aggregator + // - - - - - - Transforms: Subtract 2 + // - - - - ShapeGroup: Subtract + CanvasGeometry Geometry_4() + { + CanvasGeometry result; + using (var builder = new CanvasPathBuilder(null)) + { + builder.SetFilledRegionDetermination(CanvasFilledRegionDetermination.Winding); + builder.BeginFigure(new Vector2(0.501999974F, -1.00100005F)); + builder.AddCubicBezier(new Vector2(0.501999974F, -1.27699995F), new Vector2(0.277999997F, -1.50100005F), new Vector2(0.00200000009F, -1.50100005F)); + builder.AddCubicBezier(new Vector2(-0.273999989F, -1.50100005F), new Vector2(-0.497999996F, -1.27699995F), new Vector2(-0.497999996F, -1.00100005F)); + builder.AddLine(new Vector2(-0.497999996F, 0.00100000005F)); + builder.AddCubicBezier(new Vector2(-0.497999996F, 0.27700001F), new Vector2(-0.273999989F, 0.500999987F), new Vector2(0.00200000009F, 0.500999987F)); + builder.AddCubicBezier(new Vector2(0.277999997F, 0.500999987F), new Vector2(0.501999974F, 0.27700001F), new Vector2(0.501999974F, 0.00100000005F)); + builder.AddLine(new Vector2(0.501999974F, -1.00100005F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(2.65799999F, -0.254999995F), new Vector2(2.34100008F, -0.254999995F), new Vector2(2.14599991F, -0.0599999987F)); + builder.AddLine(new Vector2(1.43799996F, 0.648000002F)); + builder.AddCubicBezier(new Vector2(1.24300003F, 0.842999995F), new Vector2(1.24300003F, 1.15999997F), new Vector2(1.43799996F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(1.63300002F, 1.54999995F), new Vector2(1.95000005F, 1.54999995F), new Vector2(2.14499998F, 1.35500002F)); + builder.AddLine(new Vector2(2.85299993F, 0.647000015F)); + builder.AddCubicBezier(new Vector2(3.0480001F, 0.451999992F), new Vector2(3.0480001F, 0.135000005F), new Vector2(2.85299993F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + builder.BeginFigure(new Vector2(-2.14499998F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-2.33999991F, -0.254999995F), new Vector2(-2.65799999F, -0.254999995F), new Vector2(-2.85299993F, -0.0599999987F)); + builder.AddCubicBezier(new Vector2(-3.0480001F, 0.135000005F), new Vector2(-3.0480001F, 0.451999992F), new Vector2(-2.85299993F, 0.647000015F)); + builder.AddLine(new Vector2(-2.14400005F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.949F, 1.54999995F), new Vector2(-1.63199997F, 1.54999995F), new Vector2(-1.43700004F, 1.35500002F)); + builder.AddCubicBezier(new Vector2(-1.24199998F, 1.15999997F), new Vector2(-1.24199998F, 0.842999995F), new Vector2(-1.43700004F, 0.648000002F)); + builder.AddLine(new Vector2(-2.14499998F, -0.0599999987F)); + builder.EndFigure(CanvasFigureLoop.Closed); + result = CanvasGeometry.CreatePath(builder); + } + return result; + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Subtract 2 + // - - - ShapeGroup: Subtract + // Color + ColorKeyFrameAnimation ColorAnimation_TransparentWhite_to_White() + { + // Frame 0. + var result = CreateColorKeyFrameAnimation(0F, Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF), HoldThenStepEasingFunction()); + // Frame 24. + // White + result.InsertKeyFrame(0.800000012F, Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Subtract + // - - - ShapeGroup: Subtract + // Color + ColorKeyFrameAnimation ColorAnimation_White_to_TransparentWhite() + { + // Frame 0. + var result = CreateColorKeyFrameAnimation(0F, Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF), HoldThenStepEasingFunction()); + // Frame 10. + // TransparentWhite + result.InsertKeyFrame(0.333333343F, Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + // Frame 24. + // TransparentWhite + result.InsertKeyFrame(0.800000012F, Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF), _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract 2 + // - - ShapeGroup: Subtract + CompositionColorBrush AnimatedColorBrush_TransparentWhite_to_White() + { + if (_animatedColorBrush_TransparentWhite_to_White != null) { return _animatedColorBrush_TransparentWhite_to_White; } + var result = _animatedColorBrush_TransparentWhite_to_White = _c.CreateColorBrush(); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract + // - - ShapeGroup: Subtract + CompositionColorBrush AnimatedColorBrush_White_to_TransparentWhite() + { + if (_animatedColorBrush_White_to_TransparentWhite != null) { return _animatedColorBrush_White_to_TransparentWhite; } + var result = _animatedColorBrush_White_to_TransparentWhite = _c.CreateColorBrush(); + return result; + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Subtract + // Path 1 + CompositionColorBrush ColorBrush_White() + { + return _c.CreateColorBrush(Color.FromArgb(0xFF, 0xFF, 0xFF, 0xFF)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 0 + CompositionColorGradientStop GradientStop_0_AlmostKhaki_FFF8DA79_0() + { + return _c.CreateColorGradientStop(0F, Color.FromArgb(0xFF, 0xF8, 0xDA, 0x79)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 0 + CompositionColorGradientStop GradientStop_0_AlmostKhaki_FFF8DA79_1() + { + return _c.CreateColorGradientStop(0F, Color.FromArgb(0xFF, 0xF8, 0xDA, 0x79)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 1 + CompositionColorGradientStop GradientStop_1_AlmostSandyBrown_FFEDBB43_0() + { + return _c.CreateColorGradientStop(1F, Color.FromArgb(0xFF, 0xED, 0xBB, 0x43)); + } + + // - - - - - - - Layer aggregator + // - - - - - Transforms: Shape + // - - - ShapeGroup: Shape + // - Path 1 + // Stop 1 + CompositionColorGradientStop GradientStop_1_AlmostSandyBrown_FFEDBB43_1() + { + return _c.CreateColorGradientStop(1F, Color.FromArgb(0xFF, 0xED, 0xBB, 0x43)); + } + + // Layer aggregator + CompositionContainerShape ContainerShape_00() + { + if (_containerShape_00 != null) { return _containerShape_00; } + var result = _containerShape_00 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Shape + result.Shapes.Add(ContainerShape_01()); + return result; + } + + // - Layer aggregator + // Transforms for Shape + CompositionContainerShape ContainerShape_01() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0.00499999989F, 45.0149994F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_02()); + return result; + } + + // - - Layer aggregator + // Transforms: Shape + CompositionContainerShape ContainerShape_02() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Shape + result.Shapes.Add(ContainerShape_03()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_03() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_04()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_04() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_0()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_05() + { + if (_containerShape_05 != null) { return _containerShape_05; } + var result = _containerShape_05 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Shape + result.Shapes.Add(ContainerShape_06()); + return result; + } + + // - Layer aggregator + // Transforms for Shape + CompositionContainerShape ContainerShape_06() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, -39.9850006F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_07()); + return result; + } + + // - - Layer aggregator + // Transforms: Shape + CompositionContainerShape ContainerShape_07() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Shape + result.Shapes.Add(ContainerShape_08()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_08() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_09()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Shape + // ShapeGroup: Shape + CompositionContainerShape ContainerShape_09() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_1()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_10() + { + if (_containerShape_10 != null) { return _containerShape_10; } + var result = _containerShape_10 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + result.Shapes.Add(ContainerShape_11()); + return result; + } + + // - Layer aggregator + CompositionContainerShape ContainerShape_11() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Subtract + result.Shapes.Add(ContainerShape_12()); + return result; + } + + // - - Layer aggregator + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_12() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_13()); + return result; + } + + // - - - Layer aggregator + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_13() + { + var result = _c.CreateContainerShape(); + // Path 1 + result.Shapes.Add(SpriteShape_2()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_14() + { + if (_containerShape_14 != null) { return _containerShape_14; } + var result = _containerShape_14 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Subtract + result.Shapes.Add(ContainerShape_15()); + return result; + } + + // - Layer aggregator + // Transforms for Subtract + CompositionContainerShape ContainerShape_15() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 16F); + result.Offset = new Vector2(-0.023F, -44.9510002F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(1F, 1F); + result.Shapes.Add(ContainerShape_16()); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract + CompositionContainerShape ContainerShape_16() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Subtract + result.Shapes.Add(ContainerShape_17()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Subtract + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_17() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_18()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Subtract + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_18() + { + var result = _c.CreateContainerShape(); + result.Shapes.Add(SpriteShape_3()); + return result; + } + + // Layer aggregator + CompositionContainerShape ContainerShape_19() + { + if (_containerShape_19 != null) { return _containerShape_19; } + var result = _containerShape_19 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(100F, 119.985001F); + result.RotationAngleInDegrees = 0F; + // Transforms: Subtract 2 + result.Shapes.Add(ContainerShape_20()); + return result; + } + + // - Layer aggregator + // Transforms for Subtract 2 + CompositionContainerShape ContainerShape_20() + { + if (_containerShape_20 != null) { return _containerShape_20; } + var result = _containerShape_20 = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 16F); + result.Offset = new Vector2(-0.023F, -44.9510002F); + result.RotationAngleInDegrees = 0F; + result.Shapes.Add(ContainerShape_21()); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract 2 + CompositionContainerShape ContainerShape_21() + { + var result = _c.CreateContainerShape(); + // ShapeGroup: Subtract + result.Shapes.Add(ContainerShape_22()); + return result; + } + + // - - - Layer aggregator + // - Transforms: Subtract 2 + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_22() + { + var result = _c.CreateContainerShape(); + result.CenterPoint = new Vector2(0F, 0F); + result.Offset = new Vector2(0F, 0F); + result.RotationAngleInDegrees = 0F; + result.Scale = new Vector2(10F, 10F); + result.Shapes.Add(ContainerShape_23()); + return result; + } + + // - - - - Layer aggregator + // - - Transforms: Subtract 2 + // ShapeGroup: Subtract + CompositionContainerShape ContainerShape_23() + { + var result = _c.CreateContainerShape(); + result.Shapes.Add(SpriteShape_4()); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionLinearGradientBrush LinearGradientBrush_0() + { + var result = _c.CreateLinearGradientBrush(); + var colorStops = result.ColorStops; + colorStops.Add(GradientStop_0_AlmostKhaki_FFF8DA79_0()); + colorStops.Add(GradientStop_1_AlmostSandyBrown_FFEDBB43_0()); + result.MappingMode = CompositionMappingMode.Absolute; + result.StartPoint = new Vector2(0F, -1.5F); + result.EndPoint = new Vector2(0F, 1.5F); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionLinearGradientBrush LinearGradientBrush_1() + { + var result = _c.CreateLinearGradientBrush(); + var colorStops = result.ColorStops; + colorStops.Add(GradientStop_0_AlmostKhaki_FFF8DA79_1()); + colorStops.Add(GradientStop_1_AlmostSandyBrown_FFEDBB43_1()); + result.MappingMode = CompositionMappingMode.Absolute; + result.StartPoint = new Vector2(0F, -6F); + result.EndPoint = new Vector2(0F, 6F); + return result; + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionPathGeometry PathGeometry_0() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_0())); + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Shape + // - - ShapeGroup: Shape + // Path 1 + CompositionPathGeometry PathGeometry_1() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_1())); + } + + // - - - - - Layer aggregator + // - - ShapeGroup: Subtract + // Path 1 + CompositionPathGeometry PathGeometry_2() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_2())); + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract + // - - ShapeGroup: Subtract + CompositionPathGeometry PathGeometry_3() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_3())); + } + + // - - - - - - Layer aggregator + // - - - - Transforms: Subtract 2 + // - - ShapeGroup: Subtract + CompositionPathGeometry PathGeometry_4() + { + return _c.CreatePathGeometry(new CompositionPath(Geometry_4())); + } + + // - - - - - Layer aggregator + // - - - Transforms: Shape + // - ShapeGroup: Shape + // Path 1 + CompositionSpriteShape SpriteShape_0() + { + var result = _c.CreateSpriteShape(PathGeometry_0()); + result.FillBrush = LinearGradientBrush_0(); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Shape + // - ShapeGroup: Shape + // Path 1 + CompositionSpriteShape SpriteShape_1() + { + var result = _c.CreateSpriteShape(PathGeometry_1()); + result.FillBrush = LinearGradientBrush_1(); + return result; + } + + // - - - - Layer aggregator + // - ShapeGroup: Subtract + // Path 1 + CompositionSpriteShape SpriteShape_2() + { + var result = _c.CreateSpriteShape(PathGeometry_2()); + result.FillBrush = ColorBrush_White(); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Subtract + // - ShapeGroup: Subtract + CompositionSpriteShape SpriteShape_3() + { + var result = _c.CreateSpriteShape(PathGeometry_3()); + result.FillBrush = AnimatedColorBrush_White_to_TransparentWhite(); + return result; + } + + // - - - - - Layer aggregator + // - - - Transforms: Subtract 2 + // - ShapeGroup: Subtract + CompositionSpriteShape SpriteShape_4() + { + var result = _c.CreateSpriteShape(PathGeometry_4()); + result.FillBrush = AnimatedColorBrush_TransparentWhite_to_White(); + return result; + } + + // The root of the composition. + ContainerVisual Root() + { + if (_root != null) { return _root; } + var result = _root = _c.CreateContainerVisual(); + var propertySet = result.Properties; + propertySet.InsertScalar("Progress", 0F); + // Layer aggregator + result.Children.InsertAtTop(ShapeVisual_0()); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract 2 + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_0_to_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 0F, HoldThenStepEasingFunction()); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_0() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_2() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_3() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleXScalarAnimation_1_to_1_4() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - - Layer aggregator + // Transforms: Subtract 2 + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_0_to_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 0F, HoldThenStepEasingFunction()); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.200000003F, 1F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_0() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_1() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_2() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_3() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // - Layer aggregator + // Scale + ScalarKeyFrameAnimation ScaleYScalarAnimation_1_to_1_4() + { + // Frame 0. + var result = CreateScalarKeyFrameAnimation(0F, 1F, HoldThenStepEasingFunction()); + // Frame 1. + result.InsertKeyFrame(0.0333333351F, 1.00792003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.166999996F), new Vector2(0.833000004F, 0.714999974F))); + // Frame 2. + result.InsertKeyFrame(0.0666666701F, 1.02708995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.118000001F), new Vector2(0.833000004F, 0.86500001F))); + // Frame 3. + result.InsertKeyFrame(0.100000001F, 1.03894997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.217999995F), new Vector2(0.833000004F, 0.74000001F))); + // Frame 4. + result.InsertKeyFrame(0.13333334F, 1.06402004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123000003F), new Vector2(0.833000004F, 0.838F))); + // Frame 5. + result.InsertKeyFrame(0.166666672F, 1.08773994F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.171000004F), new Vector2(0.833000004F, 0.847000003F))); + // Frame 6. + result.InsertKeyFrame(0.200000003F, 1.10764003F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.182999998F), new Vector2(0.833000004F, 0.883000016F))); + // Frame 7. + result.InsertKeyFrame(0.233333334F, 1.11573005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.287999988F), new Vector2(0.833000004F, 0.822000027F))); + // Frame 8. + result.InsertKeyFrame(0.266666681F, 1.12495005F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.157000005F), new Vector2(0.833000004F, 0.953000009F))); + // Frame 9. + result.InsertKeyFrame(0.300000012F, 1.12093997F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0.455000013F))); + // Frame 10. + result.InsertKeyFrame(0.333333343F, 1.09875F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0979999974F), new Vector2(0.833000004F, 0.791999996F))); + // Frame 11. + result.InsertKeyFrame(0.366666675F, 1.06546998F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.870999992F))); + // Frame 12. + result.InsertKeyFrame(0.400000006F, 1.04718995F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.234999999F), new Vector2(0.833000004F, 0.753000021F))); + // Frame 13. + result.InsertKeyFrame(0.433333337F, 1.01118004F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.126000002F), new Vector2(0.833000004F, 0.842999995F))); + // Frame 14. + result.InsertKeyFrame(0.466666669F, 0.979480028F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.178000003F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 15. + result.InsertKeyFrame(0.5F, 0.966099977F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.280999988F), new Vector2(0.833000004F, 0.791000009F))); + // Frame 16. + result.InsertKeyFrame(0.533333361F, 0.945890009F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.138999999F), new Vector2(0.833000004F, 0.885999978F))); + // Frame 17. + result.InsertKeyFrame(0.566666663F, 0.938359976F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.307000011F), new Vector2(0.833000004F, 0.920000017F))); + // Frame 18. + result.InsertKeyFrame(0.600000024F, 0.938619971F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0F), new Vector2(0.833000004F, 0F))); + // Frame 19. + result.InsertKeyFrame(0.633333325F, 0.944859982F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.0869999975F), new Vector2(0.833000004F, 0.769999981F))); + // Frame 20. + result.InsertKeyFrame(0.666666687F, 0.955869973F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.130999997F), new Vector2(0.833000004F, 0.869000018F))); + // Frame 21. + result.InsertKeyFrame(0.699999988F, 0.96221F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.228F), new Vector2(0.833000004F, 0.746999979F))); + // Frame 22. + result.InsertKeyFrame(0.733333349F, 0.975099981F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.123999998F), new Vector2(0.833000004F, 0.841000021F))); + // Frame 23. + result.InsertKeyFrame(0.766666651F, 0.986810029F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.174999997F), new Vector2(0.833000004F, 0.880999982F))); + // Frame 24. + result.InsertKeyFrame(0.800000012F, 0.991869986F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.275999993F), new Vector2(0.833000004F, 0.782999992F))); + // Frame 25. + result.InsertKeyFrame(0.833333313F, 1F, _c.CreateCubicBezierEasingFunction(new Vector2(0.166999996F, 0.135000005F), new Vector2(0.833000004F, 0.833000004F))); + return result; + } + + // Layer aggregator + ShapeVisual ShapeVisual_0() + { + var result = _c.CreateShapeVisual(); + result.Size = new Vector2(200F, 200F); + var shapes = result.Shapes; + shapes.Add(ContainerShape_00()); + shapes.Add(ContainerShape_05()); + shapes.Add(ContainerShape_10()); + shapes.Add(ContainerShape_14()); + shapes.Add(ContainerShape_19()); + return result; + } + + StepEasingFunction HoldThenStepEasingFunction() + { + if (_holdThenStepEasingFunction != null) { return _holdThenStepEasingFunction; } + var result = _holdThenStepEasingFunction = _c.CreateStepEasingFunction(); + result.FinalStep = 1; + result.IsFinalStepSingleFrame = true; + result.StepCount = 1; + return result; + } + + internal Tips_AnimatedVisual_UAPv7( + Compositor compositor + ) + { + _c = compositor; + _reusableExpressionAnimation = compositor.CreateExpressionAnimation(); + Root(); + } + + public Visual RootVisual => _root; + public TimeSpan Duration => TimeSpan.FromTicks(c_durationTicks); + public Vector2 Size => new Vector2(200F, 200F); + void IDisposable.Dispose() => _root?.Dispose(); + + public void CreateAnimations() + { + _animatedColorBrush_TransparentWhite_to_White.StartAnimation("Color", ColorAnimation_TransparentWhite_to_White()); + var controller = _animatedColorBrush_TransparentWhite_to_White.TryGetAnimationController("Color"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _animatedColorBrush_White_to_TransparentWhite.StartAnimation("Color", ColorAnimation_White_to_TransparentWhite()); + controller = _animatedColorBrush_White_to_TransparentWhite.TryGetAnimationController("Color"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_00.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_0()); + controller = _containerShape_00.TryGetAnimationController("Scale.X"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_00.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_0()); + controller = _containerShape_00.TryGetAnimationController("Scale.Y"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_05.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_1()); + controller = _containerShape_05.TryGetAnimationController("Scale.X"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_05.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_1()); + controller = _containerShape_05.TryGetAnimationController("Scale.Y"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_10.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_2()); + controller = _containerShape_10.TryGetAnimationController("Scale.X"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_10.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_2()); + controller = _containerShape_10.TryGetAnimationController("Scale.Y"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_14.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_3()); + controller = _containerShape_14.TryGetAnimationController("Scale.X"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_14.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_3()); + controller = _containerShape_14.TryGetAnimationController("Scale.Y"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_19.StartAnimation("Scale.X", ScaleXScalarAnimation_1_to_1_4()); + controller = _containerShape_19.TryGetAnimationController("Scale.X"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_19.StartAnimation("Scale.Y", ScaleYScalarAnimation_1_to_1_4()); + controller = _containerShape_19.TryGetAnimationController("Scale.Y"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_20.StartAnimation("Scale.X", ScaleXScalarAnimation_0_to_1()); + controller = _containerShape_20.TryGetAnimationController("Scale.X"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + _containerShape_20.StartAnimation("Scale.Y", ScaleYScalarAnimation_0_to_1()); + controller = _containerShape_20.TryGetAnimationController("Scale.Y"); + controller.Pause(); + BindProperty(controller, "Progress", "_.Progress", "_", _root); + } + + public void DestroyAnimations() + { + _animatedColorBrush_TransparentWhite_to_White.StopAnimation("Color"); + _animatedColorBrush_White_to_TransparentWhite.StopAnimation("Color"); + _containerShape_00.StopAnimation("Scale.X"); + _containerShape_00.StopAnimation("Scale.Y"); + _containerShape_05.StopAnimation("Scale.X"); + _containerShape_05.StopAnimation("Scale.Y"); + _containerShape_10.StopAnimation("Scale.X"); + _containerShape_10.StopAnimation("Scale.Y"); + _containerShape_14.StopAnimation("Scale.X"); + _containerShape_14.StopAnimation("Scale.Y"); + _containerShape_19.StopAnimation("Scale.X"); + _containerShape_19.StopAnimation("Scale.Y"); + _containerShape_20.StopAnimation("Scale.X"); + _containerShape_20.StopAnimation("Scale.Y"); + } + + internal static bool IsRuntimeCompatible() + { + return Windows.Foundation.Metadata.ApiInformation.IsApiContractPresent("Windows.Foundation.UniversalApiContract", 7); + } + } + } +} diff --git a/Telegram/Assets/Icons/Tips.json b/Telegram/Assets/Icons/Tips.json new file mode 100644 index 0000000000..43458f8dd1 --- /dev/null +++ b/Telegram/Assets/Icons/Tips.json @@ -0,0 +1 @@ +{"v":"5.12.1","fr":60,"ip":0,"op":30,"w":200,"h":200,"nm":"u_username","ddd":0,"assets":[],"layers":[{"ddd":0,"ind":1,"ty":4,"nm":"Subtract 2","parent":3,"sr":1,"ks":{"o":{"a":1,"k":[{"i":{"x":[0.2],"y":[1]},"o":{"x":[0.167],"y":[0.167]},"t":0,"s":[0]},{"t":24,"s":[100]}],"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[-0.023,-28.951,0],"ix":2,"l":2},"a":{"a":0,"k":[0,16,0],"ix":1,"l":2},"s":{"a":1,"k":[{"i":{"x":[0.2,0.2,0.2],"y":[1,1,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.167,0.167,16.667]},"t":0,"s":[0,0,100]},{"t":24,"s":[100,100,100]}],"ix":6,"l":2}},"ao":0,"shapes":[{"ty":"gr","it":[{"ind":0,"ty":"sh","ix":1,"ks":{"a":0,"k":{"i":[[0,0],[0.195,-0.195],[-0.195,-0.195],[0,0],[-0.195,0.195],[0.195,0.195]],"o":[[-0.195,-0.195],[-0.195,0.195],[0,0],[0.195,0.195],[0.195,-0.195],[0,0]],"v":[[-2.145,-0.06],[-2.853,-0.06],[-2.853,0.647],[-2.144,1.355],[-1.437,1.355],[-1.437,0.648]],"c":true},"ix":2},"nm":"Path 1","mn":"ADBE Vector Shape - Group","hd":false},{"ind":1,"ty":"sh","ix":2,"ks":{"a":0,"k":{"i":[[0.195,0.195],[0.195,-0.195],[0,0],[-0.195,-0.195],[-0.195,0.195],[0,0]],"o":[[-0.195,-0.195],[0,0],[-0.195,0.195],[0.195,0.195],[0,0],[0.195,-0.195]],"v":[[2.853,-0.06],[2.146,-0.06],[1.438,0.648],[1.438,1.355],[2.145,1.355],[2.853,0.647]],"c":true},"ix":2},"nm":"Path 2","mn":"ADBE Vector Shape - Group","hd":false},{"ind":2,"ty":"sh","ix":3,"ks":{"a":0,"k":{"i":[[0,0],[0.276,0],[0,-0.276],[0,0],[-0.276,0],[0,0.276]],"o":[[0,-0.276],[-0.276,0],[0,0],[0,0.276],[0.276,0],[0,0]],"v":[[0.502,-1.001],[0.002,-1.501],[-0.498,-1.001],[-0.498,0.001],[0.002,0.501],[0.502,0.001]],"c":true},"ix":2},"nm":"Path 3","mn":"ADBE Vector Shape - Group","hd":false},{"ty":"mm","mm":1,"nm":"Merge Paths 1","mn":"ADBE Vector Filter - Merge","hd":false},{"ty":"fl","c":{"a":0,"k":[1,1,1,1],"ix":4},"o":{"a":0,"k":100,"ix":5},"r":1,"bm":0,"nm":"Fill 1","mn":"ADBE Vector Graphic - Fill","hd":false},{"ty":"tr","p":{"a":0,"k":[0,0],"ix":2},"a":{"a":0,"k":[0,0],"ix":1},"s":{"a":0,"k":[1000,1000],"ix":3},"r":{"a":0,"k":0,"ix":6},"o":{"a":0,"k":100,"ix":7},"sk":{"a":0,"k":0,"ix":4},"sa":{"a":0,"k":0,"ix":5},"nm":"Transform"}],"nm":"Subtract","np":5,"cix":2,"bm":0,"ix":1,"mn":"ADBE Vector Group","hd":false}],"ip":0,"op":30,"st":0,"ct":1,"bm":0},{"ddd":0,"ind":2,"ty":4,"nm":"Subtract","parent":3,"sr":1,"ks":{"o":{"a":1,"k":[{"i":{"x":[0.2],"y":[1]},"o":{"x":[0.167],"y":[0.167]},"t":0,"s":[100]},{"i":{"x":[0.2],"y":[1]},"o":{"x":[0.167],"y":[0]},"t":10,"s":[0]},{"t":24,"s":[0]}],"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[-0.023,-28.951,0],"ix":2,"l":2},"a":{"a":0,"k":[0,16,0],"ix":1,"l":2},"s":{"a":0,"k":[100,100,100],"ix":6,"l":2}},"ao":0,"shapes":[{"ty":"gr","it":[{"ind":0,"ty":"sh","ix":1,"ks":{"a":1,"k":[{"i":{"x":0.2,"y":1},"o":{"x":0.167,"y":0.167},"t":0,"s":[{"i":[[0,0],[0.195,-0.195],[-0.195,-0.195],[0,0],[-0.195,0.195],[0.195,0.195]],"o":[[-0.195,-0.195],[-0.195,0.195],[0,0],[0.195,0.195],[0.195,-0.195],[0,0]],"v":[[-2.145,-0.06],[-2.853,-0.06],[-2.853,0.647],[-2.144,1.355],[-1.437,1.355],[-1.437,0.648]],"c":true}]},{"t":24,"s":[{"i":[[0,0],[0.195,-0.195],[-0.195,-0.195],[0,0],[-0.195,0.195],[0.195,0.195]],"o":[[-0.195,-0.195],[-0.195,0.195],[0,0],[0.195,0.195],[0.195,-0.195],[0,0]],"v":[[-3.461,-1.376],[-4.169,-1.376],[-4.169,-0.669],[-3.46,0.039],[-2.753,0.039],[-2.753,-0.668]],"c":true}]}],"ix":2},"nm":"Path 1","mn":"ADBE Vector Shape - Group","hd":false},{"ind":1,"ty":"sh","ix":2,"ks":{"a":1,"k":[{"i":{"x":0.2,"y":1},"o":{"x":0.167,"y":0.167},"t":0,"s":[{"i":[[0.195,0.195],[0.195,-0.195],[0,0],[-0.195,-0.195],[-0.195,0.195],[0,0]],"o":[[-0.195,-0.195],[0,0],[-0.195,0.195],[0.195,0.195],[0,0],[0.195,-0.195]],"v":[[2.853,-0.06],[2.146,-0.06],[1.438,0.648],[1.438,1.355],[2.145,1.355],[2.853,0.647]],"c":true}]},{"t":24,"s":[{"i":[[0.195,0.195],[0.195,-0.195],[0,0],[-0.195,-0.195],[-0.195,0.195],[0,0]],"o":[[-0.195,-0.195],[0,0],[-0.195,0.195],[0.195,0.195],[0,0],[0.195,-0.195]],"v":[[4.169,-1.376],[3.462,-1.376],[2.754,-0.668],[2.754,0.039],[3.461,0.039],[4.169,-0.669]],"c":true}]}],"ix":2},"nm":"Path 2","mn":"ADBE Vector Shape - Group","hd":false},{"ind":2,"ty":"sh","ix":3,"ks":{"a":1,"k":[{"i":{"x":0.2,"y":1},"o":{"x":0.167,"y":0.167},"t":0,"s":[{"i":[[0,0],[0.276,0],[0,-0.276],[0,0],[-0.276,0],[0,0.276]],"o":[[0,-0.276],[-0.276,0],[0,0],[0,0.276],[0.276,0],[0,0]],"v":[[0.502,-1.001],[0.002,-1.501],[-0.498,-1.001],[-0.498,0.001],[0.002,0.501],[0.502,0.001]],"c":true}]},{"t":24,"s":[{"i":[[0,0],[0.276,0],[0,-0.276],[0,0],[-0.276,0],[0,0.276]],"o":[[0,-0.276],[-0.276,0],[0,0],[0,0.276],[0.276,0],[0,0]],"v":[[0.502,-3.633],[0.002,-4.133],[-0.498,-3.633],[-0.498,-2.631],[0.002,-2.131],[0.502,-2.631]],"c":true}]}],"ix":2},"nm":"Path 3","mn":"ADBE Vector Shape - Group","hd":false},{"ty":"mm","mm":1,"nm":"Merge Paths 1","mn":"ADBE Vector Filter - Merge","hd":false},{"ty":"fl","c":{"a":0,"k":[1,1,1,1],"ix":4},"o":{"a":0,"k":100,"ix":5},"r":1,"bm":0,"nm":"Fill 1","mn":"ADBE Vector Graphic - Fill","hd":false},{"ty":"tr","p":{"a":0,"k":[0,0],"ix":2},"a":{"a":0,"k":[0,0],"ix":1},"s":{"a":0,"k":[1000,1000],"ix":3},"r":{"a":0,"k":0,"ix":6},"o":{"a":0,"k":100,"ix":7},"sk":{"a":0,"k":0,"ix":4},"sa":{"a":0,"k":0,"ix":5},"nm":"Transform"}],"nm":"Subtract","np":5,"cix":2,"bm":0,"ix":1,"mn":"ADBE Vector Group","hd":false}],"ip":0,"op":30,"st":0,"ct":1,"bm":0},{"ddd":0,"ind":3,"ty":4,"nm":"Subtract","sr":1,"ks":{"o":{"a":0,"k":100,"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[100,119.985,0],"ix":2,"l":2},"a":{"a":0,"k":[0,0,0],"ix":1,"l":2},"s":{"a":1,"k":[{"i":{"x":[0.833,0.833,0.833],"y":[0.715,0.715,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.167,0.167,0]},"t":0,"s":[100,100,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.865,0.865,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.118,0.118,0]},"t":1,"s":[100.792,100.792,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.74,0.74,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.218,0.218,0]},"t":2,"s":[102.709,102.709,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.838,0.838,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.123,0.123,0]},"t":3,"s":[103.895,103.895,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.847,0.847,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.171,0.171,0]},"t":4,"s":[106.402,106.402,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.883,0.883,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.183,0.183,0]},"t":5,"s":[108.774,108.774,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.822,0.822,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.288,0.288,0]},"t":6,"s":[110.764,110.764,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.953,0.953,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.157,0.157,0]},"t":7,"s":[111.573,111.573,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.455,0.455,1]},"o":{"x":[0.167,0.167,0.167],"y":[-0.108,-0.108,0]},"t":8,"s":[112.495,112.495,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.792,0.792,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.098,0.098,0]},"t":9,"s":[112.094,112.094,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.871,0.871,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.139,0.139,0]},"t":10,"s":[109.875,109.875,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.753,0.753,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.235,0.235,0]},"t":11,"s":[106.547,106.547,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.843,0.843,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.126,0.126,0]},"t":12,"s":[104.719,104.719,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.881,0.881,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.178,0.178,0]},"t":13,"s":[101.118,101.118,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.791,0.791,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.281,0.281,0]},"t":14,"s":[97.948,97.948,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.886,0.886,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.139,0.139,0]},"t":15,"s":[96.61,96.61,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.92,0.92,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.307,0.307,0]},"t":16,"s":[94.589,94.589,100]},{"i":{"x":[0.833,0.833,0.833],"y":[-1.099,-1.099,1]},"o":{"x":[0.167,0.167,0.167],"y":[-2.347,-2.347,0]},"t":17,"s":[93.836,93.836,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.77,0.77,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.087,0.087,0]},"t":18,"s":[93.862,93.862,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.869,0.869,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.131,0.131,0]},"t":19,"s":[94.486,94.486,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.747,0.747,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.228,0.228,0]},"t":20,"s":[95.587,95.587,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.841,0.841,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.124,0.124,0]},"t":21,"s":[96.221,96.221,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.881,0.881,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.175,0.175,0]},"t":22,"s":[97.51,97.51,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.783,0.783,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.276,0.276,0]},"t":23,"s":[98.681,98.681,100]},{"i":{"x":[0.833,0.833,0.833],"y":[0.833,0.833,1.001]},"o":{"x":[0.167,0.167,0.167],"y":[0.135,0.135,0]},"t":24,"s":[99.187,99.187,100]},{"t":25,"s":[100,100,100]}],"ix":6,"l":2}},"ao":0,"shapes":[{"ty":"gr","it":[{"ind":0,"ty":"sh","ix":1,"ks":{"a":0,"k":{"i":[[0,0],[0.276,0],[0,-0.276],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0]],"o":[[0,-0.276],[-0.276,0],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0],[0,0]],"v":[[0.5,-2.501],[0,-3.001],[-0.5,-2.501],[-0.5,2.001],[-3.311,2.001],[-3.072,3.001],[3.073,3.001],[3.311,2.001],[0.5,2.001]],"c":true},"ix":2},"nm":"Path 1","mn":"ADBE Vector Shape - Group","hd":false},{"ty":"fl","c":{"a":0,"k":[1,1,1,1],"ix":4},"o":{"a":0,"k":100,"ix":5},"r":1,"bm":0,"nm":"Fill 1","mn":"ADBE Vector Graphic - Fill","hd":false},{"ty":"tr","p":{"a":0,"k":[0,0],"ix":2},"a":{"a":0,"k":[0,0],"ix":1},"s":{"a":0,"k":[1000,1000],"ix":3},"r":{"a":0,"k":0,"ix":6},"o":{"a":0,"k":100,"ix":7},"sk":{"a":0,"k":0,"ix":4},"sa":{"a":0,"k":0,"ix":5},"nm":"Transform"}],"nm":"Subtract","np":2,"cix":2,"bm":0,"ix":1,"mn":"ADBE Vector Group","hd":false}],"ip":0,"op":30,"st":0,"ct":1,"bm":0},{"ddd":0,"ind":4,"ty":4,"nm":"Shape","parent":3,"sr":1,"ks":{"o":{"a":0,"k":100,"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[0,-39.985,0],"ix":2,"l":2},"a":{"a":0,"k":[0,0,0],"ix":1,"l":2},"s":{"a":0,"k":[100,100,100],"ix":6,"l":2}},"ao":0,"shapes":[{"ty":"gr","it":[{"ind":0,"ty":"sh","ix":1,"ks":{"a":0,"k":{"i":[[0,1.677],[3.314,0],[0.104,-3.115],[0,0],[0,0],[-1.39,-1.312],[-0.027,-0.112],[0,0],[0,0],[0,0],[0,0],[-0.064,0.06]],"o":[[0,-3.203],[-3.247,0],[0,0],[0,0],[0.068,1.585],[0.085,0.08],[0,0],[0,0],[0,0],[0,0],[0.032,-0.08],[1.459,-1.378]],"v":[[6,-0.2],[0,-6],[-5.997,-0.391],[-6,-0.2],[-5.995,0.039],[-3.795,4.394],[-3.624,4.689],[-3.311,6],[3.311,6],[3.625,4.688],[3.651,4.607],[3.796,4.394]],"c":true},"ix":2},"nm":"Path 1","mn":"ADBE Vector Shape - Group","hd":false},{"ty":"gf","o":{"a":0,"k":100,"ix":10},"r":1,"bm":0,"g":{"p":3,"k":{"a":0,"k":[0,0.976,0.855,0.478,0.5,0.955,0.796,0.371,1,0.933,0.737,0.263],"ix":9}},"s":{"a":0,"k":[0,-6],"ix":5},"e":{"a":0,"k":[0,6],"ix":6},"t":1,"nm":"Gradient Fill 1","mn":"ADBE Vector Graphic - G-Fill","hd":false},{"ty":"tr","p":{"a":0,"k":[0,0],"ix":2},"a":{"a":0,"k":[0,0],"ix":1},"s":{"a":0,"k":[1000,1000],"ix":3},"r":{"a":0,"k":0,"ix":6},"o":{"a":0,"k":100,"ix":7},"sk":{"a":0,"k":0,"ix":4},"sa":{"a":0,"k":0,"ix":5},"nm":"Transform"}],"nm":"Shape","np":2,"cix":2,"bm":0,"ix":1,"mn":"ADBE Vector Group","hd":false}],"ip":0,"op":30,"st":0,"ct":1,"bm":0},{"ddd":0,"ind":5,"ty":4,"nm":"Shape","parent":3,"sr":1,"ks":{"o":{"a":0,"k":100,"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[0.005,45.015,0],"ix":2,"l":2},"a":{"a":0,"k":[0,0,0],"ix":1,"l":2},"s":{"a":0,"k":[100,100,100],"ix":6,"l":2}},"ao":0,"shapes":[{"ty":"gr","it":[{"ind":0,"ty":"sh","ix":1,"ks":{"a":0,"k":{"i":[[-0.184,0.771],[0,0],[0,0],[0,0],[0,0],[-0.819,0],[0,0],[0,0]],"o":[[0,0],[0,0],[0,0],[0,0],[0.241,0.745],[0,0],[0,0],[0.805,-0.06]],"v":[[2.689,0.105],[3.072,-1.5],[-3.072,-1.5],[-2.689,0.105],[-2.652,0.239],[-0.875,1.5],[0.874,1.5],[1.018,1.495]],"c":true},"ix":2},"nm":"Path 1","mn":"ADBE Vector Shape - Group","hd":false},{"ty":"gf","o":{"a":0,"k":50,"ix":10},"r":1,"bm":0,"g":{"p":3,"k":{"a":0,"k":[0,0.976,0.855,0.478,0.5,0.955,0.796,0.371,1,0.933,0.737,0.263],"ix":9}},"s":{"a":0,"k":[0,-1.5],"ix":5},"e":{"a":0,"k":[0,1.5],"ix":6},"t":1,"nm":"Gradient Fill 1","mn":"ADBE Vector Graphic - G-Fill","hd":false},{"ty":"fl","c":{"a":0,"k":[0.129411771894,0.129411771894,0.129411771894,1],"ix":4},"o":{"a":0,"k":100,"ix":5},"r":1,"bm":0,"nm":"Fill 1","mn":"ADBE Vector Graphic - Fill","hd":false},{"ty":"tr","p":{"a":0,"k":[0,0],"ix":2},"a":{"a":0,"k":[0,0],"ix":1},"s":{"a":0,"k":[1000,1000],"ix":3},"r":{"a":0,"k":0,"ix":6},"o":{"a":0,"k":100,"ix":7},"sk":{"a":0,"k":0,"ix":4},"sa":{"a":0,"k":0,"ix":5},"nm":"Transform"}],"nm":"Shape","np":3,"cix":2,"bm":0,"ix":1,"mn":"ADBE Vector Group","hd":false}],"ip":0,"op":30,"st":0,"ct":1,"bm":0}],"markers":[],"props":{}} \ No newline at end of file diff --git a/Telegram/Common/BridgeApplicationContext.cs b/Telegram/Common/BridgeApplicationContext.cs index 11137f6e38..61ebc60857 100644 --- a/Telegram/Common/BridgeApplicationContext.cs +++ b/Telegram/Common/BridgeApplicationContext.cs @@ -130,7 +130,7 @@ public static bool IsPasskeySupported() var method = _webAuthNGetApiVersionNumber.Value; if (method != null) { - return method() != 0; + return method() >= 3; } return false; @@ -138,6 +138,7 @@ public static bool IsPasskeySupported() public static async Task AddLoginPasskeyAsync(IClientService clientService) { + Logger.Info(); await ConnectAsync(); var response = await clientService.SendAsync(new GetPasskeyParameters()); @@ -176,6 +177,7 @@ public static async Task AddLoginPasskeyAsync(IClientService clientServi public static async Task CheckAuthenticationPasskeyAsync(IClientService clientService) { + Logger.Info(); await ConnectAsync(); var response = await clientService.SendAsync(new GetAuthenticationPasskeyParameters()); diff --git a/Telegram/Common/Colors.cs b/Telegram/Common/Colors.cs index 4c2d314aea..2a8e24536f 100644 --- a/Telegram/Common/Colors.cs +++ b/Telegram/Common/Colors.cs @@ -478,5 +478,11 @@ public static Color Darken(this Color color, float satuation = 0.05f, float valu // OLD: .WithBrightness(-0.2f) return color.WithSatuation(satuation, value); } + + public static Color Lighten(this Color color, float satuation = -0.05f, float value = 0.1f) + { + // OLD: .WithBrightness(0.2f) + return color.WithSatuation(satuation, value); + } } } diff --git a/Telegram/Common/CommonStyles.xaml b/Telegram/Common/CommonStyles.xaml index b3f35e7d2c..834b99c0f8 100644 --- a/Telegram/Common/CommonStyles.xaml +++ b/Telegram/Common/CommonStyles.xaml @@ -1284,6 +1284,12 @@ + + + + + + + + + + + + + + Grid.Column="2" /> + Grid.ColumnSpan="3" /> diff --git a/Telegram/Controls/Messages/MessageBubble.xaml.cs b/Telegram/Controls/Messages/MessageBubble.xaml.cs index 211515da12..3e543297e7 100644 --- a/Telegram/Controls/Messages/MessageBubble.xaml.cs +++ b/Telegram/Controls/Messages/MessageBubble.xaml.cs @@ -27,6 +27,7 @@ using Telegram.ViewModels; using Telegram.ViewModels.Delegates; using Telegram.ViewModels.Stories; +using Telegram.Views.Popups; using Windows.Foundation; using Windows.UI; using Windows.UI.Composition; @@ -37,6 +38,7 @@ using Windows.UI.Xaml.Core.Direct; using Windows.UI.Xaml.Documents; using Windows.UI.Xaml.Hosting; +using Windows.UI.Xaml.Input; using Windows.UI.Xaml.Markup; using Windows.UI.Xaml.Media; using Windows.UI.Xaml.Shapes; @@ -45,11 +47,12 @@ namespace Telegram.Controls.Messages { public partial class MessageBubbleHighlightOptions { - public MessageBubbleHighlightOptions(long messageId, TextQuote quote, int checklistTaskId, bool moveFocus = true, bool highlight = true) + public MessageBubbleHighlightOptions(long messageId, TextQuote quote, int checklistTaskId, string pollOptionId, bool moveFocus = true, bool highlight = true) { MessageId = messageId; Quote = quote; ChecklistTaskId = checklistTaskId; + PollOptionId = pollOptionId; MoveFocus = moveFocus; Highlight = highlight; } @@ -64,6 +67,8 @@ public MessageBubbleHighlightOptions(bool moveFocus = true, bool highlight = tru public int ChecklistTaskId { get; } = 0; + public string PollOptionId { get; } = ""; + public TextQuote Quote { get; } public bool MoveFocus { get; } = true; @@ -190,7 +195,8 @@ public void UpdateRecyclePool(FormattedTextBlockRecyclePool recyclePool) private TextBlock HeaderLabel; private Hyperlink HeaderLink; private Run HeaderLinkRun; - private TextBlock AdminLabel; + private BadgeControl MemberTag; + private TextBlock BoostCount; private MessageForwardHeader ForwardHeader; private IdentityIcon Identity; private GlyphButton PsaInfo; @@ -253,6 +259,7 @@ protected override void OnApplyTemplate() ElementCompositionPreview.SetIsTranslationEnabled(Media, true); _templateApplied = true; + TemplateApplied?.Invoke(this, EventArgs.Empty); if (_message != null) { @@ -260,6 +267,8 @@ protected override void OnApplyTemplate() } } + public event EventHandler TemplateApplied; + #endregion public UIElement MediaTemplateRoot @@ -371,7 +380,7 @@ public string GetAutomationName() builder.Append($" {Strings.ViaBot} @{viaBotUsername}"); } - var admin = message.Delegate?.GetAdminTitle(message); + var admin = message.Delegate?.GetMemberTag(message, out _); if (admin?.Length > 0) { builder.AppendLine($", {admin}. "); @@ -1257,7 +1266,9 @@ or MessageBigEmoji if (shown) { - var title = message.Delegate?.GetAdminTitle(message); + ChatMemberRank rank = ChatMemberRank.Other; + var title = message.Delegate?.GetMemberTag(message, out rank); + var boosts = string.Empty; if (message.SenderBoostCount > 0 && !outgoing) { @@ -1268,27 +1279,78 @@ or MessageBigEmoji if (message.SenderBoostCount > 1) { - title += $"{Icons.Boosters212} {message.SenderBoostCount}"; + boosts = $"{Icons.Boosters212} {message.SenderBoostCount}"; } else { - title += Icons.Boosters12; + boosts = Icons.Boosters12; } } - if (shown && !outgoing && !string.IsNullOrEmpty(title)) + if (shown && !outgoing && title?.Length > 0) { - LoadTemplateChild(ref AdminLabel); - AdminLabel.Text = title; + if (MemberTag == null) + { + LoadTemplateChild(ref MemberTag); + MemberTag.Tapped += MemberTag_Tapped; + } + + MemberTag.Text = title; + + if (rank != ChatMemberRank.Other) + { + var color = rank == ChatMemberRank.Owner + ? Color.FromArgb(0xFF, 0x65, 0x60, 0xF6) + : Color.FromArgb(0xFF, 0x75, 0xC8, 0x73); + + MemberTag.Background = new SolidColorBrush(color) { Opacity = 0.2 }; + MemberTag.Foreground = new SolidColorBrush(color.Darken()); + } + else + { + MemberTag.ClearValue(BackgroundProperty); + MemberTag.ClearValue(ForegroundProperty); + } + + if (boosts.Length > 0) + { + if (BoostCount == null) + { + LoadTemplateChild(ref BoostCount); + BoostCount.Tapped += BoostCount_Tapped; + } + + BoostCount.Text = boosts; + } + else + { + BoostCount?.Tapped -= BoostCount_Tapped; + UnloadTemplateChild(ref BoostCount); + } } else if (shown && !message.IsChannelPost && message.SenderId is MessageSenderChat && message.ForwardInfo != null) { - LoadTemplateChild(ref AdminLabel); - AdminLabel.Text = Strings.DiscussChannel; + if (MemberTag == null) + { + LoadTemplateChild(ref MemberTag); + MemberTag.Tapped += MemberTag_Tapped; + } + + MemberTag.Text = Strings.DiscussChannel; + + MemberTag.ClearValue(BackgroundProperty); + MemberTag.ClearValue(ForegroundProperty); + + BoostCount?.Tapped -= BoostCount_Tapped; + UnloadTemplateChild(ref BoostCount); } - else if (AdminLabel != null) + else { - UnloadTemplateChild(ref AdminLabel); + MemberTag?.Tapped -= MemberTag_Tapped; + BoostCount?.Tapped -= BoostCount_Tapped; + + UnloadTemplateChild(ref MemberTag); + UnloadTemplateChild(ref BoostCount); } if (header is false) @@ -1303,7 +1365,11 @@ or MessageBigEmoji } else { - UnloadTemplateChild(ref AdminLabel); + MemberTag?.Tapped -= MemberTag_Tapped; + BoostCount?.Tapped -= BoostCount_Tapped; + + UnloadTemplateChild(ref MemberTag); + UnloadTemplateChild(ref BoostCount); //if (HeaderPanel != null) //{ @@ -1325,6 +1391,29 @@ or MessageBigEmoji } } + private async void MemberTag_Tapped(object sender, TappedRoutedEventArgs e) + { + if (_message is not MessageViewModel message) + { + return; + } + + var response = await message.ClientService.SendAsync(new GetChatMember(message.ChatId, message.SenderId)); + if (response is ChatMember member && message.ClientService.CanEditTag(message.Chat, member)) + { + _message?.Delegate?.NavigationService?.ShowPopup(new MemberTagEditPopup(message.ClientService, message.Delegate.Aggregator, message.Chat, member)); + } + else + { + _message?.Delegate?.NavigationService?.ShowPopup(new MemberTagInfoPopup(_message)); + } + } + + private void BoostCount_Tapped(object sender, TappedRoutedEventArgs e) + { + // TODO: boost chat info + } + private TextBlock LoadHeaderLabel() { if (HeaderPanel == null) @@ -1809,7 +1898,7 @@ public void UpdateMessageContentLayout(MessageViewModel message) } else if (content is MessagePoll or MessageChecklist) { - ContentPanel.Padding = new Thickness(0, 4, 0, 0); + ContentPanel.Padding = new Thickness(0, 0, 0, 0); Media.Margin = new Thickness(0); FooterToNormal(); Grid.SetRow(Footer, 4); @@ -2852,6 +2941,17 @@ or MessageBigEmoji solid.Size = area.ToSizeF(); } } + else if (Media.Child is PollContent poll && !string.IsNullOrEmpty(options.PollOptionId)) + { + var area = poll.Highlight(options); + if (!area.IsEmpty) + { + var point = Media.TransformToVector2(ContentPanel); + var offset = area.ToOffset(); + solid.Offset = new Vector3(offset.X, point.Y + offset.Y, 0); + solid.Size = area.ToSizeF(); + } + } var animation = _highlight.Compositor.CreateScalarKeyFrameAnimation(); animation.Duration = TimeSpan.FromSeconds(2); @@ -2957,13 +3057,13 @@ public void Mockup(string message, bool outgoing, DateTime date, bool first = tr { if (!_templateApplied) { - void loaded(object o, RoutedEventArgs e) + void loaded(object o, EventArgs e) { - Loaded -= loaded; + TemplateApplied -= loaded; Mockup(message, outgoing, date, first, last); } - Loaded += loaded; + TemplateApplied += loaded; return; } @@ -2987,13 +3087,13 @@ public void Mockup(string message, string sender, string reply, bool outgoing, D { if (!_templateApplied) { - void loaded(object o, RoutedEventArgs e) + void loaded(object o, EventArgs e) { - Loaded -= loaded; + TemplateApplied -= loaded; Mockup(message, sender, reply, outgoing, date, first, last); } - Loaded += loaded; + TemplateApplied += loaded; return; } @@ -3036,13 +3136,13 @@ public void Mockup(IClientService clientService, string message, object sender, { if (!_templateApplied) { - void loaded(object o, RoutedEventArgs e) + void loaded(object o, EventArgs e) { - Loaded -= loaded; + TemplateApplied -= loaded; Mockup(clientService, message, sender, reply, outgoing, date, first, last); } - Loaded += loaded; + TemplateApplied += loaded; return; } @@ -3110,13 +3210,13 @@ public void Mockup(IClientService clientService, string message, MessageSender s { if (!_templateApplied) { - void loaded(object o, RoutedEventArgs e) + void loaded(object o, EventArgs e) { - Loaded -= loaded; + TemplateApplied -= loaded; Mockup(clientService, message, sender, reply, linkPreview, outgoing, date, first, last); } - Loaded += loaded; + TemplateApplied += loaded; return; } @@ -3231,13 +3331,13 @@ public void Mockup(MessageContent content, bool outgoing, DateTime date, bool fi { if (!_templateApplied) { - void loaded(object o, RoutedEventArgs e) + void loaded(object o, EventArgs e) { - Loaded -= loaded; + TemplateApplied -= loaded; Mockup(content, outgoing, date, first, last); } - Loaded += loaded; + TemplateApplied += loaded; return; } @@ -3289,13 +3389,13 @@ public void Mockup(MessageContent content, string caption, bool outgoing, DateTi { if (!_templateApplied) { - void loaded(object o, RoutedEventArgs e) + void loaded(object o, EventArgs e) { - Loaded -= loaded; + TemplateApplied -= loaded; Mockup(content, caption, outgoing, date, first, last); } - Loaded += loaded; + TemplateApplied += loaded; return; } @@ -3333,13 +3433,13 @@ public void UpdateMockup(IClientService clientService, long customEmojiId, int c { if (!_templateApplied) { - void loaded(object o, RoutedEventArgs e) + void loaded(object o, EventArgs e) { - Loaded -= loaded; + TemplateApplied -= loaded; UpdateMockup(clientService, customEmojiId, color, upgradedGift); } - Loaded += loaded; + TemplateApplied += loaded; return; } @@ -3363,7 +3463,124 @@ void loaded(object o, RoutedEventArgs e) } } - public void UpdateMockup(bool outgoing, bool first, bool last) + public void UpdateMockup(IClientService clientService, Chat chat, MessageSender sender, string tag, ChatMemberRank rank) + { + if (!_templateApplied) + { + void loaded(object o, EventArgs e) + { + TemplateApplied -= loaded; + UpdateMockup(clientService, chat, sender, tag, rank); + } + + TemplateApplied += loaded; + return; + } + + if (sender != null) + { + var message = new Message(chat.Id, sender, 0, null, null, false, false, false, false, false, false, false, false, false, 0, 0, null, null, null, Array.Empty(), null, null, null, null, null, 0, 0, 0, 0, 0, string.Empty, 0, string.Empty, 0, 0, null, string.Empty, null, null); + var settings = clientService.Session.Resolve(); + + var delegato = new ChatMessageDelegate(clientService, settings, chat); + var viewModel = new MessageViewModel(clientService, delegato, chat, null, null, message, true); + + UpdateMessageHeader(viewModel); + } + + if (MemberTag == null) + { + LoadTemplateChild(ref MemberTag); + MemberTag.Tapped += MemberTag_Tapped; + } + + MemberTag.Text = tag; + + if (rank != ChatMemberRank.Other) + { + var color = rank == ChatMemberRank.Owner + ? Color.FromArgb(0xFF, 0x65, 0x60, 0xF6) + : Color.FromArgb(0xFF, 0x75, 0xC8, 0x73); + + MemberTag.Background = new SolidColorBrush(color) { Opacity = 0.2 }; + MemberTag.Foreground = new SolidColorBrush(color.Darken()); + } + else + { + MemberTag.ClearValue(BackgroundProperty); + MemberTag.ClearValue(ForegroundProperty); + } + + Message.Visibility = Visibility.Collapsed; + + Footer.Mockup(false, DateTime.Now); + Panel.ForceNewLine = false; + + var placeholder = new StackPanel + { + Orientation = Orientation.Vertical, + //Width = 480, + //Height = 48 + }; + + var backgroundColor = Color.FromArgb(0x0F, 0xFF, 0xFF, 0xFF); + + var lookup = ThemeService.GetLookup(ActualTheme); + if (lookup.TryGet("MenuFlyoutItemBackgroundPointerOver", out backgroundColor)) + { + } + + var bar1 = new Border + { + CornerRadius = new CornerRadius(4), + HorizontalAlignment = HorizontalAlignment.Stretch, + Height = 8, + Background = new SolidColorBrush(backgroundColor), + Margin = new Thickness(0, 0, 4, 0) + }; + + var bar2 = new Border + { + CornerRadius = new CornerRadius(4), + HorizontalAlignment = HorizontalAlignment.Stretch, + Height = 8, + Background = new SolidColorBrush(backgroundColor), + Margin = new Thickness(0, 12, 36, 16) + }; + + placeholder.Children.Add(bar1); + placeholder.Children.Add(bar2); + + Media.Child = placeholder; + Media.Margin = new Thickness(10, 4, 10, 8); + FooterToNormal(); + Grid.SetRow(Footer, 3); + Grid.SetRow(Message, 2); + Panel.Placeholder = false; + + if (sender != null) + { + if (PhotoRoot == null) + { + PhotoRoot = GetTemplateChild(nameof(PhotoRoot)) as HyperlinkButton; + PhotoRoot.Click += Photo_Click; + + Photo = GetTemplateChild(nameof(Photo)) as ProfilePicture; + } + + PhotoRoot.Visibility = Visibility.Visible; + Photo.Source = ProfilePictureSource.MessageSender(clientService, sender); + + if (PhotoColumn.Width.IsAuto) + { + PhotoColumn.Width = new GridLength(38, GridUnitType.Pixel); + } + } + + UpdateMockup(false, true, true, false); + } + + public void UpdateMockup(bool outgoing, bool first, bool last, bool margin = true) { var radius = SettingsService.Current.Appearance.BubbleRadius; var small = radius < 4 ? radius : 4; @@ -3416,7 +3633,11 @@ public void UpdateMockup(bool outgoing, bool first, bool last) } } - Margin = new Thickness(outgoing ? 50 : 12, first ? 2 : 1, outgoing ? 12 : 50, last ? 2 : 1); + if (margin) + { + Margin = new Thickness(outgoing ? 50 : 12, first ? 2 : 1, outgoing ? 12 : 50, last ? 2 : 1); + } + Message.SetFontSize(Theme.Current.MessageFontSize); SetCorners(topLeft, topRight, bottomRight, bottomLeft); } @@ -3447,6 +3668,11 @@ protected override Size MeasureOverride(Size availableSize) constraint = message.Content; } + if (constraint is MessagePoll poll) + { + constraint = poll.Media; + } + if (constraint is MessageAnimation animationMessage) { ttl = animationMessage.IsSecret; diff --git a/Telegram/Controls/Messages/MessageBubblePanel.cs b/Telegram/Controls/Messages/MessageBubblePanel.cs index 31201e4b1a..ae45960da3 100644 --- a/Telegram/Controls/Messages/MessageBubblePanel.cs +++ b/Telegram/Controls/Messages/MessageBubblePanel.cs @@ -270,7 +270,7 @@ private float ContentEnd(FormattedTextBlock textBlock, double fontSize) var paragraph = textBlock.Text.Paragraphs[^1]; var text = textBlock.Text.Text.Substring(paragraph.Offset, paragraph.Length); - var entities = paragraph.Parts; + var entities = paragraph.GetParts(out text); var block = Children[0] is FormattedTextBlock formatted ? formatted : Children[1] as FormattedTextBlock; var width = textBlock.LastAvailableWidth; diff --git a/Telegram/Controls/Messages/MessageEffectMenuFlyout.xaml.cs b/Telegram/Controls/Messages/MessageEffectMenuFlyout.xaml.cs index 71dcbf66f5..7a546d6bf7 100644 --- a/Telegram/Controls/Messages/MessageEffectMenuFlyout.xaml.cs +++ b/Telegram/Controls/Messages/MessageEffectMenuFlyout.xaml.cs @@ -7,7 +7,6 @@ using System; using System.Numerics; -using Telegram.Common; using Telegram.Controls.Drawers; using Telegram.Services; using Telegram.Td.Api; diff --git a/Telegram/Controls/Messages/MessageFooter.xaml.cs b/Telegram/Controls/Messages/MessageFooter.xaml.cs index 62c2be0c3d..e04798fe3b 100644 --- a/Telegram/Controls/Messages/MessageFooter.xaml.cs +++ b/Telegram/Controls/Messages/MessageFooter.xaml.cs @@ -87,6 +87,7 @@ protected override void OnApplyTemplate() ToolTip.Opened += ToolTip_Opened; _templateApplied = true; + TemplateApplied?.Invoke(this, EventArgs.Empty); if (_message != null) { @@ -94,6 +95,8 @@ protected override void OnApplyTemplate() } } + public event EventHandler TemplateApplied; + #endregion private void UpdateLabel() @@ -334,6 +337,18 @@ private void UpdateMessageDateImpl(MessageViewModel message) public void Mockup(bool outgoing, DateTime date) { + if (!_templateApplied) + { + void loaded(object o, EventArgs e) + { + TemplateApplied -= loaded; + Mockup(outgoing, date); + } + + TemplateApplied += loaded; + return; + } + _dateLabel = Formatter.Time(date); UpdateLabel(); UpdateTicks(outgoing, outgoing ? MessageTicksState.Read : MessageTicksState.None); diff --git a/Telegram/Controls/Messages/MessageForwardHeader.xaml b/Telegram/Controls/Messages/MessageForwardHeader.xaml index a3a828c340..201207a1ae 100644 --- a/Telegram/Controls/Messages/MessageForwardHeader.xaml +++ b/Telegram/Controls/Messages/MessageForwardHeader.xaml @@ -11,6 +11,10 @@ Value="{ThemeResource MessageHeaderForegroundBrush}" /> + + diff --git a/Telegram/Controls/Messages/MessageReferenceBase.cs b/Telegram/Controls/Messages/MessageReferenceBase.cs index b523718593..442b7d3569 100644 --- a/Telegram/Controls/Messages/MessageReferenceBase.cs +++ b/Telegram/Controls/Messages/MessageReferenceBase.cs @@ -87,12 +87,12 @@ public void UpdateComposerHeader(MessageComposerHeader embedded) else if (embedded.Editing != null) { Message = embedded.Editing.Message; - GetMessageTemplate(embedded.Editing.Message, null, false, 0, Strings.Edit, true, false, false); + GetMessageTemplate(embedded.Editing.Message, null, false, 0, string.Empty, Strings.Edit, true, false, false); } else if (embedded.ReplyTo != null) { Message = embedded.ReplyTo.Message; - GetMessageTemplate(embedded.ReplyTo.Message, embedded.ReplyTo.Quote?.Text, false, embedded.ReplyTo.ChecklistTaskId, embedded.ReplyTo.Quote != null ? Strings.ReplyToQuote : Strings.ReplyTo, true, false, false); + GetMessageTemplate(embedded.ReplyTo.Message, embedded.ReplyTo.Quote?.Text, false, embedded.ReplyTo.ChecklistTaskId, embedded.ReplyTo.PollOptionId, embedded.ReplyTo.Quote != null ? Strings.ReplyToQuote : Strings.ReplyTo, true, false, false); } } @@ -161,7 +161,7 @@ or MessageBigEmoji else if (message.ReplyToItem is MessageViewModel replyToMessage && message.ReplyTo is MessageReplyToMessage replyToMessage1) { Visibility = Visibility.Visible; - GetMessageTemplate(replyToMessage, replyToMessage1.Quote?.Text, replyToMessage1.Quote?.IsManual ?? false, replyToMessage1.ChecklistTaskId, null, outgoing, light, message.ForwardInfo != null); + GetMessageTemplate(replyToMessage, replyToMessage1.Quote?.Text, replyToMessage1.Quote?.IsManual ?? false, replyToMessage1.ChecklistTaskId, replyToMessage1.PollOptionId, null, outgoing, light, message.ForwardInfo != null); } else if (message.ReplyToItem is Story replyToStory) { @@ -203,7 +203,7 @@ public void UpdateMessage(MessageViewModel message, bool loading, string title) else { Message = message; - GetMessageTemplate(message, null, false, 0, title, true, false, message.ForwardInfo != null); + GetMessageTemplate(message, null, false, 0, string.Empty, title, true, false, message.ForwardInfo != null); } } @@ -324,7 +324,7 @@ private void UpdateThumbnail(Minithumbnail thumbnail, bool hasSpoiler, CornerRad #region Reply - private void GetMessageTemplate(MessageViewModel message, FormattedText quote, bool manual, int checklistTaskId, string title, bool outgoing, bool white, bool forward) + private void GetMessageTemplate(MessageViewModel message, FormattedText quote, bool manual, int checklistTaskId, string pollOptionId, string title, bool outgoing, bool white, bool forward) { MessageSender sender; if (title == null) @@ -393,7 +393,7 @@ private void GetMessageTemplate(MessageViewModel message, FormattedText quote, b SetPhotoTemplate(message, sender, quote, manual, photo, title, outgoing, white, message.SelfDestructType is null); break; case MessagePoll poll: - SetPollTemplate(message, sender, poll, title, outgoing, white); + SetPollTemplate(message, sender, poll, pollOptionId, title, outgoing, white); break; case MessageChecklist checklist: SetChecklistTemplate(message, sender, checklist, checklistTaskId, title, outgoing, white); @@ -479,7 +479,7 @@ private void GetMessageTemplate(MessageViewModel message, MessageReplyToMessage SetPhotoTemplate(message, sender, quote, manual, photo, title, outgoing, white, true); break; case MessagePoll poll: - SetPollTemplate(message, sender, poll, title, outgoing, white); + SetPollTemplate(message, sender, poll, replyToMessage.PollOptionId, title, outgoing, white); break; case MessageChecklist checklist: SetChecklistTemplate(message, sender, checklist, replyToMessage.ChecklistTaskId, title, outgoing, white); @@ -827,11 +827,25 @@ private void SetAudioTemplate(MessageViewModel message, MessageSender sender, Fo white); } - private void SetPollTemplate(MessageViewModel message, MessageSender sender, MessagePoll poll, string title, bool outgoing, bool white) + private void SetPollTemplate(MessageViewModel message, MessageSender sender, MessagePoll poll, string pollOptionId, string title, bool outgoing, bool white) { HideThumbnail(); - SetText(message, + var task = string.IsNullOrEmpty(pollOptionId) ? null : poll.Poll.Options.FirstOrDefault(x => x.Id == pollOptionId); + if (task != null) + { + SetText(message, + outgoing, + sender, + title, + string.Empty, + TdExtensions.Concat(ClientEx.CustomEmoji("\uEACF "), task.Text), + false, + white); + } + else + { + SetText(message, outgoing, sender, title, @@ -839,6 +853,7 @@ private void SetPollTemplate(MessageViewModel message, MessageSender sender, Mes poll.Poll.Question, false, white); + } } private void SetChecklistTemplate(MessageViewModel message, MessageSender sender, MessageChecklist checklist, int checklistTaskId, string title, bool outgoing, bool white) diff --git a/Telegram/Controls/Messages/MessageSelector.xaml.cs b/Telegram/Controls/Messages/MessageSelector.xaml.cs index 3444b30fad..764bd32692 100644 --- a/Telegram/Controls/Messages/MessageSelector.xaml.cs +++ b/Telegram/Controls/Messages/MessageSelector.xaml.cs @@ -63,11 +63,9 @@ public MessageSelector(MessageViewModel message, UIElement child) protected override void OnLoaded() { - if (!_hasInitialLoadedEventFired && RootGrid != null && IsTrackerEnabled && (SettingsService.Current.SwipeToReply || SettingsService.Current.SwipeToShare)) + if (_trackerOwner == null && RootGrid != null && IsTrackerEnabled && (SettingsService.Current.SwipeToReply || SettingsService.Current.SwipeToShare)) { - _hasInitialLoadedEventFired = true; - - _compositor = _hitTest.Compositor; + _compositor = BootStrapper.Current.Compositor; _container ??= _compositor.CreateContainerVisual(); if (_requiresArrange) @@ -337,7 +335,7 @@ public void UpdateMessageStakeDice(MessageViewModel message) return; } - if (message.Content is MessageStakeDice { Value: not 0 }) + if (message.Content is MessageStakeDice { Value: not 0 } && !message.GeneratedContentUnread) { _hasStakeDice = true; Footer ??= GetTemplateChild(nameof(Footer)) as Border; @@ -563,7 +561,6 @@ protected override AutomationPeer OnCreateAutomationPeer() private ContainerVisual _container; private ContainerVisual _indicator; - private bool _hasInitialLoadedEventFired; private WeakInteractionTrackerOwner _trackerOwner; private InteractionTracker _tracker; private VisualInteractionSource _interactionSource; diff --git a/Telegram/Controls/Messages/MessageService.cs b/Telegram/Controls/Messages/MessageService.cs index dad5cc2dc2..a5da415926 100644 --- a/Telegram/Controls/Messages/MessageService.cs +++ b/Telegram/Controls/Messages/MessageService.cs @@ -652,6 +652,8 @@ private static FormattedText GetEntities(MessageWithOwner message, bool history) MessageChatSetTheme chatSetTheme => UpdateChatSetTheme(message, chatSetTheme, history), MessageChatDeleteMember chatDeleteMember => UpdateChatDeleteMember(message, chatDeleteMember, history), MessageChatDeletePhoto chatDeletePhoto => UpdateChatDeletePhoto(message, chatDeletePhoto, history), + MessageChatHasProtectedContentToggled chatHasProtectedContentToggled => UpdateChatHasProtectedContentToggled(message, chatHasProtectedContentToggled, history), + MessageChatHasProtectedContentDisableRequested chatHasProtectedContentDisableRequested => UpdateChatHasProtectedContentDisableRequested(message, chatHasProtectedContentDisableRequested, history), MessageChatJoinByLink chatJoinByLink => UpdateChatJoinByLink(message, chatJoinByLink, history), MessageChatJoinByRequest chatJoinByRequest => UpdateChatJoinByRequest(message, chatJoinByRequest, history), MessageChatSetBackground chatSetBackground => UpdateChatSetBackground(message, chatSetBackground, history), @@ -701,6 +703,8 @@ private static FormattedText GetEntities(MessageWithOwner message, bool history) MessageChatBoost chatBoost => UpdateChatBoost(message, chatBoost, history), MessageChecklistTasksAdded checklistTasksAdded => UpdateChecklistTasksAdded(message, checklistTasksAdded, history), MessageChecklistTasksDone checklistTasksDone => UpdateChecklistTasksDone(message, checklistTasksDone, history), + MessagePollOptionAdded pollOptionAdded => UpdatePollOptionAdded(message, pollOptionAdded, history), + MessagePollOptionDeleted pollOptionDeleted => UpdatePollOptionDeleted(message, pollOptionDeleted, history), MessageSuggestedPostPaid suggestedPostPaid => UpdateSuggestedPostPaid(message, suggestedPostPaid, history), MessageSuggestedPostRefunded suggestedPostRefunded => UpdateSuggestedPostRefunded(message, suggestedPostRefunded, history), MessageAsyncStory story => UpdateStory(message, story, history), @@ -746,6 +750,7 @@ private static FormattedText GetEntities(MessageWithOwner message, bool history) ChatEventAccentColorChanged accentColorChanged => UpdateChatEventAccentColorChanged(message, accentColorChanged, history), ChatEventProfileAccentColorChanged profileAccentColorChanged => UpdateChatEventProfileAccentColorChanged(message, profileAccentColorChanged, history), ChatEventEmojiStatusChanged emojiStatusChanged => UpdateChatEventEmojiStatusChanged(message, emojiStatusChanged, history), + ChatEventMemberTagChanged memberTagChanged => UpdateChatEventMemberTagChanged(message, memberTagChanged, history), ChatEventBackgroundChanged backgroundChanged => UpdateChatEventBackgroundChanged(message, backgroundChanged, history), //ChatEventActiveUsernamesChanged activeUsernamesChanged => UpdateChatEventActiveUsernames(messageUsernamesChanged), _ => _emptyString @@ -907,6 +912,31 @@ private static FormattedText UpdateChatEventEmojiStatusChanged(MessageWithOwner //return new FormattedText(content, entities); } + private static FormattedText UpdateChatEventMemberTagChanged(MessageWithOwner message, ChatEventMemberTagChanged memberTagChanged, bool history) + { + var newValue = !string.IsNullOrEmpty(memberTagChanged.NewTag); + var oldValue = !string.IsNullOrEmpty(memberTagChanged.OldTag); + + var outgoing = message.SenderId.IsUser(memberTagChanged.UserId); + + if (newValue && oldValue) + { + return outgoing + ? FormattedText.Format(ReplaceWithLink(Strings.EventLogRankSelfEdit, message.GetSender()), memberTagChanged.OldTag, memberTagChanged.NewTag) + : FormattedText.Format(ReplaceWithLink(Strings.EventLogRankEdit, message.GetSender(), message.ClientService.GetUser(memberTagChanged.UserId)), memberTagChanged.OldTag, memberTagChanged.NewTag); + } + else if (newValue && !oldValue) + { + return outgoing + ? FormattedText.Format(ReplaceWithLink(Strings.EventLogRankSelfAdd, message.GetSender()), memberTagChanged.NewTag) + : FormattedText.Format(ReplaceWithLink(Strings.EventLogRankAdd, message.GetSender(), message.ClientService.GetUser(memberTagChanged.UserId)), memberTagChanged.NewTag); + } + + return outgoing + ? FormattedText.Format(ReplaceWithLink(Strings.EventLogRankSelfRemove, message.GetSender()), memberTagChanged.OldTag) + : FormattedText.Format(ReplaceWithLink(Strings.EventLogRankRemove, message.GetSender(), message.ClientService.GetUser(memberTagChanged.UserId)), memberTagChanged.OldTag); + } + private static FormattedText UpdateChatEventBackgroundChanged(MessageWithOwner message, ChatEventBackgroundChanged backgroundChanged, bool history) { if (backgroundChanged.NewBackground != null) @@ -1623,6 +1653,33 @@ private static FormattedText UpdateChatDeletePhoto(MessageWithOwner message, Mes } } + + private static FormattedText UpdateChatHasProtectedContentToggled(MessageWithOwner message, MessageChatHasProtectedContentToggled chatHasProtectedContentToggled, bool history) + { + if (chatHasProtectedContentToggled.NewHasProtectedContent == chatHasProtectedContentToggled.OldHasProtectedContent) + { + return chatHasProtectedContentToggled.NewHasProtectedContent + ? Strings.DisableSharingActionStillDisabled.AsFormattedText() + : Strings.DisableSharingActionStillEnabled.AsFormattedText(); + } + + if (message.IsOutgoing) + { + return chatHasProtectedContentToggled.NewHasProtectedContent + ? Strings.DisableSharingActionYou.AsFormattedText() + : Strings.EnableSharingActionYou.AsFormattedText(); + } + + return ReplaceWithName(chatHasProtectedContentToggled.NewHasProtectedContent ? Strings.DisableSharingActionOther : Strings.EnableSharingActionOther, message.GetSender()); + } + + private static FormattedText UpdateChatHasProtectedContentDisableRequested(MessageWithOwner message, MessageChatHasProtectedContentDisableRequested chatHasProtectedContentDisableRequested, bool history) + { + return message.IsOutgoing + ? Strings.SharingOfferEnableHeaderYou.AsFormattedText() + : ClientEx.ParseMarkdown(ReplaceWithName(Strings.SharingOfferEnableHeaderOther, message.GetSender())); + } + private static FormattedText UpdateChatJoinByLink(MessageWithOwner message, MessageChatJoinByLink chatJoinByLink, bool history) { if (message.IsOutgoing) @@ -2508,7 +2565,7 @@ private static FormattedText UpdateUpgradedGiftPurchaseOffer(MessageWithOwner me if (upgradedGift.State is GiftPurchaseOfferStatePending) { var now = DateTime.Now.ToTimestamp(); - if (now > upgradedGift.ExpirationDate) + if (now >= upgradedGift.ExpirationDate) { content += "\n\n" + Strings.GiftOfferStatusExpired; } @@ -2765,6 +2822,41 @@ private static FormattedText UpdateChecklistTasksDone(MessageWithOwner message, return ReplaceWithLink(formatted, message.GetSender()); } } + private static FormattedText UpdatePollOptionAdded(MessageWithOwner message, MessagePollOptionAdded pollOptionAdded, bool history) + { + FormattedText formatted; + var text = message.IsOutgoing + ? Strings.PollAddingActionYou + : Strings.PollAddingActionOther; + formatted = ClientEx.Format(text, pollOptionAdded.Text); + formatted = ClientEx.ParseMarkdown(formatted); + //formatted = TdExtensions.Concat(ClientEx.CustomEmoji("\uEAD2 "), formatted); + + if (message.IsOutgoing) + { + return formatted; + } + + return ReplaceWithLink(formatted, message.GetSender()); + } + + private static FormattedText UpdatePollOptionDeleted(MessageWithOwner message, MessagePollOptionDeleted pollOptionDeleted, bool history) + { + FormattedText formatted; + var text = message.IsOutgoing + ? Strings.PollRemovedActionYou + : Strings.PollRemovedActionOther; + formatted = ClientEx.Format(text, pollOptionDeleted.Text); + formatted = ClientEx.ParseMarkdown(formatted); + //formatted = TdExtensions.Concat(ClientEx.CustomEmoji("\uEAD2 "), formatted); + + if (message.IsOutgoing) + { + return formatted; + } + + return ReplaceWithLink(formatted, message.GetSender()); + } private static FormattedText UpdateSuggestedPostPaid(MessageWithOwner message, MessageSuggestedPostPaid suggestedPostPaid, bool history) { @@ -2987,6 +3079,48 @@ public static FormattedText ReplaceWithLink(FormattedText source, params object[ return source; } + public static FormattedText ReplaceWithName(string source, params object[] args) + { + for (int i = 0; i < args.Length; i++) + { + var obj = args[i]; + if (obj is User user) + { + args[i] = user.FullName(); + } + else if (obj is Chat chat) + { + args[i] = chat.Title; + } + else if (obj is Game game) + { + args[i] = game.Title; + } + else if (obj is MessageGift gift) + { + args[i] = Locale.Declension(Strings.R.StarsCount, gift.Gift.StarCount + gift.PrepaidUpgradeStarCount); + } + else if (obj is MessageGiftedPremium giftedPremium) + { + args[i] = Locale.FormatCurrency(giftedPremium.Amount, giftedPremium.Currency); + } + else if (obj is MessagePremiumGiftCode premiumGiftCode) + { + args[i] = Locale.FormatCurrency(premiumGiftCode.Amount, premiumGiftCode.Currency); + } + else if (obj is MessageGiftedStars giftedStars) + { + args[i] = Locale.FormatCurrency(giftedStars.Amount, giftedStars.Currency); + } + else if (obj is ForumTopicInfo forumTopicInfo) + { + args[i] = $"\U0001F4C3 {forumTopicInfo.Name}"; + } + } + + return string.Format(source, args).AsFormattedText(); + } + private static FormattedText ReplaceWithLinks(string source, string param, IEnumerable uids, IClientService clientService) { return ReplaceWithLinks(new FormattedText(source, new List()), param, uids, clientService); diff --git a/Telegram/Controls/Messages/ReactionAsPaidButton.cs b/Telegram/Controls/Messages/ReactionAsPaidButton.cs index dcc6071d4a..4967b6d47e 100644 --- a/Telegram/Controls/Messages/ReactionAsPaidButton.cs +++ b/Telegram/Controls/Messages/ReactionAsPaidButton.cs @@ -5,7 +5,6 @@ // file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) // -using Telegram.Common; using Telegram.Services; using Telegram.Td.Api; using Telegram.ViewModels; diff --git a/Telegram/Controls/Messages/ReactionButton.cs b/Telegram/Controls/Messages/ReactionButton.cs index 82c3d98521..967125bd70 100644 --- a/Telegram/Controls/Messages/ReactionButton.cs +++ b/Telegram/Controls/Messages/ReactionButton.cs @@ -15,6 +15,7 @@ using Telegram.Converters; using Telegram.Native.Controls; using Telegram.Navigation; +using Telegram.Navigation.Services; using Telegram.Services; using Telegram.Streams; using Telegram.Td.Api; @@ -279,7 +280,7 @@ void handler(InteractionsView sender, ItemClickEventArgs e) if (e.ClickedItem is AddedReaction addedReaction) { - message.Delegate.NavigationService.NavigateToSender(addedReaction.SenderId); + message.Delegate.NavigationService.NavigateToSender(addedReaction.SenderId, state: new NavigationState { { "report_reactions", new ReportMessageReactions(message.ChatId, message.Id, addedReaction.SenderId) } }); } else if (e.ClickedItem is MessageViewer messageViewer) { diff --git a/Telegram/Controls/Messages/ReplyMarkupInlinePanel.cs b/Telegram/Controls/Messages/ReplyMarkupInlinePanel.cs index 55a62f330b..cd0d731b60 100644 --- a/Telegram/Controls/Messages/ReplyMarkupInlinePanel.cs +++ b/Telegram/Controls/Messages/ReplyMarkupInlinePanel.cs @@ -9,13 +9,18 @@ using System.Numerics; using Telegram.Common; using Telegram.Controls.Media; +using Telegram.Streams; using Telegram.Td.Api; using Telegram.ViewModels; using Windows.Foundation; +using Windows.UI; using Windows.UI.Composition; using Windows.UI.Xaml; +using Windows.UI.Xaml.Automation.Peers; using Windows.UI.Xaml.Controls; using Windows.UI.Xaml.Hosting; +using Windows.UI.Xaml.Input; +using Windows.UI.Xaml.Media; namespace Telegram.Controls.Messages { @@ -31,6 +36,16 @@ public partial class ReplyMarkupInlinePanel : Panel public Vector2 CornerRadius { get; set; } + public ReplyMarkupInlinePanel() + { + TabFocusNavigation = KeyboardNavigationMode.Once; + } + + protected override AutomationPeer OnCreateAutomationPeer() + { + return new ReplyMarkupInlinePanelAutomationPeer(this); + } + public void Update(MessageViewModel message) { if (_empty && message?.ReplyMarkup == null) @@ -81,6 +96,11 @@ public void Update(MessageViewModel message, ReplyMarkupInlineKeyboard inlineMar button.Text = item.Text.Replace('\n', ' '); button.Click += Button_Click; + if (item.IconCustomEmojiId != 0) + { + button.Source = new CustomEmojiFileSource(message.ClientService, item.IconCustomEmojiId); + } + switch (item.Type) { case InlineKeyboardButtonTypeUrl typeUrl: @@ -123,6 +143,19 @@ public void Update(MessageViewModel message, ReplyMarkupInlineKeyboard inlineMar break; } + switch (item.Style) + { + case ButtonStylePrimary: + button.Background = new SolidColorBrush(Color.FromArgb(0xB2, 0x22, 0x9a, 0xf0)); + break; + case ButtonStyleDanger: + button.Background = new SolidColorBrush(Color.FromArgb(0xB2, 0xdb, 0x46, 0x46)); + break; + case ButtonStyleSuccess: + button.Background = new SolidColorBrush(Color.FromArgb(0xB2, 0x40, 0xb1, 0x35)); + break; + } + Children.Add(button); } @@ -225,4 +258,17 @@ protected override Size ArrangeOverride(Size finalSize) return finalSize; } } + + public partial class ReplyMarkupInlinePanelAutomationPeer : FrameworkElementAutomationPeer + { + public ReplyMarkupInlinePanelAutomationPeer(ReplyMarkupInlinePanel owner) + : base(owner) + { + } + + protected override AutomationControlType GetAutomationControlTypeCore() + { + return AutomationControlType.List; + } + } } diff --git a/Telegram/Controls/Messages/Service/MessageChatHasProtectedContentDisableRequestedContent.xaml b/Telegram/Controls/Messages/Service/MessageChatHasProtectedContentDisableRequestedContent.xaml new file mode 100644 index 0000000000..eaf5a3cf2b --- /dev/null +++ b/Telegram/Controls/Messages/Service/MessageChatHasProtectedContentDisableRequestedContent.xaml @@ -0,0 +1,86 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Telegram/Controls/Messages/Service/MessageChatHasProtectedContentDisableRequestedContent.xaml.cs b/Telegram/Controls/Messages/Service/MessageChatHasProtectedContentDisableRequestedContent.xaml.cs new file mode 100644 index 0000000000..58ce6e5d12 --- /dev/null +++ b/Telegram/Controls/Messages/Service/MessageChatHasProtectedContentDisableRequestedContent.xaml.cs @@ -0,0 +1,69 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using System; +using Telegram.Td.Api; +using Telegram.ViewModels; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; + +namespace Telegram.Controls.Messages.Service +{ + public sealed partial class MessageChatHasProtectedContentDisableRequestedContent : MessageService + { + public MessageChatHasProtectedContentDisableRequestedContent() + { + InitializeComponent(); + + Features.Text = Strings.SharingOfferEnable1.Replace(">", "\u2713") + + "\n\n" + Strings.SharingOfferEnable2.Replace(">", "\u2713") + + "\n\n" + Strings.SharingOfferEnable3.Replace(">", "\u2713") + + "\n\n" + Strings.SharingOfferEnable4.Replace(">", "\u2713"); + } + + protected override void UpdateContent(MessageViewModel message) + { + if (message.Content is not MessageChatHasProtectedContentDisableRequested chatHasProtectedContentDisableRequested) + { + return; + } + + if (!chatHasProtectedContentDisableRequested.IsExpired && !message.IsOutgoing) + { + Accept.Visibility = Visibility.Visible; + Reject.Visibility = Visibility.Visible; + Service.CornerRadius = new CornerRadius(11, 11, 4, 4); + } + else + { + Accept.Visibility = Visibility.Collapsed; + Reject.Visibility = Visibility.Collapsed; + Service.CornerRadius = new CornerRadius(11); + } + } + + private async void Reject_Click(object sender, RoutedEventArgs e) + { + Message.ClientService.TryGetUser(Message.Chat, out User user); + + var confirm = await Message.Delegate.NavigationService.ShowPopupAsync(Strings.SharingOfferDisableCancelText, Strings.SharingOfferDisableCancelTitle, Strings.SharingOfferCancelYes, Strings.Cancel); + if (confirm == ContentDialogResult.Primary) + { + Message.ClientService.Send(new ProcessChatHasProtectedContentDisableRequest(Message.ChatId, Message.Id, false)); + } + } + + private async void Accept_Click(object sender, RoutedEventArgs e) + { + var confirm = await Message.Delegate.NavigationService.ShowPopupAsync(Strings.SharingOfferEnableConfirmText, Strings.SharingOfferEnableCancelTitle, Strings.SharingOfferCancelYes, Strings.Cancel); + if (confirm == ContentDialogResult.Primary) + { + Message.ClientService.Send(new ProcessChatHasProtectedContentDisableRequest(Message.ChatId, Message.Id, true)); + } + } + } +} diff --git a/Telegram/Controls/Messages/Service/MessageUpgradedGiftPurchaseOfferContent.xaml.cs b/Telegram/Controls/Messages/Service/MessageUpgradedGiftPurchaseOfferContent.xaml.cs index 823cea4e5b..3e882e2fe1 100644 --- a/Telegram/Controls/Messages/Service/MessageUpgradedGiftPurchaseOfferContent.xaml.cs +++ b/Telegram/Controls/Messages/Service/MessageUpgradedGiftPurchaseOfferContent.xaml.cs @@ -5,6 +5,8 @@ // file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) // +using System; +using Telegram.Common; using Telegram.Streams; using Telegram.Td.Api; using Telegram.ViewModels; @@ -30,7 +32,8 @@ protected override void UpdateContent(MessageViewModel message) Pattern.Update(message.ClientService, upgradedGiftPurchaseOffer.Gift); Animation.Source = DelayedFileSource.FromSticker(message.ClientService, upgradedGiftPurchaseOffer.Gift.Model.Sticker); - if (upgradedGiftPurchaseOffer.State is GiftPurchaseOfferStatePending && !message.IsOutgoing) + var now = DateTime.Now.ToTimestamp(); + if (now < upgradedGiftPurchaseOffer.ExpirationDate && upgradedGiftPurchaseOffer.State is GiftPurchaseOfferStatePending && !message.IsOutgoing) { Accept.Visibility = Visibility.Visible; Reject.Visibility = Visibility.Visible; diff --git a/Telegram/Controls/PatternBackground.xaml.cs b/Telegram/Controls/PatternBackground.xaml.cs index c0b5ce9c25..ab0c241125 100644 --- a/Telegram/Controls/PatternBackground.xaml.cs +++ b/Telegram/Controls/PatternBackground.xaml.cs @@ -74,6 +74,16 @@ public void Update(IClientService clientService, UpgradedGift gift) Update(source, centerColor, edgeColor, symbolColor); } + public void Update(IClientService clientService, UpgradedGiftBackdrop backdrop, UpgradedGiftSymbol symbol) + { + var source = DelayedFileSource.FromSticker(clientService, symbol.Sticker); + var centerColor = backdrop.Colors.CenterColor.ToColor(); + var edgeColor = backdrop.Colors.EdgeColor.ToColor(); + var symbolColor = backdrop.Colors.SymbolColor.ToColor(); + + Update(source, centerColor, edgeColor, symbolColor); + } + public void Update(AnimatedImageSource pattern, Color centerColor, Color edgeColor, Color symbolColor) { _pattern = pattern; @@ -102,6 +112,17 @@ public void Update(AnimatedImageSource pattern, Color centerColor, Color edgeCol Pattern.Source = pattern; } + public void Clear() + { + if (!_templateApplied) + { + return; + } + + HeaderRoot.Background = null; + Pattern.Source = null; + } + #region Footer public object Footer diff --git a/Telegram/Controls/PivotRadioButton.cs b/Telegram/Controls/PivotRadioButton.cs index f7e4326b22..81fdd441b1 100644 --- a/Telegram/Controls/PivotRadioButton.cs +++ b/Telegram/Controls/PivotRadioButton.cs @@ -10,7 +10,7 @@ namespace Telegram.Controls { - public partial class PivotRadioButton : RadioButton + public partial class PivotRadioButton : SettingsRadioButton { public PivotRadioButton() { diff --git a/Telegram/Controls/PremiumProgressBar.cs b/Telegram/Controls/PremiumProgressBar.cs index 4767e4cfd9..ef5b0ac854 100644 --- a/Telegram/Controls/PremiumProgressBar.cs +++ b/Telegram/Controls/PremiumProgressBar.cs @@ -273,6 +273,8 @@ private void UpdateClip() _arrow.Properties.InsertVector3("Translation", new Vector3()); } + Arrow.Fill = GetArrowFill(value); + Vector2 CalculateRadius(float diff) { diff = center + diff - Arrow.ActualSize.X / 2; @@ -311,6 +313,16 @@ float CalculateRadius2(float diff) } } + private SolidColorBrush GetArrowFill(double amount) + { + return Background switch + { + SolidColorBrush solid => solid, + LinearGradientBrush linear => new SolidColorBrush(ColorsHelper.Mix(linear.GradientStops[0].Color, linear.GradientStops[^1].Color, amount)), + _ => null + }; + } + private bool _arrowCentered = true; public void CreatePathGeometry(double radiusLeft, double radiusRight) diff --git a/Telegram/Controls/PrivacyRadioButton.cs b/Telegram/Controls/PrivacyRadioButton.cs index 0739698296..ab05132126 100644 --- a/Telegram/Controls/PrivacyRadioButton.cs +++ b/Telegram/Controls/PrivacyRadioButton.cs @@ -10,7 +10,7 @@ namespace Telegram.Controls { - public partial class PrivacyRadioButton : FauxRadioButton + public partial class PrivacyRadioButton : SettingsRadioButton { #region Type diff --git a/Telegram/Controls/ProfileHeader.xaml b/Telegram/Controls/ProfileHeader.xaml index 9014f6bb1f..1f961cb17c 100644 --- a/Telegram/Controls/ProfileHeader.xaml +++ b/Telegram/Controls/ProfileHeader.xaml @@ -553,6 +553,13 @@ + + diff --git a/Telegram/Controls/ProfileHeader.xaml.cs b/Telegram/Controls/ProfileHeader.xaml.cs index 6f40e6c5dd..4bcbfec90e 100644 --- a/Telegram/Controls/ProfileHeader.xaml.cs +++ b/Telegram/Controls/ProfileHeader.xaml.cs @@ -1422,7 +1422,7 @@ private void UpdateUsernames(Usernames usernames) private void About_ContextRequested(UIElement sender, ContextRequestedEventArgs args) { - MessageHelper.Hyperlink_ContextRequested(ViewModel.TranslateService, sender, args); + MessageHelper.Hyperlink_ContextRequested(ViewModel.TranslateService, sender, args, null); } private void About_ContextMenuOpening(object sender, ContextMenuEventArgs e) @@ -1581,6 +1581,7 @@ void AddToggle(int value, int? parameter, string text, string icon) if (user.Type is UserTypeRegular && !user.IsSupport) { flyout.CreateFlyoutItem(ViewModel.CreateSecretChat, Strings.StartEncryptedChat, Icons.LockClosed); + flyout.CreateFlyoutItem(ViewModel.ToggleProtectedContent, chat.HasProtectedContent ? Strings.EnableSharing : Strings.DisableSharing, chat.HasProtectedContent ? Icons.Share : Icons.ShareOff); } } else @@ -1612,7 +1613,7 @@ void AddToggle(int value, int? parameter, string text, string icon) { //flyout.CreateFlyoutItem(ViewModel.EditCommand, Strings.ManageChannelMenu, Icons.Edit); } - else if (chat.Permissions.CanInviteUsers || supergroup.CanInviteUsers()) + else if (supergroup.CanInviteUsers(chat)) { flyout.CreateFlyoutItem(ViewModel.Invite, Strings.AddMember, Icons.PersonAdd); } @@ -2145,10 +2146,7 @@ private void Location_Click(object sender, RoutedEventArgs e) { try { - var options = new Windows.System.LauncherOptions(); - options.FallbackUri = new Uri(string.Format(CultureInfo.InvariantCulture, "https://www.google.com/maps/search/?api=1&query={0},{1}", location.Latitude, location.Longitude)); - - _ = Windows.System.Launcher.LaunchUriAsync(new Uri(string.Format(CultureInfo.InvariantCulture, "bingmaps:?collection=point.{0}_{1}", location.Latitude, location.Longitude)), options); + _ = Windows.System.Launcher.LaunchUriAsync(new Uri(string.Format(CultureInfo.InvariantCulture, "https://www.google.com/maps/search/?api=1&query={0},{1}", location.Latitude, location.Longitude))); } catch { diff --git a/Telegram/Controls/ProfilePatternCover.cs b/Telegram/Controls/ProfilePatternCover.cs index 57527db72f..c7ab708910 100644 --- a/Telegram/Controls/ProfilePatternCover.cs +++ b/Telegram/Controls/ProfilePatternCover.cs @@ -55,12 +55,15 @@ public ProfilePatternCover() protected override void OnApplyTemplate() { // TODO: Names - var animated = GetTemplateChild("Animated") as AnimatedImage; + var pattern = GetTemplateChild("Animated") as UIElement; var layoutRoot = GetTemplateChild("LayoutRoot") as Border; - animated.Ready += OnReady; + if (pattern is AnimatedImage animated) + { + animated.Ready += OnReady; + } - var visual = ElementComposition.GetElementVisual(animated); + var visual = ElementComposition.GetElementVisual(pattern); var compositor = visual.Compositor; // Create a VisualSurface positioned at the same location as this control and feed that diff --git a/Telegram/Controls/ReplyMarkupPanel.cs b/Telegram/Controls/ReplyMarkupPanel.cs index 80312a211a..27080bf27f 100644 --- a/Telegram/Controls/ReplyMarkupPanel.cs +++ b/Telegram/Controls/ReplyMarkupPanel.cs @@ -9,12 +9,15 @@ using Telegram.Common; using Telegram.Controls.Media; using Telegram.Controls.Messages; +using Telegram.Navigation; +using Telegram.Streams; using Telegram.Td.Api; using Telegram.ViewModels; using Windows.Foundation; using Windows.UI.Xaml; using Windows.UI.Xaml.Automation.Peers; using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Input; namespace Telegram.Controls { @@ -164,11 +167,29 @@ public bool Update(MessageViewModel message, ReplyMarkupShowKeyboard keyboardMar button.CornerRadius = new CornerRadius(topLeft, topRight, bottomRight, bottomLeft); + if (item.IconCustomEmojiId != 0) + { + button.Source = new CustomEmojiFileSource(message.ClientService, item.IconCustomEmojiId); + } + if (item.Type is KeyboardButtonTypeWebApp) { button.Glyph = Icons.Window16; } + switch (item.Style) + { + case ButtonStylePrimary: + button.Style = BootStrapper.Current.Resources["AccentReplyMarkupButtonStyle"] as Style; + break; + case ButtonStyleDanger: + button.Style = BootStrapper.Current.Resources["DangerReplyMarkupButtonStyle"] as Style; + break; + case ButtonStyleSuccess: + button.Style = BootStrapper.Current.Resources["SuccessReplyMarkupButtonStyle"] as Style; + break; + } + panel.Children.Add(button); } @@ -254,6 +275,26 @@ protected override AutomationPeer OnCreateAutomationPeer() public KeyboardButton Button { get; } + private UIElement IconPresenter; + private UIElement EmojiPresenter; + + protected override void OnApplyTemplate() + { + if (!string.IsNullOrEmpty(Icon)) + { + IconPresenter = GetTemplateChild(nameof(IconPresenter)) as UIElement; + IconPresenter.Visibility = Visibility.Visible; + } + + if (Source != null) + { + EmojiPresenter = GetTemplateChild(nameof(EmojiPresenter)) as UIElement; + EmojiPresenter.Visibility = Visibility.Visible; + } + + base.OnApplyTemplate(); + } + #region Text public string Text @@ -266,6 +307,56 @@ public string Text DependencyProperty.Register("Text", typeof(string), typeof(ReplyMarkupButton), new PropertyMetadata(string.Empty)); #endregion + + #region Icon + + public string Icon + { + get { return (string)GetValue(IconProperty); } + set { SetValue(IconProperty, value); } + } + + public static readonly DependencyProperty IconProperty = + DependencyProperty.Register("Icon", typeof(string), typeof(ReplyMarkupButton), new PropertyMetadata(string.Empty, OnIconChanged)); + + private static void OnIconChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) + { + var sender = d as ReplyMarkupButton; + if (sender?.IconPresenter != null || !string.IsNullOrEmpty((string)e.NewValue)) + { + sender.IconPresenter ??= sender.GetTemplateChild(nameof(sender.IconPresenter)) as UIElement; + sender.IconPresenter?.Visibility = string.IsNullOrEmpty((string)e.NewValue) + ? Visibility.Collapsed + : Visibility.Visible; + } + } + + #endregion + + #region Source + + public AnimatedImageSource Source + { + get { return (AnimatedImageSource)GetValue(SourceProperty); } + set { SetValue(SourceProperty, value); } + } + + public static readonly DependencyProperty SourceProperty = + DependencyProperty.Register(nameof(Source), typeof(AnimatedImageSource), typeof(ReplyMarkupButton), new PropertyMetadata(null, OnSourceChanged)); + + private static void OnSourceChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) + { + var sender = d as ReplyMarkupButton; + if (sender?.EmojiPresenter != null || e.NewValue != null) + { + sender.EmojiPresenter ??= sender.GetTemplateChild(nameof(sender.EmojiPresenter)) as UIElement; + sender.EmojiPresenter?.Visibility = e.NewValue == null + ? Visibility.Collapsed + : Visibility.Visible; + } + } + + #endregion } public partial class ReplyMarkupButtonAutomationPeer : ButtonAutomationPeer @@ -309,6 +400,7 @@ protected override AutomationPeer OnCreateAutomationPeer() public InlineKeyboardButton Button { get; } private UIElement IconPresenter; + private UIElement EmojiPresenter; protected override void OnApplyTemplate() { @@ -318,6 +410,12 @@ protected override void OnApplyTemplate() IconPresenter.Visibility = Visibility.Visible; } + if (Source != null) + { + EmojiPresenter = GetTemplateChild(nameof(EmojiPresenter)) as UIElement; + EmojiPresenter.Visibility = Visibility.Visible; + } + base.OnApplyTemplate(); } @@ -351,7 +449,6 @@ private static void OnIconChanged(DependencyObject d, DependencyPropertyChangedE if (sender?.IconPresenter != null || !string.IsNullOrEmpty((string)e.NewValue)) { sender.IconPresenter ??= sender.GetTemplateChild(nameof(sender.IconPresenter)) as UIElement; - sender.IconPresenter?.Visibility = string.IsNullOrEmpty((string)e.NewValue) ? Visibility.Collapsed : Visibility.Visible; @@ -359,6 +456,70 @@ private static void OnIconChanged(DependencyObject d, DependencyPropertyChangedE } #endregion + + #region Source + + public AnimatedImageSource Source + { + get { return (AnimatedImageSource)GetValue(SourceProperty); } + set { SetValue(SourceProperty, value); } + } + + public static readonly DependencyProperty SourceProperty = + DependencyProperty.Register(nameof(Source), typeof(AnimatedImageSource), typeof(ReplyMarkupInlineButton), new PropertyMetadata(null, OnSourceChanged)); + + private static void OnSourceChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) + { + var sender = d as ReplyMarkupInlineButton; + if (sender?.EmojiPresenter != null || e.NewValue != null) + { + sender.EmojiPresenter ??= sender.GetTemplateChild(nameof(sender.EmojiPresenter)) as UIElement; + sender.EmojiPresenter?.Visibility = e.NewValue == null + ? Visibility.Collapsed + : Visibility.Visible; + } + } + + #endregion + + protected override void OnKeyDown(KeyRoutedEventArgs e) + { + if (e.Key is VirtualKey.Left or VirtualKey.Right && Parent is Panel panel) + { + e.Handled = true; + + var index = panel.Children.IndexOf(this); + + Control control = null; + if (e.Key == VirtualKey.Left && index > 0) + { + control = panel.Children[index - 1] as Control; + } + else if (e.Key == VirtualKey.Right && index < panel.Children.Count - 1) + { + control = panel.Children[index + 1] as Control; + } + + control?.Focus(Windows.UI.Xaml.FocusState.Keyboard); + } + if (e.Key is >= VirtualKey.Left and <= VirtualKey.Down && false) + { + e.Handled = true; + + var direction = e.Key switch + { + VirtualKey.Left => FocusNavigationDirection.Left, + VirtualKey.Up => FocusNavigationDirection.Up, + VirtualKey.Right => FocusNavigationDirection.Right, + VirtualKey.Down => FocusNavigationDirection.Down, + _ => FocusNavigationDirection.Next + }; + + FocusManager.TryMoveFocus(direction, new FindNextElementOptions { SearchRoot = Parent }); + } + + base.OnKeyDown(e); + } } public partial class ReplyMarkupInlineButtonAutomationPeer : ButtonAutomationPeer @@ -376,6 +537,11 @@ protected override string GetNameCore() return _owner.Text; } + protected override AutomationControlType GetAutomationControlTypeCore() + { + return AutomationControlType.ListItem; + } + protected override int GetPositionInSetCore() { if (_owner._owner != null) diff --git a/Telegram/Controls/SettingsRadioButton.cs b/Telegram/Controls/SettingsRadioButton.cs new file mode 100644 index 0000000000..e0d92c4ae4 --- /dev/null +++ b/Telegram/Controls/SettingsRadioButton.cs @@ -0,0 +1,64 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using Windows.UI.Xaml; + +namespace Telegram.Controls +{ + public class SettingsRadioButton : FauxRadioButton + { + private UIElement DescriptionPresenter; + + public SettingsRadioButton() + { + DefaultStyleKey = typeof(SettingsRadioButton); + } + + protected override void OnApplyTemplate() + { + if (ComputedIsDescriptionVisible) + { + DescriptionPresenter = GetTemplateChild(nameof(DescriptionPresenter)) as UIElement; + DescriptionPresenter?.Visibility = Visibility.Visible; + } + + base.OnApplyTemplate(); + } + + #region Description + + public object Description + { + get { return (object)GetValue(DescriptionProperty); } + set { SetValue(DescriptionProperty, value); } + } + + public static readonly DependencyProperty DescriptionProperty = + DependencyProperty.Register("Description", typeof(object), typeof(SettingsRadioButton), new PropertyMetadata(null, OnDescriptionChanged)); + + private static void OnDescriptionChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) + { + var sender = d as SettingsRadioButton; + if (sender?.DescriptionPresenter != null || sender.ComputedIsDescriptionVisible) + { + sender.DescriptionPresenter ??= sender.GetTemplateChild(nameof(sender.DescriptionPresenter)) as UIElement; + + sender.DescriptionPresenter?.Visibility = sender.ComputedIsDescriptionVisible + ? Visibility.Visible + : Visibility.Collapsed; + } + } + + #endregion + + #region IsDescriptionVisible + + public bool ComputedIsDescriptionVisible => Description is string description ? !string.IsNullOrEmpty(description) : Description != null; + + #endregion + } +} diff --git a/Telegram/Controls/Stories/StoriesStrip.xaml b/Telegram/Controls/Stories/StoriesStrip.xaml index 8ff64b559f..4f324e7b03 100644 --- a/Telegram/Controls/Stories/StoriesStrip.xaml +++ b/Telegram/Controls/Stories/StoriesStrip.xaml @@ -54,5 +54,14 @@ CornerRadius="16" VerticalAlignment="Top" HorizontalAlignment="Left" /> + + diff --git a/Telegram/Controls/Stories/StoriesStrip.xaml.cs b/Telegram/Controls/Stories/StoriesStrip.xaml.cs index a5b1b66395..27f9c4582e 100644 --- a/Telegram/Controls/Stories/StoriesStrip.xaml.cs +++ b/Telegram/Controls/Stories/StoriesStrip.xaml.cs @@ -11,7 +11,9 @@ using Telegram.Common; using Telegram.Controls.Cells; using Telegram.Controls.Media; +using Telegram.Controls.Messages; using Telegram.Td.Api; +using Telegram.ViewModels.Drawers; using Telegram.ViewModels.Stories; using Telegram.Views.Stories.Popups; using Windows.Foundation; @@ -106,15 +108,25 @@ private void UpdateIndexes() } var count = _last - _first + 1; - if (count > 0 && _collapsed) + if (count > 0 && _collapsed && _isVisible) { Show.Width = count * 12 + 12 + 8; Show.Margin = new Thickness(_first > 0 ? 26 : 14, 20, 0, 0); Show.Visibility = Visibility.Visible; + + Icon.Margin = new Thickness(Show.Width + Show.Margin.Left + 8, 20, 0, 0); + Icon.Visibility = Visibility.Visible; + + TitleBarrr?.IsHitTestVisible = false; + TitleBarHandle?.Margin = new Thickness(SystemOverlayLeftInset > 0 ? SystemOverlayLeftInset + (count * 12 + 12 + 8) : TitleBarrr.Margin.Left + 40 + (count * 12 + 12 + 8), 0, SystemOverlayRightInset > 0 ? SystemOverlayRightInset : 88, 0); } else { Show.Visibility = Visibility.Collapsed; + Icon.Visibility = Visibility.Collapsed; + + TitleBarrr?.IsHitTestVisible = true; + TitleBarHandle?.Margin = new Thickness(SystemOverlayLeftInset > 0 ? SystemOverlayLeftInset : TitleBarrr.Margin.Left + 40, 0, SystemOverlayRightInset > 0 ? SystemOverlayRightInset : 88, 0); } ScrollingHost.IsHitTestVisible = !_collapsed; @@ -347,6 +359,7 @@ public FrameworkElement ChatTabs } public FrameworkElement TitleBarrr { get; set; } + public Border TitleBarHandle { get; set; } public FrameworkElement Header { get; set; } private bool _tabsLeftCollapsed = true; @@ -371,6 +384,17 @@ public float SystemOverlayLeftInset } } + private float _systemOverlayRightInset; + public float SystemOverlayRightInset + { + get => _systemOverlayRightInset; + set + { + _systemOverlayRightInset = value; + UpdateIndexes(); + } + } + private void UpdatePadding() { _progress?.InsertBoolean("RightToLeft", _systemOverlayLeftInset > 0); @@ -385,6 +409,8 @@ public bool IsVisible { _isVisible = value; _progress?.InsertBoolean("Visible", value); + + UpdateIndexes(); } } @@ -479,6 +505,7 @@ private void SetControlledList(FrameworkElement value) _progress.InsertScalar("First", _first); _progress.InsertScalar("Last", _last); _progress.InsertScalar("Count", _last - _first + 1); + _progress.InsertScalar("Total", _last + 1); _progress.InsertScalar("Progress", 0); _progress.StartAnimation("Progress", _progressAnimation); @@ -487,8 +514,21 @@ private void SetControlledList(FrameworkElement value) ForEach(_progress, _progressAnimation); - var titleVisualOffsetAnimation = compositor.CreateExpressionAnimation( - "_.RightToLeft ? 0 : _.Visible && _.Count > 0 ? (24 + (12 * _.Count)) * (1 - _.Progress) : 0"); + // >= 0.5 : above + // < 0.5 : below + var offsetExpandedX = "-(_.Padding - _.First * 12) * (_.Progress)"; + var offsetExpandedX2 = "24 + (12 * _.Count) + (((72 * _.Total) - (40 + (12 * _.Total))) * _.Progress)"; + var offsetExpandedY = "48 * _.Progress"; + + var offsetExpressionX = $"_.Progress < 0.5 ? ({offsetExpandedX}) + ({offsetExpandedX2}) : 0"; + var offsetExpressionY = $"_.Progress < 0.5 ? {offsetExpandedY} : 0"; + var scaleExpression = "_.Progress < 0.5 ? 1 : 0.5 + (_.Progress - 0.5)"; + var opacityExpression = "_.Progress < 0.5 ? 1 - _.Progress * 2 : (_.Progress - 0.5) * 2"; + + var titleVisualOffsetAnimation = compositor.CreateExpressionAnimation($"_.Visible && _.Count > 0 ? Vector3({offsetExpressionX}, {offsetExpressionY}, 0) : Vector3(0, 0, 0)"); + var titleVisualScaleAnimation = compositor.CreateExpressionAnimation($"_.Visible && _.Count > 0 ? Vector3(Clamp({scaleExpression}, 0.5, 1), Clamp({scaleExpression}, 0.5, 1), 1) : Vector3(1, 1, 1)"); + var titleVisualOpacityAnimation = compositor.CreateExpressionAnimation($"_.Visible && _.Count > 0 ? Clamp({opacityExpression}, 0, 1) : 1"); + var titleVisualOpacityInverseAnimation = compositor.CreateExpressionAnimation("Clamp(1 - _.Progress * 2, 0, 1)"); var storiesVisualOffsetAnimationX = compositor.CreateExpressionAnimation( "(_.Padding - _.First * 12) * (1 - _.Progress)"); @@ -500,6 +540,9 @@ private void SetControlledList(FrameworkElement value) "84 * _.Progress"); titleVisualOffsetAnimation.SetReferenceParameter("_", _progress); + titleVisualScaleAnimation.SetReferenceParameter("_", _progress); + titleVisualOpacityAnimation.SetReferenceParameter("_", _progress); + titleVisualOpacityInverseAnimation.SetReferenceParameter("_", _progress); storiesVisualOffsetAnimationX.SetReferenceParameter("_", _progress); storiesVisualOffsetAnimation.SetReferenceParameter("_", _progress); headerVisualOffsetAnimation.SetReferenceParameter("_", _progress); @@ -508,6 +551,7 @@ private void SetControlledList(FrameworkElement value) var storiesVisual = ElementComposition.GetElementVisual(this); var headerVisual = ElementComposition.GetElementVisual(Header); + titleVisual.CenterPoint = new Vector3(0, 10, 0); storiesVisual.Clip = clip; titleVisual.Properties.InsertVector3("Translation", Vector3.Zero); @@ -518,7 +562,9 @@ private void SetControlledList(FrameworkElement value) ElementCompositionPreview.SetIsTranslationEnabled(this, true); ElementCompositionPreview.SetIsTranslationEnabled(Header, true); - titleVisual.StartAnimation("Translation.X", titleVisualOffsetAnimation); + titleVisual.StartAnimation("Translation", titleVisualOffsetAnimation); + titleVisual.StartAnimation("Scale", titleVisualScaleAnimation); + titleVisual.StartAnimation("Opacity", titleVisualOpacityAnimation); storiesVisual.StartAnimation("Translation.X", storiesVisualOffsetAnimationX); clip.StartAnimation("RightInset", storiesVisualOffsetAnimationX); storiesVisual.StartAnimation("Translation.Y", storiesVisualOffsetAnimation); @@ -797,5 +843,13 @@ public void Expand(bool animated = true, float offset = 0) #endregion + + private void Icon_Click(object sender, RoutedEventArgs e) + { + if (ViewModel.IsPremium) + { + EmojiMenuFlyout.ShowAt(ViewModel.ClientService, EmojiDrawerMode.EmojiStatus, Icon, EmojiFlyoutAlignment.TopLeft); + } + } } } diff --git a/Telegram/Controls/Stories/StoryContent.xaml.cs b/Telegram/Controls/Stories/StoryContent.xaml.cs index 486a816e56..b0fb729c2f 100644 --- a/Telegram/Controls/Stories/StoryContent.xaml.cs +++ b/Telegram/Controls/Stories/StoryContent.xaml.cs @@ -660,10 +660,7 @@ private async void Area_Click(object sender, RoutedEventArgs e) _ => null }; - var options = new Windows.System.LauncherOptions(); - options.FallbackUri = new Uri(string.Format(CultureInfo.InvariantCulture, "https://www.google.com/maps/search/?api=1&query={0},{1}", location.Latitude, location.Longitude)); - - await Windows.System.Launcher.LaunchUriAsync(new Uri(string.Format(CultureInfo.InvariantCulture, "bingmaps:?collection=point.{0}_{1}", location.Latitude, location.Longitude)), options); + await Windows.System.Launcher.LaunchUriAsync(new Uri(string.Format(CultureInfo.InvariantCulture, "https://www.google.com/maps/search/?api=1&query={0},{1}", location.Latitude, location.Longitude))); } catch { diff --git a/Telegram/Controls/TableView.cs b/Telegram/Controls/TableView.cs index c437315fc5..1a2b869220 100644 --- a/Telegram/Controls/TableView.cs +++ b/Telegram/Controls/TableView.cs @@ -45,9 +45,9 @@ private void OnColumnWidthChanged(object sender, EventArgs e) width = Math.Max(width, child.ColumnWidth); } - if (RootGrid.Margin.Left != width) + if (RootGrid.Width != width) { - RootGrid.Margin = new Thickness(width, 0, 0, 0); + RootGrid.Width = width; foreach (TableViewItem child in ItemsPanelRoot.Children) { diff --git a/Telegram/Controls/ToastPopup.cs b/Telegram/Controls/ToastPopup.cs index fc47872344..3fe5235e3e 100644 --- a/Telegram/Controls/ToastPopup.cs +++ b/Telegram/Controls/ToastPopup.cs @@ -7,6 +7,7 @@ using Microsoft.UI.Xaml.Controls; using System; +using System.Threading; using System.Threading.Tasks; using Telegram.Common; using Telegram.Controls.Messages; @@ -511,6 +512,60 @@ void closed(TeachingTip sender, TeachingTipClosedEventArgs e) return Task.FromResult(ContentDialogResult.None); } + public static Task ShowActionAsync(XamlRoot xamlRoot, FrameworkElement text, string action, FrameworkElement icon, TeachingTipPlacementMode placement, ElementTheme requestedTheme = ElementTheme.Dark, TimeSpan? dismissAfter = null, CancellationToken cancellationToken = default) + { + var toast = ShowImpl(xamlRoot, text, icon, placement, requestedTheme, dismissAfter); + if (toast?.Content is Grid content) + { + toast.MaxWidth = 500; + + if (cancellationToken != default) + { + cancellationToken.Register(() => + { + toast.IsOpen = false; + }); + } + + var tsc = new TaskCompletionSource(); + var undo = new Button() + { + Content = action, + FontWeight = FontWeights.SemiBold, + VerticalAlignment = VerticalAlignment.Center, + Style = BootStrapper.Current.Resources["AccentTextButtonStyle"] as Style, + Margin = new Thickness(8, -4, -4, -4), + Padding = new Thickness(4, 5, 4, 6) + }; + + void handler(object sender, RoutedEventArgs e) + { + Logger.Info("closed"); + + tsc.TrySetResult(ContentDialogResult.Primary); + undo.Click -= handler; + + toast.IsOpen = false; + } + + void closed(TeachingTip sender, TeachingTipClosedEventArgs e) + { + tsc.TrySetResult(ContentDialogResult.None); + sender.Closed -= closed; + } + + undo.Click += handler; + toast.Closed += closed; + + Grid.SetColumn(undo, 2); + content.Children.Add(undo); + + return tsc.Task; + } + + return Task.FromResult(ContentDialogResult.None); + } + public static Task ShowCountdownAsync(XamlRoot xamlRoot, string text, string action, TimeSpan dismissAfter, ElementTheme requestedTheme = ElementTheme.Dark) { return ShowCountdownAsync(xamlRoot, ClientEx.ParseMarkdown(text), action, dismissAfter, TeachingTipPlacementMode.Center, requestedTheme); diff --git a/Telegram/Controls/TopNavView.cs b/Telegram/Controls/TopNavView.cs index 1951c5fc0d..9ef4243f59 100644 --- a/Telegram/Controls/TopNavView.cs +++ b/Telegram/Controls/TopNavView.cs @@ -183,6 +183,9 @@ private void AnimateSelectionChanged(object nextItem, bool retry = true) var scopedBatch = BootStrapper.Current.Compositor.CreateScopedBatch(CompositionBatchTypes.Animation); scopedBatch.Completed += OnAnimationCompleted; + SetZIndex(prevIndicator, -1); + SetZIndex(nextIndicator, -2); + // Play the animation on both the previous and next indicators PlayIndicatorAnimations(prevIndicator, 0, @@ -213,6 +216,15 @@ private void AnimateSelectionChanged(object nextItem, bool retry = true) } } + private void SetZIndex(UIElement indicator, int index) + { + var selector = indicator.GetParent(); + if (selector != null) + { + Canvas.SetZIndex(selector, index); + } + } + private UIElement FindSelectionIndicator(object item, bool retry) { var container = (item is TopNavViewItem ? item : ContainerFromItem(item)) as TopNavViewItem; diff --git a/Telegram/Controls/Views/ForumView.xaml b/Telegram/Controls/Views/ForumView.xaml index b9b4ea0f93..9f298f97d7 100644 --- a/Telegram/Controls/Views/ForumView.xaml +++ b/Telegram/Controls/Views/ForumView.xaml @@ -196,7 +196,9 @@ - + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Telegram/Views/Gifts/Popups/GiftCraftChoosePopup.xaml.cs b/Telegram/Views/Gifts/Popups/GiftCraftChoosePopup.xaml.cs new file mode 100644 index 0000000000..3ea91c5fae --- /dev/null +++ b/Telegram/Views/Gifts/Popups/GiftCraftChoosePopup.xaml.cs @@ -0,0 +1,431 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using Microsoft.Graphics.Canvas.Geometry; +using System; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.Numerics; +using System.Runtime.InteropServices.WindowsRuntime; +using System.Threading; +using System.Threading.Tasks; +using Telegram.Common; +using Telegram.Controls; +using Telegram.Controls.Cells; +using Telegram.Controls.Media; +using Telegram.Navigation; +using Telegram.Navigation.Services; +using Telegram.Services; +using Telegram.Td.Api; +using Telegram.Views.Popups; +using Telegram.Views.Stars.Popups; +using Windows.Foundation; +using Windows.UI; +using Windows.UI.Composition; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Controls.Primitives; +using Windows.UI.Xaml.Data; +using Windows.UI.Xaml.Hosting; + +namespace Telegram.Views.Gifts.Popups +{ + public partial class GiftsForCraftingCollection : ObservableCollection, ISupportIncrementalLoading + { + private readonly IClientService _clientService; + private readonly long _giftId; + + private readonly GiftForResaleOrder _order = new GiftForResaleOrderPrice(); + private readonly bool _forCrafting; + private readonly IList _attributes = Array.Empty(); + + private string _nextOffset = string.Empty; + private bool _hasMoreItems = true; + + public GiftsForCraftingCollection(IClientService clientService, long giftId, GiftsForCrafting crafting) + : base(crafting.Gifts.Where(x => x.Gift is SentGiftUpgraded upgraded && upgraded.Gift.OwnerId.IsUser(clientService.Options.MyId))) + { + _clientService = clientService; + _giftId = giftId; + _nextOffset = crafting.NextOffset; + } + + public IAsyncOperation LoadMoreItemsAsync(uint count) + { + return AsyncInfo.Run(LoadMoreItemsAsync); + } + + private async Task LoadMoreItemsAsync(CancellationToken token) + { + var totalCount = 0u; + + var response = await _clientService.SendAsync(new GetGiftsForCrafting(_giftId, _nextOffset, 24)); + if (response is GiftsForCrafting gifts) + { + foreach (var gift in gifts.Gifts) + { + if (gift.Gift is SentGiftUpgraded upgraded && upgraded.Gift.OwnerId.IsUser(_clientService.Options.MyId)) + { + Add(gift); + totalCount++; + } + } + + _nextOffset = gifts.NextOffset; + _hasMoreItems = gifts.NextOffset.Length > 0; + } + else + { + _nextOffset = string.Empty; + _hasMoreItems = false; + } + + return new LoadMoreItemsResult + { + Count = totalCount + }; + } + + public bool HasMoreItems => _hasMoreItems; + + public GiftForResaleOrder Order => _order; + } + + public sealed partial class GiftCraftChoosePopup : ContentPopup, IResoldGiftsPopup + { + private readonly IClientService _clientService; + private readonly INavigationService _navigationService; + + private readonly long _giftId; + private readonly int _resaleCount; + private readonly MessageSender _receiverId; + + private ResoldGiftsCollection _gifts; + + private ResoldGiftFilterManager _models; + private ResoldGiftFilterManager _backdrops; + private ResoldGiftFilterManager _symbols; + + public GiftCraftChoosePopup(IClientService clientService, INavigationService navigationService, ReceivedGift gift, GiftsForCrafting crafting) + { + InitializeComponent(); + + _clientService = clientService; + _navigationService = navigationService; + + if (gift.Gift is not SentGiftUpgraded upgraded) + { + return; + } + + _giftId = upgraded.Gift.RegularGiftId; + //_resaleCount = valueInfo.TelegramListedGiftCount; + //_receiverId = receiverId; + + Title = upgraded.Gift.Title; + //Subtitle.Text = Locale.Declension(Strings.R.Gift2ResaleCount, valueInfo.TelegramListedGiftCount); + + _gifts = new ResoldGiftsCollection(clientService, this, upgraded.Gift.RegularGiftId); + ScrollingHost.ItemsSource = _gifts; + + ScrollingHost2.ItemsSource = new GiftsForCraftingCollection(clientService, upgraded.Gift.RegularGiftId, crafting); + + //if (valueInfo.TelegramListedGiftCount >= 18) + { + OrderIcon.Text = Icons.DollarArrowUp16; + OrderText.Text = Strings.ResellGiftFilterSortPriceShort; + ModelButton.Content = Strings.Gift2ResaleFilterModel; + BackdropButton.Content = Strings.Gift2ResaleFilterBackdrop; + SymbolButton.Content = Strings.Gift2ResaleFilterSymbol; + } + //else + //{ + // FiltersRoot.Visibility = Visibility.Collapsed; + //} + + Opened += OnOpened; + } + + public ReceivedGift SelectedGift { get; private set; } + + private void OnOpened(ContentDialog sender, ContentDialogOpenedEventArgs args) + { + ShowHideSkeleton(); + } + + public void UpdateItems(GiftsForResale gifts, bool updateFilters) + { + if (updateFilters) + { + if (gifts.Models.Count > 0) + { + _models = new ResoldGiftFilterManager(_clientService, this, ModelButton, gifts.Models); + } + + if (gifts.Backdrops.Count > 0) + { + _backdrops = new ResoldGiftFilterManager(_clientService, this, BackdropButton, gifts.Backdrops); + } + + if (gifts.Symbols.Count > 0) + { + _symbols = new ResoldGiftFilterManager(_clientService, this, SymbolButton, gifts.Symbols); + } + } + + Subtitle.Text = Locale.Declension(Strings.R.Gift2ResaleCount, gifts.TotalCount); + ShowHideSkeleton(); + } + + private bool _skeletonCollapsed = true; + + private void ShowHideSkeleton() + { + if (_skeletonCollapsed && _gifts.Count == 0) + { + _skeletonCollapsed = false; + ShowSkeleton(); + } + else if (_skeletonCollapsed is false && _gifts.Count > 0) + { + _skeletonCollapsed = true; + + var visual = ElementCompositionPreview.GetElementChildVisual(ScrollingHost); + var animation = visual.Compositor.CreateScalarKeyFrameAnimation(); + animation.InsertKeyFrame(0, 1); + animation.InsertKeyFrame(1, 0); + + visual.StartAnimation("Opacity", animation); + } + } + + private void ShowSkeleton() + { + var size = ScrollingHost.ActualSize; + var itemHeight = 136 + 4; + var itemWidth = (size.X - 4) / 3; + + var rows = Math.Min(_resaleCount / 3, Math.Ceiling(size.Y / itemHeight)); + var shapes = new List(); + + for (int i = 0; i < rows; i++) + { + for (int j = 0; j < 3; j++) + { + shapes.Add(CanvasGeometry.CreateRoundedRectangle(null, 4 + j * itemWidth, 4 + itemHeight * i, itemWidth - 4, itemHeight - 4, 4, 4)); + } + } + + var compositor = BootStrapper.Current.Compositor; + + var geometries = shapes.ToArray(); + var path = compositor.CreatePathGeometry(new CompositionPath(CanvasGeometry.CreateGroup(null, geometries, CanvasFilledRegionDetermination.Winding))); + + var transparent = Color.FromArgb(0x00, 0xFF, 0xFF, 0xFF); + var foregroundColor = Color.FromArgb(0x0F, 0xFF, 0xFF, 0xFF); + var backgroundColor = Color.FromArgb(0x0F, 0xFF, 0xFF, 0xFF); + + var lookup = ThemeService.GetLookup(ActualTheme); + if (lookup.TryGet("MenuFlyoutItemBackgroundPointerOver", out Color color)) + { + foregroundColor = color; + backgroundColor = color; + } + + var gradient = compositor.CreateLinearGradientBrush(); + gradient.StartPoint = new Vector2(0, 0); + gradient.EndPoint = new Vector2(1, 0); + gradient.ColorStops.Add(compositor.CreateColorGradientStop(0.0f, transparent)); + gradient.ColorStops.Add(compositor.CreateColorGradientStop(0.5f, foregroundColor)); + gradient.ColorStops.Add(compositor.CreateColorGradientStop(1.0f, transparent)); + + var background = compositor.CreateRectangleGeometry(); + background.Size = size; + var backgroundShape = compositor.CreateSpriteShape(background); + backgroundShape.FillBrush = compositor.CreateColorBrush(backgroundColor); + + var foreground = compositor.CreateRectangleGeometry(); + foreground.Size = size; + var foregroundShape = compositor.CreateSpriteShape(foreground); + foregroundShape.FillBrush = gradient; + + var clip = compositor.CreateGeometricClip(path); + var visual = compositor.CreateShapeVisual(); + visual.Clip = clip; + visual.Shapes.Add(backgroundShape); + visual.Shapes.Add(foregroundShape); + visual.RelativeSizeAdjustment = Vector2.One; + + var animation = compositor.CreateVector2KeyFrameAnimation(); + animation.InsertKeyFrame(0, new Vector2(-size.X, 0)); + animation.InsertKeyFrame(1, new Vector2(size.X, 0)); + animation.IterationBehavior = AnimationIterationBehavior.Forever; + animation.Duration = TimeSpan.FromSeconds(1); + + foregroundShape.StartAnimation("Offset", animation); + + ElementCompositionPreview.SetElementChildVisual(ScrollingHost, visual); + } + + private async void OnItemClick(object sender, ItemClickEventArgs e) + { + if (e.ClickedItem is GiftForResale giftForResale) + { + var chat = await _clientService.GetChatFromMessageSenderAsync(null); + + var confirm = await TransferGiftPopup.ShowAsync(XamlRoot, _clientService, giftForResale, chat); + if (confirm == ContentDialogResult.Primary) + { + GiftResalePrice price; + if (giftForResale.Gift.ResaleParameters.ToncoinOnly) + { + price = new GiftResalePriceTon(giftForResale.Gift.ResaleParameters.ToncoinCentCount); + } + else + { + price = new GiftResalePriceStar(giftForResale.Gift.ResaleParameters.StarCount); + } + + var response = await _clientService.SendPaymentAsync(giftForResale.Gift.ResaleParameters.StarCount, new SendResoldGift(giftForResale.Gift.Name, _clientService.MyId, price)); + if (response is GiftResaleResultOk ok) + { + //_aggregator.Publish(new UpdateGiftIsSold(_gift.ReceivedGiftId)); + SelectedGift = new ReceivedGift(ok.ReceivedGiftId, null, null, 0, false, false, false, false, false, false, 0, new SentGiftUpgraded(giftForResale.Gift), Array.Empty(), 0, 0, false, 0, 0, 0, 0, 0, string.Empty, 0); ; + Hide(ContentDialogResult.Primary); + + //if (chat != null) + //{ + // _navigationService.NavigateToChat(chat.Id); + // ToastPopup.Show(XamlRoot, string.Format("**{0}**\n{1}", Strings.BoughtResoldGiftToTitle, string.Format(Strings.BoughtResoldGiftToText, chat.Title)), new DelayedFileSource(_clientService, upgraded.Gift.Model.Sticker)); + //} + //else + //{ + // ToastPopup.Show(XamlRoot, string.Format("**{0}**\n{1}", Strings.BoughtResoldGiftTitle, string.Format(Strings.BoughtResoldGiftText, upgraded.Gift.ToName())), new DelayedFileSource(_clientService, upgraded.Gift.Model.Sticker)); + //} + } + else if (response is Error error) + { + ToastPopup.ShowError(XamlRoot, error); + } + else if (response is ErrorStarsNeeded) + { + Hide(); + await _navigationService.ShowPopupAsync(new BuyPopup(), BuyStarsArgs.ForChannel(giftForResale.Gift.ResaleParameters.StarCount, 0)); + } + } + + //Hide(ContentDialogResult.Primary); + + //var receivedGift = new ReceivedGift(giftForResale.ReceivedGiftId, null, null, 0, false, false, false, false, false, false, 0, new SentGiftUpgraded(giftForResale.Gift), Array.Empty(), 0, 0, false, 0, 0, 0, 0, 0, string.Empty, 0); + + //var confirm = await _navigationService.ShowPopupAsync(new ReceivedGiftPopup(_clientService, _navigationService, receivedGift, giftForResale.Gift.OwnerId, _receiverId)); + //if (confirm == ContentDialogResult.Primary && _receiverId == null) + //{ + // _gifts.Remove(giftForResale); + // await this.ShowQueuedAsync(XamlRoot); + //} + } + else if (e.ClickedItem is ReceivedGift receivedGift) + { + SelectedGift = receivedGift; + Hide(ContentDialogResult.Primary); + } + } + + private void OnContainerContentChanging(ListViewBase sender, ContainerContentChangingEventArgs args) + { + if (args.InRecycleQueue) + { + return; + } + else if (args.ItemContainer.ContentTemplateRoot is ReceivedGiftCell receivedGiftCell) + { + if (args.Item is GiftForResale giftForResale) + { + receivedGiftCell.UpdateGift(_clientService, giftForResale); + } + else if (args.Item is ReceivedGift receivedGift) + { + receivedGiftCell.UpdateGift(_clientService, receivedGift); + } + } + + args.Handled = true; + } + + private void Order_Click(object sender, RoutedEventArgs e) + { + var flyout = new MenuFlyout(); + flyout.CreateFlyoutItem(UpdateOrder, new GiftForResaleOrderPrice(), Strings.ResellGiftFilterSortPrice, Icons.DollarArrowUp); + flyout.CreateFlyoutItem(UpdateOrder, new GiftForResaleOrderPriceChangeDate(), Strings.ResellGiftFilterSortDate, Icons.CalendarArrowUp); + flyout.CreateFlyoutItem(UpdateOrder, new GiftForResaleOrderNumber(), Strings.ResellGiftFilterSortNumber, Icons.NumberSymbolArrowUp); + + flyout.ShowAt(OrderButton, FlyoutPlacementMode.Bottom); + } + + private void UpdateOrder(GiftForResaleOrder order) + { + UpdateItems(order, GetAttributes()); + + OrderText.Text = order switch + { + GiftForResaleOrderNumber => Strings.ResellGiftFilterSortNumberShort, + GiftForResaleOrderPriceChangeDate => Strings.ResellGiftFilterSortDateShort, + _ => Strings.ResellGiftFilterSortPriceShort + }; + + OrderIcon.Text = order switch + { + GiftForResaleOrderNumber => Icons.NumberSymbolArrowUp16, + GiftForResaleOrderPriceChangeDate => Icons.CalendarArrowUp16, + _ => Icons.DollarArrowUp16 + }; + } + + private void Model_Click(object sender, RoutedEventArgs e) + { + _models?.ShowAt(); + } + + private void Backdrop_Click(object sender, RoutedEventArgs e) + { + _backdrops?.ShowAt(); + } + + private void Symbol_Click(object sender, RoutedEventArgs e) + { + _symbols?.ShowAt(); + } + + public void UpdateAttributes() + { + UpdateItems(_gifts.Order, GetAttributes()); + } + + public void UpdateItems(GiftForResaleOrder order, IList attributes) + { + _gifts = new ResoldGiftsCollection(_clientService, this, _giftId, order, attributes); + ScrollingHost.ItemsSource = _gifts; + ShowHideSkeleton(); + } + + private IList GetAttributes() + { + if (_models == null || _backdrops == null || _symbols == null) + { + return Array.Empty(); + } + + var attributes = new List(_models.GetAttributes()); + attributes.AddRange(_backdrops.GetAttributes()); + attributes.AddRange(_symbols.GetAttributes()); + + return attributes; + } + } +} diff --git a/Telegram/Views/Gifts/Popups/GiftCraftPopup.xaml b/Telegram/Views/Gifts/Popups/GiftCraftPopup.xaml new file mode 100644 index 0000000000..fddb0ac7ca --- /dev/null +++ b/Telegram/Views/Gifts/Popups/GiftCraftPopup.xaml @@ -0,0 +1,521 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Telegram/Views/Gifts/Popups/GiftCraftPopup.xaml.cs b/Telegram/Views/Gifts/Popups/GiftCraftPopup.xaml.cs new file mode 100644 index 0000000000..fd2c1c07be --- /dev/null +++ b/Telegram/Views/Gifts/Popups/GiftCraftPopup.xaml.cs @@ -0,0 +1,1492 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using Microsoft.Graphics.Canvas.Geometry; +using Microsoft.UI.Xaml.Media; +using System; +using System.Collections.Generic; +using System.Linq; +using System.Numerics; +using System.Threading.Tasks; +using Telegram.Common; +using Telegram.Controls; +using Telegram.Controls.Cells; +using Telegram.Controls.Gifts; +using Telegram.Controls.Media; +using Telegram.Navigation; +using Telegram.Navigation.Services; +using Telegram.Services; +using Telegram.Streams; +using Telegram.Td; +using Telegram.Td.Api; +using Telegram.Views.Stars.Popups; +using Windows.UI; +using Windows.UI.Composition; +using Windows.UI.Text; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Documents; +using Windows.UI.Xaml.Hosting; +using Windows.UI.Xaml.Media; + +namespace Telegram.Views.Gifts.Popups +{ + public sealed partial class GiftCraftPopup : ContentPopup + { + private readonly IClientService _clientService; + private readonly INavigationService _navigationService; + + private readonly ReceivedGift[] _items = [null, null, null, null]; + + private readonly ReceivedGift _reference; + + private GiftsForCrafting _crafting; + + private TaskCompletionSource _crafted; + + public GiftCraftPopup(IClientService clientService, INavigationService navigationService, ReceivedGift gift) + { + InitializeComponent(); + + _clientService = clientService; + _navigationService = navigationService; + + _items[0] = gift; + _reference = gift; + + _cube = ElementCompositionPreview.GetElementVisual(Cube); + _cube.CenterPoint = new Vector3(FACE_CENTER, FACE_CENTER, -FACE_CENTER); + + for (int i = 0; i < _items.Length; i++) + { + UpdateContent(Gifts.Children[i] as Button, i, _items[i]); + } + + UpdateSelection(); + + InitializeGiftsForCrafting(); + InitializeGiftVariants(); + InitializeCube(); + } + + private record CraftingColors(Color Center, Color Edge, Color Pattern, Color Button1, Color Button2) + { + public CraftingColors(int center, int edge, int pattern, int button1, int button2) + : this(center.ToColor(), edge.ToColor(), pattern.ToColor(), button1.ToColor(), button2.ToColor()) + { + + } + } + + private readonly CraftingColors[] _colors = new[] + { + new CraftingColors(0x2C4359, 0x232E3F, 0x040C1A, 0x10A5DF, 0x2091E9), + new CraftingColors(0x2C4359, 0x232E3F, 0x040C1A, 0x10A5DF, 0x2091E9), + new CraftingColors(0x2C4359, 0x232E3F, 0x040C1A, 0x10A5DF, 0x2091E9), + new CraftingColors(0x1C4843, 0x1A2E37, 0x040C1A, 0x3ACA49, 0x007D9E), + new CraftingColors(0x5D2E16, 0x371B1A, 0x040C1A, 0xE27519, 0xDD4819), + }; + + private void InitializeCube() + { + Pattern.Center = new RectangleF(new Vector2(0, 0), new Vector2(140)); + + CreateFace(Face2, Quaternion.Identity); + CreateFace(Face3, CreateRotationY(-90)); + CreateFace(Face4, CreateRotationY(90)); + CreateFace(Face5, CreateRotationY(180)); + CreateFace(Face6, CreateRotationX(90)); + CreateFace(Face1, CreateRotationX(-90)); + + CreateGift(Gift1, new Vector3(-104, -40, 0)); + CreateGift(Gift2, new Vector3(-104, 40, 0)); + CreateGift(Gift3, new Vector3(104, -40, 0)); + CreateGift(Gift4, new Vector3(104, 40, 0)); + } + + private async void InitializeGiftsForCrafting() + { + if (_reference.Gift is not SentGiftUpgraded upgraded) + { + return; + } + + var response = await _clientService.SendAsync(new GetGiftsForCrafting(upgraded.Gift.RegularGiftId, string.Empty, 100)); + if (response is GiftsForCrafting crafting) + { + _crafting = crafting; + UpdateSelection(); + } + } + + private async void InitializeGiftVariants() + { + if (_reference.Gift is not SentGiftUpgraded upgraded) + { + return; + } + + var response = await _clientService.SendAsync(new GetUpgradedGiftVariants(upgraded.Gift.RegularGiftId, false, true)); + if (response is GiftUpgradeVariants variants) + { + var count = Math.Min(variants.Models.Count, 3); + + for (int i = count - 1; i >= 0; i--) + { + var player = new CustomEmojiIcon(); + player.LoopCount = 0; + player.Source = DelayedFileSource.FromSticker(_clientService, variants.Models[i].Sticker); + player.HorizontalAlignment = HorizontalAlignment.Left; + player.FlowDirection = FlowDirection.LeftToRight; + player.IsHitTestVisible = false; + player.Margin = new Thickness(0, -2, 0, -2); + player.Width = 16; + player.Height = 16; + player.FrameSize = new Windows.Foundation.Size(16, 16); + + Variants.Children.Insert(0, player); + } + } + } + + private void UpdateSelection() + { + UpdateText(); + UpdateProbability(); + UpdateColors(); + } + + private class BackdropComparer : IEqualityComparer + { + public bool Equals(UpgradedGiftBackdrop x, UpgradedGiftBackdrop y) + { + return x.Id == y.Id; + } + + public int GetHashCode(UpgradedGiftBackdrop obj) + { + return obj.Id.GetHashCode(); + } + } + + private class SymbolComparer : IEqualityComparer + { + public bool Equals(UpgradedGiftSymbol x, UpgradedGiftSymbol y) + { + return x.Sticker.Id == y.Sticker.Id; + } + + public int GetHashCode(UpgradedGiftSymbol obj) + { + return obj.Sticker.Id.GetHashCode(); + } + } + + private void UpdateColors() + { + var count = _items.Count(x => x != null); + var colors = _colors[Math.Max(0, count - 1)]; + + var radial = new RadialGradientBrush(); + radial.Center = new Point(0.5f, 0.3f); + radial.GradientOrigin = new Point(0.5f, 0.3f); + radial.RadiusX = 0.5; + radial.RadiusY = 0.5; + radial.GradientStops.Add(new GradientStop { Color = colors.Center }); + radial.GradientStops.Add(new GradientStop { Color = colors.Edge, Offset = 1 }); + + BackgroundRoot.Background = radial; + Pattern.Foreground = new SolidColorBrush(colors.Pattern); + + if (count > 0) + { + var linear = new LinearGradientBrush(); + linear.GradientStops.Add(new GradientStop { Color = colors.Button1 }); + linear.GradientStops.Add(new GradientStop { Color = colors.Button2, Offset = 1 }); + + CraftButtonBackground.Background = linear; + CraftButtonBackground.Visibility = Visibility.Visible; + } + else + { + CraftButtonBackground.Visibility = Visibility.Collapsed; + } + } + + private void UpdateProbability() + { + Attributes1.Children.Clear(); + Attributes2.Children.Clear(); + + var count = _items.Count(x => x != null); + if (count > 0) + { + var probability = _crafting?.AttributePersistenceProbabilities[_items.Length - 1]; + var sum = 0f; + + var backdrops = new Dictionary(new BackdropComparer()); + var symbols = new Dictionary(new SymbolComparer()); + + foreach (var gift in _items) + { + if (gift?.Gift is not SentGiftUpgraded upgraded) + { + continue; + } + + backdrops.TryGetValue(upgraded.Gift.Backdrop, out int backdropCount); + backdrops[upgraded.Gift.Backdrop] = ++backdropCount; + + symbols.TryGetValue(upgraded.Gift.Symbol, out int symbolCount); + symbols[upgraded.Gift.Symbol] = ++symbolCount; + + sum += upgraded.Gift.CraftProbabilityPerMille / 1000f; + } + + var backdropTarget = Attributes1; + var symbolTarget = backdrops.Count + symbols.Count > 4 + ? Attributes2 + : Attributes1; + + if (probability != null) + { + foreach (var backdrop in backdrops) + { + backdropTarget.Children.Add(new GiftAttributeGauge(_clientService, backdrop.Key, probability.PersistenceChancePerMille[backdrop.Value - 1] / 1000f)); + } + + foreach (var symbol in symbols) + { + symbolTarget.Children.Add(new GiftAttributeGauge(_clientService, symbol.Key, probability.PersistenceChancePerMille[symbol.Value - 1] / 1000f)); + } + } + + VariantsRoot.Visibility = backdrops.Count + symbols.Count > 4 + ? Visibility.Collapsed + : Visibility.Visible; + + InitializeProbability(sum); + } + else + { + Attributes1.Children.Add(new GiftAttributeGauge(_clientService, null as UpgradedGiftBackdrop, 0)); + Attributes1.Children.Add(new GiftAttributeGauge(_clientService, null as UpgradedGiftSymbol, 0)); + + VariantsRoot.Visibility = Visibility.Visible; + + InitializeProbability(0); + } + } + + private void InitializeProbability(float probability) + { + Probability.Text = (probability * 100).ToString("0.##") + "%"; + CraftingProbability.Text = string.Format(Strings.GiftCraftProgressSuccessChance, (probability * 100).ToString("0.##") + "%"); + + CraftButtonText.Text = Strings.GiftCraftButton; + + if (probability > 0) + { + TextBlockHelper.SetMarkdown(CraftButtonInfo, string.Format(Strings.GiftCraftSuccessChance, (probability * 100).ToString("0.##") + "%")); + } + else + { + TextBlockHelper.SetMarkdown(CraftButtonInfo, Strings.GiftCraftButtonEmpty); + } + + var compositor = BootStrapper.Current.Compositor; + var visual = compositor.CreateShapeVisual(); + + var background = compositor.CreateEllipseGeometry(); + background.Radius = new Vector2(34); + background.Center = new Vector2(36); + background.TrimStart = 0.25f; + + var backgroundShape = compositor.CreateSpriteShape(background); + backgroundShape.StrokeBrush = compositor.CreateColorBrush(Color.FromArgb(0x55, 255, 255, 255)); + backgroundShape.StrokeThickness = 4; + backgroundShape.StrokeStartCap = CompositionStrokeCap.Round; + backgroundShape.StrokeEndCap = CompositionStrokeCap.Round; + backgroundShape.RotationAngleInDegrees = 45 + 90; + backgroundShape.CenterPoint = new Vector2(36); + + var foreground = compositor.CreateEllipseGeometry(); + foreground.Radius = new Vector2(34); + foreground.Center = new Vector2(36); + foreground.TrimStart = 0.25f; + foreground.TrimEnd = 0.25f + (probability * 0.75f); + + var foregroundShape = compositor.CreateSpriteShape(foreground); + foregroundShape.StrokeBrush = compositor.CreateColorBrush(Color.FromArgb(255, 255, 255, 255)); + foregroundShape.StrokeThickness = 4; + foregroundShape.StrokeStartCap = CompositionStrokeCap.Round; + foregroundShape.StrokeEndCap = CompositionStrokeCap.Round; + foregroundShape.RotationAngleInDegrees = 45 + 90; + foregroundShape.CenterPoint = new Vector2(36); + + visual.Shapes.Add(backgroundShape); + visual.Shapes.Add(foregroundShape); + visual.Size = new Vector2(72); + + ElementCompositionPreview.SetElementChildVisual(Gauge, visual); + } + + private void UpdateText() + { + if (_reference.Gift is not SentGiftUpgraded upgraded) + { + return; + } + + var any = _items.Any(x => x != null); + + TextBlockHelper.SetMarkdown(Text1, any ? Strings.GiftCraftText1 : Strings.GiftCraftTextEmpty1); + + var markdown = ClientEx.ParseMarkdown(any ? Strings.GiftCraftText2 : Strings.GiftCraftTextEmpty2); + var previous = 0; + + var paragraph = new Paragraph(); + + foreach (var entity in markdown.Entities) + { + if (entity.Offset > previous) + { + paragraph.Inlines.Add(markdown.Text.Substring(previous, entity.Offset - previous)); + } + + var text = markdown.Text.Substring(entity.Offset, entity.Length); + if (text == "{0}" || text == "{0} #{1}") + { + var player = new CustomEmojiIcon(); + player.LoopCount = 0; + player.Source = DelayedFileSource.FromSticker(_clientService, upgraded.Gift.Model.Sticker); + player.HorizontalAlignment = HorizontalAlignment.Left; + player.FlowDirection = FlowDirection.LeftToRight; + player.IsHitTestVisible = false; + player.Margin = new Thickness(0, -2, 0, -6); + + var inline = new InlineUIContainer(); + inline.Child = player; + + // If the Span starts with a InlineUIContainer the RichTextBlock bugs and shows ellipsis + if (previous == 0) + { + paragraph.Inlines.Add(Icons.ZWNJ); + } + + paragraph.Inlines.Add(inline); + paragraph.Inlines.Add(Icons.ZWNJ); + + paragraph.Inlines.Add(Icons.Space); + + if (any) + { + paragraph.Inlines.Add(string.Format(text, upgraded.Gift.Title, upgraded.Gift.Number.ToString("N0")), FontWeights.SemiBold); + } + else + { + paragraph.Inlines.Add(string.Format(text, upgraded.Gift.Title), FontWeights.SemiBold); + } + } + else + { + paragraph.Inlines.Add(text, FontWeights.SemiBold); + } + + previous = entity.Offset + entity.Length; + } + + if (markdown.Text.Length > previous) + { + paragraph.Inlines.Add(markdown.Text.Substring(previous, markdown.Text.Length - previous)); + } + + Text2.Blocks.Clear(); + Text2.Blocks.Add(paragraph); + } + + private async void Button_Click(object sender, RoutedEventArgs e) + { + if (sender is Button button) + { + SelectGift(button, Gifts.Children.IndexOf(button)); + } + } + + private async void SelectGift(Button target, int index) + { + if (_items[index] != null) + { + UpdateContent(target, index, null); + UpdateSelection(); + return; + } + + Hide(); + + var popup = new GiftCraftChoosePopup(_clientService, _navigationService, _reference, _crafting); + + var confirm = await _navigationService.ShowPopupAsync(popup); + if (confirm == ContentDialogResult.Primary && popup.SelectedGift != null) + { + UpdateContent(target, index, popup.SelectedGift); + UpdateSelection(); + } + + await this.ShowQueuedAsync(XamlRoot); + } + + private void UpdateContent(Button target, int index, ReceivedGift gift) + { + _items[index] = gift; + + var overlay = Overlays.Children[index] as Grid; + var probability = overlay.Children[0] as BadgeControl; + var dismiss = overlay.Children[1] as Border; + + if (gift == null) + { + overlay.Visibility = Visibility.Collapsed; + target.Content = new TextBlock + { + Text = Icons.AddCircleFilled, + FontFamily = BootStrapper.Current.Resources["SymbolThemeFontFamily"] as FontFamily, + FontSize = 48, + HorizontalAlignment = HorizontalAlignment.Center, + VerticalAlignment = VerticalAlignment.Center, + }; + } + else if (gift.Gift is SentGiftUpgraded upgraded) + { + var background = new PatternBackground + { + Margin = new Thickness(-1), + CornerRadius = new CornerRadius(16), + Content = new AnimatedImage + { + AutoPlay = true, + Width = 64, + Height = 64, + FrameSize = new Windows.Foundation.Size(64, 64), + DecodeFrameType = Windows.UI.Xaml.Media.Imaging.DecodePixelType.Logical, + Source = DelayedFileSource.FromSticker(_clientService, upgraded.Gift.Model.Sticker) + } + }; + + background.Update(_clientService, upgraded.Gift); + + overlay.Visibility = Visibility.Visible; + target.Content = background; + + probability.Text = ((upgraded.Gift.CraftProbabilityPerMille / 1000d) * 100).ToString("0.##") + "%"; + + var badge = new SolidColorBrush(upgraded.Gift.Backdrop.Colors.EdgeColor.ToColor().Darken()); + probability.Background = badge; + dismiss.Background = badge; + } + } + + #region Cube + + private readonly Visual _cube; + + private const float FACE_SIZE = 96; + private const float FACE_CENTER = 48; + private const float FACE_SCALE = 64f / 96f; + + private void CreateFace(Grid element, Quaternion rotation) + { + var visual = ElementCompositionPreview.GetElementVisual(element); + visual.CenterPoint = new Vector3(FACE_CENTER, FACE_CENTER, -FACE_CENTER); + visual.Orientation = rotation; + visual.BackfaceVisibility = CompositionBackfaceVisibility.Hidden; + visual.RotationAngle = 0; + + if (rotation.IsIdentity) + { + return; + } + + for (int i = 0; i < element.Children.Count; i++) + { + if (i == 1) + { + element.Children.RemoveAt(1); + i++; + + continue; + } + + element.Children[i].Visibility = Visibility.Visible; + } + } + + private static Quaternion CreateRotationY(float angle) + { + return Quaternion.CreateFromAxisAngle(Vector3.UnitY, DegreesToRadians(angle)); + } + + private static Quaternion CreateRotationX(float angle) + { + return Quaternion.CreateFromAxisAngle(Vector3.UnitX, DegreesToRadians(angle)); + } + + private static float DegreesToRadians(float degrees) + { + return degrees * (MathF.PI / 180f); + } + + private void CreateGift(UIElement element, Vector3 offset) + { + ElementCompositionPreview.SetIsTranslationEnabled(element, true); + + var visual = ElementCompositionPreview.GetElementVisual(element); + visual.Properties.InsertVector3("Translation", offset); + visual.Scale = new Vector3(FACE_SCALE); + visual.CenterPoint = new Vector3(FACE_CENTER, FACE_CENTER, -FACE_CENTER); + visual.Orientation = Quaternion.Identity; + visual.BackfaceVisibility = CompositionBackfaceVisibility.Hidden; + visual.RotationAngleInDegrees = 0; + visual.Opacity = 1; + } + + private bool _spinning; + + private record Face(Visual Visual, float Duration, float Rotations, float Force, Vector3 Axis) + { + public Quaternion Orientation { get; set; } = Quaternion.Identity; + + public bool Snapped { get; set; } + + public float? LastHiddenTime { get; set; } + + public int LastFaceIndex { get; set; } + + public float LastFaceRotationAngle { get; set; } + } + + private record Spin(float Duration, float Rotations, float Force); + + private Spin[][] _spins = new[] + { + new[] + { + new Spin(2244, 3.7f, 1.5f), + }, + new[] + { + //new Spin(1620, 1.2f, 1.5f), + //new Spin(2244, 7.0f, 1.5f), + new Spin(1620, 1.2f, 3.0f), + new Spin(1620, 4.9f, 1.5f), + }, + new[] + { + new Spin(1620, 1.2f, 3.0f), + new Spin(1620, 1.6f, 2.0f), + //new Spin(1620, 2.3f, 2.0f), // 4.3 + new Spin(1620, 5.1f, 1.5f), + //new Spin(1620, 1.2f, 1.8f), + //new Spin(2244, 3.7f, 1.5f), + //new Spin(2244, 7.1f, 1.5f), + }, + new[] + { + new Spin(1333, 1.2f, 3.0f), + new Spin(1333, 1.6f, 2.0f), + new Spin(1333, 2.3f, 2.0f), // 4.3 + new Spin(1333, 5.1f, 1.5f), + }, + }; + + private void TransitionToCrafting() + { + var reference = _items.FirstOrDefault(x => x != null); + if (reference.Gift is not SentGiftUpgraded upgraded) + { + return; + } + + var visual1 = ElementComposition.GetElementVisual(PrepareRoot); + var visual2 = ElementComposition.GetElementVisual(CraftingRoot); + var visual3 = ElementComposition.GetElementVisual(Overlays); + + var show = visual1.Compositor.CreateScalarKeyFrameAnimation(); + show.InsertKeyFrame(0, 0); + show.InsertKeyFrame(1, 1); + + var hide = visual1.Compositor.CreateScalarKeyFrameAnimation(); + hide.InsertKeyFrame(0, 1); + hide.InsertKeyFrame(1, 0); + + visual1.StartAnimation("Opacity", hide); + visual2.StartAnimation("Opacity", show); + visual3.StartAnimation("Opacity", hide); + + CraftingName.Text = upgraded.Gift.ToName(); + CraftingRoot.Visibility = Visibility.Visible; + } + + private ulong _tickCount; + private float _accumulated; + + private readonly HashSet _excludedFaces = new(); + + private Face[] _faces; + private int _faceIndex; + + private Quaternion _orientation = Quaternion.Identity; + + private void OnRendering(object sender, object e) + { + var elapsed = Logger.TickCount - _tickCount; + + _tickCount = Logger.TickCount; + _accumulated += elapsed; + + var face = _faces[_faceIndex]; + var duration = face.Duration; + var rotations = face.Rotations; + var axis = face.Axis; + + var decay = CalculateSpinDecay(_accumulated, duration, face.Force); + + _cube.Orientation = SlerpOrientation(face, _orientation, decay, _faceIndex == _faces.Length - 1, _excludedFaces); + + var facesCount = _faceIndex; + var finalDecay = CalculateSpinDecay(face.Duration, face.Duration, face.Force); + var finalDuration = duration * finalDecay; + + if (_accumulated >= duration - Constants.FastAnimation.TotalMilliseconds * 1 && _faceIndex != _faces.Length - 1) + { + facesCount++; + + if (_faces[facesCount].Orientation.IsIdentity) + { + var finalOrientation = SlerpOrientation(face, _orientation, finalDecay, false, _excludedFaces); + + var childFace = _faces[facesCount]; + var child = childFace.Visual; + + childFace.Orientation = GetRotationToFront(finalOrientation, _excludedFaces); + + var compositor = _cube.Compositor; + + var linear = compositor.CreateLinearEasingFunction(); + + var orientation = compositor.CreateQuaternionKeyFrameAnimation(); + orientation.InsertKeyFrame(0, Quaternion.Identity); + orientation.InsertKeyFrame(1, childFace.Orientation, linear); + orientation.Duration = Constants.FastAnimation; + + var offset = compositor.CreateVector3KeyFrameAnimation(); + offset.InsertKeyFrame(1, Vector3.Zero, linear); + offset.Duration = Constants.FastAnimation; + + var scale = compositor.CreateVector3KeyFrameAnimation(); + scale.InsertKeyFrame(1, Vector3.One, linear); + scale.Duration = Constants.FastAnimation; + + child.StartAnimation("Orientation", orientation); + child.StartAnimation("Translation", offset); + child.StartAnimation("Scale", scale); + } + } + + for (int i = 0; i <= _faceIndex; i++) + { + _faces[i].Visual.Orientation = SlerpOrientation(face, _faces[i].Orientation, decay, _faceIndex == _faces.Length - 1, null); + } + + if (_accumulated >= duration) + { + float overflow = _accumulated - duration; + + for (int i = 0; i <= _faceIndex; i++) + { + var childFace = _faces[i]; + var child = childFace.Visual; + + childFace.Orientation = child.Orientation; + } + + _orientation = _cube.Orientation; + _accumulated = overflow; + + _faceIndex++; + + if (_faceIndex == _faces.Length - 1) + { + var finalFace = _faces[^1]; + finalDecay = CalculateSpinDecay(finalFace.Duration, finalFace.Duration, finalFace.Force); + + var finalSpinOrientation = Quaternion.Concatenate(_orientation, Quaternion.CreateFromAxisAngle(finalFace.Axis, MathF.PI * (finalFace.Rotations * finalDecay))); + var targetSnapOrientation = GetNearestCardinalOrientation(finalSpinOrientation, _excludedFaces, out int faceIndex, out float rotationAngle); + + finalFace.LastHiddenTime = FindLastHiddenMoment(finalFace.Axis, finalFace.Rotations, finalFace.Duration, finalFace.Force, faceIndex, _orientation); + finalFace.LastFaceIndex = faceIndex; + finalFace.LastFaceRotationAngle = rotationAngle; + } + else if (_faceIndex >= _faces.Length) + { + Windows.UI.Xaml.Media.CompositionTarget.Rendering -= OnRendering; + TransitionToCompleted(); + } + } + } + + private async void TransitionToCompleted(int faceIndex, float rotationAngle) + { + if (_crafted == null) + { + TransitionToFailed(faceIndex, rotationAngle); + return; + } + else if (_crafted.Task.IsCompleted) + { + if (_crafted.Task.Result is ReceivedGift receivedGift) + { + TransitionToSucceeded(receivedGift, faceIndex, rotationAngle); + } + else + { + TransitionToFailed(faceIndex, rotationAngle); + } + } + else + { + var response = await _crafted.Task; + if (response is ReceivedGift receivedGift) + { + TransitionToSucceeded(receivedGift, faceIndex, rotationAngle); + } + else + { + TransitionToFailed(faceIndex, rotationAngle); + } + } + } + + private void TransitionToFailed(int faceIndex, float rotationAngle) + { + var target = faceIndex switch + { + 0 => Face1, + 1 => Face2, + 2 => Face4, + 3 => Face3, + 4 => Face5, + 5 => Face6, + _ => null + }; + + if (target != null) + { + var visual = ElementComposition.GetElementVisual(target); + visual.RotationAngle = -rotationAngle; + + var animated = new AnimatedImage + { + Source = new LocalFileSource("ms-appx:///Assets/Animations/GiftCraftingFailed.tgs"), + AutoPlay = true, + Width = 48, + Height = 48, + FrameSize = new Windows.Foundation.Size(48, 48), + LoopCount = 1, + DecodeFrameType = Windows.UI.Xaml.Media.Imaging.DecodePixelType.Logical, + IsCachingEnabled = false, + HorizontalAlignment = HorizontalAlignment.Center, + VerticalAlignment = VerticalAlignment.Center, + }; + + for (int i = 0; i < target.Children.Count; i++) + { + if (i == 1) + { + target.Children.RemoveAt(1); + i++; + + continue; + } + + target.Children[i].Visibility = Visibility.Collapsed; + } + + target.Children.Add(animated); + } + } + + private void TransitionToSucceeded(ReceivedGift receivedGift, int faceIndex, float rotationAngle) + { + var target = faceIndex switch + { + 0 => Face1, + 1 => Face2, + 2 => Face4, + 3 => Face3, + 4 => Face5, + 5 => Face6, + _ => null + }; + + if (target != null && receivedGift.Gift is SentGiftUpgraded success) + { + var visual = ElementComposition.GetElementVisual(target); + visual.RotationAngle = -rotationAngle; + + var pattern = new PatternBackground + { + Margin = new Thickness(-1), + CornerRadius = new CornerRadius(16), + Content = new AnimatedImage + { + AutoPlay = true, + Width = 64, + Height = 64, + FrameSize = new Windows.Foundation.Size(64, 64), + DecodeFrameType = Windows.UI.Xaml.Media.Imaging.DecodePixelType.Logical, + Source = DelayedFileSource.FromSticker(_clientService, success.Gift.Model.Sticker) + } + }; + + pattern.Update(_clientService, success.Gift); + + for (int i = 0; i < target.Children.Count; i++) + { + if (i == 1) + { + target.Children.RemoveAt(1); + i++; + + continue; + } + + target.Children[i].Visibility = Visibility.Collapsed; + } + + target.Children.Add(pattern); + } + } + + private async void TransitionToCompleted() + { + if (_crafted == null) + { + TransitionToFailed(); + return; + } + else if (_crafted.Task.IsCompleted) + { + if (_crafted.Task.Result is ReceivedGift receivedGift) + { + TransitionToSucceeded(receivedGift); + } + else + { + TransitionToFailed(); + } + } + else + { + var response = await _crafted.Task; + if (response is ReceivedGift receivedGift) + { + TransitionToSucceeded(receivedGift); + } + else + { + TransitionToFailed(); + } + } + } + + private void TransitionToFailed() + { + var visual1 = ElementComposition.GetElementVisual(CraftingRoot); + var visual2 = ElementComposition.GetElementVisual(FailedRoot); + var visual3 = ElementComposition.GetElementVisual(FailedBackground); + + var show = visual1.Compositor.CreateScalarKeyFrameAnimation(); + show.InsertKeyFrame(0, 0); + show.InsertKeyFrame(1, 1); + + var hide = visual1.Compositor.CreateScalarKeyFrameAnimation(); + hide.InsertKeyFrame(0, 1); + hide.InsertKeyFrame(1, 0); + + visual1.StartAnimation("Opacity", hide); + visual2.StartAnimation("Opacity", show); + visual3.StartAnimation("Opacity", show); + + TextBlockHelper.SetMarkdown(FailedName, Locale.Declension(Strings.R.GiftCraftFailedText, _items.Count(x => x != null))); + FailedRoot.Visibility = Visibility.Visible; + FailedBackground.Visibility = Visibility.Visible; + FailedList.Children.Clear(); + + foreach (var item in _items) + { + if (item == null) + { + continue; + } + + var cell = new BurnedGiftCell(); + cell.UpdateGift(_clientService, item); + + FailedList.Children.Add(cell); + } + } + + private void TransitionToSucceeded(ReceivedGift receivedGift) + { + Hide(); + _navigationService.ShowPopup(new ReceivedGiftPopup(_clientService, _navigationService, receivedGift, _clientService.MyId, null)); + return; + + var size = 240; + var center = 120; + + var compositor = Window.Current.Compositor; + var shapeVisual = compositor.CreateShapeVisual(); + shapeVisual.Size = new Vector2(size); + + for (int i = 0; i < 6; i++) + { + CanvasGeometry geometry; + using (var builder = new CanvasPathBuilder(null)) + { + // Calculate start and end angles (in radians) + float startAngle = -(float)(Math.PI * 2 / 24); // Starting at 0 degrees + float sweepAngle = (float)(Math.PI * 2 / 12); // 30 degrees in radians (2π/12) + + // Calculate start and end points + Vector2 startPoint = new Vector2( + center + center * (float)Math.Cos(startAngle), + center + center * (float)Math.Sin(startAngle) + ); + + Vector2 endPoint = new Vector2( + center + center * (float)Math.Cos(startAngle + sweepAngle), + center + center * (float)Math.Sin(startAngle + sweepAngle) + ); + + // Begin the path at the start point + builder.BeginFigure(startPoint); + + // Add the arc + builder.AddArc( + endPoint, // End point of the arc + center, // X radius + center, // Y radius + 0, // Rotation angle (0 for circular arc) + CanvasSweepDirection.Clockwise, + CanvasArcSize.Small // Small arc (less than 180 degrees) + ); + + builder.AddLine(new Vector2(center, center)); + + builder.EndFigure(CanvasFigureLoop.Closed); + + geometry = CanvasGeometry.CreatePath(builder); + } + + + var ellipse = compositor.CreatePathGeometry(new CompositionPath(geometry)); + + var fillGradient = compositor.CreateLinearGradientBrush(); + fillGradient.ColorStops.Add(compositor.CreateColorGradientStop(0, Color.FromArgb(0, 255, 0, 0))); + fillGradient.ColorStops.Add(compositor.CreateColorGradientStop(0.15f, Color.FromArgb(0, 255, 0, 0))); + fillGradient.ColorStops.Add(compositor.CreateColorGradientStop(0.32f, Color.FromArgb(0x55, 255, 0, 0))); + fillGradient.ColorStops.Add(compositor.CreateColorGradientStop(0.55f, Color.FromArgb(0x55, 255, 0, 0))); + fillGradient.ColorStops.Add(compositor.CreateColorGradientStop(1, Color.FromArgb(0, 255, 0, 0))); + + var strokeGradient = compositor.CreateLinearGradientBrush(); + strokeGradient.ColorStops.Add(compositor.CreateColorGradientStop(0, Color.FromArgb(0, 255, 0, 0))); + strokeGradient.ColorStops.Add(compositor.CreateColorGradientStop(0.2f, Color.FromArgb(0, 255, 0, 0))); + strokeGradient.ColorStops.Add(compositor.CreateColorGradientStop(0.40f, Color.FromArgb(0x55, 255, 0, 0))); + strokeGradient.ColorStops.Add(compositor.CreateColorGradientStop(0.50f, Color.FromArgb(0x88, 255, 0, 0))); + strokeGradient.ColorStops.Add(compositor.CreateColorGradientStop(0.80f, Color.FromArgb(0, 255, 0, 0))); + strokeGradient.ColorStops.Add(compositor.CreateColorGradientStop(1, Color.FromArgb(0, 255, 0, 0))); + + var ellipseShape = compositor.CreateSpriteShape(ellipse); + ellipseShape.FillBrush = fillGradient; + ellipseShape.StrokeBrush = strokeGradient; + ellipseShape.StrokeThickness = 2; + ellipseShape.CenterPoint = new Vector2(center); + ellipseShape.RotationAngleInDegrees = i * 2 * 30; + + shapeVisual.Shapes.Add(ellipseShape); + } + + var easing = compositor.CreateLinearEasingFunction(); + + var rotationAngle = compositor.CreateScalarKeyFrameAnimation(); + rotationAngle.InsertKeyFrame(0, 0); + rotationAngle.InsertKeyFrame(1, 360, easing); + rotationAngle.IterationBehavior = AnimationIterationBehavior.Forever; + rotationAngle.Duration = TimeSpan.FromSeconds(10); + + shapeVisual.CenterPoint = new Vector3(center); + shapeVisual.StartAnimation("RotationAngleInDegrees", rotationAngle); + + Success.Width = size; + Success.Height = size; + Success.Margin = new Thickness(0, -((size - 96) / 2), 0, -((size - 96) / 2)); + ElementCompositionPreview.SetElementChildVisual(Success, shapeVisual); + } + + public static double RadiansToDegrees(double radians) + { + return radians * (180.0 / Math.PI); + } + + private Quaternion SlerpOrientation(Face face, Quaternion orientation, float decay, bool final, HashSet excludedFaces) + { + var spinRotation = Quaternion.CreateFromAxisAngle(face.Axis, MathF.PI * (decay * face.Rotations)); + var currentOrientation = Quaternion.Concatenate(orientation, spinRotation); + + float snapThreshold = 0.7f; + float normalizedTime = Math.Min(1.0f, _accumulated / face.Duration); + + if (final && _accumulated >= face.LastHiddenTime) + { + if (excludedFaces != null && !face.Snapped) + { + face.Snapped = true; + TransitionToCompleted(face.LastFaceIndex, face.LastFaceRotationAngle); + } + } + + if (normalizedTime > snapThreshold && final) + { + float finalDecay = CalculateSpinDecay(face.Duration, face.Duration, face.Force); + + var finalSpinOrientation = Quaternion.Concatenate(_orientation, Quaternion.CreateFromAxisAngle(face.Axis, MathF.PI * (face.Rotations * finalDecay))); + var targetSnapOrientation = GetNearestCardinalOrientation(finalSpinOrientation, _excludedFaces, out int faceIndex, out float rotationAngle); + + if (excludedFaces != null && !face.Snapped) + { + face.Snapped = true; + TransitionToCompleted(faceIndex, rotationAngle); + } + + float snapBlend = (normalizedTime - snapThreshold) / (1.0f - snapThreshold); + snapBlend = snapBlend * snapBlend * (3.0f - 2.0f * snapBlend); + + if (_excludedFaces != excludedFaces) + { + var straighteningRotation = Quaternion.Concatenate( + Quaternion.Inverse(finalSpinOrientation), + targetSnapOrientation + ); + + var frontFaceOrientation = Quaternion.Concatenate(orientation, Quaternion.CreateFromAxisAngle(face.Axis, MathF.PI * (face.Rotations * finalDecay))); + var frontFaceSnapped = Quaternion.Concatenate( + frontFaceOrientation, + straighteningRotation + ); + + targetSnapOrientation = frontFaceSnapped; + } + + return Quaternion.Slerp(currentOrientation, targetSnapOrientation, snapBlend); + } + + return currentOrientation; + } + + private float? FindLastHiddenMoment(Vector3 axis, float totalRotations, float duration, float force, int targetFaceIndex, Quaternion startingOrientation) + { + Vector3 targetFaceNormal = _faceNormals[targetFaceIndex]; + Vector3 cameraDirection = new Vector3(0, 0, -1); // Camera looks at -Z + + int samples = 100; + float? lastHiddenTime = null; + + for (int i = samples; i >= 0; i--) + { + float t = (i / (float)samples) * duration; + float decay = CalculateSpinDecay(t, duration, force); + + var spinRotation = Quaternion.CreateFromAxisAngle(axis, MathF.PI * (decay * totalRotations)); + var orientation = Quaternion.Concatenate(startingOrientation, spinRotation); + + Vector3 worldNormal = Vector3.Transform(targetFaceNormal, orientation); + + float dot = Vector3.Dot(worldNormal, -cameraDirection); + + if (dot < 0) // Face is hidden + { + lastHiddenTime = t; + break; + } + } + + return lastHiddenTime; + } + + public float CalculateSpinDecay(float position, float duration, float force = 1.0f) + { + if (duration <= 0) return 0f; + + float normalizedTime = Math.Clamp(position / duration, 0, 1); + + float decayRate = 1.0f / MathF.Max(0.1f, force); + float decay = MathF.Exp(-decayRate * normalizedTime * 5.0f); + + return 1 - Math.Clamp(decay, 0, 1); + } + + private Vector3 CalculateAxis(UIElement element) + { + var transform1 = element.TransformToVisual(this); + var point1 = transform1.TransformPoint(new Point()).ToVector2(); + + var transform2 = Cube.TransformToVisual(this); + var point2 = transform2.TransformPoint(new Point()).ToVector2(); + + var x1 = point1.X + ((element.ActualSize.X * FACE_SCALE) / 2); + var y1 = point1.Y + ((element.ActualSize.Y * FACE_SCALE) / 2); + + var x2 = point2.X + ((Cube.ActualSize.X * 1) / 2); + var y2 = point2.Y + ((Cube.ActualSize.Y * 1) / 2); + + float dx = x1 - x2; + float dy = y1 - y2; + + float angleRadians = MathF.Atan2(dy, dx); + Vector2 dir2D = new Vector2( + MathF.Cos(-angleRadians), + MathF.Sin(-angleRadians) + ); + + dir2D = -dir2D; + + return Vector3.Normalize(new Vector3( + dir2D.Y, + dir2D.X, + 0f + )); + } + + private static readonly Vector3[] _faceNormals = new[] + { + new Vector3(0, 1, 0), // [1] Top + new Vector3(0, 0, 1), // [2] Front (center) + new Vector3(1, 0, 0), // [3] Right + new Vector3(-1, 0, 0), // [4] Left + new Vector3(0, 0, -1), // [5] Back + new Vector3(0, -1, 0) // [6] Bottom + }; + + private Quaternion GetRotationToFront(Quaternion orientation, HashSet excludedFaces) + { + int facingFaceIndex = GetNearestFaceIndex(orientation, excludedFaces); + if (facingFaceIndex == -1) + { + return orientation; + } + + if (excludedFaces != null) + { + excludedFaces.Add(facingFaceIndex); + } + + Vector3 fromNormal = _faceNormals[1]; + Vector3 toNormal = _faceNormals[facingFaceIndex]; + + Vector3 rotationAxis = Vector3.Cross(fromNormal, toNormal); + float rotationAngle = MathF.Acos(Vector3.Dot( + Vector3.Normalize(fromNormal), + Vector3.Normalize(toNormal) + )); + + Quaternion faceSwapRotation; + if (rotationAxis.LengthSquared() < 0.0001f) + { + if (Vector3.Dot(fromNormal, toNormal) > 0) + { + faceSwapRotation = Quaternion.Identity; + } + else + { + // 180° flip - choose perpendicular axis + Vector3 perpAxis = Math.Abs(fromNormal.X) < 0.9f + ? new Vector3(1, 0, 0) + : new Vector3(0, 1, 0); + rotationAxis = Vector3.Cross(fromNormal, perpAxis); + faceSwapRotation = Quaternion.CreateFromAxisAngle( + Vector3.Normalize(rotationAxis), + MathF.PI + ); + } + } + else + { + faceSwapRotation = Quaternion.CreateFromAxisAngle( + Vector3.Normalize(rotationAxis), + rotationAngle + ); + } + + Quaternion newOrientation = orientation * faceSwapRotation; + return newOrientation; + } + + private void Craft_Click(object sender, RoutedEventArgs e) + { + if (_spinning) + { + Clear_Click(null, null); + return; + } + + var count = _items.Count(x => x != null); + if (count == 0) + { + VisualUtilities.ShakeView(CraftButton); + return; + } + + TransitionToCrafting(); + + var diff = _items.Length - count; + var spins = _spins[count - 1]; + + _orientation = Quaternion.Identity; + _accumulated = 0; + _tickCount = 0; + _excludedFaces.Clear(); + _excludedFaces.Add(1); + + _faces = new Face[count]; + _faceIndex = 0; + + int j = 0; + + for (int i = 0; i < _items.Length; i++) + { + var child = ElementComposition.GetElementVisual(Gifts.Children[i]); + + if (_items[i] == null) + { + var opacity = child.Compositor.CreateScalarKeyFrameAnimation(); + opacity.InsertKeyFrame(1, 0); + + child.StartAnimation("Opacity", opacity); + continue; + } + + if (j == 0) + { + var offset = child.Compositor.CreateVector3KeyFrameAnimation(); + offset.InsertKeyFrame(1, Vector3.Zero); + offset.Duration = Constants.SoftAnimation; + + var scale = child.Compositor.CreateVector3KeyFrameAnimation(); + scale.InsertKeyFrame(1, Vector3.One); + scale.Duration = Constants.SoftAnimation; + + child.StartAnimation("Translation", offset); + child.StartAnimation("Scale", scale); + } + + var spin = spins[j]; + + _faces[j++] = new Face(child, spin.Duration, spin.Rotations, spin.Force, CalculateAxis(Gifts.Children[i])); + } + + if (_faces.Length == 1) + { + var finalFace = _faces[^1]; + var finalDecay = CalculateSpinDecay(finalFace.Duration, finalFace.Duration, finalFace.Force); // decay at t=duration + + var finalSpinOrientation = Quaternion.Concatenate(Quaternion.Identity, Quaternion.CreateFromAxisAngle(finalFace.Axis, MathF.PI * (finalFace.Rotations * finalDecay))); + var targetSnapOrientation = GetNearestCardinalOrientation(finalSpinOrientation, _excludedFaces, out int faceIndex, out float rotationAngle); + + finalFace.LastHiddenTime = FindLastHiddenMoment(finalFace.Axis, finalFace.Rotations, finalFace.Duration, finalFace.Force, faceIndex, _orientation); + finalFace.LastFaceIndex = faceIndex; + finalFace.LastFaceRotationAngle = rotationAngle; + } + + _tickCount = Logger.TickCount; + + _spinning = true; + Windows.UI.Xaml.Media.CompositionTarget.Rendering += OnRendering; + + var receivedGiftIds = _items.Where(x => x != null).Select(x => x.ReceivedGiftId).ToList(); + var craftGifts = new CraftGift(receivedGiftIds); + + _crafted = new TaskCompletionSource(); + _clientService.Send(craftGifts, SetResult); + } + + private async void SetResult(Object result) + { + if (result is Error error) + { + _crafted.TrySetResult(result); + + this.BeginOnUIThread(() => + { + ToastPopup.ShowError(XamlRoot, error); + Clear_Click(null, null); + }); + } + else if (result is CraftGiftResultSuccess success) + { + _clientService.Send(new GetReceivedGift(success.ReceivedGiftId), SetResult); + } + else + { + _crafted.TrySetResult(result); + } + } + + private void Clear_Click(object sender, RoutedEventArgs e) + { + _spinning = false; + Windows.UI.Xaml.Media.CompositionTarget.Rendering -= OnRendering; + + ElementCompositionPreview.SetElementChildVisual(Success, null); + + _cube.Orientation = Quaternion.Identity; + + var visual1 = ElementComposition.GetElementVisual(PrepareRoot); + var visual3 = ElementComposition.GetElementVisual(Overlays); + visual1.Opacity = 1; + visual3.Opacity = 1; + + CraftingRoot.Visibility = Visibility.Collapsed; + FailedRoot.Visibility = Visibility.Collapsed; + FailedBackground.Visibility = Visibility.Collapsed; + + CreateFace(Face2, Quaternion.Identity); + CreateFace(Face3, CreateRotationY(-90)); + CreateFace(Face4, CreateRotationY(90)); + CreateFace(Face5, CreateRotationY(180)); + CreateFace(Face6, CreateRotationX(90)); + CreateFace(Face1, CreateRotationX(-90)); + + CreateGift(Gift1, new Vector3(-104, -40, 0)); + CreateGift(Gift2, new Vector3(-104, 40, 0)); + CreateGift(Gift3, new Vector3(104, -40, 0)); + CreateGift(Gift4, new Vector3(104, 40, 0)); + + for (int i = 0; i < _items.Length; i++) + { + _items[i] = null; + } + + UpdateSelection(); + } + + private int GetNearestFaceIndex(Quaternion orientation, HashSet excludedFaces) + { + Vector3 cameraDirection = new Vector3(0, 0, -1); // Camera looks at -Z + + var faceCandidates = new List<(int index, float dot)>(); + + for (int i = 0; i < _faceNormals.Length; i++) + { + if (excludedFaces.Contains(i)) + continue; + + Vector3 worldNormal = Vector3.Transform(_faceNormals[i], orientation); + float dot = Vector3.Dot(worldNormal, -cameraDirection); + + faceCandidates.Add((i, dot)); + } + + if (faceCandidates.Count == 0) + return -1; + + faceCandidates.Sort((a, b) => b.dot.CompareTo(a.dot)); + return faceCandidates[0].index; + } + + private Quaternion GetNearestCardinalOrientation(Quaternion orientation, HashSet excludedFaces, out int faceIndex, out float rotationAngle) + { + int bestFaceIndex = GetNearestFaceIndex(orientation, excludedFaces); + if (bestFaceIndex == -1) + { + faceIndex = -1; + rotationAngle = 0; + return orientation; + } + + // 0 => face 1 + // 1 => face 2 + // 2 => face 4 + // 3 => face 3 + // 4 => face 5 + // 5 => face 6 + + Vector3 targetFaceNormal = _faceNormals[bestFaceIndex]; + Vector3 desiredForward = new Vector3(0, 0, 1); // We want this face to point forward (+Z) + + Quaternion faceAlignment; + Vector3 rotationAxis = Vector3.Cross(targetFaceNormal, desiredForward); + + if (rotationAxis.LengthSquared() < 0.0001f) + { + if (Vector3.Dot(targetFaceNormal, desiredForward) > 0) + { + faceAlignment = Quaternion.Identity; + } + else + { + Vector3 perpAxis = Math.Abs(targetFaceNormal.X) < 0.9f + ? new Vector3(1, 0, 0) + : new Vector3(0, 1, 0); + faceAlignment = Quaternion.CreateFromAxisAngle(perpAxis, MathF.PI); + } + } + else + { + float angle = MathF.Acos(Math.Clamp(Vector3.Dot( + Vector3.Normalize(targetFaceNormal), + Vector3.Normalize(desiredForward) + ), -1f, 1f)); + faceAlignment = Quaternion.CreateFromAxisAngle(Vector3.Normalize(rotationAxis), angle); + } + + Quaternion bestOrientation = faceAlignment; + float bestDistance = float.MaxValue; + float bestRotationAngle = 0; + + for (int i = 0; i < 4; i++) + { + float rollAngle = i * MathF.PI / 2; // 0°, 90°, 180°, 270° + Quaternion rollRotation = Quaternion.CreateFromAxisAngle(desiredForward, rollAngle); + Quaternion candidate = Quaternion.Concatenate(faceAlignment, rollRotation); + + float distance = QuaternionAngularDistance(orientation, candidate); + + if (distance < bestDistance) + { + bestDistance = distance; + bestOrientation = candidate; + bestRotationAngle = rollAngle; + } + } + + faceIndex = bestFaceIndex; + rotationAngle = bestRotationAngle; + return bestOrientation; + } + + private float QuaternionAngularDistance(Quaternion a, Quaternion b) + { + float dot = Math.Abs(a.X * b.X + a.Y * b.Y + a.Z * b.Z + a.W * b.W); + dot = Math.Clamp(dot, 0f, 1f); + return 2.0f * MathF.Acos(dot); + } + + #endregion + } +} diff --git a/Telegram/Views/Gifts/Popups/GiftVariantsPopup.xaml b/Telegram/Views/Gifts/Popups/GiftVariantsPopup.xaml new file mode 100644 index 0000000000..bb01d5d616 --- /dev/null +++ b/Telegram/Views/Gifts/Popups/GiftVariantsPopup.xaml @@ -0,0 +1,270 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Telegram/Views/Gifts/Popups/GiftVariantsPopup.xaml.cs b/Telegram/Views/Gifts/Popups/GiftVariantsPopup.xaml.cs new file mode 100644 index 0000000000..ca97a7ec58 --- /dev/null +++ b/Telegram/Views/Gifts/Popups/GiftVariantsPopup.xaml.cs @@ -0,0 +1,245 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using System; +using System.Linq; +using Telegram.Collections; +using Telegram.Common; +using Telegram.Controls; +using Telegram.Controls.Cells; +using Telegram.Navigation.Services; +using Telegram.Services; +using Telegram.Streams; +using Telegram.Td.Api; +using Windows.UI; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Controls.Primitives; +using Windows.UI.Xaml.Media; + +namespace Telegram.Views.Gifts.Popups +{ + public sealed partial class GiftVariantsPopup : ContentPopup + { + private readonly IClientService _clientService; + private readonly INavigationService _navigationService; + + private readonly DispatcherTimer _timer; + private readonly Random _random = new(); + + private readonly GiftUpgradeVariants _variants; + private readonly MvxObservableCollection _itemsSource; + + private UpgradedGiftModel _selectedModel; + private UpgradedGiftBackdrop _selectedBackdrop; + private UpgradedGiftSymbol _selectedSymbol; + + public GiftVariantsPopup(IClientService clientService, INavigationService navigationService, ReceivedGift gift, GiftUpgradeVariants variants) + { + InitializeComponent(); + + _clientService = clientService; + _navigationService = navigationService; + + _variants = variants; + _itemsSource = new MvxObservableCollection(variants.Models.Cast()); + + OnTick(null, null); + + if (gift.Gift is SentGiftUpgraded upgraded) + { + UpgradedTitle.Text = upgraded.Gift.Title; + } + + ScrollingHost.ItemsSource = _itemsSource; + + _timer = new DispatcherTimer + { + Interval = TimeSpan.FromSeconds(3) + }; + + _timer.Tick += OnTick; + _timer.Start(); + + UpgradedSubtitle.Text = Strings.Gift2PreviewRandomTraits; + + TextBlockHelper.SetMarkdown(Info, Locale.Declension(Strings.R.GiftPreviewCountModels, _variants.Models.Count)); + + Navigation.SelectedIndex = 0; + Navigation.SelectionChanged += Navigation_SelectionChanged; + } + + private void OnTick(object sender, object e) + { + _selectedModel = _variants.Models[_random.Next(0, _variants.Models.Count)]; + _selectedBackdrop = _variants.Backdrops[_random.Next(0, _variants.Backdrops.Count)]; + _selectedSymbol = _variants.Symbols[_random.Next(0, _variants.Symbols.Count)]; + + UpdateComposition(); + } + + private void OnContainerContentChanging(ListViewBase sender, ContainerContentChangingEventArgs args) + { + if (args.InRecycleQueue) + { + return; + } + else if (args.ItemContainer.ContentTemplateRoot is GiftVariantCell content) + { + Color color = default; + + if (args.Item is UpgradedGiftModel model) + { + color = Theme.Accent; + content.UpdateModel(_clientService, model); + } + else if (args.Item is UpgradedGiftBackdrop backdrop) + { + color = backdrop.Colors.EdgeColor.ToColor(); + content.UpdateBackdrop(_clientService, _selectedModel, backdrop, _selectedSymbol); + } + else if (args.Item is UpgradedGiftSymbol symbol) + { + color = _selectedBackdrop.Colors.EdgeColor.ToColor(); + content.UpdateSymbol(_clientService, _selectedBackdrop, symbol); + } + + var presenter = VisualTreeHelper.GetChild(args.ItemContainer, 0) as ListViewItemPresenter; + if (presenter != null) + { + var brush = new SolidColorBrush(color); + + presenter.SelectedBorderBrush = brush; + presenter.SelectedPointerOverBorderBrush = brush; + presenter.SelectedPressedBorderBrush = brush; + } + } + + args.Handled = true; + } + + private void Navigation_SelectionChanged(object sender, SelectionChangedEventArgs e) + { + StopRandomization(false); + + if (Navigation.SelectedIndex == 0) + { + //ScrollingHost.ItemsSource = _variants.Models; + _itemsSource.ReplaceWithT(_variants.Models); + ScrollingHost.SelectedItem = _selectedModel; + + TextBlockHelper.SetMarkdown(Info, Locale.Declension(Strings.R.GiftPreviewCountModels, _variants.Models.Count)); + } + else if (Navigation.SelectedIndex == 1) + { + //ScrollingHost.ItemsSource = _variants.Backdrops; + _itemsSource.ReplaceWithT(_variants.Backdrops); + ScrollingHost.SelectedItem = _selectedBackdrop; + + TextBlockHelper.SetMarkdown(Info, Locale.Declension(Strings.R.GiftPreviewCountBackdrops, _variants.Backdrops.Count)); + } + else if (Navigation.SelectedIndex == 2) + { + //ScrollingHost.ItemsSource = _variants.Symbols; + _itemsSource.ReplaceWithT(_variants.Symbols); + ScrollingHost.SelectedItem = _selectedSymbol; + + TextBlockHelper.SetMarkdown(Info, Locale.Declension(Strings.R.GiftPreviewCountSymbols, _variants.Symbols.Count)); + } + } + + private void OnSelectionChanged(object sender, SelectionChangedEventArgs e) + { + if (ScrollingHost.SelectedItem != null) + { + StopRandomization(false); + } + + if (ScrollingHost.SelectedItem is UpgradedGiftModel model) + { + _selectedModel = model; + UpdateComposition(); + } + else if (ScrollingHost.SelectedItem is UpgradedGiftBackdrop backdrop) + { + _selectedBackdrop = backdrop; + UpdateComposition(); + } + else if (ScrollingHost.SelectedItem is UpgradedGiftSymbol symbol) + { + _selectedSymbol = symbol; + UpdateComposition(); + } + } + + private void StopRandomization(bool updateSelection) + { + _timer.Stop(); + Randomize.IsChecked = false; + UpgradedSubtitle.Text = Strings.Gift2PreviewSelectedTraits; + + if (updateSelection) + { + if (Navigation.SelectedIndex == 0) + { + ScrollingHost.SelectedItem = _selectedModel; + } + else if (Navigation.SelectedIndex == 1) + { + ScrollingHost.SelectedItem = _selectedBackdrop; + } + else if (Navigation.SelectedIndex == 2) + { + ScrollingHost.SelectedItem = _selectedSymbol; + } + } + } + + private void UpdateComposition() + { + if (_selectedModel == null || _selectedBackdrop == null || _selectedSymbol == null) + { + return; + } + + UpgradedHeader.Update(_clientService, _selectedBackdrop, _selectedSymbol); + UpgradedAnimatedPhoto.Source = DelayedFileSource.FromSticker(_clientService, _selectedModel.Sticker); + + ModelName.Text = _selectedModel.Name; + ModelRarity.Text = _selectedModel.Rarity.ToText(); + + BackdropName.Text = _selectedBackdrop.Name; + BackdropRarity.Text = _selectedBackdrop.Rarity.ToText(); + + SymbolName.Text = _selectedSymbol.Name; + SymbolRarity.Text = _selectedSymbol.Rarity.ToText(); + + var badgeColor = _selectedBackdrop.Colors.CenterColor.ToColor(); + var badgeBrush = new SolidColorBrush(badgeColor.Lighten()); + + ModelRarity.Background = badgeBrush; + BackdropRarity.Background = badgeBrush; + SymbolRarity.Background = badgeBrush; + } + + private void Randomize_Click(object sender, RoutedEventArgs e) + { + if (_timer.IsEnabled) + { + StopRandomization(true); + } + else + { + _timer.Start(); + OnTick(null, null); + + UpgradedSubtitle.Text = Strings.Gift2PreviewRandomTraits; + ScrollingHost.SelectedItem = null; + } + } + } +} diff --git a/Telegram/Views/Host/RootPage.xaml b/Telegram/Views/Host/RootPage.xaml index 60a9bf566e..887fb49cc4 100644 --- a/Telegram/Views/Host/RootPage.xaml +++ b/Telegram/Views/Host/RootPage.xaml @@ -10,8 +10,7 @@ xmlns:settings="using:Telegram.Views.Settings" mc:Ignorable="d" d:DesignHeight="300" - d:DesignWidth="400" - PreviewKeyDown="OnPreviewKeyDown"> + d:DesignWidth="400"> - - - - + + + + + + + + + + + + + + + + + + + diff --git a/Telegram/Views/Popups/OAuthPopup.xaml.cs b/Telegram/Views/Popups/OAuthPopup.xaml.cs new file mode 100644 index 0000000000..0c8e645c57 --- /dev/null +++ b/Telegram/Views/Popups/OAuthPopup.xaml.cs @@ -0,0 +1,174 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using System; +using Telegram.Common; +using Telegram.Controls; +using Telegram.Navigation; +using Telegram.Navigation.Services; +using Telegram.Services; +using Telegram.Td; +using Telegram.Td.Api; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Controls.Primitives; +using Windows.UI.Xaml.Documents; + +namespace Telegram.Views.Popups +{ + public sealed partial class OAuthPopup : ContentPopup + { + private readonly IClientService _clientService; + private readonly INavigationService _navigationService; + + private readonly OauthLinkInfo _requestConfirmation; + + private bool _requestedPhoneNumberAccess; + + public OAuthPopup(IClientService clientService, INavigationService navigationService, OauthLinkInfo linkInfo) + { + InitializeComponent(); + + _clientService = clientService; + _navigationService = navigationService; + + _requestConfirmation = linkInfo; + + var botUser = clientService.GetUser(linkInfo.BotUserId); + if (botUser == null) + { + // ?? + } + + Photo.Source = ProfilePictureSource.User(clientService, botUser); + + if (LifetimeService.Current.Count > 1 + && clientService.TryGetUser(clientService.Options.MyId, out User user)) + { + AliasRoot.Visibility = Visibility.Visible; + Alias.Source = ProfilePictureSource.User(clientService, user); + } + + var markdown = ClientEx.ParseMarkdown(string.Format(Strings.BotAuthTitle, linkInfo.Domain)); + if (markdown.Entities.Count == 1) + { + var prefix = markdown.Text.Substring(0, markdown.Entities[0].Offset); + var suffix = markdown.Text.Substring(markdown.Entities[0].Offset + markdown.Entities[0].Length); + + var hyperlink = new Hyperlink(); + hyperlink.Inlines.Add(markdown.Text.Substring(markdown.Entities[0].Offset, markdown.Entities[0].Length)); + hyperlink.UnderlineStyle = UnderlineStyle.None; + + Title.Inlines.Add(prefix); + Title.Inlines.Add(hyperlink); + Title.Inlines.Add(suffix); + } + else + { + Title.Text = markdown.Text; + } + + if (string.IsNullOrEmpty(linkInfo.Domain)) + { + TextBlockHelper.SetMarkdown(Subtitle, Strings.BotAuthBotSubtitle); + } + else + { + TextBlockHelper.SetMarkdown(Subtitle, Strings.BotAuthSiteSubtitle); + } + + if (string.IsNullOrEmpty(linkInfo.Platform) || string.IsNullOrEmpty(linkInfo.Browser)) + { + Application.Visibility = Visibility.Collapsed; + } + else + { + Application.Title = linkInfo.Platform; + Application.Subtitle = linkInfo.Browser; + } + + if (string.IsNullOrEmpty(linkInfo.Location) || string.IsNullOrEmpty(linkInfo.IpAddress)) + { + Location.Visibility = Visibility.Collapsed; + } + else + { + Location.Title = linkInfo.Location; + Location.Subtitle = string.Format(Strings.BotAuthBasedOnIP, linkInfo.IpAddress); + } + + if (linkInfo.RequestWriteAccess) + { + AllowMessagesInfo.Text = string.Format(Strings.BotAuthAllowMessagesInfo, botUser.FullName()); + } + else + { + AllowMessagesRoot.Visibility = Visibility.Collapsed; + } + + PrimaryButtonText = Strings.BotAuthLogin; + SecondaryButtonText = Strings.Cancel; + } + + public bool AllowWriteAccess => AllowMessages.IsChecked is true; + + public bool AllowPhoneNumberAccess { get; private set; } + + private async void ContentDialog_PrimaryButtonClick(ContentDialog sender, ContentDialogButtonClickEventArgs args) + { + if (_requestConfirmation.RequestPhoneNumberAccess && !_requestedPhoneNumberAccess) + { + _requestedPhoneNumberAccess = true; + args.Cancel = true; + + var user = _clientService.GetUser(_clientService.Options.MyId); + var phoneNumber = PhoneNumber.Format(user.PhoneNumber); + + var confirm = await _navigationService.ShowPopupAsync(string.Format(Strings.BotAuthPhoneNumberText, _requestConfirmation.Domain, phoneNumber), Strings.BotAuthPhoneNumber, Strings.BotAuthPhoneNumberAccept, Strings.BotAuthPhoneNumberDeny); + if (confirm == ContentDialogResult.Primary) + { + AllowPhoneNumberAccess = true; + } + + Hide(ContentDialogResult.Primary); + } + } + + private void Alias_Click(object sender, RoutedEventArgs e) + { + var flyout = new MenuFlyout(); + + foreach (var session in LifetimeService.Current.Items) + { + if (session.ClientService.TryGetUser(session.ClientService.Options.MyId, out User user)) + { + var photo = new ProfilePicture(); + photo.Size = 20; + photo.Source = ProfilePictureSource.User(session.ClientService, user); + + var item = new ToggleMenuFlyoutItem(); + item.Style = BootStrapper.Current.Resources["ProfilePictureToggleMenuFlyoutItemStyle"] as Style; + item.IsChecked = session == _clientService.Session; + item.Icon = new SymbolIcon(); + item.Text = user.FullName(); + item.Tag = photo; + item.CommandParameter = session.Id; + item.Click += Account_Click; + + flyout.Items.Add(item); + } + } + + flyout.ShowAt(AliasRoot, FlyoutPlacementMode.BottomEdgeAlignedLeft); + } + + private void Account_Click(object sender, RoutedEventArgs e) + { + throw new NotImplementedException(); + } + } +} diff --git a/Telegram/Views/Popups/PollResultsPopup.xaml b/Telegram/Views/Popups/PollResultsPopup.xaml index 973135f0af..71c0db8d60 100644 --- a/Telegram/Views/Popups/PollResultsPopup.xaml +++ b/Telegram/Views/Popups/PollResultsPopup.xaml @@ -41,6 +41,7 @@ - + + + + + + diff --git a/Telegram/Views/Popups/PollResultsPopup.xaml.cs b/Telegram/Views/Popups/PollResultsPopup.xaml.cs index 127a3e8e76..3afe570908 100644 --- a/Telegram/Views/Popups/PollResultsPopup.xaml.cs +++ b/Telegram/Views/Popups/PollResultsPopup.xaml.cs @@ -49,19 +49,19 @@ public PollResultsPopup(IClientService clientService, ISettingsService settingsS private void OnElementPrepared(Microsoft.UI.Xaml.Controls.ItemsRepeater sender, Microsoft.UI.Xaml.Controls.ItemsRepeaterElementPreparedEventArgs args) { var item = sender.ItemsSourceView.GetAt(args.Index); - if (item is MessageSender messageSender) + if (item is PollVoter pollVoter) { var button = args.Element as Button; var content = button.Content as ProfileCell; - content.UpdateMessageSender(_clientService, messageSender); + content.UpdatePollVoter(_clientService, pollVoter); button.Click += User_Click; - if (_clientService.TryGetUser(messageSender, out User user)) + if (_clientService.TryGetUser(pollVoter.VoterId, out User user)) { AutomationProperties.SetName(button, user.FullName()); } - else if (_clientService.TryGetChat(messageSender, out Chat chat)) + else if (_clientService.TryGetChat(pollVoter.VoterId, out Chat chat)) { AutomationProperties.SetName(button, chat.Title); } @@ -121,7 +121,7 @@ public PollResultViewModel(long chatId, long messageId, Poll poll, PollOption op _poll = poll; _option = option; - Items = new MvxObservableCollection(); + Items = new MvxObservableCollection(); LoadMoreCommand = new RelayCommand(LoadMoreExecute); LoadMoreExecute(); @@ -133,7 +133,7 @@ public PollResultViewModel(long chatId, long messageId, Poll poll, PollOption op public PollType Type => _poll.Type; - public MvxObservableCollection Items { get; private set; } + public MvxObservableCollection Items { get; private set; } public RelayCommand LoadMoreCommand { get; } private async void LoadMoreExecute() @@ -142,14 +142,14 @@ private async void LoadMoreExecute() limit = _offset > 0 ? 50 : limit; var response = await ClientService.SendAsync(new GetPollVoters(_chatId, _messageId, _poll.Options.IndexOf(_option), _offset, limit)); - if (response is MessageSenders senders) + if (response is PollVoters senders) { - foreach (var sender in senders.Senders) + foreach (var sender in senders.Voters) { Items.Add(sender); } - _offset += senders.Senders.Count; + _offset += senders.Voters.Count; _remaining = senders.TotalCount - _offset; RaisePropertyChanged(nameof(LoadMoreLabel)); diff --git a/Telegram/Views/Popups/ProxyPopup.xaml.cs b/Telegram/Views/Popups/ProxyPopup.xaml.cs index 31b8b08511..f00b8b682b 100644 --- a/Telegram/Views/Popups/ProxyPopup.xaml.cs +++ b/Telegram/Views/Popups/ProxyPopup.xaml.cs @@ -60,9 +60,11 @@ public ProxyPopup(IClientService clientService, ProxyViewModel proxy) } } - public string Server => FieldServer.Text ?? string.Empty; + public Proxy Proxy => new Proxy(Server, Port, Type); - public int Port + private string Server => FieldServer.Text ?? string.Empty; + + private int Port { get { @@ -71,7 +73,7 @@ public int Port } } - public ProxyType Type + private ProxyType Type { get { diff --git a/Telegram/Views/Popups/ReportChatPopup.xaml.cs b/Telegram/Views/Popups/ReportChatPopup.xaml.cs index 5a6a56c701..a62237aeb6 100644 --- a/Telegram/Views/Popups/ReportChatPopup.xaml.cs +++ b/Telegram/Views/Popups/ReportChatPopup.xaml.cs @@ -9,7 +9,6 @@ using System.Collections.Generic; using System.Numerics; using System.Threading.Tasks; -using Telegram.Common; using Telegram.Controls; using Telegram.Navigation; using Telegram.Navigation.Services; diff --git a/Telegram/Views/Popups/SearchChatResultsPopup.xaml b/Telegram/Views/Popups/SearchChatResultsPopup.xaml deleted file mode 100644 index dee52f0fe0..0000000000 --- a/Telegram/Views/Popups/SearchChatResultsPopup.xaml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - - - - - - - - - - - diff --git a/Telegram/Views/Popups/SearchChatResultsPopup.xaml.cs b/Telegram/Views/Popups/SearchChatResultsPopup.xaml.cs deleted file mode 100644 index d6687421b5..0000000000 --- a/Telegram/Views/Popups/SearchChatResultsPopup.xaml.cs +++ /dev/null @@ -1,83 +0,0 @@ -// -// Copyright (c) Fela Ameghino 2015-2026 -// -// Distributed under the GNU General Public License v3.0. (See accompanying -// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) -// - -using Telegram.Collections; -using Telegram.Common; -using Telegram.Controls; -using Telegram.Controls.Cells; -using Telegram.Td.Api; -using Windows.UI.Xaml.Controls; - -namespace Telegram.Views.Popups -{ - public sealed partial class SearchChatResultsPopup : ContentPopup - { - private readonly SearchChatMessagesCollection _collection; - - public SearchChatResultsPopup(SearchChatMessagesCollection results) - { - InitializeComponent(); - - _collection = results; - - if (results.TotalCount > 0) - { - Title = Locale.Declension(Strings.R.messages, results.TotalCount); - } - else - { - Title = Strings.MessagesOverview; - } - - ScrollingHost.ItemsSource = results; - } - - public Message SelectedItem { get; private set; } - - #region Recycle - - private void OnChoosingItemContainer(ListViewBase sender, ChoosingItemContainerEventArgs args) - { - if (args.ItemContainer == null) - { - args.ItemContainer = new TextListViewItem(); - args.ItemContainer.Style = sender.ItemContainerStyle; - args.ItemContainer.ContentTemplate = sender.ItemTemplate; - } - - args.IsContainerPrepared = true; - } - - private void OnContainerContentChanging(ListViewBase sender, ContainerContentChangingEventArgs args) - { - if (args.InRecycleQueue) - { - return; - } - if (args.Item is Message message) - { - var content = args.ItemContainer.ContentTemplateRoot as ChatCell; - if (content == null) - { - return; - } - - content.UpdateMessage(_collection.ClientService, message, true); - } - - args.Handled = true; - } - - #endregion - - private void OnItemClick(object sender, ItemClickEventArgs e) - { - SelectedItem = e.ClickedItem as Message; - Hide(ContentDialogResult.Primary); - } - } -} diff --git a/Telegram/Views/Popups/StakeDicePopup.xaml b/Telegram/Views/Popups/StakeDicePopup.xaml index d6035f487c..f291dc16cf 100644 --- a/Telegram/Views/Popups/StakeDicePopup.xaml +++ b/Telegram/Views/Popups/StakeDicePopup.xaml @@ -534,11 +534,56 @@ - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Telegram/Views/Popups/TextEditorPopup.xaml.cs b/Telegram/Views/Popups/TextEditorPopup.xaml.cs new file mode 100644 index 0000000000..010ee19983 --- /dev/null +++ b/Telegram/Views/Popups/TextEditorPopup.xaml.cs @@ -0,0 +1,217 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using System; +using System.Collections.Generic; +using Telegram.Common; +using Telegram.Controls; +using Telegram.Navigation.Services; +using Telegram.Services; +using Telegram.Streams; +using Telegram.Td.Api; +using Windows.Foundation; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Controls.Primitives; + +namespace Telegram.Views.Popups +{ + public sealed partial class TextEditorPopup : ContentPopup + { + private readonly IClientService _clientService; + private readonly INavigationService _navigationService; + private readonly FormattedText _text; + + public TextEditorPopup(IClientService clientService, INavigationService navigationService, FormattedText text) + { + InitializeComponent(); + + _clientService = clientService; + _navigationService = navigationService; + _text = text; + + //_variants = variants; + //_itemsSource = new MvxObservableCollection(variants.Models.Cast()); + + //OnTick(null, null); + + //if (gift.Gift is SentGiftUpgraded upgraded) + //{ + // UpgradedTitle.Text = upgraded.Gift.Title; + //} + + //ScrollingHost.ItemsSource = _itemsSource; + + //_timer = new DispatcherTimer + //{ + // Interval = TimeSpan.FromSeconds(3) + //}; + + //_timer.Tick += OnTick; + //_timer.Start(); + + //UpgradedSubtitle.Text = Strings.Gift2PreviewRandomTraits; + + //TextBlockHelper.SetMarkdown(Info, Locale.Declension(Strings.R.GiftPreviewCountModels, _variants.Models.Count)); + + TabStyleItems.ItemsSource = clientService.TextCompositionStyles; + TabStyleOutput.SetText(clientService, text); + + Navigation.SelectedIndex = 1; + Navigation.SelectionChanged += Navigation_SelectionChanged; + } + + private void Navigation_SelectionChanged(object sender, SelectionChangedEventArgs e) + { + TabTranslate.Visibility = Navigation.SelectedIndex == 0 + ? Visibility.Visible + : Visibility.Collapsed; + TabStyle.Visibility = Navigation.SelectedIndex == 1 + ? Visibility.Visible + : Visibility.Collapsed; + TabFix.Visibility = Navigation.SelectedIndex == 2 + ? Visibility.Visible + : Visibility.Collapsed; + + if (Navigation.SelectedIndex == 2 && _fix == null) + { + InitializeFix(); + } + } + + private async void InitializeFix() + { + _fix = new MessageTranslateResultPending(); + + TabFixOriginal.SetText(_clientService, _text); + + var response = await _clientService.SendAsync(new FixTextWithAi(_text)); + if (response is FixedText text) + { + TabFixResult.Document.SetText(Windows.UI.Text.TextSetOptions.None, text.DiffText.Text); + + foreach (var diff in text.DiffText.Entities) + { + var range = TabFixResult.Document.GetRange(diff.Offset, diff.Offset + diff.Length); + range.CharacterFormat.Underline = Windows.UI.Text.UnderlineType.Wave; + } + + TabFixResult.IsReadOnly = true; + } + } + + private void TabStyleItems_ContainerContentChanging(ListViewBase sender, ContainerContentChangingEventArgs args) + { + if (args.InRecycleQueue) + { + return; + } + else if (args.ItemContainer.ContentTemplateRoot is Grid content && args.Item is TextCompositionStyle style) + { + var animated = content.Children[0] as AnimatedImage; + var text = content.Children[1] as TextBlock; + + animated.Source = new CustomEmojiFileSource(_clientService, style.CustomEmojiId); + text.Text = style.Title; + } + + args.Handled = true; + } + + private void TabStyleItems_PrepareContainerForItem(SelectorItem sender, object args) + { + if (sender.ContentTemplateRoot is Grid content && args is TextCompositionStyle style) + { + var animated = content.Children[0] as AnimatedImage; + var text = content.Children[1] as TextBlock; + + animated.Source = new CustomEmojiFileSource(_clientService, style.CustomEmojiId); + text.Text = style.Title; + } + } + + private Dictionary _styles = new(); + private MessageTranslateResult _fix; + + private void TabStyleItems_SelectionChanged(object sender, SelectionChangedEventArgs e) + { + if (TabStyleItems.SelectedItem is not TextCompositionStyle style) + { + return; + } + + var addEmojis = TabStyleEmoji.IsChecked is true; + var styleName = style.Name + "_" + addEmojis; + + if (_styles.TryGetValue(styleName, out MessageTranslateResult result)) + { + if (result is MessageTranslateResultText text) + { + TabStyleOutput.ShowHideSkeleton(false); + TabStyleOutput.SetText(_clientService, text.Text); + } + } + else + { + TabStyleOutput.ShowHideSkeleton(true); + TabStyleOutput.InvalidateArrange(); + + _styles[styleName] = new MessageTranslateResultPending(); + _clientService.Send(new ComposeTextWithAi(_text, string.Empty, style.Name, addEmojis), result => + { + this.BeginOnUIThread(() => + { + if (result is FormattedText text) + { + var styled = TextStyleRun.GetText(text); + + _styles[styleName] = new MessageTranslateResultText(style.Name, styled); + TabStyleOutput.ShowHideSkeleton(false); + TabStyleOutput.SetText(_clientService, styled); + } + else + { + _styles[styleName] = new MessageTranslateResultError(); + } + }); + }); + } + } + } + + public class TabStylePanel : Panel + { + protected override Size MeasureOverride(Size availableSize) + { + var maxWidth = 0d; + var maxHeight = 0d; + + foreach (var child in Children) + { + child.Measure(new Size(double.PositiveInfinity, double.PositiveInfinity)); + maxWidth = Math.Max(maxWidth, child.DesiredSize.Width); + maxHeight = Math.Max(maxHeight, child.DesiredSize.Height); + } + + return new Size(Math.Max(availableSize.Width, maxWidth * Children.Count), maxHeight); + } + + protected override Size ArrangeOverride(Size finalSize) + { + var width = finalSize.Width / Children.Count; + var x = 0d; + + foreach (var child in Children) + { + child.Arrange(new Rect(x, 0, width, finalSize.Height)); + x += width; + } + + return finalSize; + } + } +} diff --git a/Telegram/Views/Popups/ThemePreviewPopup.xaml.cs b/Telegram/Views/Popups/ThemePreviewPopup.xaml.cs index 481b1b85e4..0509ab4670 100644 --- a/Telegram/Views/Popups/ThemePreviewPopup.xaml.cs +++ b/Telegram/Views/Popups/ThemePreviewPopup.xaml.cs @@ -51,7 +51,7 @@ private async void Initialize(StorageFile file) Title.Text = Strings.ThemePreviewTitle; Subtitle.Text = string.Format("{0} {1} {2}", Strings.LastSeen, Strings.TodayAt, Formatter.Time(DateTime.Now.AddHours(-1))); - Message1.Mockup(new MessagePhoto(new Photo(false, null, new[] { new PhotoSize("i", TdExtensions.GetLocalFile("Assets\\Mockup\\theme_preview_image.jpg"), 500, 302, Array.Empty()) }), new FormattedText(), false, false, false), Strings.ThemePreviewLine4, false, DateTime.Now.AddSeconds(-25), true, true); + Message1.Mockup(new MessagePhoto(new Photo(false, null, new[] { new PhotoSize("i", TdExtensions.GetLocalFile("Assets\\Mockup\\theme_preview_image.jpg"), 500, 302, Array.Empty()) }), null, new FormattedText(), false, false, false), Strings.ThemePreviewLine4, false, DateTime.Now.AddSeconds(-25), true, true); Message2.Mockup(Strings.ThemePreviewLine1, true, DateTime.Now, true, false); //Message3.Mockup(Strings.FontSizePreviewLine1, Strings.FontSizePreviewName, Strings.FontSizePreviewReply, false, DateTime.Now.AddSeconds(-25)); Message3.Mockup(new MessageVoiceNote(new VoiceNote(3, new byte[] diff --git a/Telegram/Views/Popups/TranslatePopup.xaml.cs b/Telegram/Views/Popups/TranslatePopup.xaml.cs index d65327e2c4..f1cd7cc809 100644 --- a/Telegram/Views/Popups/TranslatePopup.xaml.cs +++ b/Telegram/Views/Popups/TranslatePopup.xaml.cs @@ -6,7 +6,6 @@ // using System.Threading.Tasks; -using Telegram.Common; using Telegram.Controls; using Telegram.Services; using Telegram.Td.Api; @@ -19,6 +18,7 @@ public sealed partial class TranslatePopup : ContentPopup { private readonly ITranslateService _translateService; private readonly string _toLanguage; + private readonly string _tone; private readonly long _chatId; private readonly long _messageId; @@ -91,11 +91,11 @@ private async void OnOpened(ContentDialog sender, ContentDialogOpenedEventArgs a Task task; if (_chatId != 0 && _messageId != 0) { - task = _translateService.TranslateAsync(_chatId, _messageId, _toLanguage); + task = _translateService.TranslateAsync(_chatId, _messageId, _toLanguage, _tone); } else { - task = _translateService.TranslateAsync(block.PlaceholderText, _toLanguage); + task = _translateService.TranslateAsync(block.PlaceholderText, _toLanguage, _tone); } var response = await task; diff --git a/Telegram/Views/Profile/ProfileMembersTabPage.xaml b/Telegram/Views/Profile/ProfileMembersTabPage.xaml index c5b5fed0f7..c2e50cc88c 100644 --- a/Telegram/Views/Profile/ProfileMembersTabPage.xaml +++ b/Telegram/Views/Profile/ProfileMembersTabPage.xaml @@ -70,11 +70,16 @@ - + + + + + diff --git a/Telegram/Views/Profile/ProfileMembersTabPage.xaml.cs b/Telegram/Views/Profile/ProfileMembersTabPage.xaml.cs index e086e79cca..3c4e7c4b33 100644 --- a/Telegram/Views/Profile/ProfileMembersTabPage.xaml.cs +++ b/Telegram/Views/Profile/ProfileMembersTabPage.xaml.cs @@ -33,12 +33,12 @@ protected override void OnNavigatedTo(NavigationEventArgs e) if (ViewModel.ClientService.TryGetSupergroup(ViewModel.Chat, out Supergroup supergroup)) { AddNew.Content = supergroup.IsChannel ? Strings.AddSubscriber : Strings.AddMember; - AddNewPanel.Visibility = supergroup.CanInviteUsers() ? Visibility.Visible : Visibility.Collapsed; + AddNewPanel.Visibility = supergroup.CanInviteUsers(ViewModel.Chat) ? Visibility.Visible : Visibility.Collapsed; } else if (ViewModel.ClientService.TryGetBasicGroup(ViewModel.Chat, out BasicGroup basicGroup)) { AddNew.Content = Strings.AddMember; - AddNewPanel.Visibility = basicGroup.CanInviteUsers() ? Visibility.Visible : Visibility.Collapsed; + AddNewPanel.Visibility = basicGroup.CanInviteUsers(ViewModel.Chat) ? Visibility.Visible : Visibility.Collapsed; } } @@ -79,9 +79,14 @@ private void Member_ContextRequested(UIElement sender, ContextRequestedEventArgs return; } + if (ViewModel.ClientService.CanEditTag(chat, member)) + { + flyout.CreateFlyoutItem(ViewModel.MembersTab.EditTag, member, member.Status is ChatMemberStatusAdministrator or ChatMemberStatusCreator ? Strings.EditAdminTag : Strings.EditMemberTag, Icons.PersonTag); + } + if (chat.Type is ChatTypeSupergroup) { - flyout.CreateFlyoutItem(MemberPromote_Loaded, ViewModel.MembersTab.PromoteMember, chat, status, member, member.Status is ChatMemberStatusAdministrator ? Strings.EditAdminRights : Strings.SetAsAdmin, Icons.Star); + flyout.CreateFlyoutItem(MemberPromote_Loaded, ViewModel.MembersTab.PromoteMember, chat, status, member, member.Status is ChatMemberStatusAdministrator ? Strings.EditAdminRights : Strings.SetAsAdmin, Icons.ShieldStar); flyout.CreateFlyoutItem(MemberRestrict_Loaded, ViewModel.MembersTab.RestrictMember, chat, status, member, member.Status is ChatMemberStatusRestricted ? Strings.ChangePermissions : Strings.KickFromSupergroup, Icons.LockClosed); } diff --git a/Telegram/Views/Profile/ProfileSavedChatsTabPage.xaml.cs b/Telegram/Views/Profile/ProfileSavedChatsTabPage.xaml.cs index 75b27f0912..3007120c4c 100644 --- a/Telegram/Views/Profile/ProfileSavedChatsTabPage.xaml.cs +++ b/Telegram/Views/Profile/ProfileSavedChatsTabPage.xaml.cs @@ -104,12 +104,9 @@ public void UpdateSavedMessagesTopicLastMessage(SavedMessagesTopic topic) } var container = ScrollingHost.ContainerFromItem(topic) as SelectorItem; - if (container?.ContentTemplateRoot is Grid content) + if (container?.ContentTemplateRoot is ChatCell cell) { - if (content.Children[0] is ChatCell cell) - { - cell.UpdateSavedMessagesTopic(clientService, topic); - } + cell.UpdateSavedMessagesTopic(clientService, topic); } }); } diff --git a/Telegram/Views/Profile/ProfileTopicsTabPage.xaml b/Telegram/Views/Profile/ProfileTopicsTabPage.xaml new file mode 100644 index 0000000000..378289529c --- /dev/null +++ b/Telegram/Views/Profile/ProfileTopicsTabPage.xaml @@ -0,0 +1,51 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Telegram/Views/Profile/ProfileTopicsTabPage.xaml.cs b/Telegram/Views/Profile/ProfileTopicsTabPage.xaml.cs new file mode 100644 index 0000000000..fde261303a --- /dev/null +++ b/Telegram/Views/Profile/ProfileTopicsTabPage.xaml.cs @@ -0,0 +1,183 @@ +// +// Copyright (c) Fela Ameghino 2015-2026 +// +// Distributed under the GNU General Public License v3.0. (See accompanying +// file LICENSE or copy at https://www.gnu.org/licenses/gpl-3.0.txt) +// + +using System; +using System.Collections.Generic; +using Telegram.Common; +using Telegram.Controls; +using Telegram.Controls.Cells; +using Telegram.Controls.Media; +using Telegram.Td.Api; +using Telegram.ViewModels; +using Telegram.ViewModels.Delegates; +using Windows.UI.Xaml; +using Windows.UI.Xaml.Controls; +using Windows.UI.Xaml.Controls.Primitives; +using Windows.UI.Xaml.Input; + +namespace Telegram.Views.Profile +{ + public sealed partial class ProfileTopicsTabPage : ProfileTabPage, ITopicListDelegate + { + public new ProfileViewModel ViewModel => DataContext as ProfileViewModel; + + public ProfileTopicsTabPage() + { + InitializeComponent(); + + Connected += OnConnected; + Disconnected += OnDisconnected; + } + + private void OnConnected(object sender, RoutedEventArgs e) + { + ViewModel?.TopicsTab.Delegate = this; + } + + private void OnDisconnected(object sender, RoutedEventArgs e) + { + ViewModel?.TopicsTab.Delegate = null; + } + + private void ListView_ItemClick(object sender, ItemClickEventArgs e) + { + if (e.ClickedItem is ForumTopic topic) + { + ViewModel.OpenForumTopic(topic); + } + } + + private readonly Dictionary _itemToSelector = new(); + + protected override void OnChoosingItemContainer(ListViewBase sender, ChoosingItemContainerEventArgs args) + { + if (args.ItemContainer == null) + { + args.ItemContainer = new TableListViewItem(); + args.ItemContainer.Style = ScrollingHost.ItemContainerStyle; + args.ItemContainer.ContentTemplate = ScrollingHost.ItemTemplate; + args.ItemContainer.ContextRequested += OnContextRequested; + } + + args.IsContainerPrepared = true; + } + + private void OnContainerContentChanging(ListViewBase sender, ContainerContentChangingEventArgs args) + { + if (args.Item is not ForumTopic forumTopic) + { + return; + } + + if (args.InRecycleQueue) + { + _itemToSelector.Remove(forumTopic.Info.ForumTopicId); + return; + } + else if (args.ItemContainer.ContentTemplateRoot is ForumTopicCell content) + { + _itemToSelector[forumTopic.Info.ForumTopicId] = args.ItemContainer; + content.UpdateForumTopic(ViewModel.TopicsTab, forumTopic); + } + } + + private void OnContextRequested(UIElement sender, ContextRequestedEventArgs args) + { + var topic = ScrollingHost.ItemFromContainer(sender) as SavedMessagesTopic; + var flyout = new MenuFlyout(); + + if (topic.IsPinned) + { + flyout.CreateFlyoutItem(ViewModel.SavedChatsTab.UnpinTopic, topic, Strings.UnpinFromTop, Icons.PinOff); + } + else + { + flyout.CreateFlyoutItem(ViewModel.SavedChatsTab.PinTopic, topic, Strings.PinToTop, Icons.Pin); + } + + flyout.CreateFlyoutItem(ViewModel.SavedChatsTab.DeleteTopic, topic, Strings.Delete, Icons.Delete, destructive: true); + + flyout.ShowAt(sender, args); + } + + public void SetSelectedItem(object topic) + { + // Do nothing + } + + public void SetSelectedItems(IList topics) + { + // Do nothing + } + + public void UpdateForumTopicLastMessage(ForumTopic topic) + { + HandleForumTopic(topic, (chatView, chat) => + { + chatView.UpdateForumTopicReadInbox(chat); + chatView.UpdateForumTopicLastMessage(chat); + }); + } + + public void HandleForumTopic(int forumTopicId, Action action) + { + if (TryGetTopicAndCell(forumTopicId, out ForumTopic chat, out IForumTopicDelegate cell)) + { + action(cell, chat); + } + } + + public void HandleForumTopic(ForumTopic topic, Action action) + { + if (TryGetCell(topic, out IForumTopicDelegate cell)) + { + action(cell, topic); + } + } + + public void UpdateDirectMessagesChatTopicLastMessage(DirectMessagesChatTopic topic) + { + // Do nothing + } + + public void HandleDirectMessagesChatTopic(long topicId, Action action) + { + // Do nothing + } + + public void HandleDirectMessagesChatTopic(DirectMessagesChatTopic topic, Action action) + { + // Do nothing + } + + private bool TryGetTopicAndCell(int topicId, out ForumTopic topic, out IForumTopicDelegate cell) + { + if (_itemToSelector.TryGetValue(topicId, out SelectorItem container)) + { + topic = ScrollingHost.ItemFromContainer(container) as ForumTopic; + cell = container.ContentTemplateRoot as IForumTopicDelegate; + return topic != null && cell != null; + } + + topic = null; + cell = null; + return false; + } + + private bool TryGetCell(ForumTopic topic, out IForumTopicDelegate cell) + { + if (_itemToSelector.TryGetValue(topic.Info.ForumTopicId, out SelectorItem container)) + { + cell = container.ContentTemplateRoot as IForumTopicDelegate; + return cell != null; + } + + cell = null; + return false; + } + } +} diff --git a/Telegram/Views/ProfilePage.xaml b/Telegram/Views/ProfilePage.xaml index 86eb1e3dab..50f0a7bcf3 100644 --- a/Telegram/Views/ProfilePage.xaml +++ b/Telegram/Views/ProfilePage.xaml @@ -59,7 +59,7 @@ ItemsSource="{x:Bind ViewModel.Items}" SelectedItem="{x:Bind ViewModel.SelectedItem, Mode=TwoWay}" Height="48" - Padding="8,4"> + Padding="8,0,8,4"> (), null, null, null, null, null, 0, 0, 0, 0, 0, 0, string.Empty, 0, 0, null, string.Empty, content, null); + var message = new Message(0, new MessageSenderUser(user.Id), 0, null, null, false, false, false, false, false, false, false, false, false, DateTime.Now.ToTimestamp(), 0, forwardInfo, null, null, Array.Empty(), null, null, null, null, null, 0, 0, 0, 0, 0, string.Empty, 0, string.Empty, 0, 0, null, string.Empty, content, null); var delegato = new ChatMessageDelegate(ViewModel.ClientService, ViewModel.Settings, chat); var viewModel = new MessageViewModel(ViewModel.ClientService, delegato, chat, null, null, message, true); diff --git a/Telegram/Views/Settings/SettingsAppearancePage.xaml b/Telegram/Views/Settings/SettingsAppearancePage.xaml index 5878593119..cd7584c3b0 100644 --- a/Telegram/Views/Settings/SettingsAppearancePage.xaml +++ b/Telegram/Views/Settings/SettingsAppearancePage.xaml @@ -238,17 +238,15 @@ - + - + (), null, null, null, null, null, 0, 0, 0, 0, 0, 0, string.Empty, 0, 0, null, string.Empty, null, null); + var message = new Message(0, senderId, 0, null, null, false, false, false, false, false, false, false, false, false, 0, 0, null, null, null, Array.Empty(), null, null, null, null, null, 0, 0, 0, 0, 0, string.Empty, 0, string.Empty, 0, 0, null, string.Empty, null, null); var settings = clientService.Session.Resolve(); diff --git a/Telegram/Views/Settings/SettingsAutoDeletePage.xaml b/Telegram/Views/Settings/SettingsAutoDeletePage.xaml index 80ff7aa898..4d257e2bcd 100644 --- a/Telegram/Views/Settings/SettingsAutoDeletePage.xaml +++ b/Telegram/Views/Settings/SettingsAutoDeletePage.xaml @@ -41,12 +41,11 @@ - + diff --git a/Telegram/Views/Settings/SettingsDataAndStoragePage.xaml b/Telegram/Views/Settings/SettingsDataAndStoragePage.xaml index 02abf7ccad..8bd83e3bc4 100644 --- a/Telegram/Views/Settings/SettingsDataAndStoragePage.xaml +++ b/Telegram/Views/Settings/SettingsDataAndStoragePage.xaml @@ -74,21 +74,20 @@ x:Load="{x:Bind ViewModel.HasDownloadFolder}" Header="{CustomResource DownloadPath}" Footer="{CustomResource TemporaryFolderHint}"> - + - +