Package io.jmix.ui
Interface WebBrowserTools
- All Known Implementing Classes:
WebBrowserToolsImpl
public interface WebBrowserTools
Utility bean to provide common functionality related to web browser.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Removes 'onbeforeunload' listener.void
Adds 'onbeforeunload' listener that prevents browser tab from closing.void
showWebPage
(String url, Map<String, Object> params) Open a web page in browser.
-
Method Details
-
showWebPage
Open a web page in browser.- Parameters:
url
- URL of the pageparams
- optional parameters.
The following parameters are recognized by Web client:target
- String value used as the target name in a window.open call in the client. This means that special values such as "_blank", "_self", "_top", "_parent" have special meaning. If not specified, "_blank" is used.-
width
- Integer value specifying the width of the browser window in pixels -
height
- Integer value specifying the height of the browser window in pixels -
border
- String value specifying the border style of the window of the browser window. Possible values are "DEFAULT", "MINIMAL", "NONE".
-
preventBrowserTabClosing
void preventBrowserTabClosing()Adds 'onbeforeunload' listener that prevents browser tab from closing. -
allowBrowserTabClosing
void allowBrowserTabClosing()Removes 'onbeforeunload' listener.
-