Skip to content
This repository has been archived by the owner on Nov 3, 2021. It is now read-only.

Commit

Permalink
Merge pull request #6689 from etiennesegonzac/bug-813900-blackscreen-fix
Browse files Browse the repository at this point in the history
Bug 813900 - Fix black "mozilla" screen freeze.
  • Loading branch information
etiennesegonzac committed Nov 28, 2012
2 parents 24bd9ec + fb62e91 commit 8dc07da
Showing 1 changed file with 15 additions and 7 deletions.
22 changes: 15 additions & 7 deletions apps/system/js/window_manager.js
Expand Up @@ -773,16 +773,20 @@ var WindowManager = (function() {
}
}

function skipFTU() {
// Eventually ask for SIM code, but only when we do not show FTU,
// which already asks for it!
handleInitlogo();
SimLock.showIfLocked();
setDisplayedApp(homescreen);
}

// Check if the FTU was executed or not, if not, get a
// reference to the app and launch it.
function retrieveFTU() {
window.asyncStorage.getItem('ftu.enabled', function getItem(launchFTU) {
if (launchFTU === false) {
// Eventually ask for SIM code, but only when we do not show FTU,
// which already asks for it!
handleInitlogo();
SimLock.showIfLocked();
setDisplayedApp(homescreen);
skipFTU();
return;
}
document.getElementById('screen').classList.add('ftuStarting');
Expand All @@ -792,18 +796,22 @@ var WindowManager = (function() {
ftuManifestURL = this.result['ftu.manifestURL'];
if (!ftuManifestURL) {
dump('FTU manifest cannot be found skipping.\n');
setDisplayedApp(homescreen);
skipFTU();
return;
}
ftu = Applications.getByManifestURL(ftuManifestURL);
if (!ftu) {
dump('Opps, bogus FTU manifest.\n');
setDisplayedApp(homescreen);
skipFTU();
return;
}
ftuURL = ftu.origin + ftu.manifest.entry_points['ftu'].launch_path;
ftu.launch('ftu');
};
req.onerror = function() {
dump('Couldn\'t get the ftu manifestURL.\n');
skipFTU();
};
});
}

Expand Down

0 comments on commit 8dc07da

Please sign in to comment.