Resolves #164
Template cover has supported_features = 11, but it supports setting position.
This commit is contained in:
		| @@ -40,7 +40,7 @@ class CoverEntity extends Entity { | |||||||
|  |  | ||||||
|   double get currentPosition => _getDoubleAttributeValue('current_position'); |   double get currentPosition => _getDoubleAttributeValue('current_position'); | ||||||
|   double get currentTiltPosition => _getDoubleAttributeValue('current_tilt_position'); |   double get currentTiltPosition => _getDoubleAttributeValue('current_tilt_position'); | ||||||
|   bool get canBeOpened => ((state != "opening") && (state != "open")) || (state == "open" && supportSetPosition && currentPosition > 0.0 && currentPosition < 100.0); |   bool get canBeOpened => ((state != "opening") && (state != "open")) || (state == "open" && currentPosition != null && currentPosition > 0.0 && currentPosition < 100.0); | ||||||
|   bool get canBeClosed => ((state != "closing") && (state != "closed")); |   bool get canBeClosed => ((state != "closing") && (state != "closed")); | ||||||
|   bool get canTiltBeOpened => currentTiltPosition < 100; |   bool get canTiltBeOpened => currentTiltPosition < 100; | ||||||
|   bool get canTiltBeClosed => currentTiltPosition > 0; |   bool get canTiltBeClosed => currentTiltPosition > 0; | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user