Begin moving non window-related member functions out of Fl_X class.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11629 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
f8104524e8
commit
083e9ed06a
1
FL/x.H
1
FL/x.H
@ -136,7 +136,6 @@ public:
|
||||
static void x(Fl_Window* wi, int X) {wi->x(X);}
|
||||
static void y(Fl_Window* wi, int Y) {wi->y(Y);}
|
||||
static int ewmh_supported();
|
||||
static int xrender_supported();
|
||||
static void activate_window(Window w);
|
||||
static void copy_image(const unsigned char* data, int W, int H, int destination = 0);
|
||||
};
|
||||
|
19
src/Fl_x.cxx
19
src/Fl_x.cxx
@ -40,6 +40,7 @@
|
||||
# include "drivers/X11/Fl_X11_Screen_Driver.H"
|
||||
# include "drivers/X11/Fl_X11_Window_Driver.H"
|
||||
# include "drivers/X11/Fl_X11_System_Driver.H"
|
||||
# include "drivers/Xlib/Fl_Xlib_Graphics_Driver.H"
|
||||
# include <unistd.h>
|
||||
# include <time.h>
|
||||
# include <sys/time.h>
|
||||
@ -2194,17 +2195,17 @@ int Fl_X::ewmh_supported() {
|
||||
return result;
|
||||
}
|
||||
|
||||
int Fl_X::xrender_supported() {
|
||||
#if HAVE_XRENDER
|
||||
static int result = -1;
|
||||
|
||||
if (result == -1) {
|
||||
fl_open_display();
|
||||
|
||||
int nop1, nop2;
|
||||
result = XRenderQueryExtension(fl_display, &nop1, &nop2);
|
||||
}
|
||||
static int xrender_supported() {
|
||||
int nop1, nop2;
|
||||
fl_open_display();
|
||||
return XRenderQueryExtension(fl_display, &nop1, &nop2);
|
||||
}
|
||||
#endif
|
||||
|
||||
char Fl_Xlib_Graphics_Driver::can_do_alpha_blending() {
|
||||
#if HAVE_XRENDER
|
||||
static char result = (char)xrender_supported();
|
||||
return result;
|
||||
#else
|
||||
return 0;
|
||||
|
@ -61,12 +61,6 @@ void Fl_Xlib_Graphics_Driver::gc(void *value) {
|
||||
fl_gc = gc_;
|
||||
}
|
||||
|
||||
|
||||
char Fl_Xlib_Graphics_Driver::can_do_alpha_blending() {
|
||||
return Fl_X::xrender_supported();
|
||||
}
|
||||
|
||||
|
||||
void Fl_Xlib_Graphics_Driver::copy_offscreen(int x, int y, int w, int h, Fl_Offscreen pixmap, int srcx, int srcy) {
|
||||
XCopyArea(fl_display, pixmap, fl_window, gc_, srcx, srcy, w, h, x, y);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user