AlertDialog with internal keyboard [closed]

2

I'dliketoknowhowtocreateaAlertDialogliketheimage(withkeyboard)onAndroid.Thankyou.

Keyboard:                            

<Buttonandroid:id="@+id/dois"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="2"
            />
        <Button
            android:id="@+id/tres"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="3"
            />
    </TableRow>

    <TableRow>
        <Button
            android:id="@+id/quatro"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="4"
            />

        <Button
            android:id="@+id/cinco"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="5"
            />
        <Button
            android:id="@+id/seis"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="6"
            />
    </TableRow>
    <TableRow>
        <Button
            android:id="@+id/sete"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="7"
            />

        <Button
            android:id="@+id/oito"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="8"
            />
        <Button
            android:id="@+id/nove"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="9"
            />
    </TableRow>

    <TableRow>
    <Button
        android:id="@+id/excluir"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="excluir"
        />

    <Button
        android:id="@+id/zero"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="0"
        />
    <Button
        android:id="@+id/igual"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="="
        />
</TableRow>
    </TableLayout>

AlertDialog:

AlertDialog.Builder builder = new AlertDialog.Builder(this);

    LayoutInflater inflater = this.getLayoutInflater();

    builder.setView(inflater.inflate(R.layout.insertnum, null))
            .setPositiveButton(R.string.ok, new DialogInterface.OnClickListener() {
                @Override
                public void onClick(DialogInterface dialog, int id) {
                    // sign in the user ...
                }
            })
            .setNegativeButton(R.string.cancelar, new DialogInterface.OnClickListener() {
                public void onClick(DialogInterface dialog, int id) {
                    //
                }
            });
    builder.create();
    builder.show();
}
    
asked by anonymous 15.03.2015 / 04:22

0 answers