00001 /*************************************************************************** 00002 * Copyright (C) 2005-2008 by the FIFE team * 00003 * http://www.fifengine.de * 00004 * This file is part of FIFE. * 00005 * * 00006 * FIFE is free software; you can redistribute it and/or * 00007 * modify it under the terms of the GNU Lesser General Public * 00008 * License as published by the Free Software Foundation; either * 00009 * version 2.1 of the License, or (at your option) any later version. * 00010 * * 00011 * This library is distributed in the hope that it will be useful, * 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of * 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * 00014 * Lesser General Public License for more details. * 00015 * * 00016 * You should have received a copy of the GNU Lesser General Public * 00017 * License along with this library; if not, write to the * 00018 * Free Software Foundation, Inc., * 00019 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA * 00020 ***************************************************************************/ 00021 00022 /* _______ __ __ __ ______ __ __ _______ __ __ 00023 * / _____/\ / /\ / /\ / /\ / ____/\ / /\ / /\ / ___ /\ / |\/ /\ 00024 * / /\____\// / // / // / // /\___\// /_// / // /\_/ / // , |/ / / 00025 * / / /__ / / // / // / // / / / ___ / // ___ / // /| ' / / 00026 * / /_// /\ / /_// / // / // /_/_ / / // / // /\_/ / // / | / / 00027 * /______/ //______/ //_/ //_____/\ /_/ //_/ //_/ //_/ //_/ /|_/ / 00028 * \______\/ \______\/ \_\/ \_____\/ \_\/ \_\/ \_\/ \_\/ \_\/ \_\/ 00029 * 00030 * Copyright (c) 2004, 2005 darkbits Js_./ 00031 * Per Larsson a.k.a finalman _RqZ{a<^_aa 00032 * Olof Naess�n a.k.a jansem/yakslem _asww7!uY`> )\a// 00033 * _Qhm`] _f "'c 1!5m 00034 * Visit: http://guichan.darkbits.org )Qk<P ` _: :+' .' "{[ 00035 * .)j(] .d_/ '-( P . S 00036 * License: (BSD) <Td/Z <fP"5(\"??"\a. .L 00037 * Redistribution and use in source and _dV>ws?a-?' ._/L #' 00038 * binary forms, with or without )4d[#7r, . ' )d`)[ 00039 * modification, are permitted provided _Q-5'5W..j/?' -?!\)cam' 00040 * that the following conditions are met: j<<WP+k/);. _W=j f 00041 * 1. Redistributions of source code must .$%w\/]Q . ."' . mj$ 00042 * retain the above copyright notice, ]E.pYY(Q]>. a J@\ 00043 * this list of conditions and the j(]1u<sE"L,. . ./^ ]{a 00044 * following disclaimer. 4'_uomm\. )L);-4 (3= 00045 * 2. Redistributions in binary form must )_]X{Z('a_"a7'<a"a, ]"[ 00046 * reproduce the above copyright notice, #}<]m7`Za??4,P-"'7. ).m 00047 * this list of conditions and the ]d2e)Q(<Q( ?94 b- LQ/ 00048 * following disclaimer in the <B!</]C)d_, '(<' .f. =C+m 00049 * documentation and/or other materials .Z!=J ]e []('-4f _ ) -.)m]' 00050 * provided with the distribution. .w[5]' _[ /.)_-"+? _/ <W" 00051 * 3. Neither the name of Guichan nor the :$we` _! + _/ . j? 00052 * names of its contributors may be used =3)= _f (_yQmWW$#( " 00053 * to endorse or promote products derived - W, sQQQQmZQ#Wwa].. 00054 * from this software without specific (js, \[QQW$QWW#?!V"". 00055 * prior written permission. ]y:.<\.. . 00056 * -]n w/ ' [. 00057 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT )/ )/ ! 00058 * HOLDERS AND CONTRIBUTORS "AS IS" AND ANY < (; sac , ' 00059 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, ]^ .- % 00060 * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF c < r 00061 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR aga< <La 00062 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 5% )P'-3L 00063 * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR _bQf` y`..)a 00064 * ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, ,J?4P'.P"_(\?d'., 00065 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES _Pa,)!f/<[]/ ?" 00066 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT _2-..:. .r+_,.. . 00067 * OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, ?a.<%"' " -'.a_ _, 00068 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) ^ 00069 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 00070 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 00071 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 00072 * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN 00073 * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 00074 */ 00075 00076 #ifndef GCN_ICON2_HPP 00077 #define GCN_ICON2_HPP 00078 00079 // Standard C++ library includes 00080 00081 // 3rd party library includes 00082 #include <guichan/image.hpp> 00083 #include <guichan/platform.hpp> 00084 #include <guichan/widget.hpp> 00085 00086 // FIFE includes 00087 // These includes are split up in two parts, separated by one empty line 00088 // First block: files included from the FIFE root src directory 00089 // Second block: files included from the same folder 00090 00091 namespace gcn 00092 { 00098 class Icon2 : public Widget 00099 { 00100 public: 00106 Icon2(Image* image); 00107 virtual ~Icon2() {} 00108 00109 00110 // Inherited from Widget 00111 00112 virtual void draw(Graphics* graphics); 00113 00114 virtual void drawFrame(Graphics* graphics); 00115 00116 // added for FIFE 00117 void setImage(Image* image); 00118 00119 // changed from private to allow derived instance access 00120 protected: 00121 Image* mImage; 00122 }; 00123 } 00124 00125 #endif // end GCN_ICON2_HPP