summaryrefslogtreecommitdiff
path: root/plugins
diff options
context:
space:
mode:
authorThomas Bruederli <bruederli@kolabsys.com>2015-01-21 19:33:10 (GMT)
committerThomas Bruederli <bruederli@kolabsys.com>2015-01-21 19:33:10 (GMT)
commita8acc5052085db3b4b8db8153f9ecd5082c270e0 (patch)
treef1209a5f631fd566cd4c1fe407f447df3a1125a5 /plugins
parent8d420a94cc3fe3eda4475b22b1dc1b218cb84aca (diff)
downloadroundcubemail-plugins-kolab-a8acc5052085db3b4b8db8153f9ecd5082c270e0.tar.gz
Move assets loading and env setting routine to startup hook.
This will give the odfviewer plugin the opportunity to update the config with the additional mimetypes regardless of the plugin loading order.
Diffstat (limited to 'plugins')
-rw-r--r--plugins/libcalendaring/libcalendaring.php12
1 files changed, 6 insertions, 6 deletions
diff --git a/plugins/libcalendaring/libcalendaring.php b/plugins/libcalendaring/libcalendaring.php
index ec82fdf..b9055b1 100644
--- a/plugins/libcalendaring/libcalendaring.php
+++ b/plugins/libcalendaring/libcalendaring.php
@@ -98,12 +98,6 @@ class libcalendaring extends rcube_plugin
// include client scripts and styles
if ($this->rc->output) {
- if ($this->rc->output->type == 'html') {
- $this->rc->output->set_env('libcal_settings', $this->load_settings());
- $this->include_script('libcalendaring.js');
- $this->include_stylesheet($this->local_skin_path() . '/libcal.css');
- }
-
// add hook to display alarms
$this->add_hook('refresh', array($this, 'refresh'));
$this->register_action('plugin.alarms', array($this, 'alarms_action'));
@@ -119,6 +113,12 @@ class libcalendaring extends rcube_plugin
*/
public function startup($args)
{
+ if ($this->rc->output && $this->rc->output->type == 'html') {
+ $this->rc->output->set_env('libcal_settings', $this->load_settings());
+ $this->include_script('libcalendaring.js');
+ $this->include_stylesheet($this->local_skin_path() . '/libcal.css');
+ }
+
if ($args['task'] == 'mail') {
if ($args['action'] == 'show' || $args['action'] == 'preview') {
$this->add_hook('message_load', array($this, 'mail_message_load'));