diff options
author | Tor Norbye <tnorbye@google.com> | 2012-07-14 08:53:34 -0700 |
---|---|---|
committer | Tor Norbye <tnorbye@google.com> | 2012-07-14 12:59:59 -0700 |
commit | ef297cc99f4e4adda22fbe1a94db815f56e973f3 (patch) | |
tree | c15904431a03014b7c621930b2f35409964e74ee /templates/activities | |
parent | 0d8f973905a4925e00eb9e32887c192b2148b29f (diff) | |
download | sdk-ef297cc99f4e4adda22fbe1a94db815f56e973f3.zip sdk-ef297cc99f4e4adda22fbe1a94db815f56e973f3.tar.gz sdk-ef297cc99f4e4adda22fbe1a94db815f56e973f3.tar.bz2 |
Reference android.R in template rather than importing it
Change-Id: I84ffc48d8c57ac3f46ab28b62be4785135f2878d
Diffstat (limited to 'templates/activities')
-rw-r--r-- | templates/activities/MasterDetailFlow/root/src/app_package/ContentListActivity.java.ftl | 2 | ||||
-rw-r--r-- | templates/activities/MasterDetailFlow/root/src/app_package/ContentListFragment.java.ftl | 5 |
2 files changed, 4 insertions, 3 deletions
diff --git a/templates/activities/MasterDetailFlow/root/src/app_package/ContentListActivity.java.ftl b/templates/activities/MasterDetailFlow/root/src/app_package/ContentListActivity.java.ftl index 9edf5c8..4456815 100644 --- a/templates/activities/MasterDetailFlow/root/src/app_package/ContentListActivity.java.ftl +++ b/templates/activities/MasterDetailFlow/root/src/app_package/ContentListActivity.java.ftl @@ -3,8 +3,10 @@ package ${packageName}; import android.content.Intent; import android.os.Bundle; import android.support.v4.app.FragmentActivity; +<#if parentActivityClass != ""> import android.support.v4.app.NavUtils; import android.view.MenuItem; +</#if> public class ${CollectionName}Activity extends FragmentActivity implements ${CollectionName}Fragment.Callbacks { diff --git a/templates/activities/MasterDetailFlow/root/src/app_package/ContentListFragment.java.ftl b/templates/activities/MasterDetailFlow/root/src/app_package/ContentListFragment.java.ftl index 6b4b9a0..7de2868 100644 --- a/templates/activities/MasterDetailFlow/root/src/app_package/ContentListFragment.java.ftl +++ b/templates/activities/MasterDetailFlow/root/src/app_package/ContentListFragment.java.ftl @@ -2,7 +2,6 @@ package ${packageName}; import ${packageName}.dummy.DummyContent; -import android.R; import android.app.Activity; import android.os.Bundle; import android.support.v4.app.ListFragment; @@ -35,8 +34,8 @@ public class ${CollectionName}Fragment extends ListFragment { public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setListAdapter(new ArrayAdapter<DummyContent.DummyItem>(getActivity(), - R.layout.simple_list_item_activated_1, - R.id.text1, + android.R.layout.simple_list_item_activated_1, + android.R.id.text1, DummyContent.ITEMS)); } |