@ -3453,25 +3453,37 @@ function rcube_webmail()
// process the response data according to the sent action
switch ( request _obj . _ _action )
{
case 'delete' :
case 'moveto' :
if ( this . env . action == 'show' )
this . command ( 'list' ) ;
else if ( this . message _list )
this . message _list . init ( ) ;
break ;
case 'purge' :
case 'expunge' :
if ( ! this . env . messagecount )
{
// clear preview pane content
if ( this . env . contentframe )
this . show _contentframe ( false ) ;
// disable commands useless when mailbox is empty
this . enable _command ( 'show' , 'reply' , 'reply-all' , 'forward' , 'moveto' , 'delete' , 'mark' , 'viewsource' ,
'print' , 'load-attachment' , 'purge' , 'expunge' , 'select-all' , 'select-none' , 'sort' , false ) ;
}
break ;
case 'list' :
this . enable _command ( 'purge' , ( this . env . messagecount && ( this . env . mailbox == this . env . trash _mailbox || this . env . mailbox == this . env . junk _mailbox ) ) ) ;
this . msglist _select ( this . message _list ) ;
case 'check-recent' :
case 'getunread' :
this . enable _command ( 'sort' , ( this . env . messagecount > 0 ) ) ;
this . enable _command ( 'show' , 'expunge' , 'select-all' , 'select-none' , 'sort' , ( this . env . messagecount > 0 ) ) ;
this . enable _command ( 'purge' , ( this . env . messagecount && ( this . env . mailbox == this . env . trash _mailbox || this . env . mailbox == this . env . junk _mailbox ) ) ) ;
case 'expunge' :
this . enable _command ( 'select-all' , 'select-none' , 'expunge' , this . env . messagecount ? true : false ) ;
break ;
break ;
}