/// <summary> /// Adds a script extension to this thread. /// </summary> /// <param name="extension"></param> public static void Add(ScriptExtension extension) { if (_extensions.Contains(extension)) { return; } extension.RegisterEvent("keydown"); _extensions.Add(extension); extension.OnThreadAttached(); }
internal static void Remove(ScriptExtension extension) { extension.OnThreadDetached(); _extensions.Remove(extension); }