converted all sound files to .ogg (to avoid problems with different sampling rates...
[supertux.git] / src / object / text_object.cpp
index 298e787..706b2fb 100644 (file)
@@ -1,8 +1,8 @@
 #include <config.h>
 
-#include "text_object.h"
-#include "resources.h"
-#include "video/drawing_context.h"
+#include "text_object.hpp"
+#include "resources.hpp"
+#include "video/drawing_context.hpp"
 
 TextObject::TextObject()
   : fading(0), fadetime(0), visible(false)
@@ -25,8 +25,6 @@ TextObject::set_font(const std::string& name)
     font = blue_text;
   } else if(name == "gray") {
     font = gray_text;
-  } else if(name == "white") {
-    font = white_text;
   } else if(name == "big") {
     font = white_big_text;
   } else if(name == "small") {
@@ -79,14 +77,14 @@ TextObject::draw(DrawingContext& context)
   }
 
   context.draw_filled_rect(Vector(125, 50), Vector(550, 120),
-      Color(150, 180, 200, 125), LAYER_GUI-10);
-  context.draw_text(font, text, Vector(125+35, 50+35), LEFT_ALLIGN, LAYER_GUI);
+      Color(150, 180, 200, 125), LAYER_GUI-50);
+  context.draw_text(font, text, Vector(125+35, 50+35), LEFT_ALLIGN, LAYER_GUI-40);
 
   context.pop_transform();
 }
 
 void
-TextObject::action(float elapsed_time)
+TextObject::update(float elapsed_time)
 {
   if(fading > 0) {
     fading -= elapsed_time;