Fl_Shared_Image::reload() didn't set the image_ pointer properly
in all cases (STR #632) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3929 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
0184365c80
commit
416ff7f24e
2
CHANGES
2
CHANGES
@ -1,5 +1,7 @@
|
||||
CHANGES IN FLTK 1.1.7
|
||||
|
||||
- Fl_Shared_Image::reload() didn't set the image_
|
||||
pointer properly in all cases (STR #632)
|
||||
- Fl_Help_View::topline() incorrectly set the changed()
|
||||
flag (STR #631)
|
||||
- Fl_Choice::value() now supports NULL or -1 to deselect
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
//
|
||||
// "$Id: Fl_Shared_Image.cxx,v 1.23.2.21 2004/09/24 16:00:11 easysw Exp $"
|
||||
// "$Id: Fl_Shared_Image.cxx,v 1.23.2.22 2004/12/03 02:51:03 easysw Exp $"
|
||||
//
|
||||
// Shared image code for the Fast Light Tool Kit (FLTK).
|
||||
//
|
||||
@ -245,14 +245,15 @@ Fl_Shared_Image::reload() {
|
||||
if (img) {
|
||||
if (alloc_image_) delete image_;
|
||||
|
||||
image_ = img;
|
||||
alloc_image_ = 1;
|
||||
|
||||
if ((img->w() != w() && w()) || (img->h() != h() && h())) {
|
||||
// Make sure the reloaded image is the same size as the existing one.
|
||||
Fl_Image *temp = img->copy(w(), h());
|
||||
delete img;
|
||||
img = temp;
|
||||
image_ = temp;
|
||||
} else {
|
||||
image_ = img;
|
||||
}
|
||||
|
||||
update();
|
||||
@ -460,5 +461,5 @@ Fl_Shared_Image::remove_handler(Fl_Shared_Handler f) {
|
||||
|
||||
|
||||
//
|
||||
// End of "$Id: Fl_Shared_Image.cxx,v 1.23.2.21 2004/09/24 16:00:11 easysw Exp $".
|
||||
// End of "$Id: Fl_Shared_Image.cxx,v 1.23.2.22 2004/12/03 02:51:03 easysw Exp $".
|
||||
//
|
||||
|
||||
Loading…
Reference in New Issue
Block a user