You're catching configuration changes, now you have to do something with it.
Within initUI() you should determine your new aspect ratio and location. A simple If-Else that sets sizes and LayoutParams based on which way the user rotated the screen. Instead, you're simply calling Activity2 with the same layout of activity_main. You could easily setContentView to activity_main_port or programmatically set sizes, layouts, etc.