bo.java 5.81 KB
import android.annotation.TargetApi;
import android.support.annotation.RequiresApi;
import android.support.annotation.RestrictTo;
import android.support.transition.TransitionPort;
import android.support.transition.TransitionPort.TransitionListener;
import android.support.transition.TransitionPort.TransitionListenerAdapter;
import android.support.transition.TransitionValues;
import android.util.AndroidRuntimeException;
import android.view.View;
import android.view.ViewGroup;
import java.util.ArrayList;
import java.util.Iterator;

@TargetApi(14)
@RequiresApi(14)
public class bo
  extends TransitionPort
{
  ArrayList<TransitionPort> a = new ArrayList();
  int b;
  boolean c = false;
  boolean z = true;
  
  private bo f()
  {
    bo localbo = (bo)super.e();
    localbo.a = new ArrayList();
    int j = this.a.size();
    int i = 0;
    while (i < j)
    {
      localbo.a(((TransitionPort)this.a.get(i)).e());
      i += 1;
    }
    return localbo;
  }
  
  public final bo a(TransitionPort paramTransitionPort)
  {
    if (paramTransitionPort != null)
    {
      this.a.add(paramTransitionPort);
      paramTransitionPort.o = this;
      if (this.e >= 0L) {
        paramTransitionPort.a(this.e);
      }
    }
    return this;
  }
  
  final String a(String paramString)
  {
    String str = super.a(paramString);
    int i = 0;
    while (i < this.a.size())
    {
      str = str + "\n" + ((TransitionPort)this.a.get(i)).a(new StringBuilder().append(paramString).append("  ").toString());
      i += 1;
    }
    return str;
  }
  
  public final void a(TransitionValues paramTransitionValues)
  {
    int i = paramTransitionValues.view.getId();
    if (a(paramTransitionValues.view, i))
    {
      Iterator localIterator = this.a.iterator();
      while (localIterator.hasNext())
      {
        TransitionPort localTransitionPort = (TransitionPort)localIterator.next();
        if (localTransitionPort.a(paramTransitionValues.view, i)) {
          localTransitionPort.a(paramTransitionValues);
        }
      }
    }
  }
  
  @RestrictTo({android.support.annotation.RestrictTo.Scope.LIBRARY_GROUP})
  protected final void a(ViewGroup paramViewGroup, bp parambp1, bp parambp2)
  {
    Iterator localIterator = this.a.iterator();
    while (localIterator.hasNext()) {
      ((TransitionPort)localIterator.next()).a(paramViewGroup, parambp1, parambp2);
    }
  }
  
  @RestrictTo({android.support.annotation.RestrictTo.Scope.LIBRARY_GROUP})
  protected final void b()
  {
    if (this.a.isEmpty())
    {
      c();
      d();
    }
    for (;;)
    {
      return;
      Object localObject = new bo.a(this);
      Iterator localIterator = this.a.iterator();
      while (localIterator.hasNext()) {
        ((TransitionPort)localIterator.next()).a((TransitionPort.TransitionListener)localObject);
      }
      this.b = this.a.size();
      if (!this.z)
      {
        int i = 1;
        while (i < this.a.size())
        {
          ((TransitionPort)this.a.get(i - 1)).a(new TransitionPort.TransitionListenerAdapter()
          {
            public final void onTransitionEnd(TransitionPort paramAnonymousTransitionPort)
            {
              this.a.b();
              paramAnonymousTransitionPort.b(this);
            }
          });
          i += 1;
        }
        localObject = (TransitionPort)this.a.get(0);
        if (localObject != null) {
          ((TransitionPort)localObject).b();
        }
      }
      else
      {
        localObject = this.a.iterator();
        while (((Iterator)localObject).hasNext()) {
          ((TransitionPort)((Iterator)localObject).next()).b();
        }
      }
    }
  }
  
  public final void b(TransitionValues paramTransitionValues)
  {
    int i = paramTransitionValues.view.getId();
    if (a(paramTransitionValues.view, i))
    {
      Iterator localIterator = this.a.iterator();
      while (localIterator.hasNext())
      {
        TransitionPort localTransitionPort = (TransitionPort)localIterator.next();
        if (localTransitionPort.a(paramTransitionValues.view, i)) {
          localTransitionPort.b(paramTransitionValues);
        }
      }
    }
  }
  
  final void b(boolean paramBoolean)
  {
    super.b(paramBoolean);
    int j = this.a.size();
    int i = 0;
    while (i < j)
    {
      ((TransitionPort)this.a.get(i)).b(paramBoolean);
      i += 1;
    }
  }
  
  public final bo c(int paramInt)
  {
    switch (paramInt)
    {
    default: 
      throw new AndroidRuntimeException("Invalid parameter for TransitionSet ordering: " + paramInt);
    case 1: 
      this.z = false;
      return this;
    }
    this.z = true;
    return this;
  }
  
  @RestrictTo({android.support.annotation.RestrictTo.Scope.LIBRARY_GROUP})
  public final void c(View paramView)
  {
    super.c(paramView);
    int j = this.a.size();
    int i = 0;
    while (i < j)
    {
      ((TransitionPort)this.a.get(i)).c(paramView);
      i += 1;
    }
  }
  
  @RestrictTo({android.support.annotation.RestrictTo.Scope.LIBRARY_GROUP})
  public final void d(View paramView)
  {
    super.d(paramView);
    int j = this.a.size();
    int i = 0;
    while (i < j)
    {
      ((TransitionPort)this.a.get(i)).d(paramView);
      i += 1;
    }
  }
  
  static final class a
    extends TransitionPort.TransitionListenerAdapter
  {
    bo a;
    
    a(bo parambo)
    {
      this.a = parambo;
    }
    
    public final void onTransitionEnd(TransitionPort paramTransitionPort)
    {
      bo localbo = this.a;
      localbo.b -= 1;
      if (this.a.b == 0)
      {
        this.a.c = false;
        this.a.d();
      }
      paramTransitionPort.b(this);
    }
    
    public final void onTransitionStart(TransitionPort paramTransitionPort)
    {
      if (!this.a.c)
      {
        this.a.c();
        this.a.c = true;
      }
    }
  }
}


/* Location:              /home/merong/decompile/hackery-dex2jar.jar!/bo.class
 * Java compiler version: 6 (50.0)
 * JD-Core Version:       0.7.1
 */