Git: Show full description on tooltip in commit chooser dialogs

Like Push to Gerrit, Rebase, Reset, Fixup Commit.

Fixes: QTCREATORBUG-24366
Change-Id: I0f596f84661a1a4f37fe971683cc0d985a6c9b1f
Reviewed-by: André Hartmann <aha_1980@gmx.de>
This commit is contained in:
Orgad Shaneh
2020-07-31 07:55:08 +03:00
committed by Orgad Shaneh
parent 78406916a3
commit a48cde86f3
5 changed files with 45 additions and 19 deletions

View File

@@ -315,13 +315,9 @@ IEditor *GitGrep::openEditor(const SearchResultItem &item,
if (params.ref.isEmpty() || item.path.isEmpty())
return nullptr;
const QString path = QDir::fromNativeSeparators(item.path.first());
QByteArray content;
const QString topLevel = parameters.additionalParameters.toString();
const QString relativePath = QDir(topLevel).relativeFilePath(path);
if (!m_client->synchronousShow(topLevel, params.ref + ":./" + relativePath,
&content, nullptr)) {
return nullptr;
}
const QByteArray content = m_client->synchronousShow(topLevel, params.ref + ":./" + relativePath);
if (content.isEmpty())
return nullptr;
QByteArray fileContent;