Browse Source

Fix math node showing three inputs when created

CPKreuz 9 months ago
parent
commit
1da84c54f4
1 changed files with 3 additions and 2 deletions
  1. 3 2
      src/PixiEditor/ViewModels/Document/Nodes/MathNodeViewModel.cs

+ 3 - 2
src/PixiEditor/ViewModels/Document/Nodes/MathNodeViewModel.cs

@@ -27,10 +27,11 @@ internal class MathNodeViewModel : NodeViewModel<MathNode>
         Y = FindInputProperty("Y");
         Y = FindInputProperty("Y");
         Z = FindInputProperty("Z");
         Z = FindInputProperty("Z");
         
         
-        Mode.ValueChanged += ModeChanged;
+        Mode.ValueChanged += (_, _) => ModeChanged();
+        ModeChanged();
     }
     }
 
 
-    private void ModeChanged(INodePropertyHandler property, NodePropertyValueChangedArgs args)
+    private void ModeChanged()
     {
     {
         if (Mode.Value is not MathNodeMode mode)
         if (Mode.Value is not MathNodeMode mode)
             return;
             return;