Populate the component list
| 162 | |
| 163 | // Populate the component list |
| 164 | void ComponentsDialog::populateComponents() |
| 165 | { |
| 166 | // Clear the list store |
| 167 | _componentList->Clear(); |
| 168 | |
| 169 | // Add components from the Objective to the list store |
| 170 | for (Objective::ComponentMap::iterator i = _components.begin(); |
| 171 | i != _components.end(); |
| 172 | ++i) |
| 173 | { |
| 174 | wxutil::TreeModel::Row row = _componentList->AddItem(); |
| 175 | |
| 176 | row[_columns.index] = i->first; |
| 177 | row[_columns.description] = i->second.getString(); |
| 178 | |
| 179 | row.SendItemAdded(); |
| 180 | } |
| 181 | |
| 182 | _updateNeeded = true; |
| 183 | } |
| 184 | |
| 185 | void ComponentsDialog::updateComponents() |
| 186 | { |