Skip to content

Commit

Permalink
forcing semanticeContentAttribute for uibutotn textview and uitextfield
Browse files Browse the repository at this point in the history
  • Loading branch information
dark2torch committed Jan 18, 2019
1 parent 213e0ad commit 3e29ec0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion MOLH.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Pod::Spec.new do |s|


s.name = "MOLH"
s.version = "0.5"
s.version = "0.6"
s.summary = "Localization helper for iOS apps mainly focusing on the LTR/RTL issue Edit"

s.description = <<-DESC
Expand Down
6 changes: 6 additions & 0 deletions MOLH/MOLH.swift
Original file line number Diff line number Diff line change
Expand Up @@ -132,8 +132,14 @@ open class MOLH {
MOLHLanguage.setAppleLAnguageTo(language)
if MOLHLanguage.isRTLLanguage() {
UIView.appearance().semanticContentAttribute = .forceRightToLeft
UIButton.appearance().semanticContentAttribute = .forceRightToLeft
UITextView.appearance().semanticContentAttribute = .forceRightToLeft
UITextField.appearance().semanticContentAttribute = .forceRightToLeft
} else {
UIView.appearance().semanticContentAttribute = .forceLeftToRight
UIButton.appearance().semanticContentAttribute = .forceLeftToRight
UITextView.appearance().semanticContentAttribute = .forceLeftToRight
UITextField.appearance().semanticContentAttribute = .forceLeftToRight
}
}

Expand Down

0 comments on commit 3e29ec0

Please sign in to comment.