WordPress.org

Make WordPress Core


Ignore:
Timestamp:
01/18/2020 12:52:28 AM (21 months ago)
Author:
SergeyBiryukov
Message:

Docs: Improve comments in some wp-admin files per the documentation standards.

Props passoniate.
Fixes #49215, #49216.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/image-edit.php

    r47065 r47084  
    200200            <?php
    201201
    202             // On some setups GD library does not provide imagerotate() - Ticket #11536
     202            // On some setups GD library does not provide imagerotate() - Ticket #11536.
    203203            if ( wp_image_editor_supports(
    204204                array(
     
    602602                    $h    = $size['height'];
    603603
    604                     $scale = 1 / _image_get_preview_ratio( $w, $h ); // discard preview scaling
     604                    $scale = 1 / _image_get_preview_ratio( $w, $h ); // Discard preview scaling.
    605605                    $image->crop( $sel->x * $scale, $sel->y * $scale, $sel->w * $scale, $sel->h * $scale );
    606606                } else {
    607                     $scale = 1 / _image_get_preview_ratio( imagesx( $image ), imagesy( $image ) ); // discard preview scaling
     607                    $scale = 1 / _image_get_preview_ratio( imagesx( $image ), imagesy( $image ) ); // Discard preview scaling.
    608608                    $image = _crop_image_resource( $image, $sel->x * $scale, $sel->y * $scale, $sel->w * $scale, $sel->h * $scale );
    609609                }
     
    956956
    957957        if ( $target == 'thumbnail' || $target == 'all' || $target == 'full' ) {
    958             // Check if it's an image edit from attachment edit screen
     958            // Check if it's an image edit from attachment edit screen.
    959959            if ( ! empty( $_REQUEST['context'] ) && 'edit-attachment' == $_REQUEST['context'] ) {
    960960                $thumb_url         = wp_get_attachment_image_src( $post_id, array( 900, 600 ), true );
Note: See TracChangeset for help on using the changeset viewer.