Im developing a mobile application in J2ME with the configuration CLDC1.1,MIDP2.0 and using LWUIT.

Now i want to create a Custom Component (user defined component) which is added in the Form,etc (in LWUIT)

Inside the custom component there is 2 ComboBoxes and 1 TextField (com.sun.lwuit.TextField and com.sun.lwuit.ComboBox).

I does not know how to do.Because in LWUIT the custom component is derived from Component class.But their we need to paint.We cannot able to add the high level UI components such as Label,TextField,ComboBox.

So please help me .To create a custom component which having one or more high level UI components (UI components of LWUT like com.sun.lwuit.TextField,com.sun.lwuit.ComboBox,etc).

All are welcome to give their valuable ideas.

有帮助吗?

解决方案

My idea to create your `CustomComponent`in LWUIT is the following.

You can try to create a class wich extends from `Container`, and inside it add the 2 `ComboBox` and the `TextField`. So you can use this "CustomComponent" as a high level UI Component.

其他提示

You cannot derive MIDP high level UI classes in LWUIT. The whole idea of LWUIT and similar frameworks is abandonment of the broken MIDP API's.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top