mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-185543 do not ignore a footer height if popup is not shown yet
This commit is contained in:
@@ -1592,20 +1592,18 @@ public class AbstractPopup implements JBPopup {
|
||||
private void setSize(Dimension size, boolean adjustByContent) {
|
||||
if (isBusy()) return;
|
||||
|
||||
Dimension toSet = size;
|
||||
Dimension toSet = new Dimension(size);
|
||||
if (adjustByContent) toSet.height += getAdComponentHeight();
|
||||
if (myPopup == null) {
|
||||
myForcedSize = toSet;
|
||||
}
|
||||
else {
|
||||
if (adjustByContent) {
|
||||
toSet.height += getAdComponentHeight();
|
||||
}
|
||||
updateMaskAndAlpha(setSize(myContent, toSet));
|
||||
}
|
||||
}
|
||||
|
||||
private int getAdComponentHeight() {
|
||||
return myAdComponent != null && myAdComponent.isShowing() ? myAdComponent.getPreferredSize().height + JBUI.scale(1) : 0;
|
||||
return myAdComponent != null ? myAdComponent.getPreferredSize().height + JBUI.scale(1) : 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user