Ok, here it is
private class QuestionEditForm extends Form {
private boolean questionformatter = true;
public QuestionEditForm(String id) {
super(id);
TextChunk question =
paragraphwebmodel.getEntity().getStatement();
setModel(new
CompoundPropertyModel(paragraphwebmodel));
VariableTextFieldPanel questionpanel = new
VariableTextFieldPanel(
"question", new PropertyModel(paragraphwebmodel,
"statement.value"));
final AdvancedFormatterPanel formatquestion = new
AdvancedFormatterPanel(
"formatquestion", new AdvancedFormatterWebModel(question
.getFormatter()));
add(new
DropDownChoice("clear",Arrays.asList(QuestionLayoutClearance.values()),new
MyChoiceRenderer()));
formatquestion.setVisible(false);
add(new Link("showquestionformat") {
@Override
public void onClick() {
formatquestion.setVisible(questionformatter);
if (questionformatter) {
questionformatter = false;
} else {
questionformatter = true;
}
}
});
On Tue, Jul 21, 2009 at 10:03 AM, Mathias Nilsson <
wicket.program...@gmail.com> wrote:
>
> Can you post some code so we can see whats going on?
> --
> View this message in context:
> http://www.nabble.com/setVisbile-on-form-makes-me-reset-fields-tp2458p24583413.html
> Sent from the Wicket - User mailing list archive at Nabble.com.
>
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>
--
Pieter Claassen
musmato.com