8

When using Segues in Messages Extension Application the layout gets messed up.
Is there any way to solve this issue while still using storrybord segues?

Screenshots:
(Note: The first and second View / ViewController are identical. The segue-type doesn't matter)

Expanded Presentation Style:

1Exp 2Exp


Compact Presentation Style:

1Comp 2Comp

Update 1:

The top and bottom layout guides reset after a segue

  • compact:
    • top: should be: 0 but is: 20
    • bottom: should be: 44 but is: 0
  • expanded:
    • top: should be: 86 but is: 20
    • bottom: should be: 44 but is: 0


P.S. Can someone create a new "messages-extension" tag?

4

3 に答える 3

0

私のアプリでは、viewcontroller が .expand モードに設定されています:

view.topAnchor.constraint(equalTo: self.topLayoutGuide.bottomAnchor).isActive = true

.compact モードでは false に設定します

view.topAnchor.constraint(equalTo: self.topLayoutGuide.bottomAnchor).isActive = false

それはうまくいくはずです。

于 2016-12-10T02:19:53.053 に答える