summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/Fl_x.cxx2
-rw-r--r--src/drivers/X11/Fl_X11_Screen_Driver.H1
-rw-r--r--src/drivers/Xlib/Fl_Xlib_Copy_Surface_Driver.cxx3
3 files changed, 4 insertions, 2 deletions
diff --git a/src/Fl_x.cxx b/src/Fl_x.cxx
index 5a784be71..9f45072df 100644
--- a/src/Fl_x.cxx
+++ b/src/Fl_x.cxx
@@ -1024,7 +1024,7 @@ static unsigned char *create_bmp(const unsigned char *data, int W, int H, int *r
}
// takes a raw RGB image and puts it in the copy/paste buffer
-void Fl_X::copy_image(const unsigned char *data, int W, int H, int clipboard){
+void Fl_X11_Screen_Driver::copy_image(const unsigned char *data, int W, int H, int clipboard){
if (!data || W <= 0 || H <= 0) return;
delete[] fl_selection_buffer[clipboard];
fl_selection_buffer[clipboard] = (char *) create_bmp(data,W,H,&fl_selection_length[clipboard]);
diff --git a/src/drivers/X11/Fl_X11_Screen_Driver.H b/src/drivers/X11/Fl_X11_Screen_Driver.H
index cc202e881..bf7aca3c2 100644
--- a/src/drivers/X11/Fl_X11_Screen_Driver.H
+++ b/src/drivers/X11/Fl_X11_Screen_Driver.H
@@ -45,6 +45,7 @@ protected:
public:
static int ewmh_supported();
+ static void copy_image(const unsigned char* data, int W, int H, int destination);
// --- display management
virtual void display(const char *disp);
virtual int visual(int flags);
diff --git a/src/drivers/Xlib/Fl_Xlib_Copy_Surface_Driver.cxx b/src/drivers/Xlib/Fl_Xlib_Copy_Surface_Driver.cxx
index e665bc9ea..2c31e109d 100644
--- a/src/drivers/Xlib/Fl_Xlib_Copy_Surface_Driver.cxx
+++ b/src/drivers/Xlib/Fl_Xlib_Copy_Surface_Driver.cxx
@@ -24,6 +24,7 @@
#include <FL/x.H>
#include <FL/fl_draw.H>
#include "Fl_Translated_Xlib_Graphics_Driver.H"
+#include "../X11/Fl_X11_Screen_Driver.H"
class Fl_Xlib_Copy_Surface_Driver : public Fl_Copy_Surface_Driver {
friend class Fl_Copy_Surface_Driver;
@@ -69,7 +70,7 @@ Fl_Xlib_Copy_Surface_Driver::~Fl_Xlib_Copy_Surface_Driver() {
unsigned char *data = fl_read_image(NULL,0,0,width,height,0);
fl_window = oldwindow;
_ss->set_current();
- Fl_X::copy_image(data,width,height,1);
+ Fl_X11_Screen_Driver::copy_image(data, width, height, 1);
delete[] data;
fl_delete_offscreen(xid);
}