1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-09 10:46:02 +02:00

If the changes of the editor were discarded at closing

no event were sent.
This commit is contained in:
Alain Magloire 2004-03-09 20:54:55 +00:00
parent d055189a64
commit 209df8040a
2 changed files with 16 additions and 5 deletions

View file

@ -1,3 +1,15 @@
2004-03-08 Alain Magloire
In the Editor if the changes are discarded i.e.
closing the editor whitout saving. We do not update
the working copy or rathe we do not discard the change
and fire an event to the listeners. Now we do but it
can still be a problem since the destroy becomes heavy
wieght and it is not wrap around a Workspace operation.
Fire the event at destroy will have to do for now.
* model/org/eclipse/cdt/internal/core/model/WorkingCopy.java
2004-03-08 Hoda Amer
Partial fix for bug#52948 : Content Assist: typedef-ed types do not appear in the completion list.

View file

@ -132,11 +132,10 @@ public class WorkingCopy extends TranslationUnit implements IWorkingCopy {
Map perFactoryWorkingCopies = (Map) sharedWorkingCopies.get(this.bufferFactory);
if (perFactoryWorkingCopies != null){
if (perFactoryWorkingCopies.remove(originalElement) != null) {
// report removed java delta
//CElementDelta delta = new CElementDelta(this.getCoreModel());
//delta.removed(this);
//manager.fire(delta, CModelManager.DEFAULT_CHANGE_EVENT);
// report C deltas
CElementDelta delta = new CElementDelta(this.getCModel());
delta.removed(this);
CModelManager.getDefault().fire(delta, ElementChangedEvent.POST_RECONCILE);
}
}
} catch (CModelException e) {