public void ChangeTool(string toolName) { currentToolName = toolName; var args = new ToolChangedArgs { toolName = currentToolName }; OnToolChangedEvent?.Invoke(this, args); ShowCurrentTool(showTools); }
void OnToolChanged(object sender, ToolChangedArgs args) { bool switchToAnim = args.toolName == "Animation"; if (switchToAnim && !isAnimationTool) { UpdateFromSelection(); } if (!switchToAnim && isAnimationTool) { DeleteGoalCurves(); } isAnimationTool = switchToAnim; }
public static void OnChangeTool(object sender, ToolChangedArgs args) { ChangeTool(args.toolName); }