BrowserLifecycleObserver

Implement this interface and contribute it as a multibinding if you want to get callbacks about the lifecycle of the DDG Browser application.

Functions

Link copied to clipboard
open fun onBackground()

Called every time the application is backgrounded

Link copied to clipboard
open fun onClose()

Called when the application is closed. Close means that the application does not have any activity in STARTED state, however it may have activities in CREATED state. Examples are:

Link copied to clipboard
open fun onExit()

Called when the application exits. Exit means that the application does NOT have any activity in CREATED state. This call will always follow the BrowserLifecycleObserver.onClose call

Link copied to clipboard
open fun onForeground()

Called every time the application is foregrounded

Link copied to clipboard
open fun onOpen(isFreshLaunch: Boolean)

Called once when the application is opened. isFreshLaunch will be true if it is a fresh launch, false otherwise