- Loc updates

- Add access URL to webinterface panel
This commit is contained in:
Infi
2024-08-28 14:31:25 +02:00
parent 2ababa82b0
commit 8d6f59f9fa
5 changed files with 59 additions and 26 deletions
+2 -16
View File
@@ -417,7 +417,7 @@ public sealed class PayloadHandler {
GameFunctions.GameFunctions.OpenPartyFinder();
break;
case UriPayload uri:
TryOpenURI(uri.Uri);
WrapperUtil.TryOpenURI(uri.Uri);
break;
default:
RightClickPayload(chunk, payload);
@@ -671,7 +671,7 @@ public sealed class PayloadHandler {
ImGui.Separator();
if (ImGui.Selectable(Language.Context_OpenInBrowser))
TryOpenURI(uri.Uri);
WrapperUtil.TryOpenURI(uri.Uri);
if (ImGui.Selectable(Language.Context_CopyLink))
{
@@ -679,18 +679,4 @@ public sealed class PayloadHandler {
WrapperUtil.AddNotification(Language.Context_CopyLinkNotification, NotificationType.Info);
}
}
private void TryOpenURI(Uri uri)
{
try
{
Plugin.Log.Debug($"Opening URI {uri} in default browser");
Dalamud.Utility.Util.OpenLink(uri.ToString());
}
catch (Exception ex)
{
Plugin.Log.Error($"Error opening URI: {ex}");
WrapperUtil.AddNotification(Language.Context_OpenInBrowserError, NotificationType.Error);
}
}
}