Fix some hackificator odds and ends in wp-admin:

* `wp-activate.php` and `wp-admin/themes.php` don't need the closing PHP tag
* Switch single quotes for HTML attribute values to double in a few places
* Convert `include_once file.php` syntax to `include_once( 'file.php' )`
* Add access modifiers to methods/members in: `_WP_List_Table_Compat`, `Walker_Nav_Menu_Edit`, `Walker_Nav_Menu_Checklist`, `WP_Screen`, `Walker_Category_Checklist`
* `edit_user()` doesn't need to import the `$wpdb` global
* `wp_list_widgets()` doesn't need to import the `$sidebars_widgets` global
* switch/endswitch syntax is not supported in Hack
* A `<ul>` in `wp-admin/users.php` is unclosed

See #27881.

Built from https://develop.svn.wordpress.org/trunk@28500


git-svn-id: http://core.svn.wordpress.org/trunk@28326 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Scott Taylor
2014-05-19 05:04:16 +00:00
parent 511eabe5f3
commit 2f513d3320
27 changed files with 71 additions and 68 deletions

View File

@@ -19,7 +19,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu {
* @param int $depth Depth of menu item. Used for padding.
* @param array $args Not used.
*/
function start_lvl( &$output, $depth = 0, $args = array() ) {}
public function start_lvl( &$output, $depth = 0, $args = array() ) {}
/**
* Ends the list of after the elements are added.
@@ -32,7 +32,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu {
* @param int $depth Depth of menu item. Used for padding.
* @param array $args Not used.
*/
function end_lvl( &$output, $depth = 0, $args = array() ) {}
public function end_lvl( &$output, $depth = 0, $args = array() ) {}
/**
* Start the element output.
@@ -46,7 +46,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu {
* @param array $args Not used.
* @param int $id Not used.
*/
function start_el( &$output, $item, $depth = 0, $args = array(), $id = 0 ) {
public function start_el( &$output, $item, $depth = 0, $args = array(), $id = 0 ) {
global $_wp_nav_menu_max_depth;
$_wp_nav_menu_max_depth = $depth > $_wp_nav_menu_max_depth ? $depth : $_wp_nav_menu_max_depth;
@@ -235,7 +235,7 @@ class Walker_Nav_Menu_Edit extends Walker_Nav_Menu {
* @uses Walker_Nav_Menu
*/
class Walker_Nav_Menu_Checklist extends Walker_Nav_Menu {
function __construct( $fields = false ) {
public function __construct( $fields = false ) {
if ( $fields ) {
$this->db_fields = $fields;
}
@@ -252,7 +252,7 @@ class Walker_Nav_Menu_Checklist extends Walker_Nav_Menu {
* @param int $depth Depth of page. Used for padding.
* @param array $args Not used.
*/
function start_lvl( &$output, $depth = 0, $args = array() ) {
public function start_lvl( &$output, $depth = 0, $args = array() ) {
$indent = str_repeat( "\t", $depth );
$output .= "\n$indent<ul class='children'>\n";
}
@@ -268,7 +268,7 @@ class Walker_Nav_Menu_Checklist extends Walker_Nav_Menu {
* @param int $depth Depth of page. Used for padding.
* @param array $args Not used.
*/
function end_lvl( &$output, $depth = 0, $args = array() ) {
public function end_lvl( &$output, $depth = 0, $args = array() ) {
$indent = str_repeat( "\t", $depth );
$output .= "\n$indent</ul>";
}
@@ -286,7 +286,7 @@ class Walker_Nav_Menu_Checklist extends Walker_Nav_Menu {
* @param array $args Not used.
* @param int $id Not used.
*/
function start_el( &$output, $item, $depth = 0, $args = array(), $id = 0 ) {
public function start_el( &$output, $item, $depth = 0, $args = array(), $id = 0 ) {
global $_nav_menu_placeholder;
$_nav_menu_placeholder = ( 0 > $_nav_menu_placeholder ) ? intval($_nav_menu_placeholder) - 1 : -1;