Tom Coomer Tom Coomer - 1 year ago 142
Swift Question

Disable iMessage App Resizing

I am developing an iMessage app for iPhone. It currently allows the user to press the arrow to resize the app from keyboard size to full screen. For my app, the full screen view is not necessary.

Is it possible to disable the resizing in the iMessage app?

Thank you

Answer Source

I'm afraid this arrow will always call the full screen layout. You'll have to handle both. But here are some ideas:

  • When the user tap the arrow, it will fire the method didTransition(to: MSMessagesAppPresentationStyle). So you could requestPresentationStyle(_ presentationStyle: MSMessagesAppPresentationStyle) with a compact mode. So that when ever it try to go in full screen, it will go back to compact mode
  • Also I'm not sure, but you could maybe use requestPresentationStyle(_ presentationStyle: MSMessagesAppPresentationStyle) to always present compact mode, instead of extend mode.

Also have a look here :

They say this :

Note, however, that the user should have ultimate control over the extension’s presentation style. If the user chooses to change the presentation style, you should respect that choice.

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download