mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-147259 "Find Usages" popup is 2 pixels too small, showing unnecessary scrollbar
This commit is contained in:
@@ -1075,7 +1075,8 @@ public class ShowUsagesAction extends AnAction implements PopupAction {
|
||||
|
||||
int footer = footerSize.height;
|
||||
int footerBorder = footer == 0 ? 0 : 1;
|
||||
rectangle.height += headerSize.height + footer + footerBorder;
|
||||
Insets insets = ((AbstractPopup)popup).getPopupBorder().getBorderInsets(content);
|
||||
rectangle.height += headerSize.height + footer + footerBorder + insets.top + insets.bottom;
|
||||
ScreenUtil.fitToScreen(rectangle);
|
||||
Dimension newDim = rectangle.getSize();
|
||||
window.setBounds(rectangle);
|
||||
|
||||
@@ -395,6 +395,11 @@ public class AbstractPopup implements JBPopup {
|
||||
setAdText(s, SwingConstants.LEFT);
|
||||
}
|
||||
|
||||
@NotNull
|
||||
public PopupBorder getPopupBorder() {
|
||||
return myPopupBorder;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setAdText(@NotNull final String s, int alignment) {
|
||||
if (myAdComponent == null) {
|
||||
|
||||
Reference in New Issue
Block a user