summaryrefslogtreecommitdiff
path: root/svx/source
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2013-12-05 11:21:02 +0000
committerCaolán McNamara <caolanm@redhat.com>2013-12-05 11:32:18 +0000
commitab80ea279bea37f4dd919417433cfd72ca28e8bd (patch)
treeeee7c9d48a04f75cf5919634290cfa2c0656a16f /svx/source
parent130833f80e89774269108cf30b2d1155a00354ce (diff)
Related: fdo#34396 convert extrusion dialog to .ui
Change-Id: Iea6e42fb7b65e148dcf6b566a7595b9e18f2e2eb
Diffstat (limited to 'svx/source')
-rw-r--r--svx/source/tbxctrls/extrusioncontrols.cxx20
-rw-r--r--svx/source/tbxctrls/extrusioncontrols.hrc2
-rw-r--r--svx/source/tbxctrls/extrusioncontrols.src57
3 files changed, 5 insertions, 74 deletions
diff --git a/svx/source/tbxctrls/extrusioncontrols.cxx b/svx/source/tbxctrls/extrusioncontrols.cxx
index 9a98163f0879..8ebf54ea92e8 100644
--- a/svx/source/tbxctrls/extrusioncontrols.cxx
+++ b/svx/source/tbxctrls/extrusioncontrols.cxx
@@ -297,27 +297,17 @@ Sequence< OUString > SAL_CALL ExtrusionDirectionControl::getSupportedServiceName
// ####################################################################
ExtrusionDepthDialog::ExtrusionDepthDialog( Window* pParent, double fDepth, FieldUnit eDefaultUnit )
-: ModalDialog( pParent, SVX_RES( RID_SVX_MDLG_EXTRUSION_DEPTH ) ),
- maFLDepth( this, SVX_RES( FL_DEPTH ) ),
- maMtrDepth( this, SVX_RES( MTR_DEPTH ) ),
- maOKButton( this, SVX_RES( BTN_OK ) ),
- maCancelButton( this, SVX_RES( BTN_CANCEL ) ),
- maHelpButton( this, SVX_RES( BTN_HELP ) )
+ : ModalDialog( pParent, "ExtrustionDepthDialog", "svx/ui/extrustiondepthdialog.ui" )
{
+ get(m_pMtrDepth, "depth");
bool bMetric = IsMetric( eDefaultUnit );
- maMtrDepth.SetUnit( bMetric ? FUNIT_CM : FUNIT_INCH );
- maMtrDepth.SetValue( (int) fDepth * 100, FUNIT_100TH_MM );
-
- FreeResource();
-}
-
-ExtrusionDepthDialog::~ExtrusionDepthDialog()
-{
+ m_pMtrDepth->SetUnit( bMetric ? FUNIT_CM : FUNIT_INCH );
+ m_pMtrDepth->SetValue( (int) fDepth * 100, FUNIT_100TH_MM );
}
double ExtrusionDepthDialog::getDepth() const
{
- return (double)( maMtrDepth.GetValue( FUNIT_100TH_MM ) ) / 100.0;
+ return (double)( m_pMtrDepth->GetValue( FUNIT_100TH_MM ) ) / 100.0;
}
// ####################################################################
diff --git a/svx/source/tbxctrls/extrusioncontrols.hrc b/svx/source/tbxctrls/extrusioncontrols.hrc
index f878df263633..6193ccadb2c5 100644
--- a/svx/source/tbxctrls/extrusioncontrols.hrc
+++ b/svx/source/tbxctrls/extrusioncontrols.hrc
@@ -80,8 +80,6 @@
#define IMG_LIGHTING_NORMAL 111
#define IMG_LIGHTING_DIM 112
-#define FL_DEPTH 1
-#define MTR_DEPTH 2
#define BTN_OK 3
#define BTN_CANCEL 4
#define BTN_HELP 5
diff --git a/svx/source/tbxctrls/extrusioncontrols.src b/svx/source/tbxctrls/extrusioncontrols.src
index 527707616a27..3600a28cc02c 100644
--- a/svx/source/tbxctrls/extrusioncontrols.src
+++ b/svx/source/tbxctrls/extrusioncontrols.src
@@ -430,63 +430,6 @@ DockingWindow RID_SVXFLOAT_EXTRUSION_SURFACE
};
};
-#define WIDTH 140
-#define HEIGHT (4 * 3 + 3 * 14)
-
-ModalDialog RID_SVX_MDLG_EXTRUSION_DEPTH
-{
- HelpID = "svx:ModalDialog:RID_SVX_MDLG_EXTRUSION_DEPTH";
- OutputSize = TRUE;
- SVLook = TRUE ;
- Moveable = TRUE;
- Closeable = TRUE;
-
- Size = MAP_APPFONT( WIDTH, HEIGHT );
-
- Text [ en-US ] = "Extrusion Depth" ;
-
- FixedText FL_DEPTH
- {
- Pos = MAP_APPFONT ( 3 , 3 ) ;
- Size = MAP_APPFONT ( WIDTH - 50 - 12 , 8 ) ;
- Text [ en-US ] = "~Value" ;
- };
- MetricField MTR_DEPTH
- {
- Border = FALSE ;
- Pos = MAP_APPFONT ( 3 , 14 ) ;
- Size = MAP_APPFONT ( WIDTH - 50 - 12, 12 ) ;
- TabStop = TRUE ;
- Repeat = TRUE ;
- Spin = TRUE ;
- Minimum = 0 ;
- Maximum = 338666 ;
- StrictFormat = TRUE ;
- DecimalDigits = 2 ;
- Unit = FUNIT_MM ;
- SpinSize = 10 ;
- };
- OkButton BTN_OK
- {
- Pos = MAP_APPFONT ( WIDTH - 50 - 3 , 1 * 3 + 0 * 14 ) ;
- Size = MAP_APPFONT ( 50, 14 ) ;
- DefButton = TRUE ;
- TabStop = TRUE ;
- };
- CancelButton BTN_CANCEL
- {
- Pos = MAP_APPFONT ( WIDTH - 50 - 3 , 2 * 3 + 1 * 14 ) ;
- Size = MAP_APPFONT ( 50, 14 ) ;
- TabStop = TRUE ;
- };
- HelpButton BTN_HELP
- {
- Pos = MAP_APPFONT ( WIDTH - 50 - 3 , 3 * 3 + 2 * 14 ) ;
- Size = MAP_APPFONT ( 50, 14 ) ;
- TabStop = TRUE ;
- };
-};
-
String RID_SVXSTR_EXTRUSION_COLOR
{
Text [ en-US ] = "Extrusion Color";