Returns the screen containing a rectangle, or -1 if none does.
| 61 | |
| 62 | // Returns the screen containing a rectangle, or -1 if none does. |
| 63 | int ScreenContaining( wxRect & r ){ |
| 64 | unsigned int n = wxDisplay::GetCount(); |
| 65 | for(unsigned int i = 0;i<n;i++){ |
| 66 | wxDisplay d(i); |
| 67 | wxRect scr = d.GetClientArea(); |
| 68 | if( scr.Contains( r ) ) |
| 69 | return (int)i; |
| 70 | } |
| 71 | return -1; |
| 72 | } |
| 73 | |
| 74 | // true IFF TL and BR corners are on a connected display. |
| 75 | // Does not need to check all four. We just need to check that |
no test coverage detected