summaryrefslogtreecommitdiff
path: root/roundcubemail/program/js
diff options
context:
space:
mode:
authorthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-08-29 17:30:11 +0000
committerthomasb <thomasb@208e9e7b-5314-0410-a742-e7e81cd9613c>2011-08-29 17:30:11 +0000
commit888d9e6579ca3dcd698210f3092a17aa0cb514cd (patch)
tree2d1fb5266839812bcbbfc23c861add515f22bb22 /roundcubemail/program/js
parent233821ed931e87acb3a9f3ae683d0d568be3f938 (diff)
Make list of mimetypes that open in preview window configurable (#1487625)
git-svn-id: https://svn.roundcube.net/trunk@5144 208e9e7b-5314-0410-a742-e7e81cd9613c
Diffstat (limited to 'roundcubemail/program/js')
-rw-r--r--roundcubemail/program/js/app.js7
1 files changed, 1 insertions, 6 deletions
diff --git a/roundcubemail/program/js/app.js b/roundcubemail/program/js/app.js
index 2763b120c..b12d5c219 100644
--- a/roundcubemail/program/js/app.js
+++ b/roundcubemail/program/js/app.js
@@ -41,11 +41,6 @@ function rcube_webmail()
this.identifier_expr = new RegExp('[^0-9a-z\-_]', 'gi');
- // mimetypes supported by the browser (default settings)
- this.mimetypes = new Array('text/plain', 'text/html', 'text/xml',
- 'image/jpeg', 'image/gif', 'image/png',
- 'application/x-javascript', 'application/pdf', 'application/x-shockwave-flash');
-
// default environment vars
this.env.keep_alive = 60; // seconds
this.env.request_timeout = 180; // seconds
@@ -749,7 +744,7 @@ function rcube_webmail()
var qstring = '_mbox='+urlencode(this.env.mailbox)+'&_uid='+this.env.uid+'&_part='+props.part;
// open attachment in frame if it's of a supported mimetype
- if (this.env.uid && props.mimetype && $.inArray(props.mimetype, this.mimetypes)>=0) {
+ if (this.env.uid && props.mimetype && this.env.mimetypes && $.inArray(props.mimetype, this.env.mimetypes)>=0) {
if (props.mimetype == 'text/html')
qstring += '&_safe=1';
this.attachment_win = window.open(this.env.comm_path+'&_action=get&'+qstring+'&_frame=1', 'rcubemailattachment');