mirror of
https://github.com/db48x/emularity.git
synced 2026-09-15 02:52:57 +00:00
show a percentage in the splash screen if we can
This commit is contained in:
@@ -624,7 +624,10 @@ var Module = null;
|
||||
|
||||
var formatSize = function (event) {
|
||||
if (event.lengthComputable)
|
||||
return "("+ formatBytes(event.loaded) +" of "+ formatBytes(event.total) +")";
|
||||
return "("+ (event.total ? (event.loaded / event.total * 100).toFixed(0)
|
||||
: "100") +
|
||||
"%; "+ formatBytes(event.loaded) +
|
||||
" of "+ formatBytes(event.total) +")";
|
||||
return "("+ formatBytes(event.loaded) +")";
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user