Port Chick to Resourceloader. Bug 26649
authorDerk-Jan Hartman <hartman@users.mediawiki.org>
Sat, 22 Jan 2011 21:29:39 +0000 (21:29 +0000)
committerDerk-Jan Hartman <hartman@users.mediawiki.org>
Sat, 22 Jan 2011 21:29:39 +0000 (21:29 +0000)
resources/Resources.php
resources/jquery/jquery.placeholder.js
skins/Chick.php

index 5921280..3d8c144 100644 (file)
@@ -24,6 +24,9 @@ return array(
        'skins.simple' => array(
                'styles' => array( 'skins/simple/main.css' => array( 'media' => 'screen' ) ),
        ),
+       'skins.chick' => array(
+               'styles' => array( 'skins/chick/main.css' => array( 'media' => 'screen,handheld' ) ),
+       ),
 
        /* jQuery */
 
index 8daa462..024441d 100644 (file)
@@ -38,7 +38,7 @@ $.fn.placeholder = function() {
                        } )
 
                        // Hide on focus
-                       .focus( function() {
+                       .bind( 'onfocus ondrop ondragdrop', function() {
                                if ($input.hasClass('placeholder')) {
                                        this.value = '';
                                        $input.removeClass( 'placeholder' );
@@ -58,4 +58,4 @@ $.fn.placeholder = function() {
                });
 
        });
-};
\ No newline at end of file
+};
index c8eb815..df78b4b 100644 (file)
@@ -23,10 +23,12 @@ class SkinChick extends SkinTemplate {
 
        function setupSkinUserCss( OutputPage $out ){
                parent::setupSkinUserCss( $out );
-               // Append to the default screen common & print styles...
-               $out->addStyle( 'chick/main.css', 'screen,handheld' );
-               $out->addStyle( 'chick/IE50Fixes.css', 'screen,handheld', 'lt IE 5.5000' );
-               $out->addStyle( 'chick/IE55Fixes.css', 'screen,handheld', 'IE 5.5000' );
-               $out->addStyle( 'chick/IE60Fixes.css', 'screen,handheld', 'IE 6' );
+
+               $out->addModuleStyles( 'skins.chick' );
+
+               // TODO: Migrate all of these
+               //$out->addStyle( 'chick/IE50Fixes.css', 'screen,handheld', 'lt IE 5.5000' );
+               //$out->addStyle( 'chick/IE55Fixes.css', 'screen,handheld', 'IE 5.5000' );
+               //$out->addStyle( 'chick/IE60Fixes.css', 'screen,handheld', 'IE 6' );
        }
 }