| 332 | } |
| 333 | |
| 334 | void ToolBarConfiguration::PostRead(Legacy &legacy) |
| 335 | { |
| 336 | // Be sure no nodes contain NULL, |
| 337 | // against the case of obsolete preferences, perhaps |
| 338 | RemoveNulls(mForest); |
| 339 | |
| 340 | // Interpret what was saved in old .cfg files under "order" |
| 341 | // which specified toolbar configuration simply as a sequence, not a tree |
| 342 | ToolBar *prev {}; |
| 343 | for (auto pBar : legacy.bars) { |
| 344 | if (!pBar) |
| 345 | continue; |
| 346 | |
| 347 | Position position{ prev }; |
| 348 | Insert(pBar, position); |
| 349 | |
| 350 | prev = pBar; |
| 351 | } |
| 352 | } |
| 353 | |
| 354 | void ToolBarConfiguration::Write |
| 355 | (const ToolBarConfiguration *pConfiguration, const ToolBar *bar) |