Fix the implementation of Fl_Window::default_icons(const Fl_RGB_Image *icons[], int count) under the driver model.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11417 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Manolo Gouy 2016-03-24 06:19:10 +00:00
parent 6e141d14df
commit 1778ee8831
5 changed files with 7 additions and 5 deletions

View File

@ -29,7 +29,6 @@
#include <stdlib.h>
class Fl_X;
class Fl_Image;
class Fl_Shared_Image;
@ -132,6 +131,8 @@ public:
virtual const void *icon() const {return NULL;} // TODO: check
virtual void icon(const void * ic) {} // TODO: check
virtual void free_icons() {} // TODO: check
// each platform implements this its own way
static void default_icons(const Fl_RGB_Image *icons[], int count);
// --- window printing helper
virtual void capture_titlebar_and_borders(Fl_Shared_Image*& top, Fl_Shared_Image*& left, Fl_Shared_Image*& bottom, Fl_Shared_Image*& right);

View File

@ -21,7 +21,6 @@
// crap you need to do to communicate with X is in Fl_x.cxx, the
// equivalent (but totally different) crap for MSWindows is in Fl_win32.cxx
#include <FL/Fl.H>
#include <FL/x.H>
#include <FL/Fl_Window_Driver.H>
#include <FL/Fl_RGB_Image.H>
#include <FL/Fl_Window.H>
@ -310,7 +309,7 @@ void Fl_Window::default_icon(const Fl_RGB_Image *icon) {
\see Fl_Window::icons(const Fl_RGB_Image *[], int)
*/
void Fl_Window::default_icons(const Fl_RGB_Image *icons[], int count) {
Fl_X::set_default_icons(icons, count);
Fl_Window_Driver::default_icons(icons, count);
}
/** Sets a single window icon.

View File

@ -158,6 +158,8 @@ void fl_set_status(int x, int y, int w, int h)
{
}
void Fl_Window_Driver::default_icons(const Fl_RGB_Image *icons[], int count) {}
/*
* Mac keyboard lookup table
*/

View File

@ -2030,7 +2030,7 @@ static const Fl_RGB_Image *find_best_icon(int ideal_width,
return best;
}
void Fl_X::set_default_icons(const Fl_RGB_Image *icons[], int count) {
void Fl_Window_Driver::default_icons(const Fl_RGB_Image *icons[], int count) {
const Fl_RGB_Image *best_big, *best_small;
if (default_big_icon != NULL)

View File

@ -2708,7 +2708,7 @@ static void icons_to_property(const Fl_RGB_Image *icons[], int count,
}
}
void Fl_X::set_default_icons(const Fl_RGB_Image *icons[], int count) {
void Fl_Window_Driver::default_icons(const Fl_RGB_Image *icons[], int count) {
if (default_net_wm_icons) {
delete [] default_net_wm_icons;
default_net_wm_icons = 0L;