- Timestamp:
- 09/15/11 21:47:04 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/modelicaml/org.openmodelica.modelicaml.common/src/org/openmodelica/modelicaml/common/services/PapyrusServices.java
r943 r958 36 36 if (object instanceof String) { 37 37 38 // IViewPart view = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage().findView("org.openmodelica.modelicaml.view.componentstree");39 38 List<Object> elements = new ArrayList<Object>(); 40 39 // find treeObject with the dotPath 41 42 40 HashSet<Object> treeObjects = TreeUtls.findTreeItems((String) object, TreeUtls.componentsTreeRoot, new HashSet<Object>()); 43 41 elements.addAll(treeObjects); 44 42 45 43 StructuredSelection selection = new StructuredSelection(elements); 46 TreeUtls.componentsTreeViewer.setSelection(selection); 47 48 // if (view instanceof ModelExplorerPageBookView) { 49 // modelExplorerPageBookView = (ModelExplorerPageBookView)view; 50 // } 51 // CommonViewer modelExplorerView = ((ModelExplorerView) modelExplorerPageBookView.getAdapter(ModelExplorerView.class)).getCommonViewer(); 52 // List<Object> items = new ArrayList<Object>(); 53 // items.add(modelExplorerPageBookView.findElementForEObject( modelExplorerView, (EObject)object)); 54 // modelExplorerView.setSelection(new StructuredSelection(items), true); 44 45 if (TreeUtls.componentsTreeViewer != null) { 46 TreeUtls.componentsTreeViewer.setSelection(selection); 47 } 55 48 } 56 49 }
Note: See TracChangeset
for help on using the changeset viewer.