2017-04-26 2 views
0

In meiner Anwendung bin ich Layout-Richtung von rechts nach links, meine Anwendung funktioniert gut auf tvOS 9, aber wenn ich meine Anwendung auf tvOS 10 läuft es in Links nach rechts Layoutrichtung läuft. Es sieht so aus, als ob OS setSemanticContentAttribute ignoriert. Ich verwende folgenden Code.setSemanticContentAttribute: funktioniert nicht in tvOS 10

if(IOS9) { 
    [[UINavigationBar appearance] setSemanticContentAttribute:UISemanticContentAttributeForceLeftToRight]; 
    [[UITabBar appearance] setSemanticContentAttribute:UISemanticContentAttributeForceRightToLeft]; 
    if ([[[UIView alloc] init] respondsToSelector:@selector(setSemanticContentAttribute:)]) { 
     [[UIView appearance] setSemanticContentAttribute:UISemanticContentAttributeForceRightToLeft]; 
     [[UILabel appearance] setSemanticContentAttribute:UISemanticContentAttributeForceRightToLeft]; 
     [[UITableView appearance] setSemanticContentAttribute:UISemanticContentAttributeForceRightToLeft]; 
     [[UICollectionView appearance] setSemanticContentAttribute:UISemanticContentAttributeForceRightToLeft]; 
     [[UIButton appearance] setSemanticContentAttribute:UISemanticContentAttributeForceRightToLeft]; 
    } 
}else{ 
    if ([[[UIView alloc] init] respondsToSelector:@selector(setSemanticContentAttribute:)]) { 
     [[UIView appearance] setSemanticContentAttribute:UISemanticContentAttributeForceRightToLeft]; 
    } 
} 

Antwort

0

Wenn Sie den Wert der Eigenschaft semanticContentAttribute in tvOS forceRightToLeft hat keine Wirkung. Die Ansichten werden sowieso von links nach rechts hinzugefügt.

Dies ist ein Fehler in tvOS https://openradar.appspot.com/31138095

Verwandte Themen