diff --git a/Import/Vlpp.h b/Import/Vlpp.h index 5ab6c952..49ac0fba 100644 --- a/Import/Vlpp.h +++ b/Import/Vlpp.h @@ -9379,7 +9379,7 @@ Interface Implementation Proxy class IValueSubscription : public virtual IDescriptable, public Description { public: - virtual Ptr Subscribe(const Func& callback) = 0; + virtual Ptr Subscribe(const Func& callback) = 0; virtual bool Update() = 0; virtual bool Close() = 0; }; @@ -12010,7 +12010,8 @@ TypeInfoRetriver Helper Functions (BoxValue, UnboxValue) template Value BoxValue(const T& object, ITypeDescriptor* typeDescriptor=0) { - return ValueAccessor::Decorator>::BoxValue(object, typeDescriptor); + using Type = RemoveCVR::Type; + return ValueAccessor::Decorator>::BoxValue(object, typeDescriptor); } /// Unbox an reflectable object. Its type cannot be generic. @@ -12022,7 +12023,8 @@ TypeInfoRetriver Helper Functions (BoxValue, UnboxValue) template T UnboxValue(const Value& value, ITypeDescriptor* typeDescriptor=0, const WString& valueName=L"value") { - return ValueAccessor::Decorator>::UnboxValue(value, typeDescriptor, valueName); + using Type = RemoveCVR::Type; + return ValueAccessor::Decorator>::UnboxValue(value, typeDescriptor, valueName); } /*********************************************************************** @@ -18491,7 +18493,7 @@ Interface Implementation Proxy (Implement) END_INTERFACE_PROXY(IValueListener) BEGIN_INTERFACE_PROXY_NOPARENT_SHAREDPTR(IValueSubscription) - Ptr Subscribe(const Func& callback)override + Ptr Subscribe(const Func& callback)override { INVOKEGET_INTERFACE_PROXY(Subscribe, callback); } diff --git a/Import/VlppWorkflowCompiler.cpp b/Import/VlppWorkflowCompiler.cpp index d18c7ec5..47e28f42 100644 --- a/Import/VlppWorkflowCompiler.cpp +++ b/Import/VlppWorkflowCompiler.cpp @@ -14776,6 +14776,7 @@ WfCppConfig auto td = typeInfo->GetTypeDescriptor(); bool constRef = td == description::GetTypeDescriptor() || + td == description::GetTypeDescriptor() || ( typeInfo->GetDecorator() == ITypeInfo::SharedPtr && typeInfo->GetElementType()->GetDecorator() == ITypeInfo::Generic && ( @@ -17250,10 +17251,14 @@ WfGenerateExpressionVisitor } else if (node->op == WfBinaryOperator::FailedThen) { + auto firstResult = config->manager->expressionResolvings[node->first.Obj()]; + auto secondResult = config->manager->expressionResolvings[node->second.Obj()]; + auto mergedType = GetMergedType(firstResult.type, secondResult.type); + writer.WriteString(L"[&](){ try{ return "); - Call(node->first); + Call(node->first, mergedType.Obj()); writer.WriteString(L"; } catch(...){ return "); - Call(node->second); + Call(node->second, mergedType.Obj()); writer.WriteString(L"; } }()"); } else diff --git a/Tutorial/GacUI_Controls/AddressBook/UI/Resource.xml b/Tutorial/GacUI_Controls/AddressBook/UI/Resource.xml index d23e91ec..84e1b1ba 100644 --- a/Tutorial/GacUI_Controls/AddressBook/UI/Resource.xml +++ b/Tutorial/GacUI_Controls/AddressBook/UI/Resource.xml @@ -2,19 +2,15 @@ - Source - GacUIReflection.h + Source + ..\..\UIRes\AddressBook.bin + GacUI.h Demo - - - - ..\..\UIRes - AddressBook.bin - diff --git a/Tutorial/GacUI_Controls/ColorPicker/ColorPicker.vcxproj b/Tutorial/GacUI_Controls/ColorPicker/ColorPicker.vcxproj index 9b70971e..fc755dac 100644 --- a/Tutorial/GacUI_Controls/ColorPicker/ColorPicker.vcxproj +++ b/Tutorial/GacUI_Controls/ColorPicker/ColorPicker.vcxproj @@ -53,7 +53,7 @@ Level3 Disabled - WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions) + WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION true @@ -69,7 +69,7 @@ MaxSpeed true true - WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions) + WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION true @@ -79,11 +79,6 @@ true - - - {8018d622-66ba-4e65-9d03-bdac37ea9a54} - - @@ -95,6 +90,11 @@ + + + {96c559ca-9718-4bec-a053-28a0ab6a8ca2} + + diff --git a/Tutorial/GacUI_Controls/ColorPicker/UI/Resource.xml b/Tutorial/GacUI_Controls/ColorPicker/UI/Resource.xml index d7ced6d0..cfcdfb1d 100644 --- a/Tutorial/GacUI_Controls/ColorPicker/UI/Resource.xml +++ b/Tutorial/GacUI_Controls/ColorPicker/UI/Resource.xml @@ -2,19 +2,15 @@ - Source - GacUIReflection.h + Source + ..\..\UIRes\ColorPicker.bin + GacUI.h Demo - - - - ..\..\UIRes - ColorPicker.bin - @@ -82,7 +78,29 @@ - + + + diff --git a/Tutorial/GacUI_Controls/ColorPicker/UI/Source/Demo.h b/Tutorial/GacUI_Controls/ColorPicker/UI/Source/Demo.h index febeba0f..b902c7a9 100644 --- a/Tutorial/GacUI_Controls/ColorPicker/UI/Source/Demo.h +++ b/Tutorial/GacUI_Controls/ColorPicker/UI/Source/Demo.h @@ -1,16 +1,59 @@ -/*********************************************************************** -Vczh Library++ 3.0 -Developer: Zihan Chen(vczh) -GacUI::Demo +/*********************************************************************** +!!!!!! DO NOT MODIFY !!!!!! -This file is generated by: Vczh GacUI Resource Code Generator -************************************************************************ -DO NOT MODIFY +GacGen.exe Resource.xml + +This file is generated by Workflow compiler +https://github.com/vczh-libraries ***********************************************************************/ -#ifndef VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo -#define VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo +#ifndef VCZH_WORKFLOW_COMPILER_GENERATED_DEMO +#define VCZH_WORKFLOW_COMPILER_GENERATED_DEMO #include "DemoPartialClasses.h" +/*********************************************************************** +Reflection +***********************************************************************/ + +namespace vl +{ + namespace reflection + { + namespace description + { +#ifndef VCZH_DEBUG_NO_REFLECTION + DECL_TYPE_INFO(::demo::ColorBomboItemTemplate) + DECL_TYPE_INFO(::demo::ColorBomboItemTemplateConstructor) + DECL_TYPE_INFO(::demo::ColorListItemTemplate) + DECL_TYPE_INFO(::demo::ColorListItemTemplateConstructor) + DECL_TYPE_INFO(::demo::IColorItem) + DECL_TYPE_INFO(::demo::IViewModel) + DECL_TYPE_INFO(::demo::MainWindow) + DECL_TYPE_INFO(::demo::MainWindowConstructor) + + BEGIN_INTERFACE_PROXY_NOPARENT_SHAREDPTR(::demo::IColorItem) + ::vl::presentation::Color GetItemColor() override + { + INVOKEGET_INTERFACE_PROXY_NOPARAMS(GetItemColor); + } + ::vl::WString GetItemName() override + { + INVOKEGET_INTERFACE_PROXY_NOPARAMS(GetItemName); + } + END_INTERFACE_PROXY(::demo::IColorItem) + + BEGIN_INTERFACE_PROXY_NOPARENT_SHAREDPTR(::demo::IViewModel) + ::vl::collections::LazyList<::vl::Ptr<::demo::IColorItem>> GetColorItems() override + { + INVOKEGET_INTERFACE_PROXY_NOPARAMS(GetColorItems); + } + END_INTERFACE_PROXY(::demo::IViewModel) +#endif + + extern bool LoadDemoTypes(); + } + } +} + #endif diff --git a/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.cpp b/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.cpp index 78bab742..09dec82e 100644 --- a/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.cpp +++ b/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.cpp @@ -1,98 +1,1076 @@ -/*********************************************************************** -Vczh Library++ 3.0 -Developer: Zihan Chen(vczh) -GacUI::Partial Classes +/*********************************************************************** +!!!!!! DO NOT MODIFY !!!!!! -This file is generated by: Vczh GacUI Resource Code Generator -************************************************************************ -DO NOT MODIFY +GacGen.exe Resource.xml + +This file is generated by Workflow compiler +https://github.com/vczh-libraries ***********************************************************************/ #include "Demo.h" +#if defined( _MSC_VER) +#pragma warning(push) +#pragma warning(disable:4250) +#elif defined(__GNUC__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wparentheses-equality" +#elif defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wparentheses-equality" +#endif + +#define GLOBAL_SYMBOL ::vl_workflow_global::Demo:: +#define GLOBAL_NAME ::vl_workflow_global::Demo::Instance(). +#define GLOBAL_OBJ &::vl_workflow_global::Demo::Instance() +#define USERIMPL(...) + +/*********************************************************************** +Global Variables +***********************************************************************/ + +BEGIN_GLOBAL_STORAGE_CLASS(vl_workflow_global_Demo) + vl_workflow_global::Demo instance; + INITIALIZE_GLOBAL_STORAGE_CLASS + FINALIZE_GLOBAL_STORAGE_CLASS +END_GLOBAL_STORAGE_CLASS(vl_workflow_global_Demo) + +namespace vl_workflow_global +{ +/*********************************************************************** +Closure Definitions +***********************************************************************/ + + struct __vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__ + { + ::demo::ColorBomboItemTemplateConstructor* __vwsnthis_0; + + __vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0); + + void operator()(const ::vl::reflection::description::Value& __vwsn_value_) const; + }; + + struct __vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__ + { + ::demo::ColorBomboItemTemplateConstructor* __vwsnthis_0; + + __vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0); + + void operator()(const ::vl::reflection::description::Value& __vwsn_value_) const; + }; + + struct __vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__ + { + ::demo::ColorListItemTemplateConstructor* __vwsnthis_0; + + __vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0); + + void operator()(const ::vl::reflection::description::Value& __vwsn_value_) const; + }; + + struct __vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__ + { + ::demo::ColorListItemTemplateConstructor* __vwsnthis_0; + + __vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0); + + void operator()(const ::vl::reflection::description::Value& __vwsn_value_) const; + }; + + class __vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory : public ::vl::Object, public virtual ::vl::presentation::templates::GuiTemplate::IFactory + { + public: + ::demo::MainWindowConstructor* __vwsnthis_0; + + __vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory(::demo::MainWindowConstructor* __vwsnctorthis_0); + + ::vl::presentation::templates::GuiTemplate* CreateTemplate(const ::vl::reflection::description::Value& __vwsn_viewModel_) override; + }; + + class __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription : public ::vl::Object, public virtual ::vl::reflection::description::IValueSubscription + { + public: + ::demo::ColorBomboItemTemplateConstructor* __vwsnthis_0; + + __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0); + + ::demo::ColorBomboItemTemplate* __vwsn_bind_cache_0 = nullptr; + ::vl::Ptr<::vl::reflection::description::IEventHandler> __vwsn_bind_handler_0_0; + bool __vwsn_bind_opened_ = false; + bool __vwsn_bind_closed_ = false; + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + void __vwsn_bind_activator_(); + void __vwsn_bind_callback_0_0(); + void __vwsn_bind_initialize_(); + ::vl::Ptr<::vl::reflection::description::IValueListener> Subscribe(const ::vl::Func& __vwsn_bind_callback_) override; + bool Update() override; + bool Close() override; + }; + + class __vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener : public ::vl::Object, public virtual ::vl::reflection::description::IValueListener + { + public: + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + ::vl::reflection::description::IValueSubscription* __vwsn_subscription_; + ::vl::reflection::description::IValueSubscription* __vwsnthis_0; + ::demo::ColorBomboItemTemplateConstructor* __vwsnthis_1; + + __vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_1); + + ::vl::reflection::description::IValueSubscription* GetSubscription() override; + bool GetStopped() override; + bool StopListening() override; + }; + + class __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription : public ::vl::Object, public virtual ::vl::reflection::description::IValueSubscription + { + public: + ::demo::ColorBomboItemTemplateConstructor* __vwsnthis_0; + + __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0); + + ::demo::ColorBomboItemTemplate* __vwsn_bind_cache_0 = nullptr; + ::vl::Ptr<::vl::reflection::description::IEventHandler> __vwsn_bind_handler_0_0; + bool __vwsn_bind_opened_ = false; + bool __vwsn_bind_closed_ = false; + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + void __vwsn_bind_activator_(); + void __vwsn_bind_callback_0_0(::vl::presentation::compositions::GuiGraphicsComposition* __vwsn_bind_callback_argument_0, ::vl::presentation::compositions::GuiEventArgs* __vwsn_bind_callback_argument_1); + void __vwsn_bind_initialize_(); + ::vl::Ptr<::vl::reflection::description::IValueListener> Subscribe(const ::vl::Func& __vwsn_bind_callback_) override; + bool Update() override; + bool Close() override; + }; + + class __vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener : public ::vl::Object, public virtual ::vl::reflection::description::IValueListener + { + public: + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + ::vl::reflection::description::IValueSubscription* __vwsn_subscription_; + ::vl::reflection::description::IValueSubscription* __vwsnthis_0; + ::demo::ColorBomboItemTemplateConstructor* __vwsnthis_1; + + __vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_1); + + ::vl::reflection::description::IValueSubscription* GetSubscription() override; + bool GetStopped() override; + bool StopListening() override; + }; + + class __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription : public ::vl::Object, public virtual ::vl::reflection::description::IValueSubscription + { + public: + ::demo::ColorListItemTemplateConstructor* __vwsnthis_0; + + __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0); + + ::demo::ColorListItemTemplate* __vwsn_bind_cache_0 = nullptr; + ::vl::Ptr<::vl::reflection::description::IEventHandler> __vwsn_bind_handler_0_0; + bool __vwsn_bind_opened_ = false; + bool __vwsn_bind_closed_ = false; + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + void __vwsn_bind_activator_(); + void __vwsn_bind_callback_0_0(::vl::presentation::compositions::GuiGraphicsComposition* __vwsn_bind_callback_argument_0, ::vl::presentation::compositions::GuiEventArgs* __vwsn_bind_callback_argument_1); + void __vwsn_bind_initialize_(); + ::vl::Ptr<::vl::reflection::description::IValueListener> Subscribe(const ::vl::Func& __vwsn_bind_callback_) override; + bool Update() override; + bool Close() override; + }; + + class __vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener : public ::vl::Object, public virtual ::vl::reflection::description::IValueListener + { + public: + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + ::vl::reflection::description::IValueSubscription* __vwsn_subscription_; + ::vl::reflection::description::IValueSubscription* __vwsnthis_0; + ::demo::ColorListItemTemplateConstructor* __vwsnthis_1; + + __vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorListItemTemplateConstructor* __vwsnctorthis_1); + + ::vl::reflection::description::IValueSubscription* GetSubscription() override; + bool GetStopped() override; + bool StopListening() override; + }; + + class __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription : public ::vl::Object, public virtual ::vl::reflection::description::IValueSubscription + { + public: + ::demo::ColorListItemTemplateConstructor* __vwsnthis_0; + + __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0); + + ::demo::ColorListItemTemplate* __vwsn_bind_cache_0 = nullptr; + ::vl::Ptr<::vl::reflection::description::IEventHandler> __vwsn_bind_handler_0_0; + bool __vwsn_bind_opened_ = false; + bool __vwsn_bind_closed_ = false; + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + void __vwsn_bind_activator_(); + void __vwsn_bind_callback_0_0(::vl::presentation::compositions::GuiGraphicsComposition* __vwsn_bind_callback_argument_0, ::vl::presentation::compositions::GuiEventArgs* __vwsn_bind_callback_argument_1); + void __vwsn_bind_initialize_(); + ::vl::Ptr<::vl::reflection::description::IValueListener> Subscribe(const ::vl::Func& __vwsn_bind_callback_) override; + bool Update() override; + bool Close() override; + }; + + class __vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener : public ::vl::Object, public virtual ::vl::reflection::description::IValueListener + { + public: + ::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsn_bind_listeners_; + ::vl::reflection::description::IValueSubscription* __vwsn_subscription_; + ::vl::reflection::description::IValueSubscription* __vwsnthis_0; + ::demo::ColorListItemTemplateConstructor* __vwsnthis_1; + + __vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorListItemTemplateConstructor* __vwsnctorthis_1); + + ::vl::reflection::description::IValueSubscription* GetSubscription() override; + bool GetStopped() override; + bool StopListening() override; + }; + + class __vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory : public ::vl::Object, public virtual ::vl::presentation::templates::GuiTemplate::IFactory + { + public: + ::demo::MainWindowConstructor* __vwsnthis_0; + + __vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory(::demo::MainWindowConstructor* __vwsnctorthis_0); + + ::vl::presentation::templates::GuiTemplate* CreateTemplate(const ::vl::reflection::description::Value& __vwsn_viewModel_) override; + }; + + //------------------------------------------------------------------- + + __vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__::__vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + } + + void __vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__::operator()(const ::vl::reflection::description::Value& __vwsn_value_) const + { + auto __vwsn_old_ = ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_4.Obj())->GetColor(); + auto __vwsn_new_ = ::vl::__vwsn::Unbox<::vl::presentation::Color>(__vwsn_value_); + if ((__vwsn_old_ == __vwsn_new_)) + { + return; + } + ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_4.Obj())->SetColor(__vwsn_new_); + } + + //------------------------------------------------------------------- + + __vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__::__vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + } + + void __vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__::operator()(const ::vl::reflection::description::Value& __vwsn_value_) const + { + auto __vwsn_old_ = ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_4.Obj())->GetFont(); + auto __vwsn_new_ = ::vl::__vwsn::Unbox<::vl::presentation::FontProperties>(__vwsn_value_); + if ((__vwsn_old_ == __vwsn_new_)) + { + return; + } + ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_4.Obj())->SetFont(__vwsn_new_); + } + + //------------------------------------------------------------------- + + __vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__::__vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + } + + void __vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__::operator()(const ::vl::reflection::description::Value& __vwsn_value_) const + { + auto __vwsn_old_ = ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_0)->GetFont(); + auto __vwsn_new_ = ::vl::__vwsn::Unbox<::vl::presentation::FontProperties>(__vwsn_value_); + if ((__vwsn_old_ == __vwsn_new_)) + { + return; + } + ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_0)->SetFont(__vwsn_new_); + } + + //------------------------------------------------------------------- + + __vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__::__vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + } + + void __vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__::operator()(const ::vl::reflection::description::Value& __vwsn_value_) const + { + auto __vwsn_old_ = ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_0)->GetTextColor(); + auto __vwsn_new_ = ::vl::__vwsn::Unbox<::vl::presentation::Color>(__vwsn_value_); + if ((__vwsn_old_ == __vwsn_new_)) + { + return; + } + ::vl::__vwsn::This(::vl::__vwsn::This(__vwsnthis_0)->__vwsn_precompile_0)->SetTextColor(__vwsn_new_); + } + + //------------------------------------------------------------------- + + __vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory::__vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory(::demo::MainWindowConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + } + + ::vl::presentation::templates::GuiTemplate* __vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory::CreateTemplate(const ::vl::reflection::description::Value& __vwsn_viewModel_) + { + { + if ([&](){ auto __vwsn_temp__ = __vwsn_viewModel_; return __vwsn_temp__.GetSharedPtr() && ::vl::__vwsn::RawPtrCast<::demo::IColorItem>(__vwsn_temp__.GetRawPtr()) != nullptr; }()) + { + auto __vwsn_template_ = ::vl::__vwsn::Ensure(static_cast<::vl::presentation::templates::GuiControlTemplate*>(new ::demo::ColorBomboItemTemplate(::vl::__vwsn::Unbox<::vl::Ptr<::demo::IColorItem>>(__vwsn_viewModel_)))); + return ::vl::__vwsn::Ensure(static_cast<::vl::presentation::templates::GuiTemplate*>(__vwsn_template_)); + } + } + } + + //------------------------------------------------------------------- + + __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + this->__vwsn_bind_cache_0 = static_cast<::demo::ColorBomboItemTemplate*>(nullptr); + this->__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>(); + this->__vwsn_bind_opened_ = false; + this->__vwsn_bind_closed_ = false; + this->__vwsn_bind_listeners_ = ::vl::reflection::description::IValueDictionary::Create(); + } + + void __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_activator_() + { + auto __vwsn_bind_activator_result_ = ::vl::__vwsn::This(__vwsn_bind_cache_0)->GetTextColor(); + using __vwsnt_0 = ::vl::reflection::description::Value; + FOREACH(__vwsnt_0, __vwsn_bind_callback_, ::vl::reflection::description::GetLazyList<::vl::reflection::description::Value>(::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->GetValues())) + { + ::vl::__vwsn::Unbox<::vl::Func>(__vwsn_bind_callback_)(::vl::__vwsn::Box(__vwsn_bind_activator_result_)); + } + } + + void __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0() + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + } + + void __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_initialize_() + { + (__vwsn_bind_cache_0 = ::vl::__vwsn::This(__vwsnthis_0)->self); + (__vwsn_bind_handler_0_0 = ::vl::__vwsn::EventAttach(::vl::__vwsn::This(__vwsn_bind_cache_0)->TextColorChanged, ::vl::Func(::vl::__vwsn::This(this), &__vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0))); + } + + ::vl::Ptr<::vl::reflection::description::IValueListener> __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Subscribe(const ::vl::Func& __vwsn_bind_callback_) + { + if ((! __vwsn_bind_opened_)) + { + (__vwsn_bind_opened_ = true); + ::vl::__vwsn::This(this)->__vwsn_bind_initialize_(); + } + auto __vwsn_subscription_ = this; + auto __vwsn_listener_shared_ = ::vl::Ptr<::vl::reflection::description::IValueListener>(new ::vl_workflow_global::__vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(__vwsn_bind_listeners_, __vwsn_subscription_, this, __vwsnthis_0)); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Set(::vl::__vwsn::Box(__vwsn_listener_shared_), ::vl::__vwsn::Box(__vwsn_bind_callback_)); + return __vwsn_listener_shared_; + } + + bool __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Update() + { + if ((! __vwsn_bind_closed_)) + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + return true; + } + return false; + } + + bool __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Close() + { + if ((! __vwsn_bind_closed_)) + { + (__vwsn_bind_closed_ = true); + ::vl::__vwsn::EventDetach(::vl::__vwsn::This(__vwsn_bind_cache_0)->TextColorChanged, __vwsn_bind_handler_0_0); + (__vwsn_bind_cache_0 = static_cast<::demo::ColorBomboItemTemplate*>(nullptr)); + (__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>()); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Clear(); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::__vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_1) + :__vwsn_bind_listeners_(__vwsnctor___vwsn_bind_listeners_) + , __vwsn_subscription_(__vwsnctor___vwsn_subscription_) + , __vwsnthis_0(__vwsnctorthis_0) + , __vwsnthis_1(__vwsnctorthis_1) + { + } + + ::vl::reflection::description::IValueSubscription* __vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetSubscription() + { + return ::vl::__vwsn::This(this)->__vwsn_subscription_; + } + + bool __vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetStopped() + { + return (! ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))); + } + + bool __vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::StopListening() + { + if (::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))) + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->Remove(::vl::__vwsn::Box(this)); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + this->__vwsn_bind_cache_0 = static_cast<::demo::ColorBomboItemTemplate*>(nullptr); + this->__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>(); + this->__vwsn_bind_opened_ = false; + this->__vwsn_bind_closed_ = false; + this->__vwsn_bind_listeners_ = ::vl::reflection::description::IValueDictionary::Create(); + } + + void __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_activator_() + { + auto __vwsn_bind_activator_result_ = ::vl::__vwsn::This(__vwsn_bind_cache_0)->GetFont(); + using __vwsnt_0 = ::vl::reflection::description::Value; + FOREACH(__vwsnt_0, __vwsn_bind_callback_, ::vl::reflection::description::GetLazyList<::vl::reflection::description::Value>(::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->GetValues())) + { + ::vl::__vwsn::Unbox<::vl::Func>(__vwsn_bind_callback_)(::vl::__vwsn::Box(__vwsn_bind_activator_result_)); + } + } + + void __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0(::vl::presentation::compositions::GuiGraphicsComposition* __vwsn_bind_callback_argument_0, ::vl::presentation::compositions::GuiEventArgs* __vwsn_bind_callback_argument_1) + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + } + + void __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_initialize_() + { + (__vwsn_bind_cache_0 = ::vl::__vwsn::This(__vwsnthis_0)->self); + (__vwsn_bind_handler_0_0 = ::vl::__vwsn::EventAttach(::vl::__vwsn::This(__vwsn_bind_cache_0)->FontChanged, ::vl::Func(::vl::__vwsn::This(this), &__vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0))); + } + + ::vl::Ptr<::vl::reflection::description::IValueListener> __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Subscribe(const ::vl::Func& __vwsn_bind_callback_) + { + if ((! __vwsn_bind_opened_)) + { + (__vwsn_bind_opened_ = true); + ::vl::__vwsn::This(this)->__vwsn_bind_initialize_(); + } + auto __vwsn_subscription_ = this; + auto __vwsn_listener_shared_ = ::vl::Ptr<::vl::reflection::description::IValueListener>(new ::vl_workflow_global::__vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(__vwsn_bind_listeners_, __vwsn_subscription_, this, __vwsnthis_0)); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Set(::vl::__vwsn::Box(__vwsn_listener_shared_), ::vl::__vwsn::Box(__vwsn_bind_callback_)); + return __vwsn_listener_shared_; + } + + bool __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Update() + { + if ((! __vwsn_bind_closed_)) + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + return true; + } + return false; + } + + bool __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Close() + { + if ((! __vwsn_bind_closed_)) + { + (__vwsn_bind_closed_ = true); + ::vl::__vwsn::EventDetach(::vl::__vwsn::This(__vwsn_bind_cache_0)->FontChanged, __vwsn_bind_handler_0_0); + (__vwsn_bind_cache_0 = static_cast<::demo::ColorBomboItemTemplate*>(nullptr)); + (__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>()); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Clear(); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::__vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorBomboItemTemplateConstructor* __vwsnctorthis_1) + :__vwsn_bind_listeners_(__vwsnctor___vwsn_bind_listeners_) + , __vwsn_subscription_(__vwsnctor___vwsn_subscription_) + , __vwsnthis_0(__vwsnctorthis_0) + , __vwsnthis_1(__vwsnctorthis_1) + { + } + + ::vl::reflection::description::IValueSubscription* __vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetSubscription() + { + return ::vl::__vwsn::This(this)->__vwsn_subscription_; + } + + bool __vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetStopped() + { + return (! ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))); + } + + bool __vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::StopListening() + { + if (::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))) + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->Remove(::vl::__vwsn::Box(this)); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + this->__vwsn_bind_cache_0 = static_cast<::demo::ColorListItemTemplate*>(nullptr); + this->__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>(); + this->__vwsn_bind_opened_ = false; + this->__vwsn_bind_closed_ = false; + this->__vwsn_bind_listeners_ = ::vl::reflection::description::IValueDictionary::Create(); + } + + void __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_activator_() + { + auto __vwsn_bind_activator_result_ = ::vl::__vwsn::This(__vwsn_bind_cache_0)->GetFont(); + using __vwsnt_0 = ::vl::reflection::description::Value; + FOREACH(__vwsnt_0, __vwsn_bind_callback_, ::vl::reflection::description::GetLazyList<::vl::reflection::description::Value>(::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->GetValues())) + { + ::vl::__vwsn::Unbox<::vl::Func>(__vwsn_bind_callback_)(::vl::__vwsn::Box(__vwsn_bind_activator_result_)); + } + } + + void __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0(::vl::presentation::compositions::GuiGraphicsComposition* __vwsn_bind_callback_argument_0, ::vl::presentation::compositions::GuiEventArgs* __vwsn_bind_callback_argument_1) + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + } + + void __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_initialize_() + { + (__vwsn_bind_cache_0 = ::vl::__vwsn::This(__vwsnthis_0)->self); + (__vwsn_bind_handler_0_0 = ::vl::__vwsn::EventAttach(::vl::__vwsn::This(__vwsn_bind_cache_0)->FontChanged, ::vl::Func(::vl::__vwsn::This(this), &__vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0))); + } + + ::vl::Ptr<::vl::reflection::description::IValueListener> __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Subscribe(const ::vl::Func& __vwsn_bind_callback_) + { + if ((! __vwsn_bind_opened_)) + { + (__vwsn_bind_opened_ = true); + ::vl::__vwsn::This(this)->__vwsn_bind_initialize_(); + } + auto __vwsn_subscription_ = this; + auto __vwsn_listener_shared_ = ::vl::Ptr<::vl::reflection::description::IValueListener>(new ::vl_workflow_global::__vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(__vwsn_bind_listeners_, __vwsn_subscription_, this, __vwsnthis_0)); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Set(::vl::__vwsn::Box(__vwsn_listener_shared_), ::vl::__vwsn::Box(__vwsn_bind_callback_)); + return __vwsn_listener_shared_; + } + + bool __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Update() + { + if ((! __vwsn_bind_closed_)) + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + return true; + } + return false; + } + + bool __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Close() + { + if ((! __vwsn_bind_closed_)) + { + (__vwsn_bind_closed_ = true); + ::vl::__vwsn::EventDetach(::vl::__vwsn::This(__vwsn_bind_cache_0)->FontChanged, __vwsn_bind_handler_0_0); + (__vwsn_bind_cache_0 = static_cast<::demo::ColorListItemTemplate*>(nullptr)); + (__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>()); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Clear(); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::__vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorListItemTemplateConstructor* __vwsnctorthis_1) + :__vwsn_bind_listeners_(__vwsnctor___vwsn_bind_listeners_) + , __vwsn_subscription_(__vwsnctor___vwsn_subscription_) + , __vwsnthis_0(__vwsnctorthis_0) + , __vwsnthis_1(__vwsnctorthis_1) + { + } + + ::vl::reflection::description::IValueSubscription* __vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetSubscription() + { + return ::vl::__vwsn::This(this)->__vwsn_subscription_; + } + + bool __vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetStopped() + { + return (! ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))); + } + + bool __vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::StopListening() + { + if (::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))) + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->Remove(::vl::__vwsn::Box(this)); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(::demo::ColorListItemTemplateConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + this->__vwsn_bind_cache_0 = static_cast<::demo::ColorListItemTemplate*>(nullptr); + this->__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>(); + this->__vwsn_bind_opened_ = false; + this->__vwsn_bind_closed_ = false; + this->__vwsn_bind_listeners_ = ::vl::reflection::description::IValueDictionary::Create(); + } + + void __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_activator_() + { + auto __vwsn_bind_activator_result_ = ::vl::__vwsn::This(__vwsn_bind_cache_0)->GetTextColor(); + using __vwsnt_0 = ::vl::reflection::description::Value; + FOREACH(__vwsnt_0, __vwsn_bind_callback_, ::vl::reflection::description::GetLazyList<::vl::reflection::description::Value>(::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->GetValues())) + { + ::vl::__vwsn::Unbox<::vl::Func>(__vwsn_bind_callback_)(::vl::__vwsn::Box(__vwsn_bind_activator_result_)); + } + } + + void __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0(::vl::presentation::compositions::GuiGraphicsComposition* __vwsn_bind_callback_argument_0, ::vl::presentation::compositions::GuiEventArgs* __vwsn_bind_callback_argument_1) + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + } + + void __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_initialize_() + { + (__vwsn_bind_cache_0 = ::vl::__vwsn::This(__vwsnthis_0)->self); + (__vwsn_bind_handler_0_0 = ::vl::__vwsn::EventAttach(::vl::__vwsn::This(__vwsn_bind_cache_0)->TextColorChanged, ::vl::Func(::vl::__vwsn::This(this), &__vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::__vwsn_bind_callback_0_0))); + } + + ::vl::Ptr<::vl::reflection::description::IValueListener> __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Subscribe(const ::vl::Func& __vwsn_bind_callback_) + { + if ((! __vwsn_bind_opened_)) + { + (__vwsn_bind_opened_ = true); + ::vl::__vwsn::This(this)->__vwsn_bind_initialize_(); + } + auto __vwsn_subscription_ = this; + auto __vwsn_listener_shared_ = ::vl::Ptr<::vl::reflection::description::IValueListener>(new ::vl_workflow_global::__vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(__vwsn_bind_listeners_, __vwsn_subscription_, this, __vwsnthis_0)); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Set(::vl::__vwsn::Box(__vwsn_listener_shared_), ::vl::__vwsn::Box(__vwsn_bind_callback_)); + return __vwsn_listener_shared_; + } + + bool __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Update() + { + if ((! __vwsn_bind_closed_)) + { + ::vl::__vwsn::This(this)->__vwsn_bind_activator_(); + return true; + } + return false; + } + + bool __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription::Close() + { + if ((! __vwsn_bind_closed_)) + { + (__vwsn_bind_closed_ = true); + ::vl::__vwsn::EventDetach(::vl::__vwsn::This(__vwsn_bind_cache_0)->TextColorChanged, __vwsn_bind_handler_0_0); + (__vwsn_bind_cache_0 = static_cast<::demo::ColorListItemTemplate*>(nullptr)); + (__vwsn_bind_handler_0_0 = ::vl::Ptr<::vl::reflection::description::IEventHandler>()); + ::vl::__vwsn::This(__vwsn_bind_listeners_.Obj())->Clear(); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::__vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener(::vl::Ptr<::vl::reflection::description::IValueDictionary> __vwsnctor___vwsn_bind_listeners_, ::vl::reflection::description::IValueSubscription* __vwsnctor___vwsn_subscription_, ::vl::reflection::description::IValueSubscription* __vwsnctorthis_0, ::demo::ColorListItemTemplateConstructor* __vwsnctorthis_1) + :__vwsn_bind_listeners_(__vwsnctor___vwsn_bind_listeners_) + , __vwsn_subscription_(__vwsnctor___vwsn_subscription_) + , __vwsnthis_0(__vwsnctorthis_0) + , __vwsnthis_1(__vwsnctorthis_1) + { + } + + ::vl::reflection::description::IValueSubscription* __vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetSubscription() + { + return ::vl::__vwsn::This(this)->__vwsn_subscription_; + } + + bool __vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::GetStopped() + { + return (! ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))); + } + + bool __vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener::StopListening() + { + if (::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->GetKeys().Obj())->Contains(::vl::__vwsn::Box(this))) + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_bind_listeners_.Obj())->Remove(::vl::__vwsn::Box(this)); + return true; + } + return false; + } + + //------------------------------------------------------------------- + + __vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory::__vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory(::demo::MainWindowConstructor* __vwsnctorthis_0) + :__vwsnthis_0(__vwsnctorthis_0) + { + } + + ::vl::presentation::templates::GuiTemplate* __vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory::CreateTemplate(const ::vl::reflection::description::Value& __vwsn_viewModel_) + { + { + if ([&](){ auto __vwsn_temp__ = __vwsn_viewModel_; return __vwsn_temp__.GetSharedPtr() && ::vl::__vwsn::RawPtrCast<::demo::IColorItem>(__vwsn_temp__.GetRawPtr()) != nullptr; }()) + { + auto __vwsn_template_ = ::vl::__vwsn::Ensure(static_cast<::vl::presentation::templates::GuiTextListItemTemplate*>(new ::demo::ColorListItemTemplate(::vl::__vwsn::Unbox<::vl::Ptr<::demo::IColorItem>>(__vwsn_viewModel_)))); + return ::vl::__vwsn::Ensure(static_cast<::vl::presentation::templates::GuiTemplate*>(__vwsn_template_)); + } + } + } + +/*********************************************************************** +Global Functions +***********************************************************************/ + + Demo& Demo::Instance() + { + return Getvl_workflow_global_Demo().instance; + } +} + +/*********************************************************************** +Class (::demo::ColorBomboItemTemplateConstructor) +***********************************************************************/ + namespace demo { - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) + void ColorBomboItemTemplateConstructor::__vwsn_initialize_instance_(::demo::ColorBomboItemTemplate* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_) + { + (::vl::__vwsn::This(this)->self = __vwsn_this_); + (::vl::__vwsn::This(this)->ViewModel = ::vl::__vwsn::This(__vwsn_this_)->GetViewModel()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->self)->SetMinSizeLimitation(::vl::presentation::compositions::GuiGraphicsComposition::MinSizeLimitation::LimitToElementAndChildren); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_0 = new ::vl::presentation::compositions::GuiTableComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetMinSizeLimitation(::vl::presentation::compositions::GuiGraphicsComposition::MinSizeLimitation::LimitToElementAndChildren); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetRowsAndColumns(3, 3); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetRowOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetRowOption(1, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Absolute; __vwsn_temp__.absolute = 16; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetRowOption(2, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetColumnOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Absolute; __vwsn_temp__.absolute = 16; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetColumnOption(1, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Absolute; __vwsn_temp__.absolute = 3; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetColumnOption(2, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_1 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetSite(1, 0, 1, 1); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_2 = ::vl::Ptr<::vl::presentation::elements::GuiSolidBackgroundElement>(::vl::reflection::description::Element_Constructor<::vl::presentation::elements::GuiSolidBackgroundElement>())); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetOwnedElement(::vl::__vwsn::Ensure(::vl::Ptr<::vl::presentation::elements::IGuiGraphicsElement>(::vl::__vwsn::This(this)->__vwsn_precompile_2))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_1))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_3 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetSite(0, 2, 3, 1); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_4 = ::vl::Ptr<::vl::presentation::elements::GuiSolidLabelElement>(::vl::reflection::description::Element_Constructor<::vl::presentation::elements::GuiSolidLabelElement>())); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_4.Obj())->SetVerticalAlignment(::vl::presentation::Alignment::Center); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_4.Obj())->SetEllipse(::vl::__vwsn::Parse(::vl::WString(L"true", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetOwnedElement(::vl::__vwsn::Ensure(::vl::Ptr<::vl::presentation::elements::IGuiGraphicsElement>(::vl::__vwsn::This(this)->__vwsn_precompile_4))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_3))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->self)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_0))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_2.Obj())->SetColor(::vl::__vwsn::This(::vl::__vwsn::This(this)->ViewModel.Obj())->GetItemColor()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_4.Obj())->SetText(::vl::__vwsn::This(::vl::__vwsn::This(this)->ViewModel.Obj())->GetItemName()); + } + { + auto __vwsn_created_subscription_ = ::vl::__vwsn::This(__vwsn_this_)->AddSubscription(::vl::Ptr<::vl::reflection::description::IValueSubscription>(new ::vl_workflow_global::__vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Subscribe(LAMBDA(::vl_workflow_global::__vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Update(); + } + { + auto __vwsn_created_subscription_ = ::vl::__vwsn::This(__vwsn_this_)->AddSubscription(::vl::Ptr<::vl::reflection::description::IValueSubscription>(new ::vl_workflow_global::__vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Subscribe(LAMBDA(::vl_workflow_global::__vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Update(); + } + } - void ColorBomboItemTemplate::OnCreate() + ColorBomboItemTemplateConstructor::ColorBomboItemTemplateConstructor() { } - void ColorBomboItemTemplate::OnDestroy() +/*********************************************************************** +Class (::demo::ColorBomboItemTemplate) +***********************************************************************/ + + ::vl::presentation::Color ColorBomboItemTemplate::GetTextColor() { + return ::vl::__vwsn::This(this)->textColor; } - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER - - ColorBomboItemTemplate::ColorBomboItemTemplate(vl::Ptr ViewModel) + void ColorBomboItemTemplate::SetTextColor(::vl::presentation::Color value) { - InitializeComponents(ViewModel); - OnCreate(); + if ((::vl::__vwsn::This(this)->textColor != value)) + { + (::vl::__vwsn::This(this)->textColor = value); + ::vl::__vwsn::EventInvoke(::vl::__vwsn::This(this)->TextColorChanged)(); + } + } + + ::vl::Ptr<::demo::IColorItem> ColorBomboItemTemplate::GetViewModel() + { + return ::vl::__vwsn::This(this)->__vwsn_parameter_ViewModel; + } + + ColorBomboItemTemplate::ColorBomboItemTemplate(::vl::Ptr<::demo::IColorItem> __vwsn_ctor_parameter_ViewModel) + { + (::vl::__vwsn::This(this)->__vwsn_parameter_ViewModel = __vwsn_ctor_parameter_ViewModel); + auto __vwsn_resource_ = ::vl::__vwsn::This(::vl::presentation::GetResourceManager())->GetResourceFromClassName(::vl::WString(L"demo::ColorBomboItemTemplate", false)); + auto __vwsn_resolver_ = ::vl::Ptr<::vl::presentation::GuiResourcePathResolver>(new ::vl::presentation::GuiResourcePathResolver(__vwsn_resource_, ::vl::__vwsn::This(__vwsn_resource_.Obj())->GetWorkingDirectory())); + ::vl::__vwsn::This(this)->__vwsn_initialize_instance_(this, ::vl::__vwsn::Ensure(static_cast<::vl::presentation::GuiResourcePathResolver*>(__vwsn_resolver_.Obj()))); } ColorBomboItemTemplate::~ColorBomboItemTemplate() { - OnDestroy(); - ClearSubscriptions(); + ::vl::__vwsn::This(this)->ClearSubscriptions(); } -} +/*********************************************************************** +Class (::demo::ColorListItemTemplateConstructor) +***********************************************************************/ -namespace demo -{ - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) + void ColorListItemTemplateConstructor::__vwsn_initialize_instance_(::demo::ColorListItemTemplate* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_) + { + (::vl::__vwsn::This(this)->self = __vwsn_this_); + (::vl::__vwsn::This(this)->ViewModel = ::vl::__vwsn::This(__vwsn_this_)->GetViewModel()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->self)->SetMinSizeLimitation(::vl::presentation::compositions::GuiGraphicsComposition::MinSizeLimitation::LimitToElementAndChildren); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_0 = new ::demo::ColorBomboItemTemplate(::vl::__vwsn::This(this)->ViewModel)); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 6; __vwsn_temp__.top = 6; __vwsn_temp__.right = 6; __vwsn_temp__.bottom = 6; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->self)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_0))); + } + { + auto __vwsn_created_subscription_ = ::vl::__vwsn::This(__vwsn_this_)->AddSubscription(::vl::Ptr<::vl::reflection::description::IValueSubscription>(new ::vl_workflow_global::__vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Subscribe(LAMBDA(::vl_workflow_global::__vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Update(); + } + { + auto __vwsn_created_subscription_ = ::vl::__vwsn::This(__vwsn_this_)->AddSubscription(::vl::Ptr<::vl::reflection::description::IValueSubscription>(new ::vl_workflow_global::__vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Subscribe(LAMBDA(::vl_workflow_global::__vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__(this))); + ::vl::__vwsn::This(__vwsn_created_subscription_.Obj())->Update(); + } + } - void ColorListItemTemplate::OnCreate() + ColorListItemTemplateConstructor::ColorListItemTemplateConstructor() { } - void ColorListItemTemplate::OnDestroy() +/*********************************************************************** +Class (::demo::ColorListItemTemplate) +***********************************************************************/ + + ::vl::Ptr<::demo::IColorItem> ColorListItemTemplate::GetViewModel() { + return ::vl::__vwsn::This(this)->__vwsn_parameter_ViewModel; } - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER - - ColorListItemTemplate::ColorListItemTemplate(vl::Ptr ViewModel) + ColorListItemTemplate::ColorListItemTemplate(::vl::Ptr<::demo::IColorItem> __vwsn_ctor_parameter_ViewModel) { - InitializeComponents(ViewModel); - OnCreate(); + (::vl::__vwsn::This(this)->__vwsn_parameter_ViewModel = __vwsn_ctor_parameter_ViewModel); + auto __vwsn_resource_ = ::vl::__vwsn::This(::vl::presentation::GetResourceManager())->GetResourceFromClassName(::vl::WString(L"demo::ColorListItemTemplate", false)); + auto __vwsn_resolver_ = ::vl::Ptr<::vl::presentation::GuiResourcePathResolver>(new ::vl::presentation::GuiResourcePathResolver(__vwsn_resource_, ::vl::__vwsn::This(__vwsn_resource_.Obj())->GetWorkingDirectory())); + ::vl::__vwsn::This(this)->__vwsn_initialize_instance_(this, ::vl::__vwsn::Ensure(static_cast<::vl::presentation::GuiResourcePathResolver*>(__vwsn_resolver_.Obj()))); } ColorListItemTemplate::~ColorListItemTemplate() { - OnDestroy(); - ClearSubscriptions(); + ::vl::__vwsn::This(this)->ClearSubscriptions(); } -} +/*********************************************************************** +Class (::demo::MainWindowConstructor) +***********************************************************************/ -namespace demo -{ - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) + void MainWindowConstructor::__vwsn_initialize_instance_(::demo::MainWindow* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_) + { + (::vl::__vwsn::This(this)->__vwsn_precompile_0 = __vwsn_this_); + (::vl::__vwsn::This(this)->ViewModel = ::vl::__vwsn::This(__vwsn_this_)->GetViewModel()); + (::vl::__vwsn::This(this)->__vwsn_precompile_8 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_8)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 480; __vwsn_temp__.y = 320; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetClientSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 480; __vwsn_temp__.y = 320; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetText(::vl::WString(L"ColorPicker", false)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_1 = new ::vl::presentation::compositions::GuiTableComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetCellPadding(::vl::__vwsn::Parse<::vl::vint32_t>(::vl::WString(L"10", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetRowsAndColumns(3, 2); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetRowOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetRowOption(1, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetRowOption(2, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetColumnOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->SetColumnOption(1, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_2 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_2)->SetSite(0, 0, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateLabelStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_3 = new ::vl::presentation::controls::GuiLabel(__vwsn_controlStyle_)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetText(::vl::WString(L"ComboBox and BindableTextList using ItemTemplate:", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_2)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_2))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_4 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_4)->SetSite(1, 0, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateTextListStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_6 = new ::vl::presentation::controls::GuiBindableTextList(__vwsn_controlStyle_, ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateTextListItemStyle())); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetTextProperty(::vl::WString(L"name", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetVerticalAlwaysVisible(::vl::__vwsn::Parse(::vl::WString(L"false", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetHorizontalAlwaysVisible(::vl::__vwsn::Parse(::vl::WString(L"false", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetStyleProvider(::vl::__vwsn::Ensure(::vl::Ptr<::vl::presentation::controls::GuiListControl::IItemStyleProvider>(::vl::Ptr<::vl::presentation::templates::GuiTextListItemTemplate_ItemStyleProvider>(new ::vl::presentation::templates::GuiTextListItemTemplate_ItemStyleProvider(::vl::Ptr<::vl::presentation::templates::GuiTemplate::IFactory>(new ::vl_workflow_global::__vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory(this))))))); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateComboBoxStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_5 = new ::vl::presentation::controls::GuiComboBoxListControl(__vwsn_controlStyle_, ::vl::__vwsn::This(this)->__vwsn_precompile_6)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_7 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_7)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->SetStyleProvider(::vl::__vwsn::Ensure(::vl::Ptr<::vl::presentation::controls::GuiComboBoxListControl::IItemStyleProvider>(::vl::Ptr<::vl::presentation::templates::GuiControlTemplate_ItemStyleProvider>(new ::vl::presentation::templates::GuiControlTemplate_ItemStyleProvider(::vl::Ptr<::vl::presentation::templates::GuiTemplate::IFactory>(new ::vl_workflow_global::__vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory(this))))))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_4)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_4))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->GetContainerComposition())->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_1))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetItemSource(::vl::__vwsn::Ensure(::vl::Ptr<::vl::reflection::description::IValueEnumerable>(::vl::__vwsn::This(::vl::__vwsn::This(this)->ViewModel.Obj())->GetColorItems()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->SetSelectedIndex(0); + } + } - void MainWindow::OnCreate() + MainWindowConstructor::MainWindowConstructor() { } - void MainWindow::OnDestroy() +/*********************************************************************** +Class (::demo::MainWindow) +***********************************************************************/ + + ::vl::Ptr<::demo::IViewModel> MainWindow::GetViewModel() { + return ::vl::__vwsn::This(this)->__vwsn_parameter_ViewModel; } - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER - - MainWindow::MainWindow(vl::Ptr ViewModel) + MainWindow::MainWindow(::vl::Ptr<::demo::IViewModel> __vwsn_ctor_parameter_ViewModel) + : ::vl::presentation::controls::GuiWindow(::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateWindowStyle()) { - InitializeComponents(ViewModel); - OnCreate(); + (::vl::__vwsn::This(this)->__vwsn_parameter_ViewModel = __vwsn_ctor_parameter_ViewModel); + auto __vwsn_resource_ = ::vl::__vwsn::This(::vl::presentation::GetResourceManager())->GetResourceFromClassName(::vl::WString(L"demo::MainWindow", false)); + auto __vwsn_resolver_ = ::vl::Ptr<::vl::presentation::GuiResourcePathResolver>(new ::vl::presentation::GuiResourcePathResolver(__vwsn_resource_, ::vl::__vwsn::This(__vwsn_resource_.Obj())->GetWorkingDirectory())); + ::vl::__vwsn::This(this)->__vwsn_initialize_instance_(this, ::vl::__vwsn::Ensure(static_cast<::vl::presentation::GuiResourcePathResolver*>(__vwsn_resolver_.Obj()))); } MainWindow::~MainWindow() { - OnDestroy(); - ClearSubscriptions(); + ::vl::__vwsn::This(this)->ClearSubscriptions(); } -} +/*********************************************************************** +Class (::demo::IColorItem) +***********************************************************************/ + +/*********************************************************************** +Class (::demo::IViewModel) +***********************************************************************/ + +} +#undef GLOBAL_SYMBOL +#undef GLOBAL_NAME +#undef GLOBAL_OBJ +#undef USERIMPL + +/*********************************************************************** +Reflection +***********************************************************************/ namespace vl { @@ -100,87 +1078,124 @@ namespace vl { namespace description { - #define _ , - IMPL_CPP_TYPE_INFO(demo::IColorItem) - IMPL_CPP_TYPE_INFO(demo::IViewModel) - IMPL_CPP_TYPE_INFO(demo::ColorBomboItemTemplate) - IMPL_CPP_TYPE_INFO(demo::ColorListItemTemplate) - IMPL_CPP_TYPE_INFO(demo::MainWindow) +#ifndef VCZH_DEBUG_NO_REFLECTION + IMPL_CPP_TYPE_INFO(::demo::ColorBomboItemTemplate) + IMPL_CPP_TYPE_INFO(::demo::ColorBomboItemTemplateConstructor) + IMPL_CPP_TYPE_INFO(::demo::ColorListItemTemplate) + IMPL_CPP_TYPE_INFO(::demo::ColorListItemTemplateConstructor) + IMPL_CPP_TYPE_INFO(::demo::IColorItem) + IMPL_CPP_TYPE_INFO(::demo::IViewModel) + IMPL_CPP_TYPE_INFO(::demo::MainWindow) + IMPL_CPP_TYPE_INFO(::demo::MainWindowConstructor) - BEGIN_CLASS_MEMBER(demo::IColorItem) - CLASS_MEMBER_BASE(::vl::reflection::IDescriptable) - CLASS_MEMBER_METHOD(GetItemName, NO_PARAMETER); - CLASS_MEMBER_METHOD(GetItemColor, NO_PARAMETER); - CLASS_MEMBER_PROPERTY_READONLY(ItemName, GetItemName) - CLASS_MEMBER_PROPERTY_READONLY(ItemColor, GetItemColor) - END_CLASS_MEMBER(demo::IColorItem) - - BEGIN_CLASS_MEMBER(demo::IViewModel) - CLASS_MEMBER_BASE(::vl::reflection::IDescriptable) - CLASS_MEMBER_METHOD(GetColorItems, NO_PARAMETER); - CLASS_MEMBER_PROPERTY_READONLY(ColorItems, GetColorItems) - END_CLASS_MEMBER(demo::IViewModel) - - BEGIN_CLASS_MEMBER(demo::ColorBomboItemTemplate) - CLASS_MEMBER_BASE(::vl::presentation::templates::GuiControlTemplate) - CLASS_MEMBER_CONSTRUCTOR(demo::ColorBomboItemTemplate*(vl::Ptr), { L"ViewModel" }) - - CLASS_MEMBER_PROPERTY_READONLY_FAST(ViewModel) +#define _ , + BEGIN_CLASS_MEMBER(::demo::ColorBomboItemTemplate) + CLASS_MEMBER_METHOD(GetTextColor, NO_PARAMETER) + CLASS_MEMBER_METHOD(GetViewModel, NO_PARAMETER) + CLASS_MEMBER_METHOD(SetTextColor, { L"value" }) CLASS_MEMBER_EVENT(TextColorChanged) - CLASS_MEMBER_PROPERTY_EVENT_FAST(TextColor, TextColorChanged) - END_CLASS_MEMBER(demo::ColorBomboItemTemplate) + CLASS_MEMBER_FIELD(__vwsn_parameter_ViewModel) + CLASS_MEMBER_PROPERTY_EVENT(TextColor, GetTextColor, SetTextColor, TextColorChanged) + CLASS_MEMBER_PROPERTY_READONLY(ViewModel, GetViewModel) + CLASS_MEMBER_FIELD(textColor) + END_CLASS_MEMBER(::demo::ColorBomboItemTemplate) - BEGIN_CLASS_MEMBER(demo::ColorListItemTemplate) - CLASS_MEMBER_BASE(::vl::presentation::templates::GuiTextListItemTemplate) - CLASS_MEMBER_CONSTRUCTOR(demo::ColorListItemTemplate*(vl::Ptr), { L"ViewModel" }) + BEGIN_CLASS_MEMBER(::demo::ColorBomboItemTemplateConstructor) + CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" _ L"__vwsn_resolver_" }) + CLASS_MEMBER_FIELD(__vwsn_precompile_0) + CLASS_MEMBER_FIELD(__vwsn_precompile_1) + CLASS_MEMBER_FIELD(__vwsn_precompile_2) + CLASS_MEMBER_FIELD(__vwsn_precompile_3) + CLASS_MEMBER_FIELD(__vwsn_precompile_4) + CLASS_MEMBER_FIELD(ViewModel) + CLASS_MEMBER_FIELD(self) + END_CLASS_MEMBER(::demo::ColorBomboItemTemplateConstructor) - CLASS_MEMBER_PROPERTY_READONLY_FAST(ViewModel) - END_CLASS_MEMBER(demo::ColorListItemTemplate) + BEGIN_CLASS_MEMBER(::demo::ColorListItemTemplate) + CLASS_MEMBER_METHOD(GetViewModel, NO_PARAMETER) + CLASS_MEMBER_FIELD(__vwsn_parameter_ViewModel) + CLASS_MEMBER_PROPERTY_READONLY(ViewModel, GetViewModel) + END_CLASS_MEMBER(::demo::ColorListItemTemplate) - BEGIN_CLASS_MEMBER(demo::MainWindow) - CLASS_MEMBER_BASE(::vl::presentation::controls::GuiWindow) - CLASS_MEMBER_CONSTRUCTOR(demo::MainWindow*(vl::Ptr), { L"ViewModel" }) + BEGIN_CLASS_MEMBER(::demo::ColorListItemTemplateConstructor) + CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" _ L"__vwsn_resolver_" }) + CLASS_MEMBER_FIELD(__vwsn_precompile_0) + CLASS_MEMBER_FIELD(ViewModel) + CLASS_MEMBER_FIELD(self) + END_CLASS_MEMBER(::demo::ColorListItemTemplateConstructor) - CLASS_MEMBER_PROPERTY_READONLY_FAST(ViewModel) - END_CLASS_MEMBER(demo::MainWindow) + BEGIN_INTERFACE_MEMBER(::demo::IColorItem) + CLASS_MEMBER_METHOD(GetItemColor, NO_PARAMETER) + CLASS_MEMBER_METHOD(GetItemName, NO_PARAMETER) + CLASS_MEMBER_PROPERTY_READONLY(ItemColor, GetItemColor) + CLASS_MEMBER_PROPERTY_READONLY(ItemName, GetItemName) + END_INTERFACE_MEMBER(::demo::IColorItem) - #undef _ + BEGIN_INTERFACE_MEMBER(::demo::IViewModel) + CLASS_MEMBER_METHOD(GetColorItems, NO_PARAMETER) + CLASS_MEMBER_PROPERTY_READONLY(ColorItems, GetColorItems) + END_INTERFACE_MEMBER(::demo::IViewModel) - class DemoResourceLoader : public Object, public ITypeLoader + BEGIN_CLASS_MEMBER(::demo::MainWindow) + CLASS_MEMBER_METHOD(GetViewModel, NO_PARAMETER) + CLASS_MEMBER_FIELD(__vwsn_parameter_ViewModel) + CLASS_MEMBER_PROPERTY_READONLY(ViewModel, GetViewModel) + END_CLASS_MEMBER(::demo::MainWindow) + + BEGIN_CLASS_MEMBER(::demo::MainWindowConstructor) + CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" _ L"__vwsn_resolver_" }) + CLASS_MEMBER_FIELD(__vwsn_precompile_0) + CLASS_MEMBER_FIELD(__vwsn_precompile_1) + CLASS_MEMBER_FIELD(__vwsn_precompile_2) + CLASS_MEMBER_FIELD(__vwsn_precompile_3) + CLASS_MEMBER_FIELD(__vwsn_precompile_4) + CLASS_MEMBER_FIELD(__vwsn_precompile_5) + CLASS_MEMBER_FIELD(__vwsn_precompile_6) + CLASS_MEMBER_FIELD(__vwsn_precompile_7) + CLASS_MEMBER_FIELD(__vwsn_precompile_8) + CLASS_MEMBER_FIELD(ViewModel) + END_CLASS_MEMBER(::demo::MainWindowConstructor) + +#undef _ + class DemoTypeLoader : public Object, public ITypeLoader { public: void Load(ITypeManager* manager) { - ADD_TYPE_INFO(demo::IColorItem) - ADD_TYPE_INFO(demo::IViewModel) - ADD_TYPE_INFO(demo::ColorBomboItemTemplate) - ADD_TYPE_INFO(demo::ColorListItemTemplate) - ADD_TYPE_INFO(demo::MainWindow) + ADD_TYPE_INFO(::demo::ColorBomboItemTemplate) + ADD_TYPE_INFO(::demo::ColorBomboItemTemplateConstructor) + ADD_TYPE_INFO(::demo::ColorListItemTemplate) + ADD_TYPE_INFO(::demo::ColorListItemTemplateConstructor) + ADD_TYPE_INFO(::demo::IColorItem) + ADD_TYPE_INFO(::demo::IViewModel) + ADD_TYPE_INFO(::demo::MainWindow) + ADD_TYPE_INFO(::demo::MainWindowConstructor) } void Unload(ITypeManager* manager) { } }; +#endif - class DemoResourcePlugin : public Object, public vl::presentation::controls::IGuiPlugin + bool LoadDemoTypes() { - public: - void Load()override +#ifndef VCZH_DEBUG_NO_REFLECTION + if (auto manager = GetGlobalTypeManager()) { - GetGlobalTypeManager()->AddTypeLoader(new DemoResourceLoader); + return manager->AddTypeLoader(MakePtr()); } - - void AfterLoad()override - { - } - - void Unload()override - { - } - }; - GUI_REGISTER_PLUGIN(DemoResourcePlugin) +#endif + return false; + } } } } +#if defined( _MSC_VER) +#pragma warning(pop) +#elif defined(__GNUC__) +#pragma GCC diagnostic pop +#elif defined(__clang__) +#pragma clang diagnostic pop +#endif diff --git a/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.h b/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.h index a7395d36..67542fd9 100644 --- a/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.h +++ b/Tutorial/GacUI_Controls/ColorPicker/UI/Source/DemoPartialClasses.h @@ -1,232 +1,222 @@ -/*********************************************************************** -Vczh Library++ 3.0 -Developer: Zihan Chen(vczh) -GacUI::Partial Classes +/*********************************************************************** +!!!!!! DO NOT MODIFY !!!!!! -This file is generated by: Vczh GacUI Resource Code Generator -************************************************************************ -DO NOT MODIFY +GacGen.exe Resource.xml + +This file is generated by Workflow compiler +https://github.com/vczh-libraries ***********************************************************************/ -#ifndef VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo_PARTIAL_CLASSES -#define VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo_PARTIAL_CLASSES +#ifndef VCZH_WORKFLOW_COMPILER_GENERATED_DEMOPARTIALCLASSES +#define VCZH_WORKFLOW_COMPILER_GENERATED_DEMOPARTIALCLASSES -#include "GacUIReflection.h" +#include "GacUI.h" + +#if defined( _MSC_VER) +#pragma warning(push) +#pragma warning(disable:4250) +#elif defined(__GNUC__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wparentheses-equality" +#elif defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wparentheses-equality" +#endif + +namespace vl_workflow_global +{ + class __vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory; + class __vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + class __vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + class __vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + class __vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + class __vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + class __vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + class __vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + class __vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + class __vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory; + struct __vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__; + struct __vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__; + struct __vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__; + struct __vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__; +} namespace demo { + class ColorBomboItemTemplateConstructor; + class ColorBomboItemTemplate; + class ColorListItemTemplateConstructor; + class ColorListItemTemplate; + class MainWindowConstructor; + class MainWindow; class IColorItem; class IViewModel; - class ColorBomboItemTemplate; - class ColorListItemTemplate; - class MainWindow; - class IColorItem : public virtual ::vl::reflection::IDescriptable, public vl::reflection::Description + class ColorBomboItemTemplateConstructor : public ::vl::Object, public ::vl::reflection::Description { + friend class ::vl_workflow_global::__vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend class ::vl_workflow_global::__vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend struct ::vl_workflow_global::__vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__; + friend struct ::vl_workflow_global::__vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__; +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif + protected: + ::vl::Ptr<::demo::IColorItem> ViewModel = ::vl::Ptr<::demo::IColorItem>(); + ::demo::ColorBomboItemTemplate* self = static_cast<::demo::ColorBomboItemTemplate*>(nullptr); + ::vl::presentation::compositions::GuiTableComposition* __vwsn_precompile_0 = static_cast<::vl::presentation::compositions::GuiTableComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_1 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::Ptr<::vl::presentation::elements::GuiSolidBackgroundElement> __vwsn_precompile_2 = ::vl::Ptr<::vl::presentation::elements::GuiSolidBackgroundElement>(); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_3 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::Ptr<::vl::presentation::elements::GuiSolidLabelElement> __vwsn_precompile_4 = ::vl::Ptr<::vl::presentation::elements::GuiSolidLabelElement>(); + void __vwsn_initialize_instance_(::demo::ColorBomboItemTemplate* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_); + public: + ColorBomboItemTemplateConstructor(); + }; + + class ColorBomboItemTemplate : public ::vl::presentation::templates::GuiControlTemplate, public ::demo::ColorBomboItemTemplateConstructor, public ::vl::reflection::Description + { + friend class ::demo::ColorBomboItemTemplateConstructor; + friend class ::vl_workflow_global::__vwsnc1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend class ::vl_workflow_global::__vwsnc3_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc4_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend struct ::vl_workflow_global::__vwsnf1_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__; + friend struct ::vl_workflow_global::__vwsnf2_Demo_demo_ColorBomboItemTemplateConstructor___vwsn_initialize_instance__; +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif + protected: + ::vl::presentation::Color textColor = ::vl::__vwsn::Parse<::vl::presentation::Color>(::vl::WString(L"#000000", false)); + public: + ::vl::Event TextColorChanged; + ::vl::presentation::Color GetTextColor(); + void SetTextColor(::vl::presentation::Color value); + ::vl::Ptr<::demo::IColorItem> __vwsn_parameter_ViewModel = ::vl::Ptr<::demo::IColorItem>(); + ::vl::Ptr<::demo::IColorItem> GetViewModel(); + ColorBomboItemTemplate(::vl::Ptr<::demo::IColorItem> __vwsn_ctor_parameter_ViewModel); + ~ColorBomboItemTemplate(); + }; + + class ColorListItemTemplateConstructor : public ::vl::Object, public ::vl::reflection::Description + { + friend class ::vl_workflow_global::__vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend class ::vl_workflow_global::__vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend struct ::vl_workflow_global::__vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__; + friend struct ::vl_workflow_global::__vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__; +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif + protected: + ::vl::Ptr<::demo::IColorItem> ViewModel = ::vl::Ptr<::demo::IColorItem>(); + ::demo::ColorListItemTemplate* self = static_cast<::demo::ColorListItemTemplate*>(nullptr); + ::demo::ColorBomboItemTemplate* __vwsn_precompile_0 = static_cast<::demo::ColorBomboItemTemplate*>(nullptr); + void __vwsn_initialize_instance_(::demo::ColorListItemTemplate* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_); + public: + ColorListItemTemplateConstructor(); + }; + + class ColorListItemTemplate : public ::vl::presentation::templates::GuiTextListItemTemplate, public ::demo::ColorListItemTemplateConstructor, public ::vl::reflection::Description + { + friend class ::demo::ColorListItemTemplateConstructor; + friend class ::vl_workflow_global::__vwsnc5_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc6_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend class ::vl_workflow_global::__vwsnc7_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance___vl_reflection_description_IValueSubscription; + friend class ::vl_workflow_global::__vwsnc8_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__Subscribe__vl_reflection_description_IValueListener; + friend struct ::vl_workflow_global::__vwsnf3_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__; + friend struct ::vl_workflow_global::__vwsnf4_Demo_demo_ColorListItemTemplateConstructor___vwsn_initialize_instance__; +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif + public: + ::vl::Ptr<::demo::IColorItem> __vwsn_parameter_ViewModel = ::vl::Ptr<::demo::IColorItem>(); + ::vl::Ptr<::demo::IColorItem> GetViewModel(); + ColorListItemTemplate(::vl::Ptr<::demo::IColorItem> __vwsn_ctor_parameter_ViewModel); + ~ColorListItemTemplate(); + }; + + class MainWindowConstructor : public ::vl::Object, public ::vl::reflection::Description + { + friend class ::vl_workflow_global::__vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory; + friend class ::vl_workflow_global::__vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory; +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif + protected: + ::vl::Ptr<::demo::IViewModel> ViewModel = ::vl::Ptr<::demo::IViewModel>(); + ::demo::MainWindow* __vwsn_precompile_0 = static_cast<::demo::MainWindow*>(nullptr); + ::vl::presentation::compositions::GuiTableComposition* __vwsn_precompile_1 = static_cast<::vl::presentation::compositions::GuiTableComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_2 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiLabel* __vwsn_precompile_3 = static_cast<::vl::presentation::controls::GuiLabel*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_4 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiComboBoxListControl* __vwsn_precompile_5 = static_cast<::vl::presentation::controls::GuiComboBoxListControl*>(nullptr); + ::vl::presentation::controls::GuiBindableTextList* __vwsn_precompile_6 = static_cast<::vl::presentation::controls::GuiBindableTextList*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_7 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_8 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + void __vwsn_initialize_instance_(::demo::MainWindow* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_); + public: + MainWindowConstructor(); + }; + + class MainWindow : public ::vl::presentation::controls::GuiWindow, public ::demo::MainWindowConstructor, public ::vl::reflection::Description + { + friend class ::demo::MainWindowConstructor; + friend class ::vl_workflow_global::__vwsnc10_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory; + friend class ::vl_workflow_global::__vwsnc9_Demo_demo_MainWindowConstructor___vwsn_initialize_instance___vl_presentation_templates_GuiTemplate_IFactory; +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif + public: + ::vl::Ptr<::demo::IViewModel> __vwsn_parameter_ViewModel = ::vl::Ptr<::demo::IViewModel>(); + ::vl::Ptr<::demo::IViewModel> GetViewModel(); + MainWindow(::vl::Ptr<::demo::IViewModel> __vwsn_ctor_parameter_ViewModel); + ~MainWindow(); + }; + + class IColorItem : public virtual ::vl::reflection::IDescriptable, public ::vl::reflection::Description + { +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif public: virtual ::vl::WString GetItemName() = 0; virtual ::vl::presentation::Color GetItemColor() = 0; }; - class IViewModel : public virtual ::vl::reflection::IDescriptable, public vl::reflection::Description + class IViewModel : public virtual ::vl::reflection::IDescriptable, public ::vl::reflection::Description { +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif public: - virtual vl::collections::LazyList> GetColorItems() = 0; - }; - - template - class ColorBomboItemTemplate_ : public ::vl::presentation::templates::GuiControlTemplate, public vl::presentation::GuiInstancePartialClass, public vl::reflection::Description - { - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - private: - vl::Ptr ViewModel_; - ::vl::presentation::Color TextColor_; - protected: - ::vl::presentation::templates::GuiControlTemplate* self; - - void InitializeComponents(vl::Ptr ViewModel) - { - ViewModel_ = ViewModel; - if (InitializeFromResource()) - { - GUI_INSTANCE_REFERENCE(self); - } - else - { - ViewModel_ = 0; - } - } - public: - ColorBomboItemTemplate_() - :vl::presentation::GuiInstancePartialClass<::vl::presentation::templates::GuiControlTemplate>(L"demo::ColorBomboItemTemplate") - ,self(0) - { - this->TextColor_ = vl::reflection::description::UnboxValue<::vl::presentation::Color>( - []() - { - vl::reflection::description::Value value; - vl::reflection::description::GetTypeDescriptor<::vl::presentation::Color>()->GetSerializableType()->Deserialize(L"", value); - return value; - }()); - } - - vl::Ptr GetViewModel() - { - return ViewModel_; - } - - vl::Event TextColorChanged; - - ::vl::presentation::Color GetTextColor() - { - return TextColor_; - } - - void SetTextColor(::vl::presentation::Color value) - { - TextColor_ = value; - TextColorChanged(); - } - }; - - template - class ColorListItemTemplate_ : public ::vl::presentation::templates::GuiTextListItemTemplate, public vl::presentation::GuiInstancePartialClass, public vl::reflection::Description - { - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - private: - vl::Ptr ViewModel_; - protected: - ::vl::presentation::templates::GuiTextListItemTemplate* self; - - void InitializeComponents(vl::Ptr ViewModel) - { - ViewModel_ = ViewModel; - if (InitializeFromResource()) - { - GUI_INSTANCE_REFERENCE(self); - } - else - { - ViewModel_ = 0; - } - } - public: - ColorListItemTemplate_() - :vl::presentation::GuiInstancePartialClass<::vl::presentation::templates::GuiTextListItemTemplate>(L"demo::ColorListItemTemplate") - ,self(0) - { - } - - vl::Ptr GetViewModel() - { - return ViewModel_; - } - }; - - template - class MainWindow_ : public ::vl::presentation::controls::GuiWindow, public vl::presentation::GuiInstancePartialClass, public vl::reflection::Description - { - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - private: - vl::Ptr ViewModel_; - protected: - - void InitializeComponents(vl::Ptr ViewModel) - { - ViewModel_ = ViewModel; - if (InitializeFromResource()) - { - } - else - { - ViewModel_ = 0; - } - } - public: - MainWindow_() - :vl::presentation::GuiInstancePartialClass<::vl::presentation::controls::GuiWindow>(L"demo::MainWindow") - ,::vl::presentation::controls::GuiWindow(vl::presentation::theme::GetCurrentTheme()->CreateWindowStyle()) - { - } - - vl::Ptr GetViewModel() - { - return ViewModel_; - } + virtual ::vl::collections::LazyList<::vl::Ptr<::demo::IColorItem>> GetColorItems() = 0; }; } -namespace vl +/*********************************************************************** +Global Variables and Functions +***********************************************************************/ + +namespace vl_workflow_global { - namespace reflection + class Demo { - namespace description - { - DECL_TYPE_INFO(demo::IColorItem) - DECL_TYPE_INFO(demo::IViewModel) - DECL_TYPE_INFO(demo::ColorBomboItemTemplate) - DECL_TYPE_INFO(demo::ColorListItemTemplate) - DECL_TYPE_INFO(demo::MainWindow) - - } - } -} -namespace demo -{ - class ColorBomboItemTemplate : public demo::ColorBomboItemTemplate_ - { - friend class demo::ColorBomboItemTemplate_; - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - protected: - - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) - void OnCreate(); - void OnDestroy(); - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER public: - ColorBomboItemTemplate(vl::Ptr ViewModel); - ~ColorBomboItemTemplate(); + + static Demo& Instance(); }; } - -namespace demo -{ - class ColorListItemTemplate : public demo::ColorListItemTemplate_ - { - friend class demo::ColorListItemTemplate_; - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - protected: - - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) - void OnCreate(); - void OnDestroy(); - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER - public: - ColorListItemTemplate(vl::Ptr ViewModel); - ~ColorListItemTemplate(); - }; -} - - -namespace demo -{ - class MainWindow : public demo::MainWindow_ - { - friend class demo::MainWindow_; - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - protected: - - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) - void OnCreate(); - void OnDestroy(); - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER - public: - MainWindow(vl::Ptr ViewModel); - ~MainWindow(); - }; -} - - +#if defined( _MSC_VER) +#pragma warning(pop) +#elif defined(__GNUC__) +#pragma GCC diagnostic pop +#elif defined(__clang__) +#pragma clang diagnostic pop +#endif #endif diff --git a/Tutorial/GacUI_Controls/ContainersAndButtons/ContainersAndButtons.vcxproj b/Tutorial/GacUI_Controls/ContainersAndButtons/ContainersAndButtons.vcxproj index bf13cfc2..ade9d5c5 100644 --- a/Tutorial/GacUI_Controls/ContainersAndButtons/ContainersAndButtons.vcxproj +++ b/Tutorial/GacUI_Controls/ContainersAndButtons/ContainersAndButtons.vcxproj @@ -53,7 +53,7 @@ Level3 Disabled - WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions) + WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION true @@ -69,7 +69,7 @@ MaxSpeed true true - WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions) + WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION true @@ -91,8 +91,8 @@ - - {8018d622-66ba-4e65-9d03-bdac37ea9a54} + + {96c559ca-9718-4bec-a053-28a0ab6a8ca2} diff --git a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Resource.xml b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Resource.xml index 5bea18d6..41ef5024 100644 --- a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Resource.xml +++ b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Resource.xml @@ -2,14 +2,10 @@ - Source - GacUIReflection.h + Source + ..\..\UIRes\ContainersAndButtons.bin + GacUI.h Demo - - - - ..\..\UIRes - ContainersAndButtons.bin diff --git a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/Demo.h b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/Demo.h index febeba0f..a12c85a4 100644 --- a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/Demo.h +++ b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/Demo.h @@ -1,16 +1,35 @@ -/*********************************************************************** -Vczh Library++ 3.0 -Developer: Zihan Chen(vczh) -GacUI::Demo +/*********************************************************************** +!!!!!! DO NOT MODIFY !!!!!! -This file is generated by: Vczh GacUI Resource Code Generator -************************************************************************ -DO NOT MODIFY +GacGen.exe Resource.xml + +This file is generated by Workflow compiler +https://github.com/vczh-libraries ***********************************************************************/ -#ifndef VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo -#define VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo +#ifndef VCZH_WORKFLOW_COMPILER_GENERATED_DEMO +#define VCZH_WORKFLOW_COMPILER_GENERATED_DEMO #include "DemoPartialClasses.h" +/*********************************************************************** +Reflection +***********************************************************************/ + +namespace vl +{ + namespace reflection + { + namespace description + { +#ifndef VCZH_DEBUG_NO_REFLECTION + DECL_TYPE_INFO(::demo::MainWindow) + DECL_TYPE_INFO(::demo::MainWindowConstructor) +#endif + + extern bool LoadDemoTypes(); + } + } +} + #endif diff --git a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.cpp b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.cpp index 1967f719..8cb61405 100644 --- a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.cpp +++ b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.cpp @@ -1,42 +1,647 @@ -/*********************************************************************** -Vczh Library++ 3.0 -Developer: Zihan Chen(vczh) -GacUI::Partial Classes +/*********************************************************************** +!!!!!! DO NOT MODIFY !!!!!! -This file is generated by: Vczh GacUI Resource Code Generator -************************************************************************ -DO NOT MODIFY +GacGen.exe Resource.xml + +This file is generated by Workflow compiler +https://github.com/vczh-libraries ***********************************************************************/ #include "Demo.h" +#if defined( _MSC_VER) +#pragma warning(push) +#pragma warning(disable:4250) +#elif defined(__GNUC__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wparentheses-equality" +#elif defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wparentheses-equality" +#endif + +#define GLOBAL_SYMBOL ::vl_workflow_global::Demo:: +#define GLOBAL_NAME ::vl_workflow_global::Demo::Instance(). +#define GLOBAL_OBJ &::vl_workflow_global::Demo::Instance() +#define USERIMPL(...) + +/*********************************************************************** +Global Variables +***********************************************************************/ + +BEGIN_GLOBAL_STORAGE_CLASS(vl_workflow_global_Demo) + vl_workflow_global::Demo instance; + INITIALIZE_GLOBAL_STORAGE_CLASS + FINALIZE_GLOBAL_STORAGE_CLASS +END_GLOBAL_STORAGE_CLASS(vl_workflow_global_Demo) + +namespace vl_workflow_global +{ +/*********************************************************************** +Global Functions +***********************************************************************/ + + Demo& Demo::Instance() + { + return Getvl_workflow_global_Demo().instance; + } +} + +/*********************************************************************** +Class (::demo::MainWindowConstructor) +***********************************************************************/ + namespace demo { - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) + void MainWindowConstructor::__vwsn_initialize_instance_(::demo::MainWindow* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_) + { + (::vl::__vwsn::This(this)->__vwsn_precompile_0 = __vwsn_this_); + (::vl::__vwsn::This(this)->__vwsn_precompile_75 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_75)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 480; __vwsn_temp__.y = 320; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetClientSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 480; __vwsn_temp__.y = 320; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->SetText(::vl::WString(L"ContainersAndButtons", false)); + } + (::vl::__vwsn::This(this)->radioGroup = new ::vl::presentation::controls::GuiSelectableButton::MutexGroupController()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->AddComponent(::vl::__vwsn::Ensure(static_cast<::vl::presentation::controls::GuiComponent*>(::vl::__vwsn::This(this)->radioGroup))); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateTabStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_1 = new ::vl::presentation::controls::GuiTab(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_74 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_74)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 3; __vwsn_temp__.top = 3; __vwsn_temp__.right = 3; __vwsn_temp__.bottom = 3; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_2 = new ::vl::presentation::controls::GuiTabPage()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_2)->SetText(::vl::WString(L"GroupBox", false)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_3 = new ::vl::presentation::compositions::GuiTableComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetCellPadding(::vl::__vwsn::Parse<::vl::vint32_t>(::vl::WString(L"5", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetRowsAndColumns(1, 3); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetRowOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetColumnOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetColumnOption(1, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->SetColumnOption(2, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::Percentage; __vwsn_temp__.percentage = 1.0; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_4 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_4)->SetSite(0, 0, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateGroupBoxStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_5 = new ::vl::presentation::controls::GuiControl(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_16 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_16)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->SetText(::vl::WString(L"Button", false)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_6 = new ::vl::presentation::compositions::GuiStackComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetDirection(::vl::presentation::compositions::GuiStackComposition::Direction::Vertical); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetPadding(::vl::__vwsn::Parse<::vl::vint32_t>(::vl::WString(L"5", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 5; __vwsn_temp__.top = 5; __vwsn_temp__.right = 5; __vwsn_temp__.bottom = 5; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_7 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_8 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_9 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_8)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_9)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_8)->SetText(::vl::WString(L"Button 1", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_7)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_8)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_7))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_10 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_11 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_12 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_11)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_12)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_11)->SetText(::vl::WString(L"Button 2", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_10)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_11)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_10))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_13 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_14 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_15 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_14)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_15)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_14)->SetText(::vl::WString(L"Button 3", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_13)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_14)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_6)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_13))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->GetContainerComposition())->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_6))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_4)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_5)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_4))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_17 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_17)->SetSite(0, 1, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateGroupBoxStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_18 = new ::vl::presentation::controls::GuiControl(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_29 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_18)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_29)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_18)->SetText(::vl::WString(L"CheckBox", false)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_19 = new ::vl::presentation::compositions::GuiStackComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_19)->SetDirection(::vl::presentation::compositions::GuiStackComposition::Direction::Vertical); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_19)->SetPadding(::vl::__vwsn::Parse<::vl::vint32_t>(::vl::WString(L"5", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_19)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 5; __vwsn_temp__.top = 5; __vwsn_temp__.right = 5; __vwsn_temp__.bottom = 5; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_20 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateCheckBoxStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_21 = new ::vl::presentation::controls::GuiSelectableButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_22 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_21)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_22)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_21)->SetText(::vl::WString(L"Button 1", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_20)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_21)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_19)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_20))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_23 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateCheckBoxStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_24 = new ::vl::presentation::controls::GuiSelectableButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_25 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_24)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_25)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_24)->SetText(::vl::WString(L"Button 2", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_23)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_24)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_19)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_23))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_26 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateCheckBoxStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_27 = new ::vl::presentation::controls::GuiSelectableButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_28 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_27)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_28)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_27)->SetText(::vl::WString(L"Button 3", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_26)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_27)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_19)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_26))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_18)->GetContainerComposition())->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_19))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_17)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_18)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_17))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_30 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_30)->SetSite(0, 2, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateGroupBoxStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_31 = new ::vl::presentation::controls::GuiControl(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_42 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_31)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_42)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_31)->SetText(::vl::WString(L"RadioButton", false)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_32 = new ::vl::presentation::compositions::GuiStackComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_32)->SetDirection(::vl::presentation::compositions::GuiStackComposition::Direction::Vertical); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_32)->SetPadding(::vl::__vwsn::Parse<::vl::vint32_t>(::vl::WString(L"5", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_32)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 5; __vwsn_temp__.top = 5; __vwsn_temp__.right = 5; __vwsn_temp__.bottom = 5; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_33 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateRadioButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_34 = new ::vl::presentation::controls::GuiSelectableButton(__vwsn_controlStyle_)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_34)->SetSelected(::vl::__vwsn::Parse(::vl::WString(L"true", false))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_35 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_34)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_35)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_34)->SetText(::vl::WString(L"Button 1", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_33)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_34)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_32)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_33))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_36 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateRadioButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_37 = new ::vl::presentation::controls::GuiSelectableButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_38 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_37)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_38)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_37)->SetText(::vl::WString(L"Button 2", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_36)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_37)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_32)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_36))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_39 = new ::vl::presentation::compositions::GuiStackItemComposition()); + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateRadioButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_40 = new ::vl::presentation::controls::GuiSelectableButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_41 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_40)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_41)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 0; __vwsn_temp__.top = 0; __vwsn_temp__.right = 0; __vwsn_temp__.bottom = 0; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_40)->SetText(::vl::WString(L"Button 3", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_39)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_40)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_32)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_39))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_31)->GetContainerComposition())->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_32))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_30)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_31)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_3)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_30))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_2)->GetContainerComposition())->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_3))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->CreatePage(::vl::__vwsn::This(this)->__vwsn_precompile_2, -1); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_43 = new ::vl::presentation::controls::GuiTabPage()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_43)->SetText(::vl::WString(L"ScrollContainer", false)); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateScrollContainerStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_44 = new ::vl::presentation::controls::GuiScrollContainer(__vwsn_controlStyle_)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_44)->SetVerticalAlwaysVisible(::vl::__vwsn::Parse(::vl::WString(L"false", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_44)->SetHorizontalAlwaysVisible(::vl::__vwsn::Parse(::vl::WString(L"false", false))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_73 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_44)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_73)->SetAlignmentToParent([&](){ ::vl::presentation::Margin __vwsn_temp__; __vwsn_temp__.left = 5; __vwsn_temp__.top = 5; __vwsn_temp__.right = 5; __vwsn_temp__.bottom = 5; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_45 = new ::vl::presentation::compositions::GuiTableComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetCellPadding(::vl::__vwsn::Parse<::vl::vint32_t>(::vl::WString(L"10", false))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetRowsAndColumns(3, 3); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetRowOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetRowOption(1, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetRowOption(2, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetColumnOption(0, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetColumnOption(1, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->SetColumnOption(2, [&](){ ::vl::presentation::compositions::GuiCellOption __vwsn_temp__; __vwsn_temp__.composeType = ::vl::presentation::compositions::GuiCellOption::ComposeType::MinSize; return __vwsn_temp__; }()); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_46 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_46)->SetSite(0, 0, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_47 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_48 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_47)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_48)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_47)->SetText(::vl::WString(L"(0, 0)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_46)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_47)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_46))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_49 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_49)->SetSite(0, 1, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_50 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_51 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_50)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_51)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_50)->SetText(::vl::WString(L"(0, 1)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_49)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_50)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_49))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_52 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_52)->SetSite(0, 2, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_53 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_54 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_53)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_54)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_53)->SetText(::vl::WString(L"(0, 0)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_52)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_53)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_52))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_55 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_55)->SetSite(1, 0, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_56 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_57 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_56)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_57)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_56)->SetText(::vl::WString(L"(1, 0)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_55)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_56)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_55))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_58 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_58)->SetSite(1, 1, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_59 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_60 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_59)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_60)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_59)->SetText(::vl::WString(L"(1, 1)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_58)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_59)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_58))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_61 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_61)->SetSite(1, 2, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_62 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_63 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_62)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_63)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_62)->SetText(::vl::WString(L"(1, 0)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_61)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_62)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_61))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_64 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_64)->SetSite(2, 0, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_65 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_66 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_65)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_66)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_65)->SetText(::vl::WString(L"(2, 0)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_64)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_65)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_64))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_67 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_67)->SetSite(2, 1, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_68 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_69 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_68)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_69)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_68)->SetText(::vl::WString(L"(2, 1)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_67)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_68)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_67))); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_70 = new ::vl::presentation::compositions::GuiCellComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_70)->SetSite(2, 2, 1, 1); + } + { + auto __vwsn_controlStyle_ = ::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateButtonStyle(); + (::vl::__vwsn::This(this)->__vwsn_precompile_71 = new ::vl::presentation::controls::GuiButton(__vwsn_controlStyle_)); + } + (::vl::__vwsn::This(this)->__vwsn_precompile_72 = ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_71)->GetBoundsComposition()); + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_72)->SetPreferredMinSize([&](){ ::vl::presentation::Size __vwsn_temp__; __vwsn_temp__.x = 160; __vwsn_temp__.y = 160; return __vwsn_temp__; }()); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_71)->SetText(::vl::WString(L"(2, 0)", false)); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_70)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_71)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_45)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_70))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_44)->GetContainerComposition())->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(this)->__vwsn_precompile_45))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_43)->GetContainerComposition())->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::compositions::GuiGraphicsComposition*>(::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_44)->GetBoundsComposition()))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_1)->CreatePage(::vl::__vwsn::This(this)->__vwsn_precompile_43, -1); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_0)->AddChild(::vl::__vwsn::Ensure(static_cast<::vl::presentation::controls::GuiControl*>(::vl::__vwsn::This(this)->__vwsn_precompile_1))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_34)->SetGroupController(::vl::__vwsn::Ensure(static_cast<::vl::presentation::controls::GuiSelectableButton::GroupController*>(::vl::__vwsn::This(this)->radioGroup))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_37)->SetGroupController(::vl::__vwsn::Ensure(static_cast<::vl::presentation::controls::GuiSelectableButton::GroupController*>(::vl::__vwsn::This(this)->radioGroup))); + } + { + ::vl::__vwsn::This(::vl::__vwsn::This(this)->__vwsn_precompile_40)->SetGroupController(::vl::__vwsn::Ensure(static_cast<::vl::presentation::controls::GuiSelectableButton::GroupController*>(::vl::__vwsn::This(this)->radioGroup))); + } + } - void MainWindow::OnCreate() + MainWindowConstructor::MainWindowConstructor() { } - void MainWindow::OnDestroy() - { - } - - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER +/*********************************************************************** +Class (::demo::MainWindow) +***********************************************************************/ MainWindow::MainWindow() + : ::vl::presentation::controls::GuiWindow(::vl::__vwsn::This(::vl::presentation::theme::GetCurrentTheme())->CreateWindowStyle()) { - InitializeComponents(); - OnCreate(); + auto __vwsn_resource_ = ::vl::__vwsn::This(::vl::presentation::GetResourceManager())->GetResourceFromClassName(::vl::WString(L"demo::MainWindow", false)); + auto __vwsn_resolver_ = ::vl::Ptr<::vl::presentation::GuiResourcePathResolver>(new ::vl::presentation::GuiResourcePathResolver(__vwsn_resource_, ::vl::__vwsn::This(__vwsn_resource_.Obj())->GetWorkingDirectory())); + ::vl::__vwsn::This(this)->__vwsn_initialize_instance_(this, ::vl::__vwsn::Ensure(static_cast<::vl::presentation::GuiResourcePathResolver*>(__vwsn_resolver_.Obj()))); } MainWindow::~MainWindow() { - OnDestroy(); - ClearSubscriptions(); + ::vl::__vwsn::This(this)->ClearSubscriptions(); } -} +} +#undef GLOBAL_SYMBOL +#undef GLOBAL_NAME +#undef GLOBAL_OBJ +#undef USERIMPL + +/*********************************************************************** +Reflection +***********************************************************************/ namespace vl { @@ -44,47 +649,129 @@ namespace vl { namespace description { - #define _ , - IMPL_CPP_TYPE_INFO(demo::MainWindow) +#ifndef VCZH_DEBUG_NO_REFLECTION + IMPL_CPP_TYPE_INFO(::demo::MainWindow) + IMPL_CPP_TYPE_INFO(::demo::MainWindowConstructor) - BEGIN_CLASS_MEMBER(demo::MainWindow) - CLASS_MEMBER_BASE(::vl::presentation::controls::GuiWindow) - CLASS_MEMBER_CONSTRUCTOR(demo::MainWindow*(), NO_PARAMETER) - END_CLASS_MEMBER(demo::MainWindow) +#define _ , + BEGIN_CLASS_MEMBER(::demo::MainWindow) + END_CLASS_MEMBER(::demo::MainWindow) - #undef _ + BEGIN_CLASS_MEMBER(::demo::MainWindowConstructor) + CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" _ L"__vwsn_resolver_" }) + CLASS_MEMBER_FIELD(__vwsn_precompile_0) + CLASS_MEMBER_FIELD(__vwsn_precompile_1) + CLASS_MEMBER_FIELD(__vwsn_precompile_10) + CLASS_MEMBER_FIELD(__vwsn_precompile_11) + CLASS_MEMBER_FIELD(__vwsn_precompile_12) + CLASS_MEMBER_FIELD(__vwsn_precompile_13) + CLASS_MEMBER_FIELD(__vwsn_precompile_14) + CLASS_MEMBER_FIELD(__vwsn_precompile_15) + CLASS_MEMBER_FIELD(__vwsn_precompile_16) + CLASS_MEMBER_FIELD(__vwsn_precompile_17) + CLASS_MEMBER_FIELD(__vwsn_precompile_18) + CLASS_MEMBER_FIELD(__vwsn_precompile_19) + CLASS_MEMBER_FIELD(__vwsn_precompile_2) + CLASS_MEMBER_FIELD(__vwsn_precompile_20) + CLASS_MEMBER_FIELD(__vwsn_precompile_21) + CLASS_MEMBER_FIELD(__vwsn_precompile_22) + CLASS_MEMBER_FIELD(__vwsn_precompile_23) + CLASS_MEMBER_FIELD(__vwsn_precompile_24) + CLASS_MEMBER_FIELD(__vwsn_precompile_25) + CLASS_MEMBER_FIELD(__vwsn_precompile_26) + CLASS_MEMBER_FIELD(__vwsn_precompile_27) + CLASS_MEMBER_FIELD(__vwsn_precompile_28) + CLASS_MEMBER_FIELD(__vwsn_precompile_29) + CLASS_MEMBER_FIELD(__vwsn_precompile_3) + CLASS_MEMBER_FIELD(__vwsn_precompile_30) + CLASS_MEMBER_FIELD(__vwsn_precompile_31) + CLASS_MEMBER_FIELD(__vwsn_precompile_32) + CLASS_MEMBER_FIELD(__vwsn_precompile_33) + CLASS_MEMBER_FIELD(__vwsn_precompile_34) + CLASS_MEMBER_FIELD(__vwsn_precompile_35) + CLASS_MEMBER_FIELD(__vwsn_precompile_36) + CLASS_MEMBER_FIELD(__vwsn_precompile_37) + CLASS_MEMBER_FIELD(__vwsn_precompile_38) + CLASS_MEMBER_FIELD(__vwsn_precompile_39) + CLASS_MEMBER_FIELD(__vwsn_precompile_4) + CLASS_MEMBER_FIELD(__vwsn_precompile_40) + CLASS_MEMBER_FIELD(__vwsn_precompile_41) + CLASS_MEMBER_FIELD(__vwsn_precompile_42) + CLASS_MEMBER_FIELD(__vwsn_precompile_43) + CLASS_MEMBER_FIELD(__vwsn_precompile_44) + CLASS_MEMBER_FIELD(__vwsn_precompile_45) + CLASS_MEMBER_FIELD(__vwsn_precompile_46) + CLASS_MEMBER_FIELD(__vwsn_precompile_47) + CLASS_MEMBER_FIELD(__vwsn_precompile_48) + CLASS_MEMBER_FIELD(__vwsn_precompile_49) + CLASS_MEMBER_FIELD(__vwsn_precompile_5) + CLASS_MEMBER_FIELD(__vwsn_precompile_50) + CLASS_MEMBER_FIELD(__vwsn_precompile_51) + CLASS_MEMBER_FIELD(__vwsn_precompile_52) + CLASS_MEMBER_FIELD(__vwsn_precompile_53) + CLASS_MEMBER_FIELD(__vwsn_precompile_54) + CLASS_MEMBER_FIELD(__vwsn_precompile_55) + CLASS_MEMBER_FIELD(__vwsn_precompile_56) + CLASS_MEMBER_FIELD(__vwsn_precompile_57) + CLASS_MEMBER_FIELD(__vwsn_precompile_58) + CLASS_MEMBER_FIELD(__vwsn_precompile_59) + CLASS_MEMBER_FIELD(__vwsn_precompile_6) + CLASS_MEMBER_FIELD(__vwsn_precompile_60) + CLASS_MEMBER_FIELD(__vwsn_precompile_61) + CLASS_MEMBER_FIELD(__vwsn_precompile_62) + CLASS_MEMBER_FIELD(__vwsn_precompile_63) + CLASS_MEMBER_FIELD(__vwsn_precompile_64) + CLASS_MEMBER_FIELD(__vwsn_precompile_65) + CLASS_MEMBER_FIELD(__vwsn_precompile_66) + CLASS_MEMBER_FIELD(__vwsn_precompile_67) + CLASS_MEMBER_FIELD(__vwsn_precompile_68) + CLASS_MEMBER_FIELD(__vwsn_precompile_69) + CLASS_MEMBER_FIELD(__vwsn_precompile_7) + CLASS_MEMBER_FIELD(__vwsn_precompile_70) + CLASS_MEMBER_FIELD(__vwsn_precompile_71) + CLASS_MEMBER_FIELD(__vwsn_precompile_72) + CLASS_MEMBER_FIELD(__vwsn_precompile_73) + CLASS_MEMBER_FIELD(__vwsn_precompile_74) + CLASS_MEMBER_FIELD(__vwsn_precompile_75) + CLASS_MEMBER_FIELD(__vwsn_precompile_8) + CLASS_MEMBER_FIELD(__vwsn_precompile_9) + CLASS_MEMBER_FIELD(radioGroup) + END_CLASS_MEMBER(::demo::MainWindowConstructor) - class DemoResourceLoader : public Object, public ITypeLoader +#undef _ + class DemoTypeLoader : public Object, public ITypeLoader { public: void Load(ITypeManager* manager) { - ADD_TYPE_INFO(demo::MainWindow) + ADD_TYPE_INFO(::demo::MainWindow) + ADD_TYPE_INFO(::demo::MainWindowConstructor) } void Unload(ITypeManager* manager) { } }; +#endif - class DemoResourcePlugin : public Object, public vl::presentation::controls::IGuiPlugin + bool LoadDemoTypes() { - public: - void Load()override +#ifndef VCZH_DEBUG_NO_REFLECTION + if (auto manager = GetGlobalTypeManager()) { - GetGlobalTypeManager()->AddTypeLoader(new DemoResourceLoader); + return manager->AddTypeLoader(MakePtr()); } - - void AfterLoad()override - { - } - - void Unload()override - { - } - }; - GUI_REGISTER_PLUGIN(DemoResourcePlugin) +#endif + return false; + } } } } +#if defined( _MSC_VER) +#pragma warning(pop) +#elif defined(__GNUC__) +#pragma GCC diagnostic pop +#elif defined(__clang__) +#pragma clang diagnostic pop +#endif diff --git a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.h b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.h index 57388f71..5fc5126a 100644 --- a/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.h +++ b/Tutorial/GacUI_Controls/ContainersAndButtons/UI/Source/DemoPartialClasses.h @@ -1,79 +1,153 @@ -/*********************************************************************** -Vczh Library++ 3.0 -Developer: Zihan Chen(vczh) -GacUI::Partial Classes +/*********************************************************************** +!!!!!! DO NOT MODIFY !!!!!! -This file is generated by: Vczh GacUI Resource Code Generator -************************************************************************ -DO NOT MODIFY +GacGen.exe Resource.xml + +This file is generated by Workflow compiler +https://github.com/vczh-libraries ***********************************************************************/ -#ifndef VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo_PARTIAL_CLASSES -#define VCZH_GACUI_RESOURCE_CODE_GENERATOR_Demo_PARTIAL_CLASSES +#ifndef VCZH_WORKFLOW_COMPILER_GENERATED_DEMOPARTIALCLASSES +#define VCZH_WORKFLOW_COMPILER_GENERATED_DEMOPARTIALCLASSES -#include "GacUIReflection.h" +#include "GacUI.h" + +#if defined( _MSC_VER) +#pragma warning(push) +#pragma warning(disable:4250) +#elif defined(__GNUC__) +#pragma GCC diagnostic push +#pragma GCC diagnostic ignored "-Wparentheses-equality" +#elif defined(__clang__) +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wparentheses-equality" +#endif namespace demo { + class MainWindowConstructor; class MainWindow; - template - class MainWindow_ : public ::vl::presentation::controls::GuiWindow, public vl::presentation::GuiInstancePartialClass, public vl::reflection::Description + class MainWindowConstructor : public ::vl::Object, public ::vl::reflection::Description { - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - private: +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif protected: - ::vl::presentation::controls::GuiSelectableButton::MutexGroupController* radioGroup; - - void InitializeComponents() - { - if (InitializeFromResource()) - { - GUI_INSTANCE_REFERENCE(radioGroup); - } - else - { - } - } + ::vl::presentation::controls::GuiSelectableButton::MutexGroupController* radioGroup = static_cast<::vl::presentation::controls::GuiSelectableButton::MutexGroupController*>(nullptr); + ::demo::MainWindow* __vwsn_precompile_0 = static_cast<::demo::MainWindow*>(nullptr); + ::vl::presentation::controls::GuiTab* __vwsn_precompile_1 = static_cast<::vl::presentation::controls::GuiTab*>(nullptr); + ::vl::presentation::controls::GuiTabPage* __vwsn_precompile_2 = static_cast<::vl::presentation::controls::GuiTabPage*>(nullptr); + ::vl::presentation::compositions::GuiTableComposition* __vwsn_precompile_3 = static_cast<::vl::presentation::compositions::GuiTableComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_4 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiControl* __vwsn_precompile_5 = static_cast<::vl::presentation::controls::GuiControl*>(nullptr); + ::vl::presentation::compositions::GuiStackComposition* __vwsn_precompile_6 = static_cast<::vl::presentation::compositions::GuiStackComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_7 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_8 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_9 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_10 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_11 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_12 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_13 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_14 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_15 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_16 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_17 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiControl* __vwsn_precompile_18 = static_cast<::vl::presentation::controls::GuiControl*>(nullptr); + ::vl::presentation::compositions::GuiStackComposition* __vwsn_precompile_19 = static_cast<::vl::presentation::compositions::GuiStackComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_20 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiSelectableButton* __vwsn_precompile_21 = static_cast<::vl::presentation::controls::GuiSelectableButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_22 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_23 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiSelectableButton* __vwsn_precompile_24 = static_cast<::vl::presentation::controls::GuiSelectableButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_25 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_26 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiSelectableButton* __vwsn_precompile_27 = static_cast<::vl::presentation::controls::GuiSelectableButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_28 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_29 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_30 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiControl* __vwsn_precompile_31 = static_cast<::vl::presentation::controls::GuiControl*>(nullptr); + ::vl::presentation::compositions::GuiStackComposition* __vwsn_precompile_32 = static_cast<::vl::presentation::compositions::GuiStackComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_33 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiSelectableButton* __vwsn_precompile_34 = static_cast<::vl::presentation::controls::GuiSelectableButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_35 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_36 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiSelectableButton* __vwsn_precompile_37 = static_cast<::vl::presentation::controls::GuiSelectableButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_38 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiStackItemComposition* __vwsn_precompile_39 = static_cast<::vl::presentation::compositions::GuiStackItemComposition*>(nullptr); + ::vl::presentation::controls::GuiSelectableButton* __vwsn_precompile_40 = static_cast<::vl::presentation::controls::GuiSelectableButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_41 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_42 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::controls::GuiTabPage* __vwsn_precompile_43 = static_cast<::vl::presentation::controls::GuiTabPage*>(nullptr); + ::vl::presentation::controls::GuiScrollContainer* __vwsn_precompile_44 = static_cast<::vl::presentation::controls::GuiScrollContainer*>(nullptr); + ::vl::presentation::compositions::GuiTableComposition* __vwsn_precompile_45 = static_cast<::vl::presentation::compositions::GuiTableComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_46 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_47 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_48 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_49 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_50 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_51 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_52 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_53 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_54 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_55 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_56 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_57 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_58 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_59 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_60 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_61 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_62 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_63 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_64 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_65 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_66 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_67 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_68 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_69 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiCellComposition* __vwsn_precompile_70 = static_cast<::vl::presentation::compositions::GuiCellComposition*>(nullptr); + ::vl::presentation::controls::GuiButton* __vwsn_precompile_71 = static_cast<::vl::presentation::controls::GuiButton*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_72 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_73 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_74 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + ::vl::presentation::compositions::GuiBoundsComposition* __vwsn_precompile_75 = static_cast<::vl::presentation::compositions::GuiBoundsComposition*>(nullptr); + void __vwsn_initialize_instance_(::demo::MainWindow* __vwsn_this_, ::vl::presentation::GuiResourcePathResolver* __vwsn_resolver_); public: - MainWindow_() - :vl::presentation::GuiInstancePartialClass<::vl::presentation::controls::GuiWindow>(L"demo::MainWindow") - ,::vl::presentation::controls::GuiWindow(vl::presentation::theme::GetCurrentTheme()->CreateWindowStyle()) - ,radioGroup(0) - { - } + MainWindowConstructor(); }; -} -namespace vl -{ - namespace reflection + class MainWindow : public ::vl::presentation::controls::GuiWindow, public ::demo::MainWindowConstructor, public ::vl::reflection::Description { - namespace description - { - DECL_TYPE_INFO(demo::MainWindow) - - } - } -} -namespace demo -{ - class MainWindow : public demo::MainWindow_ - { - friend class demo::MainWindow_; - friend struct vl::reflection::description::CustomTypeDescriptorSelector; - protected: - - // #region CLASS_MEMBER_GUIEVENT_HANDLER (DO NOT PUT OTHER CONTENT IN THIS #region.) - void OnCreate(); - void OnDestroy(); - // #endregion CLASS_MEMBER_GUIEVENT_HANDLER + friend class ::demo::MainWindowConstructor; +#ifndef VCZH_DEBUG_NO_REFLECTION + friend struct ::vl::reflection::description::CustomTypeDescriptorSelector; +#endif public: MainWindow(); ~MainWindow(); }; + +} +/*********************************************************************** +Global Variables and Functions +***********************************************************************/ + +namespace vl_workflow_global +{ + class Demo + { + public: + + static Demo& Instance(); + }; } - +#if defined( _MSC_VER) +#pragma warning(pop) +#elif defined(__GNUC__) +#pragma GCC diagnostic pop +#elif defined(__clang__) +#pragma clang diagnostic pop +#endif #endif diff --git a/Tutorial/GacUI_Controls/UIRes/ColorPicker.bin b/Tutorial/GacUI_Controls/UIRes/ColorPicker.bin index 12ef6a9f..a421f56c 100644 Binary files a/Tutorial/GacUI_Controls/UIRes/ColorPicker.bin and b/Tutorial/GacUI_Controls/UIRes/ColorPicker.bin differ diff --git a/Tutorial/GacUI_Controls/UIRes/ContainersAndButtons.bin b/Tutorial/GacUI_Controls/UIRes/ContainersAndButtons.bin index 0c1b7b6d..115e982a 100644 Binary files a/Tutorial/GacUI_Controls/UIRes/ContainersAndButtons.bin and b/Tutorial/GacUI_Controls/UIRes/ContainersAndButtons.bin differ