Use past tense

This commit is contained in:
Haselnussbomber 2025-08-04 03:17:50 +02:00
parent 089f0c9495
commit bac45c5e30
No known key found for this signature in database
GPG key ID: BB905BB49E7295D1
3 changed files with 19 additions and 7 deletions

View file

@ -5,15 +5,27 @@ namespace Dalamud.Plugin;
/// <summary>
/// Contains data about changes to the list of active plugins.
/// </summary>
public class ActivePluginsChangedEventArgs(PluginListInvalidationKind kind, IEnumerable<string> affectedInternalNames) : EventArgs
public class ActivePluginsChangedEventArgs : EventArgs
{
/// <summary>
/// Initializes a new instance of the <see cref="ActivePluginsChangedEventArgs"/> class
/// with the specified parameters.
/// </summary>
/// <param name="kind">The kind of change that triggered the event.</param>
/// <param name="affectedInternalNames">The internal names of the plugins affected by the change.</param>
internal ActivePluginsChangedEventArgs(PluginListInvalidationKind kind, IEnumerable<string> affectedInternalNames)
{
this.Kind = kind;
this.AffectedInternalNames = affectedInternalNames;
}
/// <summary>
/// Gets the invalidation kind that caused this event to be fired.
/// </summary>
public PluginListInvalidationKind Kind { get; } = kind;
public PluginListInvalidationKind Kind { get; }
/// <summary>
/// Gets the InternalNames of affected plugins.
/// </summary>
public IEnumerable<string> AffectedInternalNames { get; } = affectedInternalNames;
public IEnumerable<string> AffectedInternalNames { get; }
}

View file

@ -397,7 +397,7 @@ internal class LocalPlugin : IAsyncDisposable
Log.Information("Finished loading {PluginName}", this.InternalName);
var manager = Service<PluginManager>.Get();
manager.NotifyPluginsForStateChange(PluginListInvalidationKind.Load, [this.manifest.InternalName]);
manager.NotifyPluginsForStateChange(PluginListInvalidationKind.Loaded, [this.manifest.InternalName]);
}
catch (Exception ex)
{
@ -475,7 +475,7 @@ internal class LocalPlugin : IAsyncDisposable
Log.Information("Finished unloading {PluginName}", this.InternalName);
var manager = Service<PluginManager>.Get();
manager.NotifyPluginsForStateChange(PluginListInvalidationKind.Unload, [this.manifest.InternalName]);
manager.NotifyPluginsForStateChange(PluginListInvalidationKind.Unloaded, [this.manifest.InternalName]);
}
catch (Exception ex)
{

View file

@ -8,12 +8,12 @@ public enum PluginListInvalidationKind
/// <summary>
/// A plugin was loaded.
/// </summary>
Load,
Loaded,
/// <summary>
/// A plugin was unloaded.
/// </summary>
Unload,
Unloaded,
/// <summary>
/// An installer-initiated update reloaded plugins.