summaryrefslogtreecommitdiff
path: root/program/js/app.js
diff options
context:
space:
mode:
authorthomascube <thomas@roundcube.net>2009-04-26 16:47:49 +0000
committerthomascube <thomas@roundcube.net>2009-04-26 16:47:49 +0000
commit99d86607372eadef6e11701d8184d758a45c2062 (patch)
tree62ccb3677958530bf14551de20664ec8790f93fe /program/js/app.js
parent1c932d58b57930ce527a77e885ace5b430a60883 (diff)
Add two new javascript events
Diffstat (limited to 'program/js/app.js')
-rw-r--r--program/js/app.js12
1 files changed, 11 insertions, 1 deletions
diff --git a/program/js/app.js b/program/js/app.js
index f0317837d..c17e03288 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -3459,6 +3459,9 @@ function rcube_webmail()
if ((target_li = this.get_folder_li(name))) {
$(target_li).removeClass('unfocused').addClass('selected');
}
+
+ // trigger event hook
+ this.triggerEvent('selectfolder', { folder:name, old:old });
}
};
@@ -3912,9 +3915,16 @@ function rcube_webmail()
this.msglist_select(this.message_list);
this.enable_command('show', 'expunge', 'select-all', 'select-none', 'sort', (this.env.messagecount > 0));
this.enable_command('purge', this.purge_mailbox_test());
+
+ if (response.action == 'list')
+ this.triggerEvent('listupdate', { folder:this.env.mailbox, rowcount:this.message_list.rowcount });
}
- else if (this.task == 'addressbook')
+ else if (this.task == 'addressbook') {
this.enable_command('export', (this.contact_list && this.contact_list.rowcount > 0));
+
+ if (response.action == 'list')
+ this.triggerEvent('listupdate', { folder:this.env.source, rowcount:this.contact_list.rowcount });
+ }
break;
}
};