mirror of
https://github.com/goatcorp/Dalamud.git
synced 2025-12-14 20:54:16 +01:00
feat: warn if boot plugin load takes longer than 2 minutes
This commit is contained in:
parent
f9ab1dbf26
commit
bcc30e8731
1 changed files with 13 additions and 0 deletions
|
|
@ -44,6 +44,8 @@ namespace Dalamud.Interface.Internal.Windows.PluginInstaller
|
||||||
|
|
||||||
private readonly List<int> openPluginCollapsibles = new();
|
private readonly List<int> openPluginCollapsibles = new();
|
||||||
|
|
||||||
|
private readonly DateTime timeLoaded;
|
||||||
|
|
||||||
#region Image Tester State
|
#region Image Tester State
|
||||||
|
|
||||||
private string[] testerImagePaths = new string[5];
|
private string[] testerImagePaths = new string[5];
|
||||||
|
|
@ -128,6 +130,8 @@ namespace Dalamud.Interface.Internal.Windows.PluginInstaller
|
||||||
this.testerImagePaths[i] = string.Empty;
|
this.testerImagePaths[i] = string.Empty;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
this.timeLoaded = DateTime.Now;
|
||||||
}
|
}
|
||||||
|
|
||||||
private enum OperationStatus
|
private enum OperationStatus
|
||||||
|
|
@ -326,6 +330,15 @@ namespace Dalamud.Interface.Internal.Windows.PluginInstaller
|
||||||
throw new ArgumentOutOfRangeException();
|
throw new ArgumentOutOfRangeException();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (DateTime.Now - this.timeLoaded > TimeSpan.FromMinutes(2) && isWaitingManager)
|
||||||
|
{
|
||||||
|
ImGui.PushStyleColor(ImGuiCol.Text, ImGuiColors.DalamudRed);
|
||||||
|
ImGuiHelpers.CenteredText("This is embarrassing, but...");
|
||||||
|
ImGuiHelpers.CenteredText("one of your plugins may be blocking the installer.");
|
||||||
|
ImGuiHelpers.CenteredText("You should tell us about this.");
|
||||||
|
ImGui.PopStyleColor();
|
||||||
|
}
|
||||||
|
|
||||||
ImGui.EndChild();
|
ImGui.EndChild();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue