コード例 #1
0
        public virtual void HandleRemovedFromManager(PluginManager manager)
        {
            this.UnregisterWithCovalence();
            if (this.Manager == manager)
            {
                this.Manager = null;
            }
            PluginManagerEvent onRemovedFromManager = this.OnRemovedFromManager;

            if (onRemovedFromManager == null)
            {
                return;
            }
            onRemovedFromManager.Invoke(this, manager);
        }
コード例 #2
0
        public virtual void HandleAddedToManager(PluginManager manager)
        {
            this.Manager = manager;
            if (this.HasConfig)
            {
                this.LoadConfig();
            }
            if (this.HasMessages)
            {
                this.LoadDefaultMessages();
            }
            PluginManagerEvent onAddedToManager = this.OnAddedToManager;

            if (onAddedToManager != null)
            {
                onAddedToManager.Invoke(this, manager);
            }
            else
            {
            }
            this.RegisterWithCovalence();
        }