summaryrefslogtreecommitdiff
path: root/roundcubemail/program/js
diff options
context:
space:
mode:
authoralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-05-16 13:53:08 +0000
committeralec <alec@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-05-16 13:53:08 +0000
commit62daa5e8debab2430ba9913365f574f84560820c (patch)
treef9fcefff0e84fc09c87cc99e9c66dd3a00c70d76 /roundcubemail/program/js
parent2741cd97554aa27cdeeea6a6e565bbb46f522a11 (diff)
- Add option to set default action of Forward button to "Forward as attachment"
git-svn-id: https://svn.roundcube.net/trunk@4775 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/js')
-rw-r--r--roundcubemail/program/js/app.js11
1 files changed, 7 insertions, 4 deletions
diff --git a/roundcubemail/program/js/app.js b/roundcubemail/program/js/app.js
index 3f103de65..c4aa50995 100644
--- a/roundcubemail/program/js/app.js
+++ b/roundcubemail/program/js/app.js
@@ -931,10 +931,13 @@ function rcube_webmail()
case 'forward-attachment':
case 'forward':
- var uid;
- if (uid = this.get_single_uid())
- this.goto_url('compose', '_forward_uid='+uid+'&_mbox='+urlencode(this.env.mailbox)
- + (command == 'forward-attachment' ? '&_attachment=1' : ''), true);
+ var uid, url;
+ if (uid = this.get_single_uid()) {
+ url = '_forward_uid='+uid+'&_mbox='+urlencode(this.env.mailbox);
+ if (command == 'forward-attachment' || (!props && this.env.forward_attachment))
+ url += '&_attachment=1';
+ this.goto_url('compose', url, true);
+ }
break;
case 'print':