The Omni Group
These forums are now read-only. Please visit our new forums to participate in discussion. A new account will be required to post in the new forums. For more info on the switch, see this post. Thank you!

Go Back   The Omni Group Forums > OmniWeb > OmniWeb Bug Reports
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
Jarring pseudo-focus shift after opening tab in background Thread Tools Search this Thread Display Modes
While reading certain sites, especially news sites, I will frequently just click links with the middle button (the scroll wheel in my case) on my mouse to open them in background tabs. With the SP releases, however, I periodically get a strange behavior where everything goes as planned until the background tab finishes loading, at which point its content is shown in the window. When this happens, both the original tab and the new tab are shown highlighted in the tab drawer, and OW acts confused - it's as though it doesn't know what tab has focus. Clicking the original tab again selects it fully and unselects the new tab.

I've run into this on both my desktop and my laptop. Has anyone else seen this?
 
I typically command+click links to do this, and haven't had any issues like that.
 
I have seen exactly the same behaviour with the last couple of Sneaky Peeks, and I think it has to do with sites using JavaScript to set the keyboard focus for form fields after they've loaded (though I must say I haven't looked into it so I have no evidence for that claim :)).

I particularly notice this with the UK National Rail site at http://www.nationalrail.co.uk/. If I do a timetable search, then command-click one of the result links so it opens in a background tab, that tab grabs the focus when it finishes loading.

As the original poster described, the tab drawer exhibits some unusual behaviour in this situation, with the originally-selected tab retaining the outline of its 'highlight colour' around the tab thumbnail, while the newly-opened tab has its thumbnail indicated with the highlight colour as though it has been clicked. (Er, that description sounds a bit confusing, but short of a screenshot it's a bit tricky to describe...)
 
All right, so after posting that I had to investigate further. :)

It seems my theory about JavaScript and focus was almost correct. The National Rail pages have code like this in them:

Code:
<script type="text/javascript">
window.onload=function(){this.focus(); } 
</script>
...which I think is the trigger for this unusual behaviour.

Here also is a screenshot showing the tab highlighting when this occurs:

Click image for larger version

Name:	OddTabHighlighting.png
Views:	270
Size:	33.3 KB
ID:	69

David
 
Quote:
Originally Posted by David Shepherdson
Code:
<script type="text/javascript">
window.onload=function(){this.focus(); } 
</script>
"Our site is so great that we know you absolutely want to give it your full, undivided attention when it finishes loading, even if you opted to load it in the background while working on other things!"

Stupid web developers. (As a web developer myself, I can rightly call certain of us stupid if I want.)

What I'd do to these folks if I got my hands on them.... USABILITY, people, USABILITY!
 
Quote:
Originally Posted by Bob Williams
"Our site is so great that we know you absolutely want to give it your full, undivided attention when it finishes loading, even if you opted to load it in the background while working on other things!"

Stupid web developers. (As a web developer myself, I can rightly call certain of us stupid if I want.)

What I'd do to these folks if I got my hands on them.... USABILITY, people, USABILITY!
I concur .
 
Those of you having this multi-select problem. In the security preferences do you have "Allow JavaScript to reorder windows" checked?
 
Quote:
Originally Posted by troyb
Those of you having this multi-select problem. In the security preferences do you have "Allow JavaScript to reorder windows" checked?
I've never noticed that preference... so the answer is yes.

I've just tried turning it off then seeing what happens with my National Rail test case, and the problem no longer occurs. Good thinking, troyb!

So, there's the solution to our irritating user experience -- thanks Omni for building it in before we realised we needed it! :)

The weird tab selection is still a bug, obviously, but a much tamer one than we originally thought.
 
Quote:
Originally Posted by troyb
Those of you having this multi-select problem. In the security preferences do you have "Allow JavaScript to reorder windows" checked?
WOW, this pref actually takes care of an unrelated issue I was having. sweeet! only thing is, it doesn't seem to work as a site pref.
 
Quote:
Originally Posted by troyb
Those of you having this multi-select problem. In the security preferences do you have "Allow JavaScript to reorder windows" checked?
Yep, sure do; I'll turn it off and see if it kills the problem. I assume it will. As another poster said, there's obviously still a bug, but in this case, I'm content with the kill-the-feature approach to bug avoidance :-). I'm sure you'll still want to fix the issue, though, for those poor folks out there who visit sites that require that ability in scripts.

You know, I thought I had that pref turned off, but I must've turned it back on at some point for some reason and forgot about it....

Anyway, thanks!
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Opening a page from Personal Bookmarks doesn't move focus to the page Ward OmniWeb Bug Reports 0 2010-11-28 11:31 PM
Color shift laurabel OmniGraffle General 6 2007-11-29 08:12 AM
New window opening in background? Wallin OmniWeb General 2 2007-07-04 01:16 PM
Using Shift+Tab does not move focus from Search Field to Address Field jashugan OmniWeb Bug Reports 3 2006-05-30 11:54 AM
Shift of new windows myckmack OmniWeb Feature Requests 0 2006-05-05 07:59 AM


All times are GMT -8. The time now is 02:26 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2020, vBulletin Solutions, Inc.