From facf440788e985709019a5abb62d41747751005b Mon Sep 17 00:00:00 2001 From: David Steele Date: Mon, 28 Mar 2022 11:12:11 +0100 Subject: [PATCH] Fixing text-label demo mix color bug Change-Id: Ia6565e94e85a12c296bfdd76e0341103c18a9781 --- examples/text-label/text-label-example.cpp | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/examples/text-label/text-label-example.cpp b/examples/text-label/text-label-example.cpp index 83743c7..f04d074 100644 --- a/examples/text-label/text-label-example.cpp +++ b/examples/text-label/text-label-example.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2021 Samsung Electronics Co., Ltd. + * Copyright (c) 2022 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -253,11 +253,10 @@ public: mBorder.SetProperty(Actor::Property::VISIBLE, false); mGrabCorner.RaiseToTop(); - mHueAngleIndex = mLabel.RegisterProperty("hue", 0.0f); - Renderer bgRenderer = mLabel.GetRendererAt(0); - mOverrideMixColorIndex = bgRenderer.GetPropertyIndex(ColorVisual::Property::MIX_COLOR); + mHueAngleIndex = mLabel.RegisterProperty("hue", 0.0f); + Renderer bgRenderer = mLabel.GetRendererAt(0); - Constraint constraint = Constraint::New(bgRenderer, mOverrideMixColorIndex, HSVColorConstraint(0.0f, 0.5f, 0.8f)); + Constraint constraint = Constraint::New(bgRenderer, VisualRenderer::Property::VISUAL_MIX_COLOR, HSVColorConstraint(0.0f, 0.5f, 0.8f)); constraint.AddSource(Source(mLabel, mHueAngleIndex)); constraint.SetRemoveAction(Constraint::DISCARD); constraint.Apply(); -- 2.7.4