Remove unimplemented window icon-related member functions and variables.

Wayland uses .desktop files to set window icons.
This commit is contained in:
ManoloFLTK 2022-04-15 08:31:32 +02:00
parent a7267f91ae
commit 827f91110b
2 changed files with 0 additions and 51 deletions

View File

@ -64,12 +64,6 @@ public:
Fl_Wayland_Screen_Driver::output* output;
struct wl_list link;
};
struct icon_data {
const void *legacy_icon;
Fl_RGB_Image **icons;
int count;
} *icon_;
// --- support for screen-specific scaling factors
struct type_for_resize_window_between_screens {
int screen;
@ -82,8 +76,6 @@ public:
void shape_bitmap_(Fl_Image* b);
void shape_alpha_(Fl_Image* img, int offset);
void update_scale();
public:
enum kind {DECORATED, SUBWINDOW, POPUP, UNFRAMED};
struct xdg_toplevel *xdg_toplevel();
Fl_Wayland_Window_Driver(Fl_Window*);
@ -127,10 +119,6 @@ public:
virtual int set_cursor(const Fl_RGB_Image*, int, int);
virtual void shape(const Fl_Image* img);
virtual void icons(const Fl_RGB_Image *icons[], int count);
virtual const void *icon() const;
virtual void icon(const void * ic);
virtual void free_icons();
virtual void capture_titlebar_and_borders(Fl_RGB_Image*& top, Fl_RGB_Image*& left, Fl_RGB_Image*& bottom, Fl_RGB_Image*& right);
virtual int scroll(int src_x, int src_y, int src_w, int src_h, int dest_x, int dest_y, void (*draw_area)(void*, int,int,int,int), void* data);
virtual void wait_for_expose();

View File

@ -63,8 +63,6 @@ void Fl_Wayland_Window_Driver::destroy_double_buffer() {
Fl_Wayland_Window_Driver::Fl_Wayland_Window_Driver(Fl_Window *win) : Fl_Window_Driver(win)
{
icon_ = new icon_data;
memset(icon_, 0, sizeof(icon_data));
cursor_ = NULL;
in_handle_configure = false;
screen_num_ = -1;
@ -99,7 +97,6 @@ Fl_Wayland_Window_Driver::~Fl_Wayland_Window_Driver()
delete[] data;
delete shape_data_;
}
delete icon_;
delete_cursor_();
}
@ -293,42 +290,6 @@ void Fl_Wayland_Window_Driver::draw_end()
}
void Fl_Wayland_Window_Driver::icons(const Fl_RGB_Image *icons[], int count) {
free_icons();
if (count > 0) {
icon_->icons = new Fl_RGB_Image*[count];
icon_->count = count;
// FIXME: Fl_RGB_Image lacks const modifiers on methods
for (int i = 0;i < count;i++) {
icon_->icons[i] = (Fl_RGB_Image*)((Fl_RGB_Image*)icons[i])->copy();
icon_->icons[i]->normalize();
}
}
}
const void *Fl_Wayland_Window_Driver::icon() const {
return icon_->legacy_icon;
}
void Fl_Wayland_Window_Driver::icon(const void * ic) {
free_icons();
icon_->legacy_icon = ic;
}
void Fl_Wayland_Window_Driver::free_icons() {
int i;
icon_->legacy_icon = 0L;
if (icon_->icons) {
for (i = 0;i < icon_->count;i++)
delete icon_->icons[i];
delete [] icon_->icons;
icon_->icons = 0L;
}
icon_->count = 0;
}
/* Returns images of the captures of the window title-bar, and the left, bottom and right window borders
(or NULL if a particular border is absent).
Returned images can be deleted after use. Their depth and size may be platform-dependent.