How does Chrome generate thumb views of URLs?

前提是你 提交于 2019-12-23 00:46:31

问题


How does Chrome browser capture a thumbnail image of most visited URLs and show me over a blank page under Most visited??

  • I am interested in knowing how I would implement it using for my website or an extension.. to take take screenshot.

  • Lalith


回答1:


If you want to write an extension that captures a screenshot of a current site then there is chrome.tabs.captureVisibleTab() method.




回答2:


I can only tell you how would I implement it. Once you would go to a site, I will add 1 to a counter if how many times you've entered it. If it's in the top 10, I would also take a screen shot of the site (chrome has a window in the class "Chrome_RenderWidgetHostHWND" which is the window that only contains the site, not the buttons and menus around it). I can only guess it's not too far from what the guys in Google did.




回答3:


I think that it takes a screenshot from the last time you visited the page and saves it in the "Top Sites" SQLite database file that can be found in your profile folder.



来源:https://stackoverflow.com/questions/6700606/how-does-chrome-generate-thumb-views-of-urls

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!