Skip to content

Commit

Permalink
Add IMP_Flist_Mbox.ftype()
Browse files Browse the repository at this point in the history
  • Loading branch information
slusarz committed Jun 5, 2014
1 parent a661a13 commit 6559762
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions imp/js/dimpbase.js
Expand Up @@ -2367,15 +2367,15 @@ var DimpBase = {
if (drag.hasClassName('imp-sidebar-mbox')) {
dropbase = (drop == $('dropbase'));
if (dropbase ||
(drop.element().retrieve('ftype') != 'special' &&
(drop.ftype() != 'special' &&
!this.flist.isSubfolder(drag, drop))) {
DimpCore.doAction('renameMailbox', {
new_name: drag.element().retrieve('l').unescapeHTML(),
new_parent: dropbase ? '' : drop.value(),
old_name: drag.value()
});
}
} else if (drop.element().retrieve('ftype') != 'container') {
} else if (drop.ftype() != 'container') {
sel = this.viewport.getSelected();

if (sel.size()) {
Expand Down Expand Up @@ -2410,7 +2410,7 @@ var DimpBase = {
{
var m,
d = drag.retrieve('l'),
ftype = drop.retrieve('ftype'),
ftype = this.flist.getMbox(drop).ftype(),
l = drop.retrieve('l');

if (drop == $('dropbase')) {
Expand Down Expand Up @@ -3422,7 +3422,7 @@ var DimpBase = {
if (elt.hasClassName('exp') || elt.hasClassName('col')) {
this._toggleSubFolder(mbox.element(), 'tog');
} else {
switch (mbox.element().retrieve('ftype')) {
switch (mbox.ftype()) {
case 'container':
case 'rcontainer':
case 'remote':
Expand Down Expand Up @@ -4346,6 +4346,11 @@ var IMP_Flist_Mbox = Class.create({
return this.elt.hasClassName('imp-sidebar-container');
},

ftype: function()
{
return this.elt.retrieve('ftype');
},

fullMboxDisplay: function()
{
return this.elt.readAttribute('title').escapeHTML();
Expand Down

0 comments on commit 6559762

Please sign in to comment.