Browse Source

Null and error fixes

flabbet 3 years ago
parent
commit
901d53a28f

+ 1 - 1
PixiEditor/Views/UserControls/Lospec/LospecPaletteBrowser.xaml.cs

@@ -13,7 +13,7 @@ using System.Windows.Media.Imaging;
 using System.Windows.Navigation;
 using System.Windows.Shapes;
 
-namespace PixiEditor.Views.UserControls
+namespace PixiEditor.Views.UserControls.Lospec
 {
     /// <summary>
     /// Interaction logic for LospecPaletteBrowser.xaml

+ 1 - 0
PixiEditor/Views/UserControls/PaletteColorAdder.xaml.cs

@@ -47,6 +47,7 @@ namespace PixiEditor.Views.UserControls
         private static void OnColorsChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
         {
             PaletteColorAdder adder = (PaletteColorAdder)d;
+            if (adder == null || adder.Colors == null) return;
             if (e.NewValue != null)
             {
                 adder.Colors.CollectionChanged += adder.Colors_CollectionChanged;