Example usage for com.vaadin.client.metadata ConnectorBundleLoader EAGER_BUNDLE_NAME

List of usage examples for com.vaadin.client.metadata ConnectorBundleLoader EAGER_BUNDLE_NAME

Introduction

In this page you can find the example usage for com.vaadin.client.metadata ConnectorBundleLoader EAGER_BUNDLE_NAME.

Prototype

String EAGER_BUNDLE_NAME

To view the source code for com.vaadin.client.metadata ConnectorBundleLoader EAGER_BUNDLE_NAME.

Click Source Link

Usage

From source file:org.vaadin.alump.offlinebuilder.client.BuilderOfflineMode.java

License:Open Source License

@Override
protected void buildDefaultContent() {
    // Make sure metadata is loaded
    ConnectorBundleLoader.get().loadBundle(ConnectorBundleLoader.EAGER_BUNDLE_NAME, null);

    OfflineConnection.markOffline();/*from   w w  w  .  jav a 2 s.  co  m*/

    getPanel().clear();
    if (rootConnector == null) {
        rootConnector = GWT.create(ORootConnector.class);
    }

    if (rootConnector != null) {
        Widget rootWidget = rootConnector.getWidget();
        if (rootWidget != null) {
            getPanel().add(rootWidget);
            getOfflineFactory().readRootState(rootConnector);
        } else {
            HTML errorLabel = new HTML();
            errorLabel.setHTML("<h1>FAIL no root widget</h1>");
            getPanel().add(errorLabel);
        }
    } else {
        HTML errorLabel = new HTML();
        errorLabel.setHTML("<h1>FAIL to root connector</h1>");
        getPanel().add(errorLabel);
    }
}