Adding icons to the dropdowns

This commit is contained in:
Niels Laute
2026-02-04 20:45:01 +01:00
parent 805abb3192
commit 337f59db14
3 changed files with 52 additions and 18 deletions

View File

@@ -41,10 +41,20 @@
HorizontalAlignment="Stretch"
SelectionChanged="TriggerTypeComboBox_SelectionChanged">
<ComboBoxItem
Content="Key or shortcut"
AutomationProperties.Name="Key or shortcut"
IsSelected="True"
Tag="KeyOrShortcut" />
<ComboBoxItem Content="Mouse button" Tag="Mouse" />
Tag="KeyOrShortcut">
<StackPanel Orientation="Horizontal" Spacing="8">
<FontIcon FontSize="14" Glyph="&#xEDA7;" />
<TextBlock Text="Key or shortcut" />
</StackPanel>
</ComboBoxItem>
<ComboBoxItem AutomationProperties.Name="Mouse button" Tag="Mouse">
<StackPanel Orientation="Horizontal" Spacing="8">
<FontIcon FontSize="16" Glyph="&#xE962;" />
<TextBlock Text="Mouse button" />
</StackPanel>
</ComboBoxItem>
</ComboBox>
<Rectangle
@@ -177,13 +187,38 @@
HorizontalAlignment="Stretch"
SelectionChanged="ActionTypeComboBox_SelectionChanged">
<ComboBoxItem
Content="Remap to key or shortcut"
AutomationProperties.Name="Remap to key or shortcut"
IsSelected="True"
Tag="KeyOrShortcut" />
<ComboBoxItem Content="Insert text" Tag="Text" />
<ComboBoxItem Content="Open URL" Tag="OpenUrl" />
<ComboBoxItem Content="Open app" Tag="OpenApp" />
<ComboBoxItem Content="Remap to mouse click" Tag="MouseClick" />
Tag="KeyOrShortcut">
<StackPanel Orientation="Horizontal" Spacing="8">
<FontIcon FontSize="14" Glyph="&#xEDA7;" />
<TextBlock Text="Remap to key or shortcut" />
</StackPanel>
</ComboBoxItem>
<ComboBoxItem AutomationProperties.Name="Insert text" Tag="Text">
<StackPanel Orientation="Horizontal" Spacing="8">
<FontIcon FontSize="14" Glyph="&#xE8D2;" />
<TextBlock Text="Insert text" />
</StackPanel>
</ComboBoxItem>
<ComboBoxItem AutomationProperties.Name="Open URL" Tag="OpenUrl">
<StackPanel Orientation="Horizontal" Spacing="8">
<FontIcon FontSize="14" Glyph="&#xE774;" />
<TextBlock Text="Open URL" />
</StackPanel>
</ComboBoxItem>
<ComboBoxItem AutomationProperties.Name="Open app" Tag="OpenApp">
<StackPanel Orientation="Horizontal" Spacing="8">
<FontIcon FontSize="14" Glyph="&#xECAA;" />
<TextBlock Text="Open app" />
</StackPanel>
</ComboBoxItem>
<ComboBoxItem AutomationProperties.Name="Remap to mouse click" Tag="MouseClick">
<StackPanel Orientation="Horizontal" Spacing="8">
<FontIcon FontSize="14" Glyph="&#xE962;" />
<TextBlock Text="Remap to mouse click" />
</StackPanel>
</ComboBoxItem>
</ComboBox>
<Rectangle

View File

@@ -30,12 +30,10 @@ namespace KeyboardManagerEditorUI
public MainWindow()
{
this.InitializeComponent();
SetTitleBar();
this.Activated += MainWindow_Activated;
this.Closed += MainWindow_Closed;
SetTitleBar();
// Set the default page
// RootView.SelectedItem = RootView.MenuItems[0];
}

View File

@@ -85,13 +85,14 @@
</StackPanel>
</Button>
</Grid>
<Grid Grid.Row="1">
<Grid
Grid.Row="1"
Background="{ThemeResource LayerFillColorDefaultBrush}"
BorderBrush="{ThemeResource CardStrokeColorDefaultBrush}"
BorderThickness="1"
CornerRadius="{ThemeResource OverlayCornerRadius}">
<ScrollViewer VerticalAlignment="Stretch" VerticalScrollBarVisibility="Auto">
<Grid
Background="{ThemeResource LayerFillColorDefaultBrush}"
BorderBrush="{ThemeResource CardStrokeColorDefaultBrush}"
BorderThickness="1"
CornerRadius="{ThemeResource OverlayCornerRadius}">
<Grid>
<StackPanel Orientation="Vertical" Spacing="24">
<!-- Remappings Section -->
<StackPanel Orientation="Vertical" Visibility="{x:Bind RemappingList.Count, Mode=OneWay, Converter={StaticResource CountToVisibilityConverter}}">