Package org.eclipse.sapphire

Examples of org.eclipse.sapphire.ImageService


                   
                    if( row == null )
                    {
                        ImageProvider imageProvider = null;
                       
                        final ImageService imageService = element.service( ImageService.class );
                       
                        if( imageService != null )
                        {
                            imageProvider = new ImageProvider()
                            {
                                private Listener imageServiceListener;
                               
                                @Override
                                public ImageData image()
                                {
                                    if( this.imageServiceListener == null )
                                    {
                                        this.imageServiceListener = new Listener()
                                        {
                                            @Override
                                            public void handle( final Event event )
                                            {
                                                update( row() );
                                            }
                                        };
                                       
                                        imageService.attach( this.imageServiceListener );
                                    }
                                   
                                    return imageService.image();
                                }

                                @Override
                                public void dispose()
                                {
                                    if( this.imageServiceListener != null )
                                    {
                                        imageService.detach( this.imageServiceListener );
                                    }
                                }
                            };
                        }
                        else if( getColumnCount() == 1 )
View Full Code Here


                    {
                        list.detach( modelListener, CheckBoxGroupPropertyEditorPresentation.this.memberProperty.name() );
                       
                        for( final Element element : list )
                        {
                            final ImageService imageService = element.service( ImageService.class );
                           
                            if( imageService != null )
                            {
                                imageService.detach( CheckBoxGroupPropertyEditorPresentation.this.serviceListener );
                            }
                        }
                    }
                }
            }
View Full Code Here

            }
        }
       
        checkbox.setText( text );
       
        ImageService elementImageService = (ImageService) checkbox.getData( "ImageService" );
       
        if( elementImageService != null )
        {
            elementImageService.detach( this.serviceListener );
        }
       
        if( element != null )
        {
            elementImageService = element.service( ImageService.class );
            checkbox.setData( "ImageService", elementImageService );
           
            if( elementImageService != null )
            {
                elementImageService.attach( this.serviceListener );
            }
        }
       
        ImageData image = null;
       
        if( elementImageService != null )
        {
            image = elementImageService.image();
        }
        else
        {
            try
            {
View Full Code Here

TOP

Related Classes of org.eclipse.sapphire.ImageService

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.