diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 2001-11-25 22:51:34 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 2001-11-25 22:51:34 +0000 |
| commit | 2b826b0f318e8df5176d3a5fa2edba4b1811e78d (patch) | |
| tree | 8be0ceaaf079f90e5e58c6af83ca9615b9ec9939 /fluid/Fluid_Image.h | |
| parent | c147aca0541e9f45b1bd9c8eed4ec71cb1c650ec (diff) | |
Redo Fluid_Image class to use Fl_Shared_Image instead of its own subclasses
to read files...
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1730 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'fluid/Fluid_Image.h')
| -rw-r--r-- | fluid/Fluid_Image.h | 28 |
1 files changed, 15 insertions, 13 deletions
diff --git a/fluid/Fluid_Image.h b/fluid/Fluid_Image.h index f513b8785..1b8694863 100644 --- a/fluid/Fluid_Image.h +++ b/fluid/Fluid_Image.h @@ -1,13 +1,11 @@ // -// "$Id: Fluid_Image.h,v 1.3.2.4.2.1 2001/09/29 06:20:15 easysw Exp $" +// "$Id: Fluid_Image.h,v 1.3.2.4.2.2 2001/11/25 22:51:34 easysw Exp $" // -// Pixmap image header file for the Fast Light Tool Kit (FLTK). +// Image header file for the Fast Light Tool Kit (FLTK). // // This class stores the image labels for widgets in fluid. This is -// not a class in fltk itself, and this will produce different types of -// code depending on what the image type is. There are private subclasses -// in Fluid_Image.C for each type of image format. Right now only xpm -// files are supported. +// not a class in FLTK itself, and will produce different types of +// code depending on what the image type is. // // Copyright 1998-2001 by Bill Spitzak and others. // @@ -30,23 +28,27 @@ // #ifndef FLUID_IMAGE_H -#define FLUID_IMAGE_H +# define FLUID_IMAGE_H + +# include <FL/Fl_Shared_Image.H> + class Fluid_Image { const char *name_; int refcount; + Fl_Shared_Image *img; protected: Fluid_Image(const char *name); // no public constructor - virtual ~Fluid_Image(); // no public destructor + ~Fluid_Image(); // no public destructor public: int written; static Fluid_Image* find(const char *); void decrement(); // reference counting & automatic free void increment(); - virtual void image(Fl_Widget *) = 0; // set the image of this widget - virtual void deimage(Fl_Widget *) = 0; // set the deimage of this widget - virtual void write_static() = 0; - virtual void write_code(int inactive = 0) = 0; + void image(Fl_Widget *); // set the image of this widget + void deimage(Fl_Widget *); // set the deimage of this widget + void write_static(); + void write_code(int inactive = 0); const char *name() const {return name_;} }; @@ -58,5 +60,5 @@ extern const char *ui_find_image_name; #endif // -// End of "$Id: Fluid_Image.h,v 1.3.2.4.2.1 2001/09/29 06:20:15 easysw Exp $". +// End of "$Id: Fluid_Image.h,v 1.3.2.4.2.2 2001/11/25 22:51:34 easysw Exp $". // |
