@@ -1400,6 +1400,24 @@ void CMainFrame::Pause()
1400
1400
m_logSources.AddMessage (" <paused>" );
1401
1401
}
1402
1402
1403
+ void CMainFrame::UpdateTitle ()
1404
+ {
1405
+ std::wstring title = L" Paused" ;
1406
+ if ((m_pLocalReader != nullptr ) && (m_pGlobalReader != nullptr ))
1407
+ {
1408
+ title = L" Capture Win32 & Global Win32 Messages" ;
1409
+ }
1410
+ else if (m_pLocalReader != nullptr )
1411
+ {
1412
+ title = L" Capture Win32" ;
1413
+ }
1414
+ else if (m_pGlobalReader != nullptr )
1415
+ {
1416
+ title = L" Capture Global Win32" ;
1417
+ }
1418
+ SetTitle (title);
1419
+ }
1420
+
1403
1421
void CMainFrame::Resume ()
1404
1422
{
1405
1423
SetTitle ();
@@ -1438,21 +1456,7 @@ void CMainFrame::Resume()
1438
1456
m_tryGlobal = false ;
1439
1457
}
1440
1458
}
1441
-
1442
- std::wstring title = L" Paused" ;
1443
- if ((m_pLocalReader != nullptr ) && (m_pGlobalReader != nullptr ))
1444
- {
1445
- title = L" Capture Win32 & Global Win32 Messages" ;
1446
- }
1447
- else if (m_pLocalReader != nullptr )
1448
- {
1449
- title = L" Capture Win32" ;
1450
- }
1451
- else if (m_pGlobalReader != nullptr )
1452
- {
1453
- title = L" Capture Global Win32" ;
1454
- }
1455
- SetTitle (title);
1459
+ UpdateTitle ();
1456
1460
}
1457
1461
1458
1462
void CMainFrame::OnLogPause (UINT /* uNotifyCode*/ , int /* nID*/ , CWindow /* wndCtl*/ )
@@ -1480,6 +1484,7 @@ void CMainFrame::OnLogGlobal(UINT /*uNotifyCode*/, int /*nID*/, CWindow /*wndCtl
1480
1484
m_logSources.Remove (m_pGlobalReader);
1481
1485
m_pGlobalReader = nullptr ;
1482
1486
}
1487
+ UpdateTitle ();
1483
1488
}
1484
1489
1485
1490
void CMainFrame::OnLogHistory (UINT /* uNotifyCode*/ , int /* nID*/ , CWindow /* wndCtl*/ )
0 commit comments