Prevent scrolling of oversized child in parent stream: hidden (webkit)

I have problems with Webkit browsers. The problem arises when I focus the cursor on the <input> element and start moving the mouse without releasing the button.

Here is the screencast - http://screencast.com/t/P1BnT7ZAdc

Here is the html / css daemon - http://napokrovke.mysundays.net/webkit_bug.html

How can I prevent this behavior?

+7
source share
1 answer

This is not a mistake, because you set the shell to 300 pixels and applied the overflow property hidden to it, which allows you to scroll if the contents inside are more than 300 pixels that you defined, Im in firefox on OSX, and I can also scroll it.

the only way this can be enforced is perhaps to apply this to the html markup text box

 onmousedown="event.preventDefault ? event.preventDefault() : event.returnValue = false; this.focus()" 

this should disconnect the user from dragging when it is selected inside the field, but then it also disables the click inside the field, so using focus, you need to focus this field manually. but if that is what you really want?

+1
source

All Articles