mirror of
				https://github.com/chibicitiberiu/rainmeter-studio.git
				synced 2024-02-24 04:33:31 +00:00 
			
		
		
		
	IfActions: Tweaks
This commit is contained in:
		@@ -204,20 +204,20 @@ void IfActions::DoIfActions(Measure& measure, double value)
 | 
				
			|||||||
	}
 | 
						}
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
void IfActions::SetState(double value)
 | 
					void IfActions::SetState(double& value)
 | 
				
			||||||
{
 | 
					{
 | 
				
			||||||
	// Set IfAction committed state to false if condition is not met with value = 0
 | 
						// Set IfAction committed state to false if condition is not met with value = 0
 | 
				
			||||||
	if (m_EqualValue != 0)
 | 
						if (m_EqualValue != (int64_t)value)
 | 
				
			||||||
	{
 | 
						{
 | 
				
			||||||
		m_EqualCommitted = false;
 | 
							m_EqualCommitted = false;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (m_AboveValue <= 0.0)
 | 
						if (m_AboveValue <= value)
 | 
				
			||||||
	{
 | 
						{
 | 
				
			||||||
		m_AboveCommitted = false;
 | 
							m_AboveCommitted = false;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
	if (m_BelowValue >= 0.0)
 | 
						if (m_BelowValue >= value)
 | 
				
			||||||
	{
 | 
						{
 | 
				
			||||||
		m_BelowCommitted = false;
 | 
							m_BelowCommitted = false;
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -65,7 +65,7 @@ public:
 | 
				
			|||||||
	void ReadOptions(ConfigParser& parser, const WCHAR* section);
 | 
						void ReadOptions(ConfigParser& parser, const WCHAR* section);
 | 
				
			||||||
	void ReadConditionOptions(ConfigParser& parser, const WCHAR* section);
 | 
						void ReadConditionOptions(ConfigParser& parser, const WCHAR* section);
 | 
				
			||||||
	void DoIfActions(Measure& measure, double value);
 | 
						void DoIfActions(Measure& measure, double value);
 | 
				
			||||||
	void SetState(double value = 0.0f);
 | 
						void SetState(double& value);
 | 
				
			||||||
 | 
					
 | 
				
			||||||
private:
 | 
					private:
 | 
				
			||||||
	double m_AboveValue;
 | 
						double m_AboveValue;
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user