Добавление анимации для прогресс баров в АФСП

This commit is contained in:
TotMaxim
2026-04-05 16:36:43 +03:00
parent ec21282ba0
commit f407578a44
2 changed files with 64 additions and 15 deletions

View File

@@ -68,28 +68,28 @@ func _on_response_received(response: String, success: bool) -> void:
func _update_ui(json_data: Dictionary) -> void:
# Конвертер
for child in $bort.get_node('konverter/grid').get_children():
node_maper.map_value_to_item(json_data, child, 'value0')
node_maper.map_value_to_item(json_data, child, 'value1')
node_maper.map_value_to_item(json_data, child, 'value2')
node_maper.map_error_codes_to_item(json_data, child, 'state', 0)
node_maper.map_value_to_item_animated(json_data, child, 'value0')
node_maper.map_value_to_item_animated(json_data, child, 'value1')
node_maper.map_value_to_item_animated(json_data, child, 'value2')
node_maper.map_error_codes_to_item_animated(json_data, child, 'state', 0)
# Антенна 1
for child in $bort.get_node('antenna1/grid').get_children():
node_maper.map_value_to_item(json_data, child, 'value0')
node_maper.map_value_to_item(json_data, child, 'value1')
node_maper.map_error_codes_to_item(json_data, child, 'state', 0)
node_maper.map_value_to_item_animated(json_data, child, 'value0')
node_maper.map_value_to_item_animated(json_data, child, 'value1')
node_maper.map_error_codes_to_item_animated(json_data, child, 'state', 0)
# Антенна 2
for child in $bort.get_node('antenna2/grid').get_children():
node_maper.map_value_to_item(json_data, child, 'value0')
node_maper.map_value_to_item(json_data, child, 'value1')
node_maper.map_error_codes_to_item(json_data, child, 'state', 0)
node_maper.map_value_to_item_animated(json_data, child, 'value0')
node_maper.map_value_to_item_animated(json_data, child, 'value1')
node_maper.map_error_codes_to_item_animated(json_data, child, 'state', 0)
# Остальные элементы
for child in $bort.get_children():
node_maper.map_value_to_item(json_data, child, 'value0')
node_maper.map_value_to_item(json_data, child, 'value1')
node_maper.map_error_codes_to_item(json_data, child, 'state', 0)
node_maper.map_value_to_item_animated(json_data, child, 'value0')
node_maper.map_value_to_item_animated(json_data, child, 'value1')
node_maper.map_error_codes_to_item_animated(json_data, child, 'state', 0)
# Сброс всех UI элементов в 0 (при отсутствии данных)