Plugin Directory

Changeset 2044751


Ignore:
Timestamp:
03/05/2019 06:33:44 PM (7 years ago)
Author:
aprokopenko
Message:

v1.6.5 fix retina image of the same size as origin

Location:
just-responsive-images
Files:
32 added
3 edited

Legend:

Unmodified
Added
Removed
  • just-responsive-images/trunk/just-responsive-images.php

    r2019207 r2044751  
    55Description: Providing full control to set your own responsive image properties for WordPress 4.4+, the ability to use the <picture> tag, auto-generate image backgrounds and supports retina images.
    66Tags: responsive post thumbnail, post thumbnail as background, retina support, retina image, retina post thumbnail, responsive post attachment, responsive images, responsive attachments, post thumbnails, media
    7 Version: 1.6.4
     7Version: 1.6.5
    88Author: JustCoded / Alex Prokopenko
    99Author URI: http://justcoded.com/
     
    5050        // init plugin name and version.
    5151        self::$plugin_name = __( 'Just Responsive Images', JustResponsiveImages::TEXTDOMAIN );
    52         self::$version     = '1.640';
     52        self::$version     = '1.650';
    5353
    5454        // init features, which this plugin is created for.
  • just-responsive-images/trunk/models/RwdImage.php

    r2019207 r2044751  
    484484                        $retina_w = $option->size->w * $multiplier;
    485485                        $retina_h = $option->size->h * $multiplier;
    486                         if ( $retina_w < $meta_data['width'] && $retina_h < $meta_data['height'] ) {
     486                        if ( $retina_w <= $meta_data['width'] && $retina_h <= $meta_data['height'] ) {
    487487                            $meta_data = $this->resize_image(
    488488                                $attachment->ID,
     
    620620                if ( ( $meta_data['width'] > $resize_sizes['width'] && $meta_data['height'] > $resize_sizes['height'] )
    621621                    // - if crop enabled and resized image match the requested size - resize was successful.
    622                     || ( ! empty( $crop ) && $resize_sizes['width'] === $width && $resize_sizes['height'] === $height )
     622                    || ( ! empty( $crop ) && $resize_sizes['width'] == $width && $resize_sizes['height'] == $height )
    623623                ) {
    624624                    // WP Image Editor save image.
  • just-responsive-images/trunk/readme.txt

    r2019207 r2044751  
    77Author URI: http://justcoded.com/
    88Requires at least: 4.5
    9 Tested up to: 5.0.3
     9Tested up to: 5.1
    1010Requires PHP: >=5.6
    1111License: GPL3
     
    9191
    9292== Changelog ==
    93 = Version 1.6.4 - 25 January 2018 =
     93
     94= Version 1.6.5 - 5 March 2019 =
     95    * Fixed retina size, which match image original size.
     96= Version 1.6.4 - 25 January 2019 =
    9497    * Fixed always resize for retina if 2x is bigger than original image.
    9598    * Add ability to set default tag for rwd_attachment_image() with a filter.
Note: See TracChangeset for help on using the changeset viewer.