mirror of https://github.com/axmolengine/axmol.git
Merge pull request #11477 from WenhaiLin/v3-label-fix
Label:disableEffect(LabelEffect::XXXX) support disable all effect.
This commit is contained in:
commit
08df26f36a
|
@ -857,6 +857,13 @@ void Label::disableEffect(LabelEffect effect)
|
||||||
updateShaderProgram();
|
updateShaderProgram();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
case LabelEffect::ALL:
|
||||||
|
{
|
||||||
|
disableEffect(LabelEffect::SHADOW);
|
||||||
|
disableEffect(LabelEffect::GLOW);
|
||||||
|
disableEffect(LabelEffect::OUTLINE);
|
||||||
|
}
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -323,6 +323,7 @@ public:
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Disable all effect to Label.
|
* Disable all effect to Label.
|
||||||
|
* @warning Please use disableEffect(LabelEffect::ALL) instead of this API.
|
||||||
*/
|
*/
|
||||||
virtual void disableEffect();
|
virtual void disableEffect();
|
||||||
|
|
||||||
|
|
|
@ -556,7 +556,8 @@ enum class LabelEffect {
|
||||||
NORMAL,
|
NORMAL,
|
||||||
OUTLINE,
|
OUTLINE,
|
||||||
SHADOW,
|
SHADOW,
|
||||||
GLOW
|
GLOW,
|
||||||
|
ALL
|
||||||
};
|
};
|
||||||
|
|
||||||
/** @struct Acceleration
|
/** @struct Acceleration
|
||||||
|
|
Loading…
Reference in New Issue