mirror of
https://github.com/Artemis-RGB/Artemis
synced 2026-11-11 19:36:28 +00:00
Plugins - Added RequiresAdmin boolean
Utilities - Simplified shutdown method signature Utilities - Added restart method with option to elevate Core - Moved actual shutdown/restart logic to UI
This commit is contained in:
1 parent
281c18200a
commit
de5b8e4458
12 files changed
+151
-39
No files matched your search
@@ -17,6 +17,7 @@ namespace Artemis.Core
|
||||
private string _main = null!;
|
||||
private string _name = null!;
|
||||
private Plugin _plugin = null!;
|
||||
private bool _requiresAdmin;
|
||||
private Version _version = null!;
|
||||
|
||||
internal PluginInfo()
|
||||
@@ -86,7 +87,8 @@ namespace Artemis.Core
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets or sets a boolean indicating whether this plugin should automatically enable all its features when it is first loaded
|
||||
/// Gets or sets a boolean indicating whether this plugin should automatically enable all its features when it is first
|
||||
/// loaded
|
||||
/// </summary>
|
||||
[DefaultValue(true)]
|
||||
[JsonProperty(DefaultValueHandling = DefaultValueHandling.Populate)]
|
||||
@@ -96,6 +98,16 @@ namespace Artemis.Core
|
||||
set => SetAndNotify(ref _autoEnableFeatures, value);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets a boolean indicating whether this plugin requires elevated admin privileges
|
||||
/// </summary>
|
||||
[JsonProperty]
|
||||
public bool RequiresAdmin
|
||||
{
|
||||
get => _requiresAdmin;
|
||||
internal set => SetAndNotify(ref _requiresAdmin, value);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the plugin this info is associated with
|
||||
/// </summary>
|
||||
|
||||
Reference in new issue
Block a user