we also have a. setting where we do output some markup with display:none when it is not visible, setOutputMarkupIdXXXXX() (i forgot the exact name)
On 6/13/07, Alex Objelean <[EMAIL PROTECTED]> wrote: > > I found a workaround for this issue, so instead of overriding isVisible() of > the bulkContainer WebMarkupContainer, I add an AttributeModifier which makes > the container display:none.. > > private WebMarkupContainer getBulkContainer() { > if (bulkContainer == null) { > bulkContainer = new WebMarkupContainer("bulkContainer"); > bulkContainer.add(new SimpleAttributeModifier("class", "invisible") { > public boolean isEnabled() { > return getMode().isEdit(); > } > }); > //add to bulkContainer a form which contains a ListView. > } > return bulkContainer; > } > > I do not like this solution, because anyone having firebug can hack the > application + more markup than needed is generated... > > > > Johan Compagner wrote: > > > > isVisibleInHierarchy doesn't make to much sense because it has to be > > visible already because the parent is already rendering and passing > > its render to the childs. So the parent is already checked for > > visiblility.
what you seem to have is more another bug that something > > is not created or tried to rendered that is already removed by another > > request > > > > On 6/13/07, Alex Objelean <[EMAIL PROTECTED]> wrote: > >> > >> I have a question about the render method. Why, before rendering, instead > >> of > >> checking isVisibleInHierarchy(), isVisible() is called? > >> public final void render(final MarkupStream markupStream) > >> { > >> setMarkupStream(markupStream); > >> setFlag(FLAG_IS_RENDERED_ONCE, true); > >> > >> // Determine if component is visible using it's authorization > >> status > >> // and the isVisible property. > >> if (isRenderAllowed() && isVisible()) //why not > >> isVisibleInHierarchy() > >> ?? > >> { > >> //etc... > >> } > >> //more code. > >> } > >> > >> I am asking because I suspect a bug with the following StackTrace: > >> > >> Caused by: java.lang.NullPointerException > >> at wicket.markup.html.list.ListView.renderItem(ListView.java:676) > >> at wicket.markup.html.list.ListView.onRender(ListView.java:637) > >> > >> I happens when an AjaxTabbedPanel is updated via ajax. The tabbedPanel > >> contains a holder Panel with a ListView child component. The visibility > >> of > >> the holder Panel is decided dynamicaly by overriding isVisible method. > >> > >> Maybe later I will try to isolate this situation and to make it more > >> clear. > >> Still, I would like to know if you've encountered something like this. > >> > >> Thank you! > >> -- > >> View this message in context: > >> > http://www.nabble.com/-Question--render%28final-MarkupStream-markupStream%29-tf3914413.html#a11098575 > >> Sent from the Wicket - User mailing list archive at Nabble.com. > >> > >> > >> ------------------------------------------------------------------------- > >> This SF.net email is sponsored by DB2 Express > >> Download DB2 Express C - the FREE version of DB2 express and take > >> control of your XML. No limits. Just data. Click to get it now. > >> http://sourceforge.net/powerbar/db2/ > >> _______________________________________________ > >> Wicket-user mailing list > >> Wicket-user@lists.sourceforge.net > >> https://lists.sourceforge.net/lists/listinfo/wicket-user > >> > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by DB2 Express > > Download DB2 Express C - the FREE version of DB2 express and take > > control of your XML. No limits. Just data. Click to get it now. > > http://sourceforge.net/powerbar/db2/ > > _______________________________________________ > > Wicket-user mailing list > > Wicket-user@lists.sourceforge.net > > https://lists.sourceforge.net/lists/listinfo/wicket-user > > > > > > -- > View this message in context: > http://www.nabble.com/-Question--render%28final-MarkupStream-markupStream%29-tf3914413.html#a11099854 > Sent from the Wicket - User mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by DB2 Express > Download DB2 Express C - the FREE version of DB2 express and take > control of your XML. No limits. Just data. Click to get it now. > http://sourceforge.net/powerbar/db2/ > _______________________________________________ > Wicket-user mailing list > Wicket-user@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/wicket-user > ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user