* Fills the list with possible ResearchProjects. */
| 114 | * Fills the list with possible ResearchProjects. |
| 115 | */ |
| 116 | void NewResearchListState::fillProjectList () |
| 117 | { |
| 118 | _projects.clear(); |
| 119 | _lstResearch->clearList(); |
| 120 | _game->getSavedGame()->getAvailableResearchProjects(_projects, _game->getRuleset() , _base); |
| 121 | std::vector<RuleResearch*>::iterator it = _projects.begin(); |
| 122 | while (it != _projects.end ()) |
| 123 | { |
| 124 | if ((*it)->getRequirements().empty()) |
| 125 | { |
| 126 | _lstResearch->addRow(1, tr((*it)->getName ()).c_str()); |
| 127 | ++it; |
| 128 | } |
| 129 | else |
| 130 | { |
| 131 | it = _projects.erase(it); |
| 132 | } |
| 133 | } |
| 134 | } |
| 135 | |
| 136 | } |
nothing calls this directly
no test coverage detected