use of com.kunpeng.pit.HookAnnotation in project GT by Tencent.
the class FragmentHookList_v4 method performDestroyView.
@HookAnnotation(className = "android.support.v4.app.Fragment", methodName = "performDestroyView", methodSig = "()V")
public static void performDestroyView(Object thiz) {
GTRLog.e(TAG, "performDestroyView");
long start = System.currentTimeMillis();
performDestroyView_backup(thiz);
long end = System.currentTimeMillis();
String activityClassName = "";
String activityHashCode = "";
String fragmentClassName = "";
String fragmentHashCode = "";
Object fragment = thiz;
if (fragment instanceof android.support.v4.app.Fragment) {
fragmentClassName = ((android.support.v4.app.Fragment) fragment).getClass().getName();
fragmentHashCode = "" + thiz.hashCode();
Activity activity = ((android.support.v4.app.Fragment) fragment).getActivity();
if (activity != null) {
activityClassName = activity.getClass().getName();
activityHashCode = "" + activity.hashCode();
}
}
GTRClient.pushData(new StringBuilder().append("FragmentV4.performDestroyView").append(GTConfig.separator).append(activityClassName).append(GTConfig.separator).append(activityHashCode).append(GTConfig.separator).append(fragmentClassName).append(GTConfig.separator).append(fragmentHashCode).append(GTConfig.separator).append(start).append(GTConfig.separator).append(end).toString());
}
use of com.kunpeng.pit.HookAnnotation in project GT by Tencent.
the class FragmentHookList_v4 method onHiddenChanged.
@HookAnnotation(className = "android.support.v4.app.Fragment", methodName = "onHiddenChanged", methodSig = "(Z)V")
public static void onHiddenChanged(Object thiz, boolean hidden) {
GTRLog.e(TAG, "onHiddenChanged:" + hidden);
long time = System.currentTimeMillis();
onHiddenChanged_backup(thiz, hidden);
String activityClassName = "";
String activityHashCode = "";
String fragmentClassName = "";
String fragmentHashCode = "";
Object fragment = thiz;
if (fragment instanceof android.support.v4.app.Fragment) {
fragmentClassName = ((android.support.v4.app.Fragment) fragment).getClass().getName();
fragmentHashCode = "" + thiz.hashCode();
Activity activity = ((android.support.v4.app.Fragment) fragment).getActivity();
if (activity != null) {
activityClassName = activity.getClass().getName();
activityHashCode = "" + activity.hashCode();
}
}
GTRClient.pushData(new StringBuilder().append("FragmentV4.onHiddenChanged").append(GTConfig.separator).append(activityClassName).append(GTConfig.separator).append(activityHashCode).append(GTConfig.separator).append(fragmentClassName).append(GTConfig.separator).append(fragmentHashCode).append(GTConfig.separator).append(time).append(GTConfig.separator).append(hidden).toString());
}
use of com.kunpeng.pit.HookAnnotation in project GT by Tencent.
the class FragmentHookList_v4 method performStop.
@HookAnnotation(className = "android.support.v4.app.Fragment", methodName = "performStop", methodSig = "()V")
public static void performStop(Object thiz) {
GTRLog.e(TAG, "performStop");
long start = System.currentTimeMillis();
performStop_backup(thiz);
long end = System.currentTimeMillis();
String activityClassName = "";
String activityHashCode = "";
String fragmentClassName = "";
String fragmentHashCode = "";
Object fragment = thiz;
if (fragment instanceof android.support.v4.app.Fragment) {
fragmentClassName = ((android.support.v4.app.Fragment) fragment).getClass().getName();
fragmentHashCode = "" + thiz.hashCode();
Activity activity = ((android.support.v4.app.Fragment) fragment).getActivity();
if (activity != null) {
activityClassName = activity.getClass().getName();
activityHashCode = "" + activity.hashCode();
}
}
GTRClient.pushData(new StringBuilder().append("FragmentV4.performStop").append(GTConfig.separator).append(activityClassName).append(GTConfig.separator).append(activityHashCode).append(GTConfig.separator).append(fragmentClassName).append(GTConfig.separator).append(fragmentHashCode).append(GTConfig.separator).append(start).append(GTConfig.separator).append(end).toString());
}
use of com.kunpeng.pit.HookAnnotation in project GT by Tencent.
the class FragmentHookList_v4 method setUserVisibleHint.
@HookAnnotation(className = "android.support.v4.app.Fragment", methodName = "setUserVisibleHint", methodSig = "(Z)V")
public static void setUserVisibleHint(Object thiz, boolean isVisibleToUser) {
GTRLog.e(TAG, "setUserVisibleHint:" + isVisibleToUser);
long time = System.currentTimeMillis();
setUserVisibleHint_backup(thiz, isVisibleToUser);
String activityClassName = "";
String activityHashCode = "";
String fragmentClassName = "";
String fragmentHashCode = "";
Object fragment = thiz;
if (fragment instanceof android.support.v4.app.Fragment) {
fragmentClassName = ((android.support.v4.app.Fragment) fragment).getClass().getName();
fragmentHashCode = "" + thiz.hashCode();
Activity activity = ((android.support.v4.app.Fragment) fragment).getActivity();
if (activity != null) {
activityClassName = activity.getClass().getName();
activityHashCode = "" + activity.hashCode();
}
}
GTRClient.pushData(new StringBuilder().append("FragmentV4.setUserVisibleHint").append(GTConfig.separator).append(activityClassName).append(GTConfig.separator).append(activityHashCode).append(GTConfig.separator).append(fragmentClassName).append(GTConfig.separator).append(fragmentHashCode).append(GTConfig.separator).append(time).append(GTConfig.separator).append(isVisibleToUser).toString());
}
use of com.kunpeng.pit.HookAnnotation in project GT by Tencent.
the class FragmentHookList_v4 method performCreateView.
@HookAnnotation(className = "android.support.v4.app.Fragment", methodName = "performCreateView", methodSig = "(Landroid/view/LayoutInflater;Landroid/view/ViewGroup;Landroid/os/Bundle;)Landroid/view/View;")
public static View performCreateView(Object thiz, LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
GTRLog.e(TAG, "performCreateView");
long start = System.currentTimeMillis();
View resultView = performCreateView_backup(thiz, inflater, container, savedInstanceState);
long end = System.currentTimeMillis();
String activityClassName = "";
String activityHashCode = "";
String fragmentClassName = "";
String fragmentHashCode = "";
Object fragment = thiz;
if (fragment instanceof android.support.v4.app.Fragment) {
fragmentClassName = ((android.support.v4.app.Fragment) fragment).getClass().getName();
fragmentHashCode = "" + thiz.hashCode();
Activity activity = ((android.support.v4.app.Fragment) fragment).getActivity();
if (activity != null) {
activityClassName = activity.getClass().getName();
activityHashCode = "" + activity.hashCode();
}
}
GTRClient.pushData(new StringBuilder().append("FragmentV4.performCreateView").append(GTConfig.separator).append(activityClassName).append(GTConfig.separator).append(activityHashCode).append(GTConfig.separator).append(fragmentClassName).append(GTConfig.separator).append(fragmentHashCode).append(GTConfig.separator).append(start).append(GTConfig.separator).append(end).toString());
return resultView;
}
Aggregations