diff options
| author | Manolo Gouy <Manolo> | 2016-02-18 16:21:51 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2016-02-18 16:21:51 +0000 |
| commit | f33b45f1d30653fb5da4817089e38ff0a2413cfb (patch) | |
| tree | 9edc759690defa581b00b6ada80bb334f4ac5da8 /src/drivers/Quartz/Fl_Quartz_Graphics_Driver_line_style.cxx | |
| parent | 6ce27012a9412c4964e0ae40c81ea92ff39a61d3 (diff) | |
Remove all uses of the fl_gc global variable. Towards a clean driver model.
fl_gc remains usable by the application as a hook into the system.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11189 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src/drivers/Quartz/Fl_Quartz_Graphics_Driver_line_style.cxx')
| -rw-r--r-- | src/drivers/Quartz/Fl_Quartz_Graphics_Driver_line_style.cxx | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_line_style.cxx b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_line_style.cxx index b30743a1a..9231b0581 100644 --- a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_line_style.cxx +++ b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver_line_style.cxx @@ -36,11 +36,11 @@ static /*enum*/ CGLineJoin fl_quartz_line_join_ = kCGLineJoinMiter; static CGFloat *fl_quartz_line_pattern = 0; static int fl_quartz_line_pattern_size = 0; -void fl_quartz_restore_line_style_() { - CGContextSetLineWidth(fl_gc, fl_quartz_line_width_); - CGContextSetLineCap(fl_gc, fl_quartz_line_cap_); - CGContextSetLineJoin(fl_gc, fl_quartz_line_join_); - CGContextSetLineDash(fl_gc, 0, fl_quartz_line_pattern, fl_quartz_line_pattern_size); +void fl_quartz_restore_line_style_(CGContextRef gc) { + CGContextSetLineWidth(gc, fl_quartz_line_width_); + CGContextSetLineCap(gc, fl_quartz_line_cap_); + CGContextSetLineJoin(gc, fl_quartz_line_join_); + CGContextSetLineDash(gc, 0, fl_quartz_line_pattern, fl_quartz_line_pattern_size); } void Fl_Quartz_Graphics_Driver::line_style(int style, int width, char* dashes) { @@ -94,7 +94,7 @@ void Fl_Quartz_Graphics_Driver::line_style(int style, int width, char* dashes) { fl_quartz_line_pattern = 0; fl_quartz_line_pattern_size = 0; } - fl_quartz_restore_line_style_(); + fl_quartz_restore_line_style_((CGContextRef)get_gc()); } #endif // FL_CFG_GFX_QUARTZ |
