Label:disableEffect(LabelEffect::XXXX) support disable all effect.

This commit is contained in:
WenhaiLin 2015-04-17 14:39:52 +08:00
parent 5d5fa3d618
commit 0ac99002d5
3 changed files with 10 additions and 1 deletions

View File

@ -857,6 +857,13 @@ void Label::disableEffect(LabelEffect effect)
updateShaderProgram();
}
break;
case LabelEffect::ALL:
{
disableEffect(LabelEffect::SHADOW);
disableEffect(LabelEffect::GLOW);
disableEffect(LabelEffect::OUTLINE);
}
break;
default:
break;
}

View File

@ -323,6 +323,7 @@ public:
/**
* Disable all effect to Label.
* @warning Please use disableEffect(LabelEffect::ALL) instead of this API.
*/
virtual void disableEffect();

View File

@ -556,7 +556,8 @@ enum class LabelEffect {
NORMAL,
OUTLINE,
SHADOW,
GLOW
GLOW,
ALL
};
/** @struct Acceleration