MCPcopy Create free account
hub / github.com/BehaviorTree/Groot / load

Method load

QtNodeEditor/src/FlowScene.cpp:500–525  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

498
499
500void
501FlowScene::
502load()
503{
504 clearScene();
505
506 //-------------
507
508 QString fileName =
509 QFileDialog::getOpenFileName(nullptr,
510 tr("Open Flow Scene"),
511 QDir::homePath(),
512 tr("Flow Scene Files (*.flow)"));
513
514 if (!QFileInfo::exists(fileName))
515 return;
516
517 QFile file(fileName);
518
519 if (!file.open(QIODevice::ReadOnly))
520 return;
521
522 QByteArray wholeFile = file.readAll();
523
524 loadFromMemory(wholeFile);
525}
526
527
528QByteArray

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected