Rg.plugins.popup: Animation in c# code

Created on 5 Mar 2017  路  1Comment  路  Source: rotorgames/Rg.Plugins.Popup

Hello all,

Thank your for this awesome plugin.

I'd like to implement the loginsuccess popup on my app.
I'm not doing any xaml, and I'm not finding how to translate that snippet into pure c# code :

  <pages:PopupPage.Animation>
    <animations:MoveAnimation
      PositionIn="Top"
      PositionOut="Top"/>
  </pages:PopupPage.Animation>

Where should I do that ?
I've got a page, extends popupPage and stacklayout with label as a content

Thanks.

question

Most helpful comment

@Umar3x You can do that:


public partial class YourPopupPage : PopupPage
{
    public YourPopupPage()
    {
        InitializeComponent();

        // You can set animation anywhere
        Animation = new MoveAnimation()
        {
            DurationIn = 100,
            DurationOut = 200,
            EasingIn = Easing.BounceIn,
            EasingOut = Easing.CubicIn,
            HasBackgroundAnimation = true,
            PositionIn = MoveAnimationOptions.Left,
            PositionOut = MoveAnimationOptions.Right
        };
    }
}

>All comments

@Umar3x You can do that:


public partial class YourPopupPage : PopupPage
{
    public YourPopupPage()
    {
        InitializeComponent();

        // You can set animation anywhere
        Animation = new MoveAnimation()
        {
            DurationIn = 100,
            DurationOut = 200,
            EasingIn = Easing.BounceIn,
            EasingOut = Easing.CubicIn,
            HasBackgroundAnimation = true,
            PositionIn = MoveAnimationOptions.Left,
            PositionOut = MoveAnimationOptions.Right
        };
    }
}

Was this page helpful?
0 / 5 - 0 ratings

Related issues

mshenoy83 picture mshenoy83  路  4Comments

luis-barreira picture luis-barreira  路  5Comments

luis-barreira picture luis-barreira  路  5Comments

DevendraMaran picture DevendraMaran  路  4Comments

juanmalm picture juanmalm  路  4Comments