Skip to content
Browse files

svn:eol-style wizz

  • Loading branch information...
1 parent 98df8a8 commit 7ca8af59aeda3913e0703c07b041f5690ffb3d6d @gsnedders gsnedders committed Jun 18, 2007
Showing with 31 additions and 31 deletions.
  1. +31 −31 demo/for_the_demo/sleight.js
View
62 demo/for_the_demo/sleight.js
@@ -1,31 +1,31 @@
-/**********************************************************
-Sleight
-(c) 2001, Aaron Boodman
-http://www.youngpup.net
-**********************************************************/
-
-if (navigator.platform == "Win32" && navigator.appName == "Microsoft Internet Explorer" && window.attachEvent)
-{
- document.writeln('<style type="text/css">img { visibility:hidden; } </style>');
- window.attachEvent("onload", fnLoadPngs);
-}
-
-function fnLoadPngs()
-{
- var rslt = navigator.appVersion.match(/MSIE (\d+\.\d+)/, '');
- var itsAllGood = (rslt != null && Number(rslt[1]) >= 5.5);
-
- for (var i = document.images.length - 1, img = null; (img = document.images[i]); i--)
- {
- if (itsAllGood && img.src.match(/\.png$/i) != null)
- {
- var src = img.src;
- var div = document.createElement("DIV");
- div.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + src + "', sizing='scale')"
- div.style.width = img.width + "px";
- div.style.height = img.height + "px";
- img.replaceNode(div);
- }
- img.style.visibility = "visible";
- }
-}
+/**********************************************************
+Sleight
+(c) 2001, Aaron Boodman
+http://www.youngpup.net
+**********************************************************/
+
+if (navigator.platform == "Win32" && navigator.appName == "Microsoft Internet Explorer" && window.attachEvent)
+{
+ document.writeln('<style type="text/css">img { visibility:hidden; } </style>');
+ window.attachEvent("onload", fnLoadPngs);
+}
+
+function fnLoadPngs()
+{
+ var rslt = navigator.appVersion.match(/MSIE (\d+\.\d+)/, '');
+ var itsAllGood = (rslt != null && Number(rslt[1]) >= 5.5);
+
+ for (var i = document.images.length - 1, img = null; (img = document.images[i]); i--)
+ {
+ if (itsAllGood && img.src.match(/\.png$/i) != null)
+ {
+ var src = img.src;
+ var div = document.createElement("DIV");
+ div.style.filter = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='" + src + "', sizing='scale')"
+ div.style.width = img.width + "px";
+ div.style.height = img.height + "px";
+ img.replaceNode(div);
+ }
+ img.style.visibility = "visible";
+ }
+}

0 comments on commit 7ca8af5

Please sign in to comment.
Something went wrong with that request. Please try again.