android - How can I create my own theme for alertDialog? -


i want create different theme of alertdialog instances. need own title view instead of usual black title background. text should have blue color, , set edge of alertdialog round shape.

is possible create our own theme alert dialogs, using style or creating class extends alertdialog.builder? need common theme or style instances of alertdialog. using alertdialog in many places - 1 singlechoice items, 1 arrayadapter.

my alertdialog array adapter:

string[] items = {"edit profile","change user","change password","logout"}; arrayadapter<string> adapter = new arrayadapter<string>(loged.this,                     r.layout.my_spinner_layout, items);  settingmenu.setadapter(adapter, listener);  

my alertdialog single choice items:

alertdelete = new alertdialog.builder(getparent());                     alertdelete.settitle("delete");                     alertdelete.setcancelable(true);                     charsequence[] choice = {"this user","all user"};                     alertdelete.setsinglechoiceitems(choice, 0, 

for alertdialog, need common theme, like:

enter image description here

please check link. here creating own alertdialog class , simple method if reuse alertdialog in many situation in application

how create setadapter() alertdialog


Comments

Popular posts from this blog

php - cannot display multiple markers in google maps v3 from traceroute result -

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -