Package 

Object FragmentLifecycleObserver

    • Method Summary

      Modifier and Type Method Description
      final Unit registerEvent(String event, FragmentActivity activity) Register that we've started tracking an event; keep track of the fragment that was shown when the event was initially tracked
      final Unit clearRegisteredEvents() We assume that we should be dismissing on page change until the SDK is fully initialized; if once it is initialized it turns out we won't dismiss on page change, we should clear out our tracked data
      final Boolean sameFragmentVisibleForEvent(String event) We consider the same fragment to be showing for an even in three scenarios:
      • There wasn't a fragment associated with the event

      • currentFragment is null, which means there hasn't been a fragment going through onResume

      • The same fragment is currently showing as was showing when the event was tracked

      Unit onFragmentResumed(FragmentManager fm, Fragment f)
      • Methods inherited from class com.userleap.internal.FragmentLifecycleObserver

        onFragmentActivityCreated, onFragmentAttached, onFragmentCreated, onFragmentDestroyed, onFragmentDetached, onFragmentPaused, onFragmentPreAttached, onFragmentPreCreated, onFragmentSaveInstanceState, onFragmentStarted, onFragmentStopped, onFragmentViewCreated, onFragmentViewDestroyed
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • registerEvent

         final Unit registerEvent(String event, FragmentActivity activity)

        Register that we've started tracking an event; keep track of the fragment that was shown when the event was initially tracked

      • clearRegisteredEvents

         final Unit clearRegisteredEvents()

        We assume that we should be dismissing on page change until the SDK is fully initialized; if once it is initialized it turns out we won't dismiss on page change, we should clear out our tracked data

      • sameFragmentVisibleForEvent

         final Boolean sameFragmentVisibleForEvent(String event)

        We consider the same fragment to be showing for an even in three scenarios:

        • There wasn't a fragment associated with the event

        • currentFragment is null, which means there hasn't been a fragment going through onResume

        • The same fragment is currently showing as was showing when the event was tracked