Demo: GacUI_Layout\Responsive2

This commit is contained in:
Zihan Chen
2018-04-02 03:16:59 -07:00
parent 1edb89999c
commit 6809a9221e
20 changed files with 3752 additions and 0 deletions
+10
View File
@@ -21,6 +21,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "TableSplitter", "TableSplit
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Responsive1", "Responsive1\Responsive1.vcxproj", "{B7E80D3D-6357-484C-A98F-17B6D6ABABF5}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Responsive2", "Responsive2\Responsive2.vcxproj", "{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Win32 = Debug|Win32
@@ -79,6 +81,14 @@ Global
{B7E80D3D-6357-484C-A98F-17B6D6ABABF5}.Release|Win32.Build.0 = Release|Win32
{B7E80D3D-6357-484C-A98F-17B6D6ABABF5}.Release|x64.ActiveCfg = Release|x64
{B7E80D3D-6357-484C-A98F-17B6D6ABABF5}.Release|x64.Build.0 = Release|x64
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Debug|Win32.ActiveCfg = Debug|Win32
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Debug|Win32.Build.0 = Debug|Win32
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Debug|x64.ActiveCfg = Debug|x64
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Debug|x64.Build.0 = Debug|x64
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Release|Win32.ActiveCfg = Release|Win32
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Release|Win32.Build.0 = Release|Win32
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Release|x64.ActiveCfg = Release|x64
{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}.Release|x64.Build.0 = Release|x64
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@@ -0,0 +1,18 @@
#define GAC_HEADER_USE_NAMESPACE
#include "UI/Source/Demo.h"
#include <Windows.h>
using namespace vl::collections;
using namespace vl::stream;
void GuiMain()
{
{
FileStream fileStream(L"../UIRes/Responsive2.bin", FileStream::ReadOnly);
auto resource = GuiResource::LoadPrecompiledBinary(fileStream);
GetResourceManager()->SetResource(L"Resource", resource);
}
demo::MainWindow window;
window.MoveToScreenCenter();
GetApplication()->Run(&window);
}
@@ -0,0 +1,172 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<ClCompile Include="Main.cpp" />
<ClCompile Include="UI\Source\DemoPartialClasses.cpp" />
</ItemGroup>
<ItemGroup>
<Xml Include="UI\Resource.xml" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="UI\Source\Demo.h" />
<ClInclude Include="UI\Source\DemoPartialClasses.h" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\Lib\GacUILite\GacUILite.vcxproj">
<Project>{96c559ca-9718-4bec-a053-28a0ab6a8ca2}</Project>
</ProjectReference>
</ItemGroup>
<PropertyGroup Label="Globals">
<VCProjectVersion>15.0</VCProjectVersion>
<ProjectGuid>{747D66CE-7F4C-44A0-BE17-99C23C8AC55F}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>Responsive2</RootNamespace>
<WindowsTargetPlatformVersion>10.0.16299.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<PlatformToolset>v141</PlatformToolset>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="Shared">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
<IncludePath>$(ProjectDir)..\..\..\Import;$(IncludePath)</IncludePath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<LinkIncremental>true</LinkIncremental>
<IncludePath>$(ProjectDir)..\..\..\Import;$(IncludePath)</IncludePath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<IncludePath>$(ProjectDir)..\..\..\Import;$(IncludePath)</IncludePath>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<LinkIncremental>false</LinkIncremental>
<IncludePath>$(ProjectDir)..\..\..\Import;$(IncludePath)</IncludePath>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>_DEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<SDLCheck>true</SDLCheck>
<PreprocessorDefinitions>NDEBUG;_WINDOWS;%(PreprocessorDefinitions);VCZH_DEBUG_NO_REFLECTION</PreprocessorDefinitions>
<ConformanceMode>true</ConformanceMode>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>
@@ -0,0 +1,41 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hh;hpp;hxx;hm;inl;inc;xsd</Extensions>
</Filter>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
<Filter Include="UI">
<UniqueIdentifier>{3de35dbb-5a4f-40c2-989f-b5fe4f9e2856}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="Main.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="UI\Source\DemoPartialClasses.cpp">
<Filter>UI</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<Xml Include="UI\Resource.xml">
<Filter>Resource Files</Filter>
</Xml>
</ItemGroup>
<ItemGroup>
<ClInclude Include="UI\Source\DemoPartialClasses.h">
<Filter>UI</Filter>
</ClInclude>
<ClInclude Include="UI\Source\Demo.h">
<Filter>UI</Filter>
</ClInclude>
</ItemGroup>
</Project>
Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 46 KiB

@@ -0,0 +1,259 @@
<?xml version="1.0" encoding="utf-8"?>
<Resource>
<Folder name="GacGenConfig">
<Folder name="Cpp">
<Text name="SourceFolder">Source</Text>
<Text name="Resource">..\..\UIRes\Responsive2.bin</Text>
<Text name="NormalInclude">GacUI.h</Text>
<Text name="Name">Demo</Text>
</Folder>
</Folder>
<Folder name="Images">
<Image name="_1" content="File">Images/1.png</Image>
<Image name="_2" content="File">Images/2.png</Image>
<Image name="_3" content="File">Images/3.png</Image>
<Image name="_4" content="File">Images/4.png</Image>
<Image name="_5" content="File">Images/5.png</Image>
<Image name="_6" content="File">Images/6.png</Image>
<Image name="_7" content="File">Images/7.png</Image>
<Image name="_8" content="File">Images/8.png</Image>
<Image name="Video" content="File">Images/Video.png</Image>
</Folder>
<Script name="ViewModelScript">
<Workflow>
<![CDATA[
module viewmodel;
using presentation::*;
using presentation::controls::*;
namespace demo
{
class AccountButtonViewModel
{
prop Controller: GuiSelectableButton::GroupController* = null {not observe}
prop Name: string = "" {not observe}
prop Image: INativeImage^ = null {not observe}
}
class VideoViewModel
{
prop Author: string = "" {}
prop Title: string = "" {}
prop Font: FontProperties = {} {}
}
}
]]>
</Workflow>
</Script>
<Instance name="AccountButtonTemplateResource">
<Instance ref.CodeBehind="false" ref.Class="demo::AccountButtonTemplate">
<ref.Members>
<![CDATA[
prop ViewModel: AccountButtonViewModel^ = null {}
]]>
</ref.Members>
<SelectableButtonTemplate ref.Name="self" MinSizeLimitation="LimitToElementAndChildren">
<att.ViewModel-bind>cast (AccountButtonViewModel^) self.Context</att.ViewModel-bind>
<SolidBackground Color-bind="cast Color (self.Selected ? '#FFFFFF' : self.State != ButtonState::Normal ? '#0000FF' : '#00000000')"/>
<ResponsiveView Direction="Horizontal" AlignmentToParent="left:0 top:0 right:0 bottom:0">
<att.Views>
<ResponsiveFixed>
<Table AlignmentToParent="left:0 top:0 right:0 bottom:0" CellPadding="5">
<att.Rows>
<CellOption>composeType:MinSize</CellOption>
</att.Rows>
<att.Columns>
<CellOption>composeType:MinSize</CellOption>
<CellOption>composeType:Percentage percentage:1.0</CellOption>
</att.Columns>
<Cell Site="row:0 column:0">
<ImageFrame FrameIndex="0" Image-bind="self.ViewModel.Image ?? null"/>
</Cell>
<Cell Site="row:0 column:1">
<SolidLabel Font-bind="self.Font" Text-bind="self.ViewModel.Name ?? ''" Color-bind="cast Color (self.Selected ? '#000000' : '#FFFFFF')">
<att.VerticalAlignment>Center</att.VerticalAlignment>
</SolidLabel>
</Cell>
</Table>
</ResponsiveFixed>
<ResponsiveFixed>
<Bounds AlignmentToParent="left:5 top:5 right:5 bottom:5" MinSizeLimitation="LimitToElementAndChildren">
<ImageFrame FrameIndex="0" Image-bind="self.ViewModel.Image ?? null"/>
</Bounds>
</ResponsiveFixed>
</att.Views>
</ResponsiveView>
</SelectableButtonTemplate>
</Instance>
</Instance>
<Instance name="AccountItemTemplateResource">
<Instance ref.CodeBehind="false" ref.Class="demo::AccountItemTemplate">
<ref.Parameter Name="ViewModel" Class="demo::AccountButtonViewModel"/>
<ControlTemplate MinSizeLimitation="LimitToElementAndChildren" AssociatedCursor-eval="INativeController::GetCurrentController().ResourceService().GetSystemCursor(Hand)">
<CheckBox ControlTemplate="demo::AccountButtonTemplate" Context-eval="ViewModel" GroupController-eval="ViewModel.Controller">
<att.BoundsComposition-set AlignmentToParent="left:0 top:0 right:0 bottom:0"/>
</CheckBox>
</ControlTemplate>
</Instance>
</Instance>
<Instance name="AccountMenuItemTemplateResource">
<Instance ref.CodeBehind="false" ref.Class="demo::AccountMenuItemTemplate">
<ref.Parameter Name="ViewModel" Class="demo::AccountButtonViewModel"/>
<ControlTemplate MinSizeLimitation="LimitToElementAndChildren" AssociatedCursor-eval="INativeController::GetCurrentController().ResourceService().GetSystemCursor(Hand)">
<MenuItemButton Text-bind="ViewModel.Name">
<att.BoundsComposition-set AlignmentToParent="left:0 top:0 right:0 bottom:0"/>
</MenuItemButton>
</ControlTemplate>
</Instance>
</Instance>
<Instance name="VideoItemTemplateResource">
<Instance ref.CodeBehind="false" ref.Class="demo::VideoItemTemplate">
<ref.Parameter Name="ViewModel" Class="demo::VideoViewModel"/>
<ControlTemplate ref.Name="self" MinSizeLimitation="LimitToElementAndChildren">
<Table AlignmentToParent="left:0 top:0 right:0 bottom:0" CellPadding="5">
<att.Rows>
<CellOption>composeType:MinSize</CellOption>
<CellOption>composeType:MinSize</CellOption>
<CellOption>composeType:MinSize</CellOption>
</att.Rows>
<att.Columns>
<CellOption>composeType:Percentage percentage:1.0</CellOption>
<CellOption>composeType:MinSize</CellOption>
<CellOption>composeType:MinSize</CellOption>
</att.Columns>
<Cell Site="row:0 column:0 columnSpan:3" PreferredMinSize="x:192 y:192">
<ImageFrame Stretch="true" FrameIndex="0" Image-uri="res://Images/Video"/>
</Cell>
<Cell Site="row:1 column:0 columnSpan:3">
<SolidLabel Font-bind="ViewModel.Font" Text-bind="ViewModel.Title" WrapLine="true" WrapLineHeightCalculation="true" Color="#FFFFFF"/>
</Cell>
<Cell Site="row:2 column:1">
<SolidLabel Font-bind="ViewModel.Font" Text="by:" Color="#808080"/>
</Cell>
<Cell Site="row:2 column:2">
<SolidLabel Font-bind="ViewModel.Font" Text-bind="ViewModel.Author" Color="#FFFFFF"/>
</Cell>
</Table>
</ControlTemplate>
</Instance>
</Instance>
<Instance name="MainWindowResource">
<Instance ref.CodeBehind="false" ref.Class="demo::MainWindow" xmlns:x="presentation::controls::GuiSelectableButton::*">
<ref.Members>
<![CDATA[
var accounts: observe AccountButtonViewModel^[] = {};
var videos: observe VideoViewModel^[] = {};
]]>
</ref.Members>
<ref.Ctor>
<![CDATA[
{
for (i in range [1, 8])
{
var item = new AccountButtonViewModel^();
item.Controller = self.accountController;
item.Name = Sys::LoremIpsumTitle(20);
item.Image = (cast (GuiImageData^) self.ResolveResource("res", $"Images/_$(i)", true)).Image;
self.accounts.Add(item);
}
for (i in range (0, 20))
{
var item = new VideoViewModel^();
item.Author = Sys::LoremIpsumTitle(16);
item.Title = Sys::LoremIpsumTitle(80);
item.Font = self.Font;
self.videos.Add(item);
}
}
]]>
</ref.Ctor>
<Window ref.Name="self" Text-format="Welcome to GacUI Video, $(Sys::LoremIpsumTitle(16))" ClientSize="x:800 y:600">
<x:MutexGroupController ref.Name="accountController"/>
<ResponsiveContainer AlignmentToParent="left:0 top:0 right:0 bottom:0">
<att.ResponsiveTarget>
<ResponsiveView Direction="Horizontal">
<att.SharedControls>
<ScrollContainer ref.Name="videoContainer" ExtendToFullWidth="true" HorizontalAlwaysVisible="false">
<RepeatFlow RowPadding="5" ColumnPadding="5">
<att.MinSizeLimitation>LimitToElementAndChildren</att.MinSizeLimitation>
<att.AlignmentToParent>left:0 top:0 right:0 bottom:0</att.AlignmentToParent>
<att.ItemSource-eval>self.videos</att.ItemSource-eval>
<att.ItemTemplate>demo::VideoItemTemplate</att.ItemTemplate>
</RepeatFlow>
</ScrollContainer>
</att.SharedControls>
<att.Views>
<ResponsiveGroup Direction="Horizontal">
<Table AlignmentToParent="left:0 top:0 right:0 bottom:0" CellPadding="5" MinSizeLimitation="LimitToElementAndChildren">
<att.Rows>
<CellOption>composeType:Percentage percentage:1.0</CellOption>
</att.Rows>
<att.Columns>
<CellOption>composeType:MinSize</CellOption>
<CellOption>composeType:Percentage percentage:1.0</CellOption>
</att.Columns>
<Cell Site="row:0 column:0">
<RepeatStack Direction="Vertical" Padding="5">
<att.MinSizeLimitation>LimitToElementAndChildren</att.MinSizeLimitation>
<att.AlignmentToParent>left:0 top:0 right:0 bottom:0</att.AlignmentToParent>
<att.ItemSource-eval>self.accounts</att.ItemSource-eval>
<att.ItemTemplate>demo::AccountItemTemplate</att.ItemTemplate>
</RepeatStack>
</Cell>
<Cell Site="row:0 column:1" PreferredMinSize="x:420">
<ResponsiveShared Shared-ref="videoContainer" AlignmentToParent="left:0 top:0 right:0 bottom:0"/>
</Cell>
</Table>
</ResponsiveGroup>
<ResponsiveFixed>
<Table CellPadding="5" BorderVisible="false" AlignmentToParent="left:0 top:0 right:0 bottom:0" MinSizeLimitation="LimitToElementAndChildren">
<att.Rows>
<CellOption>composeType:MinSize</CellOption>
<CellOption>composeType:Percentage percentage:1.0</CellOption>
</att.Rows>
<att.Columns>
<CellOption>composeType:Percentage percentage:1.0</CellOption>
</att.Columns>
<Cell Site="row:0 column:0">
<ToolstripMenuBar>
<att.BoundsComposition-set AlignmentToParent="left:0 top:0 right:0 bottom:0"/>
<MenuBarButton Text="Subscribed Accounts">
<att.SubMenu-set>
<RepeatStack Direction="Vertical">
<att.MinSizeLimitation>LimitToElementAndChildren</att.MinSizeLimitation>
<att.AlignmentToParent>left:0 top:0 right:0 bottom:0</att.AlignmentToParent>
<att.ItemSource-eval>self.accounts</att.ItemSource-eval>
<att.ItemTemplate>demo::AccountMenuItemTemplate</att.ItemTemplate>
</RepeatStack>
</att.SubMenu-set>
</MenuBarButton>
</ToolstripMenuBar>
</Cell>
<Cell Site="row:1 column:0">
<ResponsiveShared Shared-ref="videoContainer" AlignmentToParent="left:0 top:0 right:0 bottom:0"/>
</Cell>
</Table>
</ResponsiveFixed>
</att.Views>
</ResponsiveView>
</att.ResponsiveTarget>
</ResponsiveContainer>
</Window>
</Instance>
</Instance>
</Resource>
@@ -0,0 +1,15 @@
/***********************************************************************
!!!!!! DO NOT MODIFY !!!!!!
GacGen.exe Resource.xml
This file is generated by Workflow compiler
https://github.com/vczh-libraries
***********************************************************************/
#ifndef VCZH_WORKFLOW_COMPILER_GENERATED_DEMO
#define VCZH_WORKFLOW_COMPILER_GENERATED_DEMO
#include "DemoPartialClasses.h"
#endif
File diff suppressed because it is too large Load Diff
File diff suppressed because it is too large Load Diff
@@ -0,0 +1,244 @@
/***********************************************************************
!!!!!! DO NOT MODIFY !!!!!!
GacGen.exe Resource.xml
This file is generated by Workflow compiler
https://github.com/vczh-libraries
***********************************************************************/
#include "DemoReflection.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
/***********************************************************************
Reflection
***********************************************************************/
namespace vl
{
namespace reflection
{
namespace description
{
#ifndef VCZH_DEBUG_NO_REFLECTION
IMPL_CPP_TYPE_INFO(demo::AccountButtonTemplate)
IMPL_CPP_TYPE_INFO(demo::AccountButtonTemplateConstructor)
IMPL_CPP_TYPE_INFO(demo::AccountButtonViewModel)
IMPL_CPP_TYPE_INFO(demo::AccountItemTemplate)
IMPL_CPP_TYPE_INFO(demo::AccountItemTemplateConstructor)
IMPL_CPP_TYPE_INFO(demo::AccountMenuItemTemplate)
IMPL_CPP_TYPE_INFO(demo::AccountMenuItemTemplateConstructor)
IMPL_CPP_TYPE_INFO(demo::MainWindow)
IMPL_CPP_TYPE_INFO(demo::MainWindowConstructor)
IMPL_CPP_TYPE_INFO(demo::VideoItemTemplate)
IMPL_CPP_TYPE_INFO(demo::VideoItemTemplateConstructor)
IMPL_CPP_TYPE_INFO(demo::VideoViewModel)
#define _ ,
BEGIN_CLASS_MEMBER(::demo::AccountButtonTemplate)
CLASS_MEMBER_CONSTRUCTOR(::demo::AccountButtonTemplate*(), NO_PARAMETER)
CLASS_MEMBER_METHOD(GetViewModel, NO_PARAMETER)
CLASS_MEMBER_METHOD(SetViewModel, { L"__vwsn_value_" })
CLASS_MEMBER_EVENT(ViewModelChanged)
CLASS_MEMBER_FIELD(__vwsn_prop_ViewModel)
CLASS_MEMBER_PROPERTY_EVENT(ViewModel, GetViewModel, SetViewModel, ViewModelChanged)
END_CLASS_MEMBER(::demo::AccountButtonTemplate)
BEGIN_CLASS_MEMBER(::demo::AccountButtonTemplateConstructor)
CLASS_MEMBER_CONSTRUCTOR(::vl::Ptr<::demo::AccountButtonTemplateConstructor>(), NO_PARAMETER)
CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" })
CLASS_MEMBER_FIELD(__vwsn_precompile_0)
CLASS_MEMBER_FIELD(__vwsn_precompile_1)
CLASS_MEMBER_FIELD(__vwsn_precompile_10)
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(__vwsn_precompile_9)
CLASS_MEMBER_FIELD(self)
END_CLASS_MEMBER(::demo::AccountButtonTemplateConstructor)
BEGIN_CLASS_MEMBER(::demo::AccountButtonViewModel)
CLASS_MEMBER_CONSTRUCTOR(::vl::Ptr<::demo::AccountButtonViewModel>(), NO_PARAMETER)
CLASS_MEMBER_METHOD(GetController, NO_PARAMETER)
CLASS_MEMBER_METHOD(GetImage, NO_PARAMETER)
CLASS_MEMBER_METHOD(GetName, NO_PARAMETER)
CLASS_MEMBER_METHOD(SetController, { L"__vwsn_value_" })
CLASS_MEMBER_METHOD(SetImage, { L"__vwsn_value_" })
CLASS_MEMBER_METHOD(SetName, { L"__vwsn_value_" })
CLASS_MEMBER_FIELD(__vwsn_prop_Controller)
CLASS_MEMBER_FIELD(__vwsn_prop_Image)
CLASS_MEMBER_FIELD(__vwsn_prop_Name)
CLASS_MEMBER_PROPERTY(Controller, GetController, SetController)
CLASS_MEMBER_PROPERTY(Image, GetImage, SetImage)
CLASS_MEMBER_PROPERTY(Name, GetName, SetName)
END_CLASS_MEMBER(::demo::AccountButtonViewModel)
BEGIN_CLASS_MEMBER(::demo::AccountItemTemplate)
CLASS_MEMBER_CONSTRUCTOR(::demo::AccountItemTemplate*(::vl::Ptr<::demo::AccountButtonViewModel>), { L"__vwsn_ctor_parameter_ViewModel" })
CLASS_MEMBER_METHOD(GetViewModel, NO_PARAMETER)
CLASS_MEMBER_FIELD(__vwsn_parameter_ViewModel)
CLASS_MEMBER_PROPERTY_READONLY(ViewModel, GetViewModel)
END_CLASS_MEMBER(::demo::AccountItemTemplate)
BEGIN_CLASS_MEMBER(::demo::AccountItemTemplateConstructor)
CLASS_MEMBER_CONSTRUCTOR(::vl::Ptr<::demo::AccountItemTemplateConstructor>(), NO_PARAMETER)
CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" })
CLASS_MEMBER_FIELD(__vwsn_precompile_0)
CLASS_MEMBER_FIELD(__vwsn_precompile_1)
CLASS_MEMBER_FIELD(__vwsn_precompile_2)
CLASS_MEMBER_FIELD(ViewModel)
END_CLASS_MEMBER(::demo::AccountItemTemplateConstructor)
BEGIN_CLASS_MEMBER(::demo::AccountMenuItemTemplate)
CLASS_MEMBER_CONSTRUCTOR(::demo::AccountMenuItemTemplate*(::vl::Ptr<::demo::AccountButtonViewModel>), { L"__vwsn_ctor_parameter_ViewModel" })
CLASS_MEMBER_METHOD(GetViewModel, NO_PARAMETER)
CLASS_MEMBER_FIELD(__vwsn_parameter_ViewModel)
CLASS_MEMBER_PROPERTY_READONLY(ViewModel, GetViewModel)
END_CLASS_MEMBER(::demo::AccountMenuItemTemplate)
BEGIN_CLASS_MEMBER(::demo::AccountMenuItemTemplateConstructor)
CLASS_MEMBER_CONSTRUCTOR(::vl::Ptr<::demo::AccountMenuItemTemplateConstructor>(), NO_PARAMETER)
CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" })
CLASS_MEMBER_FIELD(__vwsn_precompile_0)
CLASS_MEMBER_FIELD(__vwsn_precompile_1)
CLASS_MEMBER_FIELD(__vwsn_precompile_2)
CLASS_MEMBER_FIELD(ViewModel)
END_CLASS_MEMBER(::demo::AccountMenuItemTemplateConstructor)
BEGIN_CLASS_MEMBER(::demo::MainWindow)
CLASS_MEMBER_CONSTRUCTOR(::demo::MainWindow*(), NO_PARAMETER)
CLASS_MEMBER_METHOD(__vwsn_instance_ctor_, NO_PARAMETER)
CLASS_MEMBER_FIELD(accounts)
CLASS_MEMBER_FIELD(videos)
END_CLASS_MEMBER(::demo::MainWindow)
BEGIN_CLASS_MEMBER(::demo::MainWindowConstructor)
CLASS_MEMBER_CONSTRUCTOR(::vl::Ptr<::demo::MainWindowConstructor>(), NO_PARAMETER)
CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" })
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_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(__vwsn_precompile_9)
CLASS_MEMBER_FIELD(accountController)
CLASS_MEMBER_FIELD(self)
CLASS_MEMBER_FIELD(videoContainer)
END_CLASS_MEMBER(::demo::MainWindowConstructor)
BEGIN_CLASS_MEMBER(::demo::VideoItemTemplate)
CLASS_MEMBER_CONSTRUCTOR(::demo::VideoItemTemplate*(::vl::Ptr<::demo::VideoViewModel>), { L"__vwsn_ctor_parameter_ViewModel" })
CLASS_MEMBER_METHOD(GetViewModel, NO_PARAMETER)
CLASS_MEMBER_FIELD(__vwsn_parameter_ViewModel)
CLASS_MEMBER_PROPERTY_READONLY(ViewModel, GetViewModel)
END_CLASS_MEMBER(::demo::VideoItemTemplate)
BEGIN_CLASS_MEMBER(::demo::VideoItemTemplateConstructor)
CLASS_MEMBER_CONSTRUCTOR(::vl::Ptr<::demo::VideoItemTemplateConstructor>(), NO_PARAMETER)
CLASS_MEMBER_METHOD(__vwsn_initialize_instance_, { L"__vwsn_this_" })
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)
CLASS_MEMBER_FIELD(self)
END_CLASS_MEMBER(::demo::VideoItemTemplateConstructor)
BEGIN_CLASS_MEMBER(::demo::VideoViewModel)
CLASS_MEMBER_CONSTRUCTOR(::vl::Ptr<::demo::VideoViewModel>(), NO_PARAMETER)
CLASS_MEMBER_METHOD(GetAuthor, NO_PARAMETER)
CLASS_MEMBER_METHOD(GetFont, NO_PARAMETER)
CLASS_MEMBER_METHOD(GetTitle, NO_PARAMETER)
CLASS_MEMBER_METHOD(SetAuthor, { L"__vwsn_value_" })
CLASS_MEMBER_METHOD(SetFont, { L"__vwsn_value_" })
CLASS_MEMBER_METHOD(SetTitle, { L"__vwsn_value_" })
CLASS_MEMBER_EVENT(AuthorChanged)
CLASS_MEMBER_EVENT(FontChanged)
CLASS_MEMBER_EVENT(TitleChanged)
CLASS_MEMBER_FIELD(__vwsn_prop_Author)
CLASS_MEMBER_FIELD(__vwsn_prop_Font)
CLASS_MEMBER_FIELD(__vwsn_prop_Title)
CLASS_MEMBER_PROPERTY_EVENT(Author, GetAuthor, SetAuthor, AuthorChanged)
CLASS_MEMBER_PROPERTY_EVENT(Font, GetFont, SetFont, FontChanged)
CLASS_MEMBER_PROPERTY_EVENT(Title, GetTitle, SetTitle, TitleChanged)
END_CLASS_MEMBER(::demo::VideoViewModel)
#undef _
class DemoTypeLoader : public Object, public ITypeLoader
{
public:
void Load(ITypeManager* manager)
{
ADD_TYPE_INFO(::demo::AccountButtonTemplate)
ADD_TYPE_INFO(::demo::AccountButtonTemplateConstructor)
ADD_TYPE_INFO(::demo::AccountButtonViewModel)
ADD_TYPE_INFO(::demo::AccountItemTemplate)
ADD_TYPE_INFO(::demo::AccountItemTemplateConstructor)
ADD_TYPE_INFO(::demo::AccountMenuItemTemplate)
ADD_TYPE_INFO(::demo::AccountMenuItemTemplateConstructor)
ADD_TYPE_INFO(::demo::MainWindow)
ADD_TYPE_INFO(::demo::MainWindowConstructor)
ADD_TYPE_INFO(::demo::VideoItemTemplate)
ADD_TYPE_INFO(::demo::VideoItemTemplateConstructor)
ADD_TYPE_INFO(::demo::VideoViewModel)
}
void Unload(ITypeManager* manager)
{
}
};
#endif
bool LoadDemoTypes()
{
#ifndef VCZH_DEBUG_NO_REFLECTION
if (auto manager = GetGlobalTypeManager())
{
return manager->AddTypeLoader(MakePtr<DemoTypeLoader>());
}
#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
@@ -0,0 +1,64 @@
/***********************************************************************
!!!!!! DO NOT MODIFY !!!!!!
GacGen.exe Resource.xml
This file is generated by Workflow compiler
https://github.com/vczh-libraries
***********************************************************************/
#ifndef VCZH_WORKFLOW_COMPILER_GENERATED_DEMOREFLECTION
#define VCZH_WORKFLOW_COMPILER_GENERATED_DEMOREFLECTION
#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
/***********************************************************************
Reflection
***********************************************************************/
namespace vl
{
namespace reflection
{
namespace description
{
#ifndef VCZH_DEBUG_NO_REFLECTION
DECL_TYPE_INFO(::demo::AccountButtonTemplate)
DECL_TYPE_INFO(::demo::AccountButtonTemplateConstructor)
DECL_TYPE_INFO(::demo::AccountButtonViewModel)
DECL_TYPE_INFO(::demo::AccountItemTemplate)
DECL_TYPE_INFO(::demo::AccountItemTemplateConstructor)
DECL_TYPE_INFO(::demo::AccountMenuItemTemplate)
DECL_TYPE_INFO(::demo::AccountMenuItemTemplateConstructor)
DECL_TYPE_INFO(::demo::MainWindow)
DECL_TYPE_INFO(::demo::MainWindowConstructor)
DECL_TYPE_INFO(::demo::VideoItemTemplate)
DECL_TYPE_INFO(::demo::VideoItemTemplateConstructor)
DECL_TYPE_INFO(::demo::VideoViewModel)
#endif
extern bool LoadDemoTypes();
}
}
}
#if defined( _MSC_VER)
#pragma warning(pop)
#elif defined(__GNUC__)
#pragma GCC diagnostic pop
#elif defined(__clang__)
#pragma clang diagnostic pop
#endif
#endif
Binary file not shown.