Changes

Jump to: navigation, search

Using Fragments in Android - A Worked Example

12 bytes removed, 15:07, 29 April 2016
no edit summary
<htmlet>androidstudioandroid44</htmlet>
(for example com.example.fragmentexample). From the resulting menu, select the New -> Class option. In the resulting New Java Class dialog, name the class ToolbarFragment. Next, click on the Browse button to the right of the Superclass field. In the superclass selection dialog, enter Fragment into the text box. From the matching items list, locate and double click on the Fragment - android.support.v4.app entry (selecting the android.app instance of the class will not make use of the support library precluding the execution of the application on older Android versions).
<htmlet>androidstudioandroid44</htmlet>
Click Finish to complete the class creation process. Once the class has been created, it should, by default, appear in the editing panel where it will read as follows:
<htmlet>androidstudioandroid44</htmlet>

Navigation menu