mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[file-history] highlight matches in hash and date
This commit is contained in:
@@ -960,8 +960,18 @@ public class FileHistoryPanelImpl extends PanelWithActionsAndCloseButton impleme
|
||||
|
||||
abstract static class VcsColumnInfo<T extends Comparable<T>> extends DualViewColumnInfo<VcsFileRevision, String>
|
||||
implements Comparator<VcsFileRevision> {
|
||||
@NotNull private final ColoredTableCellRenderer myRenderer;
|
||||
|
||||
public VcsColumnInfo(String name) {
|
||||
super(name);
|
||||
|
||||
myRenderer = new ColoredTableCellRenderer() {
|
||||
protected void customizeCellRenderer(JTable table, Object value, boolean selected, boolean hasFocus, int row, int column) {
|
||||
setOpaque(selected);
|
||||
append(value.toString());
|
||||
SpeedSearchUtil.applySpeedSearchHighlighting(table, this, false, selected);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
protected abstract T getDataOf(VcsFileRevision o);
|
||||
@@ -986,6 +996,12 @@ public class FileHistoryPanelImpl extends PanelWithActionsAndCloseButton impleme
|
||||
public boolean shouldBeShownIsTheTable() {
|
||||
return true;
|
||||
}
|
||||
|
||||
@Nullable
|
||||
@Override
|
||||
public TableCellRenderer getRenderer(VcsFileRevision revision) {
|
||||
return myRenderer;
|
||||
}
|
||||
}
|
||||
|
||||
private static class MyTreeCellRenderer implements TreeCellRenderer {
|
||||
|
||||
Reference in New Issue
Block a user