Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Preloaded tabs are not handled correctly #32

Closed
kav2k opened this issue Mar 7, 2016 · 1 comment
Closed

Preloaded tabs are not handled correctly #32

kav2k opened this issue Mar 7, 2016 · 1 comment

Comments

@kav2k
Copy link
Contributor

kav2k commented Mar 7, 2016

Some time ago, Chrome introduced a new mechanism of tab preloading - usually used for instant search.

Such tabs are loaded/rendered off-screen, and then the current tab is swapped for the new one.

This results in a race condition: if the page loading is very fast, the message to set the icon may arrive before the tab is visible - and that makes the indicator not show up, even after the tab is swapped in. A reload fixes it.

The proper way to correct this is to have a listener to chrome.tabs.onReplaced event and run the content script again for the swapped-in tab.

kav2k added a commit to kav2k/chrome-spdy-indicator that referenced this issue Mar 7, 2016
Note: since onMessage was dropped, the script is
simply injected again (it is safe).

Fixes rauchg#32
kav2k added a commit to kav2k/chrome-spdy-indicator that referenced this issue Mar 7, 2016
kav2k added a commit to kav2k/chrome-spdy-indicator that referenced this issue Mar 7, 2016
@kav2k
Copy link
Contributor Author

kav2k commented Mar 7, 2016

Sorry for the reference spam.

kav2k added a commit to kav2k/chrome-spdy-indicator that referenced this issue Mar 7, 2016
@rauchg rauchg closed this as completed in 8d87b7b Mar 11, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant