mirror of
https://github.com/roundcube/roundcubemail.git
synced 2026-02-20 01:21:20 +01:00
Improve code to prevent sorting protected folders
This commit is contained in:
@@ -162,14 +162,14 @@ function rcube_treelist_widget(node, p) {
|
||||
e.stopPropagation();
|
||||
return false;
|
||||
}
|
||||
})
|
||||
.on('mousedown', 'li.mailbox.protected, li.mailbox.protected a', function (e) {
|
||||
// Prevent protected folders from being dragged/sorted.
|
||||
// We can't use the options of $.sortable() for that (then sub-folders of protected folders couldn't be
|
||||
// dragged, either), thus we implement it here.
|
||||
if ($(e.target).parent().is('li.mailbox.protected')) {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
return false;
|
||||
}
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
return false;
|
||||
});
|
||||
|
||||
// activate search function
|
||||
|
||||
Reference in New Issue
Block a user