From the course: Android Development Essential Training: App Architecture with Kotlin

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Add a new launcher activity

Add a new launcher activity - Android Tutorial

From the course: Android Development Essential Training: App Architecture with Kotlin

Start my 1-month free trial

Add a new launcher activity

- [Instructor] Most Android apps have multiple activities. Only one activity in each app is known as the launcher activity. All other activities are launched from there and in some cases can be launched in response to requests from other apps. In order to demonstrate this, I'm going to add a new activity to this project. It's going to become in the launcher activity and my current activity, currently called Main Activity, will become a secondary activity. So I'm going to refactor this. I'm going to rename MainActivity as DiceActivity. I'll click on the activity class in the Project Window, then I'll press shift + F6 and that opens the rename dialog, I'll change this to DiceActivity and click Refactor and that changes the name of the activity, both in the file name, in the code and anywhere where that activity is referenced. For consistency in file naming I'll go to my layout directory under resources and once again I'll use refactoring to rename this file from activity_main to…

Contents