Let's try to tone down the alerts when 'resume' is set to AUTO (1)

This commit is contained in:
Jeff Parsons 2017-06-27 09:54:59 -07:00 • committed by Jeff Parsons
commit 7aa689c745
9 changed files with 68 additions and 70 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -519,12 +519,11 @@ class Computer extends Component {
* may have happened the last time around.
*/
this.stateFailSafe = new State(this, PCX86.APPVERSION, Computer.STATE_FAILSAFE);
if (this.stateFailSafe.load()) {
if (this.powerReport(stateComputer)) {
if (resume != Computer.RESUME_AUTO && this.powerReport(stateComputer)) {
/*
* We already know resume is something other than RESUME_NONE, so we'll go ahead and bump it
* all the way to RESUME_PROMPT, so that the user will be prompted, and if the user declines to
* restore, the state will be removed.
* Prompt the user; if they decline to restore, the state will be removed.
*/
resume = Computer.RESUME_PROMPT;
}

View file

@ -196,7 +196,7 @@ class ROM extends Component {
doneLoad(sURL, sROMData, nErrorCode)
{
if (nErrorCode) {
this.notice("Unable to load system ROM (error " + nErrorCode + ": " + sURL + ")");
this.notice("Unable to load system ROM (error " + nErrorCode + ": " + sURL + ")", nErrorCode < 0);
return;
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View file

@ -43155,7 +43155,7 @@ class ROM extends Component {
doneLoad(sURL, sROMData, nErrorCode)
{
if (nErrorCode) {
this.notice("Unable to load system ROM (error " + nErrorCode + ": " + sURL + ")");
this.notice("Unable to load system ROM (error " + nErrorCode + ": " + sURL + ")", nErrorCode < 0);
return;
}
@ -74369,12 +74369,11 @@ class Computer extends Component {
* may have happened the last time around.
*/
this.stateFailSafe = new State(this, PCX86.APPVERSION, Computer.STATE_FAILSAFE);
if (this.stateFailSafe.load()) {
if (this.powerReport(stateComputer)) {
if (resume != Computer.RESUME_AUTO && this.powerReport(stateComputer)) {
/*
* We already know resume is something other than RESUME_NONE, so we'll go ahead and bump it
* all the way to RESUME_PROMPT, so that the user will be prompted, and if the user declines to
* restore, the state will be removed.
* Prompt the user; if they decline to restore, the state will be removed.
*/
resume = Computer.RESUME_PROMPT;
}

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long