1
0
mirror of https://github.com/Artemis-RGB/Artemis synced 2025-12-13 05:48:35 +00:00
Artemis/src/Artemis.UI/Screens/Device/DeviceSettingsView.axaml
Robert c86dba30fc Settings - Brought the with and margins of different tabs in line with eachother
Settings - Tweaked card title font size and spacing
Plugins - Show extra information on plugins in their config dialog 
Plugins - Added the ability to provide a license in plugin.json
2023-05-18 11:18:55 +02:00

61 lines
3.5 KiB
XML

<UserControl xmlns="https://github.com/avaloniaui"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:avalonia="clr-namespace:Material.Icons.Avalonia;assembly=Material.Icons.Avalonia"
xmlns:controls="clr-namespace:FluentAvalonia.UI.Controls;assembly=FluentAvalonia"
xmlns:shared="clr-namespace:Artemis.UI.Shared;assembly=Artemis.UI.Shared"
xmlns:local="clr-namespace:Artemis.UI.Screens.Device"
mc:Ignorable="d" d:DesignWidth="800" d:DesignHeight="450"
x:DataType="local:DeviceSettingsViewModel"
x:Class="Artemis.UI.Screens.Device.DeviceSettingsView">
<Border Classes="card" Padding="0" Width="240" ClipToBounds="True" Margin="5">
<Grid RowDefinitions="160,*,Auto">
<Rectangle Grid.Row="0" Fill="{DynamicResource CheckerboardBrush}" />
<shared:DeviceVisualizer Grid.Row="0"
VerticalAlignment="Center"
HorizontalAlignment="Center"
Margin="10"
ShowColors="False"
Device="{CompiledBinding Device}"
RenderOptions.BitmapInterpolationMode="HighQuality" />
<Button Grid.Row="0"
Classes="icon-button icon-button-large"
VerticalAlignment="Bottom"
HorizontalAlignment="Right"
Margin="5"
ToolTip.Tip="Identify"
Command="{CompiledBinding IdentifyDevice}">
<avalonia:MaterialIcon Kind="AlarmLight" />
</Button>
<StackPanel Grid.Row="1" Margin="8 16 8 0">
<TextBlock Text="{CompiledBinding Device.RgbDevice.DeviceInfo.Model}" />
<StackPanel>
<TextBlock TextWrapping="Wrap" Classes="subtitle" Text="{CompiledBinding Device.RgbDevice.DeviceInfo.Manufacturer, Mode=OneWay}" />
<TextBlock TextWrapping="Wrap" Classes="subtitle" Text="{CompiledBinding Device.DeviceType, Mode=OneWay}" />
</StackPanel>
</StackPanel>
<Grid Grid.Row="2" Margin="10" ColumnDefinitions="25,*">
<CheckBox IsChecked="{CompiledBinding IsDeviceEnabled}" />
<SplitButton Grid.Column="1" Content="Properties" Command="{CompiledBinding ViewProperties}" HorizontalAlignment="Right">
<SplitButton.Flyout>
<MenuFlyout Placement="Bottom">
<MenuItem Header="Open plugin directory" Command="{CompiledBinding OpenPluginDirectory}">
<MenuItem.Icon>
<avalonia:MaterialIcon Kind="FolderOpen" />
</MenuItem.Icon>
</MenuItem>
<MenuItem Header="Identity input" Command="{CompiledBinding DetectInput}">
<MenuItem.Icon>
<avalonia:MaterialIcon Kind="GestureDoubleTap" />
</MenuItem.Icon>
</MenuItem>
</MenuFlyout>
</SplitButton.Flyout>
</SplitButton>
</Grid>
</Grid>
</Border>
</UserControl>