MainActivity improved