Рефактор
This commit is contained in:
@@ -122,7 +122,6 @@ func on_interfer_new(ecm, table_index):
|
||||
|
||||
func on_interfer_off(ecm, ecms, thrs, table_index):
|
||||
$table.remove_row(table_index[ecm.ispp])
|
||||
table_index.clear()
|
||||
rehash(table_index)
|
||||
ecms.erase(ecm.ispp)
|
||||
thrs.erase(ecm.ispp)
|
||||
@@ -137,6 +136,7 @@ func on_interfer_off(ecm, ecms, thrs, table_index):
|
||||
|
||||
## Перестраивает индекс таблицы. Вызывать при удалении строки
|
||||
func rehash(table_index: Dictionary):
|
||||
table_index.clear()
|
||||
var rows_count = $table.get_rows_count()
|
||||
for i_row in rows_count:
|
||||
var item = $table.get_node2(0, i_row)
|
||||
|
||||
Reference in New Issue
Block a user