Search in sources :

Example 1 with XSDProcessContents

use of org.eclipse.xsd.XSDProcessContents in project webtools.sourceediting by eclipse.

the class XSDAnyElementContentsSection method refresh.

/*
   * @see org.eclipse.wst.common.ui.properties.internal.provisional.view.ITabbedPropertySection#refresh()
   */
public void refresh() {
    setListenerEnabled(false);
    // $NON-NLS-1$
    namespaceCombo.setText("");
    // $NON-NLS-1$
    processContentsCombo.setText("");
    if (input != null) {
        if (input instanceof XSDWildcard) {
            XSDWildcard wildcard = (XSDWildcard) input;
            if (wildcard.isSetLexicalNamespaceConstraint()) {
                namespaceCombo.setText(wildcard.getStringLexicalNamespaceConstraint());
            } else {
                namespaceCombo.setText("");
            }
            if (wildcard.isSetProcessContents()) {
                XSDProcessContents pc = wildcard.getProcessContents();
                processContentsCombo.setText(pc.getName());
            }
            if (wildcard.eContainer() instanceof XSDParticle) {
                minCombo.setEnabled(!isReadOnly);
                maxCombo.setEnabled(!isReadOnly);
            } else {
                minCombo.setEnabled(false);
                maxCombo.setEnabled(false);
            }
        }
    }
    refreshMinMax();
    setListenerEnabled(true);
}
Also used : XSDWildcard(org.eclipse.xsd.XSDWildcard) XSDParticle(org.eclipse.xsd.XSDParticle) XSDProcessContents(org.eclipse.xsd.XSDProcessContents)

Aggregations

XSDParticle (org.eclipse.xsd.XSDParticle)1 XSDProcessContents (org.eclipse.xsd.XSDProcessContents)1 XSDWildcard (org.eclipse.xsd.XSDWildcard)1