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

1.3 - 1.4 requestFocus() incompatibility  RSS feed

 
Barry Andrews
Ranch Hand
Posts: 529
C++ Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
The focus model changed significantly between 1.3 and 1.4 Java versions. One problem I am currently having is that I can no longer call requestFocus() on a Component that is not a "focusable" one. In 1.3 even if a Component was not focusable, you could force the focus by calling requestFocus(). Now this method checks the Component for focusability by calling isFocusTraversable(). Does anyone know if there is a way to force the focus on a Component without this check? The problem is we have overridden the isFocusTraversable() method and it cannot be changed. (At least I cannot see a way to change it without breaking other behaviors.) The solution needs to be in 1.3, but the runtime is 1.4. I appreciate any thoughts anyone might have on this!


thanks,

Barry
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!