forked from qt-creator/qt-creator
Utils: Unify CheckableMessageBox and make it look more native
Change-Id: I5690c16f38cfd2058e01441283bec28d44cadf75 Reviewed-by: Eike Ziller <eike.ziller@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
@@ -1293,14 +1293,16 @@ QStringList GitClient::setupCheckoutArguments(const FilePath &workingDirectory,
|
||||
if (localBranches.contains(ref))
|
||||
return arguments;
|
||||
|
||||
if (Utils::CheckableMessageBox::doNotAskAgainQuestion(
|
||||
ICore::dialogParent() /*parent*/,
|
||||
Tr::tr("Create Local Branch") /*title*/,
|
||||
Tr::tr("Would you like to create a local branch?") /*message*/,
|
||||
ICore::settings(), "Git.CreateLocalBranchOnCheckout" /*setting*/,
|
||||
QDialogButtonBox::Yes | QDialogButtonBox::No /*buttons*/,
|
||||
QDialogButtonBox::No /*default button*/,
|
||||
QDialogButtonBox::No /*button to save*/) != QDialogButtonBox::Yes) {
|
||||
if (Utils::CheckableMessageBox::question(
|
||||
ICore::dialogParent() /*parent*/,
|
||||
Tr::tr("Create Local Branch") /*title*/,
|
||||
Tr::tr("Would you like to create a local branch?") /*message*/,
|
||||
ICore::settings(),
|
||||
"Git.CreateLocalBranchOnCheckout" /*setting*/,
|
||||
QMessageBox::Yes | QMessageBox::No /*buttons*/,
|
||||
QMessageBox::No /*default button*/,
|
||||
QMessageBox::No /*button to save*/)
|
||||
!= QMessageBox::Yes) {
|
||||
return arguments;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user