Reto Grob wrote:
>>Since the com.nttdocomo.ui.Component paint() method is private to the
>>com.nttdocomo.ui package I can't override it by creating my "Gauge
>>extends Component" in another package, such as com.neurogrid.ui
>>
>>
>
>How do you know that it is Component.paint()? Did you just try it out
>and it worked on the emulator or some phones?
>
It worked on the emulator - I mean when I compile something with
paint(Graphics) in eclipse, if am in the same package as
com.nttdocomo.ui then it compiles fine, if I am in a different package
then I get a warning about how this method is not accessible outside the
package and so can't be overridden.
>Because I cannot see it in the official Docomo API descriptions, it
>means it is an unofficial internal implementation. Private
>implementations may vary over various phones, so you cannot be sure that
>it will work on all phones (you may be lucky tough).
>
>
Well it won't work on any phones at the moment as far as I can see cos I
can't have a com.nttdocomo.ui.Gauge class cos I'm forbidden to create
something in that package.
I hadn't thought about that aspect varying over phones, but you might be
right ...
>>There are certain other key things I can only access locally to that
>>package, that makes it look to me like docomo has explcitly set it up so
>>that you can't create new ui components ....
>>
>>
>
>What can you do when using the com.nttdocomo package?
>
I can create my own Gauge class that extends com.nttdocomo.ui.Component
abstract class and gets added to a panel and can be used just like any
other UI component.
CHEERS> SAM
Received on Wed Sep 17 13:58:11 2003