From ffd9d6f9e0ca3c2818e85ef8d720c356e9bf7a1c Mon Sep 17 00:00:00 2001 From: Chr1Z93 Date: Fri, 24 Nov 2023 15:17:21 +0100 Subject: [PATCH 1/2] added a "use custom url" button --- src/core/Global.ttslua | 7 +++++++ xml/Global/PlayareaGallery.xml | 13 +++++++++++++ 2 files changed, 20 insertions(+) diff --git a/src/core/Global.ttslua b/src/core/Global.ttslua index d1495748..4b21ce92 100644 --- a/src/core/Global.ttslua +++ b/src/core/Global.ttslua @@ -691,6 +691,13 @@ function onClick_select(_, _, identificationKey) updatePreviewWindow() end +-- click function for the "Custom URL" button in the playarea image gallery +function onClick_customUrl(player) + player.showInputDialog("Enter a custom URL for the playarea image", "", function(newURL) + playAreaApi.updateSurface(newURL) + end) +end + -- click function for the download button in the preview window function onClick_download(player) local params = library[contentToShow][currentListItem] diff --git a/xml/Global/PlayareaGallery.xml b/xml/Global/PlayareaGallery.xml index 83570b03..d03c66ec 100644 --- a/xml/Global/PlayareaGallery.xml +++ b/xml/Global/PlayareaGallery.xml @@ -12,6 +12,13 @@