AvatarStyleAdapter.java
1.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
package com.bitstrips.imoji.abv3.style;
import android.support.v4.view.PagerAdapter;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.bitstrips.imoji.abv3.model.AvatarStylePreviouslySaved;
import com.bitstrips.imoji.persistence.MediaCache;
import java.util.List;
public class AvatarStyleAdapter
extends PagerAdapter
{
private final List<Integer> a;
private final MediaCache b;
private final AvatarStylePreviouslySaved c;
public AvatarStyleAdapter(List<Integer> paramList, MediaCache paramMediaCache, AvatarStylePreviouslySaved paramAvatarStylePreviouslySaved)
{
this.a = paramList;
this.b = paramMediaCache;
this.c = paramAvatarStylePreviouslySaved;
}
public void destroyItem(ViewGroup paramViewGroup, int paramInt, Object paramObject)
{
paramViewGroup.removeView(((AvatarStyleViewHolder)paramObject).getView());
}
public int getCount()
{
return this.a.size();
}
public Object instantiateItem(ViewGroup paramViewGroup, int paramInt)
{
View localView = LayoutInflater.from(paramViewGroup.getContext()).inflate(2130903207, paramViewGroup, false);
paramViewGroup.addView(localView);
localView.setTag(Integer.valueOf(paramInt));
paramInt = ((Integer)this.a.get(paramInt)).intValue();
paramViewGroup = new AvatarStyleViewHolder(localView, this.b, this.c.getStyleTemplateUrl(paramInt));
paramViewGroup.setAvatarImage();
return paramViewGroup;
}
public boolean isViewFromObject(View paramView, Object paramObject)
{
return paramView == ((AvatarStyleViewHolder)paramObject).getView();
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/com/bitstrips/imoji/abv3/style/AvatarStyleAdapter.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/