public class

OnVisibilityChangedListenerManager

extends Object
implements OnVisibilityChangedListener
java.lang.Object
   ↳ com.pspdfkit.listeners.OnVisibilityChangedListenerManager

Class Overview

Collection of multiple OnVisibilityChangedListener objects. Calling onShow(View) and onHide(View) will dispatch on all previously added listeners.

Summary

Public Constructors
OnVisibilityChangedListenerManager()
Public Methods
void addOnVisibilityChangedListener(OnVisibilityChangedListener listener)
Adds a listener to the collection.
void clear()
Removes all previously added OnVisibilityChangedListener instances.
void onHide(View view)
Called whenever a PSPDFKit view has been hidden.
void onShow(View view)
Called whenever a PSPDFKit view has become visible.
void removeOnVisibilityChangedListener(OnVisibilityChangedListener listener)
Removes a previously added listener from the collection.
[Expand]
Inherited Methods
From class java.lang.Object
From interface com.pspdfkit.listeners.OnVisibilityChangedListener

Public Constructors

public OnVisibilityChangedListenerManager ()

Public Methods

public void addOnVisibilityChangedListener (OnVisibilityChangedListener listener)

Adds a listener to the collection.

Parameters
listener On visibility changed listener to be added.

public void clear ()

Removes all previously added OnVisibilityChangedListener instances.

public void onHide (View view)

Called whenever a PSPDFKit view has been hidden.

Parameters
view View that became hidden.

public void onShow (View view)

Called whenever a PSPDFKit view has become visible.

Parameters
view View that became visible.

public void removeOnVisibilityChangedListener (OnVisibilityChangedListener listener)

Removes a previously added listener from the collection. Once removed the listener will no longer receive visibility change events.

Parameters
listener On visibility changed listener to be added. If not found this method is no-op.