diff options
author | Armin Weatherwax | 2010-06-14 17:51:51 +0200 |
---|---|---|
committer | Armin Weatherwax | 2010-09-23 15:42:38 +0200 |
commit | 093b99196f27b518b183953cade1077fa6d7c5ed (patch) | |
tree | 154ce4bfa2fbdeae561aa4b115568e4ec2680861 /linden/indra/llplugin/llpluginclassmedia.cpp | |
parent | update to latest SG2 media_plugins (diff) | |
download | meta-impy-093b99196f27b518b183953cade1077fa6d7c5ed.zip meta-impy-093b99196f27b518b183953cade1077fa6d7c5ed.tar.gz meta-impy-093b99196f27b518b183953cade1077fa6d7c5ed.tar.bz2 meta-impy-093b99196f27b518b183953cade1077fa6d7c5ed.tar.xz |
update llplugin to latest version of SG2, pull latest webkit
Diffstat (limited to '')
-rwxr-xr-x | linden/indra/llplugin/llpluginclassmedia.cpp | 48 |
1 files changed, 41 insertions, 7 deletions
diff --git a/linden/indra/llplugin/llpluginclassmedia.cpp b/linden/indra/llplugin/llpluginclassmedia.cpp index 2e8bf3f..b958f0c 100755 --- a/linden/indra/llplugin/llpluginclassmedia.cpp +++ b/linden/indra/llplugin/llpluginclassmedia.cpp | |||
@@ -13,13 +13,13 @@ | |||
13 | * ("GPL"), unless you have obtained a separate licensing agreement | 13 | * ("GPL"), unless you have obtained a separate licensing agreement |
14 | * ("Other License"), formally executed by you and Linden Lab. Terms of | 14 | * ("Other License"), formally executed by you and Linden Lab. Terms of |
15 | * the GPL can be found in doc/GPL-license.txt in this distribution, or | 15 | * the GPL can be found in doc/GPL-license.txt in this distribution, or |
16 | * online at http://secondlifegrid.net/programs/open_source/licensing/gplv2 | 16 | * online at http://secondlife.com/developers/opensource/gplv2 |
17 | * | 17 | * |
18 | * There are special exceptions to the terms and conditions of the GPL as | 18 | * There are special exceptions to the terms and conditions of the GPL as |
19 | * it is applied to this Source Code. View the full text of the exception | 19 | * it is applied to this Source Code. View the full text of the exception |
20 | * in the file doc/FLOSS-exception.txt in this software distribution, or | 20 | * in the file doc/FLOSS-exception.txt in this software distribution, or |
21 | * online at | 21 | * online at |
22 | * http://secondlifegrid.net/programs/open_source/licensing/flossexception | 22 | * http://secondlife.com/developers/opensource/flossexception |
23 | * | 23 | * |
24 | * By copying, modifying or distributing this software, you acknowledge | 24 | * By copying, modifying or distributing this software, you acknowledge |
25 | * that you have read and understood your obligations described above, | 25 | * that you have read and understood your obligations described above, |
@@ -29,6 +29,7 @@ | |||
29 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, | 29 | * WARRANTIES, EXPRESS, IMPLIED OR OTHERWISE, REGARDING ITS ACCURACY, |
30 | * COMPLETENESS OR PERFORMANCE. | 30 | * COMPLETENESS OR PERFORMANCE. |
31 | * $/LicenseInfo$ | 31 | * $/LicenseInfo$ |
32 | * | ||
32 | * @endcond | 33 | * @endcond |
33 | */ | 34 | */ |
34 | 35 | ||
@@ -66,15 +67,19 @@ LLPluginClassMedia::~LLPluginClassMedia() | |||
66 | reset(); | 67 | reset(); |
67 | } | 68 | } |
68 | 69 | ||
69 | bool LLPluginClassMedia::init(const std::string &launcher_filename, const std::string &plugin_filename, bool debug, const std::string &user_data_path) | 70 | bool LLPluginClassMedia::init(const std::string &launcher_filename, const std::string &plugin_filename, bool debug) |
70 | { | 71 | { |
71 | LL_DEBUGS("Plugin") << "launcher: " << launcher_filename << LL_ENDL; | 72 | LL_DEBUGS("Plugin") << "launcher: " << launcher_filename << LL_ENDL; |
72 | LL_DEBUGS("Plugin") << "plugin: " << plugin_filename << LL_ENDL; | 73 | LL_DEBUGS("Plugin") << "plugin: " << plugin_filename << LL_ENDL; |
73 | LL_DEBUGS("Plugin") << "user_data_path: " << user_data_path << LL_ENDL; | ||
74 | 74 | ||
75 | mPlugin = new LLPluginProcessParent(this); | 75 | mPlugin = new LLPluginProcessParent(this); |
76 | mPlugin->setSleepTime(mSleepTime); | 76 | mPlugin->setSleepTime(mSleepTime); |
77 | mPlugin->init(launcher_filename, plugin_filename, debug, user_data_path); | 77 | |
78 | // Queue up the media init message -- it will be sent after all the currently queued messages. | ||
79 | LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "init"); | ||
80 | sendMessage(message); | ||
81 | |||
82 | mPlugin->init(launcher_filename, plugin_filename, debug); | ||
78 | 83 | ||
79 | return true; | 84 | return true; |
80 | } | 85 | } |
@@ -384,7 +389,7 @@ bool LLPluginClassMedia::textureValid(void) | |||
384 | 389 | ||
385 | bool LLPluginClassMedia::getDirty(LLRect *dirty_rect) | 390 | bool LLPluginClassMedia::getDirty(LLRect *dirty_rect) |
386 | { | 391 | { |
387 | bool result = !mDirtyRect.isNull();//awfixme isEmpty(); | 392 | bool result = !mDirtyRect.isNull(); |
388 | 393 | ||
389 | if(dirty_rect != NULL) | 394 | if(dirty_rect != NULL) |
390 | { | 395 | { |
@@ -679,6 +684,34 @@ void LLPluginClassMedia::paste() | |||
679 | sendMessage(message); | 684 | sendMessage(message); |
680 | } | 685 | } |
681 | 686 | ||
687 | void LLPluginClassMedia::setUserDataPath(const std::string &user_data_path) | ||
688 | { | ||
689 | LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "set_user_data_path"); | ||
690 | message.setValue("path", user_data_path); | ||
691 | sendMessage(message); | ||
692 | } | ||
693 | |||
694 | void LLPluginClassMedia::setLanguageCode(const std::string &language_code) | ||
695 | { | ||
696 | LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "set_language_code"); | ||
697 | message.setValue("language", language_code); | ||
698 | sendMessage(message); | ||
699 | } | ||
700 | |||
701 | void LLPluginClassMedia::setPluginsEnabled(const bool enabled) | ||
702 | { | ||
703 | LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "plugins_enabled"); | ||
704 | message.setValueBoolean("enable", enabled); | ||
705 | sendMessage(message); | ||
706 | } | ||
707 | |||
708 | void LLPluginClassMedia::setJavascriptEnabled(const bool enabled) | ||
709 | { | ||
710 | LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA, "javascript_enabled"); | ||
711 | message.setValueBoolean("enable", enabled); | ||
712 | sendMessage(message); | ||
713 | } | ||
714 | |||
682 | LLPluginClassMedia::ETargetType getTargetTypeFromLLQtWebkit(int target_type) | 715 | LLPluginClassMedia::ETargetType getTargetTypeFromLLQtWebkit(int target_type) |
683 | { | 716 | { |
684 | // convert a LinkTargetType value from llqtwebkit to an ETargetType | 717 | // convert a LinkTargetType value from llqtwebkit to an ETargetType |
@@ -746,7 +779,7 @@ void LLPluginClassMedia::receivePluginMessage(const LLPluginMessage &message) | |||
746 | newDirtyRect.mBottom = temp; | 779 | newDirtyRect.mBottom = temp; |
747 | } | 780 | } |
748 | 781 | ||
749 | if(mDirtyRect.isNull())//awfixme isEmpty()) | 782 | if(mDirtyRect.isNull()) |
750 | { | 783 | { |
751 | mDirtyRect = newDirtyRect; | 784 | mDirtyRect = newDirtyRect; |
752 | } | 785 | } |
@@ -1048,6 +1081,7 @@ void LLPluginClassMedia::clear_cookies() | |||
1048 | void LLPluginClassMedia::enable_cookies(bool enable) | 1081 | void LLPluginClassMedia::enable_cookies(bool enable) |
1049 | { | 1082 | { |
1050 | LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER, "enable_cookies"); | 1083 | LLPluginMessage message(LLPLUGIN_MESSAGE_CLASS_MEDIA_BROWSER, "enable_cookies"); |
1084 | message.setValueBoolean("enable", enable); | ||
1051 | sendMessage(message); | 1085 | sendMessage(message); |
1052 | } | 1086 | } |
1053 | 1087 | ||