summaryrefslogtreecommitdiff
path: root/indra/llplugin
diff options
context:
space:
mode:
authorJonathan "Geenz" Goodman <geenz@lindenlab.com>2026-05-19 18:51:02 -0400
committerGitHub <noreply@github.com>2026-05-19 18:51:02 -0400
commit6d4c4c029ce43aa413266135829cd2bc00001890 (patch)
tree209ae880aba5ac777d524bdc557ed166b466347f /indra/llplugin
parent5c500ccf407f0b5a0b253b98dd4bd3f33f643aba (diff)
parent115686ca0f962da9ec5dbcdbe54a4cb6c86302bb (diff)
Merge pull request #5369 from secondlife/release/2026.02
Release/2026.02
Diffstat (limited to 'indra/llplugin')
-rw-r--r--indra/llplugin/llpluginclassmedia.cpp12
-rw-r--r--indra/llplugin/llpluginclassmedia.h2
2 files changed, 14 insertions, 0 deletions
diff --git a/indra/llplugin/llpluginclassmedia.cpp b/indra/llplugin/llpluginclassmedia.cpp
index 77a4b08af5..a1e1f75367 100644
--- a/indra/llplugin/llpluginclassmedia.cpp
+++ b/indra/llplugin/llpluginclassmedia.cpp
@@ -1641,3 +1641,15 @@ void LLPluginClassMedia::initializeUrlHistory(const LLSD& url_history)
LL_DEBUGS("Plugin") << "Sending history" << LL_ENDL;
}
+
+void LLPluginClassMedia::forceRenderRefresh()
+{
+ // Force layout recalculation by briefly hiding/showing the web content
+ // Used to clear black screen issues after resize, see #5607
+ const std::string refresh_script =
+ "document.documentElement.style.visibility='hidden';"
+ "document.documentElement.offsetHeight;"
+ "document.documentElement.style.visibility='';";
+
+ executeJavaScript(refresh_script);
+}
diff --git a/indra/llplugin/llpluginclassmedia.h b/indra/llplugin/llpluginclassmedia.h
index 71522bcd7d..40f6295e55 100644
--- a/indra/llplugin/llpluginclassmedia.h
+++ b/indra/llplugin/llpluginclassmedia.h
@@ -350,6 +350,8 @@ public:
std::shared_ptr<LLPluginClassMedia> getSharedPtr() { return std::dynamic_pointer_cast<LLPluginClassMedia>(shared_from_this()); } // due to enable_shared_from_this
+ void forceRenderRefresh();
+
protected:
LLPluginClassMediaOwner *mOwner;