commit | 82a46ae0dcb67afe7d3165b0f2a9ec7d7aee6868 | [log] [tgz] |
---|---|---|
author | kchong <kchong> | Wed Nov 07 19:42:43 2007 +0000 |
committer | kchong <kchong> | Wed Nov 07 19:42:43 2007 +0000 |
tree | 892bb31a3e1e371a9d6744ef0e6918765da8a9e2 | |
parent | be5d999f4f5f9b5282105f929a3e272eb99921f1 [diff] |
[193619] XSD Editor: Design view input not updated when elements/attributes are selected in the source view
diff --git a/bundles/org.eclipse.wst.xsd.ui/src-adt/org/eclipse/wst/xsd/ui/internal/adt/design/DesignViewGraphicalViewer.java b/bundles/org.eclipse.wst.xsd.ui/src-adt/org/eclipse/wst/xsd/ui/internal/adt/design/DesignViewGraphicalViewer.java index efce846..753c105 100644 --- a/bundles/org.eclipse.wst.xsd.ui/src-adt/org/eclipse/wst/xsd/ui/internal/adt/design/DesignViewGraphicalViewer.java +++ b/bundles/org.eclipse.wst.xsd.ui/src-adt/org/eclipse/wst/xsd/ui/internal/adt/design/DesignViewGraphicalViewer.java
@@ -98,10 +98,11 @@ if (selectedObject instanceof IField) { IField field = (IField)selectedObject; - if (!field.isGlobal() && getInput() instanceof IModel) + if (!field.isGlobal()) { - if (field.getContainerType() != null) - setInput(field.getContainerType()); + IADTObject obj = ((IGraphElement)selectedObject).getTopContainer(); + if (obj != null) + setInput (obj); } else if (field.isGlobal() && !(getInput() instanceof IModel)) {