Skip to content

Commit

Permalink
πŸ”¨[FIX] #129 - μ½”λ“œ μˆœμ„œ λ³€κ²½, 정리
Browse files Browse the repository at this point in the history
  • Loading branch information
jumining committed Mar 3, 2022
1 parent 914c13e commit f945bbf
Showing 1 changed file with 5 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -181,26 +181,25 @@ extension StudioMapViewController {
let markerInfo = Studio(id: $0.id, lati: $0.lati, long: $0.long)
marker.iconImage = NMFOverlayImage(image: Asset.icnStudio.image)

self.selectedMarkerInfo = markerInfo
StudioMapViewController.selectedMarkerID = markerInfo.id
self.studioInfoWithAPI(studioID: markerInfo.id)

marker.touchHandler = { [weak self] (overlay: NMFOverlay) -> Bool in
if self?.selectedMarker == nil { /// ν΄λ¦­ν–ˆλ˜ ν˜„μƒμ†Œκ°€ μ—†λŠ” 경우 (지도뷰 처음 λ“€μ–΄μ˜¬ λ–„)
self?.selectedMarker = marker
self?.selectedMarker?.iconImage = NMFOverlayImage(image: Asset.icnStudioSelected.image)
self?.showBottomSheet()
self?.selectedMarkerInfo = markerInfo
StudioMapViewController.selectedMarkerID = markerInfo.id
self?.studioInfoWithAPI(studioID: markerInfo.id)
// TODO: - 카메라 이동 (톡신 ν•„μš”)
} else {
if self?.selectedMarker == marker { /// ν΄λ¦­ν–ˆλ˜ ν˜„μƒμ†Œλ₯Ό λ‹€μ‹œ ν΄λ¦­ν•˜λŠ” 경우
self?.selectedMarker?.iconImage = NMFOverlayImage(image: Asset.icnStudio.image)
self?.selectedMarker = nil
self?.selectedMarker?.iconImage = NMFOverlayImage(image: Asset.icnStudio.image)
self?.hideBottomSheetAndGoBack()
} else { /// λ‹€λ₯Έ ν˜„μƒμ†Œ 클릭
self?.selectedMarker?.iconImage = NMFOverlayImage(image: Asset.icnStudio.image)
self?.selectedMarker = marker
self?.selectedMarker?.iconImage = NMFOverlayImage(image: Asset.icnStudioSelected.image)
self?.showBottomSheet()
// TODO: - 카메라 이동 (톡신 ν•„μš”)
}
}
return true
Expand Down

0 comments on commit f945bbf

Please sign in to comment.