]> git.tdb.fi Git - libs/gl.git/blobdiff - source/builders/font.cpp
Use constructor delegation instead of init functions when possible
[libs/gl.git] / source / builders / font.cpp
index dfa6bf9cf953685c2472c29b29788447e53e6642..1ede612a1dec64e9ab2e671a5a9398fc44e8f6dc 100644 (file)
@@ -1,7 +1,6 @@
 #include <msp/core/maputils.h>
 #include <msp/datafile/collection.h>
 #include <msp/fs/utils.h>
-#include "gl.h"
 #include "font.h"
 #include "primitivebuilder.h"
 #include "texture2d.h"
@@ -144,19 +143,8 @@ Font::Glyph::Glyph():
 { }
 
 
-Font::Loader::Loader(Font &f):
-       DataFile::CollectionObjectLoader<Font>(f, 0)
-{
-       init();
-}
-
-Font::Loader::Loader(Font &f, Collection &c):
-       DataFile::CollectionObjectLoader<Font>(f, &c)
-{
-       init();
-}
-
-void Font::Loader::init()
+Font::Loader::Loader(Font &f, Collection *c):
+       DataFile::CollectionObjectLoader<Font>(f, c)
 {
        add("native_size", &Font::native_size);
        add("ascent",      &Font::ascent);