use of org.zmlx.hg4idea.ui.HgMqUnAppliedPatchesPanel in project intellij-community by JetBrains.
the class HgActionFromMqPatches method actionPerformed.
@Override
public void actionPerformed(AnActionEvent e) {
final HgMqUnAppliedPatchesPanel patchInfo = e.getRequiredData(HgMqUnAppliedPatchesPanel.MQ_PATCHES);
final List<String> names = patchInfo.getSelectedPatchNames();
final HgRepository repository = patchInfo.getRepository();
Runnable task = new Runnable() {
@Override
public void run() {
ProgressManager.getInstance().getProgressIndicator().setText(getTitle());
executeInCurrentThread(repository, names);
}
};
patchInfo.updatePatchSeriesInBackground(task);
}
use of org.zmlx.hg4idea.ui.HgMqUnAppliedPatchesPanel in project intellij-community by JetBrains.
the class HgActionFromMqPatches method update.
@Override
public void update(AnActionEvent e) {
HgMqUnAppliedPatchesPanel patchInfo = e.getData(HgMqUnAppliedPatchesPanel.MQ_PATCHES);
e.getPresentation().setEnabled(patchInfo != null && patchInfo.getSelectedRowsCount() != 0 && isEnabled(patchInfo.getRepository()));
}
use of org.zmlx.hg4idea.ui.HgMqUnAppliedPatchesPanel in project intellij-community by JetBrains.
the class HgSingleActionFomMqPatches method update.
@Override
public void update(AnActionEvent e) {
HgMqUnAppliedPatchesPanel patchInfo = e.getData(HgMqUnAppliedPatchesPanel.MQ_PATCHES);
e.getPresentation().setEnabled(patchInfo != null && patchInfo.getSelectedRowsCount() == 1);
}
use of org.zmlx.hg4idea.ui.HgMqUnAppliedPatchesPanel in project intellij-community by JetBrains.
the class HgShowUnAppliedPatchesAction method showUnAppliedPatches.
public static void showUnAppliedPatches(@NotNull Project project, @NotNull HgRepository selectedRepo) {
ToolWindow toolWindow = ObjectUtils.assertNotNull(ToolWindowManager.getInstance(project).getToolWindow(ToolWindowId.VCS));
ContentUtilEx.addTabbedContent(toolWindow.getContentManager(), new HgMqUnAppliedPatchesPanel(selectedRepo), "MQ", selectedRepo.getRoot().getName(), true);
toolWindow.activate(null);
}
Aggregations