JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
vanilla ckeditor-3.4.2
[ckeditor.git] / _source / core / _bootstrap.js
index 9b9d081..f6ba4d6 100644 (file)
@@ -9,13 +9,19 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
 \r
 (function()\r
 {\r
+       // Disable HC detaction in WebKit. (#5429)\r
+       if ( CKEDITOR.env.webkit )\r
+       {\r
+               CKEDITOR.env.hc = false;\r
+               return;\r
+       }\r
+\r
        // Check is High Contrast is active by creating a temporary element with a\r
        // background image.\r
 \r
        var useSpacer = CKEDITOR.env.ie && CKEDITOR.env.version < 7,\r
                useBlank = CKEDITOR.env.ie && CKEDITOR.env.version == 7;\r
 \r
-\r
        var backgroundImageUrl = useSpacer ? ( CKEDITOR.basePath + 'images/spacer.gif' ) :\r
                                                         useBlank ? 'about:blank' : 'data:image/png;base64,';\r
 \r
@@ -36,6 +42,7 @@ For licensing, see LICENSE.html or http://ckeditor.com/license
        {\r
                CKEDITOR.env.hc = false;\r
        }\r
+\r
        if ( CKEDITOR.env.hc )\r
                CKEDITOR.env.cssClass += ' cke_hc';\r
 \r
@@ -59,9 +66,7 @@ CKEDITOR.plugins.load( CKEDITOR.config.corePlugins.split( ',' ), function()
                }\r
        });\r
 \r
-/*\r
-TODO: Enable the following and check if effective.\r
-\r
+// Needed for IE6 to not request image (HTTP 200 or 304) for every CSS background. (#6187)\r
 if ( CKEDITOR.env.ie )\r
 {\r
        // Remove IE mouse flickering on IE6 because of background images.\r
@@ -75,7 +80,14 @@ if ( CKEDITOR.env.ie )
                // line. For safety, let's just ignore errors.\r
        }\r
 }\r
-*/\r
+\r
+/**\r
+ * Indicates that CKEditor is running on a High Contrast environment.\r
+ * @name CKEDITOR.env.hc\r
+ * @example\r
+ * if ( CKEDITOR.env.hc )\r
+ *     alert( 'You're running on High Contrast mode. The editor interface will get adapted to provide you a better experience.' );\r
+ */\r
 \r
 /**\r
  * Fired when a CKEDITOR core object is fully loaded and ready for interaction.\r