Fixed issues with offsets when the window-manager has a toolbar that
consumes space and prevents overlap.
This commit is contained in:
parent
85b9a8d961
commit
abc7966f19
|
@ -301,14 +301,22 @@ class LookAndFeel {
|
||||||
// the popups are ALL the same size!
|
// the popups are ALL the same size!
|
||||||
// popups at TOP grow down, popups at BOTTOM grow up
|
// popups at TOP grow down, popups at BOTTOM grow up
|
||||||
int targetY;
|
int targetY;
|
||||||
|
int prevTargetY; // this is to determine if there is an offset as a result of a toolbar/etc
|
||||||
int anchorX = sourceLook.anchorX;
|
int anchorX = sourceLook.anchorX;
|
||||||
int anchorY = sourceLook.anchorY;
|
int anchorY = sourceLook.anchorY;
|
||||||
|
|
||||||
if (isShowFromTop(sourceLook)) {
|
|
||||||
targetY = anchorY + (popupIndex * (NotifyCanvas.HEIGHT + 10));
|
if (popupIndex == 0) {
|
||||||
}
|
targetY = anchorY;
|
||||||
else {
|
} else {
|
||||||
targetY = anchorY - (popupIndex * (NotifyCanvas.HEIGHT + 10));
|
int previousY = looks.get(popupIndex - 1).getParentY();
|
||||||
|
|
||||||
|
if (isShowFromTop(sourceLook)) {
|
||||||
|
targetY = previousY + (NotifyCanvas.HEIGHT + 10);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
targetY = previousY - (NotifyCanvas.HEIGHT + 10);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
looks.add(sourceLook);
|
looks.add(sourceLook);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user