Skip to content

Commit 4ddcf7a

Browse files
committed
fix/#87-watch issue 모두 해결
1 parent 1a65fdd commit 4ddcf7a

File tree

16 files changed

+286
-154
lines changed

16 files changed

+286
-154
lines changed

hearo/HearoadWatch Watch App/Assets.xcassets/MainCircle.appiconset/Contents.json

Lines changed: 0 additions & 14 deletions
This file was deleted.
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "MainCircle.svg",
5+
"idiom" : "universal",
6+
"scale" : "1x"
7+
},
8+
{
9+
"filename" : "MainCircle 1.svg",
10+
"idiom" : "universal",
11+
"scale" : "2x"
12+
},
13+
{
14+
"filename" : "MainCircle 2.svg",
15+
"idiom" : "universal",
16+
"scale" : "3x"
17+
}
18+
],
19+
"info" : {
20+
"author" : "xcode",
21+
"version" : 1
22+
}
23+
}
Lines changed: 37 additions & 0 deletions
Loading
Lines changed: 37 additions & 0 deletions
Loading
Lines changed: 37 additions & 0 deletions
Loading

hearo/HearoadWatch Watch App/ContentView.swift

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,28 @@ struct ContentView: View {
1212
@ObservedObject var sessionManager = WatchSessionManager.shared
1313

1414
var body: some View {
15+
16+
17+
1518
ZStack {
1619
// 배경색을 alert 상태에 따라 변경
1720
sessionManager.isAlerting ? Color.red.edgesIgnoringSafeArea(.all) : Color.black.edgesIgnoringSafeArea(.all)
18-
21+
22+
1923
// 알림 상태에 따른 아이콘 표시
20-
if sessionManager.isAlerting {
24+
if sessionManager.isAlerting {
2125
Image(sessionManager.alertImageName())
2226
.resizable()
2327
.scaledToFit()
2428
.frame(width: 200, height: 200)
2529
.padding()
26-
} else {
27-
// 알림이 아닐 때는 MainCircle 이미지를 표시
28-
Image("MainCircle")
29-
.resizable()
30-
.frame(width: 200, height: 200)
31-
.padding()
32-
}
30+
}
31+
else{
32+
Image("MainCircle")
33+
.resizable()
34+
.frame(width: 200, height: 200)
35+
.padding()
36+
}
3337
}
3438
.onAppear {
3539
// 초기화

hearo/HearoadWatch Watch App/WatchSessionManager.swift

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,18 +43,29 @@ class WatchSessionManager: NSObject, ObservableObject, WCSessionDelegate {
4343
case "Bicyclebell":
4444
return "Bicycle" // bicycle 이미지 이름
4545
default:
46-
return "exclamationmark.triangle.fill" // 기본 알림 아이콘
46+
return "Car" // 기본 알림 아이콘
4747
}
4848
}
4949

5050
// 3초 동안 알림 표시 후 기본 상태로 복구
5151
func showAlert(with message: String) {
52+
// "녹음 시작 전" 메시지는 무시
53+
guard message != "녹음 시작 전" else {
54+
print("메시지 무시: \(message)")
55+
return
56+
}
57+
5258
alertMessage = message
5359
isAlerting = true
5460

5561
// 강한 진동 알림 발생
5662
playUrgentHapticPattern()
5763

64+
// UI 업데이트: 빨간 배경, 아이콘 표시
65+
DispatchQueue.main.async {
66+
print("UI 업데이트 - 배경색: 빨간색, 메시지: \(message)")
67+
}
68+
5869
// 3초 후에 기본 상태로 복구
5970
DispatchQueue.main.asyncAfter(deadline: .now() + 3) {
6071
self.resetAlert()
@@ -79,6 +90,7 @@ class WatchSessionManager: NSObject, ObservableObject, WCSessionDelegate {
7990
func resetAlert() {
8091
alertMessage = "인식중"
8192
isAlerting = false
93+
print("UI 상태 복구 - 배경색: 검정, 메시지: 기본 상태")
8294
}
8395

8496
// WCSession 활성화 완료 시 호출되는 메서드

hearo/hearo.xcodeproj/project.pbxproj

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1015,8 +1015,8 @@
10151015
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
10161016
CODE_SIGN_STYLE = Automatic;
10171017
CURRENT_PROJECT_VERSION = 1;
1018-
DEVELOPMENT_ASSET_PATHS = "\"hearo/Preview Content\"";
1019-
DEVELOPMENT_TEAM = GT56H2MYWV;
1018+
DEVELOPMENT_ASSET_PATHS = "hearo/Preview\\ Content HearoadWatch\\ Watch\\ App";
1019+
DEVELOPMENT_TEAM = J5N8Y9F8Z8;
10201020
ENABLE_PREVIEWS = YES;
10211021
GENERATE_INFOPLIST_FILE = YES;
10221022
INFOPLIST_FILE = hearo/Info.plist;
@@ -1049,8 +1049,8 @@
10491049
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
10501050
CODE_SIGN_STYLE = Automatic;
10511051
CURRENT_PROJECT_VERSION = 1;
1052-
DEVELOPMENT_ASSET_PATHS = "\"hearo/Preview Content\"";
1053-
DEVELOPMENT_TEAM = GT56H2MYWV;
1052+
DEVELOPMENT_ASSET_PATHS = "hearo/Preview\\ Content HearoadWatch\\ Watch\\ App";
1053+
DEVELOPMENT_TEAM = J5N8Y9F8Z8;
10541054
ENABLE_PREVIEWS = YES;
10551055
GENERATE_INFOPLIST_FILE = YES;
10561056
INFOPLIST_FILE = hearo/Info.plist;
@@ -1155,8 +1155,8 @@
11551155
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
11561156
CODE_SIGN_STYLE = Automatic;
11571157
CURRENT_PROJECT_VERSION = 1;
1158-
DEVELOPMENT_ASSET_PATHS = "\"HearoadWatch Watch App/Preview Content\"";
1159-
DEVELOPMENT_TEAM = GT56H2MYWV;
1158+
DEVELOPMENT_ASSET_PATHS = "hearo HearoadWatch\\ Watch\\ App/Preview\\ Content";
1159+
DEVELOPMENT_TEAM = J5N8Y9F8Z8;
11601160
ENABLE_PREVIEWS = YES;
11611161
GENERATE_INFOPLIST_FILE = YES;
11621162
INFOPLIST_FILE = "HearoadWatch-Watch-App-Info.plist";
@@ -1186,8 +1186,8 @@
11861186
ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor;
11871187
CODE_SIGN_STYLE = Automatic;
11881188
CURRENT_PROJECT_VERSION = 1;
1189-
DEVELOPMENT_ASSET_PATHS = "\"HearoadWatch Watch App/Preview Content\"";
1190-
DEVELOPMENT_TEAM = GT56H2MYWV;
1189+
DEVELOPMENT_ASSET_PATHS = "hearo HearoadWatch\\ Watch\\ App/Preview\\ Content";
1190+
DEVELOPMENT_TEAM = J5N8Y9F8Z8;
11911191
ENABLE_PREVIEWS = YES;
11921192
GENERATE_INFOPLIST_FILE = YES;
11931193
INFOPLIST_FILE = "HearoadWatch-Watch-App-Info.plist";
@@ -1295,7 +1295,7 @@
12951295
ASSETCATALOG_COMPILER_WIDGET_BACKGROUND_COLOR_NAME = WidgetBackground;
12961296
CODE_SIGN_STYLE = Automatic;
12971297
CURRENT_PROJECT_VERSION = 1;
1298-
DEVELOPMENT_TEAM = GT56H2MYWV;
1298+
DEVELOPMENT_TEAM = J5N8Y9F8Z8;
12991299
GENERATE_INFOPLIST_FILE = YES;
13001300
INFOPLIST_FILE = LiveActivity/Info.plist;
13011301
INFOPLIST_KEY_CFBundleDisplayName = LiveActivity;
@@ -1323,7 +1323,7 @@
13231323
ASSETCATALOG_COMPILER_WIDGET_BACKGROUND_COLOR_NAME = WidgetBackground;
13241324
CODE_SIGN_STYLE = Automatic;
13251325
CURRENT_PROJECT_VERSION = 1;
1326-
DEVELOPMENT_TEAM = GT56H2MYWV;
1326+
DEVELOPMENT_TEAM = J5N8Y9F8Z8;
13271327
GENERATE_INFOPLIST_FILE = YES;
13281328
INFOPLIST_FILE = LiveActivity/Info.plist;
13291329
INFOPLIST_KEY_CFBundleDisplayName = LiveActivity;

hearo/hearo.xcodeproj/xcuserdata/pil_gaaang.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -3,41 +3,4 @@
33
uuid = "E612D0C1-8F2A-42B7-B849-5689FA63B147"
44
type = "1"
55
version = "2.0">
6-
<Breakpoints>
7-
<BreakpointProxy
8-
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
9-
<BreakpointContent
10-
uuid = "88C89FED-F133-41C7-AF37-E3E6A1698142"
11-
shouldBeEnabled = "Yes"
12-
ignoreCount = "0"
13-
continueAfterRunningActions = "No"
14-
filePath = "hearo/Sources/Helper/Coordinator.swift"
15-
startingColumnNumber = "9223372036854775807"
16-
endingColumnNumber = "9223372036854775807"
17-
startingLineNumber = "6"
18-
endingLineNumber = "6"
19-
landmarkName = "unknown"
20-
landmarkType = "0">
21-
</BreakpointContent>
22-
</BreakpointProxy>
23-
<<<<<<< Updated upstream
24-
=======
25-
<BreakpointProxy
26-
BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
27-
<BreakpointContent
28-
uuid = "35B5EB06-74AC-48F5-97F1-7808B582A78F"
29-
shouldBeEnabled = "Yes"
30-
ignoreCount = "0"
31-
continueAfterRunningActions = "No"
32-
filePath = "hearo/Sources/Presentations/Working/ViewModel/WorkingViewModel.swift"
33-
startingColumnNumber = "9223372036854775807"
34-
endingColumnNumber = "9223372036854775807"
35-
startingLineNumber = "67"
36-
endingLineNumber = "67"
37-
landmarkName = "WorkingViewModel"
38-
landmarkType = "3">
39-
</BreakpointContent>
40-
</BreakpointProxy>
41-
>>>>>>> Stashed changes
42-
</Breakpoints>
436
</Bucket>

hearo/hearo/Application/hearoApp.swift

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ struct hearoApp: App {
5757
}
5858

5959
final class AppRootManager: ObservableObject {
60+
static let shared = AppRootManager() // 싱글톤 객체
61+
6062
@Published var currentRoot: AppRoot = .splash {
6163
didSet {
6264
// working 상태로 전환될 때 오디오 수집 자동 시작
@@ -87,10 +89,7 @@ final class AppRootManager: ObservableObject {
8789
case warning
8890
}
8991

90-
init() {
91-
self.hornSoundDetector = HornSoundDetector(appRootManager: self)
92-
}
93-
92+
9493
// 스플래시 끝났을 때 호출
9594
func determineNextRoot() {
9695
let hasSeenOnboarding = UserDefaults.standard.bool(forKey: "hasSeenOnboarding")

hearo/hearo/Info.plist

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,13 @@
22
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
33
<plist version="1.0">
44
<dict>
5+
<key>WKCompanionAppBundleIdentifier</key>
6+
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
57
<key>UIAppFonts</key>
68
<array>
79
<string>Pretendard-Light.otf</string>
810
<string>Pretendard-Regular.otf</string>
911
<string>Pretendard-Medium.otf</string>
1012
</array>
11-
<key>UIBackgroundModes</key>
12-
<array>
13-
<string>audio</string>
14-
<string>Audio</string>
15-
</array>
1613
</dict>
1714
</plist>

hearo/hearo/Resources/Assets.xcassets/SVGIcon/Icon.imageset/Contents.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{
22
"images" : [
33
{
4-
"filename" : "Icon 오후 9.05.06 1.png",
4+
"filename" : "Icon 오후 9.05.06 1.png",
55
"idiom" : "universal",
66
"scale" : "1x"
77
},
88
{
9-
"filename" : "Icon 오후 9.05.06.png",
9+
"filename" : "Icon 오후 9.05.06.png",
1010
"idiom" : "universal",
1111
"scale" : "2x"
1212
},

hearo/hearo/Resources/Assets.xcassets/SVGIcon/StartButton.imageset/Contents.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"images" : [
33
{
4-
"filename" : "시작하기.svg",
4+
"filename" : "시작하기.svg",
55
"idiom" : "universal",
66
"scale" : "1x"
77
},

0 commit comments

Comments
 (0)