WordPress.org

Make WordPress Core

Ticket #16827: colors-hacked-fixed.diff

File colors-hacked-fixed.diff, 1.8 KB (added by westi, 4 years ago)

In progress hacking

  • public/wp-includes/general-template.php

    ### Eclipse Workspace Patch 1.0
    #P multisite.domain
     
    21232123        // For backward compatibility 
    21242124        $handle = 0 === strpos( $file, 'css/' ) ? substr( $file, 4 ) : $file; 
    21252125 
     2126        if ( 'colors' == $handle ) { 
     2127                global $_wp_admin_css_colors; 
     2128                $color = get_user_option('admin_color'); 
     2129                 
     2130                if ( empty($color) || !isset($_wp_admin_css_colors[$color]) ) 
     2131                        $color = 'fresh'; 
     2132                 
     2133                $handle = $handle . '-' . $color; 
     2134        }        
     2135 
    21262136        if ( $wp_styles->query( $handle ) ) { 
    21272137                if ( $force_echo || did_action( 'wp_print_styles' ) ) // we already printed the style queue.  Print this one immediately 
    21282138                        wp_print_styles( $handle ); 
  • public/wp-includes/script-loader.php

     
    480480        $colors_version = '20110121'; 
    481481 
    482482        // Register "meta" stylesheet for admin colors. All colors-* style sheets should have the same version string. 
    483         $styles->add( 'colors', true, array(), $colors_version ); 
     483//      $styles->add( 'colors', "/wp-admin/css/colors$suffix.css", array(), $colors_version ); 
    484484 
    485485        // do not refer to these directly, the right one is queued by the above "meta" colors handle 
    486486        $styles->add( 'colors-fresh', "/wp-admin/css/colors-fresh$suffix.css", array(), $colors_version ); 
     
    790790add_filter( 'print_scripts_array', 'wp_prototype_before_jquery' ); 
    791791 
    792792add_action( 'wp_default_styles', 'wp_default_styles' ); 
    793 add_filter( 'style_loader_src', 'wp_style_loader_src', 10, 2 ); 
     793//add_filter( 'style_loader_src', 'wp_style_loader_src', 10, 2 );