Package org.richfaces.skin

Examples of org.richfaces.skin.Skin$Preferable


import org.richfaces.skin.Skin;
import org.richfaces.skin.SkinFactory;

public class SliderArrowImage extends SliderArrowBase {
  protected Object getDataToStore(FacesContext context, Object data) {
    Skin skin = SkinFactory.getInstance().getSkin(context);
   
    String skinParameter = "generalTextColor";
    String tmp = (String) skin.getParameter(context, skinParameter);
    if (null == tmp || "".equals(tmp)) {
      Skin defaultSkin = SkinFactory.getInstance().getDefaultSkin(context);
      tmp = (String) defaultSkin.getParameter(context, skinParameter);
    }
    int intValue = HtmlColor.decode(tmp ==null? "#000000":tmp).getRGB();
    // Serialize data as byte[]
    ByteBuffer buff = ByteBuffer.allocate(1*4);
    IntBuffer intBuffer = buff.asIntBuffer();
View Full Code Here


    }

    @PostConstructResource
    public final void initialize() {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);

        String skinParameter = "headerBackgroundColor";
        String tmp = (String) skin.getParameter(context, skinParameter);
        if (null == tmp || "".equals(tmp)) {
            tmp = (String) defaultSkin.getParameter(context, skinParameter);
        }
        this.setHeaderBackgroundColor(Color.decode(tmp == null ? "#224986" : tmp).getRGB());

        skinParameter = "headerGradientColor";
        tmp = (String) skin.getParameter(context, skinParameter);
        if (null == tmp || "".equals(tmp)) {
            tmp = (String) defaultSkin.getParameter(context, skinParameter);
        }
        this.setHeaderGradientColor(Color.decode(tmp == null ? "#CCCCFF" : tmp).getRGB());

        if (getSeparatorHeight() == null) {
            setSeparatorHeight(0);
View Full Code Here

    }

    @PostConstructResource
    public void initialize() {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);
        basicColor = skin.getColorParameter(context, Skin.SELECT_CONTROL_COLOR);
        if (basicColor == null) {
            basicColor = defaultSkin.getColorParameter(context, Skin.SELECT_CONTROL_COLOR);
        }
    }
View Full Code Here

    }

    @PostConstructResource
    public final void initialize() {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);

        String skinParameter = "generalTextColor";
        String tmp = (String) skin.getParameter(context, skinParameter);
        if (null == tmp || "".equals(tmp)) {
            tmp = (String) defaultSkin.getParameter(context, skinParameter);
        }

        this.setGeneralColor(Color.decode(tmp == null ? "#4A75B5" : tmp).getRGB());

        skinParameter = "tabDisabledTextColor";
        tmp = (String) skin.getParameter(context, skinParameter);
        if (null == tmp || "".equals(tmp)) {
            tmp = (String) defaultSkin.getParameter(context, skinParameter);
        }
        this.setDisabledColor(Color.decode(tmp == null ? "#6A92CF" : tmp).getRGB());
    }
View Full Code Here

        trimColorValue = getColorParameter(Skin.TRIM_COLOR);
    }

    protected Integer getColorParameter(String property) {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);

        Integer value = skin.getColorParameter(context, property);
        if (value == null) {
            value = defaultSkin.getColorParameter(context, property);
        }
        return value;
    }
View Full Code Here

    @PostConstructResource
    public void init() {
        FacesContext context = FacesContext.getCurrentInstance();

        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);

        trimColorValue = skin.getColorParameter(context, Skin.TRIM_COLOR);
        if (trimColorValue == null) {
            trimColorValue = defaultSkin.getColorParameter(context, Skin.TRIM_COLOR);
        }
    }
View Full Code Here

    }

    @PostConstructResource
    public void initialize() {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);

        topColor = skin.getColorParameter(context, topColorParam);
        bottomColor = skin.getColorParameter(context, bottomColorParam);
    }
View Full Code Here

    }

    @PostConstructResource
    public final void initialize() {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);

        this.arrowColor = skin.getColorParameter(context, disabled ? Skin.TABLE_BORDER_COLOR : Skin.GENERAL_TEXT_COLOR);
        if (this.arrowColor == null) {
            this.arrowColor = defaultSkin.getColorParameter(context, disabled ? Skin.TABLE_BORDER_COLOR
                : Skin.GENERAL_TEXT_COLOR);
        }
    }
View Full Code Here

    }

    @PostConstructResource
    public void initialize() {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);
        basicColor = skin.getColorParameter(context, colorParam);
        if (basicColor == null) {
            basicColor = defaultSkin.getColorParameter(context, colorParam);
        }
    }
View Full Code Here

    }

    @PostConstructResource
    public void initialize() {
        FacesContext context = FacesContext.getCurrentInstance();
        Skin skin = SkinFactory.getInstance(context).getSkin(context);
        Skin defaultSkin = SkinFactory.getInstance(context).getDefaultSkin(context);

        this.color = skin.getColorParameter(context, colorParam);
        if (this.color == null) {
            this.color = defaultSkin.getColorParameter(context, colorParam);
        }
    }
View Full Code Here

TOP

Related Classes of org.richfaces.skin.Skin$Preferable

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.