Example usage for com.vaadin.ui Notification DELAY_NONE

List of usage examples for com.vaadin.ui Notification DELAY_NONE

Introduction

In this page you can find the example usage for com.vaadin.ui Notification DELAY_NONE.

Prototype

int DELAY_NONE

To view the source code for com.vaadin.ui Notification DELAY_NONE.

Click Source Link

Usage

From source file:com.expressui.core.view.form.EntityForm.java

License:Open Source License

/**
 * Shows notification message that save was unsuccessful because of a conflict with another user's changes.
 *//*from   w  w w .  j  a va 2 s .co m*/
public void showSaveConflictMessage() {
    Window.Notification notification = new Window.Notification(
            uiMessageSource.getMessage("entityForm.saveConflictError"), Window.Notification.TYPE_ERROR_MESSAGE);
    notification.setDelayMsec(Window.Notification.DELAY_NONE);
    notification.setPosition(Window.Notification.POSITION_CENTERED);
    getMainApplication().showNotification(notification);
}

From source file:com.expressui.core.view.form.EntityForm.java

License:Open Source License

/**
 * Shows notification message that save was unsuccessful because of validation error.
 *//* w  w  w .ja  v a  2s  .  co m*/
public void showSaveValidationErrorMessage() {
    Window.Notification notification = new Window.Notification(
            uiMessageSource.getMessage("entityForm.saveValidationError", new Object[] { getEntityCaption() }),
            Window.Notification.TYPE_ERROR_MESSAGE);
    notification.setDelayMsec(Window.Notification.DELAY_NONE);
    notification.setPosition(Window.Notification.POSITION_CENTERED);
    getMainApplication().showNotification(notification);
}