package com.seewo.ota.view;

import android.content.Context;
import android.graphics.drawable.ColorDrawable;
import android.os.Bundle;
import android.view.KeyEvent;
import android.widget.TextView;
import com.seewo.ota.R;
import f.z.d.k;

/* JADX INFO: compiled from: UpdateWaitingDialog.kt */
/* JADX INFO: loaded from: classes.dex */
public final class i extends e {
    /* JADX WARN: 'super' call moved to the top of the method (can break code semantics) */
    public i(Context context) {
        super(context);
        k.e(context, "context");
    }

    @Override // android.app.Dialog
    protected void onCreate(Bundle bundle) {
        super.onCreate(bundle);
        getWindow().requestFeature(1);
        getWindow().setType(2018);
        setContentView(R.layout.sys_upgrade_dialog);
        ((TextView) findViewById(R.id.tips)).setText(R.string.system_firmware_update_tips);
    }

    @Override // android.app.Dialog, android.view.KeyEvent.Callback
    public boolean onKeyDown(int i2, KeyEvent keyEvent) {
        if (i2 != 4) {
            return super.onKeyDown(i2, keyEvent);
        }
        dismiss();
        return true;
    }

    @Override // android.app.Dialog
    protected void onStart() {
        super.onStart();
        getWindow().setBackgroundDrawable(new ColorDrawable(-1));
        getWindow().setLayout(-1, -1);
    }
}
