summaryrefslogtreecommitdiff
path: root/src/drivers/WinAPI
diff options
context:
space:
mode:
authorManolo Gouy <Manolo>2016-03-10 18:45:50 +0000
committerManolo Gouy <Manolo>2016-03-10 18:45:50 +0000
commit7098924b82110cf468d3cbdc4742bd9a2632296d (patch)
tree926e95e71f236d2ad05bd503d572d327c2262a11 /src/drivers/WinAPI
parent9bffd04b3a096fe1032307aebf2654049de2929e (diff)
Add code to delete Fl_WinAPI_Window_Driver object.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11341 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/drivers/WinAPI')
-rw-r--r--src/drivers/WinAPI/Fl_WinAPI_Window_Driver.H1
-rw-r--r--src/drivers/WinAPI/Fl_WinAPI_Window_Driver.cxx8
2 files changed, 9 insertions, 0 deletions
diff --git a/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.H b/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.H
index 252550a56..2517130bb 100644
--- a/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.H
+++ b/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.H
@@ -56,6 +56,7 @@ private:
void shape_alpha_(Fl_Image* img, int offset);
public:
Fl_WinAPI_Window_Driver(Fl_Window*);
+ ~Fl_WinAPI_Window_Driver();
virtual void shape(const Fl_Image* img);
virtual void draw();
};
diff --git a/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.cxx b/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.cxx
index 4947ff6e2..e61fa4799 100644
--- a/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.cxx
+++ b/src/drivers/WinAPI/Fl_WinAPI_Window_Driver.cxx
@@ -32,6 +32,14 @@ Fl_WinAPI_Window_Driver::Fl_WinAPI_Window_Driver(Fl_Window *win)
{
}
+Fl_WinAPI_Window_Driver::~Fl_WinAPI_Window_Driver()
+{
+ if (shape_data_) {
+ delete shape_data_->todelete_;
+ delete shape_data_;
+ }
+}
+
void Fl_WinAPI_Window_Driver::shape_bitmap_(Fl_Image* b) {
shape_data_->shape_ = b;
}