If I'm correct, the modal window uses js to determine the resizing in px. If you want it to resize in % of screen, you'd probably have to override modal.js to determine the appropriate % to set the window width. However, if you want the window to be some percentage wide, you don't really want it resizeable, you want it to be some percentage wide. If you want the window to start at 50% width and then be resizeable after the fact, you could just detect the client screen width and set the modal window width to half of that to start.
Regards, Matt. On Fri, Jan 9, 2009 at 10:57 AM, Emanuele Gesuato <[email protected]> wrote: > getWidthUnit() is not considered if the ModalWindow is resizable. > > > Nino Martinez wrote: > >> if getWidthUnit() arent final then override? >> >> Emanuele Gesuato wrote: >> >>> Hi there, >>> >>> >>> In ModalWindow as defined in wicket-extension the width has a fixed >>> length expressed in pixel (600px). I would like to have the width in "%" but >>> the widthUnit is available only when the the component is not resizable. >>> >>> >>> In fact in ModalWindow.getWindowOpenJavascript() there is the following: >>> >>> .. >>> if (isResizable() == false) >>> { >>> buffer.append("settings.widthUnit=\"" + getWidthUnit() + "\";\n"); >>> buffer.append("settings.heightUnit=\"" + getHeightUnit() + "\";\n"); >>> } >>> ... >>> >>> >>> How could i setting the width as "%" and mantain the resizability of the >>> component ? >>> >>> And why this behaviour is present ? >>> >>> >>> Thanks, >>> Emanuele >>> >>> >>> --------------------------------------------------------------------- >>> To unsubscribe, e-mail: [email protected] >>> For additional commands, e-mail: [email protected] >>> >>> >> >> --------------------------------------------------------------------- >> To unsubscribe, e-mail: [email protected] >> For additional commands, e-mail: [email protected] >> >> > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > -- Matthew Rollins Hanlon http://squareoftwo.org _____________________ Hanlon's Razor: "Never attribute to malice that which can be adequately explained by stupidity." http://wikipedia.org/wiki/Hanlon's_razor
