礼包最新页面修改实现逻辑(未完成), 9.5测试需求

This commit is contained in:
kehaoyuan
2017-09-06 14:37:10 +08:00
parent 00879964e4
commit 0bcd37c1f1
18 changed files with 1173 additions and 36 deletions

View File

@ -1,5 +1,6 @@
package com.gh.base;
import android.content.Intent;
import android.os.Build;
import android.os.Bundle;
import android.view.View;
@ -14,10 +15,10 @@ import com.gh.common.util.RunningUtils;
import com.gh.common.util.ShareUtils;
import com.gh.common.util.StringUtils;
import com.gh.download.DownloadManager;
import com.gh.gamecenter.LoginActivity;
import com.gh.gamecenter.MainActivity;
import com.gh.gamecenter.R;
import com.gh.gamecenter.eventbus.EBShowDialog;
import com.gh.gamecenter.eventbus.EBSkip;
import com.lightgame.download.FileUtils;
import com.lightgame.utils.AppManager;
import com.readystatesoftware.systembartint.SystemBarTintManager.SystemBarConfig;
@ -137,12 +138,18 @@ public abstract class BaseActivity extends BaseAppCompatToolBarActivity {
String model = device.getString("model");
DialogUtils.showAlertDialog(this, "你的账号已在另外一台设备登录"
, StringUtils.buildString("", manufacturer, "", model, "")
, "知道了", null, new DialogUtils.ConfirmListener() {
, "知道了", "重新登录"
, null, new DialogUtils.CancelListener() {
@Override
public void onConfirm() {
EventBus.getDefault().post(new EBSkip(MainActivity.EB_SKIP_GAMEFRAGMENT, 2));
public void onCancel() {
// TODO 未测试
if (!MainActivity.class.getName().equals(RunningUtils.getTopActivity(BaseActivity.this))) {
finish();
}
Intent intent = LoginActivity.getIntent(BaseActivity.this, false);
startActivity(intent);
}
}, null);
});
} catch (JSONException e) {
e.printStackTrace();
}