Copied activity to common activity.java