mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-08-13 05:10:18 +00:00
Customize: Allow button_labels to be overridden in $args passed to WP_Customize_Media_Control and WP_Customize_Image_Control.
Props chetanchauhan, celloexpressions. See #33755. Fixes #35542. git-svn-id: https://develop.svn.wordpress.org/trunk@36769 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -31,7 +31,7 @@ class WP_Customize_Image_Control extends WP_Customize_Upload_Control {
|
||||
public function __construct( $manager, $id, $args = array() ) {
|
||||
parent::__construct( $manager, $id, $args );
|
||||
|
||||
$this->button_labels = array(
|
||||
$this->button_labels = wp_parse_args( $this->button_labels, array(
|
||||
'select' => __( 'Select Image' ),
|
||||
'change' => __( 'Change Image' ),
|
||||
'remove' => __( 'Remove' ),
|
||||
@@ -39,7 +39,7 @@ class WP_Customize_Image_Control extends WP_Customize_Upload_Control {
|
||||
'placeholder' => __( 'No image selected' ),
|
||||
'frame_title' => __( 'Select Image' ),
|
||||
'frame_button' => __( 'Choose Image' ),
|
||||
);
|
||||
) );
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user