本文整理匯總了Java中com.intellij.ui.content.Content.setActions方法的典型用法代碼示例。如果您正苦於以下問題:Java Content.setActions方法的具體用法?Java Content.setActions怎麽用?Java Content.setActions使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類com.intellij.ui.content.Content
的用法示例。
在下文中一共展示了Content.setActions方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。
示例1: createContent
import com.intellij.ui.content.Content; //導入方法依賴的package包/類
@Override
@NotNull
public Content createContent(@NotNull final String contentId, @NotNull final ComponentWithActions withActions, @NotNull final String displayName,
@Nullable final Icon icon,
@Nullable final JComponent toFocus) {
final Content content = getContentFactory().createContent(withActions.getComponent(), displayName, false);
content.putUserData(CONTENT_TYPE, contentId);
content.putUserData(ViewImpl.ID, contentId);
content.setIcon(icon);
if (toFocus != null) {
content.setPreferredFocusableComponent(toFocus);
}
if (!withActions.isContentBuiltIn()) {
content.setSearchComponent(withActions.getSearchComponent());
content.setActions(withActions.getToolbarActions(), withActions.getToolbarPlace(), withActions.getToolbarContextComponent());
}
return content;
}
示例2: addAdditionalConsoleEditorActions
import com.intellij.ui.content.Content; //導入方法依賴的package包/類
public static void addAdditionalConsoleEditorActions(final ConsoleView console, final Content consoleContent) {
final DefaultActionGroup consoleActions = new DefaultActionGroup();
for (AnAction action : console.createConsoleActions()) {
consoleActions.add(action);
}
consoleContent.setActions(consoleActions, ActionPlaces.RUNNER_TOOLBAR, console.getComponent());
}
示例3: createVariablesContent
import com.intellij.ui.content.Content; //導入方法依賴的package包/類
private Content createVariablesContent(@NotNull XDebugSessionImpl session) {
final XVariablesView variablesView = new XVariablesView(session);
myViews.add(variablesView);
Content result = myUi.createContent(DebuggerContentInfo.VARIABLES_CONTENT, variablesView.getPanel(),
XDebuggerBundle.message("debugger.session.tab.variables.title"),
AllIcons.Debugger.Value, null);
result.setCloseable(false);
ActionGroup group = getCustomizedActionGroup(XDebuggerActions.VARIABLES_TREE_TOOLBAR_GROUP);
result.setActions(group, ActionPlaces.DEBUGGER_TOOLBAR, variablesView.getTree());
return result;
}
示例4: addAdditionalConsoleEditorActions
import com.intellij.ui.content.Content; //導入方法依賴的package包/類
public static void addAdditionalConsoleEditorActions(final ExecutionConsole console, final Content consoleContent) {
final DefaultActionGroup consoleActions = new DefaultActionGroup();
if (console instanceof ConsoleView) {
for (AnAction action : ((ConsoleView)console).createConsoleActions()) {
consoleActions.add(action);
}
}
consoleContent.setActions(consoleActions, ActionPlaces.UNKNOWN, console.getComponent());
}