ارفع راسك فوق انته سوري حر ... :green_heart::green_heart:

Skip to content
Snippets Groups Projects
Commit eea2d36c authored by Mustafa Merza's avatar Mustafa Merza
Browse files

- Fixed middle button tapping area to be on the buttons frame.

parent c4e1cade
Branches
No related tags found
No related merge requests found
......@@ -42,6 +42,8 @@ class AppTabBarController: UITabBarController, UITabBarControllerDelegate, Walkt
tabBar.items?[0].image = .folderOpen
tabBar.items?[2].image = .gallery
tabBar.items?[1].isEnabled = false
}
private func loadLocalization() {
......@@ -134,7 +136,7 @@ class AppTabBar: UITabBar, CustomTabBarLayerProtocol {
let from = point
let to = middleButton.center
return sqrt((from.x - to.x) * (from.x - to.x) + (from.y - to.y) * (from.y - to.y)) <= 120 ? middleButton : super.hitTest(point, with: event)
return sqrt((from.x - to.x) * (from.x - to.x) + (from.y - to.y) * (from.y - to.y)) <= middleButton.frame.height / 2 ? middleButton : super.hitTest(point, with: event)
}
override func layoutSubviews() {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment