125 else |
125 else |
126 continue; |
126 continue; |
127 |
127 |
128 // Merge in the inlined objects |
128 // Merge in the inlined objects |
129 for (LDObject* inlineobj : objs) { |
129 for (LDObject* inlineobj : objs) { |
130 // This object is now inlined so it has no parent anymore. |
130 str line = inlineobj->raw(); |
131 inlineobj->setParent (null); |
131 delete inlineobj; |
132 g_curfile->insertObj (idx++, inlineobj); |
132 |
|
133 LDObject* newobj = parseLine( line ); |
|
134 g_curfile->insertObj( idx++, newobj ); |
|
135 g_win->sel() << newobj; |
133 } |
136 } |
134 |
137 |
135 // Delete the subfile now as it's been inlined. |
138 // Delete the subfile now as it's been inlined. |
136 g_curfile->forgetObject (obj); |
139 g_curfile->forgetObject( obj ); |
137 delete obj; |
140 delete obj; |
138 } |
141 } |
139 |
142 |
140 g_win->fullRefresh (); |
143 g_win->fullRefresh (); |
141 } |
144 } |