MCPcopy Create free account
hub / github.com/Geant4/geant4 / CreateHelpTree

Method CreateHelpTree

source/interfaces/implementation/src/G4UIWin32.cc:1242–1269  ·  view source on GitHub ↗

/ !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!*/

Source from the content-addressed store, hash-verified

1240/****************************************************************************************************/
1241/*!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!*/
1242void G4UIWin32::CreateHelpTree(HTREEITEM aParent, G4UIcommandTree* aCommandTree)
1243{
1244 if ((aParent != nullptr) && (aCommandTree != nullptr)) {
1245 // Creating new item
1246 HTREEITEM newItem;
1247
1248 G4String commandText;
1249 // Get the Sub directories
1250 for (G4int a = 0; a < aCommandTree->GetTreeEntry(); a++) {
1251 commandText = aCommandTree->GetTree(a + 1)->GetPathName().data();
1252
1253 // Add the item to the tree-view control.
1254 newItem =
1255 AddItemToHelpTree((PTSTR)GetShortCommandPath(commandText).c_str(), aParent);
1256
1257 // Look for children
1258 CreateHelpTree(newItem, aCommandTree->GetTree(a + 1));
1259 }
1260
1261 // Get the Commands
1262 for (G4int a = 0; a < aCommandTree->GetCommandEntry(); a++) {
1263 commandText = aCommandTree->GetCommand(a + 1)->GetCommandPath().data();
1264
1265 // Add the item to the tree-view control.
1266 AddItemToHelpTree((PTSTR)GetShortCommandPath(commandText).c_str(), aParent);
1267 }
1268 }
1269}
1270/*!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!*/
1271/****************************************************************************************************/
1272

Callers

nothing calls this directly

Calls 6

GetTreeEntryMethod · 0.80
c_strMethod · 0.80
GetCommandEntryMethod · 0.80
dataMethod · 0.45
GetTreeMethod · 0.45
GetCommandMethod · 0.45

Tested by

no test coverage detected