diff options
| author | Manolo Gouy <Manolo> | 2016-03-19 18:14:58 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2016-03-19 18:14:58 +0000 |
| commit | f936eb1a962d9578befff4d4cdeac64339644594 (patch) | |
| tree | 3f91ce050b1ee050dbaaf8cc04f99c73bb43cd34 /FL | |
| parent | 3dcc91d1f09b78a43f6fa8e8f13fd09076da0476 (diff) | |
Driver-based rewrite of the Fl_Copy_Surface class.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11374 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'FL')
| -rw-r--r-- | FL/Fl_Copy_Surface.H | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/FL/Fl_Copy_Surface.H b/FL/Fl_Copy_Surface.H index 753068cb3..fa1e96ac2 100644 --- a/FL/Fl_Copy_Surface.H +++ b/FL/Fl_Copy_Surface.H @@ -48,8 +48,7 @@ */ class FL_EXPORT Fl_Copy_Surface : public Fl_Widget_Surface { private: - class Helper; - Helper *platform_surface; + class Fl_Copy_Surface_Driver *platform_surface; protected: void translate(int x, int y); void untranslate(); @@ -66,6 +65,24 @@ public: int printable_rect(int *w, int *h); }; + +class Fl_Copy_Surface_Driver : public Fl_Widget_Surface { + friend class Fl_Copy_Surface; +protected: + int width; + int height; + Fl_Copy_Surface_Driver(int w, int h) : Fl_Widget_Surface(NULL), width(w), height(h) {} + virtual ~Fl_Copy_Surface_Driver() {} + virtual void set_current() {} + virtual void translate(int x, int y) {} + virtual void untranslate() {} + int printable_rect(int *w, int *h) {*w = width; *h = height; return 0;} + virtual Fl_RGB_Image *image() {return NULL;} + virtual void end_current() {} + static Fl_Copy_Surface_Driver *newCopySurfaceDriver(int w, int h); +}; + + #endif // Fl_Copy_Surface_H // |
