mirror of
https://github.com/chibicitiberiu/rainmeter-studio.git
synced 2024-02-24 04:33:31 +00:00
Reapply accidentally reverted changes in 3b1dfba
This commit is contained in:
parent
1eb46ae448
commit
ec9c2ef598
@ -103,12 +103,11 @@ void MeasureCalc::ReadOptions(ConfigParser& parser, const WCHAR* section)
|
|||||||
oldUpdateRandom != m_UpdateRandom ||
|
oldUpdateRandom != m_UpdateRandom ||
|
||||||
oldUniqueRandom != m_UniqueRandom)
|
oldUniqueRandom != m_UniqueRandom)
|
||||||
{
|
{
|
||||||
// Reset bounds if |m_LowBound| is greater than |m_HighBound|
|
// Reset bounds if |m_LowBound| is greater than |m_HighBound|.
|
||||||
if (m_LowBound > m_HighBound)
|
if (m_LowBound > m_HighBound &&
|
||||||
|
(oldLowBound != m_LowBound || oldHighBound != m_HighBound))
|
||||||
{
|
{
|
||||||
LogErrorF(this, L"\"LowBound\" (%i) must be less then or equal to \"HighBound\" (%i)", m_LowBound, m_HighBound);
|
LogErrorF(this, L"\"LowBound\" (%i) must be less then or equal to \"HighBound\" (%i)", m_LowBound, m_HighBound);
|
||||||
|
|
||||||
m_HighBound = m_LowBound;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Reset the list if the bounds are changed
|
// Reset the list if the bounds are changed
|
||||||
@ -199,7 +198,7 @@ bool MeasureCalc::GetMeasureValue(const WCHAR* str, int len, double* value, void
|
|||||||
|
|
||||||
int MeasureCalc::GetRandom()
|
int MeasureCalc::GetRandom()
|
||||||
{
|
{
|
||||||
if (m_LowBound == m_HighBound)
|
if (m_LowBound == m_HighBound || m_LowBound > m_HighBound)
|
||||||
{
|
{
|
||||||
return m_LowBound;
|
return m_LowBound;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user