Package org.eclipse.sapphire

Examples of org.eclipse.sapphire.Element.parent()


               
                protected boolean draggable( final MasterDetailsContentNodePart node )
                {
                    final Element element = node.getModelElement();
                   
                    if( element.parent() instanceof ElementList && node.controls( element ) )
                    {
                        return true;
                    }
                   
                    return false;
View Full Code Here


                           
                            if( precedingNode != null )
                            {
                                final Element precedingElement = precedingNode.getModelElement();
                               
                                if( precedingElement.parent() instanceof ElementList && precedingNode.controls( precedingElement ) )
                                {
                                    ok = true;
                                }
                            }
                           
View Full Code Here

                           
                            if( ! ok && trailingNode != null )
                            {
                                final Element trailingElement = trailingNode.getModelElement();
                               
                                if( trailingElement.parent() instanceof ElementList && trailingNode.controls( trailingElement ) )
                                {
                                    ok = true;
                                }
                            }
                           
View Full Code Here

                   
                    if( precedingNode != null )
                    {
                        final Element precedingElement = precedingNode.getModelElement();
                       
                        if( precedingElement.parent() instanceof ElementList && ! precedingElement.parent().definition().isReadOnly() &&
                            precedingNode.controls( precedingElement ) )
                        {
                            list = (ElementList<?>) precedingElement.parent();
                           
                            final Set<ElementType> possibleListElementTypes = list.definition().service( PossibleTypesService.class ).types();
View Full Code Here

                   
                    if( precedingNode != null )
                    {
                        final Element precedingElement = precedingNode.getModelElement();
                       
                        if( precedingElement.parent() instanceof ElementList && ! precedingElement.parent().definition().isReadOnly() &&
                            precedingNode.controls( precedingElement ) )
                        {
                            list = (ElementList<?>) precedingElement.parent();
                           
                            final Set<ElementType> possibleListElementTypes = list.definition().service( PossibleTypesService.class ).types();
View Full Code Here

                        final Element precedingElement = precedingNode.getModelElement();
                       
                        if( precedingElement.parent() instanceof ElementList && ! precedingElement.parent().definition().isReadOnly() &&
                            precedingNode.controls( precedingElement ) )
                        {
                            list = (ElementList<?>) precedingElement.parent();
                           
                            final Set<ElementType> possibleListElementTypes = list.definition().service( PossibleTypesService.class ).types();
                           
                            for( final ElementData droppedElement : droppedElements )
                            {
View Full Code Here

                   
                    if( list == null && trailingNode != null )
                    {
                        final Element trailingElement = trailingNode.getModelElement();
                       
                        if( trailingElement.parent() instanceof ElementList && ! trailingElement.parent().definition().isReadOnly() &&
                            trailingNode.controls( trailingElement ) )
                        {
                            list = (ElementList<?>) trailingElement.parent();
                           
                            final Set<ElementType> possibleListElementTypes = list.definition().service( PossibleTypesService.class ).types();
View Full Code Here

                   
                    if( list == null && trailingNode != null )
                    {
                        final Element trailingElement = trailingNode.getModelElement();
                       
                        if( trailingElement.parent() instanceof ElementList && ! trailingElement.parent().definition().isReadOnly() &&
                            trailingNode.controls( trailingElement ) )
                        {
                            list = (ElementList<?>) trailingElement.parent();
                           
                            final Set<ElementType> possibleListElementTypes = list.definition().service( PossibleTypesService.class ).types();
View Full Code Here

                        final Element trailingElement = trailingNode.getModelElement();
                       
                        if( trailingElement.parent() instanceof ElementList && ! trailingElement.parent().definition().isReadOnly() &&
                            trailingNode.controls( trailingElement ) )
                        {
                            list = (ElementList<?>) trailingElement.parent();
                           
                            final Set<ElementType> possibleListElementTypes = list.definition().service( PossibleTypesService.class ).types();
                           
                            for( final ElementData droppedElement : droppedElements )
                            {
View Full Code Here

        @Override
        public boolean applicable( final ServiceContext context )
        {
            final ValueProperty property = context.find( ValueProperty.class );
            final Element element = context.find( Element.class );
            return ( property != null && property.hasAnnotation( Unique.class ) && element.parent() instanceof ElementList );
        }
       
    }
   
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.