0
6
Login
Code
Issues
1
Pull requests
Events
Packages
06f599acb9ddc582d65982f5232600b430100754
06f599acb9ddc582d65982f5232600b430100754
Name
Commit
Updated at
src
README-fragmentview.txt

Steps to implement FragmentView template: -in template-params.xml.ftl: -add the following line to common imports

-Add a Fragment to show behavior. In your MainActivity.java class, it will reference a Fragment called (yourProjectName)Fragment.java. Create that file in your project, using the "main" source folder instead of "common" or "templates". For instance, if your package name is com.example.foo, create the file src/main/java/com/example/foo/FooFragment.java

-Within this fragment, make sure that the onCreate method has the line "setHasOptionsMenu(true);", to enable the fragment to handle menu events.

-In order to override menu events, override onOptionsItemSelected.

-refer to sampleSamples/fragmentViewSample for a reference implementation of a project built on this template.