summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-01-08 09:22:59 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-01-08 10:13:50 +0000
commit094869634d491a96e9de109a14fe4fc8db90a30a (patch)
tree0571094ca6c39d8f64c085f4267494378815143d /cui
parent3d4753f551914d0841552fcd37f569cea16a9a9d (diff)
can drop SfxNoLayoutSingleTabDialog use here now
Change-Id: I668b4f0b767d3a93a1407ae4ba7922235815a28b
Diffstat (limited to 'cui')
-rw-r--r--cui/UIConfig_cui.mk1
-rw-r--r--cui/source/inc/dstribut.hxx5
-rw-r--r--cui/source/tabpages/dstribut.cxx30
-rw-r--r--cui/uiconfig/ui/distributiondialog.ui82
4 files changed, 94 insertions, 24 deletions
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 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.16.0 on Wed Jan 8 09:29:54 2014 -->
+<interface>
+ <!-- interface-requires gtk+ 3.0 -->
+ <object class="GtkDialog" id="DistributionDialog">
+ <property name="can_focus">False</property>
+ <property name="border_width">6</property>
+ <property name="title" translatable="yes">Distribution</property>
+ <property name="type_hint">dialog</property>
+ <child internal-child="vbox">
+ <object class="GtkBox" id="dialog-vbox1">
+ <property name="can_focus">False</property>
+ <property name="orientation">vertical</property>
+ <property name="spacing">12</property>
+ <child internal-child="action_area">
+ <object class="GtkButtonBox" id="dialog-action_area1">
+ <property name="can_focus">False</property>
+ <property name="layout_style">end</property>
+ <child>
+ <object class="GtkButton" id="ok">
+ <property name="label">gtk-ok</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="can_default">True</property>
+ <property name="has_default">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="cancel">
+ <property name="label">gtk-cancel</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkButton" id="help">
+ <property name="label">gtk-help</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="use_stock">True</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">2</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="pack_type">end</property>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ </child>
+ <action-widgets>
+ <action-widget response="0">ok</action-widget>
+ <action-widget response="0">cancel</action-widget>
+ <action-widget response="0">help</action-widget>
+ </action-widgets>
+ </object>
+</interface>