fr$2.java
2.27 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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
import android.support.v4.content.ParallelExecutorCompat;
import android.support.v7.util.ThreadUtil.BackgroundCallback;
import android.support.v7.util.TileList.Tile;
import android.util.Log;
import java.util.concurrent.Executor;
import java.util.concurrent.atomic.AtomicBoolean;
final class fr$2
implements ThreadUtil.BackgroundCallback<T>
{
final fr.a a = new fr.a();
AtomicBoolean b = new AtomicBoolean(false);
private final Executor e = ParallelExecutorCompat.getParallelExecutor();
private Runnable f = new Runnable()
{
public final void run()
{
for (;;)
{
fr.b localb = fr.2.this.a.a();
if (localb == null) {
break;
}
switch (localb.a)
{
default:
Log.e("ThreadUtil", "Unsupported message, what=" + localb.a);
break;
case 1:
fr.2.this.a.a(1);
fr.2.this.c.refresh(localb.b);
break;
case 2:
fr.2.this.a.a(2);
fr.2.this.a.a(3);
fr.2.this.c.updateRange(localb.b, localb.c, localb.d, localb.e, localb.f);
break;
case 3:
fr.2.this.c.loadTile(localb.b, localb.c);
break;
case 4:
fr.2.this.c.recycleTile((TileList.Tile)localb.g);
}
}
fr.2.this.b.set(false);
}
};
fr$2(fr paramfr, ThreadUtil.BackgroundCallback paramBackgroundCallback) {}
private void a()
{
if (this.b.compareAndSet(false, true)) {
this.e.execute(this.f);
}
}
private void a(fr.b paramb)
{
this.a.b(paramb);
a();
}
private void b(fr.b paramb)
{
this.a.a(paramb);
a();
}
public final void loadTile(int paramInt1, int paramInt2)
{
a(fr.b.a(3, paramInt1, paramInt2));
}
public final void recycleTile(TileList.Tile<T> paramTile)
{
a(fr.b.a(4, 0, paramTile));
}
public final void refresh(int paramInt)
{
b(fr.b.a(1, paramInt, null));
}
public final void updateRange(int paramInt1, int paramInt2, int paramInt3, int paramInt4, int paramInt5)
{
b(fr.b.a(2, paramInt1, paramInt2, paramInt3, paramInt4, paramInt5, null));
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/fr$2.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/