diff: LST - cleanup

This commit is contained in:
Aleksey Pivovarov
2014-09-24 15:37:22 +04:00
parent 192bf3cf7b
commit d446a1596e
@@ -141,6 +141,19 @@ public class LineStatusTracker {
}
}
private void installAnathema() {
myAnathemaThrown = true;
final FileEditor[] editors = myFileEditorManager.getAllEditors(myVirtualFile);
for (FileEditor editor : editors) {
CanNotCalculateDiffPanel panel = editor.getUserData(PANEL_KEY);
if (panel == null) {
final CanNotCalculateDiffPanel newPanel = new CanNotCalculateDiffPanel();
editor.putUserData(PANEL_KEY, newPanel);
myFileEditorManager.addTopComponent(editor, newPanel);
}
}
}
private void removeAnathema() {
if (!myAnathemaThrown) return;
myAnathemaThrown = false;
@@ -206,6 +219,11 @@ public class LineStatusTracker {
}
}
@NotNull
Project getProject() {
return myProject;
}
@NotNull
public Document getDocument() {
return myDocument;
@@ -885,11 +903,6 @@ public class LineStatusTracker {
}
}
@NotNull
Project getProject() {
return myProject;
}
public enum BaseLoadState {
LOADING,
FAILED,
@@ -934,19 +947,6 @@ public class LineStatusTracker {
}
}
private void installAnathema() {
myAnathemaThrown = true;
final FileEditor[] editors = myFileEditorManager.getAllEditors(myVirtualFile);
for (FileEditor editor : editors) {
CanNotCalculateDiffPanel panel = editor.getUserData(PANEL_KEY);
if (panel == null) {
final CanNotCalculateDiffPanel newPanel = new CanNotCalculateDiffPanel();
editor.putUserData(PANEL_KEY, newPanel);
myFileEditorManager.addTopComponent(editor, newPanel);
}
}
}
public static class CanNotCalculateDiffPanel extends EditorNotificationPanel {
public CanNotCalculateDiffPanel() {
myLabel.setText("Can not highlight changed lines. File is too big and there are too many changes.");