Final layout update and fixed possible duplicate applications bug