Added FlowDirection picker to SampleController
This commit is contained in:
Родитель
4f394ce3e4
Коммит
14a609739f
|
@ -82,6 +82,12 @@
|
|||
<ComboBoxItem Content="Light" />
|
||||
<ComboBoxItem Content="Dark" />
|
||||
</ComboBox>
|
||||
|
||||
<TextBlock Text="Flow Direction" VerticalAlignment="Center" Margin="8,0,10,0" />
|
||||
<ComboBox x:Name="FlowDirectionPicker">
|
||||
<ComboBoxItem Content="Left To Right" />
|
||||
<ComboBoxItem Content="Right To Left" />
|
||||
</ComboBox>
|
||||
</StackPanel>
|
||||
</StackPanel>
|
||||
|
||||
|
|
|
@ -52,6 +52,9 @@ namespace Microsoft.Toolkit.Uwp.SampleApp
|
|||
ThemePicker.SelectedIndex = (int)GetCurrentTheme();
|
||||
ThemePicker.SelectionChanged += ThemePicker_SelectionChanged;
|
||||
|
||||
FlowDirectionPicker.SelectedIndex = (int)DemoFlowDirection;
|
||||
FlowDirectionPicker.SelectionChanged += this.FlowDirectionPicker_SelectionChanged;
|
||||
|
||||
DocumentationTextBlock.SetRenderer<SampleAppMarkdownRenderer>();
|
||||
|
||||
ProcessSampleEditorTime();
|
||||
|
@ -661,6 +664,11 @@ namespace Microsoft.Toolkit.Uwp.SampleApp
|
|||
}
|
||||
}
|
||||
|
||||
private void FlowDirectionPicker_SelectionChanged(object sender, SelectionChangedEventArgs e)
|
||||
{
|
||||
DemoFlowDirection = (FlowDirection)FlowDirectionPicker.SelectedIndex;
|
||||
}
|
||||
|
||||
public Sample CurrentSample { get; private set; }
|
||||
|
||||
public ObservableCollection<SampleCommand> Commands { get; } = new ObservableCollection<SampleCommand>();
|
||||
|
@ -694,6 +702,12 @@ namespace Microsoft.Toolkit.Uwp.SampleApp
|
|||
}
|
||||
}
|
||||
|
||||
private FlowDirection DemoFlowDirection
|
||||
{
|
||||
get => DemoAreaGrid.FlowDirection;
|
||||
set => DemoAreaGrid.FlowDirection = value;
|
||||
}
|
||||
|
||||
// The Loaded Instance of the backing .xaml.cs Page (if any)
|
||||
private Page SamplePage { get; set; }
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче