Skip to content
This repository was archived by the owner on Nov 27, 2024. It is now read-only.

Commit 071bd74

Browse files
committed
Rename Settings view to ModelsView
1 parent 776cc12 commit 071bd74

File tree

3 files changed

+14
-13
lines changed

3 files changed

+14
-13
lines changed

OnnxStack.UI/MainWindow.xaml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,23 +76,24 @@
7676
<StackPanel Orientation="Horizontal">
7777
<userControls:FontAwesome Icon="&#xf022;" IconStyle="Light"/>
7878
</StackPanel>
79-
<TextBlock Text="Logs" Margin="5,0,0,0"/>
79+
<TextBlock Text="" Margin="5,0,0,0"/>
8080
</StackPanel>
8181
</TabItem.Header>
8282
<views:Logger LogOutput="{Binding OutputLog, Mode=TwoWay}" Margin="0,6,0,0"/>
8383
</TabItem>
8484

85-
<!--Settings-->
85+
86+
<!--Models-->
8687
<TabItem DockPanel.Dock="Right" HorizontalAlignment="Right">
8788
<TabItem.Header>
8889
<StackPanel Orientation="Horizontal" Margin="5">
8990
<StackPanel Orientation="Horizontal">
90-
<userControls:FontAwesome Icon="&#xf013;" IconStyle="Light"/>
91+
<userControls:FontAwesome Icon="&#xf5fd;" IconStyle="Light"/>
9192
</StackPanel>
92-
<TextBlock Text="Settings" Margin="5,0,0,0"/>
93+
<TextBlock Text="Models" Margin="5,0,0,0"/>
9394
</StackPanel>
9495
</TabItem.Header>
95-
<views:Settings ModelOptions="{Binding Models, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged, NotifyOnSourceUpdated=True, NotifyOnTargetUpdated=True}" Margin="0,6,0,0"/>
96+
<views:ModelView ModelOptions="{Binding Models, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged, NotifyOnSourceUpdated=True, NotifyOnTargetUpdated=True}" Margin="0,6,0,0"/>
9697
</TabItem>
9798
</TabControl>
9899
</Grid>

OnnxStack.UI/Views/Settings.xaml renamed to OnnxStack.UI/Views/ModelView.xaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<UserControl x:Class="OnnxStack.UI.Views.Settings"
1+
<UserControl x:Class="OnnxStack.UI.Views.ModelView"
22
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
33
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
44
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"

OnnxStack.UI/Views/Settings.xaml.cs renamed to OnnxStack.UI/Views/ModelView.xaml.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,11 @@
2525
namespace OnnxStack.UI.Views
2626
{
2727
/// <summary>
28-
/// Interaction logic for Settings.xaml
28+
/// Interaction logic for ModelView.xaml
2929
/// </summary>
30-
public partial class Settings : UserControl, INavigatable, INotifyPropertyChanged
30+
public partial class ModelView : UserControl, INavigatable, INotifyPropertyChanged
3131
{
32-
private readonly ILogger<Settings> _logger;
32+
private readonly ILogger<ModelView> _logger;
3333
private readonly string _defaultTokenizerPath;
3434
private readonly IDialogService _dialogService;
3535
private readonly IOnnxModelService _onnxModelService;
@@ -45,13 +45,13 @@ public partial class Settings : UserControl, INavigatable, INotifyPropertyChange
4545

4646

4747
/// <summary>
48-
/// Initializes a new instance of the <see cref="Settings"/> class.
48+
/// Initializes a new instance of the <see cref="ModelView"/> class.
4949
/// </summary>
50-
public Settings()
50+
public ModelView()
5151
{
5252
if (!DesignerProperties.GetIsInDesignMode(this))
5353
{
54-
_logger = App.GetService<ILogger<Settings>>();
54+
_logger = App.GetService<ILogger<ModelView>>();
5555
_dialogService = App.GetService<IDialogService>();
5656
_onnxModelService = App.GetService<IOnnxModelService>();
5757
_stableDiffusionConfig = App.GetService<StableDiffusionConfig>();
@@ -95,7 +95,7 @@ public ObservableCollection<ModelOptionsModel> ModelOptions
9595
}
9696

9797
public static readonly DependencyProperty ModelOptionsProperty =
98-
DependencyProperty.Register("ModelOptions", typeof(ObservableCollection<ModelOptionsModel>), typeof(Settings));
98+
DependencyProperty.Register("ModelOptions", typeof(ObservableCollection<ModelOptionsModel>), typeof(ModelView));
9999

100100
public ObservableCollection<ModelSetViewModel> ModelSets
101101
{

0 commit comments

Comments
 (0)