Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions files/markup/en/app/CreateWebSocket.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,30 @@ See Also: @CreateWebServer
*/


/** ### SetOnWsClose ###
* @brief Called when WebSocket client is close
* %cb% the WebSocket client has been close.
* $$ wbs.SetOnWsClose(callback) $$
* @param {fnc_json} callback {}
*/


/** ### SetOnWsOpen ###
* @brief Called when WebSocket client is open
* %cb% the WebSocket client has been open.
* $$ wbs.SetOnWsOpen(callback) $$
* @param {fnc_json} callback {}
*/


/** ### SetOnWsReceive ###
* @brief Called when WebSocket client receives a message
* %cb% the WebSocket client receives a message.
* $$ wbs.SetOnWsReceive(callback) $$
* @param {fnc_json} callback {}
*/



// ------------- SAMPLES -------------

Expand Down
38 changes: 38 additions & 0 deletions files/markup/en/app/GetNavBarHeight
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
// ------------- HEADER SECTION -------------


/** # GetNavBarHeight #
* @brief Get apps navbar height
* Get the navbar height of the app in pixels.
*
* See Also: @GetDisplayHeight, @GetDisplayWidth, @GetScreenHeight
* $$ app.GetNavBarHeight() $$
* @returns num_pxl
*/




// ------------- SAMPLES -------------



/**
@sample Show navbar height
function OnStart()
{
<b>var height = app.GetNavBarHeight();</b>
app.Alert( height );
}
*/



/**
@sample Python Show navbar height
from native import app

def OnStart():
height = app.GetNavBarHeight()
app.Alert(height)
*/
37 changes: 37 additions & 0 deletions files/markup/en/app/IsEdgeToEdge
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
// ------------- HEADER SECTION -------------


/** # IsEdgeToEdge #
* @brief Check if device supports edge to edge
* Checks if the device supports edge to edge.
*
* $$ app.IsEdgeToEdge() $$
* @returns bin
*/




// ------------- SAMPLES -------------



/**
@sample Check edge to edge
function OnStart()
{
<b>var isEdgeToEdge = app.IsEdgeToEdge();</b>
app.Alert( isEdgeToEdge, "is Connected:" );
}
*/



/**
@sample Python Check edge to edge
from native import app

def OnStart():
isEdgeToEdge = app.IsEdgeToEdge()
app.Alert(isEdgeToEdge, "is Connected:")
*/
3 changes: 3 additions & 0 deletions files/markup/en/intro/04 Coding Features.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,9 @@ This includes methods like setInterval and setTimeout which should be converted

**Note:** The same effect can be observed when running in a Node.js environment (using the `cfg.Node` flag)

#### cfg.EdgeToEdge
This will enable edge-to-edge feature when device supports edge-to-edge.


## app.eventSource
In callback functions of controls you can use <js nobox>app.eventSource</js> to access the callee control object without having to assign the control to a specific variable. Previously this could be achieved by using the <js nobox>this</js> keyword. This allows you to create multiple controls with the same behaviour without having to redefine callback functions for different controls:
Expand Down