diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-08-18 15:05:10 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-08-20 08:19:48 +0200 |
commit | 0f34e96a5ce68a3039f65cd0f896b33f2d20af5f (patch) | |
tree | 2ea420b96865e6fe69bbbbc1915d3b1ac4c1e808 /svtools | |
parent | f05b0a6aaf8af5d78f9cad8bb953228cb0ce09f1 (diff) |
return weld widgets by std::unique_ptr from builder
Change-Id: I20c007b13dae2d1155034711ad1ad48bfdfd0ba8
Reviewed-on: https://gerrit.libreoffice.org/59288
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'svtools')
-rw-r--r-- | svtools/source/control/inettbc.cxx | 4 | ||||
-rw-r--r-- | svtools/source/control/valueset.cxx | 4 | ||||
-rw-r--r-- | svtools/source/dialogs/restartdialog.cxx | 22 |
3 files changed, 15 insertions, 15 deletions
diff --git a/svtools/source/control/inettbc.cxx b/svtools/source/control/inettbc.cxx index cf7f7c7e0473..25e70761e7d4 100644 --- a/svtools/source/control/inettbc.cxx +++ b/svtools/source/control/inettbc.cxx @@ -2009,9 +2009,9 @@ IMPL_LINK_NOARG(URLBox, TryAutoComplete, Timer *, void) m_xWidget->clear(); } -URLBox::URLBox(weld::ComboBoxText* pWidget) +URLBox::URLBox(std::unique_ptr<weld::ComboBoxText> pWidget) : bHistoryDisabled(false) - , m_xWidget(pWidget) + , m_xWidget(std::move(pWidget)) { Init(); diff --git a/svtools/source/control/valueset.cxx b/svtools/source/control/valueset.cxx index 34f980bec084..50e674bee2da 100644 --- a/svtools/source/control/valueset.cxx +++ b/svtools/source/control/valueset.cxx @@ -2276,9 +2276,9 @@ void ValueSet::SetEdgeBlending(bool bNew) } } -SvtValueSet::SvtValueSet(weld::ScrolledWindow* pScrolledWindow) +SvtValueSet::SvtValueSet(std::unique_ptr<weld::ScrolledWindow> pScrolledWindow) : maVirDev( VclPtr<VirtualDevice>::Create()) - , mxScrolledWindow(pScrolledWindow) + , mxScrolledWindow(std::move(pScrolledWindow)) , maColor(COL_TRANSPARENT) , mnStyle(0) , mbFormat(true) diff --git a/svtools/source/dialogs/restartdialog.cxx b/svtools/source/dialogs/restartdialog.cxx index 122f314eccd8..47a3ee906091 100644 --- a/svtools/source/dialogs/restartdialog.cxx +++ b/svtools/source/dialogs/restartdialog.cxx @@ -30,37 +30,37 @@ public: { switch (reason) { case svtools::RESTART_REASON_JAVA: - reason_.reset(m_xBuilder->weld_widget("reason_java")); + reason_ = m_xBuilder->weld_widget("reason_java"); break; case svtools::RESTART_REASON_PDF_AS_STANDARD_JOB_FORMAT: - reason_.reset(m_xBuilder->weld_widget("reason_pdf")); + reason_ = m_xBuilder->weld_widget("reason_pdf"); break; case svtools::RESTART_REASON_BIBLIOGRAPHY_INSTALL: - reason_.reset(m_xBuilder->weld_widget("reason_bibliography_install")); + reason_ = m_xBuilder->weld_widget("reason_bibliography_install"); break; case svtools::RESTART_REASON_MAILMERGE_INSTALL: - reason_.reset(m_xBuilder->weld_widget("reason_mailmerge_install")); + reason_ = m_xBuilder->weld_widget("reason_mailmerge_install"); break; case svtools::RESTART_REASON_LANGUAGE_CHANGE: - reason_.reset(m_xBuilder->weld_widget("reason_language_change")); + reason_ = m_xBuilder->weld_widget("reason_language_change"); break; case svtools::RESTART_REASON_ADDING_PATH: - reason_.reset(m_xBuilder->weld_widget("reason_adding_path")); + reason_ = m_xBuilder->weld_widget("reason_adding_path"); break; case svtools::RESTART_REASON_ASSIGNING_JAVAPARAMETERS: - reason_.reset(m_xBuilder->weld_widget("reason_assigning_javaparameters")); + reason_ = m_xBuilder->weld_widget("reason_assigning_javaparameters"); break; case svtools::RESTART_REASON_ASSIGNING_FOLDERS: - reason_.reset(m_xBuilder->weld_widget("reason_assigning_folders")); + reason_ = m_xBuilder->weld_widget("reason_assigning_folders"); break; case svtools::RESTART_REASON_EXP_FEATURES: - reason_.reset(m_xBuilder->weld_widget("reason_exp_features")); + reason_ = m_xBuilder->weld_widget("reason_exp_features"); break; case svtools::RESTART_REASON_EXTENSION_INSTALL: - reason_.reset(m_xBuilder->weld_widget("reason_extension_install")); + reason_ = m_xBuilder->weld_widget("reason_extension_install"); break; case svtools::RESTART_REASON_OPENGL: - reason_.reset(m_xBuilder->weld_widget("reason_opengl")); + reason_ = m_xBuilder->weld_widget("reason_opengl"); break; default: assert(false); // this cannot happen |