Tag: cws_src680_asyncdialogs2 User: pb Date: 2007-11-13 07:42:59+0000 Removed: dba/dbaccess/source/ui/dlg/AdvancedPageDlg.cxx dba/dbaccess/source/ui/dlg/AdvancedPageDlg.hrc dba/dbaccess/source/ui/dlg/AdvancedPageDlg.src dba/dbaccess/source/ui/inc/AdvancedPageDlg.hxx dba/dbaccess/source/ui/querydesign/TableWindowData.hxx dba/dbaccess/source/ui/uno/AdvancedSettingsDlg.hxx
Modified: dba/dbaccess/source/ui/app/AppController.cxx Log: RESYNC: (1.47-1.48); FILE MERGED File Changes: Directory: /dba/dbaccess/source/ui/app/ ======================================= File [changed]: AppController.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/app/AppController.cxx?r1=1.37.34.8&r2=1.37.34.9 Delta lines: +39 -52 --------------------- --- AppController.cxx 2007-10-16 04:29:53+0000 1.37.34.8 +++ AppController.cxx 2007-11-13 07:42:27+0000 1.37.34.9 @@ -36,12 +36,10 @@ // MARKER(update_precomp.py): autogen include statement, do not remove #include "precompiled_dbaccess.hxx" -#ifndef DBAUI_APPCONTROLLER_HXX #include "AppController.hxx" -#endif -#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC #include "dbustrings.hrc" -#endif +#include "advancedsettingsdlg.hxx" + /** === begin UNO includes === **/ #ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_ #include <com/sun/star/container/XNameContainer.hpp> @@ -795,9 +793,8 @@ break; case SID_DB_APP_DSUSERADMIN: { - ODsnTypeCollection aTypeCollection; - DATASOURCE_TYPE eType = aTypeCollection.getType(::comphelper::getString(m_xDataSource->getPropertyValue(PROPERTY_URL))); - aReturn.bEnabled = DST_EMBEDDED != eType; + DATASOURCE_TYPE eType = m_aTypeCollection.getType(::comphelper::getString(m_xDataSource->getPropertyValue(PROPERTY_URL))); + aReturn.bEnabled = DST_EMBEDDED_HSQLDB != eType; } break; case SID_DB_APP_DSRELDESIGN: @@ -814,7 +811,7 @@ if ( aReturn.bEnabled ) { DATASOURCE_TYPE eType = m_aTypeCollection.getType(::comphelper::getString(m_xDataSource->getPropertyValue(PROPERTY_URL))); - aReturn.bEnabled = DST_EMBEDDED != eType && DST_MOZILLA != eType && DST_EVOLUTION != eType && DST_KAB != eType && DST_MACAB != eType && DST_OUTLOOK != eType && DST_OUTLOOKEXP != eType; + aReturn.bEnabled = DST_EMBEDDED_HSQLDB != eType && DST_MOZILLA != eType && DST_EVOLUTION != eType && DST_KAB != eType && DST_MACAB != eType && DST_OUTLOOK != eType && DST_OUTLOOKEXP != eType; } break; case SID_DB_APP_DSCONNECTION_TYPE: @@ -822,15 +819,15 @@ if ( aReturn.bEnabled ) { DATASOURCE_TYPE eType = m_aTypeCollection.getType(::comphelper::getString(m_xDataSource->getPropertyValue(PROPERTY_URL))); - aReturn.bEnabled = DST_EMBEDDED != eType; + aReturn.bEnabled = DST_EMBEDDED_HSQLDB != eType; } break; case SID_DB_APP_DSADVANCED_SETTINGS: aReturn.bEnabled = m_xDataSource.is(); if ( aReturn.bEnabled ) { - DATASOURCE_TYPE eType = m_aTypeCollection.getType(::comphelper::getString(m_xDataSource->getPropertyValue(PROPERTY_URL))); - aReturn.bEnabled = DST_EMBEDDED != eType && DST_LDAP != eType && DST_CALC != eType && DST_MOZILLA != eType && DST_THUNDERBIRD != eType && DST_EVOLUTION != eType && DST_KAB != eType && DST_MACAB != eType && DST_OUTLOOK != eType && DST_OUTLOOKEXP != eType; + DATASOURCE_TYPE eType = m_aTypeCollection.getType( ::comphelper::getString( m_xDataSource->getPropertyValue( PROPERTY_URL ) ) ); + aReturn.bEnabled = AdvancedSettingsDialog::doesHaveAnyAdvancedSettings( eType ); } break; case SID_DB_APP_CONVERTTOVIEW: @@ -890,22 +887,18 @@ aReturn.bEnabled = m_xDataSource.is(); if ( aReturn.bEnabled ) { - ::rtl::OUString sTemp; - m_xDataSource->getPropertyValue(PROPERTY_URL) >>= sTemp; - DATASOURCE_TYPE eType = m_aTypeCollection.getType(sTemp); + ::rtl::OUString sURL; + m_xDataSource->getPropertyValue(PROPERTY_URL) >>= sURL; + DATASOURCE_TYPE eType = m_aTypeCollection.getType( sURL ); + String sDatabaseName; - if ( eType != DST_EMBEDDED ) - { - String sUser,sHostName,ssTemp; - ssTemp = sTemp; - sal_Int32 nPortNumber = -1; + String sHostName; + sal_Int32 nPortNumber( -1 ); + + m_aTypeCollection.extractHostNamePort( sURL, sDatabaseName, sHostName, nPortNumber ); - m_aTypeCollection.extractHostNamePort(ssTemp - ,sDatabaseName - ,sHostName - ,nPortNumber); if ( !sDatabaseName.Len() ) - sDatabaseName = m_aTypeCollection.cutPrefix(sTemp); + sDatabaseName = m_aTypeCollection.cutPrefix( sURL ); if ( m_aTypeCollection.isFileSystemBased(eType) ) { @@ -917,9 +910,10 @@ sDatabaseName = aFileNotation.get(::svt::OFileNotation::N_SYSTEM); } } - } - else - sDatabaseName = m_aTypeCollection.getEmbeddedDatabaseUIName(getORB()); + + if ( sDatabaseName.Len() == 0 ) + sDatabaseName = m_aTypeCollection.getTypeDisplayName( eType ); + aReturn.sTitle = sDatabaseName; } break; @@ -932,21 +926,14 @@ aReturn.bEnabled = m_xDataSource.is(); if ( aReturn.bEnabled ) { - ::rtl::OUString sTemp; - m_xDataSource->getPropertyValue(PROPERTY_URL) >>= sTemp; - DATASOURCE_TYPE eType = m_aTypeCollection.getType(sTemp); - if ( eType != DST_EMBEDDED ) - { - String sUser,sHostName,sDatabaseName,ssTemp; - ssTemp = sTemp; + ::rtl::OUString sURL; + m_xDataSource->getPropertyValue( PROPERTY_URL ) >>= sURL; + + String sHostName, sDatabaseName; sal_Int32 nPortNumber = -1; - m_aTypeCollection.extractHostNamePort(ssTemp - ,sDatabaseName - ,sHostName - ,nPortNumber); + m_aTypeCollection.extractHostNamePort( sURL, sDatabaseName, sHostName, nPortNumber ); aReturn.sTitle = sHostName; } - } break; default: aReturn = OApplicationController_CBASE::GetState(_nId); Directory: /dba/dbaccess/source/ui/dlg/ ======================================= File [removed]: AdvancedPageDlg.cxx Directory: /dba/dbaccess/source/ui/dlg/ ======================================= File [removed]: AdvancedPageDlg.hrc Directory: /dba/dbaccess/source/ui/dlg/ ======================================= File [removed]: AdvancedPageDlg.src Directory: /dba/dbaccess/source/ui/inc/ ======================================= File [removed]: AdvancedPageDlg.hxx Directory: /dba/dbaccess/source/ui/querydesign/ =============================================== File [removed]: TableWindowData.hxx Directory: /dba/dbaccess/source/ui/uno/ ======================================= File [removed]: AdvancedSettingsDlg.hxx --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
