summaryrefslogtreecommitdiff
path: root/svx/source/sidebar/possize/PosSizePropertyPanel.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'svx/source/sidebar/possize/PosSizePropertyPanel.cxx')
-rw-r--r--svx/source/sidebar/possize/PosSizePropertyPanel.cxx28
1 files changed, 5 insertions, 23 deletions
diff --git a/svx/source/sidebar/possize/PosSizePropertyPanel.cxx b/svx/source/sidebar/possize/PosSizePropertyPanel.cxx
index aac8619a448e..50915798a068 100644
--- a/svx/source/sidebar/possize/PosSizePropertyPanel.cxx
+++ b/svx/source/sidebar/possize/PosSizePropertyPanel.cxx
@@ -53,11 +53,11 @@ const char USERITEM_NAME[] = "FitItem";
namespace svx::sidebar {
PosSizePropertyPanel::PosSizePropertyPanel(
- vcl::Window* pParent,
+ weld::Widget* pParent,
const css::uno::Reference<css::frame::XFrame>& rxFrame,
SfxBindings* pBindings,
const css::uno::Reference<css::ui::XSidebar>& rxSidebar)
-: PanelLayout(pParent, "PosSizePropertyPanel", "svx/ui/sidebarpossize.ui", rxFrame),
+: PanelLayout(pParent, "PosSizePropertyPanel", "svx/ui/sidebarpossize.ui"),
mxFtPosX(m_xBuilder->weld_label("horizontallabel")),
mxMtrPosX(m_xBuilder->weld_metric_spin_button("horizontalpos", FieldUnit::CM)),
mxFtPosY(m_xBuilder->weld_label("verticallabel")),
@@ -123,11 +123,6 @@ PosSizePropertyPanel::PosSizePropertyPanel(
PosSizePropertyPanel::~PosSizePropertyPanel()
{
- disposeOnce();
-}
-
-void PosSizePropertyPanel::dispose()
-{
mxFtPosX.reset();
mxMtrPosX.reset();
mxFtPosY.reset();
@@ -167,11 +162,8 @@ void PosSizePropertyPanel::dispose()
maAutoWidthControl.dispose();
maAutoHeightControl.dispose();
m_aMetricCtl.dispose();
-
- PanelLayout::dispose();
}
-
namespace
{
bool hasText(const SdrView& rSdrView)
@@ -241,8 +233,8 @@ void PosSizePropertyPanel::Initialize()
mePoolUnit = maTransfWidthControl.GetCoreMetric();
}
-VclPtr<vcl::Window> PosSizePropertyPanel::Create (
- vcl::Window* pParent,
+std::unique_ptr<PanelLayout> PosSizePropertyPanel::Create (
+ weld::Widget* pParent,
const css::uno::Reference<css::frame::XFrame>& rxFrame,
SfxBindings* pBindings,
const css::uno::Reference<css::ui::XSidebar>& rxSidebar)
@@ -254,17 +246,7 @@ VclPtr<vcl::Window> PosSizePropertyPanel::Create (
if (pBindings == nullptr)
throw lang::IllegalArgumentException("no SfxBindings given to PosSizePropertyPanel::Create", nullptr, 2);
- return VclPtr<PosSizePropertyPanel>::Create(
- pParent,
- rxFrame,
- pBindings,
- rxSidebar);
-}
-
-
-void PosSizePropertyPanel::DataChanged(
- const DataChangedEvent& /*rEvent*/)
-{
+ return std::make_unique<PosSizePropertyPanel>(pParent, rxFrame, pBindings, rxSidebar);
}
void PosSizePropertyPanel::HandleContextChange(