mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Merge remote-tracking branch 'origin/master'
This commit is contained in:
@@ -90,7 +90,7 @@ public class CopyHandler extends EditorActionHandler {
|
||||
|
||||
List<TextBlockTransferableData> transferableDatas = new ArrayList<TextBlockTransferableData>();
|
||||
CopyPastePostProcessor<? extends TextBlockTransferableData>[] postProcessors = Extensions.getExtensions(CopyPastePostProcessor.EP_NAME);
|
||||
for (CopyPastePostProcessor<? extends TextBlockTransferableData> processor : DumbService.getInstance(project).filterByDumbAwareness( Arrays.asList(postProcessors))) {
|
||||
for (CopyPastePostProcessor<? extends TextBlockTransferableData> processor : DumbService.getInstance(project).filterByDumbAwareness(Arrays.asList(postProcessors))) {
|
||||
transferableDatas.addAll(processor.collectTransferableData(file, editor, startOffsets, endOffsets));
|
||||
}
|
||||
|
||||
|
||||
+5
@@ -19,6 +19,7 @@ package com.intellij.codeInsight.editorActions;
|
||||
import com.intellij.openapi.editor.Editor;
|
||||
import com.intellij.openapi.editor.RangeMarker;
|
||||
import com.intellij.openapi.extensions.ExtensionPointName;
|
||||
import com.intellij.openapi.project.DumbAware;
|
||||
import com.intellij.openapi.project.Project;
|
||||
import com.intellij.openapi.util.Ref;
|
||||
import com.intellij.psi.PsiFile;
|
||||
@@ -29,6 +30,10 @@ import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* An extension to collect and apply additional transferable data when performing copy-paste in editors.<p/>
|
||||
*
|
||||
* Can be {@link DumbAware}
|
||||
*
|
||||
* @author yole
|
||||
*/
|
||||
public abstract class CopyPastePostProcessor<T extends TextBlockTransferableData> {
|
||||
|
||||
Reference in New Issue
Block a user