From 658a84310017e5d4c9cc906e100fd9b6e73b6387 Mon Sep 17 00:00:00 2001 From: 0Hooni Date: Mon, 2 Dec 2024 19:57:03 +0900 Subject: [PATCH 1/2] =?UTF-8?q?fix/#164=20::=20view.isExclusiveTouch?= =?UTF-8?q?=EB=A5=BC=20=EC=BC=9C=EC=A4=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - view를 터치한 채로 다른 탭을 방지함 - 유저가 스티커를 다중으로 잡는 문제를 방지 Co-Authored-By: seuhong <66902876+hsw1920@users.noreply.github.com> --- .../EditPhotoRoomFeature/Source/View/StickerView.swift | 1 + 1 file changed, 1 insertion(+) diff --git a/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift b/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift index 68dc54b9..0be19331 100644 --- a/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift +++ b/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift @@ -104,6 +104,7 @@ final class StickerView: UIView { isUserInteractionEnabled = true let tapGesture = UITapGestureRecognizer(target: self, action: #selector(handleTap)) + self.isExclusiveTouch = true addGestureRecognizer(tapGesture) dragPanGestureRecognizer.minimumNumberOfTouches = 1 From 7875c6ce3809b9c41cede10a106f27d6a453c605 Mon Sep 17 00:00:00 2001 From: 0Hooni Date: Mon, 2 Dec 2024 20:22:33 +0900 Subject: [PATCH 2/2] =?UTF-8?q?fix/#164=20::=20=EB=8B=A4=EB=A5=B8=20?= =?UTF-8?q?=EB=8B=A4=EC=A4=91=20=ED=83=AD=20=EC=83=81=ED=99=A9=EB=8F=84=20?= =?UTF-8?q?=EB=B0=A9=EC=A7=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-Authored-By: seuhong <66902876+hsw1920@users.noreply.github.com> --- .../DesignSystem/DesignSystem/Source/PTGGrayButton.swift | 1 + .../Source/EditPhotoHostBottomView.swift | 1 + .../EditPhotoRoomFeature/Source/View/StickerView.swift | 5 ++++- 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/PhotoGether/PresentationLayer/DesignSystem/DesignSystem/Source/PTGGrayButton.swift b/PhotoGether/PresentationLayer/DesignSystem/DesignSystem/Source/PTGGrayButton.swift index 10231ceb..7c6725cb 100644 --- a/PhotoGether/PresentationLayer/DesignSystem/DesignSystem/Source/PTGGrayButton.swift +++ b/PhotoGether/PresentationLayer/DesignSystem/DesignSystem/Source/PTGGrayButton.swift @@ -40,6 +40,7 @@ public final class PTGGrayButton: UIButton { private func configureUI() { backgroundColor = .gray85 layer.cornerRadius = 12 + isExclusiveTouch = true stackView.axis = .horizontal stackView.distribution = .equalSpacing diff --git a/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/EditPhotoHostBottomView.swift b/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/EditPhotoHostBottomView.swift index ef1d94ec..11903b3b 100644 --- a/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/EditPhotoHostBottomView.swift +++ b/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/EditPhotoHostBottomView.swift @@ -69,5 +69,6 @@ final class EditPhotoHostBottomView: UIView { nextButton.backgroundColor = PTGColor.primaryGreen.color nextButton.setImage(PTGImage.chevronRightBlack.image, for: .normal) nextButton.layer.cornerRadius = 8 + nextButton.isExclusiveTouch = true } } diff --git a/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift b/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift index 0be19331..42853ffc 100644 --- a/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift +++ b/PhotoGether/PresentationLayer/EditPhotoRoomFeature/EditPhotoRoomFeature/Source/View/StickerView.swift @@ -80,6 +80,8 @@ final class StickerView: UIView { } private func configureUI() { + isExclusiveTouch = true + let deleteButtonImage = PTGImage.xmarkIcon.image layerView.layer.borderWidth = 2 layerView.layer.borderColor = PTGColor.primaryGreen.color.cgColor @@ -88,11 +90,13 @@ final class StickerView: UIView { deleteButton.setImage(deleteButtonImage, for: .normal) deleteButton.layer.cornerRadius = deleteButton.bounds.width / 2 deleteButton.clipsToBounds = true + deleteButton.isExclusiveTouch = true let resizeButtonImage = PTGImage.resizeIcon.image resizeButton.setImage(resizeButtonImage, for: .normal) resizeButton.layer.cornerRadius = resizeButton.bounds.width / 2 resizeButton.clipsToBounds = true + resizeButton.isExclusiveTouch = true setImage(to: sticker.image) updateOwnerUI(owner: sticker.owner) @@ -104,7 +108,6 @@ final class StickerView: UIView { isUserInteractionEnabled = true let tapGesture = UITapGestureRecognizer(target: self, action: #selector(handleTap)) - self.isExclusiveTouch = true addGestureRecognizer(tapGesture) dragPanGestureRecognizer.minimumNumberOfTouches = 1