HI,
I created a little method that should change the color of the image, but
can't make it happen.
In the Label component I load the image like this:
* Label lbImagenInventario = new Label ();*
* FontImage.setMaterialIcon (lbImagenInventario,
FontImage.MATERIAL_LOCAL_SHIPPING);*
And the method is as follows:
* private void changesInventColor (Double quantity, Label lbIcon, Label
lbCantidad) {*
* if (quantity <0) {*
* lbIcono.setIconUIID ("LabelRojo");*
* lbCantidad.setText (round (amount, 2));*
* lbCantidad.setUIID ("LabelRojo");*
* } else if (amount> 0) {*
* lbIcono.setIconUIID ("LabelVerde");*
* lbCantidad.setText (round (amount, 2));*
* lbCantidad.setUIID ("LabelVerde");*
* } else {*
* lbIcono.setIconUIID ("LabelGris");*
* lbCantidad.setText (round (amount, 2));*
* lbCantidad.setUIID ("LabelGris");*
* }*
* }*
--
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].
To view this discussion on the web visit
https://groups.google.com/d/msgid/codenameone-discussions/d9e52a77-a860-462d-8a68-4e0a99d903a8o%40googlegroups.com.