Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 367052 - [xtext][editor] DirtyStateEditorSupport#haveEObjectDescriptionsChanged() should use IResourceDescription.Manager#createDelta()
Summary: [xtext][editor] DirtyStateEditorSupport#haveEObjectDescriptionsChanged() shou...
Status: CLOSED FIXED
Alias: None
Product: TMF
Classification: Modeling
Component: Xtext (show other bugs)
Version: 2.2.1   Edit
Hardware: PC Mac OS X - Carbon (unsup.)
: P3 normal (vote)
Target Milestone: M7   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-12-19 02:17 EST by Knut Wannheden CLA
Modified: 2017-10-31 11:17 EDT (History)
2 users (show)

See Also:
jan: juno+


Attachments
proposed patch (2.97 KB, patch)
2011-12-19 02:17 EST, Knut Wannheden CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Knut Wannheden CLA 2011-12-19 02:17:09 EST
The method DirtyStateEditorSupport#haveEObjectDescriptionsChanged() is currently implemented like this:


	public boolean haveEObjectDescriptionsChanged(final IResourceDescription newDescription) {
		return new DefaultResourceDescriptionDelta(dirtyResource.getDescription(), newDescription).haveEObjectDescriptionsChanged();
	}

I think it should instead be using the appropriate IResourceDescription.Manager and call its createDelta() method. See attached patch for details.
Comment 1 Knut Wannheden CLA 2011-12-19 02:17:38 EST
Created attachment 208534 [details]
proposed patch
Comment 2 Jan Koehnlein CLA 2012-02-24 12:08:27 EST
Scheduled for review.
Comment 3 Sven Efftinge CLA 2012-04-03 04:17:19 EDT
Makes sense, but we cannot change the signature of haveEObjectDescriptionsChanged.
Please add an overloaded variant instead and call that. Feel free to push the changes.
Comment 4 Knut Wannheden CLA 2012-04-30 11:33:35 EDT
Pushed fix to master: http://git.eclipse.org/c/tmf/org.eclipse.xtext.git/commit/?id=2f6770d309c7091a63051868c5acfbee51f1e160.

Marked old method as deprecated and implemented as delegate to new method.
Comment 5 Eclipse Webmaster CLA 2017-10-31 11:05:47 EDT
Requested via bug 522520.

-M.
Comment 6 Eclipse Webmaster CLA 2017-10-31 11:17:03 EDT
Requested via bug 522520.

-M.