diff options
author | Andrei Karas <akaras@inbox.ru> | 2015-12-27 18:37:26 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2015-12-27 18:37:26 +0300 |
commit | 12f2ce912aa1a7e158f06aa20396f213abdd2583 (patch) | |
tree | cd75248717e990fee8b7418df35eb5d27c195336 /src/particle/textparticle.cpp | |
parent | 3605741892b995144111d4d885cf88063c3f4379 (diff) | |
download | manaplus-12f2ce912aa1a7e158f06aa20396f213abdd2583.tar.gz manaplus-12f2ce912aa1a7e158f06aa20396f213abdd2583.tar.bz2 manaplus-12f2ce912aa1a7e158f06aa20396f213abdd2583.tar.xz manaplus-12f2ce912aa1a7e158f06aa20396f213abdd2583.zip |
Add restrict keyword to particle.
Diffstat (limited to 'src/particle/textparticle.cpp')
-rw-r--r-- | src/particle/textparticle.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/particle/textparticle.cpp b/src/particle/textparticle.cpp index 33a0c4b0c..c79b94c81 100644 --- a/src/particle/textparticle.cpp +++ b/src/particle/textparticle.cpp @@ -28,9 +28,10 @@ #include "debug.h" -TextParticle::TextParticle(const std::string &text, - const Color *const color, - Font *const font, const bool outline) : +TextParticle::TextParticle(const std::string &restrict text, + const Color *restrict const color, + Font *restrict const font, + const bool outline) : Particle(), mText(text), mTextFont(font), @@ -40,8 +41,9 @@ TextParticle::TextParticle(const std::string &text, { } -void TextParticle::draw(Graphics *const graphics, - const int offsetX, const int offsetY) const +void TextParticle::draw(Graphics *restrict const graphics, + const int offsetX, + const int offsetY) const restrict2 { if (!mColor || !mTextFont) return; @@ -77,7 +79,7 @@ void TextParticle::draw(Graphics *const graphics, graphics->setColor(color); if (mOutline) { - const Color &color2 = theme->getColor(ThemeColorId::OUTLINE, + const Color &restrict color2 = theme->getColor(ThemeColorId::OUTLINE, static_cast<int>(alpha)); mTextFont->drawString(graphics, color, color2, |