Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 355731

Summary: [collaborative work] move element/diagram into a submodel not loaded should be forbidden
Product: [Modeling] Papyrus Reporter: Raphael Faudou <raphael.faudou>
Component: CoreAssignee: Project Inbox <mdt-papyrus-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: major    
Priority: P3 CC: faure.tristan, papyrus-bugs, Patrick.Tessier, raphael.faudou, thanhliem.phan
Version: 0.8.0   
Target Milestone: 4.0.0   
Hardware: PC   
OS: Windows XP   
See Also: https://git.eclipse.org/r/92523
https://git.eclipse.org/c/papyrus/org.eclipse.papyrus.git/commit/?id=54fc6c60773a0b877e128bd02bdb7aa91d41f59e
Whiteboard:
Bug Depends on: 348653    
Bug Blocks:    

Description Raphael Faudou CLA 2011-08-24 11:52:08 EDT

    
Comment 1 Raphael Faudou CLA 2011-08-24 11:55:09 EDT
From model explorer view we can move a model element or a diagram from one package to another. 
In the case the target package belongs to a submodel in a resource not loaded (proxy), the "move" command should not be authorized.
Comment 2 Thanh Liem PHAN CLA 2017-03-07 03:58:06 EST
Tested on Eclipse Oxygen: this bug still exists. Moving an element into an unloaded submodel package could be always done. This should be prohibited.

Steps to reproduce the bug:
- Create a model with submodels
- In Preferences/Papyrus/Model loading/, choose the following option
   + "Load additional resources (profile and pathmap). Submodels can be loaded manually in Model Explorer view".
- Close and reopen the model.
- All submodels are now in unloaded state
- Right click on the submodel and select "Load" to load it manually.
Comment 3 Thanh Liem PHAN CLA 2017-03-07 08:52:56 EST
If the move command is not prohibited. It would lead to the following to the scenario:
- Create a main model and a submodel of its package, for example
- Move a certain element into the unloaded submodel package
- Save the modification & close the main model
- Reopen the main model
- Now the moved element does not exist neither in the main model nor in the submodel.

It causes the lost information silently, which must be prohibited.
Comment 4 Eclipse Genie CLA 2017-03-07 10:47:39 EST
New Gerrit change created: https://git.eclipse.org/r/92523