Changeset 29903 for trunk/src/wp-includes/class-wp-customize-widgets.php
- Timestamp:
- 10/15/2014 05:20:34 PM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/class-wp-customize-widgets.php
r29488 r29903 117 117 * Set up widget addition previews. 118 118 * 119 * Since the widgets get registered on 'widgets_init' before the customizer119 * Since the widgets get registered on 'widgets_init' before the Customizer 120 120 * settings are set up on 'customize_register', we have to filter the options 121 121 * similarly to how the setting previewer will filter the options later. … … 147 147 } 148 148 149 // Input from customizer preview.149 // Input from Customizer preview. 150 150 if ( isset( $_POST['customized'] ) ) { 151 151 $this->_customized = json_decode( $this->get_post_value( 'customized' ), true ); … … 202 202 * Ensure that newly-added widgets will appear in the widgets_sidebars. 203 203 * 204 * This is necessary because the customizer's setting preview filters204 * This is necessary because the Customizer's setting preview filters 205 205 * are added after the widgets_init action, which is too late for the 206 206 * widgets to be set up properly. … … 226 226 * will be recognized. 227 227 * 228 * This is necessary because the customizer's setting preview228 * This is necessary because the Customizer's setting preview 229 229 * filters are added after the widgets_init action, which is 230 230 * too late for the widgets to be set up properly. … … 288 288 * Override sidebars_widgets for theme switch. 289 289 * 290 * When switching a theme via the customizer, supply any previously-configured290 * When switching a theme via the Customizer, supply any previously-configured 291 291 * sidebars_widgets from the target theme as the initial sidebars_widgets 292 292 * setting. Also store the old theme's existing settings so that they can … … 314 314 315 315 /** 316 * Filter old_sidebars_widgets_data customizer setting.316 * Filter old_sidebars_widgets_data Customizer setting. 317 317 * 318 318 * When switching themes, filter the Customizer setting … … 389 389 390 390 /** 391 * Register customizer settings and controls for all sidebars and widgets.391 * Register Customizer settings and controls for all sidebars and widgets. 392 392 * 393 393 * @since 3.9.0 … … 535 535 536 536 /** 537 * Covert a widget_id into its corresponding customizer setting ID (option name).537 * Covert a widget_id into its corresponding Customizer setting ID (option name). 538 538 * 539 539 * @since 3.9.0 … … 557 557 * 558 558 * Core widgets which may have controls wider than 250, but can 559 * still be shown in the narrow customizer panel. The RSS and Text559 * still be shown in the narrow Customizer panel. The RSS and Text 560 560 * widgets in Core, for example, have widths of 400 and yet they 561 * still render fine in the customizer panel. This method will561 * still render fine in the Customizer panel. This method will 562 562 * return all Core widgets as being not wide, but this can be 563 563 * overridden with the is_wide_widget_in_customizer filter. … … 665 665 666 666 /** 667 * Enqueue scripts and styles for customizer panel and export data to JavaScript.667 * Enqueue scripts and styles for Customizer panel and export data to JavaScript. 668 668 * 669 669 * @since 3.9.0 … … 965 965 966 966 /** 967 * Add hooks for the customizer preview.967 * Add hooks for the Customizer preview. 968 968 * 969 969 * @since 3.9.0 … … 983 983 * (via wp_convert_widget_settings()) and can set global variable 984 984 * $_wp_sidebars_widgets to the value of get_option( 'sidebars_widgets' ) 985 * before the customizer preview filter is added, we have to reset985 * before the Customizer preview filter is added, we have to reset 986 986 * it after the filter has been added. 987 987 * … … 1040 1040 public function export_preview_data() { 1041 1041 1042 // Prepare customizer settings to pass to Javascript.1042 // Prepare Customizer settings to pass to Javascript. 1043 1043 $settings = array( 1044 1044 'renderedSidebars' => array_fill_keys( array_unique( $this->rendered_sidebars ), true ),
Note: See TracChangeset
for help on using the changeset viewer.