br.java
6.33 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
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
import android.annotation.TargetApi;
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Rect;
import android.graphics.drawable.Drawable;
import android.support.annotation.RequiresApi;
import android.support.v4.view.ViewCompat;
import android.view.MotionEvent;
import android.view.View;
import android.view.ViewGroup;
import android.view.ViewParent;
import java.lang.reflect.Method;
import java.util.ArrayList;
@TargetApi(14)
@RequiresApi(14)
class br
{
protected br.a a = new br.a(paramContext, paramViewGroup, paramView, this);
br(Context paramContext, ViewGroup paramViewGroup, View paramView) {}
public static br c(View paramView)
{
Object localObject = paramView;
label27:
int j;
int i;
if (localObject != null) {
if ((((View)localObject).getId() == 16908290) && ((localObject instanceof ViewGroup)))
{
localObject = (ViewGroup)localObject;
if (localObject == null) {
break label114;
}
j = ((ViewGroup)localObject).getChildCount();
i = 0;
}
}
for (;;)
{
if (i >= j) {
break label100;
}
View localView = ((ViewGroup)localObject).getChildAt(i);
if ((localView instanceof br.a))
{
return ((br.a)localView).e;
if (!(((View)localObject).getParent() instanceof ViewGroup)) {
break;
}
localObject = (ViewGroup)((View)localObject).getParent();
break;
localObject = null;
break label27;
}
i += 1;
}
label100:
return new bq(((ViewGroup)localObject).getContext(), (ViewGroup)localObject, paramView);
label114:
return null;
}
public final void a(Drawable paramDrawable)
{
br.a locala = this.a;
if (locala.d == null) {
locala.d = new ArrayList();
}
if (!locala.d.contains(paramDrawable))
{
locala.d.add(paramDrawable);
locala.invalidate(paramDrawable.getBounds());
paramDrawable.setCallback(locala);
}
}
public final void b(Drawable paramDrawable)
{
br.a locala = this.a;
if (locala.d != null)
{
locala.d.remove(paramDrawable);
locala.invalidate(paramDrawable.getBounds());
paramDrawable.setCallback(null);
}
}
static final class a
extends ViewGroup
{
static Method a;
ViewGroup b;
View c;
ArrayList<Drawable> d = null;
br e;
static
{
try
{
a = ViewGroup.class.getDeclaredMethod("invalidateChildInParentFast", new Class[] { Integer.TYPE, Integer.TYPE, Rect.class });
return;
}
catch (NoSuchMethodException localNoSuchMethodException) {}
}
a(Context paramContext, ViewGroup paramViewGroup, View paramView, br parambr)
{
super();
this.b = paramViewGroup;
this.c = paramView;
setRight(paramViewGroup.getWidth());
setBottom(paramViewGroup.getHeight());
paramViewGroup.addView(this);
this.e = parambr;
}
public final void a(View paramView)
{
if ((paramView.getParent() instanceof ViewGroup))
{
ViewGroup localViewGroup = (ViewGroup)paramView.getParent();
if ((localViewGroup != this.b) && (localViewGroup.getParent() != null))
{
int[] arrayOfInt1 = new int[2];
int[] arrayOfInt2 = new int[2];
localViewGroup.getLocationOnScreen(arrayOfInt1);
this.b.getLocationOnScreen(arrayOfInt2);
ViewCompat.offsetLeftAndRight(paramView, arrayOfInt1[0] - arrayOfInt2[0]);
ViewCompat.offsetTopAndBottom(paramView, arrayOfInt1[1] - arrayOfInt2[1]);
}
localViewGroup.removeView(paramView);
if (paramView.getParent() != null) {
localViewGroup.removeView(paramView);
}
}
super.addView(paramView, getChildCount() - 1);
}
public final void b(View paramView)
{
super.removeView(paramView);
if ((getChildCount() == 0) && ((this.d == null) || (this.d.size() == 0))) {}
for (int i = 1;; i = 0)
{
if (i != 0) {
this.b.removeView(this);
}
return;
}
}
protected final void dispatchDraw(Canvas paramCanvas)
{
int[] arrayOfInt1 = new int[2];
int[] arrayOfInt2 = new int[2];
getParent();
this.b.getLocationOnScreen(arrayOfInt1);
this.c.getLocationOnScreen(arrayOfInt2);
paramCanvas.translate(arrayOfInt2[0] - arrayOfInt1[0], arrayOfInt2[1] - arrayOfInt1[1]);
paramCanvas.clipRect(new Rect(0, 0, this.c.getWidth(), this.c.getHeight()));
super.dispatchDraw(paramCanvas);
if (this.d == null) {}
for (int i = 0;; i = this.d.size())
{
int j = 0;
while (j < i)
{
((Drawable)this.d.get(j)).draw(paramCanvas);
j += 1;
}
}
}
public final boolean dispatchTouchEvent(MotionEvent paramMotionEvent)
{
return false;
}
public final ViewParent invalidateChildInParent(int[] paramArrayOfInt, Rect paramRect)
{
if (this.b != null)
{
paramRect.offset(paramArrayOfInt[0], paramArrayOfInt[1]);
if ((this.b instanceof ViewGroup))
{
paramArrayOfInt[0] = 0;
paramArrayOfInt[1] = 0;
int[] arrayOfInt1 = new int[2];
int[] arrayOfInt2 = new int[2];
int[] arrayOfInt3 = new int[2];
getParent();
this.b.getLocationOnScreen(arrayOfInt2);
this.c.getLocationOnScreen(arrayOfInt3);
arrayOfInt3[0] -= arrayOfInt2[0];
arrayOfInt3[1] -= arrayOfInt2[1];
paramRect.offset(arrayOfInt1[0], arrayOfInt1[1]);
return super.invalidateChildInParent(paramArrayOfInt, paramRect);
}
invalidate(paramRect);
}
return null;
}
public final void invalidateDrawable(Drawable paramDrawable)
{
invalidate(paramDrawable.getBounds());
}
protected final void onLayout(boolean paramBoolean, int paramInt1, int paramInt2, int paramInt3, int paramInt4) {}
protected final boolean verifyDrawable(Drawable paramDrawable)
{
return (super.verifyDrawable(paramDrawable)) || ((this.d != null) && (this.d.contains(paramDrawable)));
}
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/br.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/