summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTor Lillqvist <tml@collabora.com>2016-06-27 10:28:55 +0300
committerCaolán McNamara <caolanm@redhat.com>2016-06-27 10:14:20 +0000
commitaaeeb0288dfeeeed9beb33efc0a693bc1a025986 (patch)
treef922003285ee9ec0221e14f72643594f8dac9e80
parenteb7364fffe39c1aecddcab6b9cf238475fa2013c (diff)
tdf#100222: Show the dialog just once even if both toggles were changed
Change-Id: If6058d68f80ebc3e235f0a681cfe3240985e2429 Reviewed-on: https://gerrit.libreoffice.org/26693 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--cui/source/options/optopencl.cxx10
1 files changed, 4 insertions, 6 deletions
diff --git a/cui/source/options/optopencl.cxx b/cui/source/options/optopencl.cxx
index 6f015236f5f7..52c8b089cbeb 100644
--- a/cui/source/options/optopencl.cxx
+++ b/cui/source/options/optopencl.cxx
@@ -155,9 +155,6 @@ bool SvxOpenCLTabPage::FillItemSet( SfxItemSet* )
{
officecfg::Office::Common::Misc::UseSwInterpreter::set(mpUseSwInterpreter->IsChecked(), batch);
bModified = true;
-
- ScopedVclPtrInstance<MessageDialog> aWarnBox(this, CUI_RES(RID_SVXSTR_OPTIONS_RESTART), VCL_MESSAGE_INFO);
- aWarnBox->Execute();
}
if (mpUseOpenCL->IsValueChangedFromSaved())
@@ -167,13 +164,14 @@ bool SvxOpenCLTabPage::FillItemSet( SfxItemSet* )
{
maConfig.set();
bModified = true;
-
- ScopedVclPtrInstance<MessageDialog> aWarnBox(this, CUI_RES(RID_SVXSTR_OPTIONS_RESTART), VCL_MESSAGE_INFO);
- aWarnBox->Execute();
}
if (bModified)
+ {
+ ScopedVclPtrInstance<MessageDialog> aWarnBox(this, CUI_RES(RID_SVXSTR_OPTIONS_RESTART), VCL_MESSAGE_INFO);
+ aWarnBox->Execute();
batch->commit();
+ }
return bModified;
}