Import Geant4 11.3.0 source tree
This commit is contained in:
@@ -94,7 +94,6 @@ class G4ParticleMessenger : public G4UImessenger
|
||||
G4UIcmdWithAnInteger* verboseCmd = nullptr;
|
||||
|
||||
G4ParticleTable* theParticleTable = nullptr;
|
||||
G4ParticleDefinition* currentParticle = nullptr;
|
||||
|
||||
G4ParticlePropertyMessenger* fParticlePropertyMessenger = nullptr;
|
||||
};
|
||||
|
||||
@@ -201,14 +201,8 @@ G4String G4ParticleMessenger::GetCurrentValue(G4UIcommand* command)
|
||||
}
|
||||
selectCmd->SetCandidates((const char*)(candidates));
|
||||
|
||||
static const G4String noName("none");
|
||||
// current value
|
||||
if (currentParticle == nullptr) {
|
||||
// no particle is selected. return null
|
||||
return noName;
|
||||
}
|
||||
|
||||
return currentParticle->GetParticleName();
|
||||
const G4ParticleDefinition* currentParticle = theParticleTable->GetSelectedParticle();
|
||||
return (currentParticle == nullptr) ? G4String("none") : currentParticle->GetParticleName();
|
||||
}
|
||||
if (command == verboseCmd) {
|
||||
// Command /particle/verbose
|
||||
|
||||
Reference in New Issue
Block a user