objective c - compatibility DAKeyboard in iOS 9 -
i'm using dakeyboard
in app , since ios 9 many app viber
, ... problem panning gesture dismiss keyboard component. dakeyboard ios 9 support
a person write code finding keyboard in ios 9 , it's working in portrait.
problem
but many problem happen in landscape
mode. know how can fix ?
-(uiview*) findinputsethostview { if([[[uidevice currentdevice] systemversion] floatvalue] >= 9.0 && [uiapplication sharedapplication].statusbarorientation == uiinterfaceorientationportrait ) { for(uiwindow* window in [[uiapplication sharedapplication] windows]) if([window iskindofclass:nsclassfromstring(@"uiremotekeyboardwindow")]) for(uiview* subview in window.subviews) if([subview iskindofclass:nsclassfromstring(@"uiinputsethostview")]) for(uiview* subsubview in subview.subviews) if([subsubview iskindofclass:nsclassfromstring(@"uiinputsethostview")]) return subsubview; } else return self.keyboardactiveinput.inputaccessoryview.superview; return nil; }
update
only preventing bad behavior in landscape , have checked orientation in code
Comments
Post a Comment