hi shai, how are you? i hope fine.
I write you to ask you how to make an effect opening a container with
results.
i have a textfield and when you tipe a string who returns results i want to
open a container that will grow from height = 0 to the needed to fit the
results
my code is:
public void showPopupResults(Container results) {
if (this.getComponentForm() != null) {
Container lay = this.getComponentForm().getLayeredPane();
wrapper = new Container();
lay.setLayout(new BorderLayout());
lay.addComponent(BorderLayout.CENTER, wrapper);
TableLayout layout = new TableLayout(1, 1);
wrapper.setLayout(layout);
TableLayout.Constraint constr1 = layout.createConstraint();
constr1.setWidthPercentage(100);
constr1.setHeightPercentage(0);
constr1.setVerticalAlign(Component.BOTTOM);
wrapper.add(constr1, results);
results.getAllStyles().setMarginTop(100);
Display.getInstance().callSerially(new Runnable() {
@Override
public void run() {
}
});
constr1.setHeightPercentage(80);
lay.animateLayout(2000);
}
}
If you are experiencing an issue please mention the full platform your
issue applies to:
IDE: NetBeans/Eclipse/IDEA
Desktop OS
Simulator
Device
--
You received this message because you are subscribed to the Google Groups
"CodenameOne Discussions" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
Visit this group at https://groups.google.com/group/codenameone-discussions.
To view this discussion on the web visit
https://groups.google.com/d/msgid/codenameone-discussions/a41b7701-c10d-42ae-a007-961b3cd66813%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.