QQ浏览器 v12.2.3.7053版本的 MD5 值为:8285ab3059e5c8b521a264dfbc5c3685
以下内容为反编译后的 SupervisionMenuAdapterImpl.java 源代码,内容仅作参考
package com.tencent.ilive.components.supervisionmenucomponent;
import android.text.TextUtils;
import com.tencent.falco.base.libapi.datareport.DataReportInterface;
import com.tencent.falco.base.libapi.generalinfo.AppGeneralInfoService;
import com.tencent.falco.base.libapi.imageloader.ImageLoaderInterface;
import com.tencent.falco.base.libapi.log.LogInterface;
import com.tencent.falco.utils.StringUtil;
import com.tencent.ilive.supervisionmenucomponent_interface.SupervisionMenuAdapter;
import com.tencent.ilive.supervisionmenucomponent_interface.widget.TargetUserInfo;
import com.tencent.ilivesdk.liveconfigservice_interface.LiveConfigServiceInterface;
import com.tencent.ilivesdk.userinfoservice_interface.UserInfoServiceInterface;
import com.tencent.ilivesdk.userinfoservice_interface.model.UserInfo;
import com.tencent.livesdk.servicefactory.ServiceAccessorConfig;
import org.json.JSONException;
import org.json.JSONObject;
public class SupervisionMenuAdapterImpl implements SupervisionMenuAdapter {
private ServiceAccessorConfig f12193a;
public SupervisionMenuAdapterImpl(ServiceAccessorConfig serviceAccessorConfig) {
this.f12193a = serviceAccessorConfig;
}
public String a(String str, String str2, int i) {
if (!StringUtil.a(str)) {
return str;
}
if (StringUtil.a(str2)) {
return "";
}
String str3 = null;
try {
JSONObject a2 = ((LiveConfigServiceInterface) this.f12193a.a().a(LiveConfigServiceInterface.class)).a("common_urls");
if (a2 != null) {
String str4 = (String) a2.get("person_head_pic");
if (!StringUtil.a(str4)) {
str3 = str4;
}
}
} catch (JSONException e) {
e.printStackTrace();
}
if (TextUtils.isEmpty(str3)) {
str3 = "https://nowpic.gtimg.com/hy_personal/";
}
AppGeneralInfoService appGeneralInfoService = (AppGeneralInfoService) this.f12193a.a().a(AppGeneralInfoService.class);
StringBuilder sb = new StringBuilder();
appGeneralInfoService.g();
sb.append(str3);
sb.append("%s/%d");
return String.format(sb.toString(), str2, Integer.valueOf(i));
}
@Override
public LogInterface a() {
return (LogInterface) this.f12193a.a().a(LogInterface.class);
}
@Override
public void a(long j, final SupervisionMenuAdapter.OnQueryTargetUserInfoCallback onQueryTargetUserInfoCallback) {
((UserInfoServiceInterface) this.f12193a.b().a(UserInfoServiceInterface.class)).a(j, new UserInfoServiceInterface.OnQueryUserInfoCallback() {
@Override
public void a(UserInfo userInfo) {
if (userInfo == null) {
SupervisionMenuAdapterImpl.this.a().e("SupervisionMenuAdapterImpl", "userInfo is null", new Object[0]);
a(false, -99, "userInfo is null");
} else if (onQueryTargetUserInfoCallback != null) {
TargetUserInfo targetUserInfo = new TargetUserInfo();
targetUserInfo.f12443a = userInfo.f13305a;
targetUserInfo.f12444b = userInfo.f13306b;
targetUserInfo.f12445c = SupervisionMenuAdapterImpl.this.a(userInfo.e, userInfo.f, 80);
onQueryTargetUserInfoCallback.a(targetUserInfo);
}
}
@Override
public void a(boolean z, int i, String str) {
SupervisionMenuAdapter.OnQueryTargetUserInfoCallback onQueryTargetUserInfoCallback2 = onQueryTargetUserInfoCallback;
if (onQueryTargetUserInfoCallback2 != null) {
onQueryTargetUserInfoCallback2.a(z, i, str);
}
}
});
}
@Override
public DataReportInterface b() {
return (DataReportInterface) this.f12193a.a().a(DataReportInterface.class);
}
@Override
public ImageLoaderInterface c() {
return (ImageLoaderInterface) this.f12193a.a().a(ImageLoaderInterface.class);
}
}