Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

static method getFocusedComponent() of JTextComponent  RSS feed

 
Jim Martin
Ranch Hand
Posts: 80
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all
How do I use the static method getFocusedComponent() of JTextComponent. I am using JBuilder 6.0.
I am using the class DefaultFocusManager() and I am trying to used the static method getFocusedComponent() of JTextComponent to get the component the currently has the focus.
What is another way to get the component that has the focus currently?
Thank you very much
 
Howard Zhao
Greenhorn
Posts: 27
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am not sure whether this is what you are looking for:
KeyboardFocusManager.getCurrentKeyboardFocusManager().getFocusOwner()
Howard
 
Consider Paul's rocket mass heater.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!