diff options
| author | Matthias Melcher <fltk@matthiasm.com> | 2016-04-17 15:36:23 +0000 |
|---|---|---|
| committer | Matthias Melcher <fltk@matthiasm.com> | 2016-04-17 15:36:23 +0000 |
| commit | cdf85352c42dd2f3b43703897148e8fa513c9cdc (patch) | |
| tree | efdafdb13036cce810c6f648bb85c44854b86ff3 /src/drivers/Quartz/Fl_Quartz_Graphics_Driver_rect.cxx | |
| parent | c9d3eabf4e201384a930707fbe1b8a01771f5e3d (diff) | |
virtualized some Region calls.
There is a deeper issue here: regions should be handled by the graphics driver that is associated with the Fl_Window of this widget... .
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11643 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/drivers/Quartz/Fl_Quartz_Graphics_Driver_rect.cxx')
| -rw-r--r-- | src/drivers/Quartz/Fl_Quartz_Graphics_Driver_rect.cxx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_rect.cxx b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_rect.cxx index be31149f9..d61c7ad7e 100644 --- a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_rect.cxx +++ b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_rect.cxx @@ -202,7 +202,7 @@ void Fl_Quartz_Graphics_Driver::polygon(int x, int y, int x1, int y1, int x2, in // intersects current and x,y,w,h rectangle and returns result as a new Fl_Region static Fl_Region intersect_region_and_rect(Fl_Region current, int x,int y,int w, int h) { - if (current == NULL) return Fl_Graphics_Driver::XRectangleRegion(x,y,w,h); + if (current == NULL) return Fl_Graphics_Driver::default_driver().XRectangleRegion(x,y,w,h); CGRect r = Fl_Quartz_Graphics_Driver::fl_cgrectmake_cocoa(x, y, w, h); Fl_Region outr = (Fl_Region)malloc(sizeof(*outr)); outr->count = current->count; @@ -217,8 +217,8 @@ static Fl_Region intersect_region_and_rect(Fl_Region current, int x,int y,int w, outr->rects = (CGRect*)realloc(outr->rects, outr->count * sizeof(CGRect)); } else { - Fl_Graphics_Driver::XDestroyRegion(outr); - outr = Fl_Graphics_Driver::XRectangleRegion(0,0,0,0); + Fl_Graphics_Driver::default_driver().XDestroyRegion(outr); + outr = Fl_Graphics_Driver::default_driver().XRectangleRegion(0,0,0,0); } return outr; } |
