package com.tencent.mm.plugin.game.model.a;

import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import com.tencent.matrix.trace.core.AppMethodBeat;
import com.tencent.mm.kernel.a;
import com.tencent.mm.kernel.g;
import com.tencent.mm.sdk.platformtools.ab;
import com.tencent.mm.sdk.platformtools.ah;
import com.tencent.mm.sdk.platformtools.at;

class e$b extends BroadcastReceiver {
    private e$b() {
    }

    /* synthetic */ e$b(byte b) {
        this();
    }

    public final void onReceive(Context context, Intent intent) {
        AppMethodBeat.i(111514);
        if (!g.RK() || a.QT()) {
            ab.e("MicroMsg.GameSilentDownloadListener", "acc has not ready");
            AppMethodBeat.o(111514);
            return;
        }
        int netType = at.getNetType(ah.getContext());
        if (netType == e.access$200()) {
            AppMethodBeat.o(111514);
            return;
        }
        e.access$202(netType);
        if (netType == 0) {
            ab.i("MicroMsg.GameSilentDownloadListener", "netStateChange, netState = %s, checkDownload", new Object[]{Integer.valueOf(netType)});
            h.a.bFa().hO(false);
            AppMethodBeat.o(111514);
            return;
        }
        ab.i("MicroMsg.GameSilentDownloadListener", "netStateChange, netState = %s, pauseDownload", new Object[]{Integer.valueOf(netType)});
        h.a.bFa();
        h.pauseDownload();
        AppMethodBeat.o(111514);
    }
}
