mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[vcs-log] better text for not found / not matched commit
This commit is contained in:
@@ -226,7 +226,7 @@ public class FileHistoryUi extends AbstractVcsLogUi {
|
||||
|
||||
String mainText = "Commit " + commitId.toString() + " does not exist in history for " + myPath.getName();
|
||||
if (getFilterUi().getFilters().get(VcsLogFilterCollection.BRANCH_FILTER) != null) {
|
||||
showWarningWithLink(mainText + " in current branch.", "Show all branches and search again.", () -> {
|
||||
showWarningWithLink(mainText + " in current branch", "View and Show All Branches", () -> {
|
||||
myUiProperties.set(FileHistoryUiProperties.SHOW_ALL_BRANCHES, true);
|
||||
invokeOnChange(() -> jumpTo(commitId, rowGetter, SettableFuture.create()));
|
||||
});
|
||||
@@ -234,7 +234,7 @@ public class FileHistoryUi extends AbstractVcsLogUi {
|
||||
else {
|
||||
VcsLogUiImpl mainLogUi = VcsProjectLog.getInstance(myProject).getMainLogUi();
|
||||
if (mainLogUi != null) {
|
||||
showWarningWithLink(mainText + ".", "Search in Log.", () -> {
|
||||
showWarningWithLink(mainText, "View in Log", () -> {
|
||||
if (VcsLogContentUtil.selectLogUi(myProject, mainLogUi)) {
|
||||
if (commitId instanceof Hash) {
|
||||
mainLogUi.jumpToCommit((Hash)commitId,
|
||||
|
||||
@@ -211,7 +211,7 @@ public abstract class AbstractVcsLogUi implements VcsLogUi, Disposable {
|
||||
|
||||
@NotNull
|
||||
protected static <T> String getCommitNotFoundMessage(@NotNull T commitId, boolean exists) {
|
||||
return exists ? "Commit " + commitId.toString() + " does not match active filters" : "Commit " + commitId.toString() + " not found";
|
||||
return exists ? "Commit " + commitId.toString() + " doesn't match the filters" : "Commit " + commitId.toString() + " not found";
|
||||
}
|
||||
|
||||
protected void showWarningWithLink(@NotNull String mainText, @NotNull String linkText, @NotNull Runnable onClick) {
|
||||
|
||||
@@ -108,7 +108,7 @@ public class VcsLogUiImpl extends AbstractVcsLogUi {
|
||||
}
|
||||
|
||||
List<NamedRunnable> runnables = ContainerUtil.newArrayList();
|
||||
runnables.add(new NamedRunnable("Reset filters and search again.") {
|
||||
runnables.add(new NamedRunnable("View and Reset Filters") {
|
||||
@Override
|
||||
public void run() {
|
||||
getFilterUi().setFilter(null);
|
||||
@@ -117,7 +117,7 @@ public class VcsLogUiImpl extends AbstractVcsLogUi {
|
||||
}
|
||||
});
|
||||
if (VcsLogProjectTabsProperties.MAIN_LOG_ID.equals(getId())) {
|
||||
runnables.add(new NamedRunnable("Search in new tab.") {
|
||||
runnables.add(new NamedRunnable("View in New Tab") {
|
||||
@Override
|
||||
public void run() {
|
||||
VcsProjectLog projectLog = VcsProjectLog.getInstance(myProject);
|
||||
|
||||
Reference in New Issue
Block a user