Main Page   Modules   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members  

Fl_Image_List.h

00001 /*
00002  * $Id: Fl_Image_List.h,v 1.6 2003/03/15 16:09:55 laza2000 Exp $
00003  *
00004  * Extended Fast Light Toolkit (EFLTK)
00005  * Copyright (C) 2002-2003 by EDE-Team
00006  * WWW: http://www.sourceforge.net/projects/ede
00007  *
00008  * Fast Light Toolkit (FLTK)
00009  * Copyright (C) 1998-2003 by Bill Spitzak and others.
00010  * WWW: http://www.fltk.org
00011  *
00012  * This library is distributed under the GNU LIBRARY GENERAL PUBLIC LICENSE
00013  * version 2. See COPYING for details.
00014  *
00015  * Author : Mikko Lahteenmaki
00016  * Email  : mikko@fltk.net
00017  *
00018  * Please report all bugs and problems to "efltk-bugs@fltk.net"
00019  *
00020  */
00021 
00022 #ifndef _FL_IMAGE_LIST_H_
00023 #define _FL_IMAGE_LIST_H_
00024 
00025 #include "Fl_Ptr_List.h"
00026 #include "Fl_Image.h"
00027 
00029 class Fl_Image_List : public Fl_Ptr_List {
00030 public:
00031     Fl_Image_List() : Fl_Ptr_List() { }
00032     virtual ~Fl_Image_List() { clear(); }
00033 
00034     void append(Fl_Image *item) { Fl_Ptr_List::append((void *)item); }
00035     void prepend(Fl_Image  *item) { Fl_Ptr_List::prepend((void *)item); }
00036     void insert(unsigned pos, Fl_Image *item) { Fl_Ptr_List::insert(pos, (void *)item); }
00037     void replace(uint pos, Fl_Image *item) { Fl_Ptr_List::replace(pos, (void *)item); }
00038     void remove(uint pos) { Fl_Ptr_List::remove(pos); }
00039     bool remove(Fl_Image *item) { return Fl_Ptr_List::remove((void *)item); }
00040     int index_of(const Fl_Image *w) const { return Fl_Ptr_List::index_of((void*)w); }
00041 
00042     Fl_Image **data() { return (Fl_Image**)items; }
00043 
00044     Fl_Image *item(uint index) const { return (Fl_Image*)Fl_Ptr_List::item(index); }
00045     Fl_Image *operator [](uint ind) const { return (Fl_Image *)items[ind]; }
00046 
00047 protected:
00048     virtual void free_item(Fl_Ptr_List_Item item) { delete (Fl_Image*)(item); }
00049 };
00050 
00051 #endif

Generated on Thu Jul 31 15:33:44 2003 for eFLTK by doxygen1.2.15