Fix Fl_GDI_Graphics_Driver::uncache(Fl_RGB_Image*,...) that did not delete correctly the cached offscreen object.
This bug was detected by a test program that rotates an SVG image. But it's not related to SVG, and concerns any Fl_RGB_Image on the WIN32 platform. It was introduced when image support was modified according to the driver model. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12600 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
52d4fef698
commit
5a579962a6
@ -181,7 +181,6 @@ int Fl_Graphics_Driver::start_image(Fl_Image *img, int XP, int YP, int WP, int H
|
|||||||
|
|
||||||
/** Support function for image drawing */
|
/** Support function for image drawing */
|
||||||
void Fl_Graphics_Driver::uncache_pixmap(fl_uintptr_t p) {
|
void Fl_Graphics_Driver::uncache_pixmap(fl_uintptr_t p) {
|
||||||
fl_delete_offscreen((Fl_Offscreen)p);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -3,7 +3,7 @@
|
|||||||
//
|
//
|
||||||
// WIN32 image drawing code for the Fast Light Tool Kit (FLTK).
|
// WIN32 image drawing code for the Fast Light Tool Kit (FLTK).
|
||||||
//
|
//
|
||||||
// Copyright 1998-2016 by Bill Spitzak and others.
|
// Copyright 1998-2017 by Bill Spitzak and others.
|
||||||
//
|
//
|
||||||
// This library is free software. Distribution and use rights are outlined in
|
// This library is free software. Distribution and use rights are outlined in
|
||||||
// the file "COPYING" which should have been included with this file. If this
|
// the file "COPYING" which should have been included with this file. If this
|
||||||
@ -559,7 +559,7 @@ int Fl_GDI_Graphics_Driver::draw_scaled(Fl_Image *img, int XP, int YP, int WP, i
|
|||||||
void Fl_GDI_Graphics_Driver::uncache(Fl_RGB_Image*, fl_uintptr_t &id_, fl_uintptr_t &mask_)
|
void Fl_GDI_Graphics_Driver::uncache(Fl_RGB_Image*, fl_uintptr_t &id_, fl_uintptr_t &mask_)
|
||||||
{
|
{
|
||||||
if (id_) {
|
if (id_) {
|
||||||
fl_delete_offscreen((Fl_Offscreen)id_);
|
DeleteObject((Fl_Offscreen)id_);
|
||||||
id_ = 0;
|
id_ = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user