mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
kill usages of deprecated API
This commit is contained in:
-1
@@ -257,7 +257,6 @@ public class CodeCompletionHandlerBase implements CodeInsightActionHandler {
|
||||
if (editor.isOneLineMode()) {
|
||||
lookup.setCancelOnClickOutside(true);
|
||||
lookup.setCancelOnOtherWindowOpen(true);
|
||||
lookup.setForceLightweightPopup(false);
|
||||
}
|
||||
lookup.setFocused(!autopopup);
|
||||
return lookup;
|
||||
|
||||
+7
-7
@@ -147,12 +147,12 @@ public class DocumentationManager {
|
||||
PopupUpdateProcessor updateProcessor = new PopupUpdateProcessor(element.getProject()) {
|
||||
public void updatePopup(Object lookupItemObject) {
|
||||
if (lookupItemObject instanceof PsiElement) {
|
||||
doShowJavaDocInfo((PsiElement)lookupItemObject, true, false, this, original, false);
|
||||
doShowJavaDocInfo((PsiElement)lookupItemObject, false, this, original, false);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
doShowJavaDocInfo(element, true, false, updateProcessor, original, false);
|
||||
doShowJavaDocInfo(element, false, updateProcessor, original, false);
|
||||
}
|
||||
|
||||
public void showJavaDocInfo(final Editor editor, @Nullable final PsiFile file, boolean requestFocus) {
|
||||
@@ -205,7 +205,7 @@ public class DocumentationManager {
|
||||
final PopupUpdateProcessor updateProcessor = new PopupUpdateProcessor(project) {
|
||||
public void updatePopup(Object lookupIteObject) {
|
||||
if (lookupIteObject instanceof PsiElement) {
|
||||
doShowJavaDocInfo((PsiElement)lookupIteObject, false, false, this, originalElement, autoupdate);
|
||||
doShowJavaDocInfo((PsiElement)lookupIteObject, false, this, originalElement, autoupdate);
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -228,15 +228,16 @@ public class DocumentationManager {
|
||||
}
|
||||
}
|
||||
else {
|
||||
doShowJavaDocInfo(element, false, false, this, originalElement, autoupdate);
|
||||
doShowJavaDocInfo(element, false, this, originalElement, autoupdate);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
doShowJavaDocInfo(element, false, requestFocus, updateProcessor, originalElement, autoupdate);
|
||||
doShowJavaDocInfo(element, requestFocus, updateProcessor, originalElement, autoupdate);
|
||||
}
|
||||
|
||||
private void doShowJavaDocInfo(final PsiElement element, boolean heavyWeight, boolean requestFocus, PopupUpdateProcessor updateProcessor, final PsiElement originalElement, final boolean autoupdate) {
|
||||
private void doShowJavaDocInfo(final PsiElement element, boolean requestFocus, PopupUpdateProcessor updateProcessor,
|
||||
final PsiElement originalElement, final boolean autoupdate) {
|
||||
Project project = getProject(element);
|
||||
|
||||
if (myToolWindow == null && PropertiesComponent.getInstance().isTrueValue(SHOW_DOCUMENTATION_IN_TOOL_WINDOW)) {
|
||||
@@ -304,7 +305,6 @@ public class DocumentationManager {
|
||||
.addListener(updateProcessor)
|
||||
.addUserData(updateProcessor)
|
||||
.setKeyboardActions(actions)
|
||||
.setForceHeavyweight(heavyWeight)
|
||||
.setDimensionServiceKey(myProject, JAVADOC_LOCATION_AND_SIZE, false)
|
||||
.setResizable(true)
|
||||
.setMovable(true)
|
||||
|
||||
@@ -744,7 +744,7 @@ public abstract class ChooseByNameBase {
|
||||
close(false);
|
||||
return Boolean.TRUE;
|
||||
}
|
||||
}).setFocusable(true).setRequestFocus(true).setForceHeavyweight(true).setModalContext(false).setCancelOnClickOutside(false);
|
||||
}).setFocusable(true).setRequestFocus(true).setModalContext(false).setCancelOnClickOutside(false);
|
||||
|
||||
Point point = new Point(x, y);
|
||||
SwingUtilities.convertPointToScreen(point, layeredPane);
|
||||
|
||||
@@ -128,7 +128,7 @@ public class ChooseByNamePopup extends ChooseByNameBase implements ChooseByNameP
|
||||
if (myDropdownPopup == null) {
|
||||
ComponentPopupBuilder builder = JBPopupFactory.getInstance().createComponentPopupBuilder(myListScrollPane, myListScrollPane);
|
||||
builder.setFocusable(false).setRequestFocus(false).setCancelKeyEnabled(false).setFocusOwners(new JComponent[] {myTextField}).setBelongsToGlobalPopupStack(false)
|
||||
.setForceHeavyweight(true).setModalContext(false).setAdText(adText).setMayBeParent(true);
|
||||
.setModalContext(false).setAdText(adText).setMayBeParent(true);
|
||||
builder.setCancelCallback(new Computable<Boolean>() {
|
||||
@Override
|
||||
public Boolean compute() {
|
||||
|
||||
@@ -212,7 +212,6 @@ public class LightweightHint extends UserDataHolderBase implements Hint {
|
||||
}
|
||||
})
|
||||
.setCancelOnOtherWindowOpen(myCancelOnOtherWindowOpen)
|
||||
.setForceHeavyweight(!myForceLightweightPopup && myForceShowAsPopup)
|
||||
.createPopup();
|
||||
|
||||
beforeShow();
|
||||
|
||||
@@ -80,7 +80,6 @@ public class FramelessNotificationPopup {
|
||||
|
||||
myFadeInTimer = UIUtil.createNamedTimer("Frameless fade in",10, myFadeTracker);
|
||||
myPopup = JBPopupFactory.getInstance().createComponentPopupBuilder(myContent, null)
|
||||
.setForceHeavyweight(true)
|
||||
.setRequestFocus(false)
|
||||
.setResizable(false)
|
||||
.setMovable(true)
|
||||
|
||||
Reference in New Issue
Block a user