Commit 638cb4dc57a4c0d1bfcb1d4f25f8a7dead41e870

Authored by Paul Barrett
1 parent e1088deb

Removed dubious windows only thumbnail path code. Added comment about windows c…

…ommand probably needing quotes (quotes previously added.)

Committed by: Paul Barrett

Reviewed by: Jarrett Jordaan
plugins/thumbnails/thumbnails.php
... ... @@ -171,10 +171,6 @@ class thumbnailGenerator extends BaseProcessor
171 171 return false;
172 172 }
173 173  
174   - if (WINDOWS_OS) {
175   - $thumbnailfile = KT_DIR . $thumbnailfile;
176   - }
177   -
178 174 // if a previous version of the thumbnail exists - delete it
179 175 if (file_exists($thumbnailfile)) {
180 176 @unlink($thumbnailfile);
... ... @@ -182,6 +178,7 @@ class thumbnailGenerator extends BaseProcessor
182 178 // do generation
183 179 // if (extension_loaded('imagick')) {
184 180 $pathConvert = (!empty($default->convertPath)) ? $default->convertPath : 'convert';
  181 + // windows path may contain spaces
185 182 if (WINDOWS_OS) {
186 183 $pathConvert = '"' . $pathConvert . '"';
187 184 }
... ... @@ -220,10 +217,6 @@ class ThumbnailViewlet extends KTDocumentViewlet {
220 217 global $default;
221 218 $varDir = $default->internalVarDirectory;
222 219 $thumbnailfile = $varDir . '/thumbnails/'.$documentId.'.jpg';
223   -
224   - if (WINDOWS_OS) {
225   - $thumbnailfile = KT_DIR . $thumbnailfile;
226   - }
227 220  
228 221 // if the thumbnail doesn't exist try to create it
229 222 if (!file_exists($thumbnailfile)){
... ...
setup/wizard/steps/database.php
... ... @@ -790,9 +790,8 @@ class database extends Step
790 790 // if Windows, attempt to insert full paths to binaries
791 791 if (WINDOWS_OS) {
792 792 $winBinaries = array('php' => 'ZendServer\bin\php.exe', 'python' => 'openoffice\program\python.exe',
793   - 'java' => 'jre\bin\java.exe',
794   - // since we don't know where convert is yet, let's just assume somewhere for now (manually test)
795   - 'convert' => 'bin\imagemagick\convert.exe',
  793 + 'java' => 'jre\bin\java.exe', 'convert' => 'bin\imagemagick\convert.exe',
  794 + 'df' => 'bin//df.exe',
796 795 'zip' => 'bin\zip\zip.exe', 'unzip' => 'bin\unzip\unzip.exe');
797 796 foreach ($winBinaries as $displayName => $bin)
798 797 {
... ... @@ -822,7 +821,8 @@ class database extends Step
822 821 }
823 822 // if Linux?
824 823 else {
825   - // TODO python binary
  824 + // TODO python binary?
  825 + // TODO other binaries?
826 826 }
827 827 }
828 828  
... ...