summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Weghorn <m.weghorn@posteo.de>2020-05-05 11:12:46 +0200
committerMichael Weghorn <m.weghorn@posteo.de>2020-05-05 16:21:31 +0200
commitadc783cccd06f26a6c997d3dcd894bb4dd93112e (patch)
tree33ec1f76ff8611a7555f4826a03863504334b386
parent00ba164a6ef36c0adb3ff73c6f1c6e0c4191c1cb (diff)
Prefill doc count in mail merge's "Send Email" dialog
Initialize the last document number with the doc count in the "Send Email Documents" mail merge dialog, just as is done for the "Print Merged Documents" and "Save Merged Documents" dialogs already. While at it, also set maximum value for the "from" spinbutton for the "Print Merged Documents" dialog. Change-Id: Idbd6d07eb7a21f2abf27ee06e7170125e1c706f4 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/93459 Tested-by: Jenkins Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
-rw-r--r--sw/source/ui/dbui/mmresultdialogs.cxx5
1 files changed, 5 insertions, 0 deletions
diff --git a/sw/source/ui/dbui/mmresultdialogs.cxx b/sw/source/ui/dbui/mmresultdialogs.cxx
index 3794f9f861c9..e9dcc0b93a1b 100644
--- a/sw/source/ui/dbui/mmresultdialogs.cxx
+++ b/sw/source/ui/dbui/mmresultdialogs.cxx
@@ -376,6 +376,7 @@ void SwMMResultPrintDialog::FillInPrinterSettings()
PrinterChangeHdl_Impl(*m_xPrinterLB);
sal_Int32 count = xConfigItem->GetMergedDocumentCount();
+ m_xFromNF->set_max(count);
m_xToNF->set_value(count);
m_xToNF->set_max(count);
}
@@ -432,6 +433,10 @@ void SwMMResultEmailDialog::FillInEmailSettings()
m_xSendAsLB->set_active(3);
SendTypeHdl_Impl(*m_xSendAsLB);
+ const sal_Int32 nCount = xConfigItem->GetMergedDocumentCount();
+ m_xFromNF->set_max(nCount);
+ m_xToNF->set_max(nCount);
+ m_xToNF->set_value(nCount);
}
IMPL_LINK_NOARG(SwMMResultSaveDialog, DocumentSelectionHdl_Impl, weld::ToggleButton&, void)