2
如何獲取變量,網址和名稱的fileDoesNotExist回調:變量傳給回調函數
window.checkIfFileExists = function(path, url, name) {
return window.requestFileSystem(LocalFileSystem.PERSISTENT, 0, (function(fileSystem) {
return fileSystem.root.getFile(path, {
create: false
}, fileExists, fileDoesNotExist);
}), getFSFail);
};
fileDoesNotExist = (fileEntry, url, name) ->
downloadImage(url, name)
感謝,那很簡單! :-) – Harry 2013-03-22 14:32:07