|
|
@ -641,7 +641,7 @@ function rcube_webmail()
|
|
|
|
|
|
|
|
|
|
|
|
case 'open':
|
|
|
|
case 'open':
|
|
|
|
if (uid = this.get_single_uid()) {
|
|
|
|
if (uid = this.get_single_uid()) {
|
|
|
|
obj.href = this.url('show', {_mbox: this.env.mailbox, _uid: uid});
|
|
|
|
obj.href = this.url('show', {_mbox: this.get_message_mailbox(uid), _uid: uid});
|
|
|
|
return true;
|
|
|
|
return true;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
break;
|
|
|
@ -737,9 +737,9 @@ function rcube_webmail()
|
|
|
|
this.load_contact(cid, 'edit');
|
|
|
|
this.load_contact(cid, 'edit');
|
|
|
|
else if (this.task == 'settings' && props)
|
|
|
|
else if (this.task == 'settings' && props)
|
|
|
|
this.load_identity(props, 'edit-identity');
|
|
|
|
this.load_identity(props, 'edit-identity');
|
|
|
|
else if (this.task == 'mail' && (cid = this.get_single_uid())) {
|
|
|
|
else if (this.task == 'mail' && (uid = this.get_single_uid())) {
|
|
|
|
url = { _mbox: this.env.mailbox };
|
|
|
|
url = { _mbox: this.get_message_mailbox(uid) };
|
|
|
|
url[this.env.mailbox == this.env.drafts_mailbox && props != 'new' ? '_draft_uid' : '_uid'] = cid;
|
|
|
|
url[this.env.mailbox == this.env.drafts_mailbox && props != 'new' ? '_draft_uid' : '_uid'] = uid;
|
|
|
|
this.open_compose_step(url);
|
|
|
|
this.open_compose_step(url);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
break;
|
|
|
@ -1029,7 +1029,7 @@ function rcube_webmail()
|
|
|
|
case 'reply-list':
|
|
|
|
case 'reply-list':
|
|
|
|
case 'reply':
|
|
|
|
case 'reply':
|
|
|
|
if (uid = this.get_single_uid()) {
|
|
|
|
if (uid = this.get_single_uid()) {
|
|
|
|
url = {_reply_uid: uid, _mbox: this.env.mailbox};
|
|
|
|
url = {_reply_uid: uid, _mbox: this.get_message_mailbox(uid)};
|
|
|
|
if (command == 'reply-all')
|
|
|
|
if (command == 'reply-all')
|
|
|
|
// do reply-list, when list is detected and popup menu wasn't used
|
|
|
|
// do reply-list, when list is detected and popup menu wasn't used
|
|
|
|
url._all = (!props && this.commands['reply-list'] ? 'list' : 'all');
|
|
|
|
url._all = (!props && this.commands['reply-list'] ? 'list' : 'all');
|
|
|
@ -1057,7 +1057,7 @@ function rcube_webmail()
|
|
|
|
this.gui_objects.messagepartframe.contentWindow.print();
|
|
|
|
this.gui_objects.messagepartframe.contentWindow.print();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (uid = this.get_single_uid()) {
|
|
|
|
else if (uid = this.get_single_uid()) {
|
|
|
|
ref.printwin = this.open_window(this.env.comm_path+'&_action=print&_uid='+uid+'&_mbox='+urlencode(this.env.mailbox)+(this.env.safemode ? '&_safe=1' : ''), true, true);
|
|
|
|
ref.printwin = this.open_window(this.env.comm_path+'&_action=print&_uid='+uid+'&_mbox='+urlencode(this.get_message_mailbox(uid))+(this.env.safemode ? '&_safe=1' : ''), true, true);
|
|
|
|
if (this.printwin) {
|
|
|
|
if (this.printwin) {
|
|
|
|
if (this.env.action != 'show')
|
|
|
|
if (this.env.action != 'show')
|
|
|
|
this.mark_message('read', uid);
|
|
|
|
this.mark_message('read', uid);
|
|
|
@ -1074,8 +1074,9 @@ function rcube_webmail()
|
|
|
|
if (this.env.action == 'get') {
|
|
|
|
if (this.env.action == 'get') {
|
|
|
|
location.href = location.href.replace(/_frame=/, '_download=');
|
|
|
|
location.href = location.href.replace(/_frame=/, '_download=');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else if (uid = this.get_single_uid())
|
|
|
|
else if (uid = this.get_single_uid()) {
|
|
|
|
this.goto_url('viewsource', { _uid: uid, _mbox: this.env.mailbox, _save: 1 });
|
|
|
|
this.goto_url('viewsource', { _uid: uid, _mbox: this.get_message_mailbox(uid), _save: 1 });
|
|
|
|
|
|
|
|
}
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
|
|
|
|
|
|
|
|
// quicksearch
|
|
|
|
// quicksearch
|
|
|
@ -1772,6 +1773,7 @@ function rcube_webmail()
|
|
|
|
selected: this.select_all_mode || this.message_list.in_selection(uid),
|
|
|
|
selected: this.select_all_mode || this.message_list.in_selection(uid),
|
|
|
|
ml: flags.ml?1:0,
|
|
|
|
ml: flags.ml?1:0,
|
|
|
|
ctype: flags.ctype,
|
|
|
|
ctype: flags.ctype,
|
|
|
|
|
|
|
|
mbox: flags.mbox,
|
|
|
|
// flags from plugins
|
|
|
|
// flags from plugins
|
|
|
|
flags: flags.extra_flags
|
|
|
|
flags: flags.extra_flags
|
|
|
|
});
|
|
|
|
});
|
|
|
@ -1974,7 +1976,7 @@ function rcube_webmail()
|
|
|
|
|
|
|
|
|
|
|
|
var win, target = window,
|
|
|
|
var win, target = window,
|
|
|
|
action = preview ? 'preview': 'show',
|
|
|
|
action = preview ? 'preview': 'show',
|
|
|
|
url = '&_action='+action+'&_uid='+id+'&_mbox='+urlencode(this.env.mailbox);
|
|
|
|
url = '&_action='+action+'&_uid='+id+'&_mbox='+urlencode(this.get_message_mailbox(id));
|
|
|
|
|
|
|
|
|
|
|
|
if (preview && (win = this.get_frame_window(this.env.contentframe))) {
|
|
|
|
if (preview && (win = this.get_frame_window(this.env.contentframe))) {
|
|
|
|
target = win;
|
|
|
|
target = win;
|
|
|
@ -6882,6 +6884,13 @@ function rcube_webmail()
|
|
|
|
return this.env.cid ? this.env.cid : (this.contact_list ? this.contact_list.get_single_selection() : null);
|
|
|
|
return this.env.cid ? this.env.cid : (this.contact_list ? this.contact_list.get_single_selection() : null);
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// get the IMP mailbox of the message with the given UID
|
|
|
|
|
|
|
|
this.get_message_mailbox = function(uid)
|
|
|
|
|
|
|
|
{
|
|
|
|
|
|
|
|
var msg = this.env.messages ? this.env.messages[uid] : {};
|
|
|
|
|
|
|
|
return msg.mbox || this.env.mailbox;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// gets cursor position
|
|
|
|
// gets cursor position
|
|
|
|
this.get_caret_pos = function(obj)
|
|
|
|
this.get_caret_pos = function(obj)
|
|
|
|
{
|
|
|
|
{
|
|
|
|