package com.tencent.mm.plugin.subapp.c;

import com.tencent.matrix.trace.core.AppMethodBeat;
import com.tencent.mm.compatible.util.g;
import com.tencent.mm.sdk.platformtools.ab;
import com.tencent.mm.sdk.platformtools.ap.a;

class b$1 implements a {
    final /* synthetic */ b ssP;

    b$1(b bVar) {
        this.ssP = bVar;
    }

    public final boolean BI() {
        AppMethodBeat.i(25250);
        g abp = d.cDE().abp(this.ssP.fileName);
        if (abp == null || !abp.ame()) {
            ab.e("MicroMsg.NetSceneUploadVoiceRemind", "Get info Failed file:" + this.ssP.fileName);
            this.ssP.retCode = g.getLine() + 10000;
            this.ssP.ehi.onSceneEnd(3, -1, "doScene failed", this.ssP);
            AppMethodBeat.o(25250);
            return false;
        }
        if (!(3 == abp.field_status || 8 == abp.field_status)) {
            long currentTimeMillis = System.currentTimeMillis();
            if ((currentTimeMillis / 1000) - abp.field_lastmodifytime > 30) {
                ab.e("MicroMsg.NetSceneUploadVoiceRemind", "Error ModifyTime in Read file:" + this.ssP.fileName);
                this.ssP.retCode = g.getLine() + 10000;
                this.ssP.ehi.onSceneEnd(3, -1, "doScene failed", this.ssP);
                AppMethodBeat.o(25250);
                return false;
            } else if (currentTimeMillis - this.ssP.fZf < 2000) {
                ab.d("MicroMsg.NetSceneUploadVoiceRemind", "TimerExpired :" + this.ssP.fileName + " but last send time:" + (currentTimeMillis - this.ssP.fZf));
                AppMethodBeat.o(25250);
                return true;
            } else {
                c$a Fo = h.abm(this.ssP.fileName).Fo(abp.field_offset);
                ab.d("MicroMsg.NetSceneUploadVoiceRemind", "pusher doscene:" + this.ssP.fileName + " readByte:" + Fo.cqs + " stat:" + abp.field_status);
                if (Fo.cqs < 2000) {
                    AppMethodBeat.o(25250);
                    return true;
                }
            }
        }
        if (this.ssP.a(this.ssP.ftf, this.ssP.ehi) == -1) {
            this.ssP.retCode = g.getLine() + 10000;
            this.ssP.ehi.onSceneEnd(3, -1, "doScene failed", this.ssP);
        }
        AppMethodBeat.o(25250);
        return false;
    }
}
