summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2009-04-26 16:47:49 +0000
committerthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2009-04-26 16:47:49 +0000
commit52720735d7192e84674a46b25f51c8621f84cb7e (patch)
tree01fe6a143e9d2dd2ebda6a96a56b6290b84ab822
parentb2787b5920d4d4efbb39f94a1f4e2f52cb676dd1 (diff)
Add two new javascript events
git-svn-id: https://svn.roundcube.net/trunk@2428 208e9e7b-5314-0410-a742-e7e81cd9613c
-rw-r--r--roundcubemail/program/js/app.js12
1 files changed, 11 insertions, 1 deletions
diff --git a/roundcubemail/program/js/app.js b/roundcubemail/program/js/app.js
index f0317837d..c17e03288 100644
--- a/roundcubemail/program/js/app.js
+++ b/roundcubemail/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;
}
};