WordPress.org

Make WordPress Core

Ticket #10020: 10020.2.diff

File 10020.2.diff, 1.9 KB (added by Denis-de-Bernardy, 6 years ago)
  • wp-includes/widgets.php

     
    273273 
    274274        /** Helper function: Registers a single instance. */ 
    275275        function _register_one($number = -1) { 
     276                do_action_ref_array('register_widget', array(&$this)); 
    276277                wp_register_sidebar_widget(     $this->id, $this->name, $this->_get_display_callback(), $this->widget_options, array( 'number' => $number ) ); 
    277278                _register_widget_update_callback( $this->id_base, $this->_get_update_callback(), $this->control_options, array( 'number' => -1 ) ); 
    278279                _register_widget_form_callback( $this->id, $this->name, $this->_get_form_callback(), $this->control_options, array( 'number' => $number ) ); 
  • wp-admin/includes/widgets.php

     
    188188                <a class="widget-control-remove" href="#remove"><?php _e('Remove'); ?></a> | 
    189189                <a class="widget-control-close" href="#close"><?php _e('Close'); ?></a> 
    190190                </div> 
    191 <?php           if ( 'noform' !== $has_form ) { ?> 
    192                 <div class="alignright"> 
     191                <div class="alignright <?php if ( 'noform' === $has_form ) echo ' widget-control-noform'; ?>"> 
    193192                <img src="images/wpspin_light.gif" class="ajax-feedback " title="" alt="" /> 
    194193                <input type="submit" name="savewidget" class="button-primary widget-control-save" value="<?php esc_attr_e('Save'); ?>" /> 
    195194                </div> 
    196 <?php           } ?> 
    197195                <br class="clear" /> 
    198196        </div> 
    199197        </form> 
  • wp-admin/css/widgets.css

     
    322322        font-size: 12px; 
    323323} 
    324324 
     325.widget-control-noform { 
     326        display: none; 
     327} 
     328 
    325329#access-off, 
    326330.widgets_access .widget-action, 
    327331.widgets_access .sidebar-name-arrow,