summaryrefslogtreecommitdiff
path: root/svx/source/form
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2013-12-27 11:43:03 +0000
committerCaolán McNamara <caolanm@redhat.com>2013-12-27 11:52:23 +0000
commit8f6a574d4f0fdf9d113aaa073daf948a7ec1df52 (patch)
tree7e2a7b37c9eb7a6f416477df771c259f2102abdf /svx/source/form
parentc98ce687901bb2e9f423f6cdf5fb5650ffe86b5b (diff)
convert add instance dialog to .ui
Change-Id: I92a82fb25b8b9d9cbedefb6fcebc7a4d167649bf
Diffstat (limited to 'svx/source/form')
-rw-r--r--svx/source/form/datanavi.cxx38
-rw-r--r--svx/source/form/datanavi.src89
2 files changed, 12 insertions, 115 deletions
diff --git a/svx/source/form/datanavi.cxx b/svx/source/form/datanavi.cxx
index 9820a0b3fba7..656f85479f9d 100644
--- a/svx/source/form/datanavi.cxx
+++ b/svx/source/form/datanavi.cxx
@@ -3597,39 +3597,25 @@ namespace svxform
// class AddInstanceDialog
//========================================================================
- AddInstanceDialog::AddInstanceDialog( Window* pParent, bool _bEdit ) :
-
- ModalDialog( pParent, SVX_RES( RID_SVXDLG_ADD_INSTANCE ) ),
-
- m_aInstanceFL ( this, SVX_RES( FL_INSTANCE ) ),
- m_aNameFT ( this, SVX_RES( FT_INST_NAME ) ),
- m_aNameED ( this, SVX_RES( ED_INST_NAME ) ),
- m_aURLFT ( this, SVX_RES( FT_INST_URL ) ),
- m_aURLED ( this, SVX_RES( ED_INST_URL ) ),
- m_aFilePickerBtn ( this, SVX_RES( PB_FILEPICKER ) ),
- m_aLinkInstanceCB ( this, SVX_RES( CB_INST_LINKINST ) ),
- m_aButtonsFL ( this, SVX_RES( FL_DATANAV_BTN ) ),
- m_aOKBtn ( this, SVX_RES( BTN_DATANAV_OK ) ),
- m_aEscBtn ( this, SVX_RES( BTN_DATANAV_ESC ) ),
- m_aHelpBtn ( this, SVX_RES( BTN_DATANAV_HELP ) )
-
+ AddInstanceDialog::AddInstanceDialog(Window* pParent, bool _bEdit)
+ : ModalDialog(pParent, "AddInstanceDialog" , "svx/ui/addinstancedialog.ui")
{
- if ( _bEdit )
- SetText(SVX_RESSTR(STR_EDIT_TEXT));
+ get(m_pNameED, "name");
+ get(m_pURLFT, "urlft");
+ get(m_pURLED, "url");
+ get(m_pFilePickerBtn, "browse");
+ get(m_pLinkInstanceCB, "link");
- FreeResource();
+ if ( _bEdit )
+ SetText(get<FixedText>("alttitle")->GetText());
- m_aURLED.DisableHistory();
- m_aFilePickerBtn.SetClickHdl( LINK( this, AddInstanceDialog, FilePickerHdl ) );
+ m_pURLED->DisableHistory();
+ m_pFilePickerBtn->SetClickHdl( LINK( this, AddInstanceDialog, FilePickerHdl ) );
// load the filter name from fps_office resource
m_sAllFilterName = ResId(STR_FILTERNAME_ALL, *ResMgr::CreateResMgr("fps_office")).toString();
}
- AddInstanceDialog::~AddInstanceDialog()
- {
- }
-
//------------------------------------------------------------------------
IMPL_LINK_NOARG(AddInstanceDialog, FilePickerHdl)
{
@@ -3644,7 +3630,7 @@ namespace svxform
aDlg.SetDisplayDirectory( aFile.GetMainURL( INetURLObject::NO_DECODE ) );
if( aDlg.Execute() == ERRCODE_NONE )
- m_aURLED.SetText( aDlg.GetPath() );
+ m_pURLED->SetText( aDlg.GetPath() );
return 0;
}
diff --git a/svx/source/form/datanavi.src b/svx/source/form/datanavi.src
index 882b93a6d31a..21b4b94f0682 100644
--- a/svx/source/form/datanavi.src
+++ b/svx/source/form/datanavi.src
@@ -868,95 +868,6 @@ ModalDialog RID_SVXDLG_ADD_SUBMISSION
};
};
-ModalDialog RID_SVXDLG_ADD_INSTANCE
-{
- HelpID = HID_XFORMS_ADDINSTANCE_DLG ;
- OutputSize = TRUE ;
- SVLook = TRUE ;
- Size = MAP_APPFONT ( 210 , 88 ) ;
- Text [ en-US ] = "Add Instance" ;
- Moveable = TRUE ;
- FixedLine FL_INSTANCE
- {
- Pos = MAP_APPFONT ( 4 , 3 ) ;
- Size = MAP_APPFONT ( 202 , 8 ) ;
- Text [ en-US ] = "Instance" ;
- };
- FixedText FT_INST_NAME
- {
- Pos = MAP_APPFONT ( 6 , 15 ) ;
- Size = MAP_APPFONT ( 51 , 8 ) ;
- LeftLabel = TRUE ;
- Text [ en-US ] = "~Name" ;
- };
- Edit ED_INST_NAME
- {
- HelpID = "svx:Edit:RID_SVXDLG_ADD_INSTANCE:ED_INST_NAME";
- Pos = MAP_APPFONT ( 60 , 14 ) ;
- Size = MAP_APPFONT ( 144 , 12 ) ;
- Border = TRUE ;
- };
- FixedText FT_INST_URL
- {
- Pos = MAP_APPFONT ( 6 , 30 ) ;
- Size = MAP_APPFONT ( 51 , 8 ) ;
- LeftLabel = TRUE ;
- Text [ en-US ] = "~URL" ;
- };
- ComboBox ED_INST_URL
- {
- HelpID = "svx:ComboBox:RID_SVXDLG_ADD_INSTANCE:ED_INST_URL";
- Pos = MAP_APPFONT ( 60 , 29 ) ;
- Size = MAP_APPFONT ( 127 , 48 ) ;
- DropDown = TRUE ;
- Border = TRUE ;
- };
- PushButton PB_FILEPICKER
- {
- HelpID = "svx:PushButton:RID_SVXDLG_ADD_INSTANCE:PB_FILEPICKER";
- Pos = MAP_APPFONT ( 190 , 28 ) ;
- Size = MAP_APPFONT ( 14 , 14 ) ;
- TabStop = TRUE ;
- Text = "~..." ;
- };
- CheckBox CB_INST_LINKINST
- {
- HelpID = "svx:CheckBox:RID_SVXDLG_ADD_INSTANCE:CB_INST_LINKINST";
- Pos = MAP_APPFONT ( 6 , 44 ) ;
- Size = MAP_APPFONT ( 198 , 10 ) ;
- TabStop = TRUE ;
- Text [ en-US ] = "~Link instance" ;
- };
- FixedLine FL_DATANAV_BTN
- {
- Pos = MAP_APPFONT ( 4 , 57 ) ;
- Size = MAP_APPFONT ( 202 , 8 ) ;
- };
- OKButton BTN_DATANAV_OK
- {
- Pos = MAP_APPFONT ( 45 , 68 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- TabStop = TRUE ;
- DefButton = TRUE ;
- };
- CancelButton BTN_DATANAV_ESC
- {
- Pos = MAP_APPFONT ( 98 , 68 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- TabStop = TRUE ;
- };
- HelpButton BTN_DATANAV_HELP
- {
- Pos = MAP_APPFONT ( 154 , 68 ) ;
- Size = MAP_APPFONT ( 50 , 14 ) ;
- TabStop = TRUE ;
- };
- String STR_EDIT_TEXT
- {
- Text [ en-US ] = "Edit Instance" ;
- };
-};
-
String RID_STR_DATANAV_SUBM_PARENT
{
Text [ en-US ] = "Submission: " ;