ViewUtils.java
1.99 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
package android.support.v7.widget;
import android.graphics.Rect;
import android.os.Build.VERSION;
import android.support.annotation.RestrictTo;
import android.support.v4.view.ViewCompat;
import android.view.View;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
@RestrictTo({android.support.annotation.RestrictTo.Scope.LIBRARY_GROUP})
public class ViewUtils
{
private static Method a;
static
{
if (Build.VERSION.SDK_INT >= 18) {}
try
{
Method localMethod = View.class.getDeclaredMethod("computeFitSystemWindows", new Class[] { Rect.class, Rect.class });
a = localMethod;
if (!localMethod.isAccessible()) {
a.setAccessible(true);
}
return;
}
catch (NoSuchMethodException localNoSuchMethodException) {}
}
public static int combineMeasuredStates(int paramInt1, int paramInt2)
{
return paramInt1 | paramInt2;
}
public static void computeFitSystemWindows(View paramView, Rect paramRect1, Rect paramRect2)
{
if (a != null) {}
try
{
a.invoke(paramView, new Object[] { paramRect1, paramRect2 });
return;
}
catch (Exception paramView) {}
}
public static boolean isLayoutRtl(View paramView)
{
return ViewCompat.getLayoutDirection(paramView) == 1;
}
public static void makeOptionalFitsSystemWindows(View paramView)
{
if (Build.VERSION.SDK_INT >= 16) {}
try
{
Method localMethod = paramView.getClass().getMethod("makeOptionalFitsSystemWindows", new Class[0]);
if (!localMethod.isAccessible()) {
localMethod.setAccessible(true);
}
localMethod.invoke(paramView, new Object[0]);
return;
}
catch (IllegalAccessException paramView) {}catch (InvocationTargetException paramView) {}catch (NoSuchMethodException paramView) {}
}
}
/* Location: /home/merong/decompile/hackery-dex2jar.jar!/android/support/v7/widget/ViewUtils.class
* Java compiler version: 6 (50.0)
* JD-Core Version: 0.7.1
*/