86 this->needRecache = false; |
86 this->needRecache = false; |
87 } |
87 } |
88 return this->cachedPolygons; |
88 return this->cachedPolygons; |
89 } |
89 } |
90 |
90 |
91 QModelIndex Model::lookup(ldraw::Id id) const |
91 QModelIndex Model::lookup(ldraw::id_t id) const |
92 { |
92 { |
93 // FIXME: This linear search will probably cause performance issues |
93 // FIXME: This linear search will probably cause performance issues |
94 for (std::size_t i = 0; i < this->body.size(); i += 1) |
94 for (std::size_t i = 0; i < this->body.size(); i += 1) |
95 { |
95 { |
96 if (this->body[i]->id == id) |
96 if (this->body[i]->id == id) |