Skip to content

Commit

Permalink
reduce amount of debug print
Browse files Browse the repository at this point in the history
  • Loading branch information
kangyu-california committed Feb 17, 2022
1 parent 0112f55 commit 21787fe
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -849,7 +849,7 @@ private void PostActivateWindows()
if (windowActiveCnt[curDisplayKey] >= 2)
{
normalSessions.Add(curDisplayKey);
Log.Error("normal session {0} due to active count {1}", curDisplayKey, windowActiveCnt[curDisplayKey]);
Log.Trace("normal session {0} due to active count {1}", curDisplayKey, windowActiveCnt[curDisplayKey]);
}
}

Expand Down Expand Up @@ -1224,7 +1224,7 @@ private void WinEventProc(IntPtr hWinEventHook, User32Events eventType, IntPtr h
// If the window move is caused by user snapping window to screen edge,
// delay capture by a few seconds should be fine.

Log.Error("activate {0}", GetWindowTitle(hwnd));
Log.Trace("activate {0}", GetWindowTitle(hwnd));
if (!pendingActivateWindows.Contains(hwnd))
pendingActivateWindows.Add(hwnd);

Expand Down Expand Up @@ -1282,7 +1282,7 @@ private void WinEventProc(IntPtr hWinEventHook, User32Events eventType, IntPtr h
{
//capture with slight delay inperceivable by user, required for full screen mode recovery
StartCaptureTimer(UserMoveLatency / 4);
Log.Event("{0} {1}", eventType, GetWindowTitle(hwnd));
Log.Trace("{0} {1}", eventType, GetWindowTitle(hwnd));
userMove = true;
}
break;
Expand All @@ -1307,7 +1307,7 @@ private void WinEventProc(IntPtr hWinEventHook, User32Events eventType, IntPtr h
if (monitorApplications.ContainsKey(curDisplayKey) && monitorApplications[curDisplayKey].ContainsKey(hwnd) || allUserMoveWindows.Contains(hwnd))
{
StartCaptureTimer(UserMoveLatency / 4);
Log.Event("{0} {1}", eventType, GetWindowTitle(hwnd));
Log.Trace("{0} {1}", eventType, GetWindowTitle(hwnd));
if (eventType == User32Events.EVENT_SYSTEM_MOVESIZEEND)
userMove = true;
}
Expand Down Expand Up @@ -1733,7 +1733,7 @@ public void BatchCaptureApplicationsOnCurrentDisplays(bool saveToDB = false)
if (userMovePrev)
{
normalSessions.Add(curDisplayKey);
Log.Error("normal session {0} due to user move", curDisplayKey, userMovePrev);
Log.Trace("normal session {0} due to user move", curDisplayKey, userMovePrev);
}

CaptureApplicationsOnCurrentDisplays(displayKey, saveToDB : saveToDB); //implies auto delayed capture
Expand Down

0 comments on commit 21787fe

Please sign in to comment.