... | ... |
@@ -228,9 +228,10 @@ displayClass.MFD = { |
228 | 228 |
me.device.knobs.FmsOuter = me.device.knobs.NavigateMenu; |
229 | 229 |
me.device.buttons.ENT = func (a = 0) { |
230 | 230 |
if (a) return; |
231 |
+ var (id, selected) = split('-', me.device.windows.selected); |
|
232 |
+ var state = me.device.windows.state[id]; |
|
233 |
+ var (airport_id, _) = split(" ", obj_infos[selected + state.scroll.offset].text); |
|
231 | 234 |
me.device.windows.del(windowId); |
232 |
- var (_, selected) = split('-', me.device.windows.selected); |
|
233 |
- var (airport_id, _) = split(" ", obj_infos[selected].text); |
|
234 | 235 |
call(me.device.display.MFD._ShowAirportInfo, [airport_id], me); |
235 | 236 |
}; |
236 | 237 |
}, |
... | ... |
@@ -283,9 +284,10 @@ displayClass.MFD = { |
283 | 284 |
me.device.knobs.FmsOuter = me.device.knobs.NavigateMenu; |
284 | 285 |
me.device.buttons.ENT = func (a = 0) { |
285 | 286 |
if (a) return; |
287 |
+ var (id, selected) = split('-', me.device.windows.selected); |
|
288 |
+ var state = me.device.windows.state[id]; |
|
289 |
+ var (navaid_id, _) = split(" ", obj_infos[selected + state.scroll.offset].text); |
|
286 | 290 |
me.device.windows.del(windowId); |
287 |
- var (_, selected) = split('-', me.device.windows.selected); |
|
288 |
- var (navaid_id, _) = split(" ", obj_infos[selected].text); |
|
289 | 291 |
if (navaid_type == 'airport') |
290 | 292 |
call(me.device.display.MFD._ShowAirportInfo, [navaid_id], me); |
291 | 293 |
else |
... | ... |
@@ -117,8 +117,8 @@ var knobsClass = { |
117 | 117 |
object.text = val; |
118 | 118 |
} |
119 | 119 |
if (find('immediate', object.type) > -1) { |
120 |
- if (contains(object, 'callback')) { |
|
121 |
- call(object.callback, [id, selected], me);} |
|
120 |
+ if (contains(object, 'callback')) |
|
121 |
+ call(object.callback, [id, selected + state.scroll.offset], me); |
|
122 | 122 |
else |
123 | 123 |
me.device.buttons.ENT(); |
124 | 124 |
} |