开发者

remove selected style on a DIV

开发者 https://www.devze.com 2022-12-12 00:29 出处:网络
I am doing iPhone development and I s开发者_开发百科et a webview with a DIV. I added \'toucstart\' \'touchend\' \'touchmove\' events to this DIV.

I am doing iPhone development and I s开发者_开发百科et a webview with a DIV. I added 'toucstart' 'touchend' 'touchmove' events to this DIV.

But after I added these events, the DIV has a style (look at this video : http://www.bluefly.cn/mask1.swf ) when 'touchstart' (like 'mousedown'), any one knows how to remove this visual effect?


To disable tap highlighting, set the -webkit-tap-highlight-color custom CSS property to a colour with an alpha value of 0:

#myElement {
    -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

See Highlighting Elements in the Safari Web Content Guide for iPhone OS for more information.

0

精彩评论

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

关注公众号