Skip to content

Commit 8e6af08

Browse files
committed
Add Clock/Date Format Combobox UI in settingswindow
1 parent 5758d96 commit 8e6af08

File tree

2 files changed

+38
-5
lines changed

2 files changed

+38
-5
lines changed

Flow.Launcher/SettingWindow.xaml

Lines changed: 33 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1897,13 +1897,27 @@
18971897
<StackPanel Style="{StaticResource TextPanel}">
18981898
<TextBlock Style="{DynamicResource SettingTitleLabel}" Text="{DynamicResource Clock}" />
18991899
</StackPanel>
1900-
<ui:ToggleSwitch
1901-
Grid.Row="0"
1902-
Grid.Column="2"
1900+
<StackPanel Grid.Row="0"
1901+
Grid.Column="2" Orientation="Horizontal">
1902+
<ComboBox
1903+
x:Name="TimeFormat"
1904+
Grid.Column="2"
1905+
MinWidth="180"
1906+
VerticalAlignment="Center"
1907+
Margin="0,0,18,0"
1908+
DisplayMemberPath="Display"
1909+
FontSize="14"
1910+
ItemsSource="{Binding ColorSchemes}"
1911+
SelectedValue="{Binding Settings.ColorScheme}"
1912+
SelectedValuePath="Value"
1913+
SelectionChanged="ColorSchemeSelectedIndexChanged" />
1914+
<ui:ToggleSwitch
1915+
19031916
IsOn="{Binding UseClock, Mode=TwoWay}"
19041917
OffContent="{DynamicResource disable}"
19051918
OnContent="{DynamicResource enable}"
19061919
Style="{DynamicResource SideToggleSwitch}" />
1920+
</StackPanel>
19071921
<TextBlock Style="{StaticResource Glyph}">
19081922
&#xec92;
19091923
</TextBlock>
@@ -1921,13 +1935,27 @@
19211935
<StackPanel Style="{StaticResource TextPanel}">
19221936
<TextBlock Style="{DynamicResource SettingTitleLabel}" Text="{DynamicResource Date}" />
19231937
</StackPanel>
1938+
<StackPanel Grid.Row="0"
1939+
Grid.Column="2" Orientation="Horizontal">
1940+
<ComboBox
1941+
x:Name="DateFormat"
1942+
Grid.Column="2"
1943+
MinWidth="180"
1944+
VerticalAlignment="Center"
1945+
Margin="0,0,18,0"
1946+
DisplayMemberPath="Display"
1947+
FontSize="14"
1948+
ItemsSource="{Binding ColorSchemes}"
1949+
SelectedValue="{Binding Settings.ColorScheme}"
1950+
SelectedValuePath="Value"
1951+
SelectionChanged="ColorSchemeSelectedIndexChanged" />
19241952
<ui:ToggleSwitch
1925-
Grid.Row="0"
1926-
Grid.Column="2"
1953+
19271954
IsOn="{Binding UseDate, Mode=TwoWay}"
19281955
OffContent="{DynamicResource disable}"
19291956
OnContent="{DynamicResource enable}"
19301957
Style="{DynamicResource SideToggleSwitch}" />
1958+
</StackPanel>
19311959
<TextBlock Style="{StaticResource Glyph}">
19321960
&#xe787;
19331961
</TextBlock>

Flow.Launcher/SettingWindow.xaml.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -348,5 +348,10 @@ private void ItemSizeChanged(object sender, SizeChangedEventArgs e)
348348
{
349349
Plugins.ScrollIntoView(Plugins.SelectedItem);
350350
}
351+
352+
private void ColorSchemeSelectedIndexChanged(object sender, SelectionChangedEventArgs e)
353+
{
354+
355+
}
351356
}
352357
}

0 commit comments

Comments
 (0)