Showing 2 changed files with 8 additions and 9 deletions
+4 -5
Nasal/display.nas
... ...
@@ -23,7 +23,6 @@ var displayClass = {
23 23
             .show();
24 24
 
25 25
         m.timers = {};
26
-        m.timers2 = {}; # tho old timer implementation use already a named timer hash
27 26
         # Softkeys revert to the previous level after 45 seconds of inactivity.
28 27
         m.softkeys_inactivity_delay = 45;
29 28
 
... ...
@@ -510,13 +509,13 @@ var displayClass = {
510 509
 
511 510
     softkeys_inactivity : func {
512 511
 # automagically back to previous level after some delay {{{
513
-        me.timers2.softkeys_inactivity = maketimer (
512
+        me.timers.softkeys_inactivity = maketimer (
514 513
             me.softkeys_inactivity_delay,
515 514
             func {
516 515
                 pop(me.device.softkeys.path);
517 516
                 me.updateSoftKeys();
518 517
             }, me);
519
-        me.timers2.softkeys_inactivity.singleShot = 1;
518
+        me.timers.softkeys_inactivity.singleShot = 1;
520 519
     },
521 520
 #}}}
522 521
 
... ...
@@ -617,9 +616,9 @@ var displayClass = {
617 616
         }
618 617
 
619 618
         if (size(me.device.softkeys.path))
620
-            me.timers2.softkeys_inactivity.restart(me.softkeys_inactivity_delay);
619
+            me.timers.softkeys_inactivity.restart(me.softkeys_inactivity_delay);
621 620
         else
622
-            me.timers2.softkeys_inactivity.stop();
621
+            me.timers.softkeys_inactivity.stop();
623 622
     },
624 623
 #}}}
625 624
 
+4 -4
Nasal/softkeys.nas
... ...
@@ -287,7 +287,7 @@ var softkeysClass = {
287 287
                     '0' : func (n = 0) {
288 288
                         if (radios.getValue('xpdr-tuning-fms-method'))
289 289
                             return;
290
-                        me.device.display.timers2.softkeys_inactivity.stop();
290
+                        me.device.display.timers.softkeys_inactivity.stop();
291 291
                         me.bindings.PFD.XPDR.CODE.inactivity.restart(me.device.display.softkeys_inactivity_delay);
292 292
                         # disable FMS knob entering method
293 293
                         me.device.knobs.FmsInner = void;
... ...
@@ -346,7 +346,7 @@ var softkeysClass = {
346 346
                     },
347 347
                     IDENT: func {
348 348
                         me.bindings.PFD.XPDR.CODE.inactivity.restart(me.device.display.softkeys_inactivity_delay);
349
-                        me.device.display.timers2.softkeys_inactivity.restart(me.device.display.softkeys_inactivity_delay);
349
+                        me.device.display.timers.softkeys_inactivity.restart(me.device.display.softkeys_inactivity_delay);
350 350
                         call(me.bindings.PFD.IDENT, [], me);
351 351
                     },
352 352
                     BKSP: func {
... ...
@@ -385,11 +385,11 @@ var softkeysClass = {
385 385
                         me.device.display.updateSoftKeys();
386 386
                         me.device.knobs.FmsInner = void;
387 387
                         me.device.knobs.FmsOuter = void;
388
-                        me.device.display.timers2.softkeys_inactivity.restart(me.device.display.softkeys_inactivity_delay);
388
+                        me.device.display.timers.softkeys_inactivity.restart(me.device.display.softkeys_inactivity_delay);
389 389
                     },
390 390
                     hook : func {
391 391
                         # this level has its own timer as we may need to revert changes, and got different timers
392
-                        me.device.display.timers2.softkeys_inactivity.stop();
392
+                        me.device.display.timers.softkeys_inactivity.stop();
393 393
                         me.bindings.PFD.XPDR.CODE.inactivity = maketimer(
394 394
                             me.device.display.softkeys_inactivity_delay,
395 395
                             func call(me.bindings.PFD.XPDR.CODE.BACK, [], me));