summaryrefslogtreecommitdiff
path: root/indra/llplugin
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llplugin')
-rw-r--r--indra/llplugin/llpluginclassmedia.cpp12
-rw-r--r--indra/llplugin/llpluginclassmedia.h2
-rw-r--r--indra/llplugin/slplugin/CMakeLists.txt9
3 files changed, 23 insertions, 0 deletions
diff --git a/indra/llplugin/llpluginclassmedia.cpp b/indra/llplugin/llpluginclassmedia.cpp
index 53a338b3d6..34f1b83b6d 100644
--- a/indra/llplugin/llpluginclassmedia.cpp
+++ b/indra/llplugin/llpluginclassmedia.cpp
@@ -1658,3 +1658,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 6c512003cc..91901719d3 100644
--- a/indra/llplugin/llpluginclassmedia.h
+++ b/indra/llplugin/llpluginclassmedia.h
@@ -356,6 +356,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;
diff --git a/indra/llplugin/slplugin/CMakeLists.txt b/indra/llplugin/slplugin/CMakeLists.txt
index 38f4c92b09..f7adb9404b 100644
--- a/indra/llplugin/slplugin/CMakeLists.txt
+++ b/indra/llplugin/slplugin/CMakeLists.txt
@@ -61,6 +61,13 @@ elseif (DARWIN)
)
endif ()
+if (CMAKE_BUILD_TYPE MATCHES Release AND (CMAKE_CXX_COMPILER_ID STREQUAL Clang OR CMAKE_CXX_COMPILER_ID MATCHES GNU))
+ add_custom_command(
+ TARGET ${PROJECT_NAME} POST_BUILD
+ COMMAND ${CMAKE_STRIP} ${PROJECT_NAME}
+ )
+endif ()
+
if (BUILD_SHARED_LIBS)
set_target_properties(SLPlugin PROPERTIES LINK_FLAGS_RELEASE
"${LINK_FLAGS_RELEASE} -Wl,--allow-shlib-undefined")
@@ -69,6 +76,8 @@ endif ()
if (INSTALL)
if (DARWIN OR WINDOWS)
install(TARGETS ${PROJECT_NAME} DESTINATION .)
+ elseif (USE_FLATPAK)
+ install(TARGETS ${PROJECT_NAME} DESTINATION libexec)
elseif (${LINUX_DISTRO} MATCHES arch)
install(TARGETS ${PROJECT_NAME} DESTINATION lib/${VIEWER_BINARY_NAME})
else ()