Re: Focus
- From: Frances <fdr58@xxxxxxxxx>
- Date: Mon, 26 Sep 2005 17:15:45 -0400
Frances wrote:
I see two methods for setting focus:
-- requestFocus() Requests that this Component gets the input focus.
-- grabFocus()
Requests that this Component get the input focus, and that this Component's top-level ancestor become the focused Window.
(which one is it, then, 'this Component' or 'top-level ancestor'? -- which one gets focus? ('ancestor' meaning what exactly? what if if you have just one component (and thus no 'ancestor'...))
neither one of these two methods is working for me.. let's say I have a JTextArea called TA... neither TA.grabFocus() or TA.requestFocus() is working..
why no simple Focus() method? (focus this component... seems too simple, I know...) thank you very much... Frances
sorry, neglected to mention, this is not in reponse to user-event, but for when window opens, it's for an IM window, so top textArea should NEVER have focus and bottom textArea should ALWAYS have focus.. thanks again...
.
- References:
- Focus
- From: Frances
- Focus
- Prev by Date: Re: Uptain system icon/graphics: Black arrow pointing down
- Next by Date: Re: Focus
- Previous by thread: Focus
- Next by thread: Re: Focus
- Index(es):
Relevant Pages
|
|