Skip to content

Commit

Permalink
[Code] Remove unused usings
Browse files Browse the repository at this point in the history
  • Loading branch information
BAndysc committed Aug 4, 2021
1 parent 93b1eca commit 1857b09
Show file tree
Hide file tree
Showing 263 changed files with 138 additions and 684 deletions.
1 change: 0 additions & 1 deletion AvaloniaStyles/Controls/DismissPopupBehaviour.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
using Avalonia.Input;
using Avalonia.Interactivity;
using Avalonia.LogicalTree;
using Avalonia.VisualTree;
using Avalonia.Xaml.Interactivity;

namespace AvaloniaStyles.Controls
Expand Down
1 change: 0 additions & 1 deletion AvaloniaStyles/Controls/ExtendedTitleBar.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
using Avalonia;
using Avalonia.Controls;
using Avalonia.LogicalTree;
using Avalonia.Metadata;

namespace AvaloniaStyles.Controls
{
Expand Down
10 changes: 4 additions & 6 deletions AvaloniaStyles/Controls/ExtendedWindow.cs
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@
using Avalonia;
using Avalonia.Controls;
using Avalonia.Controls.Primitives;
using Avalonia.Input;
using Avalonia.Interactivity;
using Avalonia.LogicalTree;
using Avalonia.Media;
using Avalonia.Platform;
Expand All @@ -23,8 +21,8 @@ public class ExtendedWindow : Window, IStyleable
public static readonly StyledProperty<ToolBar> ToolBarProperty =
AvaloniaProperty.Register<ExtendedWindow, ToolBar>(nameof(ToolBar));

public static readonly StyledProperty<IControl> SideBarProperty =
AvaloniaProperty.Register<ExtendedWindow, IControl>(nameof(SideBar));
public static readonly StyledProperty<IControl?> SideBarProperty =
AvaloniaProperty.Register<ExtendedWindow, IControl?>(nameof(SideBar));

public static readonly StyledProperty<StatusBar> StatusBarProperty =
AvaloniaProperty.Register<ExtendedWindow, StatusBar>(nameof(StatusBar));
Expand Down Expand Up @@ -53,7 +51,7 @@ public ToolBar ToolBar
set => SetValue(ToolBarProperty, value);
}

public IControl SideBar
public IControl? SideBar
{
get => GetValue(SideBarProperty);
set => SetValue(SideBarProperty, value);
Expand Down Expand Up @@ -81,7 +79,7 @@ public TabStrip TabStrip

static ExtendedWindow()
{
IsActiveProperty.Changed.AddClassHandler<ExtendedWindow>((x, e) =>
IsActiveProperty.Changed.AddClassHandler<ExtendedWindow>((x, _) =>
x.PseudoClasses.Set(":focused", x.IsActive));
ToolBarProperty.Changed.AddClassHandler<ExtendedWindow>((x, e) => x.ContentChanged(e, ":has-toolbar"));
SideBarProperty.Changed.AddClassHandler<ExtendedWindow>((x, e) => x.ContentChanged(e, ":has-sidebar"));
Expand Down
21 changes: 8 additions & 13 deletions AvaloniaStyles/Controls/GroupingListBox.axaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@
using Avalonia.Metadata;
using Avalonia.Styling;
using Avalonia.VisualTree;
using JetBrains.Annotations;

namespace AvaloniaStyles.Controls
{
Expand Down Expand Up @@ -60,24 +59,24 @@ public class GroupingListBox : TemplatedControl
(o, v) => o.SelectedItem = v,
defaultBindingMode: BindingMode.TwoWay);

private object? _selectedItem;
private object? selectedItem;

public object? SelectedItem
{
get => _selectedItem;
set => SetAndRaise(SelectedItemProperty, ref _selectedItem, value);
get => selectedItem;
set => SetAndRaise(SelectedItemProperty, ref selectedItem, value);
}

public static readonly DirectProperty<GroupingListBox, IEnumerable> ItemsProperty =
AvaloniaProperty.RegisterDirect<GroupingListBox, IEnumerable>(nameof(Items), o => o.Items, (o, v) => o.Items = v);

private IEnumerable _items = new AvaloniaList<object>();
private IEnumerable items = new AvaloniaList<object>();

[Content]
public IEnumerable Items
{
get => _items;
set => SetAndRaise(ItemsProperty, ref _items, value);
get => items;
set => SetAndRaise(ItemsProperty, ref items, value);
}

private static readonly FuncTemplate<IPanel> DefaultPanel =
Expand Down Expand Up @@ -167,7 +166,7 @@ private void OnPreviewKeyDown(object? sender, KeyEventArgs e)
if (that == null)
return;

var parent = FindParent<ItemsControl>(that!);
var parent = FindParent<ItemsControl>(that);

if (parent == null)
return;
Expand Down Expand Up @@ -308,11 +307,7 @@ internal class GroupingListBoxInner : ListBox, IStyleable
public object? CustomSelectedItem
{
get => SelectedItem;
set
{
var old = SelectedItem;
SelectedItem = value;
}
set => SelectedItem = value;
}

private static bool inEvent;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
using System;
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Runtime.CompilerServices;
using Avalonia;
using Avalonia.Collections;
using Avalonia.Controls;
using Avalonia.Controls.Primitives;
using JetBrains.Annotations;

Expand Down Expand Up @@ -36,7 +33,7 @@ static NumberIndicator()
o.items[(int)nnew].IsActive = true;
});

StepsCountProperty.Changed.AddClassHandler<NumberIndicator>((o, e) =>
StepsCountProperty.Changed.AddClassHandler<NumberIndicator>((o, _) =>
{
while (o.items.Count > o.stepsCount)
o.items.RemoveAt(o.items.Count - 1);
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
using System;
using Avalonia;
using Avalonia.Controls;
using Avalonia.Controls.Primitives;
Expand Down
2 changes: 0 additions & 2 deletions AvaloniaStyles/Controls/ToolBar.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
using Avalonia;
using Avalonia.Controls;
using Avalonia.Controls.Primitives;
using Avalonia.LogicalTree;
using Avalonia.Metadata;

namespace AvaloniaStyles.Controls
{
Expand Down
1 change: 0 additions & 1 deletion AvaloniaStyles/Controls/WizardPanel.axaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@
using Avalonia.Data;
using Avalonia.Markup.Xaml.Templates;
using Avalonia.Metadata;
using Avalonia.VisualTree;
using AvaloniaStyles.Utils;

namespace AvaloniaStyles.Controls
Expand Down
6 changes: 0 additions & 6 deletions AvaloniaStyles/Demo/MainWindow.axaml.cs
Original file line number Diff line number Diff line change
@@ -1,15 +1,9 @@
using System;
using System.Collections.ObjectModel;
using System.Threading.Tasks;
using Avalonia;
using Avalonia.Controls;
using Avalonia.Interactivity;
using Avalonia.Markup.Xaml;
using Avalonia.Markup.Xaml.Styling;
using Avalonia.Styling;
using Avalonia.Threading;
using AvaloniaStyles.Controls;
using DynamicData;

namespace AvaloniaStyles.Demo
{
Expand Down
2 changes: 1 addition & 1 deletion Directory.Build.props
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<Project>
<PropertyGroup>
<NoWarn>CS0067,CS4014,CS3021,CS1998,CA1416</NoWarn>
<NoWarn>CS0067,CS3021,CS1998,CA1416</NoWarn>
<AvaloniaVersion>0.10.0</AvaloniaVersion>
</PropertyGroup>
</Project>
4 changes: 1 addition & 3 deletions QuestChainTest/App.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System.Windows;

namespace QuestChainTest
namespace QuestChainTest
{
/// <summary>
/// Interaction logic for App.xaml
Expand Down
3 changes: 1 addition & 2 deletions QuestChainTest/ExampleQuestsProvider.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using System.Collections.Generic;
using WDE.QuestChainEditor.Models;
using WDE.QuestChainEditor.Models;
using WDE.QuestChainEditor.Providers;

namespace QuestChainTest
Expand Down
18 changes: 1 addition & 17 deletions QuestChainTest/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,20 +1,4 @@
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using System.Windows;
using WDE.Common.CoreVersion;
using WDE.Common.Database;
using WDE.Common.Tasks;
using WDE.MySqlDatabaseCommon.Services;
using WDE.QuestChainEditor.Editor.ViewModels;
using WDE.QuestChainEditor.Exporter;
using WDE.QuestChainEditor.Models;
using WDE.QuestChainEditor.Providers;
using WDE.TrinityMySqlDatabase;
using WDE.TrinityMySqlDatabase.Database;
using WDE.TrinityMySqlDatabase.Providers;

namespace QuestChainTest
namespace QuestChainTest
{
/// <summary>
/// Interaction logic for MainWindow.xaml
Expand Down
4 changes: 1 addition & 3 deletions QuestChainTest/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System.Reflection;
using System.Runtime.InteropServices;
using System.Windows;


// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
Expand Down
3 changes: 1 addition & 2 deletions WDE.Blueprints/BlueprintSolutionItem.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using System.Collections.ObjectModel;
using WDE.Common;
using WDE.Common;

namespace WDE.Blueprints
{
Expand Down
4 changes: 1 addition & 3 deletions WDE.Blueprints/Data/InputOutputData.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Data
{
Expand Down
5 changes: 1 addition & 4 deletions WDE.Blueprints/Data/NodeDefinition.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
using System.Collections.Generic;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Data
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System.Collections.Generic;
using System.Windows.Media;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Editor.DisignTimeViewModels
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
using System.Collections.Generic;
using System.ComponentModel;
using System.Windows.Data;

namespace WDE.Blueprints.Editor.DisignTimeViewModels
namespace WDE.Blueprints.Editor.DisignTimeViewModels
{
internal class NodePickerViewModel
{
Expand Down
6 changes: 1 addition & 5 deletions WDE.Blueprints/Editor/ViewModels/BlueprintEditorViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
using System.Windows.Input;
using AsyncAwaitBestPractices.MVVM;
using ExtensionMethods;
using Prism.Mvvm;
using WDE.Blueprints.Data;
using WDE.Blueprints.Data;
using WDE.Blueprints.Editor.Views;
using WDE.Blueprints.Enums;
using WDE.Common.History;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
using System;
using System.Windows;
using Prism.Mvvm;

namespace WDE.Blueprints.Editor.ViewModels
namespace WDE.Blueprints.Editor.ViewModels
{
public class ConnectionViewModel : BindableBase
{
Expand Down
6 changes: 1 addition & 5 deletions WDE.Blueprints/Editor/ViewModels/Graph/ConnectorViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,8 +1,4 @@
using System;
using System.Windows;
using System.Windows.Media;
using Prism.Mvvm;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Editor.ViewModels
{
Expand Down
8 changes: 1 addition & 7 deletions WDE.Blueprints/Editor/ViewModels/Graph/ElementViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Windows.Media;
using Prism.Mvvm;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Editor.ViewModels
{
Expand Down
9 changes: 1 addition & 8 deletions WDE.Blueprints/Editor/ViewModels/Graph/GraphViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,11 +1,4 @@
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Windows;
using Prism.Mvvm;

namespace WDE.Blueprints.Editor.ViewModels
namespace WDE.Blueprints.Editor.ViewModels
{
public class GraphViewModel : BindableBase
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System;
using System.Windows.Media;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Editor.ViewModels
{
Expand Down
3 changes: 1 addition & 2 deletions WDE.Blueprints/Editor/ViewModels/Graph/NodeViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using System.Windows.Media;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Editor.ViewModels
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System.Collections.ObjectModel;
using System.Windows.Media;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Enums;

namespace WDE.Blueprints.Editor.ViewModels
{
Expand Down
7 changes: 1 addition & 6 deletions WDE.Blueprints/Editor/ViewModels/NodesViewModel.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,4 @@
using System.Collections.ObjectModel;
using System.ComponentModel;
using System.Linq;
using System.Windows.Data;
using Prism.Mvvm;
using WDE.Blueprints.Data;
using WDE.Blueprints.Data;
using WDE.Blueprints.Enums;
using WDE.Blueprints.Managers;

Expand Down
5 changes: 1 addition & 4 deletions WDE.Blueprints/Editor/Views/BlueprintEditorView.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using WDE.Blueprints.Editor.ViewModels;
using WDE.Blueprints.Editor.ViewModels;

namespace WDE.Blueprints.Editor.Views
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,4 @@
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;
using GeminiGraphEditor;
using GeminiGraphEditor;
using WDE.Blueprints.Editor.ViewModels;

namespace WDE.Blueprints.Editor.Views
Expand Down
4 changes: 1 addition & 3 deletions WDE.Blueprints/Editor/Views/ConnectionLineView.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System.Windows.Controls;

namespace WDE.Blueprints.Editor.Views
namespace WDE.Blueprints.Editor.Views
{
/// <summary>
/// Interaction logic for ConnectionLineView.xaml
Expand Down
4 changes: 1 addition & 3 deletions WDE.Blueprints/Editor/Views/ConnectorView.xaml.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
using System.Windows.Controls;

namespace WDE.Blueprints.Editor.Views
namespace WDE.Blueprints.Editor.Views
{
/// <summary>
/// Interaction logic for ConnectorView.xaml
Expand Down
Loading

0 comments on commit 1857b09

Please sign in to comment.