I want to save an unlimited number of files to the user's hard drive without forcing the user to click on the dialog box.
The only documentation I saw when using unlimited storage is here: https://developers.google.com/chrome/whitepapers/storage , which says that it is available only for Chrome applications.
All the examples that I saw in the Chrome API fileSystemshow that to create a new file and write to it, the user needs to get the recording object from the function chrome.fileSystem.chooseEntry, which means that the user needs to go through the dialog box.
The regular API fileSystemlooks like it can save the file in a user extension isolation environment without forcing the user to go through the dialog box, but I wonder if it has permission "unlimitedStorage"that is granted only to the Program? This does not shock me, if only it has permission only on the Chrome API.
If I use the regular API fileSystem, I need to request the file system using window.webkitRequestFileSystem(I'm a little surprised that it window.requestFileSystemdoesn’t work for me in Chrome), but the method accepts type( "persistent"or "temporary") and size(the bytes that the application will require for storage).
, API Chrome. API fileSystem , , API , , .
https://developers.google.com/chrome/apps/docs/developers_guide#manifest :
"permissions" HTML5, . "unlimitedStorage" "notifications", HTML5 . , ; , URL- "apps" .
, "unlimitedStorage" , window.webkitRequestFileSystem(window.PERSISTENT, anySize, successCallback), , , , Chrome .
1: - , ?
, API "unlimitedStorage", API API Chrome, "unlimitedStorage".
2: API ? , API .
API fileSystem , , , - . , .