com.vaadin.client.ui
Class VNotification
java.lang.Object
PopupPanel
com.vaadin.client.widgets.Overlay
com.vaadin.client.ui.VOverlay
com.vaadin.client.ui.VNotification
- All Implemented Interfaces:
- com.google.gwt.event.logical.shared.CloseHandler<PopupPanel>, com.google.gwt.event.shared.EventHandler
public class VNotification
- extends VOverlay
|
Constructor Summary |
VNotification()
Default constructor. |
VNotification(int delayMsec)
Deprecated. Use static #createNotification(int) instead to enable
GWT deferred binding. |
VNotification(int delayMsec,
int fadeMsec,
int startOpacity)
Deprecated. Use static #createNotification(int, int, int) instead
to enable GWT deferred binding. |
|
Method Summary |
void |
addEventListener(VNotification.EventListener listener)
|
static void |
bringNotificationsToFront()
Moves currently visible notifications to the top of the event preview
stack. |
static VNotification |
createNotification(int delayMsec,
Widget owner)
|
static java.lang.String |
getDependentStyle(ApplicationConnection client,
java.lang.String style)
Meant for internal usage only. |
void |
hide()
|
protected void |
hideAfterDelay()
|
void |
onBrowserEvent(Event event)
|
boolean |
onEventPreview(Event event)
|
protected void |
onPreviewNativeEvent(NativePreviewEvent event)
|
void |
removeEventListener(VNotification.EventListener listener)
|
void |
setPosition(com.vaadin.shared.Position position)
|
void |
show()
|
void |
show(com.vaadin.shared.Position position)
|
void |
show(com.vaadin.shared.Position position,
java.lang.String style)
|
void |
show(java.lang.String style)
|
void |
show(Widget widget,
com.vaadin.shared.Position position,
java.lang.String style)
|
static void |
showError(ApplicationConnection connection,
java.lang.String caption,
java.lang.String message,
java.lang.String details,
java.lang.String url)
Shows an error notification and redirects the user to the given URL when
she clicks on the notification. |
static void |
showNotification(ApplicationConnection client,
UIDL notification)
|
| Methods inherited from class com.vaadin.client.widgets.Overlay |
center, getOwner, hide, hide, isShadowEnabled, isShimElementEnabled, isSinkShadowEvents, needsShimElement, onAttach, onClose, onDetach, positionOrSizeUpdated, setHeight, setOwner, setPopupPosition, setShadowEnabled, setShadowStyle, setSinkShadowEvents, setVisible, setWidth, setZIndex, sinkEvents, updateShadowSizeAndPosition, useShadowDiv |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface com.google.gwt.event.logical.shared.CloseHandler |
onClose |
CENTERED
public static final com.vaadin.shared.Position CENTERED
CENTERED_TOP
public static final com.vaadin.shared.Position CENTERED_TOP
CENTERED_BOTTOM
public static final com.vaadin.shared.Position CENTERED_BOTTOM
TOP_LEFT
public static final com.vaadin.shared.Position TOP_LEFT
TOP_RIGHT
public static final com.vaadin.shared.Position TOP_RIGHT
BOTTOM_LEFT
public static final com.vaadin.shared.Position BOTTOM_LEFT
BOTTOM_RIGHT
public static final com.vaadin.shared.Position BOTTOM_RIGHT
CAPTION
public static final java.lang.String CAPTION
- See Also:
- Constant Field Values
DESCRIPTION
public static final java.lang.String DESCRIPTION
- See Also:
- Constant Field Values
DETAILS
public static final java.lang.String DETAILS
- See Also:
- Constant Field Values
ASSISTIVE
public static final com.vaadin.shared.Position ASSISTIVE
- Position that is only accessible for assistive devices, invisible for
visual users.
DELAY_FOREVER
public static final int DELAY_FOREVER
- See Also:
- Constant Field Values
DELAY_NONE
public static final int DELAY_NONE
- See Also:
- Constant Field Values
STYLE_SYSTEM
public static final java.lang.String STYLE_SYSTEM
- See Also:
- Constant Field Values
VNotification
public VNotification()
- Default constructor. You should use GWT.create instead.
VNotification
@Deprecated
public VNotification(int delayMsec)
- Deprecated. Use static
#createNotification(int) instead to enable
GWT deferred binding.
- Parameters:
delayMsec -
VNotification
@Deprecated
public VNotification(int delayMsec,
int fadeMsec,
int startOpacity)
- Deprecated. Use static
#createNotification(int, int, int) instead
to enable GWT deferred binding.
- Parameters:
delayMsec - fadeMsec - startOpacity -
show
public void show()
- Overrides:
show in class Overlay
show
public void show(java.lang.String style)
show
public void show(com.vaadin.shared.Position position)
show
public void show(Widget widget,
com.vaadin.shared.Position position,
java.lang.String style)
show
public void show(com.vaadin.shared.Position position,
java.lang.String style)
hideAfterDelay
protected void hideAfterDelay()
hide
public void hide()
- Overrides:
hide in class Overlay
setPosition
public void setPosition(com.vaadin.shared.Position position)
onBrowserEvent
public void onBrowserEvent(Event event)
onPreviewNativeEvent
protected void onPreviewNativeEvent(NativePreviewEvent event)
onEventPreview
public boolean onEventPreview(Event event)
addEventListener
public void addEventListener(VNotification.EventListener listener)
removeEventListener
public void removeEventListener(VNotification.EventListener listener)
showNotification
public static void showNotification(ApplicationConnection client,
UIDL notification)
getDependentStyle
public static java.lang.String getDependentStyle(ApplicationConnection client,
java.lang.String style)
- Meant for internal usage only.
- Parameters:
client - application connectionstyle - the dependent style name
- Returns:
- the given dependent style name prefixed with current notification
primary style
- Since:
- 7.5.0
createNotification
public static VNotification createNotification(int delayMsec,
Widget owner)
bringNotificationsToFront
public static void bringNotificationsToFront()
- Moves currently visible notifications to the top of the event preview
stack. Can be called when opening other overlays such as subwindows to
ensure the notifications receive the events they need and don't linger
indefinitely. See #7136.
TODO Should this be a generic Overlay feature instead?
showError
public static void showError(ApplicationConnection connection,
java.lang.String caption,
java.lang.String message,
java.lang.String details,
java.lang.String url)
- Shows an error notification and redirects the user to the given URL when
she clicks on the notification.
If both message and caption are null, redirects the user to the url
immediately
- Parameters:
connection - A reference to the ApplicationConnectioncaption - The caption for the error or null to exclude the captionmessage - The message for the error or null to exclude the messagedetails - A details message or null to exclude the detailsurl - A url to redirect to after the user clicks the error
notification- Since:
- 7.5.1
Copyright © 2000-2014 Vaadin Ltd. All Rights Reserved.