how to make dialog box appear on the left?
问题 I want to add OnclickListener for a button,where in I want to display the Dialog box on the left of the screen on click of it.I tried to implement that but it always appears on the center of the screen.Any idea on how to implement that? 回答1: If I understand your question correctly - you want to align your dialog not appear on the center of the screen. Then look at this code sample. AlertDialog.Builder builder = new AlertDialog.Builder(this); builder.setItems(items, new DialogInterface