private void ExecuteRevertDllToOriginal()
 {
     EnsurePluginSelected();
     EnsureEventConfigEntriesHaveCorrectDllModuleHydrated();
     RunWeavingExecutable(EventILWeaverCommandLineArgsGenerator.GenerateRevertToOriginalCommandLineArgs(_config), true);
     _config.HelperClassForceUseNoBuildSymbolInEditor = true;
 }
 private void ExecuteGenerateHelperClasses()
 {
     if (string.IsNullOrWhiteSpace(_config.HelperClassNamespace))
     {
         EditorUtility.DisplayDialog("Error", $"Namespace is required", "Ok");
     }
     else
     {
         EnsureEventConfigEntriesHaveCorrectDllModuleHydrated();
         RunWeavingExecutable(EventILWeaverCommandLineArgsGenerator.GenerateCreateHelperClassesArgs(_config), false);
     }
 }
        private void ExecuteWeaveEventsToDll()
        {
            EnsurePluginSelected();

            EnsureEventConfigEntriesHaveCorrectDllModuleHydrated();
            RunWeavingExecutable(EventILWeaverCommandLineArgsGenerator.GenerateAddEventsCommandLineArgs(_config), true);

            _config.HelperClassForceUseNoBuildSymbolInEditor = false;

            var result = EditorUtility.DisplayDialog("Warning",
                                                     $"Continue in console window, you'll likely need to close Editor for weaving to complete.\r\n\r\n" +
                                                     $"Weaving events for some types/properties (eg. Object.name) will crash Editor, it's possible more type/property combinations will cause similar issues.\r\n\r\n " +
                                                     $"A rollback script will be created and kept in same folder as plugin.\r\n" +
                                                     $" '{_config.IlWeaverPluginExecutablePath}'\r\n\r\n" +
                                                     $"If any issues occur run it to revert to backups.", "Close editor", "Keep open");

            if (result)
            {
                EditorApplication.Exit(0);
            }
        }