Is there an API to control downloads in Firefox add-on SDK?

送分小仙女□ 提交于 2019-12-13 01:34:06

问题


In Firefox, is there an API equivalent to Google Chrome's chrome.downloads API?

I need to control downloads with functions such as pause, resume, and cancel. In addition, I want to be able to remove the downloaded file.

If there is no API in Firefox add-on SDK, is it possible to do the same things in another way?


回答1:


The API's are (links to documentation on MDN):

  • Downloads.jsm
  • Download
  • DownloadTarget
  • PlacesUtils.There is good info at paa's answer to the question: API to modify Firefox downloads list


来源:https://stackoverflow.com/questions/29003125/is-there-an-api-to-control-downloads-in-firefox-add-on-sdk

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