WordPress.org

Make WordPress Core


Ignore:
Timestamp:
03/02/2012 10:09:26 PM (10 years ago)
Author:
nacin
Message:

Output themes and theme-install infinite scrolling args in JS, rather than parsing query strings. props DH-Shredder, helenyhou. Make WP_Theme_Install_List_Table extend WP_Themes_List_Table. Doesn't help much yet, but we should be able to dry things up further. see #19815.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/wp-admin/includes/list-table.php

    r19712 r20094  
    2929        'WP_Plugin_Install_List_Table' => 'plugin-install',
    3030        'WP_Themes_List_Table' => 'themes',
    31         'WP_Theme_Install_List_Table' => 'theme-install',
     31        'WP_Theme_Install_List_Table' => array( 'themes', 'theme-install' ),
    3232        'WP_Plugins_List_Table' => 'plugins',
    3333        // Network Admin
     
    3838
    3939    if ( isset( $core_classes[ $class ] ) ) {
    40         require_once( ABSPATH . 'wp-admin/includes/class-wp-' . $core_classes[ $class ] . '-list-table.php' );
     40        foreach ( (array) $core_classes[ $class ] as $required )
     41            require_once( ABSPATH . 'wp-admin/includes/class-wp-' . $required . '-list-table.php' );
    4142        return new $class;
    4243    }
Note: See TracChangeset for help on using the changeset viewer.