mirror of
https://github.com/goatcorp/Dalamud.git
synced 2026-01-03 06:13:40 +01:00
make "start on boot" work as expected for dev plugins
This commit is contained in:
parent
9b3990e5c7
commit
3f112376eb
2 changed files with 29 additions and 16 deletions
|
|
@ -862,10 +862,17 @@ Thanks and have fun!";
|
|||
var devPlugin = new LocalDevPlugin(dllFile, manifest);
|
||||
loadPlugin &= !isBoot || devPlugin.StartOnBoot;
|
||||
|
||||
// If we're not loading it, make sure it's disabled
|
||||
// NOTE: Should be taken care of below by the profile code
|
||||
// if (!loadPlugin && !devPlugin.IsDisabled)
|
||||
// devPlugin.Disable();
|
||||
var probablyInternalNameForThisPurpose = manifest?.InternalName ?? dllFile.Name;
|
||||
var wantsInDefaultProfile =
|
||||
this.profileManager.DefaultProfile.WantsPlugin(probablyInternalNameForThisPurpose);
|
||||
if (wantsInDefaultProfile == false && devPlugin.StartOnBoot)
|
||||
{
|
||||
this.profileManager.DefaultProfile.AddOrUpdate(probablyInternalNameForThisPurpose, true, false);
|
||||
}
|
||||
else if (wantsInDefaultProfile == true && !devPlugin.StartOnBoot)
|
||||
{
|
||||
this.profileManager.DefaultProfile.AddOrUpdate(probablyInternalNameForThisPurpose, false, false);
|
||||
}
|
||||
|
||||
plugin = devPlugin;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue