Source of file KickAssetsImage.php
Size: 0,600 Bytes - Last Modified: 2021-12-23T10:32:40+00:00
/var/www/docs.ssmods.com/process/src/code/KickAssetsImage.php
12345678910111213141516171819202122232425 | <?php /** * Provides some some helper methods for generating images in the KickAssets UI * * @package unclecheese/silverstripe-kickassets * @author Uncle Cheese <unclecheese@leftandmain.com> */ class KickAssetsImage extends DataExtension { /** * Returns an image properly formatted for the detail panel * @return Image_Cached */ public function getKickAssetsDetailImage() { if ($this->owner->getOrientation() === Image::ORIENTATION_PORTRAIT) { return $this->owner->SetHeight(400); } return $this->owner->SetWidth(600); } } |