当前位置: 首页>>代码示例>>Java>>正文


Java DialogBuilder.showNotModal方法代码示例

本文整理汇总了Java中com.intellij.openapi.ui.DialogBuilder.showNotModal方法的典型用法代码示例。如果您正苦于以下问题:Java DialogBuilder.showNotModal方法的具体用法?Java DialogBuilder.showNotModal怎么用?Java DialogBuilder.showNotModal使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.intellij.openapi.ui.DialogBuilder的用法示例。


在下文中一共展示了DialogBuilder.showNotModal方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: showDirDiffDialog

import com.intellij.openapi.ui.DialogBuilder; //导入方法依赖的package包/类
private void showDirDiffDialog(@NotNull FilePath path, @Nullable String hash1, @Nullable String hash2, @NotNull List<Change> diff) {
  DialogBuilder dialogBuilder = new DialogBuilder(myProject);
  String title;
  if (hash2 != null) {
    if (hash1 != null) {
      title = String.format("Difference between %s and %s in %s", GitUtil.getShortHash(hash1), GitUtil.getShortHash(hash2), path.getName());
    }
    else {
      title = String.format("Initial commit %s in %s", GitUtil.getShortHash(hash2), path.getName());
    }
  }
  else {
    LOG.assertTrue(hash1 != null, "hash1 and hash2 can't both be null. Path: " + path);
    title = String.format("Difference between %s and local version in %s", GitUtil.getShortHash(hash1), path.getName());
  }
  dialogBuilder.setTitle(title);
  dialogBuilder.setActionDescriptors(new DialogBuilder.ActionDescriptor[] { new DialogBuilder.CloseDialogAction()});
  final ChangesBrowser changesBrowser = new ChangesBrowser(myProject, null, diff, null, false, true,
                                                           null, ChangesBrowser.MyUseCase.COMMITTED_CHANGES, null);
  changesBrowser.setChangesToDisplay(diff);
  dialogBuilder.setCenterPanel(changesBrowser);
  dialogBuilder.showNotModal();
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:24,代码来源:GitDiffFromHistoryHandler.java

示例2: showDirDiffDialog

import com.intellij.openapi.ui.DialogBuilder; //导入方法依赖的package包/类
private void showDirDiffDialog(@NotNull FilePath path, @Nullable String hash1, @Nullable String hash2, @NotNull List<Change> diff) {
  DialogBuilder dialogBuilder = new DialogBuilder(myProject);
  String title;
  if (hash2 != null) {
    if (hash1 != null) {
      title = String.format("Difference between %s and %s in %s", hash1, hash2, path.getName());
    }
    else {
      title = String.format("Initial commit %s in %s", hash2, path.getName());
    }
  }
  else {
    LOG.assertTrue(hash1 != null, "hash1 and hash2 can't both be null. Path: " + path);
    title = String.format("Difference between %s and local version in %s", hash1, path.getName());
  }
  dialogBuilder.setTitle(title);
  dialogBuilder.setActionDescriptors(new DialogBuilder.ActionDescriptor[]{new DialogBuilder.CloseDialogAction()});
  final ChangesBrowser changesBrowser = new ChangesBrowser(myProject, null, diff, null, false, true,
                                                           null, ChangesBrowser.MyUseCase.COMMITTED_CHANGES, null);
  changesBrowser.setChangesToDisplay(diff);
  dialogBuilder.setCenterPanel(changesBrowser);
  dialogBuilder.showNotModal();
}
 
开发者ID:lshain-android-source,项目名称:tools-idea,代码行数:24,代码来源:HgDiffFromHistoryHandler.java

示例3: showChangesDialog

import com.intellij.openapi.ui.DialogBuilder; //导入方法依赖的package包/类
protected void showChangesDialog(@NotNull String title, @NotNull List<Change> changes) {
  DialogBuilder dialogBuilder = new DialogBuilder(myProject);

  dialogBuilder.setTitle(title);
  dialogBuilder.setActionDescriptors(new DialogBuilder.ActionDescriptor[]{new DialogBuilder.CloseDialogAction()});
  final ChangesBrowser changesBrowser =
    new ChangesBrowser(myProject, null, changes, null, false, true, null, ChangesBrowser.MyUseCase.COMMITTED_CHANGES, null);
  changesBrowser.setChangesToDisplay(changes);
  dialogBuilder.setCenterPanel(changesBrowser);
  dialogBuilder.setPreferredFocusComponent(changesBrowser.getPreferredFocusedComponent());
  dialogBuilder.showNotModal();
}
 
开发者ID:jskierbi,项目名称:intellij-ce-playground,代码行数:13,代码来源:BaseDiffFromHistoryHandler.java

示例4: showChangesDialog

import com.intellij.openapi.ui.DialogBuilder; //导入方法依赖的package包/类
protected void showChangesDialog(@Nonnull String title, @Nonnull List<Change> changes) {
  DialogBuilder dialogBuilder = new DialogBuilder(myProject);

  dialogBuilder.setTitle(title);
  dialogBuilder.setActionDescriptors(new DialogBuilder.ActionDescriptor[]{new DialogBuilder.CloseDialogAction()});
  final ChangesBrowser changesBrowser =
          new ChangesBrowser(myProject, null, changes, null, false, true, null, ChangesBrowser.MyUseCase.COMMITTED_CHANGES, null);
  changesBrowser.setChangesToDisplay(changes);
  dialogBuilder.setCenterPanel(changesBrowser);
  dialogBuilder.setPreferredFocusComponent(changesBrowser.getPreferredFocusedComponent());
  dialogBuilder.showNotModal();
}
 
开发者ID:consulo,项目名称:consulo,代码行数:13,代码来源:BaseDiffFromHistoryHandler.java

示例5: showChangesDialog

import com.intellij.openapi.ui.DialogBuilder; //导入方法依赖的package包/类
@RequiredDispatchThread
public static void showChangesDialog(@Nonnull Project project, @Nonnull String title, @Nonnull List<Change> changes) {
  DialogBuilder dialogBuilder = new DialogBuilder(project);

  dialogBuilder.setTitle(title);
  dialogBuilder.setActionDescriptors(new DialogBuilder.CloseDialogAction());
  final ChangesBrowser changesBrowser =
          new ChangesBrowser(project, null, changes, null, false, true, null, ChangesBrowser.MyUseCase.COMMITTED_CHANGES, null);
  changesBrowser.setChangesToDisplay(changes);
  dialogBuilder.setCenterPanel(changesBrowser);
  dialogBuilder.setPreferredFocusComponent(changesBrowser.getPreferredFocusedComponent());
  dialogBuilder.showNotModal();
}
 
开发者ID:consulo,项目名称:consulo,代码行数:14,代码来源:VcsDiffUtil.java


注:本文中的com.intellij.openapi.ui.DialogBuilder.showNotModal方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。