diff options
author | thomascube <thomas@roundcube.net> | 2010-03-02 07:54:11 +0000 |
---|---|---|
committer | thomascube <thomas@roundcube.net> | 2010-03-02 07:54:11 +0000 |
commit | 5e9a5661011e64423e1978599c56d47f8b0cfa37 (patch) | |
tree | 9e3bbfb306473dd4fbf644d7f27c0966f80bb07e /program/js/app.js | |
parent | ff519ed8c259fa0b39ce47ccc728e62a97b9a911 (diff) |
Fix checking for new mail (#1485794)
Diffstat (limited to 'program/js/app.js')
-rw-r--r-- | program/js/app.js | 26 |
1 files changed, 14 insertions, 12 deletions
diff --git a/program/js/app.js b/program/js/app.js index c5bac8554..dee34b5a0 100644 --- a/program/js/app.js +++ b/program/js/app.js @@ -624,8 +624,8 @@ function rcube_webmail() if (this.env.sort_col==sort_col) sort_order = this.env.sort_order=='ASC' ? 'DESC' : 'ASC'; else - sort_order = 'ASC'; - + sort_order = 'ASC'; + // set table header class $('#rcm'+this.env.sort_col).removeClass('sorted'+(this.env.sort_order.toUpperCase())); $('#rcm'+sort_col).addClass('sorted'+sort_order); @@ -1618,8 +1618,8 @@ function rcube_webmail() this.env.current_page = 1; this.set_busy(true, 'searching'); this.http_request('search', '_filter='+filter - + (search ? '&_q='+urlencode(search) : '') - + (this.env.mailbox ? '&_mbox='+urlencode(this.env.mailbox) : ''), true); + + (search ? '&_q='+urlencode(search) : '') + + (this.env.mailbox ? '&_mbox='+urlencode(this.env.mailbox) : ''), true); } @@ -4260,8 +4260,8 @@ function rcube_webmail() case 'moveto': if (this.env.action == 'show') { - // re-enable commands on move/delete error - this.enable_command('reply', 'reply-all', 'forward', 'delete', 'mark', 'print', 'open', 'edit', 'viewsource', 'download', true); + // re-enable commands on move/delete error + this.enable_command('reply', 'reply-all', 'forward', 'delete', 'mark', 'print', 'open', 'edit', 'viewsource', 'download', true); } else if (this.message_list) this.message_list.init(); break; @@ -4274,8 +4274,8 @@ function rcube_webmail() this.show_contentframe(false); // disable commands useless when mailbox is empty this.enable_command('show', 'reply', 'reply-all', 'forward', 'moveto', 'delete', - 'mark', 'viewsource', 'open', 'edit', 'download', 'print', 'load-attachment', - 'purge', 'expunge', 'select-all', 'select-none', 'sort', false); + 'mark', 'viewsource', 'open', 'edit', 'download', 'print', 'load-attachment', + 'purge', 'expunge', 'select-all', 'select-none', 'sort', false); } break; @@ -4321,16 +4321,18 @@ function rcube_webmail() }; // send periodic request to check for recent messages - this.check_for_recent = function(setbusy) + this.check_for_recent = function(refresh) { if (this.busy) return; - if (setbusy) - this.set_busy(true, 'checkingmail'); - var addurl = '_t=' + (new Date().getTime()); + if (refresh) { + this.set_busy(true, 'checkingmail'); + addurl += '&_refresh=1'; + } + if (this.gui_objects.messagelist) addurl += '&_list=1'; if (this.gui_objects.quotadisplay) |