From 1aab8729fafd3bf9b4fb7cc889e9682298b9ba9d Mon Sep 17 00:00:00 2001 From: Yun Chan Date: Sat, 15 Aug 2026 14:49:02 +0900 Subject: [PATCH] refactor(1): move Detection (MediaDetector/SocialSiteDetector/DetectionContext) App->Core --- VideoDownloader.App/Core/DownloadManager.cs | 2 +- VideoDownloader.App/MainWindow.xaml.cs | 2 +- VideoDownloader.App/ViewModels/DownloadItemViewModel.cs | 2 +- .../Detection/DetectionContext.cs | 2 +- .../Detection/MediaDetector.cs | 2 +- .../Detection/SocialSiteDetector.cs | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) rename {VideoDownloader.App => VideoDownloader.Core}/Detection/DetectionContext.cs (88%) rename {VideoDownloader.App => VideoDownloader.Core}/Detection/MediaDetector.cs (99%) rename {VideoDownloader.App => VideoDownloader.Core}/Detection/SocialSiteDetector.cs (99%) diff --git a/VideoDownloader.App/Core/DownloadManager.cs b/VideoDownloader.App/Core/DownloadManager.cs index 8ccf3f3..e117090 100644 --- a/VideoDownloader.App/Core/DownloadManager.cs +++ b/VideoDownloader.App/Core/DownloadManager.cs @@ -3,7 +3,7 @@ using System.Net; using System.Net.Http; using System.Windows.Data; using Microsoft.Web.WebView2.Core; -using VideoDownloader.App.Detection; +using VideoDownloader.Core.Detection; using VideoDownloader.App.ViewModels; using VideoDownloader.Core.Config; using VideoDownloader.Core.Dash; diff --git a/VideoDownloader.App/MainWindow.xaml.cs b/VideoDownloader.App/MainWindow.xaml.cs index a8e26a4..2c0c9bf 100644 --- a/VideoDownloader.App/MainWindow.xaml.cs +++ b/VideoDownloader.App/MainWindow.xaml.cs @@ -12,7 +12,7 @@ using Microsoft.Web.WebView2.Core; using VideoDownloader.App.Browser; using VideoDownloader.App.Browser.Tabs; using VideoDownloader.App.Core; -using VideoDownloader.App.Detection; +using VideoDownloader.Core.Detection; using VideoDownloader.App.ViewModels; using VideoDownloader.Core.Config; using Wv2 = Microsoft.Web.WebView2.Wpf; diff --git a/VideoDownloader.App/ViewModels/DownloadItemViewModel.cs b/VideoDownloader.App/ViewModels/DownloadItemViewModel.cs index 746cfc7..e2e101c 100644 --- a/VideoDownloader.App/ViewModels/DownloadItemViewModel.cs +++ b/VideoDownloader.App/ViewModels/DownloadItemViewModel.cs @@ -1,7 +1,7 @@ using System.Collections.ObjectModel; using System.ComponentModel; using System.Runtime.CompilerServices; -using VideoDownloader.App.Detection; +using VideoDownloader.Core.Detection; using VideoDownloader.Core.Social; namespace VideoDownloader.App.ViewModels; diff --git a/VideoDownloader.App/Detection/DetectionContext.cs b/VideoDownloader.Core/Detection/DetectionContext.cs similarity index 88% rename from VideoDownloader.App/Detection/DetectionContext.cs rename to VideoDownloader.Core/Detection/DetectionContext.cs index bea8984..950d3a1 100644 --- a/VideoDownloader.App/Detection/DetectionContext.cs +++ b/VideoDownloader.Core/Detection/DetectionContext.cs @@ -1,4 +1,4 @@ -namespace VideoDownloader.App.Detection; +namespace VideoDownloader.Core.Detection; public enum MediaKind { Hls, Dash, Direct, Social } diff --git a/VideoDownloader.App/Detection/MediaDetector.cs b/VideoDownloader.Core/Detection/MediaDetector.cs similarity index 99% rename from VideoDownloader.App/Detection/MediaDetector.cs rename to VideoDownloader.Core/Detection/MediaDetector.cs index f17539c..8975560 100644 --- a/VideoDownloader.App/Detection/MediaDetector.cs +++ b/VideoDownloader.Core/Detection/MediaDetector.cs @@ -1,6 +1,6 @@ using VideoDownloader.Core.Config; -namespace VideoDownloader.App.Detection; +namespace VideoDownloader.Core.Detection; /// 요청(URL + content-type + 길이)과 설정으로 미디어 종류를 판정. public static class MediaDetector diff --git a/VideoDownloader.App/Detection/SocialSiteDetector.cs b/VideoDownloader.Core/Detection/SocialSiteDetector.cs similarity index 99% rename from VideoDownloader.App/Detection/SocialSiteDetector.cs rename to VideoDownloader.Core/Detection/SocialSiteDetector.cs index e475343..55ca334 100644 --- a/VideoDownloader.App/Detection/SocialSiteDetector.cs +++ b/VideoDownloader.Core/Detection/SocialSiteDetector.cs @@ -1,6 +1,6 @@ using System.Text.RegularExpressions; -namespace VideoDownloader.App.Detection; +namespace VideoDownloader.Core.Detection; /// /// 소셜 영상 페이지(YouTube/Shorts/Instagram/X/TikTok/Facebook) 판별 + URL 정규화.