Class Popup.FadeBehavior

java.lang.Object
net.dermetfan.gdx.scenes.scene2d.ui.Popup.Behavior.Adapter
net.dermetfan.gdx.scenes.scene2d.ui.Popup.FadeBehavior
All Implemented Interfaces:
Popup.Behavior
Enclosing class:
Popup<T extends com.badlogic.gdx.scenes.scene2d.Actor>

public static class Popup.FadeBehavior
extends Popup.Behavior.Adapter
fades in/out in show(Event, Popup)/hide(Event, Popup) using AlphaActions
  • Nested Class Summary

    Nested classes/interfaces inherited from interface net.dermetfan.gdx.scenes.scene2d.ui.Popup.Behavior

    Popup.Behavior.Adapter
  • Constructor Summary

    Constructors
    Constructor Description
    FadeBehavior()
    creates a FadeBehavior with the default values
    FadeBehavior​(float fadeDuration)  
    FadeBehavior​(float fadeInDuration, float fadeOutDuration)  
    FadeBehavior​(float fadeInDuration, float fadeOutDuration, com.badlogic.gdx.math.Interpolation fadeInInterpolation, com.badlogic.gdx.math.Interpolation fadeOutInterpolation)  
    FadeBehavior​(float fadeDuration, com.badlogic.gdx.math.Interpolation fadeInterpolation)  
    FadeBehavior​(com.badlogic.gdx.math.Interpolation fadeInterpolation)  
    FadeBehavior​(com.badlogic.gdx.math.Interpolation fadeInInterpolation, com.badlogic.gdx.math.Interpolation fadeOutInterpolation)  
  • Method Summary

    Modifier and Type Method Description
    float getFadeInDuration()  
    com.badlogic.gdx.math.Interpolation getFadeInInterpolation()  
    float getFadeOutDuration()  
    com.badlogic.gdx.math.Interpolation getFadeOutInterpolation()  
    boolean hide​(com.badlogic.gdx.scenes.scene2d.Event event, Popup popup)  
    void setFadeInDuration​(float fadeInDuration)  
    void setFadeInInterpolation​(com.badlogic.gdx.math.Interpolation fadeInInterpolation)  
    void setFadeOutDuration​(float fadeOutDuration)  
    void setFadeOutInterpolation​(com.badlogic.gdx.math.Interpolation fadeOutInterpolation)  
    boolean show​(com.badlogic.gdx.scenes.scene2d.Event event, Popup popup)  

    Methods inherited from class net.dermetfan.gdx.scenes.scene2d.ui.Popup.Behavior.Adapter

    handle

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • FadeBehavior

      public FadeBehavior()
      creates a FadeBehavior with the default values
    • FadeBehavior

      public FadeBehavior​(float fadeDuration)
      Parameters:
      fadeDuration - the fadeInDuration and #fadeOutDuration
    • FadeBehavior

      public FadeBehavior​(com.badlogic.gdx.math.Interpolation fadeInterpolation)
      Parameters:
      fadeInterpolation - the
    • FadeBehavior

      public FadeBehavior​(float fadeDuration, com.badlogic.gdx.math.Interpolation fadeInterpolation)
      Parameters:
      fadeDuration - the fadeInDuration and fadeOutDuration
      fadeInterpolation - the fadeInInterpolation and fadeOutInterpolation
    • FadeBehavior

      public FadeBehavior​(float fadeInDuration, float fadeOutDuration)
      Parameters:
      fadeInDuration - the fadeInDuration
      fadeOutDuration - the fadeOutDuration
    • FadeBehavior

      public FadeBehavior​(com.badlogic.gdx.math.Interpolation fadeInInterpolation, com.badlogic.gdx.math.Interpolation fadeOutInterpolation)
      Parameters:
      fadeInInterpolation - the fadeInInterpolation
      fadeOutInterpolation - the fadeOutInterpolation
    • FadeBehavior

      public FadeBehavior​(float fadeInDuration, float fadeOutDuration, com.badlogic.gdx.math.Interpolation fadeInInterpolation, com.badlogic.gdx.math.Interpolation fadeOutInterpolation)
      Parameters:
      fadeInDuration - the fadeInDuration
      fadeOutDuration - the fadeOutDuration
      fadeInInterpolation - the fadeInInterpolation
      fadeOutInterpolation - the fadeOutInterpolation
  • Method Details

    • show

      public boolean show​(com.badlogic.gdx.scenes.scene2d.Event event, Popup popup)
      Specified by:
      show in interface Popup.Behavior
      Overrides:
      show in class Popup.Behavior.Adapter
      Parameters:
      event - the Event to handle
      popup - the Popup this Behavior is attached to
      Returns:
      true
    • hide

      public boolean hide​(com.badlogic.gdx.scenes.scene2d.Event event, Popup popup)
      Specified by:
      hide in interface Popup.Behavior
      Overrides:
      hide in class Popup.Behavior.Adapter
      Parameters:
      event - the Event to handle
      popup - the Popup this Behavior is attached to
      Returns:
      false
    • getFadeInDuration

      public float getFadeInDuration()
      Returns:
      the fadeInDuration
    • setFadeInDuration

      public void setFadeInDuration​(float fadeInDuration)
      Parameters:
      fadeInDuration - the fadeInDuration to set
    • getFadeOutDuration

      public float getFadeOutDuration()
      Returns:
      the fadeOutDuration
    • setFadeOutDuration

      public void setFadeOutDuration​(float fadeOutDuration)
      Parameters:
      fadeOutDuration - the fadeOutDuration to set
    • getFadeInInterpolation

      public com.badlogic.gdx.math.Interpolation getFadeInInterpolation()
      Returns:
      the fadeInDuration
    • setFadeInInterpolation

      public void setFadeInInterpolation​(com.badlogic.gdx.math.Interpolation fadeInInterpolation)
      Parameters:
      fadeInInterpolation - the fadeInInterpolation to set
    • getFadeOutInterpolation

      public com.badlogic.gdx.math.Interpolation getFadeOutInterpolation()
      Returns:
      the fadeOutInterpolation
    • setFadeOutInterpolation

      public void setFadeOutInterpolation​(com.badlogic.gdx.math.Interpolation fadeOutInterpolation)
      Parameters:
      fadeOutInterpolation - the fadeOutInterpolation to set