my first guess in that case would be:

        JPopupMenu.setDefaultLightWeightPopupEnabled(false)

light weight popups don't mix well with Canavs3D.

-- Peter

> -----Original Message-----
> From: Ashish Aggarwal [mailto:[EMAIL PROTECTED]]
> Sent: Donnerstag, 18. Juli 2002 23:28
> To: [EMAIL PROTECTED]
> Subject: [JAVA3D] Bug or - JPopupMenu!
>
>
> Hello,
>
> I am facing a peculiar problem. I have three cones and
> three spheres on the canvas3D. what I am doing is that
> when you pick a specific shape, it will popup a menu
> as well as it will print a message in the console
> giving out some information about the shape.
>
> The peculiar thing is that, for three shapes it is
> giving a popupmenu as well as printing a message in
> the console when you picked them but when you picked
> other three shapes it is only giving message in the
> console that some specific shape has been picked up
> but no popupmenu is coming up.
>
> Why it is behaving unpredictably? Please reply.I am
> attaching the relevant code snippet:
>
>
> if (closest != null )
>            {
>              Primitive myShape=null;
>        // get the first node in the path
>         int nodeCount = closest.nodeCount();
>             System.out.println("count is "+ nodeCount);
>             Node node = closest.getNode(2);
>         JPopupMenu pop =  new JPopupMenu();
>             if (node instanceof Cone)
>              {
>               System.out.println("IT'S A CONE");
>               String s = (String)node.getUserData();
>           pop.add(s);
>           pop.show(canvas,xpos,ypos);
>             }
>
>         if (node instanceof Sphere)
>              {
>          System.out.println("IT'S A SPHERE");
>          String s = (String)node.getUserData();
>                  pop.add(s);
>          pop.show(canvas,xpos,ypos);
>              }
>
>            }// end of if(closest!=null)
>            }catch (ArrayIndexOutOfBoundsException a){}
>
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Autos - Get free new car price quotes
> http://autos.yahoo.com
>
> ==============================================================
> =============
> To unsubscribe, send email to [EMAIL PROTECTED] and
> include in the body
> of the message "signoff JAVA3D-INTEREST".  For general help,
> send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA3D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to