Example usage for com.intellij.openapi.diff DiffContent isBinary

List of usage examples for com.intellij.openapi.diff DiffContent isBinary

Introduction

In this page you can find the example usage for com.intellij.openapi.diff DiffContent isBinary.

Prototype

public boolean isBinary() 

Source Link

Document

Means this content represents binary data.

Usage

From source file:com.urswolfer.intellij.plugin.gerrit.ui.diff.CustomizableFrameDiffTool.java

License:Apache License

public static boolean canShowDiff(DiffRequest data) {
    DiffContent[] contents = data.getContents();
    if (contents.length != 2)
        return false;
    for (DiffContent content : contents) {
        if (content.isBinary())
            return false;
        VirtualFile file = content.getFile();
        if (file != null && file.isDirectory())
            return false;
    }//  w w  w. ja  v a2  s. co m
    return true;
}