docs only.

Add new web pages for sample apps included in the SDK.
Revise the existing sample app web pages.
Delete screenshots for notepad and lunar lander (these have
moved into frameworks/base/docs/html/guide/samples/image/.
This commit is contained in:
Scott Main
2009-08-24 15:27:00 -07:00
parent e95a86cfec
commit 04680858a0
10 changed files with 109 additions and 29 deletions

View File

@@ -1,19 +1,42 @@
<p>The API Demos include sample code for many aspects of the Android APIs, from screen layout to Intent resolution. <p>The API Demos application includes a variety of small applications
that illustrate the use of various Android APIs. It includes samples of:
</p> </p>
<ul>
<li>Notifications</li>
<li>Alarms</li>
<li>Progress Dialogs</li>
<li>Intents</li>
<li>Menus</li>
<li>Search</li>
<li>Persistent application state</li>
<li>Preferences</li>
<li>Background Services</li>
<li>App Widgets</li>
<li>Voice Recognition</li>
<li>And many many more...</li>
</ul>
<dl> <p>You'll notice that all the samples are included in a single Android project,
<dt><a href="src/com/example/android/apis/app/index.html">App</a></dt> so the application code and other resource files for all samples are batched together.
<dd></dd> To help you find the code that's relevant to you, here's a directory that
points to the program code for the different topics included in the project:</p>
<dt><a href="src/com/example/android/apis/content/index.html">Content</a></dt> <ul>
<dd></dd> <li><a href="src/com/example/android/apis/animation/index.html">Animation</a></li>
<li><a href="src/com/example/android/apis/app/index.html">App</a></li>
<li><a href="src/com/example/android/apis/appwidget/index.html">App Widgets</a></li>
<li><a href="src/com/example/android/apis/content/index.html">Content</a></li>
<dt><a href="src/com/example/android/apis/view/index.html">View</a></dt> <li><a href="src/com/example/android/apis/graphics/index.html">Graphics</a></li>
<dd></dd>
<dt><a href="src/com/example/android/apis/graphics/index.html">Graphics</a></dt> <li><a href="src/com/example/android/apis/media/index.html">Media</a></li>
<dd></dd>
<li><a href="src/com/example/android/apis/os/index.html">OS</a></li>
<dt><a href="src/com/example/android/apis/text/index.html">Text</a></dt> <li><a href="src/com/example/android/apis/text/index.html">Text</a></li>
<dd></dd>
</dl> <li><a href="src/com/example/android/apis/view/index.html">Views</a></li>
</ul>

9
samples/Home/_index.html Normal file
View File

@@ -0,0 +1,9 @@
<p>This is a sample Home application. The Home application that users use
to launch applications by default is an ordinary application itself.
A user can install additional Home applications and pick which one to use as the
default Home. This is a sample of such an alternative.</p>
<p>This is actually the source of an old incarnation of the default Home application,
which may look familiar if you played with some of the older pre-1.0 SDKs.</p>
<img alt="" src="/guide/samples/images/HomeSample.png" />

View File

@@ -0,0 +1,24 @@
<p>JetBoy is a sample game that demonstrates the use of the
<a href="/reference/android/media/JetPlayer.html">android.media.JetPlayer</a>
class to implement an interactive music soundtrack in an application. JetBoy uses
<a href="/guide/topics/media/index.html#jet">JET content created with
JetCreator</a> and game-generated events fed to JetPlayer
to adapt the soundtrack to the user actions. Listen to how the melody picks
up when you start shooting asteroids, how you are congratulated when you
hit several asteroids in a row, or destroy enough of them in the allotted time.</p>
<p>The JetBoyView.java file in JetBoy illustrates the loading of JET content
(loading a file, queuing segments), its playback, and how to alter what
is currently playing (use of clips and mute masks).</p>
<p class="note"><strong>Note:</strong>
The <code>JETBOY_content/</code> directory is empty in this online presentation of
the application. For complete access to all the JetBoy files, see the sample code included
in the SDK, located at <code>&lt;sdk>/platforms/&lt;platform>/samples/JetBoy/</code>.
</p>
<p><strong>See also:</strong><br/>
<a href="/guide/topics/media/jet/jetcreator_manual.html">SONiVOX JETCreator User Manual</a><br/>
<a href="/reference/android/media/JetPlayer.html">JetPlayer class</a></p>
<img alt="" src="/guide/samples/images/JetBoy.png" />

View File

@@ -1,12 +1,12 @@
<p>A sample game. Your objective: to land on the moon. <p>A sample game. Your objective: to land on the moon.
It demonstrates... It demonstrates:
<ul> <ul>
<li>loading and drawing resources <li>Loading and drawing resources</li>
<li>taking keystrokes <li>Taking keystrokes</li>
<li>animating by calling invalidate() from draw() <li>Animating by calling invalidate() from draw()</li>
<li>handling onPause() in an animation <li>Handling onPause() in an animation</li>
<li>and many other goodies... <li>And more...</li>
</ul> </ul>
</p> </p>
<img height="220px" width="320px" alt="Lunar Lander Example" class="gallery" src="sample_lunarlander.png" > <img alt="" src="/guide/samples/images/sample_lunarlander.png" >

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

View File

@@ -1,12 +1,19 @@
<p>A simple note pad application. <p>A simple note pad application.
It demonstrates... It demonstrates:</p>
<ul> <ul>
<li>using views <li>Using views</li>
<li>accessing a database <li>Accessing a database</li>
<li>using an intent to open a new window <li>Using an intent to open a new window</li>
<li>managing activity lifecycle <li>Managing activity lifecycle</li>
<li>and many other goodies... <li>And more...</li>
</ul> </ul>
</p>
<img alt="Note Pad Example" class="gallery" src="sample_notepad.png" > <p class="note">Please notice that this is not the same
<img alt="Note Pad Example" class="gallery" src="sample_note.png" > notepad code that's used for the <a href="/guide/tutorials/notepad/index.html">Notepad Tutorial</a>.
They are similar in nature, but there are several differences in implementation &mdash; the tutorial
is slightly more simple. If you're new to
Android development, we suggest you start with the tutorial, then visit this
code later to see more sample code.</p>
<img alt="" src="/guide/samples/images/sample_notepad.png" />
<img alt="" src="/guide/samples/images/sample_note.png" />

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.6 KiB

10
samples/Snake/_index.html Normal file
View File

@@ -0,0 +1,10 @@
<p>This is an implementation of the classic Game "Snake", in which you control a
serpent roaming around the garden looking for apples. Be careful, though,
because when you catch one, not only will you become longer, but you'll move
faster. Running into yourself or the walls will end the game..</p>
<p>This code demonstrates how to create custom View layouts and
request draws to the screen. A great example of a basic game that does not
require a fast framerate.</p>
<img alt="" src="/guide/samples/images/Snake.png" />

View File

@@ -0,0 +1,7 @@
<p>This application is an example of writing an input method for a software keyboard.
This code is focused on simplicity over completeness, so it should in no way be considered
to be a complete soft keyboard implementation. Its purpose is to provide
a basic example for how you would get started writing an input method, to
be fleshed out as appropriate.</p>
<img alt="" src="/guide/samples/images/SoftKeyboard.png" />