| 430 | } |
| 431 | |
| 432 | void MacroEdit::PopulateMacroElseActions(Macro &m, uint32_t afterIdx) |
| 433 | { |
| 434 | auto &actions = m.ElseActions(); |
| 435 | ui->elseActionsList->SetHelpMsgVisible(actions.size() == 0); |
| 436 | |
| 437 | if (ui->elseActionsList->PopulateWidgetsFromCache(&m)) { |
| 438 | return; |
| 439 | } |
| 440 | |
| 441 | // The layout system has not completed geometry propagation yet, so we |
| 442 | // can skip those checks for now |
| 443 | ui->elseActionsList->SetVisibilityCheckEnable(false); |
| 444 | |
| 445 | for (; afterIdx < actions.size(); afterIdx++) { |
| 446 | auto newEntry = new MacroActionEdit(this, &actions[afterIdx]); |
| 447 | ui->elseActionsList->Add(newEntry); |
| 448 | } |
| 449 | |
| 450 | // Give the layout system time before enabling the visibility checks and |
| 451 | // fully constructing the visible macro segments |
| 452 | QTimer::singleShot(0, this, [this]() { |
| 453 | ui->elseActionsList->SetVisibilityCheckEnable(true); |
| 454 | }); |
| 455 | } |
| 456 | |
| 457 | void MacroEdit::PopulateMacroConditions(Macro &m, uint32_t afterIdx) |
| 458 | { |
nothing calls this directly
no test coverage detected