Skip to content

Commit 93bec57

Browse files
committed
fix: 리셋 후에 집중도 설정이 저장되지 않는 문제 해결
1 parent 8b53913 commit 93bec57

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

FocusTimer/Features/Timer/Slot/TimerSlotViewModel.Registration.cs

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ namespace FocusTimer.Features.Timer.Slot;
2222
public partial class TimerSlotViewModel
2323
{
2424
public bool IsWaitingForApp { get; private set; }
25-
25+
2626
public void StartWaitingForApp()
2727
{
2828
this.GetLogger().Info($"현재 슬롯({SlotNumber}번)에서 사용자의 창 선택을 기다립니다.");
@@ -34,11 +34,18 @@ public void StartWaitingForApp()
3434

3535
OnRender();
3636
}
37-
37+
3838
public void StopWaitingAndRegisterApp(AppItem appItem)
3939
{
4040
this.GetLogger().Info($"현재 슬롯({SlotNumber}번)에 사용자가 선택한 앱({appItem.ProcessExecutablePath})을 등록합니다.");
4141

42+
if (CurrentAppItem?.App == appItem.App)
43+
{
44+
appItem.IsCountedOnConcentrationCalculation = CurrentAppItem?.IsCountedOnConcentrationCalculation ?? true;
45+
this.GetLogger().Info($"아, 이거 같은 앱으로 교체되는거네요? 집중도 포함 여부를 승계해줍니다. 프로그램 '{appItem.App.Title}'은(는) 집중도 계산에 " +
46+
(appItem.IsCountedOnConcentrationCalculation ? "포함됩니다." : "포함되지 않습니다."));
47+
}
48+
4249
CurrentAppItem?.Dispose();
4350
CurrentAppItem = appItem;
4451
IsWaitingForApp = false;

0 commit comments

Comments
 (0)