Core - Fixed a lot of compiler warnings

Scripting - Added script renaming/deleting
This commit is contained in:
Robert committed 2021-06-21 19:34:34 +02:00
1 parent 4a69baebb7
commit 5367027471
36 files changed
+434 -96

No files matched your search

@@ -1,6 +1,5 @@
using System.Windows;
using System.Windows.Controls;
using MaterialDesignThemes.Wpf;
namespace Artemis.UI.Shared
@@ -11,16 +10,22 @@ namespace Artemis.UI.Shared
public partial class ProfileConfigurationIcon : UserControl
{
/// <summary>
/// Gets or sets the <see cref="PackIconKind" />
/// Gets or sets the <see cref="Core.ProfileConfigurationIcon" /> to display
/// </summary>
public static readonly DependencyProperty ConfigurationIconProperty =
DependencyProperty.Register(nameof(ConfigurationIcon), typeof(Core.ProfileConfigurationIcon), typeof(ProfileConfigurationIcon));
/// <summary>
/// Creates a new instance of the <see cref="ProfileConfigurationIcon" /> class
/// </summary>
public ProfileConfigurationIcon()
{
InitializeComponent();
}
/// <summary>
/// Gets or sets the <see cref="Core.ProfileConfigurationIcon" /> to display
/// </summary>
public Core.ProfileConfigurationIcon ConfigurationIcon
{
get => (Core.ProfileConfigurationIcon) GetValue(ConfigurationIconProperty);
@@ -17,7 +17,7 @@ namespace Artemis.UI.Shared
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value is not Stream stream)
return null;
return Binding.DoNothing;
stream.Position = 0;
@@ -19,7 +19,7 @@ namespace Artemis.UI.Shared
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
if (value is not Stream stream)
return null;
return Binding.DoNothing;
stream.Position = 0;
@@ -2,12 +2,21 @@
namespace Artemis.UI.Shared
{
/// <summary>
/// Providers a proxy between data contexts
/// </summary>
public class BindingProxy : Freezable
{
// Using a DependencyProperty as the backing store for Data. This enables animation, styling, binding, etc...
/// <summary>
/// Gets or sets the data that was proxied
/// </summary>
public static readonly DependencyProperty DataProperty =
DependencyProperty.Register("Data", typeof(object), typeof(BindingProxy), new UIPropertyMetadata(null));
/// <summary>
/// Gets or sets the data that was proxied
/// </summary>
public object Data
{
get => GetValue(DataProperty);
@@ -16,6 +25,7 @@ namespace Artemis.UI.Shared
#region Overrides of Freezable
/// <inheritdoc />
protected override Freezable CreateInstanceCore()
{
return new BindingProxy();