1
0
mirror of git://projects.qi-hardware.com/fped.git synced 2025-04-21 12:27:27 +03:00

Cleaned up the disgusting mess that was the list of frames. The changes:

- removed root_frame. "frames" now takes its place.
- removed frame->prev. In those few cases where we need the previous frame (for
  deletion and dumping), we walk the list or recurse.
- the list of frames is now in GUI order, not file order.
- when reading the .fpd file, put the root frame first and leave it there.
- instead of walking the frames list and excluding the root frame by testing
  frame->name, just start at frames->next
- likewise, instead of testing !frame->name just use frame == frames



git-svn-id: http://svn.openmoko.org/trunk/eda/fped@5948 99fdad57-331a-0410-800a-d7fa5415bdb3
This commit is contained in:
werner
2010-04-28 00:34:32 +00:00
parent ac535d6e03
commit dbace0b2fa
11 changed files with 58 additions and 86 deletions

2
inst.c
View File

@@ -82,7 +82,7 @@ static int show_this(const struct inst *inst)
if (inst->ops == &frame_ops && inst->u.frame.ref == active_frame)
return 1;
if (!inst->outer)
return active_frame == root_frame;
return active_frame == frames;
return inst->outer->u.frame.ref == active_frame;
}