#3717 LLPluginClassMedia::sendMessage

master
Andrey Kleshchev 2025-03-11 18:43:22 +02:00 committed by Andrey Kleshchev
parent 8bb35ac029
commit 89a87fbf81
1 changed files with 18 additions and 2 deletions

View File

@ -692,7 +692,15 @@ void LLFloater360Capture::handleMediaEvent(LLPluginClassMedia* self, EMediaEvent
);
// execute the command on the page
mWebBrowser->getMediaPlugin()->executeJavaScript(cmd);
LLPluginClassMedia* plugin = mWebBrowser->getMediaPlugin();
if (plugin)
{
plugin->executeJavaScript(cmd);
}
else
{
LL_WARNS("360Capture") << "No media plugin found" << LL_ENDL;
}
}
}
break;
@ -773,7 +781,15 @@ void LLFloater360Capture::onSaveLocalBtn()
// send it to the browser instance, triggering the equirectangular capture
// process and complimentary offer to save the image
mWebBrowser->getMediaPlugin()->executeJavaScript(cmd);
LLPluginClassMedia* plugin = mWebBrowser->getMediaPlugin();
if (plugin)
{
plugin->executeJavaScript(cmd);
}
else
{
LL_WARNS("360Capture") << "No media plugin found" << LL_ENDL;
}
}
// We capture all 6 images sequentially and if parts of the world are moving