本文整理汇总了Java中com.intellij.ide.actions.ShowSettingsUtilImpl类的典型用法代码示例。如果您正苦于以下问题:Java ShowSettingsUtilImpl类的具体用法?Java ShowSettingsUtilImpl怎么用?Java ShowSettingsUtilImpl使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
ShowSettingsUtilImpl类属于com.intellij.ide.actions包,在下文中一共展示了ShowSettingsUtilImpl类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: actionPerformed
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
@Override
public void actionPerformed(ActionEvent e) {
final PluginManagerConfigurable configurable = createAvailableConfigurable(myVendor);
final SingleConfigurableEditor configurableEditor =
new SingleConfigurableEditor(myActionsPanel, configurable, ShowSettingsUtilImpl.createDimensionKey(configurable), false) {
{
setOKButtonText(CommonBundle.message("close.action.name"));
setOKButtonMnemonic('C');
final String filter = myFilter.getFilter();
if (!StringUtil.isEmptyOrSpaces(filter)) {
final Runnable searchRunnable = configurable.enableSearch(filter);
LOG.assertTrue(searchRunnable != null);
searchRunnable.run();
}
}
@NotNull
@Override
protected Action[] createActions() {
return new Action[]{getOKAction()};
}
};
configurableEditor.show();
}
示例2: createForcePushInfoLabel
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
@NotNull
private JComponent createForcePushInfoLabel() {
JPanel text = new JPanel();
text.setLayout(new BoxLayout(text, BoxLayout.X_AXIS));
JLabel label = new JLabel("You can enable and configure Force Push in " + ShowSettingsUtil.getSettingsMenuName() + ".");
label.setEnabled(false);
label.setFont(JBUI.Fonts.smallFont());
text.add(label);
ActionLink here = new ActionLink("Configure", new AnAction() {
@Override
public void actionPerformed(AnActionEvent e) {
Project project = myController.getProject();
VcsPushDialog.this.doCancelAction(e.getInputEvent());
ShowSettingsUtilImpl.showSettingsDialog(project, "vcs.Git", "force push");
}
});
here.setFont(JBUI.Fonts.smallFont());
text.add(here);
return JBUI.Panels.simplePanel().addToRight(text).withBorder(JBUI.Borders.emptyBottom(4));
}
示例3: GotoActionModel
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public GotoActionModel(@Nullable Project project, Component component, @Nullable Editor editor, @Nullable PsiFile file) {
myProject = project;
myContextComponent = component;
ActionGroup mainMenu = (ActionGroup)myActionManager.getActionOrStub(IdeActions.GROUP_MAIN_MENU);
collectActions(myActionGroups, mainMenu, mainMenu.getTemplatePresentation().getText());
if (project != null && editor != null && file != null) {
ApplyIntentionAction[] children = ApplyIntentionAction.getAvailableIntentions(editor, file);
if (children != null) {
for (ApplyIntentionAction action : children) {
myIntentions.put(action.getName(), action);
}
}
}
myIndex = SearchableOptionsRegistrar.getInstance();
if (!EventQueue.isDispatchThread()) {
return;
}
fillConfigurablesNames(ShowSettingsUtilImpl.getConfigurables(project, true));
}
示例4: promptToConfigureDocumentation
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
@Override
public void promptToConfigureDocumentation(@NotNull PsiElement element) {
final Project project = element.getProject();
final QualifiedName qName = QualifiedNameFinder.findCanonicalImportPath(element, element);
if (qName != null && qName.getComponentCount() > 0) {
ApplicationManager.getApplication().invokeLater(new Runnable() {
@Override
public void run() {
final int rc = Messages.showOkCancelDialog(project,
"No external documentation URL configured for module " + qName.getComponents().get(0) +
".\nWould you like to configure it now?",
"Python External Documentation",
Messages.getQuestionIcon());
if (rc == Messages.OK) {
ShowSettingsUtilImpl.showSettingsDialog(project, PythonDocumentationConfigurable.ID, "");
}
}
}, ModalityState.NON_MODAL);
}
}
示例5: MyPanel
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
MyPanel() {
setText("You can format your XML resources in the 'standard' Android way. " +
"Choose 'Set from... | Android' in the XML code style settings.");
createActionLabel("Open code style settings", new Runnable() {
@Override
public void run() {
ShowSettingsUtilImpl.showSettingsDialog(
myProject, "preferences.sourceCode." + XmlCodeStyleSettingsProvider.CONFIGURABLE_DISPLAY_NAME, "");
myNotifications.updateAllNotifications();
}
});
createActionLabel("Disable notification", new Runnable() {
@Override
public void run() {
NotificationsConfiguration.getNotificationsConfiguration()
.changeSettings(ANDROID_XML_CODE_STYLE_NOTIFICATION_GROUP, NotificationDisplayType.NONE, false, false);
myNotifications.updateAllNotifications();
}
});
}
示例6: createAccount
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
private void createAccount(ServerType<?> cloudType) {
RemoteServer<?> newAccount = RemoteServersManager.getInstance().createServer(cloudType, generateServerName(cloudType));
final Ref<Consumer<String>> errorConsumerRef = new Ref<Consumer<String>>();
SingleRemoteServerConfigurable configurable = new SingleRemoteServerConfigurable(newAccount, null, true) {
@Override
protected void setConnectionStatusText(boolean error, String text) {
super.setConnectionStatusText(error, error ? "" : text);
errorConsumerRef.get().consume(error ? text : null);
}
};
if (!new SingleConfigurableEditor(myMainPanel, configurable, ShowSettingsUtilImpl.createDimensionKey(configurable), false) {
{
errorConsumerRef.set(new Consumer<String>() {
@Override
public void consume(String s) {
setErrorText(s);
}
});
}
}.showAndGet()) {
return;
}
newAccount.setName(configurable.getDisplayName());
RemoteServersManager.getInstance().addServer(newAccount);
AccountItem newAccountItem = new AccountItem(newAccount);
myAccountComboBox.addItem(newAccountItem);
myAccountComboBox.setSelectedItem(newAccountItem);
}
示例7: getConfigureAction
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
@NotNull
protected Runnable getConfigureAction() {
return () -> {
ShowSettingsUtilImpl.showSettingsDialog(myProject, NodeSettingsConfigurable.ID, "Node interpreter");
myNotifications.updateAllNotifications();
};
}
开发者ID:jimkyndemeyer,项目名称:js-graphql-intellij-plugin,代码行数:8,代码来源:JSGraphQLNodeInterpreterEditorNotificationProvider.java
示例8: AvailablePluginsDialog
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public AvailablePluginsDialog(Component parent, SearchableConfigurable configurable, FilterComponent myFilter) {
super(parent, configurable, ShowSettingsUtilImpl.createDimensionKey(configurable), false);
setOKButtonText(CommonBundle.message("close.action.name"));
setOKButtonMnemonic('C');
final String filter = myFilter.getFilter();
if (!StringUtil.isEmptyOrSpaces(filter)) {
final Runnable searchRunnable = configurable.enableSearch(filter);
LOGGER.assertTrue(searchRunnable != null);
searchRunnable.run();
}
}
示例9: show
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public static void show(@NotNull Project project) {
ShowSettingsUtilImpl.showSettingsDialog(project, "Neos.SettingsForm", null);
}
示例10: showSettings
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public void showSettings() {
String dimensionKey = ShowSettingsUtilImpl.createDimensionKey(this);
SingleConfigurableEditor singleConfigurableEditor = new SingleConfigurableEditor(project, this, dimensionKey, false);
singleConfigurableEditor.show();
}
示例11: showSettings
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public static void showSettings(Project project) {
SassLintSettingsPage configurable = new SassLintSettingsPage(project);
String dimensionKey = ShowSettingsUtilImpl.createDimensionKey(configurable);
SingleConfigurableEditor singleConfigurableEditor = new SingleConfigurableEditor(project, configurable, dimensionKey, false);
singleConfigurableEditor.show();
}
示例12: SingleConfigurableEditor
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public SingleConfigurableEditor(@Nullable Project project, Configurable configurable, @NotNull IdeModalityType ideModalityType) {
this(project, configurable, ShowSettingsUtilImpl.createDimensionKey(configurable), ideModalityType);
}
示例13: processProjectConfigurables
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public static void processProjectConfigurables(Project project, HashMap<SearchableConfigurable, TreeSet<OptionDescription>> options) {
processConfigurables(ShowSettingsUtilImpl.getConfigurables(project, false), options);
}
示例14: getNotificationInfo
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
@Nullable
@Override
public EditorNotificationInfo getNotificationInfo(@NotNull final Project project,
@NotNull final VirtualFile file,
@NotNull final FileEditor fileEditor,
@NotNull CommonCodeStyleSettings.IndentOptions userOptions,
@NotNull CommonCodeStyleSettings.IndentOptions detectedOptions)
{
final NotificationLabels labels = getNotificationLabels(userOptions, detectedOptions);
final Editor editor = fileEditor instanceof TextEditor ? ((TextEditor)fileEditor).getEditor() : null;
if (labels == null || editor == null) return null;
ActionLabelData okAction = new ActionLabelData(
ApplicationBundle.message("code.style.indents.detector.accept"),
new Runnable() {
@Override
public void run() {
setAccepted(file);
}
}
);
ActionLabelData disableForSingleFile = new ActionLabelData(
labels.revertToOldSettingsLabel,
new Runnable() {
@Override
public void run() {
disableForFile(file);
if (editor instanceof EditorEx) {
((EditorEx)editor).reinitSettings();
}
}
}
);
ActionLabelData showSettings = new ActionLabelData(
ApplicationBundle.message("code.style.indents.detector.show.settings"),
new Runnable() {
@Override
public void run() {
ShowSettingsUtilImpl.showSettingsDialog(project, "preferences.sourceCode", "detect indent");
}
}
);
final List<ActionLabelData> actions = ContainerUtil.newArrayList(okAction, disableForSingleFile, showSettings);
return new EditorNotificationInfo() {
@NotNull
@Override
public List<ActionLabelData> getLabelAndActions() {
return actions;
}
@NotNull
@Override
public String getTitle() {
return labels.title;
}
};
}
示例15: showSettings
import com.intellij.ide.actions.ShowSettingsUtilImpl; //导入依赖的package包/类
public static void showSettings(Project project) {
RTSettingsPage configurable = new RTSettingsPage(project);
String dimensionKey = ShowSettingsUtilImpl.createDimensionKey(configurable);
SingleConfigurableEditor singleConfigurableEditor = new SingleConfigurableEditor(project, configurable, dimensionKey, false);
singleConfigurableEditor.show();
}