summaryrefslogtreecommitdiffstats
path: root/lib/private/Preview
Commit message (Collapse)AuthorAgeFilesLines
* Allow the creationg of previews of files stored in appdataRoeland Jago Douma2018-10-091-11/+8
| | | | | | | To allow us to create previews of files stored in appdata we need to construct the view differently. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Make sure the file is readable before attempting to create a previewRoeland Jago Douma2018-05-291-0/+6
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Delete the previews when a version is restoredRoeland Jago Douma2018-05-262-0/+12
| | | | | | | | | Fixes #9469 When a version of a file is restored the previews are no longer valid. Thus we should remove them so they are regenerated. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* If the preview is size 0 it is invalidRoeland Jago Douma2018-01-241-3/+13
| | | | | | | | | * delete it * throw a NotFound Exception - This should a proper 404 to the user - Next time it is then regenerated Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Merge pull request #7731 from nextcloud/preview_size_incJan-Christoph Borchardt2018-01-091-2/+2
|\ | | | | Max preview size to 4096x4096
| * Max preview size to 4096x4096Roeland Jago Douma2018-01-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | With HiDPI screens. And even normal HD screens you want more detail from your pictures. Or the ability to somewhat zoom on you previews. For this we need somewhat larger previews. Moving the default to 4096x4096 is a step up. Users that want the old behavior can still set the values in config.php Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Only return 1 typeRoeland Jago Douma2018-01-071-5/+17
| | | | | | | | | | | | | | Throw proper exception if we can't get the mimetype for a preview. Catch it later on so we can just return a not found for the preview. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | Don't lie about the preview mimetypeRoeland Jago Douma2018-01-071-7/+29
|/ | | | | | | | | | | | | | For legacy reasons we stored all the previews with a png extention. However we did not put png data in them all the time. This caused the preview endpoints to always report that a preview is a png file. Which was a lie. Since we abstract away from the storage etc in the previewmanager. There is no need anymore to store them as .png files and instead we can use the actual file extention. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Properly detect if fopen fails for txt previewsRoeland Jago Douma2017-12-111-0/+5
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Change @georgehrke's emailMorris Jobke2017-11-066-6/+6
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Update license headersMorris Jobke2017-11-065-4/+6
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Allow requesting the max previewRoeland Jago Douma2017-09-251-0/+6
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Use IConfig instead of static OCP\ConfigMorris Jobke2017-07-271-1/+1
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* Merge pull request #5836 from nextcloud/preview_updateLukas Reschke2017-07-251-1/+7
|\ | | | | Empty search no longer works
| * Empty search no longer worksRoeland Jago Douma2017-07-241-1/+7
| | | | | | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* | More phpstorm inspection fixesRoeland Jago Douma2017-07-243-3/+3
|/ | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Add PHPDocMorris Jobke2017-05-021-0/+2
| | | | Signed-off-by: Morris Jobke <hey@morrisjobke.de>
* better handling of preview generation errorsRobin Appelman2017-05-021-0/+5
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Some code cleanupRoeland Jago Douma2017-03-191-12/+21
| | | | | | As suggested by the inspector Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Don't generate max preview twiceRoeland Jago Douma2017-03-191-0/+5
| | | | | | | | If you request a preview of X by Y. And after calculating X and Y are equal to maxWidth and maxHeight then there is no reason to create a preview of that size. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* MP3 without cover don't get a previewRoeland Jago Douma2017-03-101-19/+1
| | | | | | | | | | * Fixes #2739 It tries to create an image from an SVG file. Which we don't support. So this fails and prints an log line. Then we fall back anyways to the 404 and fetch the default icon. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Fix previews for federated sharesRoeland Jago Douma2016-11-241-1/+2
| | | | | | | The owner of a federated file is the federated user. For which we obviously can't setup a view. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Dispatch event on preview requestRoeland Jago Douma2016-11-101-1/+18
| | | | | | Fixes: #73 Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Added genertor helper & testsRoeland Jago Douma2016-11-032-35/+100
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Moved over files_versionsRoeland Jago Douma2016-11-031-5/+10
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Move Ipreview to more of DI thingyRoeland Jago Douma2016-11-031-22/+15
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Fix name conflictRoeland Jago Douma2016-11-031-3/+3
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Move fileRoeland Jago Douma2016-11-031-0/+366
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Watch for file modification/deletionRoeland Jago Douma2016-11-032-0/+170
| | | | | | | * Only connect the watcher once the instance is properly setup else AppData fails hard. Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Update with robinJoas Schilling2016-07-213-3/+3
|
* Fix othersJoas Schilling2016-07-2125-44/+70
|
* remove png references in coreHendrik Leppelsack2016-07-011-1/+1
|
* Update license headersLukas Reschke2016-05-262-0/+2
|
* Move \OC\Preview to PSR-4Roeland Jago Douma2016-04-2025-0/+1247