Skip to content

Commit

Permalink
Merge pull request #30 from p-x9/feature/release-window-when-keyboard…
Browse files Browse the repository at this point in the history
…-is-shown

fix to release point windows when keyboard is displayed
  • Loading branch information
p-x9 authored Sep 5, 2023
2 parents 5e5595f + 3900036 commit bafb63b
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Sources/TouchTracker/Cocoa/TouchTrackingUIView.swift
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public class TouchTrackingUIView: UIView {
pointWindows[touches.count..<pointWindows.count].forEach {
$0.isHidden = true
$0.windowScene = nil
$0.removeFromSuperview()
$0.uiviewRemoveFormSuperView()
}
pointWindows = Array(pointWindows[0..<touches.count])
}
Expand Down
6 changes: 6 additions & 0 deletions Sources/TouchTracker/Extension/UIWindow+.swift
Original file line number Diff line number Diff line change
Expand Up @@ -76,4 +76,10 @@ extension UIWindow {
}
}

extension UIWindow {
func uiviewRemoveFormSuperView() {
super.removeFromSuperview()
}
}

#endif

0 comments on commit bafb63b

Please sign in to comment.