Results 1 to 4 of 4
  1. #1
    James Manley is offline Member
    Join Date
    Jan 2011
    Posts
    6
    Rep Power
    0

    Red face Get JRootPane with JavaBeans

    Hello,

    I am using JavaBeans that creates a web page. I nead to get the JRootPane object of the main window to handle the mouse cursor activity. I found a getRootPane() method but I don't now how to access this method.

    Could you help me,

    Thanks a lot,

    James

  2. #2
    James Manley is offline Member
    Join Date
    Jan 2011
    Posts
    6
    Rep Power
    0

    Default

    I found this :

    FacesContext facesContext = FacesContext.getCurrentInstance();
    UIViewRoot contextRoot = facesContext.getViewRoot();

  3. #3
    camickr is offline Senior Member
    Join Date
    Jul 2009
    Posts
    1,236
    Rep Power
    7

    Default

    Java Code:
    SwingUtilities.windowForComponent(...);
    Once you get the window a given component belongs to you can cast the window to a JFrame (if thats what you are using) and then get the root pane.

  4. #4
    James Manley is offline Member
    Join Date
    Jan 2011
    Posts
    6
    Rep Power
    0

Similar Threads

  1. Difference between Javabeans and EJB
    By winkodes in forum Enterprise JavaBeans (EJB)
    Replies: 2
    Last Post: 03-18-2009, 02:21 PM
  2. javaBeans with JSP
    By jainpankaj15m in forum Advanced Java
    Replies: 1
    Last Post: 07-25-2007, 01:15 PM
  3. Exception in JavaBeans
    By bbq in forum Enterprise JavaBeans (EJB)
    Replies: 2
    Last Post: 07-04-2007, 08:33 AM
  4. javabeans?
    By sin in forum Enterprise JavaBeans (EJB)
    Replies: 1
    Last Post: 05-15-2007, 06:42 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •