aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/PreviewManager.php
diff options
context:
space:
mode:
authorRoeland Jago Douma <roeland@famdouma.nl>2016-10-17 21:53:23 +0200
committerRoeland Jago Douma <roeland@famdouma.nl>2016-11-03 14:00:33 +0100
commit87855aa97b0d90f8036ec40174ac1a3dcbd463e8 (patch)
tree95aed134338652a4773af4c98549442141b67fb0 /lib/private/PreviewManager.php
parent3d6ee7ffc97af5c426ae7553bcb40f3c28064f93 (diff)
downloadnextcloud-server-87855aa97b0d90f8036ec40174ac1a3dcbd463e8.tar.gz
nextcloud-server-87855aa97b0d90f8036ec40174ac1a3dcbd463e8.zip
Added genertor helper & tests
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'lib/private/PreviewManager.php')
-rw-r--r--lib/private/PreviewManager.php7
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/private/PreviewManager.php b/lib/private/PreviewManager.php
index 2c17a5f3c80..a2ef9659b3b 100644
--- a/lib/private/PreviewManager.php
+++ b/lib/private/PreviewManager.php
@@ -26,6 +26,7 @@
namespace OC;
use OC\Preview\Generator;
+use OC\Preview\GeneratorHelper;
use OCP\Files\File;
use OCP\Files\IAppData;
use OCP\Files\IRootFolder;
@@ -159,10 +160,12 @@ class PreviewManager implements IPreview {
public function getPreview(File $file, $width = -1, $height = -1, $crop = false, $mode = IPreview::MODE_FILL, $mimeType = null) {
if ($this->generator === null) {
$this->generator = new Generator(
- $this->rootFolder,
$this->config,
$this,
- $this->appData
+ $this->appData,
+ new GeneratorHelper(
+ $this->rootFolder
+ )
);
}