replace panels with fade effect

2007-07-28 Thread Leszek Gawron
I'd like to create an ajax heavy application (no pages, all panels). 
When replacing panels during ajax event I would like the old panel to 
fade out and new one to fade in (or any kind of morph effect).


I've been trying to make use of wicket-scriptaculous module but without 
success.


please advise.
lg
--
Leszek Gawron

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: replace panels with fade effect

2007-07-28 Thread Eelco Hillenius
On 7/28/07, Leszek Gawron [EMAIL PROTECTED] wrote:
 I'd like to create an ajax heavy application (no pages, all panels).
 When replacing panels during ajax event I would like the old panel to
 fade out and new one to fade in (or any kind of morph effect).

 I've been trying to make use of wicket-scriptaculous module but without
 success.

You could just use scriptaculous by itself.

Add the appropriate header contributions and then something like

target.appendJavascript(new Effect.Highlight($(' +
thePanel.getMarkupId() + ')););

Eelco

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: replace panels with fade effect

2007-07-28 Thread Igor Vaynberg
here is what i do... i use the animator.js lib

ajaxlink.onclick(target) { SuccessFlash flash=new SuccessFlash();
c1.add(flash);
c2.add(flash); target.addcomponent(c1); target.addcomponent(c2); }

see code below

-igor



public class AbstractAnimation extends AnimatorResources {
private ListComponent components;

@Override
public void bind(Component component) {
super.bind(component);
if (components == null) {
components = new ArrayListComponent(1);
}
components.add(component);
}

protected ListComponent getComponents() {
if (components == null) {
return Collections.emptyList();
} else {
return Collections.unmodifiableList(components);
}
}

@Override
public boolean isTemporary() {
return true;
}

}

public class SuccessFlash extends AbstractAnimation {

@Override
public void renderHead(IHeaderResponse response) {
super.renderHead(response);
for (Component component : getComponents()) {
response.renderOnLoadJavascript(Animator.Javascript.flashSuccess
(component));
}
}
}


On 7/28/07, Leszek Gawron [EMAIL PROTECTED] wrote:

 I'd like to create an ajax heavy application (no pages, all panels).
 When replacing panels during ajax event I would like the old panel to
 fade out and new one to fade in (or any kind of morph effect).

 I've been trying to make use of wicket-scriptaculous module but without
 success.

 please advise.
 lg
 --
 Leszek Gawron

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]