From 0e80a70267d6725b4bde456804a5cd80af3c6ec5 Mon Sep 17 00:00:00 2001 From: Mikko Rasa Date: Wed, 29 May 2013 23:05:49 +0300 Subject: [PATCH] Remove deprecated alias from Style loader --- source/style.cpp | 16 +++++++--------- source/style.h | 2 +- 2 files changed, 8 insertions(+), 10 deletions(-) diff --git a/source/style.cpp b/source/style.cpp index da772dc..f26112a 100644 --- a/source/style.cpp +++ b/source/style.cpp @@ -40,10 +40,8 @@ Style::Loader::Loader(Style &s, Resources &r): add("font", &Loader::font); add("font_color", &Loader::font_color); add("font_size", &Style::font_size); - add("part", static_cast(&Loader::part)); - add("part", static_cast(&Loader::part)); - // Deprecated alias - add("special", static_cast(&Loader::part)); + add("part", &Loader::part); + add("part", &Loader::unnamed_part); } void Style::Loader::font(const string &n) @@ -57,11 +55,6 @@ void Style::Loader::font_color(float r, float g, float b) obj.font_color = GL::Color(r, g, b); } -void Style::Loader::part() -{ - part(string()); -} - void Style::Loader::part(const string &n) { Part p(n); @@ -69,5 +62,10 @@ void Style::Loader::part(const string &n) obj.parts.push_back(p); } +void Style::Loader::unnamed_part() +{ + part(string()); +} + } // namespace GLtk } // namespace Msp diff --git a/source/style.h b/source/style.h index 08e274c..672a7ea 100644 --- a/source/style.h +++ b/source/style.h @@ -26,8 +26,8 @@ public: private: void font(const std::string &); void font_color(float, float, float); - void part(); void part(const std::string &); + void unnamed_part(); }; typedef std::list PartSeq; -- 2.45.2