| 487 | } |
| 488 | |
| 489 | void ExecutionWindow::showIcicleTree() |
| 490 | { |
| 491 | |
| 492 | const auto &tree = execution_.tree(); |
| 493 | /// Can only show icicle tree when the tree is fully built |
| 494 | /// TODO: change this to allow partially built trees |
| 495 | //if (!tree.isDone()) |
| 496 | // return; |
| 497 | |
| 498 | if (!it_dock_) |
| 499 | { |
| 500 | /// Create Icicle Tree Widget |
| 501 | |
| 502 | it_dock_ = new QDockWidget("Icicle Tree", this); |
| 503 | it_dock_->setAllowedAreas(Qt::BottomDockWidgetArea | Qt::TopDockWidgetArea); |
| 504 | addDockWidget(Qt::TopDockWidgetArea, it_dock_); |
| 505 | |
| 506 | icicle_tree_.reset(new pixel_view::IcicleCanvas(tree)); |
| 507 | icicle_tree_->setDarkMode(dark_mode_); |
| 508 | it_dock_->setWidget(icicle_tree_.get()); |
| 509 | |
| 510 | connect(icicle_tree_.get(), &pixel_view::IcicleCanvas::nodeClicked, this, &ExecutionWindow::nodeSelected); |
| 511 | connect(icicle_tree_.get(), &pixel_view::IcicleCanvas::nodeClicked, traditional_view_.get(), &tree::TraditionalView::centerCurrentNode); |
| 512 | |
| 513 | /// Note: nodeSelected can be triggered by some other view |
| 514 | connect(this, &ExecutionWindow::nodeSelected, icicle_tree_.get(), &pixel_view::IcicleCanvas::selectNode); |
| 515 | } |
| 516 | |
| 517 | if (it_dock_->isHidden()) |
| 518 | { |
| 519 | it_dock_->show(); |
| 520 | } |
| 521 | else |
| 522 | { |
| 523 | it_dock_->hide(); |
| 524 | } |
| 525 | } |
| 526 | |
| 527 | void ExecutionWindow::toggleLanternView(bool checked) |
| 528 | { |
nothing calls this directly
no test coverage detected