How to set overflow:hidden for dojo's dialog box
I'm using a dojo dijit dialog box to popup data for the lightbox effect.
The problem is that dojo dynamically changes the style attributes of "containerNode", so that if the box is bigger than the browser window a scroll bar appears. It sets "o开发者_Python百科verflow:auto" dynamically.
I know this makes sense to do, but I want to override this and force the user to open up the browsers as the modal/lightbox looks really bad otherwise.
How can I change this behaviour? Sample code would be helpful!
Thanks
You can subscribe to 'show' method of your dialog and modify any styles you need.
dojo.connect(yourDialogWidget, "show", yourDialogWidget, function(){
dojo.style(this.containerNode, "overflow", "hidden");
});
精彩评论