From: Georg Ehrke Date: Sat, 13 Jul 2013 22:00:10 +0000 (+0200) Subject: OC\Preview - set scale factor down to 2 and upscale cached preview - this got lost... X-Git-Tag: v6.0.0alpha2~235^2~57 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=1303fe0f9fe7c67764fb48cbb84fcb30e4a32b33;p=nextcloud-server.git OC\Preview - set scale factor down to 2 and upscale cached preview - this got lost in a git stash ... --- diff --git a/lib/preview.php b/lib/preview.php index 08c0b7e20d0..03aaaceb9ca 100755 --- a/lib/preview.php +++ b/lib/preview.php @@ -60,7 +60,7 @@ class Preview { //set config $this->configMaxX = \OC_Config::getValue('preview_max_x', null); $this->configMaxY = \OC_Config::getValue('preview_max_y', null); - $this->maxScaleFactor = \OC_Config::getValue('preview_max_scale_factor', 10); + $this->maxScaleFactor = \OC_Config::getValue('preview_max_scale_factor', 2); //save parameters $this->setFile($file); @@ -377,6 +377,7 @@ class Preview { if($cached) { $image = new \OC_Image($this->userview->file_get_contents($cached, 'r')); $this->preview = $image->valid() ? $image : null; + $this->resizeAndCrop(); } if(is_null($this->preview)) {