showOrRestorePopOver

fun showOrRestorePopOver(fragment: Fragment, anchorView: View, request: TtPopOverHandler.Request, onDismissListener: (String) -> Unit? = null, onTouchOutsideListener: (String) -> Unit? = null): TtPopOverHandler

Shows the popover with given fragment as its parent. If a popover has been shown before in this fragment, and is not dismissed yet, then the previous popover is re-used. To show a popover with different content, the previous popover must be dismissed by calling TtPopOverHandler.dismissPopOver, or auto-dismissed with Request.autoDismissTimeout.

Parameters

fragment

The fragment that needs to show a popover.

anchorView

The anchor view.

request

The request that contains all data necessary to show a popover.

onDismissListener

The listener to be called when a popover is dismissed. Default value is null. The tag of the Request that was used to show the popover is passed as an argument.

onTouchOutsideListener

The listener to be called when a touch even took place outside the popover. Default value is null. The tag of the Request that was used to show the popover is passed as an argument.