summaryrefslogtreecommitdiffstats
path: root/docs/html
diff options
context:
space:
mode:
authorDianne Hackborn <hackbod@google.com>2011-01-08 17:25:57 -0800
committerDianne Hackborn <hackbod@google.com>2011-01-08 18:25:30 -0800
commit247fe74c934cb3fba85aae7e051a8044f460fb11 (patch)
tree91123356af7f3b66c19c974b885eb5d3a94707b5 /docs/html
parentf600780bea864c672e01a391b65da65d85045803 (diff)
downloadframeworks_base-247fe74c934cb3fba85aae7e051a8044f460fb11.zip
frameworks_base-247fe74c934cb3fba85aae7e051a8044f460fb11.tar.gz
frameworks_base-247fe74c934cb3fba85aae7e051a8044f460fb11.tar.bz2
Implement issue # 3255887 could CursorLoader offer...
...to throttle contentobserver-based requeries Why yes, I guess it could. This also reworks AsyncTaskLoader to not generate multiple concurrent tasks if it is getting change notifications before the last background task is complete. And removes some of the old APIs that had been deprecated but need to be gone for final release. And fixes a few little problems with applying the wrong theme in system code. Change-Id: Ic7a665b666d0fb9d348e5f23595532191065884f
Diffstat (limited to 'docs/html')
-rw-r--r--docs/html/guide/topics/fragments/index.jd14
1 files changed, 7 insertions, 7 deletions
diff --git a/docs/html/guide/topics/fragments/index.jd b/docs/html/guide/topics/fragments/index.jd
index 766146e..d07daf4 100644
--- a/docs/html/guide/topics/fragments/index.jd
+++ b/docs/html/guide/topics/fragments/index.jd
@@ -277,13 +277,13 @@ fragments to your activity layout. You simply need to specify a {@link android.v
which to place the fragment.</p>
<p>To make any fragment transactions in your activity (such as add, remove, or replace a
fragment), you must use APIs from {@link android.app.FragmentTransaction}. You can get an instance
-of {@link android.app.FragmentTransaction} from your {@link android.app.Activity} using {@link
-android.app.Activity#openFragmentTransaction()}. You can then add a fragment using the {@link
+of {@link android.app.FragmentTransaction} from your {@link android.app.FragmentManager} using {@link
+android.app.FragmentManager#openTransaction()}. You can then add a fragment using the {@link
android.app.FragmentTransaction#add add()} method, specifying the fragment to add and the view in
which to insert it. For example:</p>
<pre>
MyFragment fragment = new MyFragment();
-openFragmentTransaction().add(R.id.fragment_container, fragment).commit();
+getFragmentManager().openTransaction().add(R.id.fragment_container, fragment).commit();
</pre>
<p>The first argument passed to {@link android.app.FragmentTransaction#add add()}
is the {@link android.view.ViewGroup} in which the fragment should be placed, specified by
@@ -372,8 +372,8 @@ android.app.Fragment#onStop onStop()} and others that coincide with the fragment
operations on a fragment as the user interacts with the activity, alowing for more rich user
experiences without changing activities. In order to perform these operations, you must use {@link
android.app.FragmentTransaction} to perform fragment "transactions." You can acquire {@link
-android.app.FragmentTransaction} from your activity with {@link
-android.app.Activity#openFragmentTransaction}.</p>
+android.app.FragmentTransaction} from your FragmentManager with {@link
+android.app.FragmentManager#openTransaction}.</p>
<p>Common transactions you can perform with fragments include:</p>
@@ -397,7 +397,7 @@ in the back stack:</p>
<pre>
// Create new fragment
Fragment newFragment = new MyFragment();
-FragmentTransaction ft = openFragmentTransaction();
+FragmentTransaction ft = getFragmentManager().openTransaction();
// Replace and add to back stack
ft.replace(R.id.myfragment, newFragment);
ft.addToBackStack(null);
@@ -519,7 +519,7 @@ View listView = {@link android.app.Fragment#getActivity()}.{@link android.app.Ac
<p>Likewise, your activity can call public methods in the fragment when you have a reference to the
{@link android.app.Fragment}. You can acquire a reference to the fragment with {@link
-android.app.Activity#findFragmentById findFragmentById()} and cast it to your implementation of
+android.app.FragmentManager#findFragmentById findFragmentById()} and cast it to your implementation of
{@link android.app.Fragment}. For example:</p>
<pre>