HomeDocs
Skip to main content

dlt.getStatusBarHeight

Introduction​

Retrieve the status bar height.

Usage Restrictions​

Supported in the basic library from version 3.0.0 onwards.

Parameters​

Object object​

PropertyTypeDefaultRequiredDescription
successfunctionNoCallback function for a successful interface call
failfunctionNoCallback function for a failed interface call
completefunctionNoCallback function for the completion of the interface call (executed on both success and failure)

object.success Callback Function​

Parameters​

Object res​

PropertyTypeDescription
statusBarHeightnumberStatus bar height in pixels

Sample Code​

dlt.getStatusBarHeight({
success(res) {
console.log(res.statusBarHeight);
},
});
Privacy agreementDeveloper agreementcontact us: developer_private.mi@dlightek.com © 2024 MiniApp. All Rights Reserved.