Item
Item has been declared abstract. I wish to create an object which inherets from Item, allowing it to be appended onto a Form.
The API doesn't specify which methods needs to be declared, which allows my object to be drawn on a Form.
Could someone please direct me.
Thankz
John.
[316 byte] By [
johnlw] at [2007-9-26 15:02:25]

Hi, I have tried extending Item to create my own GUI widgets - but with no luck (could not call super.paint() etc, as these are protected methods) Then I read in a Java article, that Item is not meant to be extended and that if I wanted to create my own GUI components, I needed to write them from scratch and use the Canvas class. Which also meant that I could not mix MIPD GUI Items and my custom components.
I have no idea if this is actually true, maybe Allen can shed some light on this.
Don
[d1camero],
> Hi, I have tried extending Item to create my own GUI
> widgets - but with no luck (could not call
> super.paint() etc, as these are protected methods)
> Then I read in a Java article, that Item is not meant
> to be extended and that if I wanted to create my own
> GUI components, I needed to write them from scratch
> and use the Canvas class. Which also meant that I
> could not mix MIPD GUI Items and my custom
> components.
>
> I have no idea if this is actually true, maybe Allen
> can shed some light on this.
I managed to discuss this with some of the MIDP experts within the organisation and it looks like you are correct in that one cannot extend Item with MIDP 1.0 There is however some work within the expert group to allow custom widgets through Item for MIDP 2.0.
> Don
HTH.
Allen Lai
Developer Technical Support
SUN Microsystems
http://www.sun.com/developers/support/