add PreviewSlider

This commit is contained in:
NaBian committed 2018-10-30 00:16:04 +08:00
1 parent 0796857ed5
commit 969f58e501
20 files changed
+218 -31

No files matched your search

+2
View File
@@ -34,6 +34,8 @@
public static readonly string ScrollViewerDemoCtl = nameof(ScrollViewerDemoCtl);
public static readonly string PreviewSliderDemoCtl = nameof(PreviewSliderDemoCtl);
public static readonly string ButtonDemoCtl = nameof(ButtonDemoCtl);
public static readonly string ToggleButtonDemoCtl = nameof(ToggleButtonDemoCtl);
+2 -1
View File
@@ -19,7 +19,8 @@ var controlList = new List<string>
"CirclePanelDemoCtl",
"NumericUpDownDemoCtl",
"WindowDemoCtl",
"ScrollViewerDemoCtl"
"ScrollViewerDemoCtl",
"PreviewSliderDemoCtl"
};
var styleList = new List<string>
{
+8
View File
@@ -120,6 +120,9 @@
<Compile Include="UserControl\Controls\NumericUpDownDemoCtl.xaml.cs">
<DependentUpon>NumericUpDownDemoCtl.xaml</DependentUpon>
</Compile>
<Compile Include="UserControl\Controls\PreviewSliderDemoCtl.xaml.cs">
<DependentUpon>PreviewSliderDemoCtl.xaml</DependentUpon>
</Compile>
<Compile Include="UserControl\Controls\ScrollViewerDemoCtl.xaml.cs">
<DependentUpon>ScrollViewerDemoCtl.xaml</DependentUpon>
</Compile>
@@ -327,6 +330,10 @@
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="UserControl\Controls\PreviewSliderDemoCtl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="UserControl\Controls\ScrollViewerDemoCtl.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
@@ -483,6 +490,7 @@
<Generator>TextTemplatingFileGenerator</Generator>
<LastGenOutput>MessageToken.cs</LastGenOutput>
</Content>
<Resource Include="Resources\Img\LeftMainContent\HoverMenu_16x.png" />
<Resource Include="Resources\Img\icon.ico" />
<Resource Include="Resources\Img\LeftMainContent\Brush_16x.png" />
<Resource Include="Resources\Img\Avatar\avatar1.png" />
+9
View File
@@ -582,6 +582,15 @@ namespace HandyControlDemo.Properties.Langs {
}
}
/// <summary>
/// 查找类似 预览滑块 的本地化字符串。
/// </summary>
public static string PreviewSlider {
get {
return ResourceManager.GetString("PreviewSlider", resourceCulture);
}
}
/// <summary>
/// 查找类似 主要 的本地化字符串。
/// </summary>
@@ -378,4 +378,7 @@
<data name="Brush" xml:space="preserve">
<value>Brush</value>
</data>
<data name="PreviewSlider" xml:space="preserve">
<value>PreviewSlider</value>
</data>
</root>
@@ -358,4 +358,7 @@
<data name="Brush" xml:space="preserve">
<value>画刷</value>
</data>
<data name="PreviewSlider" xml:space="preserve">
<value>预览滑块</value>
</data>
</root>
Binary file not shown.

After

Width:  |  Height:  |  Size: 240 B

@@ -0,0 +1,13 @@
<UserControl x:Class="HandyControlDemo.UserControl.PreviewSliderDemoCtl"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:controls="clr-namespace:HandyControl.Controls;assembly=HandyControl"
Background="{DynamicResource RegionBrush}">
<controls:TransitioningContentControl>
<controls:PreviewSlider Name="PreviewSlider" Width="800" Value="500" Maximum="1000" VerticalAlignment="Center" Margin="32">
<controls:PreviewSlider.PreviewContent>
<Label Style="{StaticResource LabelPrimary}" Content="{Binding PreviewPosition,ElementName=PreviewSlider}" ContentStringFormat="{}{0:#0.0}"/>
</controls:PreviewSlider.PreviewContent>
</controls:PreviewSlider>
</controls:TransitioningContentControl>
</UserControl>
@@ -0,0 +1,11 @@
// ReSharper disable once CheckNamespace
namespace HandyControlDemo.UserControl
{
public partial class PreviewSliderDemoCtl
{
public PreviewSliderDemoCtl()
{
InitializeComponent();
}
}
}
@@ -15,7 +15,7 @@
</i:Interaction.Triggers>
<TabItem Header="{x:Static langs:Lang.Styles}">
<ListBox BorderThickness="0" SelectionMode="Single">
<ListBoxItem Style="{StaticResource ListBoxItemNew}" Tag="{x:Static data:MessageToken.BrushDemoCtl}" Content="{x:Static langs:Lang.Brush}">
<ListBoxItem Tag="{x:Static data:MessageToken.BrushDemoCtl}" Content="{x:Static langs:Lang.Brush}">
<controls:EdgeElement.LeftContent>
<Image Source="../../Resources/Img/LeftMainContent/Brush_16x.png"/>
</controls:EdgeElement.LeftContent>
@@ -174,6 +174,11 @@
<Image Source="../../Resources/Img/LeftMainContent/SplitterControl_16x.png"/>
</controls:EdgeElement.LeftContent>
</ListBoxItem>
<ListBoxItem Style="{StaticResource ListBoxItemNew}" Tag="{x:Static data:MessageToken.PreviewSliderDemoCtl}" Content="{x:Static langs:Lang.PreviewSlider}">
<controls:EdgeElement.LeftContent>
<Image Source="../../Resources/Img/LeftMainContent/HoverMenu_16x.png"/>
</controls:EdgeElement.LeftContent>
</ListBoxItem>
<ListBoxItem Tag="{x:Static data:MessageToken.TimeBarDemoCtl}" Content="{x:Static langs:Lang.TimeBar}">
<controls:EdgeElement.LeftContent>
<Image Source="../../Resources/Img/LeftMainContent/Timeline_16x.png"/>