This code
   Frame parent = null;
...
   parent = (Frame) getParent();
 Compiles and runs on Linux. However, on OS/2, it gets a ClassCastException
   if in fact the parent is an applet.

I've programmed my way round it:
                        if (p instanceof Frame)
                        {
         parent = (Frame) getParent();
         System.out.println("p(" + parent + ")"  );
         if (parent instanceof Frame)
                          parent.setTitle( "some title text "  );
                        };

(I know it's untidy: I was pressed at the time).

I don't know which implementation is at fault: if there's someone from IBM
sees this, please pass it on.

I'll be away for up to a week: I don't plan to read all the old
contributions to this list on my return. if anyone needs more info, please
mail me direct and do NOT cc the list (else my mail filter will catch it).

-- 
Cheers
John Summerfield
http://os2.ami.com.au/os2/ for OS/2 support.
Configuration, networking, combined IBM ftpsites index.

Reply via email to