summaryrefslogtreecommitdiff
path: root/dbaccess/source
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-01-29 09:40:58 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-01-29 10:57:21 +0000
commit744c6ac9aed9deb61e43f702838fdb3688b9c831 (patch)
treeb86bdce86de62e2448fc372e468e3e48a8389da4 /dbaccess/source
parent4f5dfad645e476792214c4d5c80624d858ee8e78 (diff)
convert database properties dialog .to ui
Change-Id: I63c046f1637248e274698dbe13130124669e0712
Diffstat (limited to 'dbaccess/source')
-rw-r--r--dbaccess/source/ui/dlg/dbadmin.cxx20
-rw-r--r--dbaccess/source/ui/dlg/dbadmin.src17
-rw-r--r--dbaccess/source/ui/inc/dbu_resource.hrc1
3 files changed, 8 insertions, 30 deletions
diff --git a/dbaccess/source/ui/dlg/dbadmin.cxx b/dbaccess/source/ui/dlg/dbadmin.cxx
index 6102c2870d21..a048bd299759 100644
--- a/dbaccess/source/ui/dlg/dbadmin.cxx
+++ b/dbaccess/source/ui/dlg/dbadmin.cxx
@@ -50,23 +50,19 @@ using namespace com::sun::star::container;
// ODbAdminDialog
ODbAdminDialog::ODbAdminDialog(Window* _pParent
, SfxItemSet* _pItems
- , const Reference< XComponentContext >& _rxContext
- )
- :SfxTabDialog(_pParent, ModuleRes(DLG_DATABASE_ADMINISTRATION), _pItems)
- ,m_bApplied(sal_False)
- ,m_bUIEnabled( sal_True )
- ,m_nMainPageID( PAGE_CONNECTION )
+ , const Reference< XComponentContext >& _rxContext)
+ : SfxTabDialog(_pParent, "AdminDialog",
+ "dbaccess/ui/admindialog.ui", _pItems)
+ , m_bApplied(false)
+ , m_bUIEnabled(true)
{
-
m_pImpl.reset(new ODbDataSourceAdministrationHelper(_rxContext,this,this));
// add the initial tab page
- AddTabPage( m_nMainPageID, OUString( ModuleRes( STR_PAGETITLE_GENERAL ) ), OConnectionTabPage::Create, NULL );
+ m_nMainPageID = AddTabPage("advanced", OConnectionTabPage::Create, NULL);
// remove the reset button - it's meaning is much too ambiguous in this dialog
RemoveResetButton();
- // no local resources needed anymore
- FreeResource();
}
ODbAdminDialog::~ODbAdminDialog()
@@ -200,14 +196,14 @@ void ODbAdminDialog::impl_resetPages(const Reference< XPropertySet >& _rxDatasou
delete pExampleSet;
pExampleSet = new SfxItemSet(*GetInputSetImpl());
- // special case: MySQL Native does not have the generic PAGE_CONNECTION page
+ // special case: MySQL Native does not have the generic "advanced" page
DbuTypeCollectionItem* pCollectionItem = PTR_CAST(DbuTypeCollectionItem, getOutputSet()->GetItem(DSID_TYPECOLLECTION));
::dbaccess::ODsnTypeCollection* pCollection = pCollectionItem->getCollection();
if ( pCollection->determineType(getDatasourceType( *pExampleSet )) == ::dbaccess::DST_MYSQL_NATIVE )
{
AddTabPage( PAGE_MYSQL_NATIVE, OUString( ModuleRes( STR_PAGETITLE_CONNECTION ) ), ODriversSettings::CreateMySQLNATIVE, NULL );
- RemoveTabPage( PAGE_CONNECTION );
+ RemoveTabPage("advanced");
m_nMainPageID = PAGE_MYSQL_NATIVE;
}
diff --git a/dbaccess/source/ui/dlg/dbadmin.src b/dbaccess/source/ui/dlg/dbadmin.src
index 8f88911919a0..b4de71beec83 100644
--- a/dbaccess/source/ui/dlg/dbadmin.src
+++ b/dbaccess/source/ui/dlg/dbadmin.src
@@ -78,23 +78,6 @@
};
//-------------------------------------------------------------------------
-TabDialog DLG_DATABASE_ADMINISTRATION
-{
- OutputSize = TRUE ;
- SVLook = TRUE ;
- Moveable = TRUE ;
- Closeable = TRUE ;
- Hide = TRUE;
- HelpId = HID_DSADMIN_DIALOG;
-
- TabControl 1
- {
- OutputSize = TRUE ;
- };
-
- Text [ en-US ] = "Database properties" ;
-};
-
ModalDialog DLG_DATABASE_TYPE_CHANGE
{
OutputSize = TRUE ;
diff --git a/dbaccess/source/ui/inc/dbu_resource.hrc b/dbaccess/source/ui/inc/dbu_resource.hrc
index a8323283baef..7ca4ee7c49cd 100644
--- a/dbaccess/source/ui/inc/dbu_resource.hrc
+++ b/dbaccess/source/ui/inc/dbu_resource.hrc
@@ -76,7 +76,6 @@
//========================================================================
// dialog ids
-#define DLG_DATABASE_ADMINISTRATION RID_DIALOG_START + 0
#define DLG_DBASE_INDEXES RID_DIALOG_START + 1
#define DLG_SQLEXCEPTIONCHAIN RID_DIALOG_START + 3
#define DLG_DATASOURCE_SELECTION RID_DIALOG_START + 4