Search in sources :

Example 1 with ThreesideMergeRequest

use of com.intellij.diff.merge.ThreesideMergeRequest in project intellij-community by JetBrains.

the class ExternalMergeTool method canShow.

public static boolean canShow(@NotNull MergeRequest request) {
    if (request instanceof ThreesideMergeRequest) {
        DiffContent outputContent = ((ThreesideMergeRequest) request).getOutputContent();
        if (!canProcessOutputContent(outputContent))
            return false;
        List<? extends DiffContent> contents = ((ThreesideMergeRequest) request).getContents();
        if (contents.size() != 3)
            return false;
        for (DiffContent content : contents) {
            if (!ExternalDiffToolUtil.canCreateFile(content))
                return false;
        }
        return true;
    }
    return false;
}
Also used : ThreesideMergeRequest(com.intellij.diff.merge.ThreesideMergeRequest) DiffContent(com.intellij.diff.contents.DiffContent)

Aggregations

DiffContent (com.intellij.diff.contents.DiffContent)1 ThreesideMergeRequest (com.intellij.diff.merge.ThreesideMergeRequest)1