mirror of
https://github.com/Murmele/Gittyup.git
synced 2024-09-11 10:45:39 +03:00
Also show full file conflict solving buttons when there's no hunks (happens with binary files)
This commit is contained in:
parent
722f1b0506
commit
9119d41c25
@ -200,10 +200,10 @@ void _FileWidget::Header::updatePatch(const git::Patch &patch) {
|
||||
mEdit->updatePatch(patch, -1);
|
||||
|
||||
auto isConflicted = patch.isConflicted();
|
||||
auto hasMultipleHunks = patch.count() > 1;
|
||||
auto hasOneHunk = patch.count() == 1;
|
||||
|
||||
mOurs->setVisible(isConflicted && hasMultipleHunks);
|
||||
mTheirs->setVisible(isConflicted && hasMultipleHunks);
|
||||
mOurs->setVisible(isConflicted && !hasOneHunk);
|
||||
mTheirs->setVisible(isConflicted && !hasOneHunk);
|
||||
|
||||
mSave->setVisible(mResolution != git::Patch::ConflictResolution::Unresolved);
|
||||
mUndo->setVisible(mResolution != git::Patch::ConflictResolution::Unresolved);
|
||||
|
Loading…
Reference in New Issue
Block a user