mirror of
https://github.com/sinai-dev/UnityExplorer.git
synced 2025-06-16 06:08:16 +08:00
Cancel pending generic when edit button pressed
This commit is contained in:
parent
e92556805b
commit
14f46ade6a
@ -39,6 +39,8 @@ namespace UnityExplorer.Hooks
|
|||||||
internal static Type pendingGenericDefinition;
|
internal static Type pendingGenericDefinition;
|
||||||
internal static MethodInfo pendingGenericMethod;
|
internal static MethodInfo pendingGenericMethod;
|
||||||
|
|
||||||
|
public static bool PendingGeneric => pendingGenericDefinition != null || pendingGenericMethod != null;
|
||||||
|
|
||||||
// Hook Source Editor UI
|
// Hook Source Editor UI
|
||||||
public static GameObject EditorRoot { get; private set; }
|
public static GameObject EditorRoot { get; private set; }
|
||||||
public static Text EditingHookLabel { get; private set; }
|
public static Text EditingHookLabel { get; private set; }
|
||||||
|
@ -47,6 +47,9 @@ namespace UnityExplorer.Hooks
|
|||||||
|
|
||||||
public static void EditPatchClicked(int index)
|
public static void EditPatchClicked(int index)
|
||||||
{
|
{
|
||||||
|
if (HookCreator.PendingGeneric)
|
||||||
|
HookManagerPanel.genericArgsHandler.Cancel();
|
||||||
|
|
||||||
HookManagerPanel.Instance.SetPage(HookManagerPanel.Pages.HookSourceEditor);
|
HookManagerPanel.Instance.SetPage(HookManagerPanel.Pages.HookSourceEditor);
|
||||||
HookInstance hook = (HookInstance)currentHooks[index];
|
HookInstance hook = (HookInstance)currentHooks[index];
|
||||||
HookCreator.SetEditedHook(hook);
|
HookCreator.SetEditedHook(hook);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user