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

Commit b9f99a7

Browse files
committed
Tidy up View names
1 parent f9f2e60 commit b9f99a7

12 files changed

+34
-35
lines changed

OnnxStack.UI/MainWindow.xaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
<TextBlock Text="Image To Image" Margin="5,0,0,0"/>
5252
</StackPanel>
5353
</TabItem.Header>
54-
<views:ImageToImage UISettings="{Binding UISettings}" Margin="0,6,0,0"/>
54+
<views:ImageToImageView UISettings="{Binding UISettings}" Margin="0,6,0,0"/>
5555
</TabItem>
5656

5757
<!--Image Inpaint-->
@@ -66,7 +66,7 @@
6666
<TextBlock Text="Image Inpaint" Margin="5,0,0,0"/>
6767
</StackPanel>
6868
</TabItem.Header>
69-
<views:ImageInpaint UISettings="{Binding UISettings}" Margin="0,6,0,0"/>
69+
<views:ImageInpaintView UISettings="{Binding UISettings}" Margin="0,6,0,0"/>
7070
</TabItem>
7171

7272
<!--Log Window-->
@@ -78,7 +78,7 @@
7878
</StackPanel>
7979
</StackPanel>
8080
</TabItem.Header>
81-
<views:Logger UISettings="{Binding UISettings}" LogOutput="{Binding OutputLog, Mode=TwoWay}" Margin="0,6,0,0"/>
81+
<views:LoggerView UISettings="{Binding UISettings}" LogOutput="{Binding OutputLog, Mode=TwoWay}" Margin="0,6,0,0"/>
8282
</TabItem>
8383

8484
<!--Settings Window-->
@@ -90,7 +90,7 @@
9090
</StackPanel>
9191
</StackPanel>
9292
</TabItem.Header>
93-
<views:Settings UISettings="{Binding UISettings, Mode=TwoWay}" Margin="0,6,0,0"/>
93+
<views:SettingsView UISettings="{Binding UISettings, Mode=TwoWay}" Margin="0,6,0,0"/>
9494
</TabItem>
9595

9696

OnnxStack.UI/Models/BatchOptionsModel.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ public class BatchOptionsModel : INotifyPropertyChanged
1616
private int _batchValue;
1717
private int _batchsValue = 1;
1818
private int _realtimeRefreshRate = 1000;
19-
private bool _disableHistory;
19+
private bool _disableHistory = true;
2020

2121
public BatchOptionType BatchType
2222
{

OnnxStack.UI/Views/ImageInpaint.xaml renamed to OnnxStack.UI/Views/ImageInpaintView.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.ImageInpaint"
1+
<UserControl x:Class="OnnxStack.UI.Views.ImageInpaintView"
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/ImageInpaint.xaml.cs renamed to OnnxStack.UI/Views/ImageInpaintView.xaml.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,11 @@
2121
namespace OnnxStack.UI.Views
2222
{
2323
/// <summary>
24-
/// Interaction logic for ImageInpaint.xaml
24+
/// Interaction logic for ImageInpaintView.xaml
2525
/// </summary>
26-
public partial class ImageInpaint : UserControl, INavigatable, INotifyPropertyChanged
26+
public partial class ImageInpaintView : UserControl, INavigatable, INotifyPropertyChanged
2727
{
28-
private readonly ILogger<ImageInpaint> _logger;
28+
private readonly ILogger<ImageInpaintView> _logger;
2929
private readonly IStableDiffusionService _stableDiffusionService;
3030

3131
private bool _hasResult;
@@ -47,13 +47,13 @@ public partial class ImageInpaint : UserControl, INavigatable, INotifyPropertyCh
4747

4848

4949
/// <summary>
50-
/// Initializes a new instance of the <see cref="ImageInpaint"/> class.
50+
/// Initializes a new instance of the <see cref="ImageInpaintView"/> class.
5151
/// </summary>
52-
public ImageInpaint()
52+
public ImageInpaintView()
5353
{
5454
if (!DesignerProperties.GetIsInDesignMode(this))
5555
{
56-
_logger = App.GetService<ILogger<ImageInpaint>>();
56+
_logger = App.GetService<ILogger<ImageInpaintView>>();
5757
_stableDiffusionService = App.GetService<IStableDiffusionService>();
5858
}
5959

@@ -76,7 +76,7 @@ public OnnxStackUIConfig UISettings
7676
set { SetValue(UISettingsProperty, value); }
7777
}
7878
public static readonly DependencyProperty UISettingsProperty =
79-
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(ImageInpaint));
79+
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(ImageInpaintView));
8080

8181
public List<DiffuserType> SupportedDiffusers { get; }
8282
public AsyncRelayCommand CancelCommand { get; }

OnnxStack.UI/Views/ImageToImage.xaml renamed to OnnxStack.UI/Views/ImageToImageView.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.ImageToImage"
1+
<UserControl x:Class="OnnxStack.UI.Views.ImageToImageView"
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/ImageToImage.xaml.cs renamed to OnnxStack.UI/Views/ImageToImageView.xaml.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,9 @@ namespace OnnxStack.UI.Views
2424
/// <summary>
2525
/// Interaction logic for ImageToImage.xaml
2626
/// </summary>
27-
public partial class ImageToImage : UserControl, INavigatable, INotifyPropertyChanged
27+
public partial class ImageToImageView : UserControl, INavigatable, INotifyPropertyChanged
2828
{
29-
private readonly ILogger<ImageToImage> _logger;
29+
private readonly ILogger<ImageToImageView> _logger;
3030
private readonly IStableDiffusionService _stableDiffusionService;
3131

3232
private bool _hasResult;
@@ -46,13 +46,13 @@ public partial class ImageToImage : UserControl, INavigatable, INotifyPropertyCh
4646

4747

4848
/// <summary>
49-
/// Initializes a new instance of the <see cref="ImageToImage"/> class.
49+
/// Initializes a new instance of the <see cref="ImageToImageView"/> class.
5050
/// </summary>
51-
public ImageToImage()
51+
public ImageToImageView()
5252
{
5353
if (!DesignerProperties.GetIsInDesignMode(this))
5454
{
55-
_logger = App.GetService<ILogger<ImageToImage>>();
55+
_logger = App.GetService<ILogger<ImageToImageView>>();
5656
_stableDiffusionService = App.GetService<IStableDiffusionService>();
5757
}
5858

@@ -75,7 +75,7 @@ public OnnxStackUIConfig UISettings
7575
set { SetValue(UISettingsProperty, value); }
7676
}
7777
public static readonly DependencyProperty UISettingsProperty =
78-
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(ImageToImage));
78+
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(ImageToImageView));
7979

8080
public List<DiffuserType> SupportedDiffusers { get; }
8181
public AsyncRelayCommand CancelCommand { get; }

OnnxStack.UI/Views/Logger.xaml renamed to OnnxStack.UI/Views/LoggerView.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.Logger"
1+
<UserControl x:Class="OnnxStack.UI.Views.LoggerView"
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/Logger.xaml.cs renamed to OnnxStack.UI/Views/LoggerView.xaml.cs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ namespace OnnxStack.UI.Views
1212
/// <summary>
1313
/// Interaction logic for Logger.xaml
1414
/// </summary>
15-
public partial class Logger : UserControl, INavigatable, INotifyPropertyChanged
15+
public partial class LoggerView : UserControl, INavigatable, INotifyPropertyChanged
1616
{
1717

1818
/// <summary>
19-
/// Initializes a new instance of the <see cref="Logger"/> class.
19+
/// Initializes a new instance of the <see cref="LoggerView"/> class.
2020
/// </summary>
21-
public Logger()
21+
public LoggerView()
2222
{
2323
ResetCommand = new AsyncRelayCommand(Reset, CanExecuteReset);
2424
InitializeComponent();
@@ -30,7 +30,7 @@ public OnnxStackUIConfig UISettings
3030
set { SetValue(UISettingsProperty, value); }
3131
}
3232
public static readonly DependencyProperty UISettingsProperty =
33-
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(Logger));
33+
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(LoggerView));
3434

3535
public AsyncRelayCommand ResetCommand { get; }
3636

@@ -44,7 +44,7 @@ public string LogOutput
4444
set { SetValue(LogOutputProperty, value); }
4545
}
4646
public static readonly DependencyProperty LogOutputProperty =
47-
DependencyProperty.Register("LogOutput", typeof(string), typeof(Logger));
47+
DependencyProperty.Register("LogOutput", typeof(string), typeof(LoggerView));
4848

4949

5050
public Task NavigateAsync(ImageResult imageResult)

OnnxStack.UI/Views/Settings.xaml renamed to OnnxStack.UI/Views/SettingsView.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.SettingsView"
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/SettingsView.xaml.cs

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
using Microsoft.Extensions.Logging;
22
using OnnxStack.Core.Config;
3-
using OnnxStack.StableDiffusion.Config;
43
using OnnxStack.UI.Commands;
54
using OnnxStack.UI.Models;
65
using System;
@@ -13,19 +12,19 @@
1312
namespace OnnxStack.UI.Views
1413
{
1514
/// <summary>
16-
/// Interaction logic for Settings.xaml
15+
/// Interaction logic for SettingsView.xaml
1716
/// </summary>
18-
public partial class Settings : UserControl, INavigatable, INotifyPropertyChanged
17+
public partial class SettingsView : UserControl, INavigatable, INotifyPropertyChanged
1918
{
20-
private readonly ILogger<Settings> _logger;
19+
private readonly ILogger<SettingsView> _logger;
2120

2221
/// <summary>
23-
/// Initializes a new instance of the <see cref="Settings"/> class.
22+
/// Initializes a new instance of the <see cref="SettingsView"/> class.
2423
/// </summary>
25-
public Settings()
24+
public SettingsView()
2625
{
2726
if (!DesignerProperties.GetIsInDesignMode(this))
28-
_logger = App.GetService<ILogger<Settings>>();
27+
_logger = App.GetService<ILogger<SettingsView>>();
2928

3029
SaveCommand = new AsyncRelayCommand(Save);
3130
InitializeComponent();
@@ -39,7 +38,7 @@ public OnnxStackUIConfig UISettings
3938
set { SetValue(UISettingsProperty, value); }
4039
}
4140
public static readonly DependencyProperty UISettingsProperty =
42-
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(Settings));
41+
DependencyProperty.Register("UISettings", typeof(OnnxStackUIConfig), typeof(SettingsView));
4342

4443

4544

0 commit comments

Comments
 (0)