Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Any way to customize Chrome or Firefox Speed Dial thumbs?

For a fun project, I've been implementing a small thumbnail page on a website that provides a specially catered view for the small site previews on New Tab pages. The end goal being to present the relevant information to the user before they ever need to visit the site. (Example: a weather site frequently visited, having a thumbnail page showing today's weather, so that the user can see the relevant information at a glance).


Opera this is by detecting

X-Purpose: preview

Likewise, Safari uses the same header, but requires additional JS to maintain a consistent thumbnail.

//On primary page
if (window.navigator.loadPurpose === 'preview') { /* go to thumbnail page */ }

//On thumbnail page
if (window.navigator.loadPurpose !== 'preview') { /* return to main page */ }

I'm curious if it's possible to duplicate this effect in Chrome or Firefox (the new speed dial available in the Aurora builds)?

Note: The X-Purpose: preview header in Chrome about 2 releases ago was a bug that was intended to be X-Purpose: instant and does not serve this purpose.

like image 594
anthonyryan1 Avatar asked Apr 29 '12 05:04

anthonyryan1


1 Answers

As far as I can tell, both Chrome and Firefox Speed-dial thumbnails are only populated when you visit a page - i.e. they're taken from the normal browsing context, with normal headers, rather than being independently queries in their own right.

You can test this a number of ways - I haven't spent long testing it, and you may have different version(s) of Firefox/Chrome than I do so you may see different results.

  1. In Chrome - pin a tab or two in Speed-dial and then empty your browser history. The thumbnails should disappear until you re-visit the pinned page.
  2. In Firefox - the above works, but you can also try out thumbnail generation directly using the moz-page-thumb:// URL protocol:

    moz-page-thumb://thumbnail?url=http%3A%2F%2Fstackoverflow.com%2Fq%2F10369905%2F210865"

(please do test in whatever versions you're running as I'm curious about this question too - my research sofar is disappointing, but possibly in future ...)

Other references:

  • Original bugzilla entry for adding thumbnails to FF Speed-dial
  • Another bugzilla entry on fixing thumbnail protocol security issues
  • Related Super User question
like image 159
lucideer Avatar answered Oct 28 '22 04:10

lucideer