Custom Web View Presentation
By default, Netmera provides a visually appealing user interface for displaying web view content in push/pop-up notification actions. However, if you want to implement your own web view presentation flow, follow these steps:
Step 1: Implement a Receiver Class
Create a class extending NetmeraWebContentBroadcastReceiver
and implement its abstract onShow
method. Whenever a show web content action occurs, this onShow
method will be called. In this method, you should start your flow where web view will be used to show the content. Check code below for sample receiver class.
Step 2: Add Receiver Class to AndroidManifest
Add created receiver class to your manifest with com.netmera.web.content.SHOW
action. Here is the sample,
Step 3: Let Netmera Handle Received Content
Finally, inform Netmera to display the received content in your web view.
If you want to listen url loading actions inside your web view, instead of the previous code you should call handle method as follows,
Last updated