summaryrefslogtreecommitdiff
path: root/sw/source/ui/dbui
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/ui/dbui')
-rw-r--r--sw/source/ui/dbui/addresslistdialog.cxx7
-rw-r--r--sw/source/ui/dbui/mmoutputtypepage.cxx8
-rw-r--r--sw/source/ui/dbui/selectdbtabledialog.cxx4
3 files changed, 12 insertions, 7 deletions
diff --git a/sw/source/ui/dbui/addresslistdialog.cxx b/sw/source/ui/dbui/addresslistdialog.cxx
index aac1602f3968..2b5933096ac8 100644
--- a/sw/source/ui/dbui/addresslistdialog.cxx
+++ b/sw/source/ui/dbui/addresslistdialog.cxx
@@ -46,6 +46,7 @@
#include <com/sun/star/task/InteractionHandler.hpp>
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
#include <com/sun/star/frame/XStorable.hpp>
+#include <o3tl/safeint.hxx>
#include <swunohelper.hxx>
#include <unotools/pathoptions.hxx>
#include <tools/diagnose_ex.h>
@@ -147,8 +148,10 @@ SwAddressListDialog::SwAddressListDialog(SwMailMergeAddressBlockPage* pParent)
m_xListLB->set_size_request(m_xListLB->get_approximate_digit_width() * 52,
m_xListLB->get_height_rows(9));
- std::vector<int> aWidths;
- aWidths.push_back(m_xListLB->get_approximate_digit_width() * 26);
+ std::vector<int> aWidths
+ {
+ o3tl::narrowing<int>(m_xListLB->get_approximate_digit_width() * 26)
+ };
m_xListLB->set_column_fixed_widths(aWidths);
m_xListLB->make_sorted();
diff --git a/sw/source/ui/dbui/mmoutputtypepage.cxx b/sw/source/ui/dbui/mmoutputtypepage.cxx
index 27026e86830f..e8c8e35bc3dc 100644
--- a/sw/source/ui/dbui/mmoutputtypepage.cxx
+++ b/sw/source/ui/dbui/mmoutputtypepage.cxx
@@ -232,9 +232,11 @@ SwSendMailDialog::SwSendMailDialog(weld::Window *pParent, SwMailMergeConfigItem&
m_xStop->connect_clicked(LINK( this, SwSendMailDialog, StopHdl_Impl));
m_xCancel->connect_clicked(LINK( this, SwSendMailDialog, CancelHdl_Impl));
- std::vector<int> aWidths;
- aWidths.push_back(m_xStatus->get_checkbox_column_width());
- aWidths.push_back(aSize.Width()/3 * 2);
+ std::vector<int> aWidths
+ {
+ o3tl::narrowing<int>(m_xStatus->get_checkbox_column_width()),
+ o3tl::narrowing<int>(aSize.Width()/3 * 2)
+ };
m_xStatus->set_column_fixed_widths(aWidths);
m_xPaused->set_visible(false);
diff --git a/sw/source/ui/dbui/selectdbtabledialog.cxx b/sw/source/ui/dbui/selectdbtabledialog.cxx
index e49624e48273..3622a074193e 100644
--- a/sw/source/ui/dbui/selectdbtabledialog.cxx
+++ b/sw/source/ui/dbui/selectdbtabledialog.cxx
@@ -17,6 +17,7 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <o3tl/safeint.hxx>
#include <swtypes.hxx>
#include "selectdbtabledialog.hxx"
#include "dbtablepreviewdialog.hxx"
@@ -48,8 +49,7 @@ SwSelectDBTableDialog::SwSelectDBTableDialog(weld::Window* pParent,
m_xTable->set_size_request(m_xTable->get_approximate_digit_width() * 60,
m_xTable->get_height_rows(6));
- std::vector<int> aWidths;
- aWidths.push_back(m_xTable->get_approximate_digit_width() * 30);
+ std::vector<int> aWidths{ o3tl::narrowing<int>(m_xTable->get_approximate_digit_width() * 30) };
m_xTable->set_column_fixed_widths(aWidths);
m_xPreviewPB->connect_clicked(LINK(this, SwSelectDBTableDialog, PreviewHdl));