package com.tencent.mm.plugin.qqmail.ui;

import android.content.Intent;
import android.view.GestureDetector.SimpleOnGestureListener;
import android.view.MotionEvent;
import com.tencent.matrix.trace.core.AppMethodBeat;
import com.tencent.mm.plugin.qqmail.b.o;

class MailAddrsViewControl$8 extends SimpleOnGestureListener {
    final /* synthetic */ MailAddrsViewControl pyG;

    MailAddrsViewControl$8(MailAddrsViewControl mailAddrsViewControl) {
        this.pyG = mailAddrsViewControl;
    }

    private void cdk() {
        AppMethodBeat.i(68345);
        o oVar = (o) MailAddrsViewControl.c(this.pyG).getTag();
        if (MailAddrsViewControl.g(this.pyG) != null) {
            MailAddrsViewControl.g(this.pyG);
            MailAddrsViewControl.c(this.pyG);
        }
        Intent intent = new Intent(this.pyG.getContext(), MailAddrProfileUI.class);
        intent.putExtra("name", oVar.name);
        intent.putExtra("addr", oVar.nJq);
        intent.putExtra("can_compose", !MailAddrsViewControl.h(this.pyG));
        this.pyG.getContext().startActivity(intent);
        AppMethodBeat.o(68345);
    }

    public final boolean onSingleTapUp(MotionEvent motionEvent) {
        AppMethodBeat.i(68346);
        if (!MailAddrsViewControl.h(this.pyG)) {
            cdk();
        }
        AppMethodBeat.o(68346);
        return true;
    }

    public final void onLongPress(MotionEvent motionEvent) {
        AppMethodBeat.i(68347);
        if (!(MailAddrsViewControl.g(this.pyG) == null || MailAddrsViewControl.c(this.pyG) == null)) {
            MailAddrsViewControl.g(this.pyG);
            MailAddrsViewControl.c(this.pyG);
            MailAddrsViewControl.c(this.pyG).getTag();
        }
        AppMethodBeat.o(68347);
    }

    public final boolean onDoubleTap(MotionEvent motionEvent) {
        AppMethodBeat.i(68348);
        cdk();
        AppMethodBeat.o(68348);
        return true;
    }
}
