# HG changeset patch # User Benjamin Golinvaux # Date 1570450169 -7200 # Node ID 7b89e88bb66ebd3cd89d414d1010310c7d4cfbac # Parent 7014c2397b457802771d1b5b8048472fa900d8a8# Parent 0f100d0b9caff89460382138d7cc542f82be2746 Merge diff -r 0f100d0b9caf -r 7b89e88bb66e Framework/Loaders/DicomStructureSetLoader.cpp --- a/Framework/Loaders/DicomStructureSetLoader.cpp Fri Oct 04 21:58:30 2019 +0200 +++ b/Framework/Loaders/DicomStructureSetLoader.cpp Mon Oct 07 14:09:29 2019 +0200 @@ -169,10 +169,19 @@ loader.content_.reset(new DicomStructureSet(dicom)); size_t structureCount = loader.content_->GetStructuresCount(); loader.structureVisibility_.resize(structureCount); + bool everythingVisible = false; + if ((loader.initiallyVisibleStructures_.size() == 1) + && (loader.initiallyVisibleStructures_[0].size() == 1) + && (loader.initiallyVisibleStructures_[0][0] == '*')) + { + everythingVisible = true; + } + for (size_t i = 0; i < structureCount; ++i) { - // if nothing is specified in the ctor, this means we want everything visible - if (loader.initiallyVisibleStructures_.size() == 0) + // if a single "*" string is supplied, this means we want everything + // to be visible... + if(everythingVisible) { loader.structureVisibility_.at(i) = true; } diff -r 0f100d0b9caf -r 7b89e88bb66e Framework/Loaders/DicomStructureSetLoader.h --- a/Framework/Loaders/DicomStructureSetLoader.h Fri Oct 04 21:58:30 2019 +0200 +++ b/Framework/Loaders/DicomStructureSetLoader.h Mon Oct 07 14:09:29 2019 +0200 @@ -52,11 +52,11 @@ bool structuresReady_; /** - At load time, these strings is used to initialize the - structureVisibility_ vector. + At load time, these strings are used to initialize the structureVisibility_ + vector. - As a special case, if initiallyVisibleStructures_ is empty, ALL structures - will be made visible. + As a special case, if initiallyVisibleStructures_ contains a single string + that is '*', ALL structures will be made visible. */ std::vector initiallyVisibleStructures_;