less dialogs code in MainActivity