- Tutorials:
stbWebWindow provides API to a web window functionality.
Methods
(static) windowId() → {number}
Get window ID.
Returns:
id
- Type
- number
(static) messageSend(windowId, message, dataopt)
- Since:
- 0.2.18
Send message "message
" with data "data
" to window ID "windowId
".
Message can be handled using callback stbEvent.onMessage(data)
which should be defined in target window.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
windowId |
number | receiver |
|
message |
string | id of the message |
|
data |
string |
<optional> |
message text |
(static) messageBroadcast(message, data)
- Since:
- 0.2.18
Send message "message
" with data "data
" to all existed windows.
Message can be handled using callback stbEvent.onBroadcastMessage(data)
Parameters:
Name | Type | Description |
---|---|---|
message |
string | |
data |
string |
(static) close()
- Since:
- 0.2.16
Close window
(static) SendVirtualKeypress(unicodeText, key)
- Since:
- 0.2.18
Generate virtual key event using Unicode text "unicodeText
" and QT key code "key
".
Exists only in virtual keyboard window.
Parameters:
Name | Type | Description |
---|---|---|
unicodeText |
string | |
key |
number |
(static) SetFullScreenMode(mode)
- Since:
- 0.2.18
Set full screen mode for dedicated "Wild Web" window.
Exists only in WebFace window.
Parameters:
Name | Type | Description | ||||||
---|---|---|---|---|---|---|---|---|
mode |
boolean | possible values:
|
(static) SetZoomFactor(ratio)
- Since:
- 0.2.16
Set zoom ratio for embedded web browser.
Exists only in WebFace window.
Parameters:
Name | Type | Description |
---|---|---|
ratio |
number | zoom ratio, percent [10..1000] |
(static) getCurrentUrl() → {string}
- Since:
- 0.2.16
Get currently opened URL.
Exists only in WebFace window.
Returns:
- Type
- string
(static) NavigateBack()
- Since:
- 0.2.16
Go back in the navigation history.
Defined only for dedicated "Wild Web" window.
Exists only in WebFace window.
(static) NavigateForward()
- Since:
- 0.2.16
Go forward in the navigation history.
Defined only for dedicated "Wild Web" window.
Exists only in WebFace window.
(static) ReloadDocument()
- Since:
- 0.2.16
Reload current web document.
Exists only in WebFace window.
(static) StopLoading()
- Since:
- 0.2.16
Cancel loading web document.
Exists only in WebFace window.
(static) FocusTopWindow()
- Since:
- 0.2.16
- Deprecated:
- since 0.2.18
Give the focus to the top web browser frame.
Exists only in WebFace window.
(static) FocusMiddleWindow()
- Since:
- 0.2.16
- Deprecated:
- since 0.2.18
Give the focus to the main web browser frame.
Exists only in WebFace window.