mirror of
https://git.code.sf.net/p/seeddms/code
synced 2025-03-12 00:45:34 +00:00
$width passed to getFileName() is optional
This commit is contained in:
parent
99569a3435
commit
6f9ec7cdc3
|
@ -52,10 +52,15 @@ class SeedDMS_Preview_Previewer extends SeedDMS_Preview_Base {
|
|||
* @param integer $width width of preview image
|
||||
* @return string file name of preview image
|
||||
*/
|
||||
public function getFileName($object, $width) { /* {{{ */
|
||||
public function getFileName($object, $width=0) { /* {{{ */
|
||||
if(!$object)
|
||||
return false;
|
||||
|
||||
if($width == 0)
|
||||
$width = $this->width;
|
||||
else
|
||||
$width = intval($width);
|
||||
|
||||
$document = $object->getDocument();
|
||||
$dms = $document->_dms;
|
||||
$dir = $this->previewDir.'/'.$document->getDir();
|
||||
|
|
Loading…
Reference in New Issue
Block a user