]> scripts.mit.edu Git - autoinstalls/wordpress.git/blobdiff - wp-includes/class-wp-customize-panel.php
WordPress 4.2.5
[autoinstalls/wordpress.git] / wp-includes / class-wp-customize-panel.php
index f5da18e3d7a3447e59959389b8fadab786393bf8..ee9f846bc80e84780786b2d2230d1117bb13ed7f 100644 (file)
@@ -1,13 +1,21 @@
 <?php
 /**
- * Customize Panel Class.
- *
- * A UI container for sections, managed by the WP_Customize_Manager.
+ * WordPress Customize Panel classes
  *
  * @package WordPress
  * @subpackage Customize
  * @since 4.0.0
  */
+
+/**
+ * Customize Panel class.
+ *
+ * A UI container for sections, managed by the WP_Customize_Manager.
+ *
+ * @since 4.0.0
+ *
+ * @see WP_Customize_Manager
+ */
 class WP_Customize_Panel {
 
        /**
@@ -154,8 +162,6 @@ class WP_Customize_Panel {
                $this->instance_number = self::$instance_count;
 
                $this->sections = array(); // Users cannot customize the $sections array.
-
-               return $this;
        }
 
        /**
@@ -166,7 +172,7 @@ class WP_Customize_Panel {
         *
         * @return bool Whether the panel is active to the current preview.
         */
-       public final function active() {
+       final public function active() {
                $panel = $this;
                $active = call_user_func( $this->active_callback, $this );
 
@@ -221,7 +227,7 @@ class WP_Customize_Panel {
         *
         * @return bool False if theme doesn't support the panel or the user doesn't have the capability.
         */
-       public final function check_capabilities() {
+       final public function check_capabilities() {
                if ( $this->capability && ! call_user_func_array( 'current_user_can', (array) $this->capability ) ) {
                        return false;
                }
@@ -240,7 +246,7 @@ class WP_Customize_Panel {
         *
         * @return string Content for the panel.
         */
-       public final function get_content() {
+       final public function get_content() {
                ob_start();
                $this->maybe_render();
                $template = trim( ob_get_contents() );
@@ -253,7 +259,7 @@ class WP_Customize_Panel {
         *
         * @since 4.0.0
         */
-       public final function maybe_render() {
+       final public function maybe_render() {
                if ( ! $this->check_capabilities() ) {
                        return;
                }