Check if width parameter is present.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8594 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
c23e497c42
commit
087186ef34
|
@ -209,7 +209,9 @@ function showModal(id, width) {
|
|||
$('modalbg').show();
|
||||
|
||||
var pageWidth = document.viewport.getWidth();
|
||||
el.setStyle({'width': width});
|
||||
if (width) {
|
||||
el.setStyle({'width': width});
|
||||
}
|
||||
el.setStyle({'left': (((pageWidth - el.getWidth())/2 *100) / pageWidth) + '%'});
|
||||
el.addClassName('modal');
|
||||
el.show();
|
||||
|
|
Loading…
Reference in New Issue