Design for Notifications The notification system allows users to keep informed about relevant and timely events in your app, such as new chat messages from a friend or a calendar event. Think of notifications as a news channel that alerts the user to important events as they happen or a log that chronicles events while the user is not paying attention - and one that is synced as appropriate across all their Android devices.32340
New in L
In L, notifications receive an important structural visual and functional update:
    Visual changes to notifications as part of material design
    Notifications are now available on the device lockscreen, yet sensitive content can still be hidden behind it
    A new presentation format called Heads-up for receiving high priority notifications while using the device
    Cloud-synced notifications - act on a notification on your Android tablet and it is also dismissed on your phone.
    And starting now (in Android 4.4W, API Level 20, the platform release for Android Wear), your notifications will bridge to Android Wear devices. You can extend the functionality of notifications on Wear in two different ways. First, you can add speech input and canned responses to Actions on Wear, allowing users to complete tasks from their wrists. Second, you can write Wear apps that hook into your notifications to go even further in terms of creating interactive experiences for users.
Anatomy of a notification
This section goes over basic parts of a notification and how they can appear on different types of devices.
Base Layout
At a minimum, all notifications consist of a base layout, including:
    The notification's icon, symbolizing the originating app, and also potentially the kind of notification if the app has several substantially different sorts of notifications it can post
    A notification title and additional text
    A timestamp
Notifications created with Notification.Builder for versions of Android earlier than L will look and work the same in L, with only minor stylistic changes that the system handles for you.
Base layout of a handheld notification and the same notification on Wear, with a user photo and a notification icon
Expanded layouts
You have the option to provide more details on notifications. You can use this to show the first few lines of a message or show a larger image preview. This provides the user with additional context, and - in some cases - may allow the user to read a message in its entirety. The user can pinch-zoom or perform a single-finger glide in order to toggle between compact and expanded layouts. For single event notifications, Android provides three expanded layout templates (text, inbox, and image) for you to re-use in your application.
Actions
Android has supported optional actions that are displayed at the bottom of the notification, as far back as Jelly Bean. With actions, users can handle the most common tasks for a particular notification from within the notification shade without having to open the originating application. This speeds up interaction and, in conjunction with "swipe-to-dismiss", helps users to streamline their notification triaging experience.
Be judicious with how many actions you include with a notification. The more actions you include, the more cognitive complexity you create. Limit yourself to the fewest number of actions possible by only including the most imminently important and meaningful ones.
Good candidates for actions on notifications are actions that:
    Are essential, frequent and typical for the content type you're displaying
    Allow the user to accomplish tasks quickly
Avoid actions that are:
    Ambiguous
    Duplicative of the default action of the notification (such as "Read" or "Open")
上一篇:软件测试和软件开发生命周期英文文献和翻译
下一篇:C#英文文献和中文翻译

AngularJS技术介绍英文文献和中文翻译

开关电源水冷却系统英文文献和中文翻译

减数分裂和基因重组英文文献和中文翻译

太阳能最大功率点追踪和...

移动码头的泊位分配问题英文文献和中文翻译

虚拟船舶装配集成建模方...

中学生科学探究中对等论...

STC89C52单片机NRF24L01的无线病房呼叫系统设计

提高教育质量,构建大學生...

浅论职工思想政治工作茬...

酵母菌发酵生产天然香料...

浅谈高校行政管理人员的...

上海居民的社会参与研究

基于Joomla平台的计算机学院网站设计与开发

从政策角度谈黑龙江對俄...

AES算法GPU协处理下分组加...

压疮高危人群的标准化中...