Changeset View
Changeset View
Standalone View
Standalone View
src/applications/files/document/PhabricatorVideoDocumentEngine.php
<?php | <?php | ||||
final class PhabricatorVideoDocumentEngine | final class PhabricatorVideoDocumentEngine | ||||
extends PhabricatorDocumentEngine { | extends PhabricatorDocumentEngine { | ||||
const ENGINEKEY = 'video'; | const ENGINEKEY = 'video'; | ||||
public function getViewAsLabel(PhabricatorDocumentRef $ref) { | |||||
return pht('View as Video'); | |||||
} | |||||
protected function getDocumentIconIcon(PhabricatorDocumentRef $ref) { | protected function getDocumentIconIcon(PhabricatorDocumentRef $ref) { | ||||
return 'fa-film'; | return 'fa-film'; | ||||
} | } | ||||
protected function canRenderDocumentType(PhabricatorDocumentRef $ref) { | protected function canRenderDocumentType(PhabricatorDocumentRef $ref) { | ||||
$file = $ref->getFile(); | $file = $ref->getFile(); | ||||
if ($file) { | if ($file) { | ||||
return $file->isVideo(); | return $file->isVideo(); | ||||
▲ Show 20 Lines • Show All 46 Lines • Show Last 20 Lines |