align AlertDialog buttons to center

前端 未结 9 1897
无人共我
无人共我 2020-12-06 09:09

I use this codes for Android (Java) programming:

public static MessageBoxResult showOk(
        Context context, String title, String message, String okMessa         


        
9条回答
  •  天命终不由人
    2020-12-06 09:53

    Useandroid.support.v7.app.AlertDialog which will align your positive and negative buttons in center.

    android.app.AlertDialog will place the button in the top leaving 16dp space in bottom.

提交回复
热议问题