summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/attachmentlist.php17
-rw-r--r--lib/common.php1
2 files changed, 18 insertions, 0 deletions
diff --git a/lib/attachmentlist.php b/lib/attachmentlist.php
index 61749dca5..45e4fa319 100644
--- a/lib/attachmentlist.php
+++ b/lib/attachmentlist.php
@@ -268,6 +268,23 @@ class Attachment extends AttachmentListItem
case 'image/jpeg':
$this->out->element('img', array('src' => $this->attachment->url, 'alt' => 'alt'));
break;
+
+ case 'application/ogg':
+ case 'audio/x-speex':
+ case 'video/mpeg':
+ case 'audio/mpeg':
+ case 'video/mp4':
+ case 'video/quicktime':
+ $arr = array('type' => $this->attachment->mimetype,
+ 'data' => $this->attachment->url,
+ 'width' => 320,
+ 'height' => 240
+ );
+ $this->out->elementStart('object', $arr);
+ $this->out->element('param', array('name' => 'src', 'value' => $this->attachment->url));
+ $this->out->element('param', array('name' => 'autoStart', 'value' => 1));
+ $this->out->elementEnd('object');
+ break;
}
}
} else {
diff --git a/lib/common.php b/lib/common.php
index 838f52f9d..ceb50337c 100644
--- a/lib/common.php
+++ b/lib/common.php
@@ -169,6 +169,7 @@ $config =
'image/gif',
'image/svg+xml',
'audio/mpeg',
+ 'audio/x-speex',
'application/ogg',
'application/pdf',
'application/vnd.oasis.opendocument.text',