Path: csiph.com!usenet.pasdenom.info!gegeweb.org!eternal-september.org!feeder.eternal-september.org!mx04.eternal-september.org!.POSTED!not-for-mail From: Eric Sosman Newsgroups: comp.lang.java.programmer Subject: Re: jtextfield focus Date: Tue, 04 Sep 2012 09:54:40 -0400 Organization: A noiseless patient Spider Lines: 9 Message-ID: References: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Injection-Date: Tue, 4 Sep 2012 13:54:49 +0000 (UTC) Injection-Info: mx04.eternal-september.org; posting-host="ffb8f7085759b339c1002252b48331a4"; logging-data="15218"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/s96flOVQ0675nWoqS7+CB" User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:15.0) Gecko/20120824 Thunderbird/15.0 In-Reply-To: Cancel-Lock: sha1:q41/zKX267XfOxW/1BHeFZVZGiQ= Xref: csiph.com comp.lang.java.programmer:18533 On 9/4/2012 6:11 AM, baz83 wrote: > How do I know if a JTextField has the focus? Use isFocusOwner() or addFocusListener(). -- Eric Sosman esosman@ieee-dot-org.invalid "The speed at which the system fails is usually not important."