Skip to content
Snippets Groups Projects
Commit f525de23 authored by Wuttke, Joachim's avatar Wuttke, Joachim
Browse files

setting name to 'Instrument' is pointless

parent 168c669c
No related branches found
No related tags found
2 merge requests!907Core cleanup,!905mv class Instrument out of core
......@@ -79,17 +79,13 @@ void GUI::Transform::FromDomain::populateInstrumentItems(InstrumentItems* instru
{
ASSERT(instrumentItems);
QString name = instrument_name.isEmpty()
? QString::fromStdString(simulation.instrument().className())
: instrument_name;
if (const auto* gisasSimulation = dynamic_cast<const ScatteringSimulation*>(&simulation))
createGISASInstrumentItem(instrumentItems, *gisasSimulation, name);
createGISASInstrumentItem(instrumentItems, *gisasSimulation, instrument_name);
else if (const auto* offSpecSimulation =
dynamic_cast<const OffSpecularSimulation*>(&simulation))
createOffSpecularInstrumentItem(instrumentItems, *offSpecSimulation, name);
createOffSpecularInstrumentItem(instrumentItems, *offSpecSimulation, instrument_name);
else if (const auto* spec_simulation = dynamic_cast<const SpecularSimulation*>(&simulation))
createSpecularInstrumentItem(instrumentItems, *spec_simulation, name);
createSpecularInstrumentItem(instrumentItems, *spec_simulation, instrument_name);
else
ASSERT(0);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment