User: kz Date: 05/01/21 09:11:48 Modified: /dba/dbaccess/source/ui/dlg/ ConnectionPage.cxx
Log: INTEGRATION: CWS dba22 (1.5.4); FILE MERGED 2005/01/07 07:55:32 oj 1.5.4.2: RESYNC: (1.5-1.6); FILE MERGED 2005/01/06 12:42:47 oj 1.5.4.1: #i39321# extend createConnection to return a pair now File Changes: Directory: /dba/dbaccess/source/ui/dlg/ ======================================= File [changed]: ConnectionPage.cxx Url: http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/dlg/ConnectionPage.cxx?r1=1.6&r2=1.7 Delta lines: +1 -39 -------------------- --- ConnectionPage.cxx 26 Nov 2004 18:19:06 -0000 1.6 +++ ConnectionPage.cxx 21 Jan 2005 17:11:45 -0000 1.7 @@ -242,7 +242,7 @@ m_aUserName.SetModifyHdl(getControlModifiedLink()); m_aPasswordRequired.SetClickHdl(getControlModifiedLink()); - m_aTestConnection.SetClickHdl(LINK(this,OConnectionTabPage,OnTestConnectionClickHdl)); + m_aTestConnection.SetClickHdl(LINK(this,OGenericAdministrationPage,OnTestConnectionClickHdl)); m_aTestJavaDriver.SetClickHdl(LINK(this,OConnectionTabPage,OnTestJavaClickHdl)); // extract the datasource type collection from the item set @@ -420,44 +420,6 @@ fillString(_rSet,&m_aET_Connection, DSID_CONNECTURL, bChangedSomething); return bChangedSomething; - } - - // ----------------------------------------------------------------------- - IMPL_LINK(OConnectionTabPage, OnTestConnectionClickHdl, PushButton*, _pButton) - { - OSL_ENSURE(m_pAdminDialog,"No Admin dialog set! ->GPF"); - sal_Bool bSuccess = sal_False; - if ( m_pAdminDialog ) - { - m_pAdminDialog->saveDatasource(); - OGenericAdministrationPage::implInitControls(*m_pItemSetHelper->getOutputSet(), sal_True); - try - { - Reference< XConnection > xConnection = m_pAdminDialog->createConnection(); - bSuccess = xConnection.is(); - ::comphelper::disposeComponent(xConnection); - } - catch(Exception&) - { - } - - OSQLMessageBox::MessageType eImage = OSQLMessageBox::Info; - String aMessage,sTitle; - sTitle = String (ModuleRes(STR_CONNECTION_TEST)); - if ( bSuccess ) - { - aMessage = String(ModuleRes(STR_CONNECTION_SUCCESS)); - } - else - { - eImage = OSQLMessageBox::Error; - aMessage = String(ModuleRes(STR_CONNECTION_NO_SUCCESS)); - m_pAdminDialog->clearPassword(); - } - OSQLMessageBox aMsg(this,sTitle,aMessage); - aMsg.Execute(); - } - return 0L; } // ----------------------------------------------------------------------- IMPL_LINK(OConnectionTabPage, OnTestJavaClickHdl, PushButton*, _pButton) --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
