Loading docs/html/guide/components/fragments.jd +1 −1 Original line number Diff line number Diff line Loading @@ -172,7 +172,7 @@ the user might not come back).</dd> <p>Most applications should implement at least these three methods for every fragment, but there are several other callback methods you should also use to handle various stages of the fragment lifecycle. All the lifecycle callback methods are discussed more later, in the section fragment lifecycle. All the lifecycle callback methods are discussed in more detail in the section about <a href="#Lifecycle">Handling the Fragment Lifecycle</a>.</p> Loading docs/html/guide/topics/graphics/prop-animation.jd +2 −2 Original line number Diff line number Diff line Loading @@ -479,7 +479,7 @@ ObjectAnimator.ofFloat(targetObject, "propName", 1f) </li> <li>Depending on what property or object you are animating, you might need to call the {@link android.view.View#invalidate invalidate()} method on a View force the screen to redraw itself with the android.view.View#invalidate invalidate()} method on a View to force the screen to redraw itself with the updated animated values. You do this in the {@link android.animation.ValueAnimator.AnimatorUpdateListener#onAnimationUpdate onAnimationUpdate()} callback. For example, animating the color property of a Drawable object only cause updates to the Loading Loading @@ -825,7 +825,7 @@ rotationAnim.setDuration(5000ms); <h2 id="views">Animating Views</h2> <p>The property animation system allow streamlined animation of View objects and offerse <p>The property animation system allow streamlined animation of View objects and offers a few advantages over the view animation system. The view animation system transformed View objects by changing the way that they were drawn. This was handled in the container of each View, because the View itself had no properties to manipulate. Loading docs/html/guide/topics/resources/accessing-resources.jd +7 −5 Original line number Diff line number Diff line Loading @@ -50,7 +50,7 @@ the {@code aapt} tool automatically generates.</p> <p>When your application is compiled, {@code aapt} generates the {@code R} class, which contains resource IDs for all the resources in your {@code res/} directory. For each type of resource, there is an {@code R} subclass (for example, {@code R.drawable} for all drawable resources) and for each resource of that type, there is a static {@code R.drawable} for all drawable resources), and for each resource of that type, there is a static integer (for example, {@code R.drawable.icon}). This integer is the resource ID that you can use to retrieve your resource.</p> Loading @@ -68,7 +68,7 @@ resource is a simple value (such as a string).</li> <p>There are two ways you can access a resource:</p> <ul> <li><strong>In code:</strong> Using an static integer from a sub-class of your {@code R} <li><strong>In code:</strong> Using a static integer from a sub-class of your {@code R} class, such as: <pre class="classic no-pretty-print">R.string.hello</pre> <p>{@code string} is the resource type and {@code hello} is the resource name. There are many Loading Loading @@ -264,11 +264,13 @@ reference a system resource, you would need to include the package name. For exa android:text="@string/hello" /> </pre> <p class="note"><strong>Note:</strong> You should use string resources at all times, so that your application can be localized for other languages. For information about creating alternative <p class="note"><strong>Note:</strong> You should use string resources at all times, so that your application can be localized for other languages. For information about creating alternative resources (such as localized strings), see <a href="providing-resources.html#AlternativeResources">Providing Alternative Resources</a>.</p> Resources</a>. For a complete guide to localizing your application for other languages, see <a href="localization.html">Localization</a>.</p> <p>You can even use resources in XML to create aliases. For example, you can create a drawable resource that is an alias for another drawable resource:</p> Loading docs/html/guide/topics/resources/providing-resources.jd +1 −1 Original line number Diff line number Diff line Loading @@ -376,7 +376,7 @@ res/ screen area. Specifically, the device's smallestWidth is the shortest of the screen's available height and width (you may also think of it as the "smallest possible width" for the screen). You can use this qualifier to ensure that, regardless of the screen's current orientation, your application's has at least {@code <N>} dps of width available for it UI.</p> application has at least {@code <N>} dps of width available for its UI.</p> <p>For example, if your layout requires that its smallest dimension of screen area be at least 600 dp at all times, then you can use this qualifer to create the layout resources, {@code res/layout-sw600dp/}. The system will use these resources only when the smallest dimension of Loading docs/html/guide/topics/search/search-dialog.jd +1 −0 Original line number Diff line number Diff line Loading @@ -722,6 +722,7 @@ public boolean onCreateOptionsMenu(Menu menu) { // Get the SearchView and set the searchable configuration SearchManager searchManager = (SearchManager) {@link android.app.Activity#getSystemService getSystemService}(Context.SEARCH_SERVICE); SearchView searchView = (SearchView) menu.findItem(R.id.menu_search).getActionView(); // Assumes current activity is the searchable activity searchView.setSearchableInfo(searchManager.getSearchableInfo({@link android.app.Activity#getComponentName()})); searchView.setIconifiedByDefault(false); // Do not iconify the widget; expand it by default Loading Loading
docs/html/guide/components/fragments.jd +1 −1 Original line number Diff line number Diff line Loading @@ -172,7 +172,7 @@ the user might not come back).</dd> <p>Most applications should implement at least these three methods for every fragment, but there are several other callback methods you should also use to handle various stages of the fragment lifecycle. All the lifecycle callback methods are discussed more later, in the section fragment lifecycle. All the lifecycle callback methods are discussed in more detail in the section about <a href="#Lifecycle">Handling the Fragment Lifecycle</a>.</p> Loading
docs/html/guide/topics/graphics/prop-animation.jd +2 −2 Original line number Diff line number Diff line Loading @@ -479,7 +479,7 @@ ObjectAnimator.ofFloat(targetObject, "propName", 1f) </li> <li>Depending on what property or object you are animating, you might need to call the {@link android.view.View#invalidate invalidate()} method on a View force the screen to redraw itself with the android.view.View#invalidate invalidate()} method on a View to force the screen to redraw itself with the updated animated values. You do this in the {@link android.animation.ValueAnimator.AnimatorUpdateListener#onAnimationUpdate onAnimationUpdate()} callback. For example, animating the color property of a Drawable object only cause updates to the Loading Loading @@ -825,7 +825,7 @@ rotationAnim.setDuration(5000ms); <h2 id="views">Animating Views</h2> <p>The property animation system allow streamlined animation of View objects and offerse <p>The property animation system allow streamlined animation of View objects and offers a few advantages over the view animation system. The view animation system transformed View objects by changing the way that they were drawn. This was handled in the container of each View, because the View itself had no properties to manipulate. Loading
docs/html/guide/topics/resources/accessing-resources.jd +7 −5 Original line number Diff line number Diff line Loading @@ -50,7 +50,7 @@ the {@code aapt} tool automatically generates.</p> <p>When your application is compiled, {@code aapt} generates the {@code R} class, which contains resource IDs for all the resources in your {@code res/} directory. For each type of resource, there is an {@code R} subclass (for example, {@code R.drawable} for all drawable resources) and for each resource of that type, there is a static {@code R.drawable} for all drawable resources), and for each resource of that type, there is a static integer (for example, {@code R.drawable.icon}). This integer is the resource ID that you can use to retrieve your resource.</p> Loading @@ -68,7 +68,7 @@ resource is a simple value (such as a string).</li> <p>There are two ways you can access a resource:</p> <ul> <li><strong>In code:</strong> Using an static integer from a sub-class of your {@code R} <li><strong>In code:</strong> Using a static integer from a sub-class of your {@code R} class, such as: <pre class="classic no-pretty-print">R.string.hello</pre> <p>{@code string} is the resource type and {@code hello} is the resource name. There are many Loading Loading @@ -264,11 +264,13 @@ reference a system resource, you would need to include the package name. For exa android:text="@string/hello" /> </pre> <p class="note"><strong>Note:</strong> You should use string resources at all times, so that your application can be localized for other languages. For information about creating alternative <p class="note"><strong>Note:</strong> You should use string resources at all times, so that your application can be localized for other languages. For information about creating alternative resources (such as localized strings), see <a href="providing-resources.html#AlternativeResources">Providing Alternative Resources</a>.</p> Resources</a>. For a complete guide to localizing your application for other languages, see <a href="localization.html">Localization</a>.</p> <p>You can even use resources in XML to create aliases. For example, you can create a drawable resource that is an alias for another drawable resource:</p> Loading
docs/html/guide/topics/resources/providing-resources.jd +1 −1 Original line number Diff line number Diff line Loading @@ -376,7 +376,7 @@ res/ screen area. Specifically, the device's smallestWidth is the shortest of the screen's available height and width (you may also think of it as the "smallest possible width" for the screen). You can use this qualifier to ensure that, regardless of the screen's current orientation, your application's has at least {@code <N>} dps of width available for it UI.</p> application has at least {@code <N>} dps of width available for its UI.</p> <p>For example, if your layout requires that its smallest dimension of screen area be at least 600 dp at all times, then you can use this qualifer to create the layout resources, {@code res/layout-sw600dp/}. The system will use these resources only when the smallest dimension of Loading
docs/html/guide/topics/search/search-dialog.jd +1 −0 Original line number Diff line number Diff line Loading @@ -722,6 +722,7 @@ public boolean onCreateOptionsMenu(Menu menu) { // Get the SearchView and set the searchable configuration SearchManager searchManager = (SearchManager) {@link android.app.Activity#getSystemService getSystemService}(Context.SEARCH_SERVICE); SearchView searchView = (SearchView) menu.findItem(R.id.menu_search).getActionView(); // Assumes current activity is the searchable activity searchView.setSearchableInfo(searchManager.getSearchableInfo({@link android.app.Activity#getComponentName()})); searchView.setIconifiedByDefault(false); // Do not iconify the widget; expand it by default Loading