Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Start file conflict resolve dialog asynchronous #2867

Merged
merged 1 commit into from
Jan 27, 2021

Conversation

FlexW
Copy link

@FlexW FlexW commented Jan 26, 2021

Fixes #2804

Signed-off-by: Felix Weilbach [email protected]

@FlexW FlexW requested review from allexzander and er-vin January 26, 2021 10:44
folder->scheduleThisFolderSoon();
}
});
dialog->open();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be on the safe side I'd also force raising it and getting the focus. Since this dialog can't have a parent there's a slight chance it might "pop under" something else. You can use ownCloudGui::raiseDialog() for that.

@FlexW FlexW force-pushed the fix_file_resolve_dialog branch from 8835fb7 to 48af65e Compare January 26, 2021 11:55
_currentConflictDialog->setLocalVersionFilename(conflictedPath);
_currentConflictDialog->setRemoteVersionFilename(basePath);
_currentConflictDialog->setAttribute(Qt::WA_DeleteOnClose);
connect(_currentConflictDialog, &ConflictDialog::accepted, [folder]() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For extra safety, folder should be passed as third parameter of that connect just before the lambda. In case the folder object would be deleted before accepted is emitted it would thus disconnect automatically, otherwise it won't and you risk calling into a deleted object from the lambda.

@FlexW FlexW force-pushed the fix_file_resolve_dialog branch from 48af65e to 9f3da97 Compare January 26, 2021 12:38
@er-vin
Copy link
Member

er-vin commented Jan 26, 2021

/rebase

@github-actions github-actions bot force-pushed the fix_file_resolve_dialog branch from 9f3da97 to 5d3d7a6 Compare January 26, 2021 13:01
@er-vin
Copy link
Member

er-vin commented Jan 27, 2021

/rebase

@github-actions github-actions bot force-pushed the fix_file_resolve_dialog branch from 5d3d7a6 to 51d8cf8 Compare January 27, 2021 08:01
@nextcloud-desktop-bot
Copy link

AppImage file: Nextcloud-PR-2867-51d8cf8102adabf17b946c9991ef34c62be32153-x86_64.AppImage

To test this change/fix you can simply download above AppImage file and test it.

Please make sure to quit your existing Nextcloud app and backup your data.

@er-vin er-vin merged commit c7d9e11 into master Jan 27, 2021
@er-vin er-vin deleted the fix_file_resolve_dialog branch January 27, 2021 08:10
@er-vin
Copy link
Member

er-vin commented Jan 27, 2021

/backport to stable-3.1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Nextcloud version 3.1.1git crashes when solving conflicts files with style Fusion or Chameleon on ArchLinux
3 participants