From 65baa033e067483d5bcd57294aafab413b4cda2c Mon Sep 17 00:00:00 2001 From: Thomas Bruederli Date: Sun, 3 Aug 2014 19:17:13 +0200 Subject: List all plugins which have been attempted to load (#1488871) --- program/lib/Roundcube/rcube_plugin.php | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'program/lib/Roundcube/rcube_plugin.php') diff --git a/program/lib/Roundcube/rcube_plugin.php b/program/lib/Roundcube/rcube_plugin.php index 01c340deb..cc7c7977f 100644 --- a/program/lib/Roundcube/rcube_plugin.php +++ b/program/lib/Roundcube/rcube_plugin.php @@ -94,7 +94,15 @@ abstract class rcube_plugin /** * Provide information about this * - * @return array Meta information about a plugin or false if not implemented + * @return array Meta information about a plugin or false if not implemented: + * As hash array with the following keys: + * name: The plugin name + * vendor: Name of the plugin developer + * version: Plugin version name + * license: License name (short form according to http://spdx.org/licenses/) + * uri: The URL to the plugin homepage or source repository + * src_uri: Direct download URL to the source code of this plugin + * require: List of plugins required for this one (as array of plugin names) */ public static function info() { -- cgit v1.2.3 From 4eee212883b34e1ca7cfb9466580ff20dca5c979 Mon Sep 17 00:00:00 2001 From: JohnDoh Date: Sat, 16 Aug 2014 07:05:30 +0100 Subject: add include_plugin function for optoinal plugins --- program/lib/Roundcube/rcube_plugin.php | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'program/lib/Roundcube/rcube_plugin.php') diff --git a/program/lib/Roundcube/rcube_plugin.php b/program/lib/Roundcube/rcube_plugin.php index cc7c7977f..9c7a9c2dc 100644 --- a/program/lib/Roundcube/rcube_plugin.php +++ b/program/lib/Roundcube/rcube_plugin.php @@ -120,6 +120,17 @@ abstract class rcube_plugin return $this->api->load_plugin($plugin_name, true); } + /** + * Attempt to load the given plugin which is optional for the current plugin + * + * @param string Plugin name + * @return boolean True on success, false on failure + */ + public function include_plugin($plugin_name) + { + return $this->api->load_plugin($plugin_name, true, false); + } + /** * Load local config file from plugins directory. * The loaded values are patched over the global configuration. -- cgit v1.2.3