Examples of HintLabel


Examples of org.openfaces.component.output.HintLabel

        this.value = value;
    }

    public void textValue(ValueChangeEvent event) {
        UIComponent component = event.getComponent();
        HintLabel testComponent = (HintLabel) component.findComponent("a1");
        testComponent.setValue(event.getNewValue());
    }
View Full Code Here

Examples of org.openfaces.component.output.HintLabel

    @Override
    public void encodeEnd(FacesContext context, UIComponent component) throws IOException {
        if (!component.isRendered()) return;

        ResponseWriter writer = context.getResponseWriter();
        HintLabel hintLabel = (HintLabel) component;

        String value = Rendering.getStringValue(context, hintLabel);
        String hint = hintLabel.getHint();

        String defaultHintClass = "o_hintlabel_hint" + ' ' +
                DefaultStyles.getBackgroundColorClass() + ' ' + DefaultStyles.getTextColorClass();
        String hintClass = Styles.getCSSClass(context,
                hintLabel, hintLabel.getHintStyle(), StyleGroup.rolloverStyleGroup(), hintLabel.getHintClass(), defaultHintClass
        );

        writer.startElement("div", hintLabel);
        writeIdAttribute(context, hintLabel);

        String defaultLabelClass = Environment.isExplorer() || Environment.isSafari() ||
                Environment.isChrome() || Environment.isUndefinedBrowser()
                ? "o_hintlabel_label_ie" : "o_hintlabel_label";
        writer.writeAttribute("class", Styles.getCSSClass(context,
                hintLabel, hintLabel.getStyle(), defaultLabelClass, hintLabel.getStyleClass()), null);

        Rendering.writeStandardEvents(writer, hintLabel);

        encodeText(writer, hintLabel, value);
        if (hint != null && !hint.equals(value))
            encodeHint(context, hintLabel, hintClass, hint);

        writer.startElement("div", hintLabel);
        String clientId = component.getClientId(context);
        writer.writeAttribute("id", clientId + "::innerscripts", null);
        ScriptBuilder sb = new ScriptBuilder();
        sb.initScript(context, hintLabel, "O$.HintLabel._init",
                hintLabel.getHintTimeout(),
                hintClass,
                Rendering.getRolloverClass(context, hintLabel),
                hint != null);

        Rendering.renderInitScript(context, sb,
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.