Scroll Essential Android 2.3 Manual de usuario Pagina 18

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 47
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 17
Android Wear Docs, Release 1.1
Android Wear adds even more styles that improve the user experience on the small screen of a wearable device. These
styles make it possible to group or add pages to notifications. The email example shows how messages are grouped to
reduce the number of notification delivered to a wearable.
You do not have to rely any of these stock UI styles. You can create your own full-screen layout that best suits your
custom wearable application. Just keep it simple and be consistent in presentation and usage with other wearable
displays. For example, do not try to replicate the grid layout of the handheld device - the wearable is just too small for
this approach. Users just glance at their watch, speak simple commands, or tap and swipe the screen.
3.1 First Android Wear Suggest
This section explains how to create your first Android Wear notification and add it to the Suggest context stream on an
Android wearable, or emulator. The new project wizard in Android Studio creates a project with two main activities,
one for the handheld device and another for the wearable. To create your first suggest notification, add code in the
handheld activity only, located in the “mobile” branch of the project hierarchy. The preinstalled software on a wearable
device or emulator handles the task of receiving and displaying notifications from the handheld.
3.1.1 Create a Project
This section explains how to create a new project using Android Studio Version 1. If you have an earlier version,
update it before starting this procedure.
1. Launch Android Studio.
2. Select Start a New Android Studio Project in the Welcome screen.
3. In the new project dialog, enter your Application Name, Domain, and a project directory. Click Next.
4. In the form factors dialog, select Phone and Tablet and Wear. Keep the default SDKs, and then click Next.
5. In the mobile activity dialog, select Blank Activity. Click Next.
6. In the mobile option dialog enter an Activity Name for the handheld. Accept the defaults or the other fields and
click Next. The name for an activity that generates a wearable “suggestion” might be SuggestActivity.
7. In the wear activity dialog, select Blank Wear Activity. Then click Next.
8. In the wear options dialog enter an Activity Name for the wearable. Accept the defaults for the other fields and
click Finish. You can use the same name for the wearable activity that you used for the handheld activity.
14 Chapter 3. Android Wear Suggest
Vista de pagina 17
1 2 ... 13 14 15 16 17 18 19 20 21 22 23 ... 46 47

Comentarios a estos manuales

Sin comentarios