MCPcopy Create free account
hub / github.com/OpenDDS/OpenDDS / updateNodeView

Method updateNodeView

tools/monitor/Viewer.cpp:501–524  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

499 }
500
501 void
502 Viewer::updateNodeView(bool honorDisplayFlag)
503 {
504 if (nodeScene != 0) {
505 delete nodeScene;
506 nodeScene = 0;
507 }
508
509 // invalid QModelIndex signifies the root.
510 NodeGenerator ng(this->dataSource_->modelRoot(), nodeOpt, honorDisplayFlag);
511
512 // calculate the layout based on options and number of nodes
513 ng.calcLayout(this->dataSource_->modelRoot(), 1, 1);
514
515 nodeScene = new QGraphicsScene(0, 0, ng.getSceneWidth(), ng.getSceneHeight());
516 this->ui.nodeView->setScene(nodeScene);
517
518 ng.draw(nodeScene);
519
520 std::stringstream msg;
521 msg << "Node View Updated " << ng.getSceneWidth() << "x" << ng.getSceneHeight();
522
523 this->ui.statusbar->showMessage( tr(msg.str().c_str()));
524 }
525
526 void
527 Viewer::expand(bool flag)

Callers

nothing calls this directly

Calls 6

modelRootMethod · 0.80
calcLayoutMethod · 0.80
getSceneWidthMethod · 0.80
getSceneHeightMethod · 0.80
drawMethod · 0.45
strMethod · 0.45

Tested by

no test coverage detected