Opened 11 years ago

Closed 10 years ago

#9204 closed defect (wontfix)

dijit.Dialog._size uses marginBox instead of contentBox and cause problems with scroller

Reported by: coldwind Owned by:
Priority: high Milestone: tbd
Component: Dijit Version: 1.3.0
Keywords: dijit.Dialog Cc:
Blocked By: Blocking:

Description

I'll try to exmpalin what happens.

My dialog has 5px border. I need to setup dialog's width to 600px, so I call:

dojo.style(dialog.domNode, {width: '600px'});

Now if I set some content and show dialog it will appear normal (cause dialog.containerNode width is set to 'auto'). Problems appear if my content have height more then viewports height.

marginBox(dialog.domNode) returns width 610px (600 + border) and sets this to dialog.containerNode, instead of 600px.

I suggest to use contentBox in dijit.Dialog._size function. I guess it's the right one solution.

Change History (2)

comment:1 Changed 11 years ago by bill

Dialog._size() sets Dialog.containerNode size to 75% of the viewport size. I'm not sure what you are referring to. You'll need to attach a test case.

Note though also that you aren't meant to set the size of Dialog.domNode... it would be better to set the size of the containerNode.

comment:2 Changed 10 years ago by bill

Resolution: wontfix
Status: newclosed

OK, I'm to close this because we just don't support setting a style on the Dialog's DOMNode. BTW this is documented.

Note: See TracTickets for help on using tickets.