Handing over your phone to a friend or acquaintance who "just needs to make a call" can be a little nerve-wracking. Sure, this person probably won't poke around in your email or secretly send your private pictures to their Dropbox account, but you would feel better if you could be certain. Lollipop has just the feature to keep your phone secure in the hands of your friends: Screen Pinning. Now you can lock a single app into the foreground, and nobody will be able to sneak a peek at your web history.

Screen Pinning appears to be born from a developer-oriented feature called Task Locking that we covered back when the L Developer Preview was announced. To use it, you'll first have to open Settings -> Security and enable Screen pinning at the bottom of the list. Activating it simply requires opening the Recents screen and tapping on the little push-pin button in the lower right corner of the front-most card. Once an app has been pinned, the Home and Recent navigation buttons will cease to do anything, and the back button will only function within the app. The icons on the status bar will also fade out, and the notification shade becomes inaccessible. Holding the Back and Recent buttons at the same time will escape from Pinned mode.

If the screen of the phone is turned off and back on, pinned apps thoughtfully remain active, so people won't have to constantly tap the screen to keep it alive. If you've enabled security of some kind (e.g. password, pattern unlock), an option becomes available to have the lockscreen reactivated when a user tries to leave the app. Unfortunately, there's no way to return to the pinned app once the lockscreen comes on.

With the ability to lock the screen to a single app, we don't have to worry about pranksters messing with our settings or snoopy people digging around in our private stuff. This will also be a great way for parents to hand their phone over to a kid to play a game. Keep in mind, there is no way to block features inside of an app, so people can still wander through your contact list in the dialer or hit web history if you've pinned your browser. Still, this is far better than giving somebody total access to one of our most important tools.

Update: We've discovered an interesting inconsistency in Screen Pinning. It turns out that some devices require the use of both the back button and the recents (a.k.a. overview) buttons to unpin, while other devices only require a long-press on the recents button. After a little bit of digging, I found the relevant strings in AOSP, and discovered that the distinction has to do with Accessibility Mode. If any service is enabled in Settings -> Accessibility, it will turn on Accessibility Mode, and unpinning the screen will only require a long-press on recents. Common examples of these types of services include LastPass or Password Box (for the auto-fill feature for apps), Talk Back, Switch Access, and others.