diff options
| author | Manolo Gouy <Manolo> | 2016-04-15 11:30:10 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2016-04-15 11:30:10 +0000 |
| commit | 3f64e2b28d3556a1ea316fe6ae73eabf454f1fa8 (patch) | |
| tree | 74e9929b51eab4492bc3fc824b66b67b7bc7c9b0 /src | |
| parent | 156d2e40532d7e3b0b70ece59b131678379938d2 (diff) | |
Continue removing from class Fl_X what is not window-related.
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11613 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'src')
| -rw-r--r-- | src/CMakeLists.txt | 1 | ||||
| -rw-r--r-- | src/Fl_cocoa.mm | 4 | ||||
| -rw-r--r-- | src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.H | 1 | ||||
| -rw-r--r-- | src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.cxx | 8 |
4 files changed, 5 insertions, 9 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index 65649c596..3801a7d8a 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -263,6 +263,7 @@ elseif (APPLE) drivers/Cocoa/Fl_Cocoa_Screen_Driver.H drivers/Cocoa/Fl_Cocoa_Window_Driver.H drivers/Quartz/Fl_Quartz_Graphics_Driver.H + drivers/Quartz/Fl_Quartz_Copy_Surface_Driver.H drivers/Quartz/Fl_Font.H ) diff --git a/src/Fl_cocoa.mm b/src/Fl_cocoa.mm index a0aa4121e..9720977e3 100644 --- a/src/Fl_cocoa.mm +++ b/src/Fl_cocoa.mm @@ -1905,8 +1905,10 @@ int Fl_Cocoa_Screen_Driver::h() { } // computes the work area of the nth screen (screen #0 has the menubar) -void Fl_X::screen_work_area(int &X, int &Y, int &W, int &H, int n) +void Fl_Cocoa_Screen_Driver::screen_work_area(int &X, int &Y, int &W, int &H, int n) { + if (num_screens < 0) init(); + if (n < 0 || n >= num_screens) n = 0; fl_open_display(); NSRect r = [[[NSScreen screens] objectAtIndex:n] visibleFrame]; X = int(r.origin.x); diff --git a/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.H b/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.H index afcaad924..23e123e9c 100644 --- a/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.H +++ b/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.H @@ -64,6 +64,7 @@ public: virtual int h(); virtual void screen_xywh(int &X, int &Y, int &W, int &H, int n); virtual void screen_dpi(float &h, float &v, int n=0); + // implemented in Fl_cocoa.mm because uses Objective-c virtual void screen_work_area(int &X, int &Y, int &W, int &H, int n); // --- audible output virtual void beep(int type); diff --git a/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.cxx b/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.cxx index 6f0ebfa64..270660ea5 100644 --- a/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.cxx +++ b/src/drivers/Cocoa/Fl_Cocoa_Screen_Driver.cxx @@ -94,14 +94,6 @@ void Fl_Cocoa_Screen_Driver::init() } -void Fl_Cocoa_Screen_Driver::screen_work_area(int &X, int &Y, int &W, int &H, int n) -{ - if (num_screens < 0) init(); - if (n < 0 || n >= num_screens) n = 0; - Fl_X::screen_work_area(X, Y, W, H, n); -} - - void Fl_Cocoa_Screen_Driver::screen_xywh(int &X, int &Y, int &W, int &H, int n) { if (num_screens < 0) init(); |
