refactor: update for api 9
This commit is contained in:
parent
5c7c751e48
commit
d1a47ecf76
|
@ -1,25 +1,23 @@
|
||||||
using Dalamud.Game.Command;
|
using Dalamud.IoC;
|
||||||
using Dalamud.Game.Gui;
|
|
||||||
using Dalamud.Game.Gui.Toast;
|
|
||||||
using Dalamud.IoC;
|
|
||||||
using Dalamud.Plugin;
|
using Dalamud.Plugin;
|
||||||
|
using Dalamud.Plugin.Services;
|
||||||
using XivCommon;
|
using XivCommon;
|
||||||
|
|
||||||
namespace BurntToast {
|
namespace BurntToast {
|
||||||
public class BurntToast : IDalamudPlugin {
|
public class BurntToast : IDalamudPlugin {
|
||||||
public string Name => "Burnt Toast";
|
internal static string Name => "Burnt Toast";
|
||||||
|
|
||||||
[PluginService]
|
[PluginService]
|
||||||
internal DalamudPluginInterface Interface { get; private init; } = null!;
|
internal DalamudPluginInterface Interface { get; private init; } = null!;
|
||||||
|
|
||||||
[PluginService]
|
[PluginService]
|
||||||
internal ChatGui ChatGui { get; private init; } = null!;
|
internal IChatGui ChatGui { get; private init; } = null!;
|
||||||
|
|
||||||
[PluginService]
|
[PluginService]
|
||||||
internal CommandManager CommandManager { get; private init; } = null!;
|
internal ICommandManager CommandManager { get; private init; } = null!;
|
||||||
|
|
||||||
[PluginService]
|
[PluginService]
|
||||||
internal ToastGui ToastGui { get; private init; } = null!;
|
internal IToastGui ToastGui { get; private init; } = null!;
|
||||||
|
|
||||||
internal Configuration Config { get; }
|
internal Configuration Config { get; }
|
||||||
internal PluginUi Ui { get; }
|
internal PluginUi Ui { get; }
|
||||||
|
|
|
@ -65,7 +65,7 @@ namespace BurntToast {
|
||||||
isHandled = true;
|
isHandled = true;
|
||||||
|
|
||||||
if (pattern.ShowMessage) {
|
if (pattern.ShowMessage) {
|
||||||
this.Plugin.ChatGui.PrintChat(new XivChatEntry {
|
this.Plugin.ChatGui.Print(new XivChatEntry {
|
||||||
Type = (XivChatType) 68,
|
Type = (XivChatType) 68,
|
||||||
Name = sender.TextValue,
|
Name = sender.TextValue,
|
||||||
Message = message,
|
Message = message,
|
||||||
|
|
|
@ -41,7 +41,7 @@ namespace BurntToast {
|
||||||
|
|
||||||
ImGui.SetNextWindowSize(new Vector2(450, 200), ImGuiCond.FirstUseEver);
|
ImGui.SetNextWindowSize(new Vector2(450, 200), ImGuiCond.FirstUseEver);
|
||||||
|
|
||||||
if (!ImGui.Begin($"{this.Plugin.Name} settings", ref this._showSettings)) {
|
if (!ImGui.Begin($"{BurntToast.Name} settings", ref this._showSettings)) {
|
||||||
ImGui.End();
|
ImGui.End();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue