1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-17 05:15:25 +03:00

remove active_tab_ref, name some of the anonymous functions, cleanup

This commit is contained in:
cTn 2014-10-01 12:58:09 +02:00
parent b9b5568a3b
commit 5cd042ae9d
15 changed files with 34 additions and 26 deletions

View file

@ -7,7 +7,6 @@ var GUI_control = function () {
this.connecting_to = false;
this.connected_to = false;
this.active_tab;
this.active_tab_ref = false;
this.tab_switch_in_progress = false;
this.operating_system;
this.optional_usb_permissions = false; // controlled by usb permissions code
@ -198,7 +197,7 @@ GUI_control.prototype.tab_switch_cleanup = function (callback) {
MSP.callbacks_cleanup(); // we don't care about any old data that might or might not arrive
GUI.interval_kill_all(); // all intervals (mostly data pulling) needs to be removed on tab switch
this.active_tab_ref.cleanup(callback);
TABS[this.active_tab].cleanup(callback);
};
// initialize object into GUI variable