Should only allow video and protected layer switch
Change-Id: I4633725277e0cee125c24b33a42fcd481f9f5990
Tracked-On: None
Tests: Video playback on Android
Signed-off-by: Lin Johnson <johnson.lin@intel.com>
}
void SetProtected(bool isProtected) {
- if (isProtected && type_ == kLayerVideo)
+ if (isProtected && (type_ == kLayerVideo || type_ == kLayerProtected))
type_ = kLayerProtected;
- else if (!isProtected && type_ == kLayerProtected)
+ else if (!isProtected && (type_ == kLayerProtected || type_ == kLayerVideo))
type_ = kLayerVideo;
else
type_ = kLayerNormal;