mirror of
https://github.com/libretro/RetroArch
synced 2025-04-18 14:42:30 +00:00
change to busy state while uploading
This commit is contained in:
parent
a5a26fea61
commit
041e9c327a
@ -170,6 +170,9 @@ function startRetroArch()
|
|||||||
|
|
||||||
function selectFiles(files)
|
function selectFiles(files)
|
||||||
{
|
{
|
||||||
|
$('#btnAdd').addClass('disabled');
|
||||||
|
$('#icnAdd').removeClass('fa-plus');
|
||||||
|
$('#icnAdd').addClass('fa-spinner spinning');
|
||||||
count = files.length;
|
count = files.length;
|
||||||
|
|
||||||
for (var i = 0; i < files.length; i++)
|
for (var i = 0; i < files.length; i++)
|
||||||
@ -179,18 +182,15 @@ function selectFiles(files)
|
|||||||
filereader.readAsArrayBuffer(files[i]);
|
filereader.readAsArrayBuffer(files[i]);
|
||||||
filereader.onload = function(){uploadData(this.result, this.file_name)};
|
filereader.onload = function(){uploadData(this.result, this.file_name)};
|
||||||
}
|
}
|
||||||
|
/*$('#btnAdd').removeClass('disabled');
|
||||||
|
$('#icnAdd').removeClass('fa-spinner spinning');
|
||||||
|
$('#icnAdd').addClass('fa-plus');*/
|
||||||
}
|
}
|
||||||
|
|
||||||
function uploadData(data,name)
|
function uploadData(data,name)
|
||||||
{
|
{
|
||||||
$('#btnAdd').addClass('disabled');
|
|
||||||
var dataView = new Uint8Array(data);
|
var dataView = new Uint8Array(data);
|
||||||
FS.createDataFile('/content/', name, dataView, true, false);
|
FS.createDataFile('/content/', name, dataView, true, false);
|
||||||
|
|
||||||
//var data = FS.readFile(name,{ encoding: 'binary' });
|
|
||||||
//FS.writeFile('/content/' + name, data ,{ encoding: 'binary' });
|
|
||||||
//FS.unlink(name);
|
|
||||||
$('#btnAdd').removeClass('disabled');
|
|
||||||
}
|
}
|
||||||
|
|
||||||
var Module =
|
var Module =
|
||||||
|
Loading…
x
Reference in New Issue
Block a user