|
|
@ -3198,13 +3198,14 @@ function rcube_webmail()
|
|
|
|
// show wait message
|
|
|
|
// show wait message
|
|
|
|
if (this.env.action == 'show')
|
|
|
|
if (this.env.action == 'show')
|
|
|
|
lock = this.set_busy(true, 'movingmessage');
|
|
|
|
lock = this.set_busy(true, 'movingmessage');
|
|
|
|
else
|
|
|
|
|
|
|
|
this.show_contentframe(false);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// Hide message command buttons until a message is selected
|
|
|
|
// Hide message command buttons until a message is selected
|
|
|
|
this.enable_command(this.env.message_commands, false);
|
|
|
|
this.enable_command(this.env.message_commands, false);
|
|
|
|
|
|
|
|
|
|
|
|
this.with_selected_messages('move', post_data, lock);
|
|
|
|
this.with_selected_messages('move', post_data, lock);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (this.env.action != 'show')
|
|
|
|
|
|
|
|
this.show_contentframe(false);
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
// delete selected messages from the current mailbox
|
|
|
|
// delete selected messages from the current mailbox
|
|
|
@ -3247,8 +3248,8 @@ function rcube_webmail()
|
|
|
|
if (!post_data._uid)
|
|
|
|
if (!post_data._uid)
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
|
|
|
|
|
|
|
|
this.show_contentframe(false);
|
|
|
|
|
|
|
|
this.with_selected_messages('delete', post_data);
|
|
|
|
this.with_selected_messages('delete', post_data);
|
|
|
|
|
|
|
|
this.show_contentframe(false);
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|
// Send a specific move/delete request with UIDs of all selected messages
|
|
|
|
// Send a specific move/delete request with UIDs of all selected messages
|
|
|
@ -3260,7 +3261,8 @@ function rcube_webmail()
|
|
|
|
// update the list (remove rows, clear selection)
|
|
|
|
// update the list (remove rows, clear selection)
|
|
|
|
if (this.message_list) {
|
|
|
|
if (this.message_list) {
|
|
|
|
var n, len, id, root, roots = [],
|
|
|
|
var n, len, id, root, roots = [],
|
|
|
|
selection = post_data._uid;
|
|
|
|
selection = post_data._uid,
|
|
|
|
|
|
|
|
display_next = this.env.display_next && this.preview_id;
|
|
|
|
|
|
|
|
|
|
|
|
if (selection === '*')
|
|
|
|
if (selection === '*')
|
|
|
|
selection = this.message_list.get_selection();
|
|
|
|
selection = this.message_list.get_selection();
|
|
|
@ -3278,11 +3280,13 @@ function rcube_webmail()
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if (remove)
|
|
|
|
if (remove)
|
|
|
|
this.message_list.remove_row(id, (this.env.display_next && n == selection.length-1));
|
|
|
|
this.message_list.remove_row(id, display_next && n == selection.length-1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// make sure there are no selected rows
|
|
|
|
// make sure there are no selected rows
|
|
|
|
if (!this.env.display_next && remove)
|
|
|
|
if (!display_next && remove)
|
|
|
|
this.message_list.clear_selection();
|
|
|
|
this.message_list.clear_selection();
|
|
|
|
|
|
|
|
|
|
|
|
// update thread tree icons
|
|
|
|
// update thread tree icons
|
|
|
|
for (n=0, len=roots.length; n<len; n++) {
|
|
|
|
for (n=0, len=roots.length; n<len; n++) {
|
|
|
|
this.add_tree_icons(roots[n]);
|
|
|
|
this.add_tree_icons(roots[n]);
|
|
|
@ -3466,7 +3470,8 @@ function rcube_webmail()
|
|
|
|
lock = this.display_message('markingmessage', 'loading'),
|
|
|
|
lock = this.display_message('markingmessage', 'loading'),
|
|
|
|
list = this.message_list,
|
|
|
|
list = this.message_list,
|
|
|
|
rows = list ? list.rows : {},
|
|
|
|
rows = list ? list.rows : {},
|
|
|
|
count = 0;
|
|
|
|
count = 0,
|
|
|
|
|
|
|
|
display_next = this.env.display_next && this.preview_id;
|
|
|
|
|
|
|
|
|
|
|
|
for (var i=0, len=a_uids.length; i<len; i++) {
|
|
|
|
for (var i=0, len=a_uids.length; i<len; i++) {
|
|
|
|
uid = a_uids[i];
|
|
|
|
uid = a_uids[i];
|
|
|
@ -3476,7 +3481,7 @@ function rcube_webmail()
|
|
|
|
|
|
|
|
|
|
|
|
if (this.env.skip_deleted) {
|
|
|
|
if (this.env.skip_deleted) {
|
|
|
|
count += this.update_thread(uid);
|
|
|
|
count += this.update_thread(uid);
|
|
|
|
list.remove_row(uid, (this.env.display_next && i == list.get_selection(false).length-1));
|
|
|
|
list.remove_row(uid, display_next && i == list.get_selection(false).length-1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else
|
|
|
|
else
|
|
|
|
this.set_message(uid, 'deleted', true);
|
|
|
|
this.set_message(uid, 'deleted', true);
|
|
|
@ -3485,7 +3490,7 @@ function rcube_webmail()
|
|
|
|
|
|
|
|
|
|
|
|
// make sure there are no selected rows
|
|
|
|
// make sure there are no selected rows
|
|
|
|
if (this.env.skip_deleted && list) {
|
|
|
|
if (this.env.skip_deleted && list) {
|
|
|
|
if (!this.env.display_next || !list.rowcount)
|
|
|
|
if (!display_next || !list.rowcount)
|
|
|
|
list.clear_selection();
|
|
|
|
list.clear_selection();
|
|
|
|
if (count < 0)
|
|
|
|
if (count < 0)
|
|
|
|
post_data._count = (count*-1);
|
|
|
|
post_data._count = (count*-1);
|
|
|
@ -6326,9 +6331,11 @@ function rcube_webmail()
|
|
|
|
if (this.env.search_request)
|
|
|
|
if (this.env.search_request)
|
|
|
|
url._search = this.env.search_request;
|
|
|
|
url._search = this.env.search_request;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (cid)
|
|
|
|
|
|
|
|
url._cid = this.preview_id = cid;
|
|
|
|
|
|
|
|
|
|
|
|
url._action = action;
|
|
|
|
url._action = action;
|
|
|
|
url._source = this.env.source;
|
|
|
|
url._source = this.env.source;
|
|
|
|
url._cid = cid;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
this.location_href(url, target, true);
|
|
|
|
this.location_href(url, target, true);
|
|
|
|
}
|
|
|
|
}
|
|
|
@ -6484,12 +6491,11 @@ function rcube_webmail()
|
|
|
|
for (n=0; n<selection.length; n++) {
|
|
|
|
for (n=0; n<selection.length; n++) {
|
|
|
|
id = selection[n];
|
|
|
|
id = selection[n];
|
|
|
|
a_cids.push(id);
|
|
|
|
a_cids.push(id);
|
|
|
|
this.contact_list.remove_row(id, (n == selection.length-1));
|
|
|
|
this.contact_list.remove_row(id, this.env.display_next && this.preview_id && n == selection.length-1);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
// hide content frame if we delete the currently displayed contact
|
|
|
|
if (!this.env.display_next)
|
|
|
|
if (selection.length == 1)
|
|
|
|
this.contact_list.clear_selection();
|
|
|
|
this.show_contentframe(false);
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (!post_data)
|
|
|
|
if (!post_data)
|
|
|
@ -6687,12 +6693,16 @@ function rcube_webmail()
|
|
|
|
this.remove_group_contacts = function(props)
|
|
|
|
this.remove_group_contacts = function(props)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
if (this.env.group !== undefined && (this.env.group === props.gid)) {
|
|
|
|
if (this.env.group !== undefined && (this.env.group === props.gid)) {
|
|
|
|
var n, selection = this.contact_list.get_selection();
|
|
|
|
var n, selection = this.contact_list.get_selection(),
|
|
|
|
|
|
|
|
display_next= this.env.display_next && this.preview_id;
|
|
|
|
|
|
|
|
|
|
|
|
for (n=0; n<selection.length; n++) {
|
|
|
|
for (n=0; n<selection.length; n++) {
|
|
|
|
id = selection[n];
|
|
|
|
id = selection[n];
|
|
|
|
this.contact_list.remove_row(id, (n == selection.length-1));
|
|
|
|
this.contact_list.remove_row(id, display_next && n == selection.length-1);
|
|
|
|
this.contact_list.clear_selection();
|
|
|
|
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (!display_next)
|
|
|
|
|
|
|
|
this.contact_list.clear_selection();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
|
|