diff --git a/iOS/Features/RewindJourney/RewindJourneyDemo/RewindJourneyDemo/SceneDelegate.swift b/iOS/Features/RewindJourney/RewindJourneyDemo/RewindJourneyDemo/SceneDelegate.swift index da35ddf..8c34490 100644 --- a/iOS/Features/RewindJourney/RewindJourneyDemo/RewindJourneyDemo/SceneDelegate.swift +++ b/iOS/Features/RewindJourney/RewindJourneyDemo/RewindJourneyDemo/SceneDelegate.swift @@ -29,8 +29,8 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate { MSFont.registerFonts() let repository = SpotRepositoryImplementation() - let viewModel = RewindJourneyViewModel(photoURLs: [URL(string: "https://www.google.com/url?sa=i&url=https%3A%2F%2Fm.youtube.com%2Fwatch%3Fv%3DWs5VJ1Ig1EY&psig=AOvVaw3vmGcqNwsTcGM-J59la6qB&ust=1702326229170000&source=images&cd=vfe&opi=89978449&ved=0CBEQjRxqFwoTCNDNosTZhYMDFQAAAAAdAAAAABAD")!, - URL(string: "https://www.google.com/url?sa=i&url=https%3A%2F%2Fnamu.wiki%2Fw%2F%25EC%25BC%2580%25EC%259D%25B8%2528%25EC%259D%25B8%25ED%2584%25B0%25EB%2584%25B7%2520%25EB%25B0%25A9%25EC%2586%25A1%25EC%259D%25B8%2529%2F%25EB%25B0%2588&psig=AOvVaw0qY6irtYIsc68tIwsIwJF4&ust=1702326282656000&source=images&cd=vfe&opi=89978449&ved=0CBEQjRxqFwoTCOjSpt3ZhYMDFQAAAAAdAAAAABAD")!], repository: repository) + let viewModel = RewindJourneyViewModel(photoURLs: [URL(string: "")!, + URL(string: "")!], repository: repository) let viewController = RewindJourneyViewController(viewModel: viewModel) window.rootViewController = viewController diff --git a/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/MSProgressView.swift b/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/MSProgressView.swift index a11bedd..7b76111 100644 --- a/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/MSProgressView.swift +++ b/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/MSProgressView.swift @@ -67,7 +67,6 @@ public final class MSProgressView: UIProgressView { self.progressViewModel.timerPublisher .sink { [weak self] currentPercentage in self?.percentage = currentPercentage - print(currentPercentage) } .store(in: &timerSubscriber) } diff --git a/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewController.swift b/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewController.swift index ed049d7..93f9add 100644 --- a/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewController.swift +++ b/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewController.swift @@ -50,7 +50,6 @@ public final class RewindJourneyViewController: UIViewController { private var cancellables: Set = [] private var presentingImageIndex: Int? { didSet { - print("\(self.presentingImageIndex)번이 선택됨") self.changeProgressViews() } } @@ -119,7 +118,7 @@ public final class RewindJourneyViewController: UIViewController { private func timerBinding() { self.viewModel.state.timerPublisher .sink { [weak self] _ in - self?.rightTouchViewDidTap() + DispatchQueue.main.async { self?.rightTouchViewDidTap() } } .store(in: &self.timerSubscriber) } diff --git a/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewModel.swift b/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewModel.swift index 18447aa..0c5b41e 100644 --- a/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewModel.swift +++ b/iOS/Features/RewindJourney/Sources/RewindJourney/Presentation/RewindJourneyViewModel.swift @@ -85,6 +85,7 @@ private extension RewindJourneyViewModel { func startTimer() { self.timer = Timer.publish(every: self.timerTimeInterval, on: .main, in: .common) .autoconnect() + .receive(on: DispatchQueue.global(qos: .background)) .sink { [weak self] _ in self?.state.timerPublisher.send() }