javascript - Make scroll-bar appear on hover of scroll-bar-track -


i'm using custom scroll-bar styles via css implement custom scroll-bars in webkit. if other browsers have implemented prefixed or unprefixed versions/version please let me know.

but, on question. there way can make scroll-bar appear on hover of scroll-bar-track?

kind of in mac os x lion , mountain lion ?

here css custom scroll-bars"

::-webkit-scrollbar {     width: 12px; }  /* track */ ::-webkit-scrollbar-track {     -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.3);      -webkit-border-radius: 10px;     border-radius: 10px; }  /* handle */ ::-webkit-scrollbar-thumb {     -webkit-border-radius: 10px;     border-radius: 10px;     background: rgba(255,0,0,0.8);      -webkit-box-shadow: inset 0 0 6px rgba(0,0,0,0.5);  } 

here jquery solution, since mentioned need show when hover on it. check fiddle

var bodywidth = $('body').width(); var scrollwidth = 10; $('body').mousemove(function(e){     var x = e.pagex - this.offsetleft;      if(x>bodywidth-scrollwidth)         $('body').addclass("auto");     else         $('body').removeclass("auto"); });  body {     margin:0;     overflow:hidden; } .auto {     overflow:auto; } 

Comments

Popular posts from this blog

ios - iPhone/iPad different view orientations in different views , and apple approval process -

java Extracting Zip file -

C# WinForm - loading screen -