Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 304362 - [MoDisco Browser] MoDisco browser to an editor
Summary: [MoDisco Browser] MoDisco browser to an editor
Status: CLOSED FIXED
Alias: None
Product: MoDisco
Classification: Modeling
Component: Infrastructure (show other bugs)
Version: 0.8.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 0.8.0   Edit
Assignee: Nicolas Bros CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 304011
  Show dependency tree
 
Reported: 2010-03-02 09:54 EST by Nicolas Payneau CLA
Modified: 2010-09-22 05:35 EDT (History)
3 users (show)

See Also:
nicolas.bros: helios+


Attachments
Patch transforming the MoDisco browser to an editor (60.06 KB, patch)
2010-03-02 09:56 EST, Nicolas Payneau CLA
nicolas.bros: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Nicolas Payneau CLA 2010-03-02 09:54:17 EST
Build Identifier: 20100204-1618

Hi MoDisco team,

In order to occupy my long winter nights, I transformed the MoDisco browser to an editor. In attachment, the patch for this.

In this patch:
- I modified the EcoreBrowser class
- I changed PropertySheetPage to ExtendedPropertySheetPage.
- We didn't use PropertySourceAdapterFactory but AdapterFactoryContentProvider to fuel the PropertySheetPage.
- EcoreBrowser class implements IEditingDomainProvider and IGotoMarker
- I implemented methods save saveAs isDirty ... (They were not implemented)

- I modified the BrowserActionBarContributor class
- BrowserActionBarContributor class extends EditingDomainActionBarContributor
- I added "New Child" and "New Sibling" menus
- I added a default menu to provide eclipse with delete, copy, undo, redo, ... functions

- I modified the WorkspaceChangeListener class
- I modified the Messages class and Messages.properties file.

So with this patch the following actions become available:
- Edit a model
- Add an object to the model
- Delete an object from the model
- Undo, redo, refresh

To finish, with the MoDisco browser we can see details of a selected "AttributeItem" in the property view. Now, we only show the details of containing "ModelElementItem" when we select an "AttributeItem" .

Best regards,

Nicolas Payneau

Reproducible: Always
Comment 1 Nicolas Payneau CLA 2010-03-02 09:56:58 EST
Created attachment 160623 [details]
Patch transforming the MoDisco browser to an editor
Comment 2 Nicolas Payneau CLA 2010-03-04 09:05:54 EST
(In reply to comment #1)
> Created an attachment (id=160623) [details]
> Patch transforming the MoDisco browser to an editor

Hi,

I discovered an error after the patch contributed. This error appears in some cases when selecting item in the browser.
This error located in the class org.eclipse.gmt.modisco.infra.browser.editors.BrowserActionBarContributor at line 231.
We have to check if the object has a resource before retrieving the URI.

Best regards,

Nicolas Payneau
Comment 3 Hugo Bruneliere CLA 2010-03-10 11:14:43 EST
Hi Nicolas,

Please, could you make the usual confirmations via this bug and attach to it the latest version of the patch to be actually integrated?

I will create the corresponding CQ as soon as possible.

Best regards,

Hugo
Comment 4 Nicolas Payneau CLA 2010-03-10 12:23:34 EST
(In reply to comment #3)
> Hi Nicolas,
> 
> Please, could you make the usual confirmations via this bug and attach to it
> the latest version of the patch to be actually integrated?
> 
> I will create the corresponding CQ as soon as possible.
> 
> Best regards,
> 
> Hugo

Hi Hugo,

I confirm that you have the latest version of the patch. 
I confirm that
1. I, Nicolas Payneau, authored 100% of the content
2. I have the rights to donate the content to Eclipse under the EPL
3. I have already provided the filled Employer Consent Forms to the Foundation


Best regards,

Nicolas
Comment 5 Hugo Bruneliere CLA 2010-03-11 09:07:05 EST
Corresponding CQ 3845 has been created.
Comment 6 Hugo Bruneliere CLA 2010-03-11 10:56:33 EST
The CQ has been validated (very quickly thanks to Sharon).
I'm going to integrate the patch.

Hugo
Comment 7 Hugo Bruneliere CLA 2010-03-11 11:59:43 EST
Nicolas,

I have some problems applying your patch: e.g. it removes the PropertySourceAdapterFactory class which is still required, etc.
Note that I'm using the latest version of the org.eclipse.gmt.modisco.infra.browser plug-in (sources) from the MoDisco SVN trunk.

Please, could you check from your development workspace that you don't have such issues?

Regards,

Hugo
Comment 8 Nicolas Bros CLA 2010-03-11 12:14:42 EST
Don't bother with it. Gabriel made a refactoring, and I already made modifications to the patch. So, leave it to me.
Comment 9 Hugo Bruneliere CLA 2010-03-12 04:33:20 EST
OK Nicolas.
So I consider the patch as being applied.

Hugo