Restore main window on error message

This commit is contained in:
Scott E. Graves
2019-06-04 15:20:34 -05:00
parent 18aa23c5d8
commit 7aa17de4be
5 changed files with 21 additions and 1 deletions

View File

@@ -544,6 +544,8 @@ class App extends IPCContainer {
Error: error,
ErrorAction: action,
ErrorCritical: critical,
}, () => {
this.sendRequest(Constants.IPC_Show_Window);
});
};

View File

@@ -111,6 +111,8 @@ exports.IPC_Mount_Drive_Reply = 'mount_drive_reply';
exports.IPC_Save_State = 'save_state';
exports.IPC_Show_Window = 'show_window';
exports.IPC_Set_Config_Values = 'set_config_values';
exports.IPC_Set_Config_Values_Reply = 'set_config_values_reply';

View File

@@ -46,7 +46,12 @@ class MountItems extends IPCContainer {
this.setState({
DisplayRetry: Object.keys(retryItems).length > 0,
RetryItems: retryItems,
}, stateCallback);
}, () => {
if (this.state.DisplayRetry) {
this.sendRequest(Constants.IPC_Show_Window);
}
stateCallback();
});
}
};
@@ -224,6 +229,7 @@ class MountItems extends IPCContainer {
DisplayRetry: true,
RetryItems: retryItems,
}, () => {
this.sendRequest(Constants.IPC_Show_Window);
this.retryIntervals[storageType] = setInterval(() => {
let retryItems = {
...this.state.RetryItems,