summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcallum_linden <none@none>2018-01-26 17:06:19 -0800
committercallum_linden <none@none>2018-01-26 17:06:19 -0800
commit8b09a997c5de48d30dc732a10ba3aeda6bc82d44 (patch)
treeecb22a24a693b888aecf1ea752f4efe7ca162c97
parent94f88e0121678cde7c4888d6adac9a1db1434292 (diff)
Fixes for: MAINT-8244 Text in CEF cannot be selected with the mouse. MAINT-8245 Expose CEF log file and logging severity to viewer and MAINT-8246 Expose the CEF remote debugging system to the viewer
-rw-r--r--autobuild.xml14
-rw-r--r--indra/llplugin/llpluginclassmedia.cpp11
-rw-r--r--indra/llplugin/llpluginclassmedia.h2
-rw-r--r--indra/media_plugins/cef/media_plugin_cef.cpp9
-rw-r--r--indra/newview/app_settings/settings.xml11
-rw-r--r--indra/newview/llviewermedia.cpp5
6 files changed, 41 insertions, 11 deletions
diff --git a/autobuild.xml b/autobuild.xml
index a4d0290a21..f1d22d5b93 100644
--- a/autobuild.xml
+++ b/autobuild.xml
@@ -556,9 +556,9 @@
<key>archive</key>
<map>
<key>hash</key>
- <string>7ceea1aaa8681497295770d78bfd980e</string>
+ <string>8352a71136eea487ca55784afe6bf947</string>
<key>url</key>
- <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/12667/75407/dullahan-1.1.1024_3.3239.1723.g071d1c1-darwin64-512020.tar.bz2</string>
+ <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/12933/78534/dullahan-1.1.1035_3.3239.1723.g071d1c1-darwin64-512195.tar.bz2</string>
</map>
<key>name</key>
<string>darwin64</string>
@@ -568,9 +568,9 @@
<key>archive</key>
<map>
<key>hash</key>
- <string>08d2b293087bedba2bca31ce7c517510</string>
+ <string>47cb40945d649d92d3a428fdf129fa5d</string>
<key>url</key>
- <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/12669/75414/dullahan-1.1.1024_3.3239.1723.g071d1c1-windows-512020.tar.bz2</string>
+ <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/12935/78546/dullahan-1.1.1035_3.3239.1723.g071d1c1-windows-512195.tar.bz2</string>
</map>
<key>name</key>
<string>windows</string>
@@ -580,16 +580,16 @@
<key>archive</key>
<map>
<key>hash</key>
- <string>e3f9837d9ea2be0b162f4fce3e0118ab</string>
+ <string>8a0bdf89bba7139f1c23ff2081584b2e</string>
<key>url</key>
- <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/12668/75419/dullahan-1.1.1024_3.3239.1723.g071d1c1-windows64-512020.tar.bz2</string>
+ <string>http://automated-builds-secondlife-com.s3.amazonaws.com/ct2/12934/78543/dullahan-1.1.1035_3.3239.1723.g071d1c1-windows64-512195.tar.bz2</string>
</map>
<key>name</key>
<string>windows64</string>
</map>
</map>
<key>version</key>
- <string>1.1.1024_3.3239.1723.g071d1c1</string>
+ <string>1.1.1035_3.3239.1723.g071d1c1</string>
</map>
<key>elfio</key>
<map>
diff --git a/indra/llplugin/llpluginclassmedia.cpp b/indra/llplugin/llpluginclassmedia.cpp
index a857ff0153..78eb6e75bb 100644
--- a/indra/llplugin/llpluginclassmedia.cpp
+++ b/indra/llplugin/llpluginclassmedia.cpp
@@ -31,6 +31,9 @@
#include "llpluginclassmedia.h"
#include "llpluginmessageclasses.h"
+#include "llcontrol.h"
+
+extern LLControlGroup gSavedSettings;
static int LOW_PRIORITY_TEXTURE_SIZE_DEFAULT = 256;
@@ -843,11 +846,17 @@ void LLPluginClassMedia::paste()
sendMessage(message);
}
-void LLPluginClassMedia::setUserDataPath(const std::string &user_data_path_cache, const std::string &user_data_path_cookies)
+void LLPluginClassMedia::setUserDataPath(const std::string &user_data_path_cache,
+ const std::string &user_data_path_cookies,
+ const std::string &user_data_path_cef_log)
{
LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "set_user_data_path");
message.setValue("cache_path", user_data_path_cache);
message.setValue("cookies_path", user_data_path_cookies);
+ message.setValue("cef_log_file", user_data_path_cef_log);
+
+ bool cef_verbose_log = gSavedSettings.getBOOL("CefVerboseLog");
+ message.setValueBoolean("cef_verbose_log", cef_verbose_log);
sendMessage(message);
}
diff --git a/indra/llplugin/llpluginclassmedia.h b/indra/llplugin/llpluginclassmedia.h
index dcd8af4e06..3b3075c6bd 100644
--- a/indra/llplugin/llpluginclassmedia.h
+++ b/indra/llplugin/llpluginclassmedia.h
@@ -195,7 +195,7 @@ public:
bool canPaste() const { return mCanPaste; };
// These can be called before init(), and they will be queued and sent before the media init message.
- void setUserDataPath(const std::string &user_data_path_cache, const std::string &user_data_path_cookies);
+ void setUserDataPath(const std::string &user_data_path_cache, const std::string &user_data_path_cookies, const std::string &user_data_path_cef_log);
void setLanguageCode(const std::string &language_code);
void setPluginsEnabled(const bool enabled);
void setJavascriptEnabled(const bool enabled);
diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp
index 88317655ab..bdd394da4b 100644
--- a/indra/media_plugins/cef/media_plugin_cef.cpp
+++ b/indra/media_plugins/cef/media_plugin_cef.cpp
@@ -96,6 +96,8 @@ private:
bool mCanPaste;
std::string mCachePath;
std::string mCookiePath;
+ std::string mCefLogFile;
+ bool mCefLogVerbose;
std::vector<std::string> mPickedFiles;
VolumeCatcher mVolumeCatcher;
F32 mCurVolume;
@@ -126,6 +128,8 @@ MediaPluginBase(host_send_func, host_user_data)
mCanPaste = false;
mCachePath = "";
mCookiePath = "";
+ mCefLogFile = "";
+ mCefLogVerbose = false;
mPickedFiles.clear();
mCurVolume = 0.0;
@@ -511,6 +515,8 @@ void MediaPluginCEF::receiveMessage(const char* message_string)
settings.plugins_enabled = mPluginsEnabled;
settings.user_agent_substring = mCEFLib->makeCompatibleUserAgentString(mUserAgentSubtring);
settings.webgl_enabled = true;
+ settings.log_file = mCefLogFile;
+ settings.log_verbose = mCefLogVerbose;
std::vector<std::string> custom_schemes(1, "secondlife");
mCEFLib->setCustomSchemes(custom_schemes);
@@ -540,8 +546,11 @@ void MediaPluginCEF::receiveMessage(const char* message_string)
{
std::string user_data_path_cache = message_in.getValue("cache_path");
std::string user_data_path_cookies = message_in.getValue("cookies_path");
+
mCachePath = user_data_path_cache + "cef_cache";
mCookiePath = user_data_path_cookies + "cef_cookies";
+ mCefLogFile = message_in.getValue("cef_log_file");
+ mCefLogVerbose = message_in.getValueBoolean("cef_verbose_log");
}
else if (message_name == "size_change")
{
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index 4a4f4bfc61..11c34dacb5 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -16155,6 +16155,17 @@
<key>Value</key>
<integer>0</integer>
</map>
+ <key>CefVerboseLog</key>
+ <map>
+ <key>Comment</key>
+ <string>Enable/disable CEF verbose loggingk</string>
+ <key>Persist</key>
+ <integer>1</integer>
+ <key>Type</key>
+ <string>Boolean</string>
+ <key>Value</key>
+ <integer>0</integer>
+ </map>
</map>
</llsd>
diff --git a/indra/newview/llviewermedia.cpp b/indra/newview/llviewermedia.cpp
index 1d4079289a..c92de6ada5 100644
--- a/indra/newview/llviewermedia.cpp
+++ b/indra/newview/llviewermedia.cpp
@@ -1686,6 +1686,8 @@ LLPluginClassMedia* LLViewerMediaImpl::newSourceFromMediaType(std::string media_
std::string user_data_path_cookies = gDirUtilp->getOSUserAppDir();
user_data_path_cookies += gDirUtilp->getDirDelimiter();
+ std::string user_data_path_cef_log = gDirUtilp->getExpandedFilename(LL_PATH_LOGS, "cef_log.txt");
+
// Fix for EXT-5960 - make browser profile specific to user (cache, cookies etc.)
// If the linden username returned is blank, that can only mean we are
// at the login page displaying login Web page or Web browser test via Develop menu.
@@ -1694,7 +1696,6 @@ LLPluginClassMedia* LLViewerMediaImpl::newSourceFromMediaType(std::string media_
std::string linden_user_dir = gDirUtilp->getLindenUserDir();
if ( ! linden_user_dir.empty() )
{
- // gDirUtilp->getLindenUserDir() is whole path, not just Linden name
user_data_path_cookies = linden_user_dir;
user_data_path_cookies += gDirUtilp->getDirDelimiter();
};
@@ -1715,7 +1716,7 @@ LLPluginClassMedia* LLViewerMediaImpl::newSourceFromMediaType(std::string media_
{
media_source = new LLPluginClassMedia(owner);
media_source->setSize(default_width, default_height);
- media_source->setUserDataPath(user_data_path_cache, user_data_path_cookies);
+ media_source->setUserDataPath(user_data_path_cache, user_data_path_cookies, user_data_path_cef_log);
media_source->setLanguageCode(LLUI::getLanguage());
media_source->setZoomFactor(zoom_factor);