Changeset 15003
- Timestamp:
- 05/27/2010 08:41:36 PM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/media.php
r15002 r15003 278 278 279 279 $width_ratio = $height_ratio = 1.0; 280 $did_width = $did_height = false; 280 281 281 282 if ( $max_width > 0 && $current_width > 0 && $current_width > $max_width ) { … … 306 307 // We also have issues with recursive calls resulting in an ever-changing result. Contraining to the result of a constraint should yield the original result. 307 308 // Thus we look for dimensions that are one pixel shy of the max value and bump them up 308 if ( isset( $did_width ) &&$did_width && $w == $max_width - 1 )309 if ( $did_width && $w == $max_width - 1 ) 309 310 $w = $max_width; // Round it up 310 if ( isset( $did_height ) &&$did_height && $h == $max_height - 1 )311 if ( $did_height && $h == $max_height - 1 ) 311 312 $h = $max_height; // Round it up 312 313
Note: See TracChangeset
for help on using the changeset viewer.