To participate you must create an account on apostrophenow.org. If you have already done so, click Login.

Changeset 4457

Show
Ignore:
Timestamp:
01/05/12 19:58:58 (5 months ago)
Author:
tboutell
Message:

Fixed #1211: "defaults for cropping an image in a previously saved slideshow that was not cropped on the first save make no sense." Now the right thing happens if you create a slideshow, SAVE it, click Choose Images AGAIN and attempt to crop a previously uncropped image.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • plugins/apostrophePlugin/branches/1.5/web/js/aCrop.js

    r3320 r4457  
    132132 
    133133    if (!imageInfo.cropWidth) { 
    134       if (aCrop.options.aspectRatio > 1) { 
     134                        if (!aCrop.options.aspectRatio) 
     135                        { 
     136        imageInfo.cropWidth = imageInfo.width; 
     137        imageInfo.cropHeight = imageInfo.height; 
     138                        } 
     139                        else if (aCrop.options.aspectRatio > 1)  
     140                        { 
    135141        imageInfo.cropWidth = imageInfo.width; 
    136142        imageInfo.cropHeight = Math.floor(imageInfo.width / aCrop.options.aspectRatio); 
     
    232238      imageInfo.cropTop + imageInfo.cropHeight 
    233239    ]; 
    234      
    235240    aCrop.api.setSelect(coords); 
    236241                $('.cropping-now').removeClass('cropping-now');