Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsWhite Papers
Discussion GroupsFirst AidDatabasesJavaBeansGUIJava 3DVirtual MachineCORBASecurityToolsGeneral
Java DirectoryOpen Source ProjectsSample Book ChaptersUser GroupsWeb Resources
Related Topics
Databases.NETMore Topics ...

Java Forum / GUI / January 2004

Tip: Looking for answers? Try searching our database.

Applet steals focus...

Thread view: 
Andrew Thompson - 06 Jan 2004 19:34 GMT
Some time ago I noticed an irritating quirk in
applets, they tend to 'steal the focus' of a web
page and prevent scrolling using the keyboard.

At the time I was dealing with applets that had
focusable components, and resolved that when
I had time I'd sort out what I was doing wrong.

Now my 'test case' Applet, with only a single
Label, and just 4 lines of actual code, is doing
the same thing.  The URL is..
http://www.physci.org/test/focus/

There is a link to the entire 4 lines of code
on the web page itself.

So far I have tested this on IE 6 & Mozilla
1.3 on XP, both sit stubbornly at the top of
the page.  Interestingly, NN 4.8 (a thoroughly
archaic browser) had no problems with it.

So, my questions are.
Does this behaviour occur in _your_ browser?
(If so, make, model, OS ..please)

Is there something I forgot?  Is there anything
I can do to prevent this iritating behaviour
from happening?

TIA

--
Andrew Thompson
* http://www.PhySci.org/ PhySci software suite
* http://www.1point1C.org/ 1.1C - Superluminal!
* http://www.AThompson.info/andrew/ personal site
Andrew Thompson - 06 Jan 2004 19:42 GMT
| Some time ago I noticed an irritating quirk in
| applets, they tend to 'steal the focus' of a web
| page and prevent scrolling using the keyboard.

Whoops!  Forgot to mention that usually
the page allows scrolling before the Applet
is fully loaded and started (it's <1Kb).

To see the effect, you need to wait till the
'Scroll Me..' label appears.
Andrew Thompson - 09 Jan 2004 21:16 GMT
Since the GUI experts have no response, I'm
casting this wider..

| Some time ago I noticed an irritating quirk in
| applets, they tend to 'steal the focus' of a web
[quoted text clipped - 8 lines]
| the same thing.  The URL is..
| http://www.physci.org/test/focus/

Note that the effect I describe only happens
after the label appears, the page will scroll OK
prior to that

| There is a link to the entire 4 lines of code
| on the web page itself.
[quoted text clipped - 13 lines]
|
| TIA

--
Andrew Thompson
* http://www.PhySci.org/ PhySci software suite
* http://www.1point1C.org/ 1.1C - Superluminal!
* http://www.AThompson.info/andrew/ personal site
Andrew Thompson - 12 Jan 2004 12:42 GMT
What? Nobody??  Hello..  yoo-hoo!

I at least want to hear if the behaviour occurs
on other browsers/platforms before I put
a 'fault report' (whatever) into Sun..

Oh, ComeON...

| Since the GUI experts have no response, I'm
| casting this wider..
[quoted text clipped - 39 lines]
| * http://www.1point1C.org/ 1.1C - Superluminal!
| * http://www.AThompson.info/andrew/ personal site
Andrew Harker - 12 Jan 2004 14:43 GMT
Andrew Thompson wrote (even top posted :-) :
> What? Nobody??  Hello..  yoo-hoo!
>
[quoted text clipped - 3 lines]
>
> Oh, ComeON...

> | | http://www.physci.org/test/focus/

> | | So far I have tested this on IE 6 & Mozilla
> | | 1.3 on XP, both sit stubbornly at the top of
[quoted text clipped - 4 lines]
> | | Does this behaviour occur in _your_ browser?
> | | (If so, make, model, OS ..please)

Just tried with opera 7.23 on WinXP and I could PgUP/Down
after the applet label was displayed, also Netscape Communicator
4.79. Did not workwith Netscape 7.1 (WinXP) or Mozilla 1.5
(Win98). Don't have a *nix box to hand right now.

(BTW there is only one WinXP and Win98 box so there is
a working and non-working on same box)

There appears to be quite a few posts on focus and applets on
the forum.java.sun.com site and also developer.java.sun.com
in the bugs database.

cheers
Signature

Andrew

The trouble with having an open mind, of course, is that people
will insist on coming along and trying to put things in it.
        -- (Terry Pratchett, Diggers)

Andrew Thompson - 12 Jan 2004 20:32 GMT
<snip good stuff>
Thanks for the info Andrew, added to the list..

| There appears to be quite a few posts on focus and applets on
| the forum.java.sun.com site and also developer.java.sun.com
| in the bugs database.

I had a trawl through them, but the first
hundred or so I saw were focus problems
of a much more mundane nature.

Unfortunately I was unable to think of a
good way to sort the dross, so I gave up.

[ And the top-posting?  I knew that if I
got irritating enough, somebody would
answer me, if only to shut me up.
..That's my story, and I'm sticking to it!  ;-) ]

--
Andrew Thompson
* http://www.PhySci.org/ PhySci software suite
* http://www.1point1C.org/ 1.1C - Superluminal!
* http://www.AThompson.info/andrew/ personal site
Jim Sculley - 12 Jan 2004 17:58 GMT
> What? Nobody??  Hello..  yoo-hoo!
>
> I at least want to hear if the behaviour occurs
> on other browsers/platforms before I put
> a 'fault report' (whatever) into Sun..

Confirmed on Windows XP with Mozilla 1.4 and 1.6b.

See bugs:

 4673513 (closed as 'not a bug')
 4676801 (closed as duplicate of above bug)
 4896496 (closed, will not be fixed) - closely matches your description

The bug was introduced when a fix was implemented for the opposite
problem.  Applets that *wanted* focus weren't getting it (on IE).

Jim S.

P.S.  Please don't put line numbers in the HTML version of your source
code.  It makes cut and paste impossible, which hinders the 'compilable'
aspect of a SSCCE.

Signature

Remove my extraneous mandibular appendages to reply via e-mail

ak - 12 Jan 2004 22:29 GMT
> See bugs:
>
>   4673513 (closed as 'not a bug')
>   4676801 (closed as duplicate of above bug)
>   4896496 (closed, will not be fixed) - closely matches your description

Typical SUN!
How often I read this sh.t - "not a bug",  "duplicate", "will not be fixed"
:-((

____________

http://reader.imagero.com the best java image reader.
Andrew Thompson - 13 Jan 2004 00:42 GMT
..
| The bug was introduced when a fix was implemented for the opposite
| problem.  Applets that *wanted* focus weren't getting it (on IE).

Thanks Jim.  _This_ bug'll finally stop bugging
y'all about it.  It is a real pity though, as now I
am reluctant to put _any_ applets in my
(non-IT) sites.

[ As far as I am concerned, such a problem
ruins a page for anyone that typically only
uses a keyboard.  I want my pages to be
_accessible_ ]

| P.S.  Please don't put line numbers in the HTML version of your source
| code.  It makes cut and paste impossible, which hinders the 'compilable'
| aspect of a SSCCE.

Yes, true.  I will offer a link to the
'raw source' from that same page
that offers the formatted source.

--
Andrew Thompson
* http://www.PhySci.org/ PhySci software suite
* http://www.1point1C.org/ 1.1C - Superluminal!
* http://www.AThompson.info/andrew/ personal site
Andrew Thompson - 12 Jan 2004 18:58 GMT
Update..  A kindly Mac user has given me
the following run-down..

> Works fine (i.e. scrolls via keyboard) in IE 5.2
> under Mac OS 9, IE 5.2 under Mac OS X, Netscape 7.0
> under Mac OS X, and Safari 1.0 under Mac OS X.

Crap!  Now, why does it completely fail to
surprise me that it's Windows...

Could I get some Linux users to confirm it
is not a problem on Linux, just to further
pin it down?

| | Since the GUI experts have no response, I'm
| | casting this wider..
[quoted text clipped - 31 lines]
| | | I can do to prevent this iritating behaviour
| | | from happening?
Jim Sculley - 12 Jan 2004 20:03 GMT
> Update..  A kindly Mac user has given me
> the following run-down..
[quoted text clipped - 9 lines]
> is not a problem on Linux, just to further
> pin it down?

Linux with Konqueror 3.1.4 - broken
Linux with Mozilla Firebird 0.7 - OK
Linux with Mozilla 1.4 - OK

Jim S.

Signature

Remove my extraneous mandibular appendages to reply via e-mail

Andrew Thompson - 26 Jan 2004 02:51 GMT
| | Some time ago I noticed an irritating quirk in
| | applets, they tend to 'steal the focus' of a web
[quoted text clipped - 15 lines]
| | There is a link to the entire 4 lines of code
| | on the web page itself.

I _think_ I have a fix...
You are not gonna believe the source of it..   ;-)

http://www.physci.org/test/focus/
The index.jsp page should be scrollable, it
has three buttons.  There is a link to the original
page at scroll,jsp (..well ok, I've added styles,
changed the name, yada yada ..it still does not
scroll)

--
Andrew Thompson
* http://www.PhySci.org/ PhySci software suite
* http://www.1point1C.org/ 1.1C - Superluminal!
* http://www.AThompson.info/andrew/ personal site


Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.