Examples of SwtResourceCache


Examples of org.eclipse.sapphire.ui.forms.swt.SwtResourceCache

        if( this.control.isDisposed() )
        {
            return;
        }
       
        final SwtResourceCache imageCache = this.part.getSwtResourceCache();
       
        if( this.assistContext != null )
        {
            if( this.problem != null )
            {
                final String fieldDecorationId;
               
                switch( this.problem.severity() )
                {
                    case ERROR:
                    {
                        fieldDecorationId = FieldDecorationRegistry.DEC_ERROR;
                        break;
                    }
                    case WARNING:
                    {
                        fieldDecorationId = FieldDecorationRegistry.DEC_WARNING;
                        break;
                    }
                    default:
                    {
                        throw new IllegalStateException();
                    }
                }
               
                final FieldDecoration fieldDecoration
                    = FieldDecorationRegistry.getDefault().getFieldDecoration( fieldDecorationId );
           
                this.control.setImage( fieldDecoration.getImage() );
            }
            else
            {
                if( this.mouseOverEditorControl )
                {
                    this.control.setImage( imageCache.image( IMG_ASSIST ) );
                }
                else
                {
                    this.control.setImage( imageCache.image( IMG_ASSIST_FAINT ) );
                }
            }
           
            this.control.setVisible( true );
            this.control.setCursor( Display.getCurrent().getSystemCursor( SWT.CURSOR_HAND ) );
        }
        else
        {
            this.control.setVisible( false );
            this.control.setImage( imageCache.image( IMG_ASSIST_CLEAR ) );
            this.control.setCursor( null );
        }
    }
View Full Code Here

Examples of org.eclipse.sapphire.ui.forms.swt.SwtResourceCache

    public SwtResourceCache getSwtResourceCache()
    {
        if( this.imageCache == null )
        {
            this.imageCache = ( this.parent == null ? new SwtResourceCache() : this.parent.getSwtResourceCache() );
        }
       
        return this.imageCache;
    }
View Full Code Here

Examples of org.eclipse.sapphire.ui.forms.swt.SwtResourceCache

    private boolean ignorePageChange;

    public SapphireEditor()
    {
        this.pluginId = FrameworkUtil.getBundle( getClass() ).getSymbolicName();
        this.imageCache = new SwtResourceCache();
        this.outline = null;
        this.actionsManager = new SapphireActionManager( this, getActionContexts() );
    }
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.