| 157 | } |
| 158 | |
| 159 | ProjectBaseItem::~ProjectBaseItem() |
| 160 | { |
| 161 | Q_D(ProjectBaseItem); |
| 162 | |
| 163 | if (model() && !d->m_indexedPath.isEmpty()) { |
| 164 | model()->d_func()->pathLookupTable.remove(d->m_indexedPath, this); |
| 165 | } |
| 166 | |
| 167 | if( parent() ) { |
| 168 | parent()->takeRow( d->row ); |
| 169 | } else if( model() ) { |
| 170 | model()->takeRow( d->row ); |
| 171 | } |
| 172 | removeRows(0, d->children.size()); |
| 173 | } |
| 174 | |
| 175 | ProjectBaseItem* ProjectBaseItem::child( int row ) const |
| 176 | { |