Example #1
0
 public void setActiveEditor(ITextEditor editor) {
   if (GitTraceLocation.QUICKDIFF.isActive())
     GitTraceLocation.getTrace()
         .traceEntry(GitTraceLocation.QUICKDIFF.getLocation(), editor.getTitle());
   IEditorInput editorInput = editor.getEditorInput();
   resource = ResourceUtil.getResource(editorInput);
 }
Example #2
0
  public IDocument getReference(IProgressMonitor monitor) throws CoreException {
    if (GitTraceLocation.QUICKDIFF.isActive())
      GitTraceLocation.getTrace()
          .trace(
              GitTraceLocation.QUICKDIFF.getLocation(),
              "(GitQuickDiffProvider) file: " + resource); // $NON-NLS-1$
    if (resource == null) return null;

    // Document must only be created once
    if (document == null) document = createDocument(resource);
    return document;
  }
Example #3
0
 public void dispose() {
   if (GitTraceLocation.QUICKDIFF.isActive())
     GitTraceLocation.getTrace().traceEntry(GitTraceLocation.QUICKDIFF.getLocation());
   if (document != null) document.dispose();
 }
Example #4
0
 /** Create the GitQuickDiffProvider instance */
 public GitQuickDiffProvider() {
   if (GitTraceLocation.QUICKDIFF.isActive())
     GitTraceLocation.getTrace().traceEntry(GitTraceLocation.QUICKDIFF.getLocation());
 }