4

I've never seen another website do this and it's interesting behavior. To recreate it, open a new tab in Safari and go to mail.google.com. While it's loading switch to another tab and wait. Once Gmail has finished it's ajax loading it fires what I presume to be a javascript event to force it to become the active tab.

Does anyone know what the javascript event is? Is it possible it's not javascript?

Josh Lee
  • 171,072
  • 38
  • 269
  • 275
MSaforrian
  • 599
  • 5
  • 7
  • 1
    Doesn't happen for me in Chrome Linux (26.0.1410.63) – marekful Jun 13 '13 at 13:57
  • Just Safari(read Webkit), as Chrome is built on different core – t3hn00b Jun 13 '13 at 13:57
  • *Does* happen for me in Safari under OSX (but not Chrome under the same). – user229044 Jun 13 '13 at 13:58
  • I Believe it is a browser functionality and varies between different browsers. for instance I know firefox has "Switch to tab" feature that automatically switches you over to the a new tab – Prakash Chennupati Jun 13 '13 at 13:59
  • @t3hn00b Chrome has been WebKit for its entire history (Chrome 28 will be built upon 'Blink', but Blink is just a fork of WebKit- 27 is currently the latest version). – Kitsune Jun 13 '13 at 14:10
  • @PrakashChennupati Is the switch to tab feature available via javascript? – MSaforrian Jul 03 '13 at 15:26
  • @MatthewForr Yes, Please have a look at my answer to a similar question: http://stackoverflow.com/questions/15818892/chrome-javascript-window-open-in-new-tab/15818960#15818960 – Prakash Chennupati Jul 03 '13 at 15:29

1 Answers1

2

Everything that you need about safari javascript extentions is there:

http://developer.apple.com/library/safari/#documentation/Tools/Conceptual/SafariExtensionGuide/WorkingwithWindowsandTabs/WorkingwithWindowsandTabs.html

I checked, they talk about how to set a tab active.

Maresh
  • 4,644
  • 25
  • 30