Changeset 1747658
- Timestamp:
- 10/17/2017 04:30:41 AM (8 years ago)
- Location:
- easy-lazy-loader/trunk
- Files:
-
- 4 edited
-
easy-lazy-loader.php (modified) (4 diffs)
-
js/easy-lazy-loader.js (modified) (1 diff)
-
js/easy-lazy-loader.min.js (modified) (1 diff)
-
readme.txt (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
easy-lazy-loader/trunk/easy-lazy-loader.php
r1747647 r1747658 2 2 /* 3 3 Plugin Name: Easy Lazy Loader 4 Version: 1.1. 14 Version: 1.1.2 5 5 Plugin URI: https://www.iprodev.com/go/easy-lazy-loader/ 6 6 Author: iProDev … … 16 16 17 17 class EasyLazyLoader { 18 const version = '1.1. 1';18 const version = '1.1.2'; 19 19 20 20 public $MAIN; … … 498 498 public function enqueue_scripts() { 499 499 wp_enqueue_script( 'jquery-sonar', self::get_url( $this->OPTIONS['debug_mode'] ? 'js/jquery.sonar.js' : 'js/jquery.sonar.min.js' ), array( 'jquery' ), '3.0.0', true ); 500 //wp_enqueue_script( $this->SLUG, self::get_url( $this->OPTIONS['debug_mode'] ? 'js/easy-lazy-loader.js' : 'js/easy-lazy-loader.min.js' ), array( 'jquery', 'jquery-sonar' ), self::version, true );500 wp_enqueue_script( $this->SLUG, self::get_url( $this->OPTIONS['debug_mode'] ? 'js/easy-lazy-loader.js' : 'js/easy-lazy-loader.min.js' ), array( 'jquery', 'jquery-sonar' ), self::version, true ); 501 501 502 502 wp_localize_script( $this->SLUG, $this->SLUG, array( … … 940 940 */ 941 941 public static function create_placeholder( $background = '#FFF', $width = 1, $height = 1, $text = "" ) { 942 $factor = min( 1 / $width, 1 / $height ); 943 $width_new = round( $width * $factor ); 944 $height_new = round( $height * $factor ); 945 946 if ( $width_new <= 0 ) { 947 $factor = 1 / $width; 948 } else if ( $height_new <= 0 ) { 949 $factor = 1 / $height; 950 } 951 952 $width = round( $width * $factor ); 953 $height = round( $height * $factor ); 942 if ( $width >= 30 && $height >= 30 ) { 943 $new_dimensions = wp_constrain_dimensions( $width, $height, 30, 30 ); 944 $width = $new_dimensions[0]; 945 $height = $new_dimensions[1]; 946 } 947 else { 948 if ( $width >= $height ) { 949 $width = $ratio = round( $width / $height ); 950 $height = 1; 951 } else { 952 $height = $ratio = round( $height / $width ); 953 $width = 1; 954 } 955 } 954 956 955 957 // Create a new image instance -
easy-lazy-loader/trunk/js/easy-lazy-loader.js
r1747647 r1747658 3 3 * http://www.iprodev.com/ 4 4 * 5 * @version: 1.1. 1- October 17, 20175 * @version: 1.1.2 - October 17, 2017 6 6 * 7 7 * @author: iProDev (Hemn Chawroka) -
easy-lazy-loader/trunk/js/easy-lazy-loader.min.js
r1747647 r1747658 3 3 * https://www.iprodev.com/ 4 4 * 5 * @version: 1.1. 1- October 17, 20175 * @version: 1.1.2 - October 17, 2017 6 6 * 7 7 * @author: iProDev (Hemn Chawroka) -
easy-lazy-loader/trunk/readme.txt
r1747647 r1747658 5 5 Requires at least: 3.2 6 6 Tested up to: 4.9 7 Stable tag: 1.1. 17 Stable tag: 1.1.2 8 8 License: GPLv3 9 9 License URI: https://www.gnu.org/licenses/gpl.html … … 102 102 == Changelog == 103 103 104 = 1.1.2 = 105 106 * **Fixed:** some bugs and stability improvements. 107 104 108 = 1.1.1 = 105 109
Note: See TracChangeset
for help on using the changeset viewer.