void (@NotNull String tabID, @Nullable String searchText, @NotNull AnActionEvent initEvent) { if (isShown()) { throw new IllegalStateException("Method should cannot be called when popup is shown"); } Project project = initEvent.getProject(); List<SearchEverywhereContributor<?>> contributors = createContributors(initEvent, project); SearchEverywhereContributorValidationRule.updateContributorsMap(contributors); SearchEverywhereSpellingCorrector spellingCorrector = SearchEverywhereSpellingCorrector.getInstance(project); mySearchEverywhereUI = createView(myProject, contributors, spellingCorrector); contributors.forEach(c -> Disposer.register(mySearchEverywhereUI, c)); mySearchEverywhereUI.switchToTab(tabID); myHistoryIterator = myHistoryList.getIterator(tabID); //history could be suppressed by user for some reasons (creating promo video, conference demo etc.) boolean suppressHistory = SystemProperties.getBooleanProperty("idea.searchEverywhere.noHistory", false); //or could be suppressed just for All tab in registry suppressHistory = suppressHistory || (ALL_CONTRIBUTORS_GROUP_ID.equals(tabID) && Registry.is("search.everywhere.disable.history.for.all")); if (searchText == null && !suppressHistory) { searchText = myHistoryIterator.prev(); } myBalloon = JBPopupFactory.getInstance().createComponentPopupBuilder(mySearchEverywhereUI, mySearchEverywhereUI.getSearchField()) .setProject(myProject) .setModalContext(false) .setCancelOnClickOutside(true) .setRequestFocus(true) .setCancelKeyEnabled(false) .setCancelCallback(() -> { saveSearchText(); DIALOG_CLOSED.log(myProject); return true; }) .setResizable(true) .setMovable(true) .setDimensionServiceKey(project, LOCATION_SETTINGS_KEY, true) .setLocateWithinScreenBounds(false) .createPopup(); Disposer.register(myBalloon, mySearchEverywhereUI); OpenInRightSplitAction.Companion.overrideDoubleClickWithOneClick(myBalloon.getContent()); if (project != null) { Disposer.register(project, myBalloon); } Dimension size = mySearchEverywhereUI.getMinimumSize(); JBInsets.addTo(size, myBalloon.getContent().getInsets()); myBalloon.setMinimumSize(size); UserDataHolder dataHolder = myProject != null ? project : ApplicationManager.getApplication(); ConcurrentHashMap<ClientId, JBPopup> map = dataHolder.getUserData(SEARCH_EVERYWHERE_POPUP); if (map == null) { map = new ConcurrentHashMap<>(); dataHolder.putUserData(SEARCH_EVERYWHERE_POPUP, map); } map.put(ClientId.getCurrent(), myBalloon); if (searchText != null && !searchText.isEmpty()) { mySearchEverywhereUI.getSearchField().setText(searchText); if (!Boolean.FALSE.equals(initEvent.getData(IS_SELECT_SEARCH_TEXT))) { mySearchEverywhereUI.getSearchField().selectAll(); } } Disposer.register(myBalloon, () -> { saveSize(); Objects.requireNonNull(dataHolder.getUserData(SEARCH_EVERYWHERE_POPUP)).remove(ClientId.getCurrent()); mySearchEverywhereUI = null; myBalloon = null; myBalloonFullSize = null; }); myBalloonFullSize = getStateService().getSize(LOCATION_SETTINGS_KEY); if (mySearchEverywhereUI.getViewType() == BigPopupUI.ViewType.SHORT) { Dimension prefSize = mySearchEverywhereUI.getPreferredSize(); myBalloon.setSize(prefSize); } calcPositionAndShow(initEvent, project, myBalloon); }