accessing history in a firefox addon

南笙酒味 提交于 2019-12-03 09:16:24

You'll need to access the xpcom service nsIBrowserHistory, here's some example code that works with the SDK:

https://builder.addons.mozilla.org/package/157396/latest/

The places api is a bit verbose, there are extensive examples available on MDN:

https://developer.mozilla.org/en-US/docs/Querying_Places

There is also a module developed by Mozilla community members available here that provides some abstractions:

https://github.com/autonome/Jetpack-Modules/blob/master/places.js

I'm not sure if theabove module has been tested against recent versions of Firefox and the SDK.

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