Lollipop 5.0 introduced sliding heads-up notifications instead of the scrolling status bar ticker that had been used on all Android versions prior. They showed up on top of your current screen for a few seconds, then went back into the notification tray. However, the function still seemed quite unfinished, with notifications blocking everything underneath them unless you completely got rid of them or waited for them to disappear. Lollipop 5.1 made it possible to dismiss notifications with a swipe up, sending them back to the tray so you can check them later.

Android M makes this functionality optional, and that's one very welcome change. Each app's settings page has an "App notifications" screen where you can block all notifications from the selected app, treat them as priority, and "Allow peeking." The latter enables the heads-up sliding notifications on top of other apps. If it's disabled, the app will still send its notifications directly into the tray.

This is one of M's multiple new granular control options per app. You could, for example, have important apps surface their notifications to you through peeking, but block something like Candy Crush from disturbing you while you're in other apps, instead just showing a regular notification in the tray.