Bug 146976 Save state of the report not correct.
Reproduce: 1) New a library "lib1", add a label "label1" 2) Publish "lib1" 3) New a report "report1", use "lib1" 4) Drag "lib1.label1" into "report1" 5) Go back to "lib1", drop "label1", save and publish again. 6) Go to "report1", refresh the libaray explorer and design. 7) Save "report1" 8) Now, we go back to "lib1" 9) Undo the previous "delete command", "label1" is added back. 10) Save "lib1", and re-publish. 11) Go to "report1", refresh the libaray explorer and design. 12) Save "report1" At this stage, "report1" is saved, but the dirty indicator(*) still displayed in the left side of the report name. I am testing on build N20060613
model/org.eclipse.birt.report.model/src/org/eclipse/birt/report/model/activity/ActivityStack.java
* error, and so asserts should be used to verify that the state is valid.
 * Another way of saying this is that records <em>cannot</em> throw
 * application-level exceptions: they must succeed. Any exceptions thrown would
 * be system-level exceptions such as null- pointer violations, out-of-memory
 * errors and other generic problems.
 * 
 * <h3>Persistence Support</h3>
 * 
 * The record stack contains a dirty property. This property can be used to
 * determine when persisting the Records' changes is required. Upon
 * construction, the undo stack is empty, and is not dirty.
 * 
 * <h3>Dirty State Support</h3>
 * 
 * A design is considered <em>dirty</em> if the in-memory state differs from
 * that on disk. There are three primary considerations:
 * <p>
 * <ul>
 * <li>The user has made changes to the file since it was loaded or saved. The
 * file is considered dirty.</li>
 * <li>The user has made changes, then undone them so that the file is back to
 * the same state as on disk. In this case, the file is <em>not</em> dirty.
 * </li>
 * <li>The user makes some changes, saves the file, then undoes the changes.
 * The file <em>is</em> considered dirty: the in-memory state represents an
 * "earlier" version of the file than what is stored on disk.</li>
 * </ul>
 * <p>
 * The activity stack is the primary mechanism for tracking dirty state. There
 * are three values we track: