summaryrefslogtreecommitdiff
path: root/plugins/archive
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/archive')
-rw-r--r--plugins/archive/archive.js36
-rw-r--r--plugins/archive/archive.php144
-rw-r--r--plugins/archive/localization/cs_CZ.inc25
-rw-r--r--plugins/archive/localization/de_CH.inc8
-rw-r--r--plugins/archive/localization/de_DE.inc8
-rw-r--r--plugins/archive/localization/en_US.inc8
-rw-r--r--plugins/archive/localization/et_EE.inc8
-rw-r--r--plugins/archive/localization/fr_FR.inc8
-rw-r--r--plugins/archive/localization/pl_PL.inc8
-rw-r--r--plugins/archive/localization/ru_RU.inc8
-rw-r--r--plugins/archive/localization/zh_TW.inc8
-rw-r--r--plugins/archive/skins/default/archive_act.pngbin3663 -> 0 bytes
-rw-r--r--plugins/archive/skins/default/archive_pas.pngbin977 -> 0 bytes
-rw-r--r--plugins/archive/skins/default/foldericon.pngbin3312 -> 0 bytes
14 files changed, 0 insertions, 269 deletions
diff --git a/plugins/archive/archive.js b/plugins/archive/archive.js
deleted file mode 100644
index 954fd1549..000000000
--- a/plugins/archive/archive.js
+++ /dev/null
@@ -1,36 +0,0 @@
-/*
- * Archive plugin script
- * @version 1.2
- */
-
-function rcmail_archive(prop)
-{
- if (!rcmail.env.uid && (!rcmail.message_list || !rcmail.message_list.get_selection().length))
- return;
-
- var uids = rcmail.env.uid ? rcmail.env.uid : rcmail.message_list.get_selection().join(',');
-
- rcmail.set_busy(true, 'loading');
- rcmail.http_post('plugin.archive', '_uid='+uids+'&_mbox='+urlencode(rcmail.env.mailbox), true);
-}
-
-// callback for app-onload event
-if (window.rcmail) {
- rcmail.addEventListener('init', function(evt) {
-
- // register command (directly enable in message view mode)
- rcmail.register_command('plugin.archive', rcmail_archive, (rcmail.env.uid && rcmail.env.mailbox != rcmail.env.archive_folder));
-
- // add event-listener to message list
- if (rcmail.message_list)
- rcmail.message_list.addEventListener('select', function(list){
- rcmail.enable_command('plugin.archive', (list.get_selection().length > 0 && rcmail.env.mailbox != rcmail.env.archive_folder));
- });
-
- // set css style for archive folder
- var li;
- if (rcmail.env.archive_folder && rcmail.env.archive_folder_icon && (li = rcmail.get_folder_li(rcmail.env.archive_folder)))
- $(li).css('background-image', 'url(' + rcmail.env.archive_folder_icon + ')');
- })
-}
-
diff --git a/plugins/archive/archive.php b/plugins/archive/archive.php
deleted file mode 100644
index 5d6131188..000000000
--- a/plugins/archive/archive.php
+++ /dev/null
@@ -1,144 +0,0 @@
-<?php
-
-/**
- * Archive
- *
- * Plugin that adds a new button to the mailbox toolbar
- * to move messages to a (user selectable) archive folder.
- *
- * @version 1.4
- * @author Andre Rodier, Thomas Bruederli
- */
-class archive extends rcube_plugin
-{
- public $task = 'mail|settings';
-
- function init()
- {
- $rcmail = rcmail::get_instance();
-
- $this->register_action('plugin.archive', array($this, 'request_action'));
-
- // 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'))) {
- $skin_path = $this->local_skin_path();
-
- $this->include_script('archive.js');
- $this->add_texts('localization', true);
- $this->add_button(
- array(
- 'command' => 'plugin.archive',
- 'imagepas' => $skin_path.'/archive_pas.png',
- 'imageact' => $skin_path.'/archive_act.png',
- 'title' => 'buttontitle',
- 'domain' => $this->ID,
- ),
- 'toolbar');
-
- // register hook to localize the archive folder
- $this->add_hook('render_mailboxlist', array($this, 'render_mailboxlist'));
-
- // 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)) {
- $default_folders[] = $archive_folder;
- $rcmail->config->set('default_imap_folders', $default_folders);
- }
- }
- else if ($rcmail->task == 'settings') {
- $dont_override = $rcmail->config->get('dont_override', array());
- if (!in_array('archive_mbox', $dont_override)) {
- $this->add_hook('user_preferences', array($this, 'prefs_table'));
- $this->add_hook('save_preferences', array($this, 'save_prefs'));
- }
- }
- }
-
- function render_mailboxlist($p)
- {
- $rcmail = rcmail::get_instance();
- $archive_folder = $rcmail->config->get('archive_mbox');
-
- // set localized name for the configured archive folder
- if ($archive_folder) {
- if (isset($p['list'][$archive_folder]))
- $p['list'][$archive_folder]['name'] = $this->gettext('archivefolder');
- else // search in subfolders
- $this->_mod_folder_name($p['list'], $archive_folder, $this->gettext('archivefolder'));
- }
-
- return $p;
- }
-
- function _mod_folder_name(&$list, $folder, $new_name)
- {
- foreach ($list as $idx => $item) {
- if ($item['id'] == $folder) {
- $list[$idx]['name'] = $new_name;
- return true;
- } else if (!empty($item['folders']))
- if ($this->_mod_folder_name($list[$idx]['folders'], $folder, $new_name))
- return true;
- }
- return false;
- }
-
- function request_action()
- {
- $this->add_texts('localization');
-
- $uids = get_input_value('_uid', RCUBE_INPUT_POST);
- $mbox = get_input_value('_mbox', RCUBE_INPUT_POST);
-
- $rcmail = rcmail::get_instance();
-
- // There is no "Archive flags", but I left this line in case it may be useful
- // $rcmail->imap->set_flag($uids, 'ARCHIVE');
-
- if (($archive_mbox = $rcmail->config->get('archive_mbox')) && $mbox != $archive_mbox) {
- $rcmail->output->command('move_messages', $archive_mbox);
- $rcmail->output->command('display_message', $this->gettext('archived'), 'confirmation');
- }
-
- $rcmail->output->send();
- }
-
- function prefs_table($args)
- {
- global $CURR_SECTION;
-
- if ($args['section'] == 'folders') {
- $this->add_texts('localization');
-
- $rcmail = rcmail::get_instance();
-
- // load folders list when needed
- if ($CURR_SECTION)
- $select = rcmail_mailbox_select(array('noselection' => '---', 'realnames' => true,
- 'maxlength' => 30, 'exceptions' => array('INBOX')));
- else
- $select = new html_select();
-
- $args['blocks']['main']['options']['archive_mbox'] = array(
- 'title' => $this->gettext('archivefolder'),
- 'content' => $select->show($rcmail->config->get('archive_mbox'), array('name' => "_archive_mbox"))
- );
- }
-
- return $args;
- }
-
- function save_prefs($args)
- {
- if ($args['section'] == 'folders') {
- $args['prefs']['archive_mbox'] = get_input_value('_archive_mbox', RCUBE_INPUT_POST);
- return $args;
- }
- }
-
-}
diff --git a/plugins/archive/localization/cs_CZ.inc b/plugins/archive/localization/cs_CZ.inc
deleted file mode 100644
index 04c8fcfa8..000000000
--- a/plugins/archive/localization/cs_CZ.inc
+++ /dev/null
@@ -1,25 +0,0 @@
-<?php
-
-/*
-
-+-----------------------------------------------------------------------+
-| language/cs_CZ/labels.inc |
-| |
-| Language file of the RoundCube archive plugin |
-| Copyright (C) 2005-2009, RoundCube Dev. - Switzerland |
-| Licensed under the GNU GPL |
-| |
-+-----------------------------------------------------------------------+
-| Author: Milan Kozak <hodza@hodza.net> |
-+-----------------------------------------------------------------------+
-
-@version $Id: labels.inc 2993 2009-09-26 18:32:07Z alec $
-
-*/
-
-$labels = array();
-$labels['buttontitle'] = 'Archivovat zprávu';
-$labels['archived'] = 'Úspěšně vloženo do archivu';
-$labels['archivefolder'] = 'Archiv';
-
-?>
diff --git a/plugins/archive/localization/de_CH.inc b/plugins/archive/localization/de_CH.inc
deleted file mode 100644
index 2ed0f5ac8..000000000
--- a/plugins/archive/localization/de_CH.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = 'Nachricht archivieren';
-$labels['archived'] = 'Nachricht erfolgreich archiviert';
-$labels['archivefolder'] = 'Archiv';
-
-?>
diff --git a/plugins/archive/localization/de_DE.inc b/plugins/archive/localization/de_DE.inc
deleted file mode 100644
index 2ed0f5ac8..000000000
--- a/plugins/archive/localization/de_DE.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = 'Nachricht archivieren';
-$labels['archived'] = 'Nachricht erfolgreich archiviert';
-$labels['archivefolder'] = 'Archiv';
-
-?>
diff --git a/plugins/archive/localization/en_US.inc b/plugins/archive/localization/en_US.inc
deleted file mode 100644
index fce31a0b5..000000000
--- a/plugins/archive/localization/en_US.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = 'Archive this message';
-$labels['archived'] = 'Successfully archived';
-$labels['archivefolder'] = 'Archive';
-
-?>
diff --git a/plugins/archive/localization/et_EE.inc b/plugins/archive/localization/et_EE.inc
deleted file mode 100644
index e3968d755..000000000
--- a/plugins/archive/localization/et_EE.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = 'Arhiveeri see kiri';
-$labels['archived'] = 'Edukalt arhiveeritud';
-$labels['archivefolder'] = 'Arhiveeri';
-
-?>
diff --git a/plugins/archive/localization/fr_FR.inc b/plugins/archive/localization/fr_FR.inc
deleted file mode 100644
index f44f30f44..000000000
--- a/plugins/archive/localization/fr_FR.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = 'Archiver ce message';
-$labels['archived'] = 'Message archiv avec success';
-$labels['archivefolder'] = 'Archive';
-
-?>
diff --git a/plugins/archive/localization/pl_PL.inc b/plugins/archive/localization/pl_PL.inc
deleted file mode 100644
index 2ecc77991..000000000
--- a/plugins/archive/localization/pl_PL.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = 'Przenieś do archiwum';
-$labels['archived'] = 'Pomyślnie zarchiwizowano';
-$labels['archivefolder'] = 'Archiwum';
-
-?>
diff --git a/plugins/archive/localization/ru_RU.inc b/plugins/archive/localization/ru_RU.inc
deleted file mode 100644
index e377ad017..000000000
--- a/plugins/archive/localization/ru_RU.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = 'Переместить выбранное в архив';
-$labels['archived'] = 'Перенесено в Архив';
-$labels['archivefolder'] = 'Архив';
-
-?>
diff --git a/plugins/archive/localization/zh_TW.inc b/plugins/archive/localization/zh_TW.inc
deleted file mode 100644
index 5cccebbdc..000000000
--- a/plugins/archive/localization/zh_TW.inc
+++ /dev/null
@@ -1,8 +0,0 @@
-<?php
-
-$labels = array();
-$labels['buttontitle'] = '封存此信件';
-$labels['archived'] = '已成功封存';
-$labels['archivefolder'] = '封存';
-
-?>
diff --git a/plugins/archive/skins/default/archive_act.png b/plugins/archive/skins/default/archive_act.png
deleted file mode 100644
index 2a1735868..000000000
--- a/plugins/archive/skins/default/archive_act.png
+++ /dev/null
Binary files differ
diff --git a/plugins/archive/skins/default/archive_pas.png b/plugins/archive/skins/default/archive_pas.png
deleted file mode 100644
index 8de208583..000000000
--- a/plugins/archive/skins/default/archive_pas.png
+++ /dev/null
Binary files differ
diff --git a/plugins/archive/skins/default/foldericon.png b/plugins/archive/skins/default/foldericon.png
deleted file mode 100644
index ec0853c44..000000000
--- a/plugins/archive/skins/default/foldericon.png
+++ /dev/null
Binary files differ