Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to implement 3D-Touch Peek-and-select?

Phone, Reminders, and Maps use a different 3D-Touch Peek UI allowing to select an action in one go. For instance, force-press on a reminder and select "Remind me on a day" in one go, without releasing the finger. It also differs visually from standard 3D Touch previews using the UIViewControllerPreviewing API as it displays a custom icon alongside left-aligned text.

enter image description here

I couldn't find a way to do this using the official API. Did I miss something or is this a private API indeed?

like image 423
Ortwin Gentz Avatar asked Sep 29 '15 10:09

Ortwin Gentz


People also ask

What is peek and pop?

By giving the screen varying levels of pressure, a user can do things like preview a page using Peek, then Pop to the previewed page.

What is 3D Touch on iPhone?

Apple 3D Touch is a hardware-based feature Apple introduced in iPhone 6s and 6s Plus devices running iOS 9 that perceives the amount of force a user puts on the touch screen to activate different functions. With Apple 3D Touch, users can take actions without navigating away from the original screen they were on.


2 Answers

I asked my question on the Apple Developer Forums as well and received this reply from Apple:

Currently there is not public API to do these things. Please file bug reports if this is something you want to do in your app, and include specific details of what you're looking to do.

So it's currently not possible using the official SDK. I filed this enhancement request radar and I encourage you to dupe it if you need this, too!

like image 120
Ortwin Gentz Avatar answered Oct 01 '22 04:10

Ortwin Gentz


For future readers, the response from Apple for this question is:

Currently there is not public API to do these things. Please file bug reports if this is something you want to do in your app, and include specific details of what you're looking to do.

Source: Apple Developer Forum

like image 20
julien_c Avatar answered Oct 01 '22 04:10

julien_c