diff --git a/cui/UIConfig_cui.mk b/cui/UIConfig_cui.mk index e5f5c429cc59..0b5974901f56 100644 --- a/cui/UIConfig_cui.mk +++ b/cui/UIConfig_cui.mk @@ -44,6 +44,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\ cui/uiconfig/ui/connpooloptions \ cui/uiconfig/ui/customizedialog \ cui/uiconfig/ui/dbregisterpage \ + cui/uiconfig/ui/distributiondialog \ cui/uiconfig/ui/distributionpage \ cui/uiconfig/ui/effectspage \ cui/uiconfig/ui/formatcellsdialog \ diff --git a/cui/source/inc/dstribut.hxx b/cui/source/inc/dstribut.hxx index c3133b6fc180..122284117714 100644 --- a/cui/source/inc/dstribut.hxx +++ b/cui/source/inc/dstribut.hxx @@ -56,15 +56,14 @@ public: SvxDistributeVertical GetDistributeVer() const { return m_eDistributeVer; } }; -class SvxDistributeDialog : public SfxNoLayoutSingleTabDialog +class SvxDistributeDialog : public SfxSingleTabDialog { - SvxDistributePage* mpPage; + SvxDistributePage* mpPage; public: SvxDistributeDialog(Window* pParent, const SfxItemSet& rAttr, SvxDistributeHorizontal eHor = SvxDistributeHorizontalNone, SvxDistributeVertical eVer = SvxDistributeVerticalNone); - ~SvxDistributeDialog(); SvxDistributeHorizontal GetDistributeHor() const { return mpPage->GetDistributeHor(); } SvxDistributeVertical GetDistributeVer() const { return mpPage->GetDistributeVer(); } diff --git a/cui/source/tabpages/dstribut.cxx b/cui/source/tabpages/dstribut.cxx index 8604b878aa92..20dfb4580025 100644 --- a/cui/source/tabpages/dstribut.cxx +++ b/cui/source/tabpages/dstribut.cxx @@ -38,27 +38,15 @@ static sal_uInt16 pRanges[] = |* \************************************************************************/ -SvxDistributeDialog::SvxDistributeDialog( - Window* pParent, - const SfxItemSet& rInAttrs, - SvxDistributeHorizontal eHor, +SvxDistributeDialog::SvxDistributeDialog(Window* pParent, + const SfxItemSet& rInAttrs, SvxDistributeHorizontal eHor, SvxDistributeVertical eVer) -: SfxNoLayoutSingleTabDialog(pParent, rInAttrs, RID_SVXPAGE_DISTRIBUTE ), - mpPage(0L) -{ - mpPage = new SvxDistributePage(this, rInAttrs, eHor, eVer); - SetTabPage(mpPage); - SetText(mpPage->GetText()); -} - -/************************************************************************* -|* -|* Dtor -|* -\************************************************************************/ - -SvxDistributeDialog::~SvxDistributeDialog() + : SfxSingleTabDialog(pParent, rInAttrs, "DistributionDialog", + "cui/ui/distributiondialog.ui") + , mpPage(NULL) { + mpPage = new SvxDistributePage(get_content_area(), rInAttrs, eHor, eVer); + setTabPage(mpPage); } /************************************************************************* @@ -97,12 +85,12 @@ SvxDistributePage::SvxDistributePage(Window* pWindow, SfxTabPage* SvxDistributePage::Create(Window* pWindow, const SfxItemSet& rAttrs, SvxDistributeHorizontal eHor, SvxDistributeVertical eVer) { - return(new SvxDistributePage(pWindow, rAttrs, eHor, eVer)); + return new SvxDistributePage(pWindow, rAttrs, eHor, eVer); } sal_uInt16* SvxDistributePage::GetRanges() { - return(pRanges); + return pRanges; } void SvxDistributePage::PointChanged(Window* /*pWindow*/, RECT_POINT /*eRP*/) diff --git a/cui/uiconfig/ui/distributiondialog.ui b/cui/uiconfig/ui/distributiondialog.ui new file mode 100644 index 000000000000..49e2dfa3d194 --- /dev/null +++ b/cui/uiconfig/ui/distributiondialog.ui @@ -0,0 +1,82 @@ + + + + + + False + 6 + Distribution + dialog + + + False + vertical + 12 + + + False + end + + + gtk-ok + True + True + True + True + True + True + + + False + True + 0 + + + + + gtk-cancel + True + True + True + True + + + False + True + 1 + + + + + gtk-help + True + True + True + True + + + False + True + 2 + + + + + False + True + end + 0 + + + + + + + + + ok + cancel + help + + + diff --git a/include/svx/dialogs.hrc b/include/svx/dialogs.hrc index a48c0f311d20..3a2307a170e1 100644 --- a/include/svx/dialogs.hrc +++ b/include/svx/dialogs.hrc @@ -87,7 +87,6 @@ #define RID_SVXPAGE_HATCH (RID_SVX_START + 57) #define RID_SVXPAGE_BITMAP (RID_SVX_START + 58) #define RID_SVXPAGE_GRADIENT (RID_SVX_START + 59) -#define RID_SVXPAGE_DISTRIBUTE (RID_SVX_START + 236) #define RID_SVXPAGE_MACROASSIGN (RID_SVX_START + 296)