导航菜单

页面标题

页面副标题

CityMall v1.42.1 - DeviceNumberActivity.java 源代码

正在查看: CityMall v1.42.1 应用的 DeviceNumberActivity.java JAVA 源代码文件

本页面展示 JAVA 反编译生成的源代码文件,支持语法高亮显示。 仅供安全研究与技术分析使用,严禁用于任何非法用途。请遵守相关法律法规。


package com.reactlibrary.devicenumber;

import android.app.Activity;
import android.content.Intent;
import android.content.IntentSender;
import android.os.Bundle;
import android.widget.Toast;
import com.google.android.gms.auth.api.credentials.Credential;
import com.google.android.gms.auth.api.credentials.HintRequest;
import com.google.android.gms.common.ConnectionResult;
import com.google.android.gms.common.api.GoogleApiClient;

public class DeviceNumberActivity extends Activity implements GoogleApiClient.ConnectionCallbacks, GoogleApiClient.OnConnectionFailedListener {
    String a;

    private void a() {
        GoogleApiClient d = new GoogleApiClient.a(this).a(n4.a.b).b(this).c(this).d();
        d.d();
        try {
            startIntentSenderForResult(n4.a.e.a(d, new HintRequest.a().b(true).a()).getIntentSender(), 100, null, 0, 0, 0);
        } catch (IntentSender.SendIntentException e) {
            e.printStackTrace();
        }
    }

    public void G(Bundle bundle) {
    }

    public void O(int i) {
    }

    public void T(ConnectionResult connectionResult) {
    }

    @Override
    protected void onActivityResult(int i, int i2, Intent intent) {
        super.onActivityResult(i, i2, intent);
        if (i != 100) {
            finish();
            finish();
            return;
        }
        if (i2 != -1) {
            finish();
            finish();
            return;
        }
        Credential parcelableExtra = intent.getParcelableExtra("com.google.android.gms.credentials.Credential");
        if (parcelableExtra == null) {
            finish();
            finish();
            Toast.makeText(this, "error", 0).show();
        } else {
            this.a = parcelableExtra.L();
            Intent intent2 = new Intent();
            intent2.putExtra("mobileNumber", this.a);
            setResult(-1, intent2);
            finish();
            finish();
        }
    }

    @Override
    protected void onCreate(Bundle bundle) {
        requestWindowFeature(1);
        super.onCreate(bundle);
        a();
    }

    @Override
    public void onRequestPermissionsResult(int i, String[] strArr, int[] iArr) {
        if (i != 101) {
            return;
        }
        if (iArr.length <= 0 || iArr[0] != 0) {
            Toast.makeText(this, "Permission denied.", 0).show();
        } else {
            Toast.makeText(this, "Permission granted.", 0).show();
        }
    }
}