mirror of
https://github.com/iNavFlight/inav-configurator.git
synced 2025-07-23 16:25:19 +03:00
Display a modal during reboot
This commit is contained in:
parent
3c19c15782
commit
5c4b2806ad
3 changed files with 27 additions and 0 deletions
|
@ -22,8 +22,19 @@ $(document).ready(function () {
|
|||
|
||||
GUI.handleReconnect = function ($tabElement) {
|
||||
|
||||
let modal;
|
||||
|
||||
if (BOARD.hasVcp(CONFIG.boardIdentifier)) { // VCP-based flight controls may crash old drivers, we catch and reconnect
|
||||
|
||||
modal = new jBox('Modal', {
|
||||
width: 400,
|
||||
height: 100,
|
||||
animation: false,
|
||||
closeOnClick: false,
|
||||
closeOnEsc: false,
|
||||
content: $('#modal-reconnect')
|
||||
}).open();
|
||||
|
||||
/*
|
||||
Disconnect
|
||||
*/
|
||||
|
@ -35,6 +46,7 @@ $(document).ready(function () {
|
|||
Connect again
|
||||
*/
|
||||
setTimeout(function start_connection() {
|
||||
modal.close();
|
||||
$('a.connect').click();
|
||||
|
||||
/*
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue