Localization102 icon indicating copy to clipboard operation
Localization102 copied to clipboard

issue in layout

Open harshilkotecha opened this issue 6 years ago • 1 comments

i have use this library in my project this really good lib. for language change with animation . i have one problem with textField text field data not display in some case.

Uploading Simulator
Screen Shot - iPhone SE - 2018-04-28 at 17.30.14.png…

here i have one text field and text is not display .

Localizer.swift
/// Exchange the implementation of two methods of the same Class
func MethodSwizzleGivenClassName(cls: AnyClass, originalSelector: Selector, overrideSelector: Selector) {
    let origMethod: Method = class_getInstanceMethod(cls, originalSelector)!
    let overrideMethod: Method = class_getInstanceMethod(cls, overrideSelector)!
    if (class_addMethod(cls, originalSelector, method_getImplementation(overrideMethod), method_getTypeEncoding(overrideMethod))) {
        class_replaceMethod(cls, overrideSelector, method_getImplementation(origMethod), method_getTypeEncoding(origMethod))
    } else {
        //method_exchangeImplementations(origMethod, overrideMethod)
    }
}

after comment this method_exchangeImplementations line it is working fine . can you suggest alternative for this code ? or explain me what is the roll of this method ?

harshilkotecha avatar Apr 30 '18 06:04 harshilkotecha

mmm its not really clear to me what is the issue you are facing.!! have you tried using MOLH since its more current. https://github.com/MoathOthman/MOLH

MoathOthman avatar Apr 30 '18 13:04 MoathOthman