Changeset 22493
- Timestamp:
- 11/09/2012 06:15:25 AM (12 years ago)
- Location:
- trunk/wp-includes
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/wp-includes/js/media-views.js
r22487 r22493 949 949 var state = this.state(), 950 950 display = state.get('details'), 951 single = state.get('selection').single() .cid;951 single = state.get('selection').single(); 952 952 953 953 this.settingsSidebar({ silent: true }); 954 954 955 display[ single ] = display[ single] || new Backbone.Model({955 display[ single.cid ] = display[ single.cid ] || new Backbone.Model({ 956 956 align: getUserSetting( 'align', 'none' ), 957 957 size: getUserSetting( 'imgsize', 'medium' ), … … 962 962 display: new media.view.Settings.AttachmentDisplay({ 963 963 controller: this, 964 model: display[ single ], 964 model: display[ single.cid ], 965 sizes: single.get('sizes'), 965 966 priority: 100, 966 967 userSettings: state.get('displayUserSettings') -
trunk/wp-includes/media.php
r22489 r22493 1472 1472 </button> 1473 1473 </div> 1474 1475 <# if ( ! _.isUndefined( sizes ) ) { #> 1476 <h4><?php _e('Size'); ?></h4> 1477 <select class="size" name="size" 1478 data-setting="size" 1479 <# if ( userSettings ) { #> 1480 data-user-setting="imgsize" 1481 <# } #>> 1482 <?php 1483 1484 $sizes = apply_filters( 'image_size_names_choose', array( 1485 'thumbnail' => __('Thumbnail'), 1486 'medium' => __('Medium'), 1487 'large' => __('Large'), 1488 ) ); 1489 1490 foreach ( $sizes as $value => $name ) : ?> 1491 <# if ( ! _.isUndefined( sizes['<?php echo esc_js( $value ); ?>'] ) ) { #> 1492 <option value="<?php echo esc_attr( $value ); ?>" <?php selected( $value, 'medium' ); ?>> 1493 <?php echo esc_html( $name ); ?> 1494 </option> 1495 <# } #>> 1496 <?php endforeach; ?> 1497 1498 <option value="full"> 1499 <?php echo esc_html_e( 'Full Size' ); ?> 1500 </option> 1501 </select> 1502 <# } #> 1474 1503 </script> 1475 1504
Note: See TracChangeset
for help on using the changeset viewer.