How to display UIView over keyboard in iOS

前端 未结 7 951
醉话见心
醉话见心 2020-12-05 20:04

I want to create a simple view over keyboard, when users tap \"Attach\" button in inputAccessoryView. Something like this:

Is there an easy way to do it? O

7条回答
  •  猫巷女王i
    2020-12-05 20:34

    Do you have find some effective method to solve this problem? In iOS9,you put your customView on the top of the windows:

    UIApplication.sharedApplication().windows[windowCount-1].addSubview(customView);
    

    But if the keyboard dismisses, the top Windows will be removed, so your customView will be removed. Looking forward for your help! Thank you for your help!

提交回复
热议问题