public class UnifiedDiffViewer extends ListenerDiffViewerBase
Disposable.Parent
Modifier and Type | Field and Description |
---|---|
protected Document |
myDocument |
protected EditorEx |
myEditor |
protected Side |
myMasterSide |
protected TwosideTextDiffProvider.NoIgnore |
myTextDiffProvider |
LOG, myContext, myProject, myRequest
Constructor and Description |
---|
UnifiedDiffViewer(DiffContext context,
DiffRequest request) |
Modifier and Type | Method and Description |
---|---|
void |
appendChange(UnifiedDiffChange change,
Side sourceSide) |
protected java.lang.Runnable |
apply(UnifiedFragmentBuilder builder,
java.lang.CharSequence [] texts,
ProgressIndicator indicator) |
protected java.lang.Runnable |
applyErrorNotification() |
static boolean |
canShowRequest(DiffContext context,
DiffRequest request) |
protected java.lang.Runnable |
computeDifferences(ProgressIndicator indicator) |
protected java.util.List<AnAction> |
createEditorPopupActions() |
java.util.List<AnAction> |
createPopupActions() |
protected javax.swing.JComponent |
createTitles() |
java.util.List<AnAction> |
createToolbarActions() |
protected UnifiedDiffChangeUi |
createUi(UnifiedDiffChange change) |
javax.swing.JComponent |
getComponent() |
protected DocumentContent |
getContent(Side side) |
protected DocumentContent |
getContent1() |
protected DocumentContent |
getContent2() |
protected java.util.List<? extends DocumentContent> |
getContents() |
protected UnifiedDiffChange |
getCurrentChange() |
java.lang.Object |
getData(java.lang.String dataId)
Returns the object corresponding to the specified data identifier.
|
protected java.util.List<UnifiedDiffChange> |
getDiffChanges() |
Document |
getDocument(Side side) |
EditorEx |
getEditor() |
protected java.util.List<? extends EditorEx> |
getEditors() |
FoldingModelSupport.Settings |
getFoldingModelSettings() |
Side |
getMasterSide() |
protected Navigatable |
getNavigatable() |
protected Navigatable |
getNavigatable(LineCol position) |
javax.swing.JComponent |
getPreferredFocusedComponent() |
protected java.util.List<UnifiedDiffChange> |
getSelectedChanges() |
protected StatusPanel |
getStatusPanel() |
TextDiffSettings |
getTextSettings() |
protected void |
installEditorListeners() |
boolean |
isContentGood() |
boolean |
isEditable(Side side,
boolean respectReadOnlyLock) |
protected boolean |
isStateIsOutOfDate() |
protected void |
markStateIsOutOfDate() |
protected void |
markSuppressEditorTyping() |
protected void |
onBeforeDocumentChange(DocumentEvent event) |
protected void |
onBeforeRediff() |
protected void |
onDispose() |
protected void |
onDocumentChange(DocumentEvent e) |
protected void |
onInit() |
protected void |
onSlowRediff() |
protected java.lang.Runnable |
performRediff(ProgressIndicator indicator) |
protected void |
processContextHints() |
void |
replaceChange(UnifiedDiffChange change,
Side sourceSide) |
Pair<int[],Side> |
transferLineFromOneside(int line) |
int |
transferLineFromOneside(Side side,
int line) |
int |
transferLineFromOnesideStrict(Side side,
int line) |
int |
transferLineToOneside(Side side,
int line) |
int |
transferLineToOnesideStrict(Side side,
int line) |
protected void |
updateContextHints() |
protected void |
updateEditorCanBeTyped() |
createDocumentListener, createFileListener, onFileChange, onFileChange
abortRediff, addListener, dispose, forceRediffSynchronously, getContext, getListeners, getProject, getRequest, init, isDisposed, onAfterRediff, rediff, rediff, removeListener, scheduleRediff, tryRediffSynchronously
protected final EditorEx myEditor
protected final Document myDocument
protected final TwosideTextDiffProvider.NoIgnore myTextDiffProvider
protected Side myMasterSide
public UnifiedDiffViewer(DiffContext context, DiffRequest request)
protected void onInit()
onInit
in class ListenerDiffViewerBase
protected void onDispose()
onDispose
in class DiffViewerBase
protected void processContextHints()
processContextHints
in class DiffViewerBase
protected void updateContextHints()
updateContextHints
in class DiffViewerBase
protected javax.swing.JComponent createTitles()
protected void updateEditorCanBeTyped()
public java.util.List<AnAction> createToolbarActions()
createToolbarActions
in class DiffViewerBase
public java.util.List<AnAction> createPopupActions()
createPopupActions
in class DiffViewerBase
protected java.util.List<AnAction> createEditorPopupActions()
protected void installEditorListeners()
protected UnifiedDiffChangeUi createUi(UnifiedDiffChange change)
protected void onBeforeDocumentChange(DocumentEvent event)
onBeforeDocumentChange
in class ListenerDiffViewerBase
protected void onBeforeRediff()
onBeforeRediff
in class DiffViewerBase
protected void onSlowRediff()
onSlowRediff
in class DiffViewerBase
protected java.lang.Runnable performRediff(ProgressIndicator indicator)
performRediff
in class DiffViewerBase
protected java.lang.Runnable applyErrorNotification()
protected java.lang.Runnable computeDifferences(ProgressIndicator indicator)
protected void markSuppressEditorTyping()
protected void markStateIsOutOfDate()
protected java.lang.Runnable apply(UnifiedFragmentBuilder builder, java.lang.CharSequence [] texts, ProgressIndicator indicator)
public int transferLineToOnesideStrict(Side side, int line)
public int transferLineFromOnesideStrict(Side side, int line)
public int transferLineToOneside(Side side, int line)
public int transferLineFromOneside(Side side, int line)
protected void onDocumentChange(DocumentEvent e)
onDocumentChange
in class ListenerDiffViewerBase
public void replaceChange(UnifiedDiffChange change, Side sourceSide)
public void appendChange(UnifiedDiffChange change, Side sourceSide)
protected java.util.List<UnifiedDiffChange> getSelectedChanges()
public TextDiffSettings getTextSettings()
public FoldingModelSupport.Settings getFoldingModelSettings()
public Side getMasterSide()
public EditorEx getEditor()
protected java.util.List<? extends EditorEx> getEditors()
protected java.util.List<? extends DocumentContent> getContents()
protected DocumentContent getContent(Side side)
protected DocumentContent getContent1()
protected DocumentContent getContent2()
protected java.util.List<UnifiedDiffChange> getDiffChanges()
public javax.swing.JComponent getComponent()
public javax.swing.JComponent getPreferredFocusedComponent()
protected StatusPanel getStatusPanel()
getStatusPanel
in class DiffViewerBase
public boolean isEditable(Side side, boolean respectReadOnlyLock)
protected boolean isStateIsOutOfDate()
protected Navigatable getNavigatable()
getNavigatable
in class DiffViewerBase
protected UnifiedDiffChange getCurrentChange()
protected Navigatable getNavigatable(LineCol position)
public boolean isContentGood()
public static boolean canShowRequest(DiffContext context, DiffRequest request)
public java.lang.Object getData(java.lang.String dataId)
DataProvider
PlatformDataKeys
class.getData
in interface DataProvider
getData
in class DiffViewerBase
dataId
- the data identifier for which the value is requested.