Remove IE6 specific fixes.
Just don't use IE6.
This commit is contained in:
parent
f7d90464e0
commit
e98bfec4f2
@ -80,10 +80,6 @@
|
|||||||
transition: background-color .2s linear;
|
transition: background-color .2s linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ps-container.ie6 .ps-scrollbar-x {
|
|
||||||
font-size: 0; /* fixed scrollbar height in xp sp3 ie6 */
|
|
||||||
}
|
|
||||||
|
|
||||||
.ps-container .ps-scrollbar-x-rail:hover .ps-scrollbar-x,
|
.ps-container .ps-scrollbar-x-rail:hover .ps-scrollbar-x,
|
||||||
.ps-container .ps-scrollbar-x-rail.hover .ps-scrollbar-x {
|
.ps-container .ps-scrollbar-x-rail.hover .ps-scrollbar-x {
|
||||||
background-color: #999;
|
background-color: #999;
|
||||||
@ -103,23 +99,7 @@
|
|||||||
transition: background-color .2s linear;
|
transition: background-color .2s linear;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ps-container.ie6 .ps-scrollbar-y {
|
|
||||||
font-size: 0; /* fixed scrollbar height in xp sp3 ie6 */
|
|
||||||
}
|
|
||||||
|
|
||||||
.ps-container .ps-scrollbar-y-rail:hover .ps-scrollbar-y,
|
.ps-container .ps-scrollbar-y-rail:hover .ps-scrollbar-y,
|
||||||
.ps-container .ps-scrollbar-y-rail.hover .ps-scrollbar-y {
|
.ps-container .ps-scrollbar-y-rail.hover .ps-scrollbar-y {
|
||||||
background-color: #999;
|
background-color: #999;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ps-container.ie .ps-scrollbar-x,
|
|
||||||
.ps-container.ie .ps-scrollbar-y {
|
|
||||||
visibility: hidden;
|
|
||||||
}
|
|
||||||
|
|
||||||
.ps-container.ie:hover .ps-scrollbar-x,
|
|
||||||
.ps-container.ie:hover .ps-scrollbar-y,
|
|
||||||
.ps-container.ie.hover .ps-scrollbar-x,
|
|
||||||
.ps-container.ie.hover .ps-scrollbar-y {
|
|
||||||
visibility: visible;
|
|
||||||
}
|
|
||||||
|
@ -631,61 +631,9 @@
|
|||||||
eventClassName = null;
|
eventClassName = null;
|
||||||
}
|
}
|
||||||
|
|
||||||
function ieSupport(version) {
|
|
||||||
$this.addClass('ie').addClass('ie' + version);
|
|
||||||
|
|
||||||
function bindHoverHandlers() {
|
|
||||||
function mouseenter() {
|
|
||||||
$this.addClass('hover');
|
|
||||||
}
|
|
||||||
function mouseleave() {
|
|
||||||
$this.removeClass('hover');
|
|
||||||
}
|
|
||||||
$this.bind('mouseenter' + eventClassName, mouseenter).bind('mouseleave' + eventClassName, mouseleave);
|
|
||||||
$scrollbarXRail.bind('mouseenter' + eventClassName, mouseenter).bind('mouseleave' + eventClassName, mouseleave);
|
|
||||||
$scrollbarYRail.bind('mouseenter' + eventClassName, mouseenter).bind('mouseleave' + eventClassName, mouseleave);
|
|
||||||
$scrollbarX.bind('mouseenter' + eventClassName, mouseenter).bind('mouseleave' + eventClassName, mouseleave);
|
|
||||||
$scrollbarY.bind('mouseenter' + eventClassName, mouseenter).bind('mouseleave' + eventClassName, mouseleave);
|
|
||||||
}
|
|
||||||
|
|
||||||
function fixIe6ScrollbarPosition() {
|
|
||||||
updateCss = function () {
|
|
||||||
var scrollbarXStyles = { left: scrollbarXLeft + $this.scrollLeft(), width: scrollbarXWidth };
|
|
||||||
if (isScrollbarXUsingBottom) {
|
|
||||||
scrollbarXStyles.bottom = scrollbarXBottom;
|
|
||||||
} else {
|
|
||||||
scrollbarXStyles.top = scrollbarXTop;
|
|
||||||
}
|
|
||||||
$scrollbarX.css(scrollbarXStyles);
|
|
||||||
|
|
||||||
var scrollbarYStyles = { top: scrollbarYTop + $this.scrollTop(), height: scrollbarYHeight };
|
|
||||||
if (isScrollbarYUsingRight) {
|
|
||||||
scrollbarYStyles.right = scrollbarYRight;
|
|
||||||
} else {
|
|
||||||
scrollbarYStyles.left = scrollbarYLeft;
|
|
||||||
}
|
|
||||||
|
|
||||||
$scrollbarY.css(scrollbarYStyles);
|
|
||||||
$scrollbarX.hide().show();
|
|
||||||
$scrollbarY.hide().show();
|
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
if (version === 6) {
|
|
||||||
bindHoverHandlers();
|
|
||||||
fixIe6ScrollbarPosition();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var supportsTouch = (('ontouchstart' in window) || window.DocumentTouch && document instanceof window.DocumentTouch);
|
var supportsTouch = (('ontouchstart' in window) || window.DocumentTouch && document instanceof window.DocumentTouch);
|
||||||
|
|
||||||
function initialize() {
|
function initialize() {
|
||||||
var ieMatch = navigator.userAgent.toLowerCase().match(/(msie) ([\w.]+)/);
|
|
||||||
if (ieMatch && ieMatch[1] === 'msie') {
|
|
||||||
// must be executed at first, because 'ieSupport' may addClass to the container
|
|
||||||
ieSupport(int(ieMatch[2]));
|
|
||||||
}
|
|
||||||
|
|
||||||
updateGeometry();
|
updateGeometry();
|
||||||
bindScrollHandler();
|
bindScrollHandler();
|
||||||
bindMouseScrollXHandler();
|
bindMouseScrollXHandler();
|
||||||
|
Loading…
Reference in New Issue
Block a user