Example usage for com.google.gwt.aria.client RelevantValue ADDITIONS

List of usage examples for com.google.gwt.aria.client RelevantValue ADDITIONS

Introduction

In this page you can find the example usage for com.google.gwt.aria.client RelevantValue ADDITIONS.

Prototype

RelevantValue ADDITIONS

To view the source code for com.google.gwt.aria.client RelevantValue ADDITIONS.

Click Source Link

Usage

From source file:com.haulmont.cuba.web.toolkit.ui.client.jqueryfileupload.CubaFileUploadProgressWindow.java

License:Apache License

public CubaFileUploadProgressWindow() {
    super(false, true); // no autohide, modal
    // Different style of shadow for windows

    Roles.getDialogRole().set(getElement());
    Roles.getDialogRole().setAriaRelevantProperty(getElement(), RelevantValue.ADDITIONS);

    constructDOM();//from   w w  w  .ja v a 2s .c  o m
}

From source file:com.vaadin.client.ApplicationConnection.java

License:Apache License

public void init(WidgetSet widgetSet, ApplicationConfiguration cnf) {
    getLogger().info("Starting application " + cnf.getRootPanelId());
    getLogger().info("Using theme: " + cnf.getThemeName());

    getLogger().info("Vaadin application servlet version: " + cnf.getServletVersion());

    if (!cnf.getServletVersion().equals(Version.getFullVersion())) {
        getLogger().severe("Warning: your widget set seems to be built with a different "
                + "version than the one used on server. Unexpected " + "behavior may occur.");
    }/*from ww  w.java 2s.c o m*/

    this.widgetSet = widgetSet;
    configuration = cnf;

    layoutManager.setConnection(this);
    loadingIndicator.setConnection(this);
    serverRpcQueue.setConnection(this);
    messageHandler.setConnection(this);
    messageSender.setConnection(this);

    ComponentLocator componentLocator = new ComponentLocator(this);

    String appRootPanelName = cnf.getRootPanelId();
    // remove the end (window name) of autogenerated rootpanel id
    appRootPanelName = appRootPanelName.replaceFirst("-\\d+$", "");

    initializeTestbenchHooks(componentLocator, appRootPanelName);

    initializeClientHooks();

    uIConnector.init(cnf.getRootPanelId(), this);

    // Connection state handler preloads the reconnect dialog, which uses
    // overlay container. This in turn depends on VUI being attached
    // (done in uiConnector.init)
    connectionStateHandler.setConnection(this);

    tooltip.setOwner(uIConnector.getWidget());

    getLoadingIndicator().show();

    heartbeat.init(this);

    // Ensure the overlay container is added to the dom and set as a live
    // area for assistive devices
    Element overlayContainer = VOverlay.getOverlayContainer(this);
    Roles.getAlertRole().setAriaLiveProperty(overlayContainer, LiveValue.ASSERTIVE);
    VOverlay.setOverlayContainerLabel(this, getUIConnector().getState().overlayContainerLabel);
    Roles.getAlertRole().setAriaRelevantProperty(overlayContainer, RelevantValue.ADDITIONS);
}

From source file:com.vaadin.client.ui.VWindow.java

License:Apache License

public VWindow() {
    super(false, false, true); // no autohide, not modal, shadow
    // Different style of shadow for windows
    setShadowStyle("window");

    Roles.getDialogRole().set(getElement());
    Roles.getDialogRole().setAriaRelevantProperty(getElement(), RelevantValue.ADDITIONS);

    constructDOM();/* ww w.  j  a v a  2s .c  o  m*/
    contentPanel.addScrollHandler(this);
    contentPanel.addKeyDownHandler(this);
    contentPanel.addFocusHandler(this);
    contentPanel.addBlurHandler(this);
}

From source file:com.vaadin.client.VTooltip.java

License:Apache License

/**
 * Used to show tooltips; usually used via the singleton in
 * {@link ApplicationConnection}. NOTE that #setOwner(Widget)} should be
 * called after instantiating./*from   ww  w  .j  a  v  a 2  s.  com*/
 * 
 * @see ApplicationConnection#getVTooltip()
 */
public VTooltip() {
    super(false, false, true);
    setStyleName(CLASSNAME);
    FlowPanel layout = new FlowPanel();
    setWidget(layout);
    layout.add(em);
    DOM.setElementProperty(description, "className", CLASSNAME + "-text");
    DOM.appendChild(layout.getElement(), description);
    setSinkShadowEvents(true);

    // When a tooltip is shown, the content of the tooltip changes. With a
    // tooltip being a live-area, this change is notified to a assistive
    // device.
    Roles.getTooltipRole().set(getElement());
    Roles.getTooltipRole().setAriaLiveProperty(getElement(), LiveValue.ASSERTIVE);
    Roles.getTooltipRole().setAriaRelevantProperty(getElement(), RelevantValue.ADDITIONS);

    // Tooltip needs to be on top of other VOverlay elements.
    setZIndex(VOverlay.Z_INDEX + 1);
}