Package org.eclipse.jface.fieldassist

Examples of org.eclipse.jface.fieldassist.ComboContentAdapter


        // attribute combo with field decoration and content proposal
        objectClassCombo = BaseWidgetUtils.createCombo( composite, new String[0], -1, 1 );
        objectClassCombo.setVisibleItemCount( 20 );
        objectClassCombo.setItems( allOcNames );
        objectClassCombo.setText( initialValue );
        new ExtendedContentAssistCommandAdapter( objectClassCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( objectClassCombo.getItems() ), null, null, true );

        applyDialogFont( composite );
        return composite;
    }
View Full Code Here


        // attribute combo with field decoration and content proposal
        administrativeRoleCombo = BaseWidgetUtils.createCombo( composite, new String[0], -1, 1 );
        administrativeRoleCombo.setVisibleItemCount( 20 );
        administrativeRoleCombo.setItems( administrativeRoleValues );
        administrativeRoleCombo.setText( initialValue );
        new ExtendedContentAssistCommandAdapter( administrativeRoleCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( administrativeRoleCombo.getItems() ), null, null, true );

        applyDialogFont( composite );
        return composite;
    }
View Full Code Here

           
        });

        SimpleContentProposalProvider proposalProvider = new SimpleContentProposalProvider(combo.getItems());
        proposalProvider.setFiltering(true);
        final ComboContentAdapter controlContentAdapter = new ComboContentAdapter() {
            @Override
            public void insertControlContents(Control control, String text,
                    int cursorPosition) {
                Point selection = combo.getSelection();
                combo.setText(text);
View Full Code Here

        innerComposite = BaseWidgetUtils.createColumnContainer( composite, 5, 1 );

        String[] attributes = HistoryUtils.load( ATTRIBUTE_HISTORY_DIALOGSETTING_KEY );
        quickSearchAttributeCombo = BaseWidgetUtils.createCombo( innerComposite, attributes, -1, 1 );
        quickSearchAttributePP = new ListContentProposalProvider( attributes );
        new ExtendedContentAssistCommandAdapter( quickSearchAttributeCombo, new ComboContentAdapter(),
            quickSearchAttributePP, null, null, true );
        quickSearchAttributeCombo.addModifyListener( new ModifyListener()
        {
            public void modifyText( ModifyEvent e )
            {
                quickSearchRunButton.setEnabled( !"".equals( quickSearchAttributeCombo.getText() ) );
            }
        } );
        quickSearchAttributeCombo.addSelectionListener( new SelectionAdapter()
        {
            public void widgetDefaultSelected( SelectionEvent e )
            {
                performSearch();
            }
        } );
        GridData gd = new GridData( GridData.FILL_HORIZONTAL );
        gd.widthHint = 50;
        quickSearchAttributeCombo.setLayoutData( gd );

        String[] operators = new String[]
            { "=", "!=", "<=", ">=", "~=" };
        quickSearchOperatorCombo = BaseWidgetUtils.createReadonlyCombo( innerComposite, operators, 0, 1 );
        GridData data = new GridData();
        quickSearchOperatorCombo.setLayoutData( data );

        String[] values = HistoryUtils.load( VALUE_HISTORY_DIALOGSETTING_KEY );
        quickSearchValueCombo = BaseWidgetUtils.createCombo( innerComposite, values, -1, 1 );
        quickSearchValuePP = new ListContentProposalProvider( values );
        new ExtendedContentAssistCommandAdapter( quickSearchValueCombo, new ComboContentAdapter(), quickSearchValuePP,
            null, null, true );
        quickSearchValueCombo.addSelectionListener( new SelectionAdapter()
        {
            public void widgetDefaultSelected( SelectionEvent e )
            {
View Full Code Here

        BaseWidgetUtils.createLabel( composite, Messages.getString( "AttributeTypeWizardPage.AttributeTypeLabel" ), 1 ); //$NON-NLS-1$

        // attribute combo with field decoration and content proposal
        attributeTypeCombo = BaseWidgetUtils.createCombo( composite, possibleAttributeTypes, -1, 1 );
        attributeTypeCombo.setText( parsedAttributeType );
        new ExtendedContentAssistCommandAdapter( attributeTypeCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( possibleAttributeTypes ), null, null, true );

        BaseWidgetUtils.createSpacer( composite, 1 );
        showSubschemAttributesOnlyButton = BaseWidgetUtils.createCheckbox( composite, Messages
            .getString( "AttributeTypeWizardPage.ShowSubschemaAttributesOnly" ), //$NON-NLS-1$
View Full Code Here

                    validate();
                }
            } );

            // attach content proposal behavior
            contextEntryDnComboCPA = new ContentProposalAdapter( contextEntryDnCombo, new ComboContentAdapter(), null,
                null, null );
            contextEntryDnComboCPA.setFilterStyle( ContentProposalAdapter.FILTER_NONE );
            contextEntryDnComboCPA.setProposalAcceptanceStyle( ContentProposalAdapter.PROPOSAL_REPLACE );

            setControl( composite );
View Full Code Here

        String[] attributeDescriptions = SchemaUtils.getNamesAsArray( schema.getAttributeTypeDescriptions() );
        Arrays.sort( attributeDescriptions );

        // attribute combo with field decoration and content proposal
        modSpec.modAttributeCombo = BaseWidgetUtils.createCombo( modSpecComposite, new String[0], -1, 1 );
        new ExtendedContentAssistCommandAdapter( modSpec.modAttributeCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( attributeDescriptions ), null, null, true );

        // add button with listener
        modSpec.modAddButton = new Button( modComposite, SWT.PUSH );
        modSpec.modAddButton.setText( "  +   " ); //$NON-NLS-1$
View Full Code Here

        rdnLine.rdnTypeCombo = new Combo( rdnComposite, SWT.DROP_DOWN | SWT.BORDER );
        GridData gd = new GridData();
        gd.widthHint = 180;
        rdnLine.rdnTypeCombo.setLayoutData( gd );
        rdnLine.rdnNameCPA = new ExtendedContentAssistCommandAdapter( rdnLine.rdnTypeCombo, new ComboContentAdapter(),
            new ListContentProposalProvider( attributeNames ), null, null, true );

        rdnLine.rdnEqualsLabel = new Label( rdnComposite, SWT.NONE );
        rdnLine.rdnEqualsLabel.setText( "=" ); //$NON-NLS-1$
View Full Code Here

                }
            }
        } );
        parser = new LdapFilterParser();
        contentAssistProcessor = new FilterContentAssistProcessor( parser );
        filterCPA = new ExtendedContentAssistCommandAdapter( filterCombo, new ComboContentAdapter(),
            contentAssistProcessor, null, null, true );

        // auto edit strategy
        new FilterWidgetAutoEditStrategyAdapter( filterCombo, parser );
View Full Code Here

        innerComposite = BaseWidgetUtils.createColumnContainer( composite, 5, 1 );

        String[] attributes = HistoryUtils.load( ATTRIBUTE_HISTORY_DIALOGSETTING_KEY );
        quickSearchAttributeCombo = BaseWidgetUtils.createCombo( innerComposite, attributes, -1, 1 );
        quickSearchAttributePP = new ListContentProposalProvider( attributes );
        new ExtendedContentAssistCommandAdapter( quickSearchAttributeCombo, new ComboContentAdapter(),
            quickSearchAttributePP, null, null, true );
        quickSearchAttributeCombo.addModifyListener( new ModifyListener()
        {
            public void modifyText( ModifyEvent e )
            {
                quickSearchRunButton.setEnabled( !"".equals( quickSearchAttributeCombo.getText() ) );
            }
        } );
        quickSearchAttributeCombo.addSelectionListener( new SelectionAdapter()
        {
            public void widgetDefaultSelected( SelectionEvent e )
            {
                performSearch();
            }
        } );
        GridData gd = new GridData( GridData.FILL_HORIZONTAL );
        gd.widthHint = 50;
        quickSearchAttributeCombo.setLayoutData( gd );

        String[] operators = new String[]
            { "=", "!=", "<=", ">=", "~=" };
        quickSearchOperatorCombo = BaseWidgetUtils.createReadonlyCombo( innerComposite, operators, 0, 1 );
        GridData data = new GridData();
        quickSearchOperatorCombo.setLayoutData( data );

        String[] values = HistoryUtils.load( VALUE_HISTORY_DIALOGSETTING_KEY );
        quickSearchValueCombo = BaseWidgetUtils.createCombo( innerComposite, values, -1, 1 );
        quickSearchValuePP = new ListContentProposalProvider( values );
        new ExtendedContentAssistCommandAdapter( quickSearchValueCombo, new ComboContentAdapter(), quickSearchValuePP,
            null, null, true );
        quickSearchValueCombo.addSelectionListener( new SelectionAdapter()
        {
            public void widgetDefaultSelected( SelectionEvent e )
            {
View Full Code Here

TOP

Related Classes of org.eclipse.jface.fieldassist.ComboContentAdapter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.