开发者

mac magic mouse horizontal swipe/scroll issue in firefox 6

开发者 https://www.devze.com 2023-04-08 23:54 出处:网络
I have added overflow-x: hidden to my css html tag in order to hide the slides that are floated to the left, each sl开发者_运维技巧ide fills the whole window. These slides are then accessed using a na

I have added overflow-x: hidden to my css html tag in order to hide the slides that are floated to the left, each sl开发者_运维技巧ide fills the whole window. These slides are then accessed using a navigation, this works fine in all browsers hiding the horizontal scroll as it should.

I have come across a problem now though where even though the horizontal scrollbar is hidden the hidden pages can be scrolled to using the magic pad swipe/scroll.

Is there anyway this can be disabled using a specific webkit css property or by adding javascript?

I have seen posts where people have instructed users to disable the swipe/scroll in through terminal etc but that's not what Im after.

I have found this problem only to happen in Firefox 6 for mac so far.

Thanks Kyle


If the overflow property isn't working, try using JQuery.scrollTop() or JQuery.scrollLeft()

$(document).ready(function(){
    $("#element").scroll(function(){
        $(this).scrollTop(0);
        $(this).scrollLeft(0);
    });
});

That's the only thing that comes to mind, to be honest. I assume of course that the swipe/scroll triggers a scroll event, otherwise that function would fail, in which case I know of no working solution.

0

精彩评论

暂无评论...
验证码 换一张
取 消