mirror of
https://gitflic.ru/project/openide/openide.git
synced 2025-12-16 22:51:17 +07:00
RegExp: fix balloon resizing on typing enter in the sample field (IDEA-254217)
GitOrigin-RevId: d6abcafdb487fe265540c49442f8ce6fa254f456
This commit is contained in:
committed by
intellij-monorepo-bot
parent
d32e27ad99
commit
d1c88e868f
@@ -27,6 +27,8 @@ import com.intellij.openapi.fileTypes.LanguageFileType;
|
|||||||
import com.intellij.openapi.fileTypes.PlainTextFileType;
|
import com.intellij.openapi.fileTypes.PlainTextFileType;
|
||||||
import com.intellij.openapi.progress.ProcessCanceledException;
|
import com.intellij.openapi.progress.ProcessCanceledException;
|
||||||
import com.intellij.openapi.project.Project;
|
import com.intellij.openapi.project.Project;
|
||||||
|
import com.intellij.openapi.ui.popup.Balloon;
|
||||||
|
import com.intellij.openapi.ui.popup.JBPopupFactory;
|
||||||
import com.intellij.openapi.util.Disposer;
|
import com.intellij.openapi.util.Disposer;
|
||||||
import com.intellij.openapi.util.Key;
|
import com.intellij.openapi.util.Key;
|
||||||
import com.intellij.openapi.util.NlsContexts;
|
import com.intellij.openapi.util.NlsContexts;
|
||||||
@@ -250,6 +252,11 @@ public final class CheckRegExpForm {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void update() {
|
private void update() {
|
||||||
|
// triggers resizing of balloon when necessary
|
||||||
|
myRootPanel.revalidate();
|
||||||
|
Balloon balloon = JBPopupFactory.getInstance().getParentBalloonFor(myRootPanel);
|
||||||
|
if (balloon != null && !balloon.isDisposed()) balloon.revalidate();
|
||||||
|
|
||||||
updater.cancelAllRequests();
|
updater.cancelAllRequests();
|
||||||
if (!updater.isDisposed()) {
|
if (!updater.isDisposed()) {
|
||||||
updater.addRequest(() -> {
|
updater.addRequest(() -> {
|
||||||
|
|||||||
Reference in New Issue
Block a user