From 05eba5d7b82e5b5d9c959415b36125b801266231 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Mon, 20 Nov 2017 16:08:15 -0800 Subject: Pull in CEF 3203 (Dullanan 1.1.888) Chrome 62 build and re-enable WebGL --- indra/media_plugins/cef/media_plugin_cef.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index f3d7762a08..963c69aeb9 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -115,7 +115,7 @@ MediaPluginBase(host_send_func, host_user_data) mCookiesEnabled = true; mPluginsEnabled = false; mJavascriptEnabled = true; - mDisableGPU = true; + mDisableGPU = false; mUserAgentSubtring = ""; mAuthUsername = ""; mAuthPassword = ""; -- cgit v1.2.3 From 0b97c76dbb238fab079d10433ecf37045f6134ae Mon Sep 17 00:00:00 2001 From: callum_linden Date: Wed, 13 Dec 2017 13:55:33 -0800 Subject: Pull in Dullahan 1.1.925 with fix for onFileDialogCallback(..) handling that fixes MAINT-8083 --- indra/media_plugins/cef/media_plugin_cef.cpp | 47 +++++++++++++++++----------- 1 file changed, 28 insertions(+), 19 deletions(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index 963c69aeb9..dbd33a736b 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -68,8 +68,7 @@ private: void onNavigateURLCallback(std::string url, std::string target); bool onHTTPAuthCallback(const std::string host, const std::string realm, std::string& username, std::string& password); void onCursorChangedCallback(dullahan::ECursorType type); - void onFileDownloadCallback(std::string filename); - const std::string onFileDialogCallback(); + const std::string onFileDialog(dullahan::EFileDialogType dialog_type, const std::string dialog_title, const std::string default_file, const std::string dialog_accept_filter, bool& use_default); void postDebugMessage(const std::string& msg); void authResponse(LLPluginMessage &message); @@ -285,30 +284,39 @@ bool MediaPluginCEF::onHTTPAuthCallback(const std::string host, const std::strin //////////////////////////////////////////////////////////////////////////////// // -void MediaPluginCEF::onFileDownloadCallback(const std::string filename) +const std::string MediaPluginCEF::onFileDialog(dullahan::EFileDialogType dialog_type, const std::string dialog_title, const std::string default_file, std::string dialog_accept_filter, bool& use_default) { - mAuthOK = false; + // do not use the default CEF file picker + use_default = false; - LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "file_download"); - message.setValue("filename", filename); + if (dialog_type == dullahan::FD_OPEN_FILE) + { + mPickedFile.clear(); - sendMessage(message); -} + LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "pick_file"); + message.setValueBoolean("blocking_request", true); -//////////////////////////////////////////////////////////////////////////////// -// -const std::string MediaPluginCEF::onFileDialogCallback() -{ - mPickedFile.clear(); + sendMessage(message); - LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "pick_file"); - message.setValueBoolean("blocking_request", true); + return mPickedFile; + } + else if (dialog_type == dullahan::FD_SAVE_FILE) + { + mAuthOK = false; - sendMessage(message); + LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "file_download"); + message.setValue("filename", default_file); + + sendMessage(message); + + return std::string(); + } - return mPickedFile; + return std::string(); } +//////////////////////////////////////////////////////////////////////////////// +// void MediaPluginCEF::onCursorChangedCallback(dullahan::ECursorType type) { std::string name = ""; @@ -341,6 +349,8 @@ void MediaPluginCEF::onCursorChangedCallback(dullahan::ECursorType type) sendMessage(message); } +//////////////////////////////////////////////////////////////////////////////// +// void MediaPluginCEF::authResponse(LLPluginMessage &message) { mAuthOK = message.getValueBoolean("ok"); @@ -442,8 +452,7 @@ void MediaPluginCEF::receiveMessage(const char* message_string) mCEFLib->setOnAddressChangeCallback(std::bind(&MediaPluginCEF::onAddressChangeCallback, this, std::placeholders::_1)); mCEFLib->setOnNavigateURLCallback(std::bind(&MediaPluginCEF::onNavigateURLCallback, this, std::placeholders::_1, std::placeholders::_2)); mCEFLib->setOnHTTPAuthCallback(std::bind(&MediaPluginCEF::onHTTPAuthCallback, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3, std::placeholders::_4)); - mCEFLib->setOnFileDownloadCallback(std::bind(&MediaPluginCEF::onFileDownloadCallback, this, std::placeholders::_1)); - mCEFLib->setOnFileDialogCallback(std::bind(&MediaPluginCEF::onFileDialogCallback, this)); + mCEFLib->setOnFileDialogCallback(std::bind(&MediaPluginCEF::onFileDialog, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3, std::placeholders::_4, std::placeholders::_5)); mCEFLib->setOnCursorChangedCallback(std::bind(&MediaPluginCEF::onCursorChangedCallback, this, std::placeholders::_1)); mCEFLib->setOnRequestExitCallback(std::bind(&MediaPluginCEF::onRequestExitCallback, this)); -- cgit v1.2.3 From 6166ab28dd43304085b23c0d35698be9d90bb8a9 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Thu, 14 Dec 2017 14:27:49 -0800 Subject: Pull in Dullahan 1.1.929 (multiple file picking support) and update plugin code accordingly --- indra/media_plugins/cef/media_plugin_cef.cpp | 38 +++++++++++++++++++++------- 1 file changed, 29 insertions(+), 9 deletions(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index dbd33a736b..558ae75c3c 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -68,7 +68,7 @@ private: void onNavigateURLCallback(std::string url, std::string target); bool onHTTPAuthCallback(const std::string host, const std::string realm, std::string& username, std::string& password); void onCursorChangedCallback(dullahan::ECursorType type); - const std::string onFileDialog(dullahan::EFileDialogType dialog_type, const std::string dialog_title, const std::string default_file, const std::string dialog_accept_filter, bool& use_default); + const std::vector onFileDialog(dullahan::EFileDialogType dialog_type, const std::string dialog_title, const std::string default_file, const std::string dialog_accept_filter, bool& use_default); void postDebugMessage(const std::string& msg); void authResponse(LLPluginMessage &message); @@ -94,7 +94,7 @@ private: bool mCanPaste; std::string mCachePath; std::string mCookiePath; - std::string mPickedFile; + std::vector mPickedFiles; VolumeCatcher mVolumeCatcher; F32 mCurVolume; dullahan* mCEFLib; @@ -124,7 +124,7 @@ MediaPluginBase(host_send_func, host_user_data) mCanPaste = false; mCachePath = ""; mCookiePath = ""; - mPickedFile = ""; + mPickedFiles.clear(); mCurVolume = 0.0; mCEFLib = new dullahan(); @@ -284,21 +284,34 @@ bool MediaPluginCEF::onHTTPAuthCallback(const std::string host, const std::strin //////////////////////////////////////////////////////////////////////////////// // -const std::string MediaPluginCEF::onFileDialog(dullahan::EFileDialogType dialog_type, const std::string dialog_title, const std::string default_file, std::string dialog_accept_filter, bool& use_default) +const std::vector MediaPluginCEF::onFileDialog(dullahan::EFileDialogType dialog_type, const std::string dialog_title, const std::string default_file, std::string dialog_accept_filter, bool& use_default) { // do not use the default CEF file picker use_default = false; if (dialog_type == dullahan::FD_OPEN_FILE) { - mPickedFile.clear(); + mPickedFiles.clear(); LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "pick_file"); message.setValueBoolean("blocking_request", true); + message.setValueBoolean("multiple_files", false); sendMessage(message); - return mPickedFile; + return mPickedFiles; + } + else if (dialog_type == dullahan::FD_OPEN_MULTIPLE_FILES) + { + mPickedFiles.clear(); + + LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "pick_file"); + message.setValueBoolean("blocking_request", true); + message.setValueBoolean("multiple_files", true); + + sendMessage(message); + + return mPickedFiles; } else if (dialog_type == dullahan::FD_SAVE_FILE) { @@ -309,10 +322,10 @@ const std::string MediaPluginCEF::onFileDialog(dullahan::EFileDialogType dialog_ sendMessage(message); - return std::string(); + return std::vector(); } - return std::string(); + return std::vector(); } //////////////////////////////////////////////////////////////////////////////// @@ -659,7 +672,14 @@ void MediaPluginCEF::receiveMessage(const char* message_string) } if (message_name == "pick_file_response") { - mPickedFile = message_in.getValue("file"); + LLSD file_list_llsd = message_in.getValueLLSD("file_list"); + + LLSD::array_const_iterator iter = file_list_llsd.beginArray(); + LLSD::array_const_iterator end = file_list_llsd.endArray(); + for (; iter != end; ++iter) + { + mPickedFiles.push_back(((*iter).asString())); + } } if (message_name == "auth_response") { -- cgit v1.2.3 From 6ced87c0275ec20fca994f8d2f61947d5ac62082 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Fri, 15 Dec 2017 16:11:29 -0800 Subject: Pull in Dullahan 1.1.930 with improved fix for maint-8095 (target='_blank' links) as well as an improvement for maint-8100 (no error message for invalid hostname / url) --- indra/media_plugins/cef/media_plugin_cef.cpp | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index 558ae75c3c..a8d37a1d0a 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -38,6 +38,7 @@ #include "media_plugin_base.h" #include +#include #include "dullahan.h" @@ -64,6 +65,7 @@ private: void onLoadStartCallback(); void onRequestExitCallback(); void onLoadEndCallback(int httpStatusCode); + void onLoadError(int status, const std::string error_text); void onAddressChangeCallback(std::string url); void onNavigateURLCallback(std::string url, std::string target); bool onHTTPAuthCallback(const std::string host, const std::string realm, std::string& username, std::string& password); @@ -207,6 +209,21 @@ void MediaPluginCEF::onLoadStartCallback() sendMessage(message); } +///////////////////////////////////////////////////////////////////////////////// +// +void MediaPluginCEF::onLoadError(int status, const std::string error_text) +{ + std::stringstream msg; + + msg << "Loading error!"; + msg << "

"; + msg << "Message: " << error_text; + msg << "
"; + msg << "Code: " << status; + + mCEFLib->showBrowserMessage(msg.str()); +} + //////////////////////////////////////////////////////////////////////////////// // void MediaPluginCEF::onRequestExitCallback() @@ -245,7 +262,6 @@ void MediaPluginCEF::onNavigateURLCallback(std::string url, std::string target) LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER, "click_href"); message.setValue("uri", url); message.setValue("target", target); - message.setValue("uuid", ""); // not used right now sendMessage(message); } @@ -462,6 +478,7 @@ void MediaPluginCEF::receiveMessage(const char* message_string) mCEFLib->setOnTitleChangeCallback(std::bind(&MediaPluginCEF::onTitleChangeCallback, this, std::placeholders::_1)); mCEFLib->setOnLoadStartCallback(std::bind(&MediaPluginCEF::onLoadStartCallback, this)); mCEFLib->setOnLoadEndCallback(std::bind(&MediaPluginCEF::onLoadEndCallback, this, std::placeholders::_1)); + mCEFLib->setOnLoadErrorCallback(std::bind(&MediaPluginCEF::onLoadError, this, std::placeholders::_1, std::placeholders::_2)); mCEFLib->setOnAddressChangeCallback(std::bind(&MediaPluginCEF::onAddressChangeCallback, this, std::placeholders::_1)); mCEFLib->setOnNavigateURLCallback(std::bind(&MediaPluginCEF::onNavigateURLCallback, this, std::placeholders::_1, std::placeholders::_2)); mCEFLib->setOnHTTPAuthCallback(std::bind(&MediaPluginCEF::onHTTPAuthCallback, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3, std::placeholders::_4)); -- cgit v1.2.3 From 5989dd1673768660587552fbab0d7fa2851359c2 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Mon, 8 Jan 2018 11:22:02 -0800 Subject: Bump CEF Plugin version so it can be identified as different --- indra/media_plugins/cef/media_plugin_cef.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index a8d37a1d0a..1dfa9c1d0b 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -412,7 +412,7 @@ void MediaPluginCEF::receiveMessage(const char* message_string) versions[LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER] = LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER_VERSION; message.setValueLLSD("versions", versions); - std::string plugin_version = "CEF plugin 1.1.3"; + std::string plugin_version = "CEF plugin 1.2.0"; message.setValue("plugin_version", plugin_version); sendMessage(message); } -- cgit v1.2.3 From 8f214ad00b4444e9ed876f92da56bda15310a374 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Mon, 8 Jan 2018 14:51:32 -0800 Subject: Fix for MAINT-7886 Resizing internal web browser window causes video playback to stop --- indra/media_plugins/cef/media_plugin_cef.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index 1dfa9c1d0b..b8901e4d5c 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -167,6 +167,10 @@ void MediaPluginCEF::onPageChangedCallback(const unsigned char* pixels, int x, i { memcpy(mPixels, pixels, mWidth * mHeight * mDepth); } + else + { + mCEFLib->setSize(mWidth, mHeight); + } setDirty(0, 0, mWidth, mHeight); } } @@ -412,7 +416,7 @@ void MediaPluginCEF::receiveMessage(const char* message_string) versions[LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER] = LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER_VERSION; message.setValueLLSD("versions", versions); - std::string plugin_version = "CEF plugin 1.2.0"; + std::string plugin_version = "CEF plugin 1.1.3"; message.setValue("plugin_version", plugin_version); sendMessage(message); } @@ -559,11 +563,11 @@ void MediaPluginCEF::receiveMessage(const char* message_string) mTextureWidth = texture_width; mTextureHeight = texture_height; + + mCEFLib->setSize(mWidth, mHeight); }; }; - mCEFLib->setSize(mWidth, mHeight); - LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "size_change_response"); message.setValue("name", name); message.setValueS32("width", width); -- cgit v1.2.3 From d3f544d39d204c60c6112f0ba4abd906ac28481a Mon Sep 17 00:00:00 2001 From: callum_linden Date: Wed, 17 Jan 2018 16:13:19 -0800 Subject: Fixes for 'MAINT-8196 Remove LLPluginCookieStore from the viewer' and 'MAINT-8194 Remove per-frame calls to updateJavascriptObject()' --- indra/media_plugins/cef/media_plugin_cef.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index b8901e4d5c..67164ca0af 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -747,6 +747,10 @@ void MediaPluginCEF::receiveMessage(const char* message_string) { mCookiesEnabled = message_in.getValueBoolean("enable"); } + else if (message_name == "clear_cookies") + { + mCEFLib->deleteAllCookies(); + } else if (message_name == "set_user_agent") { mUserAgentSubtring = message_in.getValue("user_agent"); -- cgit v1.2.3 From 8ee332fb10cd96ae91b21bbece19ed8f70f0e552 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Mon, 22 Jan 2018 13:30:03 -0800 Subject: Bring in the very latest version of Dullahan (1.1.1024) that matches the most recent canonical Dullahan and also bump the CEF plugin version in preparation for the RC build --- indra/media_plugins/cef/media_plugin_cef.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index 67164ca0af..88317655ab 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -416,7 +416,7 @@ void MediaPluginCEF::receiveMessage(const char* message_string) versions[LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER] = LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER_VERSION; message.setValueLLSD("versions", versions); - std::string plugin_version = "CEF plugin 1.1.3"; + std::string plugin_version = "CEF plugin 1.1.412"; message.setValue("plugin_version", plugin_version); sendMessage(message); } -- cgit v1.2.3 From 8b09a997c5de48d30dc732a10ba3aeda6bc82d44 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Fri, 26 Jan 2018 17:06:19 -0800 Subject: 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 --- indra/media_plugins/cef/media_plugin_cef.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') 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 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 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") { -- cgit v1.2.3 From 278382abd72a02b5e190cb259d2b4806f3908902 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Thu, 1 Mar 2018 09:34:25 -0800 Subject: Now CEF supports setting default page background if specifier missing from HTML, set default background color to the Linden default grey (#282828) --- indra/media_plugins/cef/media_plugin_cef.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index bdd394da4b..d6a6232221 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -496,7 +496,7 @@ void MediaPluginCEF::receiveMessage(const char* message_string) dullahan::dullahan_settings settings; settings.accept_language_list = mHostLanguage; - settings.background_color = 0xffffffff; + settings.background_color = 0xff282828; settings.cache_enabled = true; settings.cache_path = mCachePath; settings.cookie_store_path = mCookiePath; -- cgit v1.2.3 From 6b4f4e53ddf4b5252f64dccfb146f70ee7d42127 Mon Sep 17 00:00:00 2001 From: callum_linden Date: Thu, 15 Mar 2018 16:12:52 -0700 Subject: Pull in latest version of Dullahan (1.1.1072) and tweak media plugin code to match change in API --- indra/media_plugins/cef/media_plugin_cef.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'indra/media_plugins/cef/media_plugin_cef.cpp') diff --git a/indra/media_plugins/cef/media_plugin_cef.cpp b/indra/media_plugins/cef/media_plugin_cef.cpp index d6a6232221..189beb75ba 100644 --- a/indra/media_plugins/cef/media_plugin_cef.cpp +++ b/indra/media_plugins/cef/media_plugin_cef.cpp @@ -67,7 +67,7 @@ private: void onLoadEndCallback(int httpStatusCode); void onLoadError(int status, const std::string error_text); void onAddressChangeCallback(std::string url); - void onNavigateURLCallback(std::string url, std::string target); + void onOpenPopupCallback(std::string url, std::string target); bool onHTTPAuthCallback(const std::string host, const std::string realm, std::string& username, std::string& password); void onCursorChangedCallback(dullahan::ECursorType type); const std::vector onFileDialog(dullahan::EFileDialogType dialog_type, const std::string dialog_title, const std::string default_file, const std::string dialog_accept_filter, bool& use_default); @@ -265,7 +265,7 @@ void MediaPluginCEF::onAddressChangeCallback(std::string url) //////////////////////////////////////////////////////////////////////////////// // -void MediaPluginCEF::onNavigateURLCallback(std::string url, std::string target) +void MediaPluginCEF::onOpenPopupCallback(std::string url, std::string target) { LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER, "click_href"); message.setValue("uri", url); @@ -488,7 +488,7 @@ void MediaPluginCEF::receiveMessage(const char* message_string) mCEFLib->setOnLoadEndCallback(std::bind(&MediaPluginCEF::onLoadEndCallback, this, std::placeholders::_1)); mCEFLib->setOnLoadErrorCallback(std::bind(&MediaPluginCEF::onLoadError, this, std::placeholders::_1, std::placeholders::_2)); mCEFLib->setOnAddressChangeCallback(std::bind(&MediaPluginCEF::onAddressChangeCallback, this, std::placeholders::_1)); - mCEFLib->setOnNavigateURLCallback(std::bind(&MediaPluginCEF::onNavigateURLCallback, this, std::placeholders::_1, std::placeholders::_2)); + mCEFLib->setOnOpenPopupCallback(std::bind(&MediaPluginCEF::onOpenPopupCallback, this, std::placeholders::_1, std::placeholders::_2)); mCEFLib->setOnHTTPAuthCallback(std::bind(&MediaPluginCEF::onHTTPAuthCallback, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3, std::placeholders::_4)); mCEFLib->setOnFileDialogCallback(std::bind(&MediaPluginCEF::onFileDialog, this, std::placeholders::_1, std::placeholders::_2, std::placeholders::_3, std::placeholders::_4, std::placeholders::_5)); mCEFLib->setOnCursorChangedCallback(std::bind(&MediaPluginCEF::onCursorChangedCallback, this, std::placeholders::_1)); -- cgit v1.2.3