tooltips.hpp

Go to the documentation of this file.
00001 /* $Id: tooltips.hpp 53555 2012-03-18 14:57:32Z mordante $ */
00002 /*
00003    Copyright (C) 2003 - 2012 by David White <dave@whitevine.net>
00004    Part of the Battle for Wesnoth Project http://www.wesnoth.org/
00005 
00006    This program is free software; you can redistribute it and/or modify
00007    it under the terms of the GNU General Public License as published by
00008    the Free Software Foundation; either version 2 of the License, or
00009    (at your option) any later version.
00010    This program is distributed in the hope that it will be useful,
00011    but WITHOUT ANY WARRANTY.
00012 
00013    See the COPYING file for more details.
00014 */
00015 
00016 #ifndef TOOLTIPS_HPP_INCLUDED
00017 #define TOOLTIPS_HPP_INCLUDED
00018 
00019 #include "SDL.h"
00020 
00021 #include <string>
00022 
00023 class CVideo;
00024 
00025 namespace tooltips {
00026 
00027 struct manager
00028 {
00029     manager(CVideo& video);
00030     ~manager();
00031 };
00032 
00033 void clear_tooltips();
00034 void clear_tooltips(const SDL_Rect& rect);
00035 void add_tooltip(const SDL_Rect& rect, const std::string& message, const std::string& action ="", bool use_markup = true);
00036 void process(int mousex, int mousey);
00037 
00038 // Check if we clicked on a tooltip having an action.
00039 // If it is, then execute the action and return true
00040 // (only possible action are opening help page for the moment)
00041 bool click(int mousex, int mousey);
00042 
00043 }
00044 
00045 #endif
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Fri May 25 2012 01:03:13 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs