Added button to jump to template editing from profile tab, made TemplateManager IDisposable
This commit is contained in:
33
CustomizePlus/Templates/Events/TemplateEditorEvent.cs
Normal file
33
CustomizePlus/Templates/Events/TemplateEditorEvent.cs
Normal file
@@ -0,0 +1,33 @@
|
||||
using CustomizePlus.Templates.Data;
|
||||
using OtterGui.Classes;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
|
||||
namespace CustomizePlus.Templates.Events;
|
||||
|
||||
/// <summary>
|
||||
/// Triggered when something related to template editor happens
|
||||
/// </summary>
|
||||
public class TemplateEditorEvent() : EventWrapper<TemplateEditorEvent.Type, Template?, TemplateEditorEvent.Priority>(nameof(TemplateEditorEvent))
|
||||
{
|
||||
public enum Type
|
||||
{
|
||||
/// <summary>
|
||||
/// Called when something requests editor to be enabled.
|
||||
/// </summary>
|
||||
EditorEnableRequested,
|
||||
/// <summary>
|
||||
/// Called when something requests editor to be enabled. Stage 2 - logic after tab has been switched.
|
||||
/// </summary>
|
||||
EditorEnableRequestedStage2
|
||||
}
|
||||
|
||||
public enum Priority
|
||||
{
|
||||
MainWindow = -1,
|
||||
TemplatePanel
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user