Correctly locate a candidate panel's screen
Previously only the x value was used to determine the screen to which a candidate panel should below. That was incorrect. The entire point needs to be considered. This fixes the same issue that affected OpenVanilla: https://github.com/openvanilla/openvanilla/issues/49
This commit is contained in:
parent
5ff3efb385
commit
25ea443891
|
@ -98,7 +98,7 @@
|
|||
|
||||
for (NSScreen *screen in [NSScreen screens]) {
|
||||
NSRect frame = [screen visibleFrame];
|
||||
if (topLeftPoint.x >= NSMinX(frame) && topLeftPoint.x <= NSMaxX(frame)) {
|
||||
if (topLeftPoint.x >= NSMinX(frame) && topLeftPoint.x <= NSMaxX(frame) && topLeftPoint.y >= NSMinY(frame) && topLeftPoint.y <= NSMaxY(frame)) {
|
||||
screenFrame = frame;
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue