Sequence Files Initialization Fixed

This commit is contained in:
Luis Fernando Molina committed 2019-09-23 14:54:07 +02:00
1 parent 2b20301528
commit dcbe60f5a5
2 files changed
+21 -3

No files matched your search

+9
View File
@@ -33,6 +33,8 @@ function newDashboard () {
function start () {
try {
setBrowserEvents()
systemEventHandler = newSystemEventHandler()
systemEventHandler.initialize(startCanvas)
@@ -107,4 +109,11 @@ function newDashboard () {
if (ERROR_LOG === true) { logger.write('[ERROR] browserResized -> err = ' + err.stack) }
}
}
function setBrowserEvents () {
window.onbeforeunload = onBrowserClosed
function onBrowserClosed () {
window.alert('My Window is closing')
}
}
}
+12 -3
View File
@@ -257,10 +257,19 @@ function newProductStorage (pName) {
return
}
}
let event = {
totalValue: pCaller.getExpectedFiles(),
currentValue: pCaller.getFilesLoaded()
let event
if (pCaller !== undefined) {
event = {
totalValue: pCaller.getExpectedFiles(),
currentValue: pCaller.getFilesLoaded()
}
} else { // When there are no data the reference to the caller wont arrive here.
event = {
totalValue: 1,
currentValue: 1
}
}
thisObject.eventHandler.raiseEvent('File Sequence Loaded', event)
if (event.currentValue === event.totalValue) {