mirror of
https://github.com/goatcorp/Dalamud.git
synced 2026-02-20 06:47:44 +01:00
* wip * hacky fix for overlapping event text in profiler * move IsResumeGameAfterPluginLoad logic to PluginManager * fix some warnings * handle exceptions properly * remove ability to cancel, rename button to "hide" instead * undo Dalamud.Service refactor for now * warnings * add explainer, show which plugins are still loading * add some text if loading takes more than 3 minutes * undo wrong CS merge
58 lines
1.4 KiB
C#
58 lines
1.4 KiB
C#
namespace Dalamud.Interface.Internal.Windows.Settings;
|
|
|
|
/// <summary>
|
|
/// Basic, drawable settings entry.
|
|
/// </summary>
|
|
public abstract class SettingsEntry
|
|
{
|
|
/// <summary>
|
|
/// Gets or sets the public, searchable name of this settings entry.
|
|
/// </summary>
|
|
public string? Name { get; protected set; }
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether or not this entry is valid.
|
|
/// </summary>
|
|
public virtual bool IsValid { get; protected set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets or sets a value indicating whether or not this entry is visible.
|
|
/// </summary>
|
|
public virtual bool IsVisible { get; protected set; } = true;
|
|
|
|
/// <summary>
|
|
/// Gets the ID of this settings entry, used for ImGui uniqueness.
|
|
/// </summary>
|
|
protected Guid Id { get; } = Guid.NewGuid();
|
|
|
|
/// <summary>
|
|
/// Load this setting.
|
|
/// </summary>
|
|
public abstract void Load();
|
|
|
|
/// <summary>
|
|
/// Save this setting.
|
|
/// </summary>
|
|
public abstract void Save();
|
|
|
|
/// <summary>
|
|
/// Draw this setting control.
|
|
/// </summary>
|
|
public abstract void Draw();
|
|
|
|
/// <summary>
|
|
/// Function to be called when the tab is opened.
|
|
/// </summary>
|
|
public virtual void OnOpen()
|
|
{
|
|
// ignored
|
|
}
|
|
|
|
/// <summary>
|
|
/// Function to be called when the tab is closed.
|
|
/// </summary>
|
|
public virtual void OnClose()
|
|
{
|
|
// ignored
|
|
}
|
|
}
|