summaryrefslogtreecommitdiff
path: root/plugins/archive/archive.php
diff options
context:
space:
mode:
authorthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-12-22 12:05:16 +0000
committerthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-12-22 12:05:16 +0000
commit38394350ffaf894e399b860531bc9d3cee303e0d (patch)
treecfd4023345e280e78b54decb0bd4d2eaa787dd85 /plugins/archive/archive.php
parent957c5298a18e7aafc39bc33f674322f87702a683 (diff)
Let plugins adapt better to different skins
git-svn-id: https://svn.roundcube.net/trunk@5642 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'plugins/archive/archive.php')
-rw-r--r--plugins/archive/archive.php13
1 files changed, 8 insertions, 5 deletions
diff --git a/plugins/archive/archive.php b/plugins/archive/archive.php
index a56806263..ffac38a9e 100644
--- a/plugins/archive/archive.php
+++ b/plugins/archive/archive.php
@@ -20,16 +20,20 @@ class archive extends rcube_plugin
// There is no "Archived flags"
// $GLOBALS['IMAP_FLAGS']['ARCHIVED'] = 'Archive';
if ($rcmail->task == 'mail' && ($rcmail->action == '' || $rcmail->action == 'show')
- && ($archive_folder = $rcmail->config->get('archive_mbox'))) {
+ && ($archive_folder = $rcmail->config->get('archive_mbox'))) {
$skin_path = $this->local_skin_path();
-
+ if (is_file($this->home . "/$skin_path/archive.css"))
+ $this->include_stylesheet("$skin_path/archive.css");
+
$this->include_script('archive.js');
$this->add_texts('localization', true);
$this->add_button(
array(
+ 'type' => 'link',
+ 'label' => 'buttontext',
'command' => 'plugin.archive',
- 'imagepas' => $skin_path.'/archive_pas.png',
- 'imageact' => $skin_path.'/archive_act.png',
+ 'class' => 'button buttonPas archive disabled',
+ 'classact' => 'button archive',
'width' => 32,
'height' => 32,
'title' => 'buttontitle',
@@ -42,7 +46,6 @@ class archive extends rcube_plugin
// set env variable for client
$rcmail->output->set_env('archive_folder', $archive_folder);
- $rcmail->output->set_env('archive_folder_icon', $this->url($skin_path.'/foldericon.png'));
// add archive folder to the list of default mailboxes
if (($default_folders = $rcmail->config->get('default_imap_folders')) && !in_array($archive_folder, $default_folders)) {