Add !PauseMeasure, !UnpauseMeasure, and !TogglePauseMeasure bangs. This is similar to a disabled measure, only it retains its value instead of changing to 0.

Also, group bangs !PauseMeasureGroup, !UnpauseMeasureGroup, and !TogglePauseMeasureGroup bangs have been added.
This commit is contained in:
Brian Ferguson
2013-07-11 14:29:23 -06:00
parent 2507b4fe2c
commit a883e9d47d
6 changed files with 118 additions and 0 deletions

View File

@ -84,6 +84,7 @@ Measure::Measure(MeterWindow* meterWindow, const WCHAR* name) : Section(meterWin
m_IfAboveCommitted(false),
m_IfBelowCommitted(false),
m_Disabled(false),
m_Paused(false),
m_Initialized(false),
m_OldValue(),
m_ValueAssigned(false)
@ -435,6 +436,9 @@ std::wstring Measure::ExtractWord(std::wstring& buffer)
bool Measure::Update()
{
// Don't do anything if paused
if (m_Paused) return false;
if (!m_Disabled)
{
// Only update the counter if the divider