summaryrefslogtreecommitdiff
path: root/dbaccess
diff options
context:
space:
mode:
authorAndras Timar <atimar@suse.com>2012-11-11 18:24:14 +0100
committerAndras Timar <atimar@suse.com>2012-11-11 18:24:14 +0100
commit06ec1c089519ef3249464aa09eadf03a8db93a39 (patch)
tree85b2eb6d8ba6ca95e18e1ff82151224cb14106f6 /dbaccess
parent8e0d67bed54633d555a4601a5d79e2d5ba7ab2bb (diff)
parent3f899eae02eaad0b967de749fe09b869ba93ad6d (diff)
Merge branch 'master' into feature/killsdf
Conflicts: Repository.mk RepositoryFixes.mk connectivity/prj/build.lst extensions/prj/build.lst filter/prj/build.lst fpicker/prj/build.lst l10ntools/StaticLibrary_transex.mk saxon/build.xml shell/prj/build.lst solenv/gbuild/AllLangResTarget.mk solenv/gbuild/Configuration.mk solenv/gbuild/UI.mk ucb/source/ucp/webdav/webdavcontent.cxx
Diffstat (limited to 'dbaccess')
-rw-r--r--dbaccess/JunitTest_dbaccess_complex.mk10
-rw-r--r--dbaccess/JunitTest_dbaccess_unoapi.mk8
-rw-r--r--dbaccess/source/core/api/KeySet.cxx7
-rw-r--r--dbaccess/source/core/api/OptimisticSet.cxx8
-rw-r--r--dbaccess/source/core/api/RowSetCache.cxx2
-rw-r--r--dbaccess/source/core/api/SingleSelectQueryComposer.cxx15
-rw-r--r--dbaccess/source/core/api/definitioncolumn.cxx42
-rw-r--r--dbaccess/source/core/dataaccess/ContentHelper.cxx2
-rw-r--r--dbaccess/source/core/dataaccess/ModelImpl.cxx6
-rw-r--r--dbaccess/source/core/dataaccess/databasedocument.cxx8
-rw-r--r--dbaccess/source/core/dataaccess/datasource.cxx1
-rw-r--r--dbaccess/source/core/dataaccess/documentdefinition.cxx3
-rw-r--r--dbaccess/source/core/inc/definitioncolumn.hxx2
-rw-r--r--dbaccess/source/core/recovery/storagexmlstream.cxx5
-rw-r--r--dbaccess/source/ext/macromigration/migrationengine.cxx1
-rw-r--r--dbaccess/source/inc/stringconstants.inc1
-rw-r--r--dbaccess/source/ui/app/AppController.cxx6
-rw-r--r--dbaccess/source/ui/app/AppController.hxx4
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.cxx56
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.hxx10
-rw-r--r--dbaccess/source/ui/app/AppDetailView.cxx36
-rw-r--r--dbaccess/source/ui/app/AppDetailView.hxx22
-rw-r--r--dbaccess/source/ui/app/AppView.cxx8
-rw-r--r--dbaccess/source/ui/app/AppView.hxx10
-rw-r--r--dbaccess/source/ui/browser/brwctrlr.cxx2
-rw-r--r--dbaccess/source/ui/browser/dbtreeview.cxx2
-rw-r--r--dbaccess/source/ui/browser/dbtreeview.hxx6
-rw-r--r--dbaccess/source/ui/browser/dsEntriesNoExp.cxx22
-rw-r--r--dbaccess/source/ui/browser/dsbrowserDnD.cxx18
-rw-r--r--dbaccess/source/ui/browser/genericcontroller.cxx2
-rw-r--r--dbaccess/source/ui/browser/unodatbr.cxx167
-rw-r--r--dbaccess/source/ui/control/dbtreelistbox.cxx69
-rw-r--r--dbaccess/source/ui/control/listviewitems.cxx4
-rw-r--r--dbaccess/source/ui/control/marktree.cxx20
-rw-r--r--dbaccess/source/ui/control/tabletree.cxx54
-rw-r--r--dbaccess/source/ui/dlg/ConnectionHelper.cxx10
-rw-r--r--dbaccess/source/ui/dlg/adtabdlg.cxx14
-rw-r--r--dbaccess/source/ui/dlg/indexdialog.cxx40
-rw-r--r--dbaccess/source/ui/dlg/paramdialog.cxx32
-rw-r--r--dbaccess/source/ui/dlg/queryfilter.cxx4
-rw-r--r--dbaccess/source/ui/dlg/sqlmessage.cxx4
-rw-r--r--dbaccess/source/ui/dlg/tablespage.cxx32
-rw-r--r--dbaccess/source/ui/dlg/tablespage.hxx2
-rw-r--r--dbaccess/source/ui/inc/TableCopyHelper.hxx4
-rw-r--r--dbaccess/source/ui/inc/TableWindow.hxx4
-rw-r--r--dbaccess/source/ui/inc/TableWindowListBox.hxx4
-rw-r--r--dbaccess/source/ui/inc/WNameMatch.hxx4
-rw-r--r--dbaccess/source/ui/inc/callbacks.hxx4
-rw-r--r--dbaccess/source/ui/inc/dbtreelistbox.hxx26
-rw-r--r--dbaccess/source/ui/inc/indexdialog.hxx18
-rw-r--r--dbaccess/source/ui/inc/listviewitems.hxx6
-rw-r--r--dbaccess/source/ui/inc/marktree.hxx4
-rw-r--r--dbaccess/source/ui/inc/paramdialog.hxx2
-rw-r--r--dbaccess/source/ui/inc/queryfilter.hxx2
-rw-r--r--dbaccess/source/ui/inc/tabletree.hxx26
-rw-r--r--dbaccess/source/ui/inc/unodatbr.hxx74
-rw-r--r--dbaccess/source/ui/misc/WNameMatch.cxx32
-rw-r--r--dbaccess/source/ui/querydesign/ConnectionLine.cxx6
-rw-r--r--dbaccess/source/ui/querydesign/JoinTableView.cxx8
-rw-r--r--dbaccess/source/ui/querydesign/QTableWindow.cxx4
-rw-r--r--dbaccess/source/ui/querydesign/QTableWindow.hxx2
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx5
-rw-r--r--dbaccess/source/ui/querydesign/TableWindow.cxx12
-rw-r--r--dbaccess/source/ui/querydesign/TableWindowListBox.cxx12
-rw-r--r--dbaccess/source/ui/querydesign/querycontroller.cxx14
-rw-r--r--dbaccess/source/ui/uno/composerdialogs.cxx2
-rw-r--r--dbaccess/source/ui/uno/dbinteraction.cxx2
-rw-r--r--dbaccess/uiconfig/dbapp/menubar/menubar.xml3
-rw-r--r--dbaccess/uiconfig/dbquery/menubar/menubar.xml3
-rw-r--r--dbaccess/uiconfig/dbrelation/menubar/menubar.xml3
-rw-r--r--dbaccess/uiconfig/dbtable/menubar/menubar.xml3
-rw-r--r--dbaccess/uiconfig/dbtdata/menubar/menubar.xml3
72 files changed, 552 insertions, 517 deletions
diff --git a/dbaccess/JunitTest_dbaccess_complex.mk b/dbaccess/JunitTest_dbaccess_complex.mk
index fd1511e6fbab..bd8358ef70d8 100644
--- a/dbaccess/JunitTest_dbaccess_complex.mk
+++ b/dbaccess/JunitTest_dbaccess_complex.mk
@@ -7,9 +7,9 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
#
-$(eval $(call gb_JunitTest_JunitTest,dba_ju_complex))
+$(eval $(call gb_JunitTest_JunitTest,dbaccess_ju_complex))
-$(eval $(call gb_JunitTest_use_jars,dba_ju_complex,\
+$(eval $(call gb_JunitTest_use_jars,dbaccess_ju_complex,\
ConnectivityTools \
OOoRunner \
jurt \
@@ -18,17 +18,17 @@ $(eval $(call gb_JunitTest_use_jars,dba_ju_complex,\
unoil \
))
-$(eval $(call gb_JunitTest_set_defs,dba_ju_complex,\
+$(eval $(call gb_JunitTest_set_defs,dbaccess_ju_complex,\
$$(DEFS) \
-Dorg.openoffice.test.arg.tdoc=$(SRCDIR)/dbaccess/qa/dbaccess \
))
-$(eval $(call gb_JunitTest_add_classes,dba_ju_complex,\
+$(eval $(call gb_JunitTest_add_classes,dbaccess_ju_complex,\
complex.dbaccess.Beamer \
complex.dbaccess.PropertyBag \
))
-$(eval $(call gb_JunitTest_add_sourcefiles,dba_ju_complex,\
+$(eval $(call gb_JunitTest_add_sourcefiles,dbaccess_ju_complex,\
dbaccess/qa/complex/dbaccess/ApplicationController \
dbaccess/qa/complex/dbaccess/Beamer \
dbaccess/qa/complex/dbaccess/CRMBasedTestCase \
diff --git a/dbaccess/JunitTest_dbaccess_unoapi.mk b/dbaccess/JunitTest_dbaccess_unoapi.mk
index 5897697faa54..f948229c46da 100644
--- a/dbaccess/JunitTest_dbaccess_unoapi.mk
+++ b/dbaccess/JunitTest_dbaccess_unoapi.mk
@@ -26,16 +26,16 @@
# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
# instead of those above.
-$(eval $(call gb_JunitTest_JunitTest,dba_ju_unoapi))
+$(eval $(call gb_JunitTest_JunitTest,dbaccess_ju_unoapi))
-$(eval $(call gb_JunitTest_set_defs,dba_ju_unoapi,\
+$(eval $(call gb_JunitTest_set_defs,dbaccess_ju_unoapi,\
$$(DEFS) \
-Dorg.openoffice.test.arg.sce=$(SRCDIR)/dbaccess/qa/unoapi/dbaccess.sce \
-Dorg.openoffice.test.arg.xcl=$(SRCDIR)/dbaccess/qa/unoapi/knownissues.xcl \
-Dorg.openoffice.test.arg.tdoc=$(SRCDIR)/dbaccess/qa/unoapi/testdocuments \
))
-$(eval $(call gb_JunitTest_use_jars,dba_ju_unoapi,\
+$(eval $(call gb_JunitTest_use_jars,dbaccess_ju_unoapi,\
OOoRunner \
jurt \
ridl \
@@ -43,7 +43,7 @@ $(eval $(call gb_JunitTest_use_jars,dba_ju_unoapi,\
unoil \
))
-$(eval $(call gb_JunitTest_add_classes,dba_ju_unoapi,\
+$(eval $(call gb_JunitTest_add_classes,dbaccess_ju_unoapi,\
org.openoffice.test.UnoApiTest \
))
diff --git a/dbaccess/source/core/api/KeySet.cxx b/dbaccess/source/core/api/KeySet.cxx
index 6a520cf49fe1..2fa7eeafddd6 100644
--- a/dbaccess/source/core/api/KeySet.cxx
+++ b/dbaccess/source/core/api/KeySet.cxx
@@ -291,7 +291,8 @@ void OKeySet::construct(const Reference< XResultSet>& _xDriverSet,const ::rtl::O
// the first row is empty because it's now easier for us to distinguish when we are beforefirst or first
// without extra variable to be set
- m_aKeyMap.insert(OKeySetMatrix::value_type(0,OKeySetValue(NULL,::std::pair<sal_Int32,Reference<XRow> >(0,NULL))));
+ OKeySetValue keySetValue((ORowSetValueVector *)NULL,::std::pair<sal_Int32,Reference<XRow> >(0,(Reference<XRow>)NULL));
+ m_aKeyMap.insert(OKeySetMatrix::value_type(0, keySetValue));
m_aKeyIter = m_aKeyMap.begin();
::rtl::OUStringBuffer aFilter = createKeyFilter();
@@ -876,7 +877,7 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const ::rtl::OUString
ORowSetRow aKeyRow = new connectivity::ORowVector< ORowSetValue >(m_pKeyColumnNames->size());
copyRowValue(_rInsertRow,aKeyRow,aKeyIter->first + 1);
- m_aKeyIter = m_aKeyMap.insert(OKeySetMatrix::value_type(aKeyIter->first + 1,OKeySetValue(aKeyRow,::std::pair<sal_Int32,Reference<XRow> >(1,NULL)))).first;
+ m_aKeyIter = m_aKeyMap.insert(OKeySetMatrix::value_type(aKeyIter->first + 1,OKeySetValue(aKeyRow,::std::pair<sal_Int32,Reference<XRow> >(1,(Reference<XRow>)NULL)))).first;
// now we set the bookmark for this row
(_rInsertRow->get())[0] = makeAny((sal_Int32)m_aKeyIter->first);
tryRefetch(_rInsertRow,bRefetch);
@@ -1466,7 +1467,7 @@ sal_Bool OKeySet::fetchRow()
const SelectColumnDescription& rColDesc = aPosIter->second;
aIter->fill(rColDesc.nPosition, rColDesc.nType, m_xRow);
}
- m_aKeyIter = m_aKeyMap.insert(OKeySetMatrix::value_type(m_aKeyMap.rbegin()->first+1,OKeySetValue(aKeyRow,::std::pair<sal_Int32,Reference<XRow> >(0,NULL)))).first;
+ m_aKeyIter = m_aKeyMap.insert(OKeySetMatrix::value_type(m_aKeyMap.rbegin()->first+1,OKeySetValue(aKeyRow,::std::pair<sal_Int32,Reference<XRow> >(0,(Reference<XRow>)NULL)))).first;
}
else
m_bRowCountFinal = sal_True;
diff --git a/dbaccess/source/core/api/OptimisticSet.cxx b/dbaccess/source/core/api/OptimisticSet.cxx
index 17dc208cb6cf..ca6f1b59cf33 100644
--- a/dbaccess/source/core/api/OptimisticSet.cxx
+++ b/dbaccess/source/core/api/OptimisticSet.cxx
@@ -92,7 +92,7 @@ OptimisticSet::OptimisticSet(const ::comphelper::ComponentContext& _rContext,
sal_Int32 i_nMaxRows,
sal_Int32& o_nRowCount)
:OKeySet(NULL,NULL,::rtl::OUString(),_xComposer,_aParameterValueForCache,i_nMaxRows,o_nRowCount)
- ,m_aSqlParser( _rContext.getLegacyServiceFactory() )
+ ,m_aSqlParser( _rContext.getUNOContext() )
,m_aSqlIterator( i_xConnection, Reference<XTablesSupplier>(_xComposer,UNO_QUERY)->getTables(), m_aSqlParser, NULL )
,m_bResultSetChanged(false)
{
@@ -131,7 +131,8 @@ void OptimisticSet::construct(const Reference< XResultSet>& _xDriverSet,const ::
// the first row is empty because it's now easier for us to distinguish when we are beforefirst or first
// without extra variable to be set
- m_aKeyMap.insert(OKeySetMatrix::value_type(0,OKeySetValue(NULL,::std::pair<sal_Int32,Reference<XRow> >(0,NULL))));
+ OKeySetValue keySetValue((ORowSetValueVector *)NULL,::std::pair<sal_Int32,Reference<XRow> >(0,(Reference<XRow>)NULL));
+ m_aKeyMap.insert(OKeySetMatrix::value_type(0,keySetValue));
m_aKeyIter = m_aKeyMap.begin();
::rtl::OUStringBuffer aFilter = createKeyFilter();
@@ -503,7 +504,8 @@ void OptimisticSet::reset(const Reference< XResultSet>& _xDriverSet)
OCacheSet::construct(_xDriverSet,::rtl::OUString());
m_bRowCountFinal = sal_False;
m_aKeyMap.clear();
- m_aKeyMap.insert(OKeySetMatrix::value_type(0,OKeySetValue(NULL,::std::pair<sal_Int32,Reference<XRow> >(0,NULL))));
+ OKeySetValue keySetValue((ORowSetValueVector *)NULL,::std::pair<sal_Int32,Reference<XRow> >(0,(Reference<XRow>)NULL));
+ m_aKeyMap.insert(OKeySetMatrix::value_type(0,keySetValue));
m_aKeyIter = m_aKeyMap.begin();
}
diff --git a/dbaccess/source/core/api/RowSetCache.cxx b/dbaccess/source/core/api/RowSetCache.cxx
index 0a18b04af516..34896882182e 100644
--- a/dbaccess/source/core/api/RowSetCache.cxx
+++ b/dbaccess/source/core/api/RowSetCache.cxx
@@ -1580,7 +1580,7 @@ sal_Bool ORowSetCache::checkJoin(const Reference< XConnection>& _xConnection,
sal_Bool bOk = sal_False;
::rtl::OUString sSql = _xAnalyzer->getQuery();
::rtl::OUString sErrorMsg;
- ::connectivity::OSQLParser aSqlParser( m_aContext.getLegacyServiceFactory() );
+ ::connectivity::OSQLParser aSqlParser( m_aContext.getUNOContext() );
SAL_WNODEPRECATED_DECLARATIONS_PUSH
::std::auto_ptr< ::connectivity::OSQLParseNode> pSqlParseNode( aSqlParser.parseTree(sErrorMsg,sSql));
SAL_WNODEPRECATED_DECLARATIONS_POP
diff --git a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
index faef30832cc1..e078e1e28c4c 100644
--- a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
+++ b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
@@ -234,7 +234,7 @@ OSingleSelectQueryComposer::OSingleSelectQueryComposer(const Reference< XNameAcc
const ::comphelper::ComponentContext& _rContext )
:OSubComponent(m_aMutex,_xConnection)
,OPropertyContainer(m_aBHelper)
- ,m_aSqlParser( _rContext.getLegacyServiceFactory() )
+ ,m_aSqlParser( _rContext.getUNOContext() )
,m_aSqlIterator( _xConnection, _rxTables, m_aSqlParser, NULL )
,m_aAdditiveIterator( _xConnection, _rxTables, m_aSqlParser, NULL )
,m_aElementaryParts( (size_t)SQLPartCount )
@@ -1290,9 +1290,12 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
if(m_pTables && m_pTables->getCount() > 1)
{
::rtl::OUString aCatalog,aSchema,aTable,aComposedName,aColumnName;
- column->getPropertyValue(PROPERTY_CATALOGNAME) >>= aCatalog;
- column->getPropertyValue(PROPERTY_SCHEMANAME) >>= aSchema;
- column->getPropertyValue(PROPERTY_TABLENAME) >>= aTable;
+ if(column->getPropertySetInfo()->hasPropertyByName(PROPERTY_CATALOGNAME))
+ column->getPropertyValue(PROPERTY_CATALOGNAME) >>= aCatalog;
+ if(column->getPropertySetInfo()->hasPropertyByName(PROPERTY_SCHEMANAME))
+ column->getPropertyValue(PROPERTY_SCHEMANAME) >>= aSchema;
+ if(column->getPropertySetInfo()->hasPropertyByName(PROPERTY_TABLENAME))
+ column->getPropertyValue(PROPERTY_TABLENAME) >>= aTable;
column->getPropertyValue(PROPERTY_NAME) >>= aColumnName;
Sequence< ::rtl::OUString> aNames(m_pTables->getElementNames());
@@ -1515,14 +1518,14 @@ namespace
void SAL_CALL OSingleSelectQueryComposer::setStructuredFilter( const Sequence< Sequence< PropertyValue > >& filter ) throw (SQLException, ::com::sun::star::lang::IllegalArgumentException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setStructuredFilter" );
- OPredicateInputController aPredicateInput(m_aContext.getLegacyServiceFactory(),m_xConnection);
+ OPredicateInputController aPredicateInput(m_aContext.getUNOContext(),m_xConnection);
setFilter(lcl_getCondition(filter,aPredicateInput,getColumns()));
}
void SAL_CALL OSingleSelectQueryComposer::setStructuredHavingClause( const Sequence< Sequence< PropertyValue > >& filter ) throw (SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setStructuredHavingClause" );
- OPredicateInputController aPredicateInput(m_aContext.getLegacyServiceFactory(),m_xConnection);
+ OPredicateInputController aPredicateInput(m_aContext.getUNOContext(),m_xConnection);
setHavingClause(lcl_getCondition(filter,aPredicateInput,getColumns()));
}
diff --git a/dbaccess/source/core/api/definitioncolumn.cxx b/dbaccess/source/core/api/definitioncolumn.cxx
index 190da6017ae4..df9a92a6f69e 100644
--- a/dbaccess/source/core/api/definitioncolumn.cxx
+++ b/dbaccess/source/core/api/definitioncolumn.cxx
@@ -17,6 +17,7 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
+#include <bitset>
#include "apitools.hxx"
#include "dbastrings.hrc"
@@ -44,10 +45,16 @@ using namespace ::comphelper;
using namespace ::osl;
using namespace dbaccess;
-#define HAS_DESCRIPTION 0x00000001
-#define HAS_DEFAULTVALUE 0x00000002
-#define HAS_ROWVERSION 0x00000004
-#define HAS_AUTOINCREMENT_CREATION 0x00000008
+namespace
+{
+ const sal_Int32 HAS_DESCRIPTION = 0x00000001;
+ const sal_Int32 HAS_DEFAULTVALUE = 0x00000002;
+ const sal_Int32 HAS_ROWVERSION = 0x00000004;
+ const sal_Int32 HAS_AUTOINCREMENT_CREATION = 0x00000008;
+ const sal_Int32 HAS_CATALOGNAME = 0x00000010;
+ const sal_Int32 HAS_SCHEMANAME = 0x00000020;
+ const sal_Int32 HAS_TABLENAME = 0x00000040;
+}
//============================================================
//= OTableColumnDescriptor
@@ -162,7 +169,7 @@ rtl::OUString OTableColumn::getImplementationName( ) throw (RuntimeException)
// =========================================================================
DBG_NAME( OQueryColumn );
-OQueryColumn::OQueryColumn( const Reference< XPropertySet >& _rxParserColumn, const Reference< XConnection >& _rxConnection,const ::rtl::OUString i_sLabel )
+OQueryColumn::OQueryColumn( const Reference< XPropertySet >& _rxParserColumn, const Reference< XConnection >& _rxConnection, const ::rtl::OUString &i_sLabel )
:OTableColumnDescriptor( false /* do not act as descriptor */ )
,m_sLabel(i_sLabel)
{
@@ -336,6 +343,9 @@ OColumnWrapper::OColumnWrapper( const Reference< XPropertySet > & rCol, const bo
m_nColTypeID |= xInfo->hasPropertyByName(PROPERTY_DEFAULTVALUE) ? HAS_DEFAULTVALUE : 0;
m_nColTypeID |= xInfo->hasPropertyByName(PROPERTY_ISROWVERSION) ? HAS_ROWVERSION : 0;
m_nColTypeID |= xInfo->hasPropertyByName(PROPERTY_AUTOINCREMENTCREATION) ? HAS_AUTOINCREMENT_CREATION : 0;
+ m_nColTypeID |= xInfo->hasPropertyByName(PROPERTY_CATALOGNAME) ? HAS_CATALOGNAME : 0;
+ m_nColTypeID |= xInfo->hasPropertyByName(PROPERTY_SCHEMANAME) ? HAS_SCHEMANAME : 0;
+ m_nColTypeID |= xInfo->hasPropertyByName(PROPERTY_TABLENAME) ? HAS_TABLENAME : 0;
m_xAggregate->getPropertyValue(PROPERTY_NAME) >>= m_sName;
}
@@ -445,15 +455,7 @@ Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNa
const sal_Int32 nHaveAlways = 7;
// Which optional properties are contained?
- sal_Int32 nHaveOptionally = 0;
- if (nId & HAS_DESCRIPTION)
- ++nHaveOptionally;
- if (nId & HAS_DEFAULTVALUE)
- ++nHaveOptionally;
- if (nId & HAS_ROWVERSION)
- ++nHaveOptionally;
- if ( nId & HAS_AUTOINCREMENT_CREATION )
- ++nHaveOptionally;
+ const sal_Int32 nHaveOptionally (::std::bitset<7>(nId).count());
BEGIN_PROPERTY_SEQUENCE( nHaveAlways + nHaveOptionally )
@@ -481,6 +483,18 @@ Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNa
{
DECL_PROP0_BOOL( ISROWVERSION );
}
+ if ( nId & HAS_CATALOGNAME )
+ {
+ DECL_PROP0( CATALOGNAME, ::rtl::OUString );
+ }
+ if ( nId & HAS_SCHEMANAME )
+ {
+ DECL_PROP0( SCHEMANAME, ::rtl::OUString );
+ }
+ if ( nId & HAS_TABLENAME )
+ {
+ DECL_PROP0( TABLENAME, ::rtl::OUString );
+ }
END_PROPERTY_SEQUENCE()
diff --git a/dbaccess/source/core/dataaccess/ContentHelper.cxx b/dbaccess/source/core/dataaccess/ContentHelper.cxx
index 08cdd7e9c7ec..9ef5a1dc3a66 100644
--- a/dbaccess/source/core/dataaccess/ContentHelper.cxx
+++ b/dbaccess/source/core/dataaccess/ContentHelper.cxx
@@ -96,7 +96,7 @@ Reference< XContentIdentifier > SAL_CALL OContentHelper::getIdentifier( ) throw
::rtl::OUStringBuffer aIdentifier;
aIdentifier.appendAscii( "private:" );
aIdentifier.append( impl_getHierarchicalName( true ) );
- return new ::ucbhelper::ContentIdentifier( m_aContext.getLegacyServiceFactory(), aIdentifier.makeStringAndClear() );
+ return new ::ucbhelper::ContentIdentifier( aIdentifier.makeStringAndClear() );
}
::rtl::OUString OContentHelper::impl_getHierarchicalName( bool _includingRootContainer ) const
diff --git a/dbaccess/source/core/dataaccess/ModelImpl.cxx b/dbaccess/source/core/dataaccess/ModelImpl.cxx
index 66745a51e202..2d62e2cfaa32 100644
--- a/dbaccess/source/core/dataaccess/ModelImpl.cxx
+++ b/dbaccess/source/core/dataaccess/ModelImpl.cxx
@@ -32,6 +32,7 @@
#include <com/sun/star/container/XSet.hpp>
#include <com/sun/star/document/MacroExecMode.hpp>
+#include <com/sun/star/frame/GlobalEventBroadcaster.hpp>
#include <com/sun/star/embed/XTransactedObject.hpp>
#include <com/sun/star/embed/XTransactionBroadcaster.hpp>
#include <com/sun/star/sdb/BooleanComparisonMode.hpp>
@@ -976,9 +977,8 @@ Reference< XModel > ODatabaseModelImpl::createNewModel_deliverOwnership( bool _b
try
{
- Reference< XSet > xModelCollection;
- if ( m_aContext.createComponent( "com.sun.star.frame.GlobalEventBroadcaster", xModelCollection ) )
- xModelCollection->insert( makeAny( xModel ) );
+ Reference< XGlobalEventBroadcaster > xModelCollection = GlobalEventBroadcaster::create( m_aContext.getUNOContext() );
+ xModelCollection->insert( makeAny( xModel ) );
}
catch( const Exception& )
{
diff --git a/dbaccess/source/core/dataaccess/databasedocument.cxx b/dbaccess/source/core/dataaccess/databasedocument.cxx
index 83435d826e2c..8f5c6ae6d755 100644
--- a/dbaccess/source/core/dataaccess/databasedocument.cxx
+++ b/dbaccess/source/core/dataaccess/databasedocument.cxx
@@ -52,6 +52,7 @@
#include <com/sun/star/ui/XUIConfigurationStorage.hpp>
#include <com/sun/star/view/XSelectionSupplier.hpp>
#include <com/sun/star/xml/sax/XDocumentHandler.hpp>
+#include <com/sun/star/xml/sax/Writer.hpp>
#include <com/sun/star/ucb/XContent.hpp>
#include <com/sun/star/sdb/DatabaseContext.hpp>
#include <com/sun/star/sdb/application/XDatabaseDocumentUI.hpp>
@@ -1585,10 +1586,7 @@ void ODatabaseDocument::WriteThroughComponent( const Reference< XOutputStream >&
OSL_ENSURE( NULL != pServiceName, "Need component name!" );
// get component
- Reference< XActiveDataSource > xSaxWriter;
- OSL_VERIFY( m_pImpl->m_aContext.createComponent( "com.sun.star.xml.sax.Writer", xSaxWriter ) );
- if ( !xSaxWriter.is() )
- return;
+ Reference< XWriter > xSaxWriter = xml::sax::Writer::create( m_pImpl->m_aContext.getUNOContext() );
// connect XML writer to output stream
xSaxWriter->setOutputStream( xOutputStream );
@@ -2069,7 +2067,7 @@ Reference< XTitle > ODatabaseDocument::impl_getTitleHelper_throw()
UNO_QUERY_THROW );
uno::Reference< frame::XModel > xThis (getThis(), uno::UNO_QUERY_THROW);
- ::framework::TitleHelper* pHelper = new ::framework::TitleHelper(m_pImpl->m_aContext.getLegacyServiceFactory());
+ ::framework::TitleHelper* pHelper = new ::framework::TitleHelper(m_pImpl->m_aContext.getUNOContext());
m_xTitleHelper.set(static_cast< ::cppu::OWeakObject* >(pHelper), uno::UNO_QUERY_THROW);
pHelper->setOwner (xThis );
pHelper->connectWithUntitledNumbers (xDesktop);
diff --git a/dbaccess/source/core/dataaccess/datasource.cxx b/dbaccess/source/core/dataaccess/datasource.cxx
index 3139e2004498..54d7156520fb 100644
--- a/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/dbaccess/source/core/dataaccess/datasource.cxx
@@ -69,6 +69,7 @@
#include <rtl/logfile.hxx>
#include <rtl/digest.h>
#include <algorithm>
+#include <iterator>
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::sdbcx;
diff --git a/dbaccess/source/core/dataaccess/documentdefinition.cxx b/dbaccess/source/core/dataaccess/documentdefinition.cxx
index 5abe8f8bb8d9..47c6cd385292 100644
--- a/dbaccess/source/core/dataaccess/documentdefinition.cxx
+++ b/dbaccess/source/core/dataaccess/documentdefinition.cxx
@@ -1287,10 +1287,9 @@ sal_Bool ODocumentDefinition::save(sal_Bool _bApprove)
pDocuSave = new ODocumentSaveContinuation;
pRequest->addContinuation(pDocuSave);
}
- OInteraction< XInteractionApprove >* pApprove = NULL;
if ( _bApprove )
{
- pApprove = new OInteraction< XInteractionApprove >;
+ OInteraction< XInteractionApprove >* pApprove = new OInteraction< XInteractionApprove >;
pRequest->addContinuation(pApprove);
}
diff --git a/dbaccess/source/core/inc/definitioncolumn.hxx b/dbaccess/source/core/inc/definitioncolumn.hxx
index 6209710757d4..44d198cd431c 100644
--- a/dbaccess/source/core/inc/definitioncolumn.hxx
+++ b/dbaccess/source/core/inc/definitioncolumn.hxx
@@ -158,7 +158,7 @@ namespace dbaccess
OQueryColumn(
const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet>& _rxParserColumn,
const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _rxConnection,
- const ::rtl::OUString i_sLabel
+ const ::rtl::OUString &i_sLabel
);
// XTypeProvider
diff --git a/dbaccess/source/core/recovery/storagexmlstream.cxx b/dbaccess/source/core/recovery/storagexmlstream.cxx
index 14b76e7eedb1..28f3a17ff1b5 100644
--- a/dbaccess/source/core/recovery/storagexmlstream.cxx
+++ b/dbaccess/source/core/recovery/storagexmlstream.cxx
@@ -23,6 +23,7 @@
#include <com/sun/star/xml/sax/XDocumentHandler.hpp>
#include <com/sun/star/io/XActiveDataSource.hpp>
#include <com/sun/star/xml/sax/Parser.hpp>
+#include <com/sun/star/xml/sax/Writer.hpp>
#include <comphelper/componentcontext.hxx>
#include <cppuhelper/implbase1.hxx>
@@ -52,6 +53,8 @@ namespace dbaccess
using ::com::sun::star::embed::XStorage;
using ::com::sun::star::xml::sax::XDocumentHandler;
using ::com::sun::star::xml::sax::XAttributeList;
+ using ::com::sun::star::xml::sax::XWriter;
+ using ::com::sun::star::xml::sax::Writer;
using ::com::sun::star::io::XStream;
using ::com::sun::star::io::XOutputStream;
using ::com::sun::star::io::XActiveDataSource;
@@ -80,7 +83,7 @@ namespace dbaccess
:StorageOutputStream( i_rContext, i_rParentStorage, i_rStreamName )
,m_pData( new StorageXMLOutputStream_Data )
{
- const Reference< XActiveDataSource > xSaxWriter( i_rContext.createComponent( "com.sun.star.xml.sax.Writer" ), UNO_QUERY_THROW );
+ const Reference< XWriter > xSaxWriter = Writer::create( i_rContext.getUNOContext() );
xSaxWriter->setOutputStream( getOutputStream() );
m_pData->xHandler.set( xSaxWriter, UNO_QUERY_THROW );
diff --git a/dbaccess/source/ext/macromigration/migrationengine.cxx b/dbaccess/source/ext/macromigration/migrationengine.cxx
index 3524b6ac271e..cd17f77b3e4d 100644
--- a/dbaccess/source/ext/macromigration/migrationengine.cxx
+++ b/dbaccess/source/ext/macromigration/migrationengine.cxx
@@ -71,6 +71,7 @@
#include <vector>
#include <set>
+#include <iterator>
#define DEFAULT_DOC_PROGRESS_RANGE 100000
diff --git a/dbaccess/source/inc/stringconstants.inc b/dbaccess/source/inc/stringconstants.inc
index 133a06038360..9d6e79e872cb 100644
--- a/dbaccess/source/inc/stringconstants.inc
+++ b/dbaccess/source/inc/stringconstants.inc
@@ -212,7 +212,6 @@ IMPLEMENT_CONSTASCII_USTRING(SERVICE_SDBC_CONNECTIONPOOL, "com.sun.star.sdbc.Con
IMPLEMENT_CONSTASCII_USTRING(SERVICE_SDBCX_INDEXCOLUMN, "com.sun.star.sdbcx.IndexColumn");
IMPLEMENT_CONSTASCII_USTRING(SERVICE_SDBCX_KEYCOLUMN, "com.sun.star.sdbcx.KeyColumn");
IMPLEMENT_CONSTASCII_USTRING(SERVICE_FRAME_DESKTOP, "com.sun.star.frame.Desktop");
-IMPLEMENT_CONSTASCII_USTRING(SERVICE_UI_FOLDERPICKER, "com.sun.star.ui.dialogs.FolderPicker");
IMPLEMENT_CONSTASCII_USTRING(SERVICE_I18N_COLLATOR, "com.sun.star.i18n.Collator");
IMPLEMENT_CONSTASCII_USTRING(SERVICE_SDB_TABLEDEFINITION, "com.sun.star.sdb.TableDefinition");
IMPLEMENT_CONSTASCII_USTRING(SERVICE_SDB_COMMAND_DEFINITION, "com.sun.star.sdb.CommandDefinition");
diff --git a/dbaccess/source/ui/app/AppController.cxx b/dbaccess/source/ui/app/AppController.cxx
index 72520aa7e42f..bf46021f7237 100644
--- a/dbaccess/source/ui/app/AppController.cxx
+++ b/dbaccess/source/ui/app/AppController.cxx
@@ -2436,7 +2436,7 @@ Any OApplicationController::getCurrentSelection( Control& _rControl ) const
}
// -----------------------------------------------------------------------------
-sal_Bool OApplicationController::requestQuickHelp( const SvLBoxEntry* /*_pEntry*/, String& /*_rText*/ ) const
+sal_Bool OApplicationController::requestQuickHelp( const SvTreeListEntry* /*_pEntry*/, String& /*_rText*/ ) const
{
return sal_False;
}
@@ -2485,7 +2485,7 @@ sal_Int8 OApplicationController::queryDrop( const AcceptDropEvent& _rEvt, const
sal_Int8 nAction = OComponentTransferable::canExtractComponentDescriptor(_rFlavors,eType == E_FORM) ? DND_ACTION_COPY : DND_ACTION_NONE;
if ( nAction != DND_ACTION_NONE )
{
- SvLBoxEntry* pHitEntry = pView->getEntry(_rEvt.maPosPixel);
+ SvTreeListEntry* pHitEntry = pView->getEntry(_rEvt.maPosPixel);
::rtl::OUString sName;
if ( pHitEntry )
{
@@ -2553,7 +2553,7 @@ sal_Int8 OApplicationController::executeDrop( const ExecuteDropEvent& _rEvt )
else if ( OComponentTransferable::canExtractComponentDescriptor(aDroppedData.GetDataFlavorExVector(),m_aAsyncDrop.nType == E_FORM) )
{
m_aAsyncDrop.aDroppedData = OComponentTransferable::extractComponentDescriptor(aDroppedData);
- SvLBoxEntry* pHitEntry = pView->getEntry(_rEvt.maPosPixel);
+ SvTreeListEntry* pHitEntry = pView->getEntry(_rEvt.maPosPixel);
if ( pHitEntry )
m_aAsyncDrop.aUrl = pView->getQualifiedName( pHitEntry );
diff --git a/dbaccess/source/ui/app/AppController.hxx b/dbaccess/source/ui/app/AppController.hxx
index 3f0eb1ab9ff9..6cdb65c2cf29 100644
--- a/dbaccess/source/ui/app/AppController.hxx
+++ b/dbaccess/source/ui/app/AppController.hxx
@@ -47,7 +47,7 @@
#include <memory>
-class SvLBoxEntry;
+class SvTreeListEntry;
class SvTreeListBox;
class TransferableHelper;
class TransferableClipboardListener;
@@ -523,7 +523,7 @@ namespace dbaui
virtual bool interceptUserInput( const NotifyEvent& _rEvent );
// IControlActionListener overridables
- virtual sal_Bool requestQuickHelp( const SvLBoxEntry* _pEntry, String& _rText ) const;
+ virtual sal_Bool requestQuickHelp( const SvTreeListEntry* _pEntry, String& _rText ) const;
virtual sal_Bool requestDrag( sal_Int8 _nAction, const Point& _rPosPixel );
virtual sal_Int8 queryDrop( const AcceptDropEvent& _rEvt, const DataFlavorExVector& _rFlavors );
virtual sal_Int8 executeDrop( const ExecuteDropEvent& _rEvt );
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.cxx b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
index 1f827f31b1bf..dfcea23ffa12 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.cxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
@@ -88,13 +88,13 @@ namespace dbaui
namespace
{
- SvLBoxEntry* lcl_findEntry_impl(DBTreeListBox& rTree,const ::rtl::OUString& _rName,SvLBoxEntry* _pFirst)
+ SvTreeListEntry* lcl_findEntry_impl(DBTreeListBox& rTree,const ::rtl::OUString& _rName,SvTreeListEntry* _pFirst)
{
- SvLBoxEntry* pReturn = NULL;
+ SvTreeListEntry* pReturn = NULL;
sal_Int32 nIndex = 0;
String sName( _rName.getToken(0,'/',nIndex) );
- SvLBoxEntry* pEntry = _pFirst;
+ SvTreeListEntry* pEntry = _pFirst;
while( pEntry )
{
if ( rTree.GetEntryText(pEntry) == sName )
@@ -115,7 +115,7 @@ namespace
}
return pReturn;
}
- SvLBoxEntry* lcl_findEntry(DBTreeListBox& rTree,const ::rtl::OUString& _rName,SvLBoxEntry* _pFirst)
+ SvTreeListEntry* lcl_findEntry(DBTreeListBox& rTree,const ::rtl::OUString& _rName,SvTreeListEntry* _pFirst)
{
sal_Int32 nIndex = 0;
::rtl::OUString sErase = _rName.getToken(0,'/',nIndex); // we don't want to have the "private:forms" part
@@ -286,7 +286,7 @@ void OAppDetailPageHelper::selectAll()
void OAppDetailPageHelper::sort(int _nPos,SvSortMode _eSortMode )
{
OSL_ENSURE(m_pLists[_nPos],"List can not be NULL! ->GPF");
- SvLBoxTreeList* pModel = m_pLists[_nPos]->GetModel();
+ SvTreeList* pModel = m_pLists[_nPos]->GetModel();
SvSortMode eOldSortMode = pModel->GetSortMode();
pModel->SetSortMode(_eSortMode);
if ( eOldSortMode != _eSortMode )
@@ -299,7 +299,7 @@ sal_Bool OAppDetailPageHelper::isSortUp() const
int nPos = getVisibleControlIndex();
if ( nPos < E_ELEMENT_TYPE_COUNT )
{
- SvLBoxTreeList* pModel = m_pLists[nPos]->GetModel();
+ SvTreeList* pModel = m_pLists[nPos]->GetModel();
eSortMode = pModel->GetSortMode();
}
return eSortMode == SortAscending;
@@ -327,7 +327,7 @@ void OAppDetailPageHelper::getSelectionElementNames( ::std::vector< ::rtl::OUStr
DBTreeListBox& rTree = *m_pLists[nPos];
sal_Int32 nCount = rTree.GetEntryCount();
_rNames.reserve(nCount);
- SvLBoxEntry* pEntry = rTree.FirstSelected();
+ SvTreeListEntry* pEntry = rTree.FirstSelected();
ElementType eType = getElementType();
while( pEntry )
{
@@ -339,7 +339,7 @@ void OAppDetailPageHelper::getSelectionElementNames( ::std::vector< ::rtl::OUStr
else
{
::rtl::OUString sName = rTree.GetEntryText(pEntry);
- SvLBoxEntry* pParent = rTree.GetParent(pEntry);
+ SvTreeListEntry* pParent = rTree.GetParent(pEntry);
while(pParent)
{
sName = rTree.GetEntryText(pParent) + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sName;
@@ -379,7 +379,7 @@ void OAppDetailPageHelper::describeCurrentSelectionForType( const ElementType _e
::std::vector< NamedDatabaseObject > aSelected;
- SvLBoxEntry* pEntry = pList->FirstSelected();
+ SvTreeListEntry* pEntry = pList->FirstSelected();
while( pEntry )
{
NamedDatabaseObject aObject;
@@ -400,7 +400,7 @@ void OAppDetailPageHelper::describeCurrentSelectionForType( const ElementType _e
case E_REPORT:
{
::rtl::OUString sName = pList->GetEntryText(pEntry);
- SvLBoxEntry* pParent = pList->GetParent(pEntry);
+ SvTreeListEntry* pParent = pList->GetParent(pEntry);
while ( pParent )
{
::rtl::OUStringBuffer buffer;
@@ -448,14 +448,14 @@ void OAppDetailPageHelper::selectElements(const Sequence< ::rtl::OUString>& _aNa
const ::rtl::OUString* pEnd = pIter + _aNames.getLength();
for(;pIter != pEnd;++pIter)
{
- SvLBoxEntry* pEntry = rTree.GetEntryPosByName(*pIter);
+ SvTreeListEntry* pEntry = rTree.GetEntryPosByName(*pIter);
if ( pEntry )
rTree.Select(pEntry);
}
}
}
// -----------------------------------------------------------------------------
-::rtl::OUString OAppDetailPageHelper::getQualifiedName( SvLBoxEntry* _pEntry ) const
+::rtl::OUString OAppDetailPageHelper::getQualifiedName( SvTreeListEntry* _pEntry ) const
{
int nPos = getVisibleControlIndex();
::rtl::OUString sComposedName;
@@ -466,7 +466,7 @@ void OAppDetailPageHelper::selectElements(const Sequence< ::rtl::OUString>& _aNa
OSL_ENSURE(m_pLists[nPos],"Tables tree view is NULL! -> GPF");
DBTreeListBox& rTree = *m_pLists[nPos];
- SvLBoxEntry* pEntry = _pEntry;
+ SvTreeListEntry* pEntry = _pEntry;
if ( !pEntry )
pEntry = rTree.FirstSelected();
@@ -481,7 +481,7 @@ void OAppDetailPageHelper::selectElements(const Sequence< ::rtl::OUString>& _aNa
else
{
sComposedName = rTree.GetEntryText(pEntry);
- SvLBoxEntry* pParent = rTree.GetParent(pEntry);
+ SvTreeListEntry* pParent = rTree.GetParent(pEntry);
while(pParent)
{
sComposedName = rTree.GetEntryText(pParent) + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sComposedName;
@@ -505,7 +505,7 @@ sal_Int32 OAppDetailPageHelper::getSelectionCount()
if ( nPos < E_ELEMENT_TYPE_COUNT )
{
DBTreeListBox& rTree = *m_pLists[nPos];
- SvLBoxEntry* pEntry = rTree.FirstSelected();
+ SvTreeListEntry* pEntry = rTree.FirstSelected();
while( pEntry )
{
++nCount;
@@ -553,7 +553,7 @@ void OAppDetailPageHelper::paste()
{
}
// -----------------------------------------------------------------------------
-bool OAppDetailPageHelper::isLeaf(SvLBoxEntry* _pEntry) const
+bool OAppDetailPageHelper::isLeaf(SvTreeListEntry* _pEntry) const
{
if ( !_pEntry )
return false;
@@ -577,7 +577,7 @@ sal_Bool OAppDetailPageHelper::isALeafSelected() const
if ( nPos < E_ELEMENT_TYPE_COUNT )
{
DBTreeListBox& rTree = *m_pLists[nPos];
- SvLBoxEntry* pEntry = rTree.FirstSelected( );
+ SvTreeListEntry* pEntry = rTree.FirstSelected( );
while( !bLeafSelected && pEntry )
{
bLeafSelected = isLeaf( pEntry );
@@ -587,9 +587,9 @@ sal_Bool OAppDetailPageHelper::isALeafSelected() const
return bLeafSelected;
}
// -----------------------------------------------------------------------------
-SvLBoxEntry* OAppDetailPageHelper::getEntry( const Point& _aPosPixel) const
+SvTreeListEntry* OAppDetailPageHelper::getEntry( const Point& _aPosPixel) const
{
- SvLBoxEntry* pReturn = NULL;
+ SvTreeListEntry* pReturn = NULL;
int nPos = getVisibleControlIndex();
if ( nPos < E_ELEMENT_TYPE_COUNT )
pReturn = m_pLists[nPos]->GetEntry( _aPosPixel,sal_True );
@@ -621,7 +621,7 @@ void OAppDetailPageHelper::createTablesPage(const Reference< XConnection>& _xCon
{
static_cast<OTableTreeListBox*>(m_pLists[E_TABLE])->UpdateTableList(_xConnection);
- SvLBoxEntry* pEntry = m_pLists[E_TABLE]->First();
+ SvTreeListEntry* pEntry = m_pLists[E_TABLE]->First();
if ( pEntry )
m_pLists[E_TABLE]->Expand(pEntry);
m_pLists[E_TABLE]->SelectAll(sal_False);
@@ -734,7 +734,7 @@ namespace
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContainer, const ElementType _eType,
- const sal_uInt16 _nImageId, SvLBoxEntry* _pParent )
+ const sal_uInt16 _nImageId, SvTreeListEntry* _pParent )
{
OSL_ENSURE(_xContainer.is(),"Data source is NULL! -> GPF");
OSL_ENSURE( ( _eType >= E_TABLE ) && ( _eType < E_ELEMENT_TYPE_COUNT ), "OAppDetailPageHelper::fillNames: invalid type!" );
@@ -753,7 +753,7 @@ void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContaine
const ::rtl::OUString* pEnd = pIter + aSeq.getLength();
for(;pIter != pEnd;++pIter)
{
- SvLBoxEntry* pEntry = NULL;
+ SvTreeListEntry* pEntry = NULL;
Reference<XNameAccess> xSubElements(_xContainer->getByName(*pIter),UNO_QUERY);
if ( xSubElements.is() )
{
@@ -834,7 +834,7 @@ void OAppDetailPageHelper::elementReplaced(ElementType _eType
if ( pTreeView )
{
::rtl::OUString sNewName = _rNewName;
- SvLBoxEntry* pEntry = NULL;
+ SvTreeListEntry* pEntry = NULL;
switch( _eType )
{
case E_TABLE:
@@ -860,9 +860,9 @@ void OAppDetailPageHelper::elementReplaced(ElementType _eType
}
}
// -----------------------------------------------------------------------------
-SvLBoxEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const ::rtl::OUString& _rName, const Any& _rObject )
+SvTreeListEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const ::rtl::OUString& _rName, const Any& _rObject )
{
- SvLBoxEntry* pRet = NULL;
+ SvTreeListEntry* pRet = NULL;
DBTreeListBox* pTreeView = m_pLists[_eType];
if( _eType == E_TABLE && pTreeView )
{
@@ -871,7 +871,7 @@ SvLBoxEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const ::rtl::
else if ( pTreeView )
{
- SvLBoxEntry* pEntry = NULL;
+ SvTreeListEntry* pEntry = NULL;
Reference<XChild> xChild(_rObject,UNO_QUERY);
if ( xChild.is() && E_QUERY != _eType )
{
@@ -918,7 +918,7 @@ void OAppDetailPageHelper::elementRemoved( ElementType _eType,const ::rtl::OUStr
case E_QUERY:
if ( pTreeView )
{
- SvLBoxEntry* pEntry = lcl_findEntry_impl(*pTreeView,_rName,pTreeView->First());
+ SvTreeListEntry* pEntry = lcl_findEntry_impl(*pTreeView,_rName,pTreeView->First());
if ( pEntry )
pTreeView->GetModel()->Remove(pEntry);
}
@@ -928,7 +928,7 @@ void OAppDetailPageHelper::elementRemoved( ElementType _eType,const ::rtl::OUStr
{
if ( pTreeView )
{
- SvLBoxEntry* pEntry = lcl_findEntry(*pTreeView,_rName,pTreeView->First());
+ SvTreeListEntry* pEntry = lcl_findEntry(*pTreeView,_rName,pTreeView->First());
if ( pEntry )
pTreeView->GetModel()->Remove(pEntry);
}
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.hxx b/dbaccess/source/ui/app/AppDetailPageHelper.hxx
index 8b34d8c4a6ff..ba3971f930d4 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.hxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.hxx
@@ -125,7 +125,7 @@ namespace dbaui
void fillNames( const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _xContainer,
const ElementType _eType,
const sal_uInt16 _nImageId,
- SvLBoxEntry* _pParent );
+ SvTreeListEntry* _pParent );
/** sets the detail page
@param _pWindow
@@ -250,7 +250,7 @@ namespace dbaui
@return
the qualified name
*/
- ::rtl::OUString getQualifiedName( SvLBoxEntry* _pEntry ) const;
+ ::rtl::OUString getQualifiedName( SvTreeListEntry* _pEntry ) const;
/// return the element of currently select entry
ElementType getElementType() const;
@@ -267,7 +267,7 @@ namespace dbaui
@return
<TRUE/> if the entry is a leaf, otherwise <FALSE/>
*/
- bool isLeaf(SvLBoxEntry* _pEntry) const;
+ bool isLeaf(SvTreeListEntry* _pEntry) const;
/** returns if one of the selected entries is a leaf
@return
@@ -275,7 +275,7 @@ namespace dbaui
*/
sal_Bool isALeafSelected() const;
- SvLBoxEntry* getEntry( const Point& _aPosPixel ) const;
+ SvTreeListEntry* getEntry( const Point& _aPosPixel ) const;
/// clears the detail pages
void clearPages();
@@ -293,7 +293,7 @@ namespace dbaui
@param _rxConn
If we insert a table, the connection must be set.
*/
- SvLBoxEntry* elementAdded(ElementType eType
+ SvTreeListEntry* elementAdded(ElementType eType
,const ::rtl::OUString& _rName
,const ::com::sun::star::uno::Any& _rObject );
diff --git a/dbaccess/source/ui/app/AppDetailView.cxx b/dbaccess/source/ui/app/AppDetailView.cxx
index 7ebc0993aa64..d3da7bbf5c0d 100644
--- a/dbaccess/source/ui/app/AppDetailView.cxx
+++ b/dbaccess/source/ui/app/AppDetailView.cxx
@@ -98,7 +98,7 @@ void OCreationList::Paint( const Rectangle& _rRect )
}
// -----------------------------------------------------------------------------
-void OCreationList::PreparePaint( SvLBoxEntry* _pEntry )
+void OCreationList::PreparePaint( SvTreeListEntry* _pEntry )
{
Wallpaper aEntryBackground( m_aOriginalBackgroundColor );
if ( _pEntry )
@@ -128,7 +128,7 @@ void OCreationList::PreparePaint( SvLBoxEntry* _pEntry )
// -----------------------------------------------------------------------------
void OCreationList::SelectSearchEntry( const void* _pEntry )
{
- SvLBoxEntry* pEntry = const_cast< SvLBoxEntry* >( static_cast< const SvLBoxEntry* >( _pEntry ) );
+ SvTreeListEntry* pEntry = const_cast< SvTreeListEntry* >( static_cast< const SvTreeListEntry* >( _pEntry ) );
OSL_ENSURE( pEntry, "OCreationList::SelectSearchEntry: invalid entry!" );
if ( pEntry )
@@ -141,7 +141,7 @@ void OCreationList::SelectSearchEntry( const void* _pEntry )
// -----------------------------------------------------------------------------
void OCreationList::ExecuteSearchEntry( const void* _pEntry ) const
{
- SvLBoxEntry* pEntry = const_cast< SvLBoxEntry* >( static_cast< const SvLBoxEntry* >( _pEntry ) );
+ SvTreeListEntry* pEntry = const_cast< SvTreeListEntry* >( static_cast< const SvTreeListEntry* >( _pEntry ) );
OSL_ENSURE( pEntry, "OCreationList::ExecuteSearchEntry: invalid entry!" );
OSL_ENSURE( pEntry == GetCurEntry(), "OCreationList::ExecuteSearchEntry: SelectSearchEntry should have been called before!" );
@@ -150,7 +150,7 @@ void OCreationList::ExecuteSearchEntry( const void* _pEntry ) const
}
// -----------------------------------------------------------------------------
-Rectangle OCreationList::GetFocusRect( SvLBoxEntry* _pEntry, long _nLine )
+Rectangle OCreationList::GetFocusRect( SvTreeListEntry* _pEntry, long _nLine )
{
Rectangle aRect = SvTreeListBox::GetFocusRect( _pEntry, _nLine );
aRect.Left() = 0;
@@ -220,7 +220,7 @@ void OCreationList::MouseMove( const MouseEvent& rMEvt )
}
else if ( !rMEvt.IsSynthetic() )
{
- SvLBoxEntry* pEntry = GetEntry( rMEvt.GetPosPixel() );
+ SvTreeListEntry* pEntry = GetEntry( rMEvt.GetPosPixel() );
if ( m_pMouseDownEntry )
{
@@ -253,7 +253,7 @@ void OCreationList::MouseMove( const MouseEvent& rMEvt )
// -----------------------------------------------------------------------------
void OCreationList::MouseButtonUp( const MouseEvent& rMEvt )
{
- SvLBoxEntry* pEntry = GetEntry( rMEvt.GetPosPixel() );
+ SvTreeListEntry* pEntry = GetEntry( rMEvt.GetPosPixel() );
bool bExecute = false;
// Was the mouse released over the active entry?
// (i.e. the entry which was under the mouse when the button went down)
@@ -278,7 +278,7 @@ void OCreationList::MouseButtonUp( const MouseEvent& rMEvt )
onSelected( pEntry );
}
// -----------------------------------------------------------------------------
-bool OCreationList::setCurrentEntryInvalidate( SvLBoxEntry* _pEntry )
+bool OCreationList::setCurrentEntryInvalidate( SvTreeListEntry* _pEntry )
{
if ( GetCurEntry() != _pEntry )
{
@@ -304,7 +304,7 @@ void OCreationList::updateHelpText()
m_rTaskWindow.setHelpText( nHelpTextId );
}
// -----------------------------------------------------------------------------
-void OCreationList::onSelected( SvLBoxEntry* _pEntry ) const
+void OCreationList::onSelected( SvTreeListEntry* _pEntry ) const
{
OSL_ENSURE( _pEntry, "OCreationList::onSelected: invalid entry!" );
URL aCommand;
@@ -319,15 +319,15 @@ void OCreationList::KeyInput( const KeyEvent& rKEvt )
{
if ( rCode.GetCode() == KEY_RETURN )
{
- SvLBoxEntry* pEntry = GetCurEntry() ? GetCurEntry() : FirstSelected();
+ SvTreeListEntry* pEntry = GetCurEntry() ? GetCurEntry() : FirstSelected();
if ( pEntry )
onSelected( pEntry );
return;
}
}
- SvLBoxEntry* pOldCurrent = GetCurEntry();
+ SvTreeListEntry* pOldCurrent = GetCurEntry();
SvTreeListBox::KeyInput(rKEvt);
- SvLBoxEntry* pNewCurrent = GetCurEntry();
+ SvTreeListEntry* pNewCurrent = GetCurEntry();
if ( pOldCurrent != pNewCurrent )
{
@@ -439,7 +439,7 @@ void OTasksWindow::setHelpText(sal_uInt16 _nId)
IMPL_LINK(OTasksWindow, OnEntrySelectHdl, SvTreeListBox*, /*_pTreeBox*/)
{
DBG_CHKTHIS(OTasksWindow,NULL);
- SvLBoxEntry* pEntry = m_aCreation.GetHdlEntry();
+ SvTreeListEntry* pEntry = m_aCreation.GetHdlEntry();
if ( pEntry )
m_aHelpText.SetText( ModuleRes( reinterpret_cast< TaskEntry* >( pEntry->GetUserData() )->nHelpID ) );
return 1L;
@@ -498,7 +498,7 @@ void OTasksWindow::fillTaskEntryList( const TaskEntryList& _rList )
for ( TaskEntryList::const_iterator pTask = _rList.begin(); pTask != aEnd; ++pTask, ++pImages )
{
- SvLBoxEntry* pEntry = m_aCreation.InsertEntry( pTask->sTitle );
+ SvTreeListEntry* pEntry = m_aCreation.InsertEntry( pTask->sTitle );
pEntry->SetUserData( reinterpret_cast< void* >( new TaskEntry( *pTask ) ) );
Image aImage = Image( *pImages );
@@ -523,7 +523,7 @@ void OTasksWindow::Clear()
{
DBG_CHKTHIS(OTasksWindow,NULL);
m_aCreation.resetLastActive();
- SvLBoxEntry* pEntry = m_aCreation.First();
+ SvTreeListEntry* pEntry = m_aCreation.First();
while ( pEntry )
{
delete reinterpret_cast< TaskEntry* >( pEntry->GetUserData() );
@@ -764,13 +764,13 @@ void OApplicationDetailView::impl_fillTaskPaneData( ElementType _eType, TaskPane
}
// -----------------------------------------------------------------------------
-::rtl::OUString OApplicationDetailView::getQualifiedName( SvLBoxEntry* _pEntry ) const
+::rtl::OUString OApplicationDetailView::getQualifiedName( SvTreeListEntry* _pEntry ) const
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
return m_pControlHelper->getQualifiedName( _pEntry );
}
// -----------------------------------------------------------------------------
-sal_Bool OApplicationDetailView::isLeaf(SvLBoxEntry* _pEntry) const
+sal_Bool OApplicationDetailView::isLeaf(SvTreeListEntry* _pEntry) const
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
return m_pControlHelper->isLeaf(_pEntry);
@@ -857,7 +857,7 @@ void OApplicationDetailView::selectElements(const Sequence< ::rtl::OUString>& _a
m_pControlHelper->selectElements( _aNames );
}
// -----------------------------------------------------------------------------
-SvLBoxEntry* OApplicationDetailView::getEntry( const Point& _aPoint ) const
+SvTreeListEntry* OApplicationDetailView::getEntry( const Point& _aPoint ) const
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
return m_pControlHelper->getEntry(_aPoint);
@@ -882,7 +882,7 @@ void OApplicationDetailView::paste()
m_pControlHelper->paste();
}
// -----------------------------------------------------------------------------
-SvLBoxEntry* OApplicationDetailView::elementAdded(ElementType _eType,const ::rtl::OUString& _rName, const Any& _rObject )
+SvTreeListEntry* OApplicationDetailView::elementAdded(ElementType _eType,const ::rtl::OUString& _rName, const Any& _rObject )
{
DBG_CHKTHIS(OApplicationDetailView,NULL);
return m_pControlHelper->elementAdded(_eType,_rName, _rObject );
diff --git a/dbaccess/source/ui/app/AppDetailView.hxx b/dbaccess/source/ui/app/AppDetailView.hxx
index 220b31f10f2a..f8bb55627901 100644
--- a/dbaccess/source/ui/app/AppDetailView.hxx
+++ b/dbaccess/source/ui/app/AppDetailView.hxx
@@ -35,7 +35,7 @@
#include <vector>
-class SvLBoxEntry;
+class SvTreeListEntry;
namespace dbaui
{
@@ -49,8 +49,8 @@ namespace dbaui
OTasksWindow& m_rTaskWindow;
// members related to drawing the currently hovered/selected entry
- SvLBoxEntry* m_pMouseDownEntry;
- SvLBoxEntry* m_pLastActiveEntry;
+ SvTreeListEntry* m_pMouseDownEntry;
+ SvTreeListEntry* m_pLastActiveEntry;
Color m_aOriginalBackgroundColor;
Font m_aOriginalFont;
@@ -71,8 +71,8 @@ namespace dbaui
void updateHelpText();
protected:
- virtual void PreparePaint( SvLBoxEntry* _pEntry );
- virtual Rectangle GetFocusRect( SvLBoxEntry* _pEntry, long _nLine );
+ virtual void PreparePaint( SvTreeListEntry* _pEntry );
+ virtual Rectangle GetFocusRect( SvTreeListEntry* _pEntry, long _nLine );
virtual void ModelHasCleared();
// IMnemonicEntryList
@@ -80,11 +80,11 @@ namespace dbaui
virtual void ExecuteSearchEntry( const void* _pEntry ) const;
private:
- void onSelected( SvLBoxEntry* _pEntry ) const;
+ void onSelected( SvTreeListEntry* _pEntry ) const;
/** sets a new current entry, and invalidates the old and the new one, if necessary
@return <TRUE/> if and only if the "current entry" changed
*/
- bool setCurrentEntryInvalidate( SvLBoxEntry* _pEntry );
+ bool setCurrentEntryInvalidate( SvTreeListEntry* _pEntry );
};
struct TaskEntry
@@ -206,7 +206,7 @@ namespace dbaui
@return
the qualified name
*/
- ::rtl::OUString getQualifiedName( SvLBoxEntry* _pEntry ) const;
+ ::rtl::OUString getQualifiedName( SvTreeListEntry* _pEntry ) const;
/** returns if an entry is a leaf
@param _pEntry
@@ -214,7 +214,7 @@ namespace dbaui
@return
<TRUE/> if the entry is a leaf, otherwise <FALSE/>
*/
- sal_Bool isLeaf(SvLBoxEntry* _pEntry) const;
+ sal_Bool isLeaf(SvTreeListEntry* _pEntry) const;
/** returns if one of the selected entries is a leaf
@return
@@ -289,7 +289,7 @@ namespace dbaui
@param _rxConn
If we insert a table, the connection must be set.
*/
- SvLBoxEntry* elementAdded(ElementType eType
+ SvTreeListEntry* elementAdded(ElementType eType
,const ::rtl::OUString& _rName
,const ::com::sun::star::uno::Any& _rObject );
@@ -352,7 +352,7 @@ namespace dbaui
const ::rtl::OUString& _sName,
sal_Bool _bTable);
- SvLBoxEntry* getEntry( const Point& _aPoint ) const;
+ SvTreeListEntry* getEntry( const Point& _aPoint ) const;
Window* getTreeWindow() const;
private:
diff --git a/dbaccess/source/ui/app/AppView.cxx b/dbaccess/source/ui/app/AppView.cxx
index 69658324ed40..3e3469d7ce11 100644
--- a/dbaccess/source/ui/app/AppView.cxx
+++ b/dbaccess/source/ui/app/AppView.cxx
@@ -362,13 +362,13 @@ void OApplicationView::paste()
pTest->paste();
}
// -----------------------------------------------------------------------------
-::rtl::OUString OApplicationView::getQualifiedName( SvLBoxEntry* _pEntry ) const
+::rtl::OUString OApplicationView::getQualifiedName( SvTreeListEntry* _pEntry ) const
{
OSL_ENSURE(m_pWin && getDetailView(),"Detail view is NULL! -> GPF");
return getDetailView()->getQualifiedName( _pEntry );
}
// -----------------------------------------------------------------------------
-sal_Bool OApplicationView::isLeaf(SvLBoxEntry* _pEntry) const
+sal_Bool OApplicationView::isLeaf(SvTreeListEntry* _pEntry) const
{
OSL_ENSURE(m_pWin && getDetailView(),"Detail view is NULL! -> GPF");
return getDetailView()->isLeaf(_pEntry);
@@ -452,7 +452,7 @@ void OApplicationView::selectElements(const Sequence< ::rtl::OUString>& _aNames)
getDetailView()->selectElements( _aNames );
}
// -----------------------------------------------------------------------------
-SvLBoxEntry* OApplicationView::elementAdded(ElementType eType,const ::rtl::OUString& _rName, const Any& _rObject )
+SvTreeListEntry* OApplicationView::elementAdded(ElementType eType,const ::rtl::OUString& _rName, const Any& _rObject )
{
OSL_ENSURE(m_pWin && getDetailView(),"Detail view is NULL! -> GPF");
return getDetailView()->elementAdded(eType,_rName,_rObject);
@@ -486,7 +486,7 @@ void OApplicationView::selectContainer(ElementType _eType)
getPanel()->selectContainer(_eType);
}
// -----------------------------------------------------------------------------
-SvLBoxEntry* OApplicationView::getEntry( const Point& _aPosPixel ) const
+SvTreeListEntry* OApplicationView::getEntry( const Point& _aPosPixel ) const
{
OSL_ENSURE(m_pWin && getDetailView(),"Detail view is NULL! -> GPF");
return getDetailView()->getEntry(_aPosPixel);
diff --git a/dbaccess/source/ui/app/AppView.hxx b/dbaccess/source/ui/app/AppView.hxx
index f9d0940d0252..ab2c3ff50452 100644
--- a/dbaccess/source/ui/app/AppView.hxx
+++ b/dbaccess/source/ui/app/AppView.hxx
@@ -32,7 +32,7 @@
namespace com{ namespace sun { namespace star { namespace beans { class XPropertySet; } } } }
class Control;
-class SvLBoxEntry;
+class SvTreeListEntry;
class MnemonicGenerator;
namespace dbaui
@@ -141,7 +141,7 @@ namespace dbaui
@return
the qualified name
*/
- ::rtl::OUString getQualifiedName( SvLBoxEntry* _pEntry ) const;
+ ::rtl::OUString getQualifiedName( SvTreeListEntry* _pEntry ) const;
/** returns if an entry is a leaf
@param _pEntry
@@ -149,7 +149,7 @@ namespace dbaui
@return
<TRUE/> if the entry is a leaf, otherwise <FALSE/>
*/
- sal_Bool isLeaf(SvLBoxEntry* _pEntry) const;
+ sal_Bool isLeaf(SvTreeListEntry* _pEntry) const;
/** returns if one of the selected entries is a leaf
@return
@@ -224,7 +224,7 @@ namespace dbaui
@param _rxConn
If we insert a table, the connection must be set.
*/
- SvLBoxEntry* elementAdded(ElementType _eType
+ SvTreeListEntry* elementAdded(ElementType _eType
,const ::rtl::OUString& _rName
,const ::com::sun::star::uno::Any& _rObject );
@@ -296,7 +296,7 @@ namespace dbaui
const ::rtl::OUString& _sName,
sal_Bool _bTable);
- SvLBoxEntry* getEntry( const Point& _aPosPixel ) const;
+ SvTreeListEntry* getEntry( const Point& _aPosPixel ) const;
};
}
#endif // DBAUI_APPVIEW_HXX
diff --git a/dbaccess/source/ui/browser/brwctrlr.cxx b/dbaccess/source/ui/browser/brwctrlr.cxx
index 460b09354860..8fec4ff329c1 100644
--- a/dbaccess/source/ui/browser/brwctrlr.cxx
+++ b/dbaccess/source/ui/browser/brwctrlr.cxx
@@ -1923,7 +1923,7 @@ void SbaXDataBrowserController::ExecuteFilterSortCrit(sal_Bool bFilter)
Reference< XConnection> xCon(xFormSet->getPropertyValue(PROPERTY_ACTIVE_CONNECTION),UNO_QUERY);
if(bFilter)
{
- DlgFilterCrit aDlg( getBrowserView(), getORB(), xCon, xParser, xSup->getColumns() );
+ DlgFilterCrit aDlg( getBrowserView(), comphelper::getComponentContext(getORB()), xCon, xParser, xSup->getColumns() );
String aFilter;
if ( !aDlg.Execute() )
return; // if so we don't need to update the grid
diff --git a/dbaccess/source/ui/browser/dbtreeview.cxx b/dbaccess/source/ui/browser/dbtreeview.cxx
index 6f26f6c063f3..91ee108c47c7 100644
--- a/dbaccess/source/ui/browser/dbtreeview.cxx
+++ b/dbaccess/source/ui/browser/dbtreeview.cxx
@@ -85,7 +85,7 @@ void DBTreeView::Resize()
m_pTreeListBox->SetPosSizePixel(Point(0,0),GetOutputSizePixel());
}
// -------------------------------------------------------------------------
-void DBTreeView::setModel(SvLBoxTreeList* _pTreeModel)
+void DBTreeView::setModel(SvTreeList* _pTreeModel)
{
if (_pTreeModel)
_pTreeModel->InsertView(m_pTreeListBox);
diff --git a/dbaccess/source/ui/browser/dbtreeview.hxx b/dbaccess/source/ui/browser/dbtreeview.hxx
index dd6af234a43a..c54cf39ae8da 100644
--- a/dbaccess/source/ui/browser/dbtreeview.hxx
+++ b/dbaccess/source/ui/browser/dbtreeview.hxx
@@ -24,7 +24,7 @@
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-class SvLBoxTreeList;
+class SvTreeList;
namespace dbaui
{
class DBTreeListBox;
@@ -47,7 +47,7 @@ namespace dbaui
~DBTreeView();
/** sets a handler which is called when an list box entry is to be expanded.
- <p>When calling the link, the parameter is an SvLBoxEntry marking the entry to be expanded.
+ <p>When calling the link, the parameter is an SvTreeListEntry marking the entry to be expanded.
</p>
*/
void SetPreExpandHandler(const Link& _rHdl);
@@ -56,7 +56,7 @@ namespace dbaui
void setCopyHandler(const Link& _rHdl);
- void setModel(SvLBoxTreeList* _pTreeModel);
+ void setModel(SvTreeList* _pTreeModel);
void setSelChangeHdl(const Link& _rHdl);
DBTreeListBox& getListBox() const { return *m_pTreeListBox; }
diff --git a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
index dcf9a2034430..e425c557dfdc 100644
--- a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
+++ b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
@@ -37,7 +37,7 @@ namespace dbaui
{
// .........................................................................
// -----------------------------------------------------------------------------
-SbaTableQueryBrowser::EntryType SbaTableQueryBrowser::getChildType( SvLBoxEntry* _pEntry ) const
+SbaTableQueryBrowser::EntryType SbaTableQueryBrowser::getChildType( SvTreeListEntry* _pEntry ) const
{
OSL_ENSURE(isContainer(_pEntry), "SbaTableQueryBrowser::getChildType: invalid entry!");
switch (getEntryType(_pEntry))
@@ -53,21 +53,21 @@ SbaTableQueryBrowser::EntryType SbaTableQueryBrowser::getChildType( SvLBoxEntry*
}
// -----------------------------------------------------------------------------
-String SbaTableQueryBrowser::GetEntryText( SvLBoxEntry* _pEntry ) const
+String SbaTableQueryBrowser::GetEntryText( SvTreeListEntry* _pEntry ) const
{
return m_pTreeView->getListBox().GetEntryText(_pEntry);
}
// -----------------------------------------------------------------------------
-SbaTableQueryBrowser::EntryType SbaTableQueryBrowser::getEntryType( SvLBoxEntry* _pEntry ) const
+SbaTableQueryBrowser::EntryType SbaTableQueryBrowser::getEntryType( const SvTreeListEntry* _pEntry ) const
{
if (!_pEntry)
return etUnknown;
- SvLBoxEntry* pRootEntry = m_pTreeView->getListBox().GetRootLevelParent(_pEntry);
- SvLBoxEntry* pEntryParent = m_pTreeView->getListBox().GetParent(_pEntry);
- SvLBoxEntry* pTables = m_pTreeView->getListBox().GetEntry(pRootEntry, CONTAINER_TABLES);
- SvLBoxEntry* pQueries = m_pTreeView->getListBox().GetEntry(pRootEntry, CONTAINER_QUERIES);
+ SvTreeListEntry* pRootEntry = m_pTreeView->getListBox().GetRootLevelParent(const_cast<SvTreeListEntry*>(_pEntry));
+ SvTreeListEntry* pEntryParent = m_pTreeView->getListBox().GetParent(const_cast<SvTreeListEntry*>(_pEntry));
+ SvTreeListEntry* pTables = m_pTreeView->getListBox().GetEntry(pRootEntry, CONTAINER_TABLES);
+ SvTreeListEntry* pQueries = m_pTreeView->getListBox().GetEntry(pRootEntry, CONTAINER_QUERIES);
#ifdef DBG_UTIL
String sTest;
@@ -105,7 +105,7 @@ SbaTableQueryBrowser::EntryType SbaTableQueryBrowser::getEntryType( SvLBoxEntry*
return etQueryContainer;
}
//------------------------------------------------------------------------------
-void SbaTableQueryBrowser::select(SvLBoxEntry* _pEntry, sal_Bool _bSelect)
+void SbaTableQueryBrowser::select(SvTreeListEntry* _pEntry, sal_Bool _bSelect)
{
SvLBoxItem* pTextItem = _pEntry ? _pEntry->GetFirstItem(SV_ITEM_ID_BOLDLBSTRING) : NULL;
if (pTextItem)
@@ -119,7 +119,7 @@ void SbaTableQueryBrowser::select(SvLBoxEntry* _pEntry, sal_Bool _bSelect)
}
//------------------------------------------------------------------------------
-void SbaTableQueryBrowser::selectPath(SvLBoxEntry* _pEntry, sal_Bool _bSelect)
+void SbaTableQueryBrowser::selectPath(SvTreeListEntry* _pEntry, sal_Bool _bSelect)
{
while (_pEntry)
{
@@ -128,7 +128,7 @@ void SbaTableQueryBrowser::selectPath(SvLBoxEntry* _pEntry, sal_Bool _bSelect)
}
}
//------------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::isSelected(SvLBoxEntry* _pEntry) const
+sal_Bool SbaTableQueryBrowser::isSelected(SvTreeListEntry* _pEntry) const
{
SvLBoxItem* pTextItem = _pEntry ? _pEntry->GetFirstItem(SV_ITEM_ID_BOLDLBSTRING) : NULL;
if (pTextItem)
@@ -199,7 +199,7 @@ void SbaTableQueryBrowser::notifyHiContrastChanged()
if ( m_pTreeView )
{
// change all bitmap entries
- SvLBoxEntry* pEntryLoop = m_pTreeModel->First();
+ SvTreeListEntry* pEntryLoop = m_pTreeModel->First();
while ( pEntryLoop )
{
DBTreeListUserData* pData = static_cast<DBTreeListUserData*>(pEntryLoop->GetUserData());
diff --git a/dbaccess/source/ui/browser/dsbrowserDnD.cxx b/dbaccess/source/ui/browser/dsbrowserDnD.cxx
index 8f6f446c8ec0..94472f0f515a 100644
--- a/dbaccess/source/ui/browser/dsbrowserDnD.cxx
+++ b/dbaccess/source/ui/browser/dsbrowserDnD.cxx
@@ -63,7 +63,7 @@ namespace dbaui
using namespace ::svx;
// -----------------------------------------------------------------------------
- TransferableHelper* SbaTableQueryBrowser::implCopyObject( SvLBoxEntry* _pApplyTo, sal_Int32 _nCommandType, sal_Bool _bAllowConnection )
+ TransferableHelper* SbaTableQueryBrowser::implCopyObject( SvTreeListEntry* _pApplyTo, sal_Int32 _nCommandType, sal_Bool _bAllowConnection )
{
try
{
@@ -98,7 +98,7 @@ namespace dbaui
sal_Int8 SbaTableQueryBrowser::queryDrop( const AcceptDropEvent& _rEvt, const DataFlavorExVector& _rFlavors )
{
// check if we're a table or query container
- SvLBoxEntry* pHitEntry = m_pTreeView->getListBox().GetEntry( _rEvt.maPosPixel );
+ SvTreeListEntry* pHitEntry = m_pTreeView->getListBox().GetEntry( _rEvt.maPosPixel );
if ( pHitEntry ) // no drop if no entry was hit ....
{
@@ -120,7 +120,7 @@ namespace dbaui
// -----------------------------------------------------------------------------
sal_Int8 SbaTableQueryBrowser::executeDrop( const ExecuteDropEvent& _rEvt )
{
- SvLBoxEntry* pHitEntry = m_pTreeView->getListBox().GetEntry( _rEvt.maPosPixel );
+ SvTreeListEntry* pHitEntry = m_pTreeView->getListBox().GetEntry( _rEvt.maPosPixel );
EntryType eEntryType = getEntryType( pHitEntry );
if (!isContainer(eEntryType))
{
@@ -182,7 +182,7 @@ namespace dbaui
{
// get the affected list entry
// ensure that the entry which the user clicked at is selected
- SvLBoxEntry* pHitEntry = m_pTreeView->getListBox().GetEntry( _rPosPixel );
+ SvTreeListEntry* pHitEntry = m_pTreeView->getListBox().GetEntry( _rPosPixel );
if (!pHitEntry)
// no drag of no entry was hit ....
return sal_False;
@@ -203,19 +203,19 @@ namespace dbaui
// -----------------------------------------------------------------------------
IMPL_LINK(SbaTableQueryBrowser, OnCopyEntry, void*, /*NOTINTERESIN*/)
{
- SvLBoxEntry* pSelected = m_pTreeView->getListBox().FirstSelected();
+ SvTreeListEntry* pSelected = m_pTreeView->getListBox().FirstSelected();
if( isEntryCopyAllowed( pSelected ) )
copyEntry( pSelected );
return 0;
}
// -----------------------------------------------------------------------------
- sal_Bool SbaTableQueryBrowser::isEntryCopyAllowed(SvLBoxEntry* _pEntry) const
+ sal_Bool SbaTableQueryBrowser::isEntryCopyAllowed(SvTreeListEntry* _pEntry) const
{
EntryType eType = getEntryType(_pEntry);
return ( eType == etTableOrView || eType == etQuery );
}
// -----------------------------------------------------------------------------
- void SbaTableQueryBrowser::copyEntry(SvLBoxEntry* _pEntry)
+ void SbaTableQueryBrowser::copyEntry(SvTreeListEntry* _pEntry)
{
TransferableHelper* pTransfer = NULL;
Reference< XTransferable> aEnsureDelete;
@@ -237,7 +237,7 @@ namespace dbaui
SharedConnection xDestConnection;
if ( ensureConnection( m_aAsyncDrop.pDroppedAt, xDestConnection ) && xDestConnection.is() )
{
- SvLBoxEntry* pDataSourceEntry = m_pTreeView->getListBox().GetRootLevelParent(m_aAsyncDrop.pDroppedAt);
+ SvTreeListEntry* pDataSourceEntry = m_pTreeView->getListBox().GetRootLevelParent(m_aAsyncDrop.pDroppedAt);
m_aTableCopyHelper.asyncCopyTagTable( m_aAsyncDrop, getDataSourceAcessor( pDataSourceEntry ), xDestConnection );
}
}
@@ -252,7 +252,7 @@ namespace dbaui
if (m_pTreeModel)
{
// clear the user data of the tree model
- SvLBoxEntry* pEntryLoop = m_pTreeModel->First();
+ SvTreeListEntry* pEntryLoop = m_pTreeModel->First();
while (pEntryLoop)
{
DBTreeListUserData* pData = static_cast<DBTreeListUserData*>(pEntryLoop->GetUserData());
diff --git a/dbaccess/source/ui/browser/genericcontroller.cxx b/dbaccess/source/ui/browser/genericcontroller.cxx
index 3131ad131e3c..58345e6cf9d2 100644
--- a/dbaccess/source/ui/browser/genericcontroller.cxx
+++ b/dbaccess/source/ui/browser/genericcontroller.cxx
@@ -1383,7 +1383,7 @@ Reference< XTitle > OGenericUnoController::impl_getTitleHelper_throw()
Reference< XUntitledNumbers > xUntitledProvider(getPrivateModel(), UNO_QUERY );
Reference< XController > xThis(static_cast< XController* >(this), UNO_QUERY_THROW);
- ::framework::TitleHelper* pHelper = new ::framework::TitleHelper(m_xServiceFactory);
+ ::framework::TitleHelper* pHelper = new ::framework::TitleHelper( comphelper::getComponentContext(m_xServiceFactory) );
m_xTitleHelper.set( static_cast< ::cppu::OWeakObject* >(pHelper), UNO_QUERY_THROW);
pHelper->setOwner (xThis );
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx
index 5e0b0075e98f..a0484e56a0b5 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -321,7 +321,7 @@ void SAL_CALL SbaTableQueryBrowser::disposing()
// clear the tree model
{
SAL_WNODEPRECATED_DECLARATIONS_PUSH
- ::std::auto_ptr<SvLBoxTreeList> aTemp(m_pTreeModel);
+ ::std::auto_ptr<SvTreeList> aTemp(m_pTreeModel);
SAL_WNODEPRECATED_DECLARATIONS_POP
m_pTreeModel = NULL;
}
@@ -393,7 +393,7 @@ sal_Bool SbaTableQueryBrowser::Construct(Window* pParent)
getBrowserView()->setTreeView(m_pTreeView);
// fill view with data
- m_pTreeModel = new SvLBoxTreeList;
+ m_pTreeModel = new SvTreeList;
m_pTreeModel->SetSortMode(SortAscending);
m_pTreeModel->SetCompareHdl(LINK(this, SbaTableQueryBrowser, OnTreeEntryCompare));
m_pTreeView->setModel(m_pTreeModel);
@@ -857,7 +857,7 @@ sal_Bool SbaTableQueryBrowser::InitializeGridModel(const Reference< ::com::sun::
return sal_True;
}
// -----------------------------------------------------------------------------
-Reference<XPropertySet> getColumnHelper(SvLBoxEntry* _pCurrentlyDisplayed,const Reference<XPropertySet>& _rxSource)
+Reference<XPropertySet> getColumnHelper(SvTreeListEntry* _pCurrentlyDisplayed,const Reference<XPropertySet>& _rxSource)
{
Reference<XPropertySet> xRet;
if(_pCurrentlyDisplayed)
@@ -1075,9 +1075,9 @@ void SAL_CALL SbaTableQueryBrowser::statusChanged( const FeatureStateEvent& _rEv
// -------------------------------------------------------------------------
void SbaTableQueryBrowser::checkDocumentDataSource()
{
- SvLBoxEntry* pDataSourceEntry = NULL;
- SvLBoxEntry* pContainerEntry = NULL;
- SvLBoxEntry* pObjectEntry = getObjectEntry( m_aDocumentDataSource, &pDataSourceEntry, &pContainerEntry, sal_False );
+ SvTreeListEntry* pDataSourceEntry = NULL;
+ SvTreeListEntry* pContainerEntry = NULL;
+ SvTreeListEntry* pObjectEntry = getObjectEntry( m_aDocumentDataSource, &pDataSourceEntry, &pContainerEntry, sal_False );
sal_Bool bKnownDocDataSource = (NULL != pObjectEntry);
if (!bKnownDocDataSource)
{
@@ -1149,10 +1149,10 @@ namespace
virtual ~FilterByEntryDataId() {}
- virtual bool includeEntry( SvLBoxEntry* _pEntry ) const;
+ virtual bool includeEntry( SvTreeListEntry* _pEntry ) const;
};
- bool FilterByEntryDataId::includeEntry( SvLBoxEntry* _pEntry ) const
+ bool FilterByEntryDataId::includeEntry( SvTreeListEntry* _pEntry ) const
{
DBTreeListUserData* pData = static_cast< DBTreeListUserData* >( _pEntry->GetUserData() );
return ( !pData || ( pData->sAccessor == sId ) );
@@ -1160,7 +1160,7 @@ namespace
}
// -------------------------------------------------------------------------
-String SbaTableQueryBrowser::getDataSourceAcessor( SvLBoxEntry* _pDataSourceEntry ) const
+String SbaTableQueryBrowser::getDataSourceAcessor( SvTreeListEntry* _pDataSourceEntry ) const
{
OSL_ENSURE( _pDataSourceEntry, "SbaTableQueryBrowser::getDataSourceAcessor: invalid entry!" );
@@ -1171,8 +1171,8 @@ String SbaTableQueryBrowser::getDataSourceAcessor( SvLBoxEntry* _pDataSourceEntr
}
// -------------------------------------------------------------------------
-SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataSource, const ::rtl::OUString& _rCommand, sal_Int32 _nCommandType,
- SvLBoxEntry** _ppDataSourceEntry, SvLBoxEntry** _ppContainerEntry, sal_Bool _bExpandAncestors,
+SvTreeListEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataSource, const ::rtl::OUString& _rCommand, sal_Int32 _nCommandType,
+ SvTreeListEntry** _ppDataSourceEntry, SvTreeListEntry** _ppContainerEntry, sal_Bool _bExpandAncestors,
const SharedConnection& _rxConnection )
{
if (_ppDataSourceEntry)
@@ -1180,7 +1180,7 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataS
if (_ppContainerEntry)
*_ppContainerEntry = NULL;
- SvLBoxEntry* pObject = NULL;
+ SvTreeListEntry* pObject = NULL;
if ( m_pTreeView )
{
// look for the data source entry
@@ -1190,7 +1190,7 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataS
// #i33699#
FilterByEntryDataId aFilter( sDataSourceId );
- SvLBoxEntry* pDataSource = m_pTreeView->getListBox().GetEntryPosByName( sDisplayName, NULL, &aFilter );
+ SvTreeListEntry* pDataSource = m_pTreeView->getListBox().GetEntryPosByName( sDisplayName, NULL, &aFilter );
if ( !pDataSource ) // check if the data source name is a file location
{
if ( bIsDataSourceURL )
@@ -1213,7 +1213,7 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataS
m_pTreeView->getListBox().Expand(pDataSource);
// look for the object container
- SvLBoxEntry* pCommandType = NULL;
+ SvTreeListEntry* pCommandType = NULL;
switch (_nCommandType)
{
case CommandType::TABLE:
@@ -1284,8 +1284,8 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataS
}
// -------------------------------------------------------------------------
-SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::svx::ODataAccessDescriptor& _rDescriptor,
- SvLBoxEntry** _ppDataSourceEntry, SvLBoxEntry** _ppContainerEntry,
+SvTreeListEntry* SbaTableQueryBrowser::getObjectEntry(const ::svx::ODataAccessDescriptor& _rDescriptor,
+ SvTreeListEntry** _ppDataSourceEntry, SvTreeListEntry** _ppContainerEntry,
sal_Bool _bExpandAncestors)
{
// extract the props from the descriptor
@@ -1425,7 +1425,7 @@ void SAL_CALL SbaTableQueryBrowser::disposing( const EventObject& _rSource ) thr
{ // our connection is in dispose so we have to find the entry equal with this connection
// and close it what means to collapse the entry
// get the top-level representing the removed data source
- SvLBoxEntry* pDSLoop = m_pTreeView->getListBox().FirstChild(NULL);
+ SvTreeListEntry* pDSLoop = m_pTreeView->getListBox().FirstChild(NULL);
while (pDSLoop)
{
DBTreeListUserData* pData = static_cast<DBTreeListUserData*>(pDSLoop->GetUserData());
@@ -1733,12 +1733,12 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
case ID_TREE_CLOSE_CONN:
case ID_TREE_EDIT_DATABASE:
{
- SvLBoxEntry* pCurrentEntry( m_pTreeView->getListBox().GetCurEntry() );
+ SvTreeListEntry* pCurrentEntry( m_pTreeView->getListBox().GetCurEntry() );
EntryType eType = getEntryType( pCurrentEntry );
if ( eType == etUnknown )
return aReturn;
- SvLBoxEntry* pDataSourceEntry = m_pTreeView->getListBox().GetRootLevelParent( pCurrentEntry );
+ SvTreeListEntry* pDataSourceEntry = m_pTreeView->getListBox().GetRootLevelParent( pCurrentEntry );
DBTreeListUserData* pDSData
= pDataSourceEntry
? static_cast< DBTreeListUserData* >( pDataSourceEntry->GetUserData() )
@@ -1949,7 +1949,7 @@ void SbaTableQueryBrowser::Execute(sal_uInt16 nId, const Sequence< PropertyValue
// nothing to do
break;
- SvLBoxEntry* pSelected = m_pCurrentlyDisplayed;
+ SvTreeListEntry* pSelected = m_pCurrentlyDisplayed;
// unload
unloadAndCleanup( sal_False );
@@ -2115,7 +2115,7 @@ void SbaTableQueryBrowser::implAddDatasource(const String& _rDbName, Image& _rDb
String sDSDisplayName, sDataSourceId;
getDataSourceDisplayName_isURL( _rDbName, sDSDisplayName, sDataSourceId );
- SvLBoxEntry* pDatasourceEntry = m_pTreeView->getListBox().InsertEntry( sDSDisplayName, _rDbImage, _rDbImage, NULL, sal_False );
+ SvTreeListEntry* pDatasourceEntry = m_pTreeView->getListBox().InsertEntry( sDSDisplayName, _rDbImage, _rDbImage, NULL, sal_False );
DBTreeListUserData* pDSData = new DBTreeListUserData;
pDSData->eType = etDatasource;
pDSData->sAccessor = sDataSourceId;
@@ -2161,7 +2161,7 @@ void SbaTableQueryBrowser::initializeTreeModel()
}
// -------------------------------------------------------------------------
void SbaTableQueryBrowser::populateTree(const Reference<XNameAccess>& _xNameAccess,
- SvLBoxEntry* _pParent,
+ SvTreeListEntry* _pParent,
EntryType _eEntryType)
{
DBTreeListUserData* pData = static_cast<DBTreeListUserData*>(_pParent->GetUserData());
@@ -2196,7 +2196,7 @@ void SbaTableQueryBrowser::populateTree(const Reference<XNameAccess>& _xNameAcce
}
//------------------------------------------------------------------------------
-SvLBoxEntry* SbaTableQueryBrowser::implAppendEntry( SvLBoxEntry* _pParent, const String& _rName, void* _pUserData, EntryType _eEntryType )
+SvTreeListEntry* SbaTableQueryBrowser::implAppendEntry( SvTreeListEntry* _pParent, const String& _rName, void* _pUserData, EntryType _eEntryType )
{
SAL_WNODEPRECATED_DECLARATIONS_PUSH
::std::auto_ptr< ImageProvider > pImageProvider( getImageProviderFor( _pParent ) );
@@ -2205,7 +2205,7 @@ SvLBoxEntry* SbaTableQueryBrowser::implAppendEntry( SvLBoxEntry* _pParent, const
Image aImage;
pImageProvider->getImages( _rName, getDatabaseObjectType( _eEntryType ), aImage );
- SvLBoxEntry* pNewEntry = m_pTreeView->getListBox().InsertEntry( _rName, _pParent, _eEntryType == etQueryContainer , LIST_APPEND, _pUserData );
+ SvTreeListEntry* pNewEntry = m_pTreeView->getListBox().InsertEntry( _rName, _pParent, _eEntryType == etQueryContainer , LIST_APPEND, _pUserData );
m_pTreeView->getListBox().SetExpandedEntryBmp( pNewEntry, aImage );
m_pTreeView->getListBox().SetCollapsedEntryBmp( pNewEntry, aImage );
@@ -2214,13 +2214,13 @@ SvLBoxEntry* SbaTableQueryBrowser::implAppendEntry( SvLBoxEntry* _pParent, const
}
//------------------------------------------------------------------------------
-IMPL_LINK(SbaTableQueryBrowser, OnExpandEntry, SvLBoxEntry*, _pParent)
+IMPL_LINK(SbaTableQueryBrowser, OnExpandEntry, SvTreeListEntry*, _pParent)
{
if (_pParent->HasChildren())
// nothing to to ...
return 1L;
- SvLBoxEntry* pFirstParent = m_pTreeView->getListBox().GetRootLevelParent(_pParent);
+ SvTreeListEntry* pFirstParent = m_pTreeView->getListBox().GetRootLevelParent(_pParent);
OSL_ENSURE(pFirstParent,"SbaTableQueryBrowser::OnExpandEntry: No rootlevelparent!");
DBTreeListUserData* pData = static_cast< DBTreeListUserData* >(_pParent->GetUserData());
@@ -2323,7 +2323,7 @@ IMPL_LINK(SbaTableQueryBrowser, OnExpandEntry, SvLBoxEntry*, _pParent)
}
//------------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::ensureEntryObject( SvLBoxEntry* _pEntry )
+sal_Bool SbaTableQueryBrowser::ensureEntryObject( SvTreeListEntry* _pEntry )
{
OSL_ENSURE(_pEntry, "SbaTableQueryBrowser::ensureEntryObject: invalid argument!");
if (!_pEntry)
@@ -2335,7 +2335,7 @@ sal_Bool SbaTableQueryBrowser::ensureEntryObject( SvLBoxEntry* _pEntry )
DBTreeListUserData* pEntryData = static_cast<DBTreeListUserData*>(_pEntry->GetUserData());
OSL_ENSURE(pEntryData,"ensureEntryObject: user data should already be set!");
- SvLBoxEntry* pDataSourceEntry = m_pTreeView->getListBox().GetRootLevelParent(_pEntry);
+ SvTreeListEntry* pDataSourceEntry = m_pTreeView->getListBox().GetRootLevelParent(_pEntry);
sal_Bool bSuccess = sal_False;
switch (eType)
@@ -2349,7 +2349,7 @@ sal_Bool SbaTableQueryBrowser::ensureEntryObject( SvLBoxEntry* _pEntry )
}
{
- SvLBoxEntry* pParent = m_pTreeView->getListBox().GetParent(_pEntry);
+ SvTreeListEntry* pParent = m_pTreeView->getListBox().GetParent(_pEntry);
if ( pParent != pDataSourceEntry )
{
SvLBoxString* pString = (SvLBoxString*)_pEntry->GetFirstItem(SV_ITEM_ID_BOLDLBSTRING);
@@ -2513,9 +2513,9 @@ sal_Bool SbaTableQueryBrowser::implSelect(const ::rtl::OUString& _rDataSourceNam
{
if (_rDataSourceName.getLength() && _rCommand.getLength() && (-1 != _nCommandType))
{
- SvLBoxEntry* pDataSource = NULL;
- SvLBoxEntry* pCommandType = NULL;
- SvLBoxEntry* pCommand = getObjectEntry( _rDataSourceName, _rCommand, _nCommandType, &pDataSource, &pCommandType, sal_True, _rxConnection );
+ SvTreeListEntry* pDataSource = NULL;
+ SvTreeListEntry* pCommandType = NULL;
+ SvTreeListEntry* pCommand = getObjectEntry( _rDataSourceName, _rCommand, _nCommandType, &pDataSource, &pCommandType, sal_True, _rxConnection );
if (pCommand)
{
@@ -2556,9 +2556,9 @@ IMPL_LINK(SbaTableQueryBrowser, OnSelectionChange, void*, /*NOINTERESTEDIN*/)
return implSelect( m_pTreeView->getListBox().FirstSelected() ) ? 1L : 0L;
}
//------------------------------------------------------------------------------
-SvLBoxEntry* SbaTableQueryBrowser::implGetConnectionEntry(SvLBoxEntry* _pEntry) const
+SvTreeListEntry* SbaTableQueryBrowser::implGetConnectionEntry(SvTreeListEntry* _pEntry) const
{
- SvLBoxEntry* pCurrentEntry = _pEntry;
+ SvTreeListEntry* pCurrentEntry = _pEntry;
DBTreeListUserData* pEntryData = static_cast< DBTreeListUserData* >( pCurrentEntry->GetUserData() );
while(pEntryData->eType != etDatasource )
{
@@ -2568,7 +2568,7 @@ SvLBoxEntry* SbaTableQueryBrowser::implGetConnectionEntry(SvLBoxEntry* _pEntry)
return pCurrentEntry;
}
//------------------------------------------------------------------------------
-bool SbaTableQueryBrowser::implSelect( SvLBoxEntry* _pEntry )
+bool SbaTableQueryBrowser::implSelect( SvTreeListEntry* _pEntry )
{
if ( !_pEntry )
return false;
@@ -2588,11 +2588,11 @@ bool SbaTableQueryBrowser::implSelect( SvLBoxEntry* _pEntry )
OSL_ENSURE(m_pTreeModel->HasParent(m_pTreeModel->GetParent(_pEntry)), "SbaTableQueryBrowser::implSelect: invalid entry (2)!");
// get the entry for the tables or queries
- SvLBoxEntry* pContainer = m_pTreeModel->GetParent(_pEntry);
+ SvTreeListEntry* pContainer = m_pTreeModel->GetParent(_pEntry);
DBTreeListUserData* pContainerData = static_cast<DBTreeListUserData*>(pContainer->GetUserData());
// get the entry for the datasource
- SvLBoxEntry* pConnection = implGetConnectionEntry(pContainer);
+ SvTreeListEntry* pConnection = implGetConnectionEntry(pContainer);
DBTreeListUserData* pConData = static_cast<DBTreeListUserData*>(pConnection->GetUserData());
// reinitialize the rowset
@@ -2612,7 +2612,7 @@ bool SbaTableQueryBrowser::implSelect( SvLBoxEntry* _pEntry )
::rtl::OUStringBuffer sNameBuffer(sSimpleName);
if ( etQueryContainer == pContainerData->eType )
{
- SvLBoxEntry* pTemp = pContainer;
+ SvTreeListEntry* pTemp = pContainer;
while( m_pTreeModel->GetParent(pTemp) != pConnection )
{
sNameBuffer.insert(0,sal_Unicode('/'));
@@ -2786,11 +2786,11 @@ bool SbaTableQueryBrowser::implSelect( SvLBoxEntry* _pEntry )
}
// -----------------------------------------------------------------------------
-SvLBoxEntry* SbaTableQueryBrowser::getEntryFromContainer(const Reference<XNameAccess>& _rxNameAccess)
+SvTreeListEntry* SbaTableQueryBrowser::getEntryFromContainer(const Reference<XNameAccess>& _rxNameAccess)
{
DBTreeListBox& rListBox = m_pTreeView->getListBox();
- SvLBoxEntry* pContainer = NULL;
- SvLBoxEntry* pDSLoop = rListBox.FirstChild(NULL);
+ SvTreeListEntry* pContainer = NULL;
+ SvTreeListEntry* pDSLoop = rListBox.FirstChild(NULL);
while (pDSLoop)
{
pContainer = rListBox.GetEntry(pDSLoop, CONTAINER_QUERIES);
@@ -2817,7 +2817,7 @@ void SAL_CALL SbaTableQueryBrowser::elementInserted( const ContainerEvent& _rEve
Reference< XNameAccess > xNames(_rEvent.Source, UNO_QUERY);
// first search for a definition container where we can insert this element
- SvLBoxEntry* pEntry = getEntryFromContainer(xNames);
+ SvTreeListEntry* pEntry = getEntryFromContainer(xNames);
if(pEntry) // found one
{
// insert the new entry into the tree
@@ -2847,7 +2847,7 @@ void SAL_CALL SbaTableQueryBrowser::elementInserted( const ContainerEvent& _rEve
SbaXDataBrowserController::elementInserted(_rEvent);
}
// -------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::isCurrentlyDisplayedChanged(const String& _sName,SvLBoxEntry* _pContainer)
+sal_Bool SbaTableQueryBrowser::isCurrentlyDisplayedChanged(const String& _sName,SvTreeListEntry* _pContainer)
{
return m_pCurrentlyDisplayed
&& getEntryType(m_pCurrentlyDisplayed) == getChildType(_pContainer)
@@ -2862,7 +2862,7 @@ void SAL_CALL SbaTableQueryBrowser::elementRemoved( const ContainerEvent& _rEven
Reference< XNameAccess > xNames(_rEvent.Source, UNO_QUERY);
// get the top-level representing the removed data source
// and search for the queries and tables
- SvLBoxEntry* pContainer = getEntryFromContainer(xNames);
+ SvTreeListEntry* pContainer = getEntryFromContainer(xNames);
if ( pContainer )
{ // a query or table has been removed
String aName = ::comphelper::getString(_rEvent.Accessor);
@@ -2871,7 +2871,7 @@ void SAL_CALL SbaTableQueryBrowser::elementRemoved( const ContainerEvent& _rEven
{ // the element displayed currently has been replaced
// we need to remember the old value
- SvLBoxEntry* pTemp = m_pCurrentlyDisplayed;
+ SvTreeListEntry* pTemp = m_pCurrentlyDisplayed;
// unload
unloadAndCleanup( sal_False ); // don't dispose the connection
@@ -2885,7 +2885,7 @@ void SAL_CALL SbaTableQueryBrowser::elementRemoved( const ContainerEvent& _rEven
else
{
// remove the entry from the model
- SvLBoxEntry* pChild = m_pTreeModel->FirstChild(pContainer);
+ SvTreeListEntry* pChild = m_pTreeModel->FirstChild(pContainer);
while(pChild)
{
if (m_pTreeView->getListBox().GetEntryText(pChild) == aName)
@@ -2913,7 +2913,7 @@ void SAL_CALL SbaTableQueryBrowser::elementReplaced( const ContainerEvent& _rEve
SolarMutexGuard aSolarGuard;
Reference< XNameAccess > xNames(_rEvent.Source, UNO_QUERY);
- SvLBoxEntry* pContainer = getEntryFromContainer(xNames);
+ SvTreeListEntry* pContainer = getEntryFromContainer(xNames);
if ( pContainer )
{ // a table or query as been replaced
String aName = ::comphelper::getString(_rEvent.Accessor);
@@ -2922,7 +2922,7 @@ void SAL_CALL SbaTableQueryBrowser::elementReplaced( const ContainerEvent& _rEve
{ // the element displayed currently has been replaced
// we need to remember the old value
- SvLBoxEntry* pTemp = m_pCurrentlyDisplayed;
+ SvTreeListEntry* pTemp = m_pCurrentlyDisplayed;
unloadAndCleanup( sal_False ); // don't dispose the connection
DBTreeListUserData* pData = static_cast<DBTreeListUserData*>(pTemp->GetUserData());
@@ -2942,7 +2942,7 @@ void SAL_CALL SbaTableQueryBrowser::elementReplaced( const ContainerEvent& _rEve
else
{
// find the entry for this name
- SvLBoxEntry* pChild = m_pTreeModel->FirstChild(pContainer);
+ SvTreeListEntry* pChild = m_pTreeModel->FirstChild(pContainer);
while(pChild)
{
if (m_pTreeView->getListBox().GetEntryText(pChild) == aName)
@@ -3008,7 +3008,7 @@ void SbaTableQueryBrowser::impl_releaseConnection( SharedConnection& _rxConnecti
}
// -------------------------------------------------------------------------
-void SbaTableQueryBrowser::disposeConnection( SvLBoxEntry* _pDSEntry )
+void SbaTableQueryBrowser::disposeConnection( SvTreeListEntry* _pDSEntry )
{
OSL_ENSURE( _pDSEntry, "SbaTableQueryBrowser::disposeConnection: invalid entry (NULL)!" );
OSL_ENSURE( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::disposeConnection: invalid entry (not top-level)!" );
@@ -3022,7 +3022,7 @@ void SbaTableQueryBrowser::disposeConnection( SvLBoxEntry* _pDSEntry )
}
// -------------------------------------------------------------------------
-void SbaTableQueryBrowser::closeConnection(SvLBoxEntry* _pDSEntry,sal_Bool _bDisposeConnection)
+void SbaTableQueryBrowser::closeConnection(SvTreeListEntry* _pDSEntry,sal_Bool _bDisposeConnection)
{
OSL_ENSURE(_pDSEntry, "SbaTableQueryBrowser::closeConnection: invalid entry (NULL)!");
OSL_ENSURE( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::closeConnection: invalid entry (not top-level)!");
@@ -3032,16 +3032,16 @@ void SbaTableQueryBrowser::closeConnection(SvLBoxEntry* _pDSEntry,sal_Bool _bDis
unloadAndCleanup(_bDisposeConnection);
// collapse the query/table container
- for (SvLBoxEntry* pContainers = m_pTreeModel->FirstChild(_pDSEntry); pContainers; pContainers= m_pTreeModel->NextSibling(pContainers))
+ for (SvTreeListEntry* pContainers = m_pTreeModel->FirstChild(_pDSEntry); pContainers; pContainers= m_pTreeModel->NextSibling(pContainers))
{
- SvLBoxEntry* pElements = m_pTreeModel->FirstChild(pContainers);
+ SvTreeListEntry* pElements = m_pTreeModel->FirstChild(pContainers);
if ( pElements )
m_pTreeView->getListBox().Collapse(pContainers);
m_pTreeView->getListBox().EnableExpandHandler(pContainers);
// and delete their children (they are connection-relative)
for (; pElements; )
{
- SvLBoxEntry* pRemove = pElements;
+ SvTreeListEntry* pRemove = pElements;
pElements= m_pTreeModel->NextSibling(pElements);
DBTreeListUserData* pData = static_cast<DBTreeListUserData*>(pRemove->GetUserData());
pRemove->SetUserData(NULL);
@@ -3064,7 +3064,7 @@ void SbaTableQueryBrowser::unloadAndCleanup( sal_Bool _bDisposeConnection )
// nothing to do
return;
- SvLBoxEntry* pDSEntry = m_pTreeView->getListBox().GetRootLevelParent(m_pCurrentlyDisplayed);
+ SvTreeListEntry* pDSEntry = m_pTreeView->getListBox().GetRootLevelParent(m_pCurrentlyDisplayed);
// de-select the path for the currently displayed table/query
if (m_pCurrentlyDisplayed)
@@ -3356,9 +3356,9 @@ void SbaTableQueryBrowser::showExplorer()
}
// -----------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::ensureConnection(SvLBoxEntry* _pAnyEntry, SharedConnection& _rConnection)
+sal_Bool SbaTableQueryBrowser::ensureConnection(SvTreeListEntry* _pAnyEntry, SharedConnection& _rConnection)
{
- SvLBoxEntry* pDSEntry = m_pTreeView->getListBox().GetRootLevelParent(_pAnyEntry);
+ SvTreeListEntry* pDSEntry = m_pTreeView->getListBox().GetRootLevelParent(_pAnyEntry);
DBTreeListUserData* pDSData =
pDSEntry
? static_cast<DBTreeListUserData*>(pDSEntry->GetUserData())
@@ -3369,7 +3369,7 @@ sal_Bool SbaTableQueryBrowser::ensureConnection(SvLBoxEntry* _pAnyEntry, SharedC
// -----------------------------------------------------------------------------
SAL_WNODEPRECATED_DECLARATIONS_PUSH
-::std::auto_ptr< ImageProvider > SbaTableQueryBrowser::getImageProviderFor( SvLBoxEntry* _pAnyEntry )
+::std::auto_ptr< ImageProvider > SbaTableQueryBrowser::getImageProviderFor( SvTreeListEntry* _pAnyEntry )
{
::std::auto_ptr< ImageProvider > pImageProvider( new ImageProvider );
SharedConnection xConnection;
@@ -3380,9 +3380,9 @@ SAL_WNODEPRECATED_DECLARATIONS_PUSH
SAL_WNODEPRECATED_DECLARATIONS_POP
// -----------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::getExistentConnectionFor( SvLBoxEntry* _pAnyEntry, SharedConnection& _rConnection )
+sal_Bool SbaTableQueryBrowser::getExistentConnectionFor( SvTreeListEntry* _pAnyEntry, SharedConnection& _rConnection )
{
- SvLBoxEntry* pDSEntry = m_pTreeView->getListBox().GetRootLevelParent( _pAnyEntry );
+ SvTreeListEntry* pDSEntry = m_pTreeView->getListBox().GetRootLevelParent( _pAnyEntry );
DBTreeListUserData* pDSData =
pDSEntry
? static_cast< DBTreeListUserData* >( pDSEntry->GetUserData() )
@@ -3394,14 +3394,14 @@ sal_Bool SbaTableQueryBrowser::getExistentConnectionFor( SvLBoxEntry* _pAnyEntry
#if OSL_DEBUG_LEVEL > 0
// -----------------------------------------------------------------------------
-bool SbaTableQueryBrowser::impl_isDataSourceEntry( SvLBoxEntry* _pEntry ) const
+bool SbaTableQueryBrowser::impl_isDataSourceEntry( SvTreeListEntry* _pEntry ) const
{
return m_pTreeModel->GetRootLevelParent( _pEntry ) == _pEntry;
}
#endif
// -----------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::ensureConnection( SvLBoxEntry* _pDSEntry, void* pDSData, SharedConnection& _rConnection )
+sal_Bool SbaTableQueryBrowser::ensureConnection( SvTreeListEntry* _pDSEntry, void* pDSData, SharedConnection& _rConnection )
{
OSL_ENSURE( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::ensureConnection: this entry does not denote a data source!" );
if(_pDSEntry)
@@ -3440,8 +3440,8 @@ sal_Bool SbaTableQueryBrowser::ensureConnection( SvLBoxEntry* _pDSEntry, void* p
// -----------------------------------------------------------------------------
IMPL_LINK( SbaTableQueryBrowser, OnTreeEntryCompare, const SvSortData*, _pSortData )
{
- SvLBoxEntry* pLHS = static_cast<SvLBoxEntry*>(_pSortData->pLeft);
- SvLBoxEntry* pRHS = static_cast<SvLBoxEntry*>(_pSortData->pRight);
+ const SvTreeListEntry* pLHS = static_cast<const SvTreeListEntry*>(_pSortData->pLeft);
+ const SvTreeListEntry* pRHS = static_cast<const SvTreeListEntry*>(_pSortData->pRight);
OSL_ENSURE(pLHS && pRHS, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid tree entries!");
// we want the table entry and the end so we have to do a check
@@ -3455,7 +3455,7 @@ IMPL_LINK( SbaTableQueryBrowser, OnTreeEntryCompare, const SvSortData*, _pSortDa
// every other container should be placed _before_ the bookmark container
return -1;
- const String sLeft = m_pTreeView->getListBox().GetEntryText(pLHS);
+ const String sLeft = m_pTreeView->getListBox().GetEntryText(const_cast<SvTreeListEntry*>(pLHS));
EntryType eLeft = etTableContainer;
if (String(ModuleRes(RID_STR_TABLES_CONTAINER)) == sLeft)
@@ -3503,7 +3503,7 @@ IMPL_LINK( SbaTableQueryBrowser, OnTreeEntryCompare, const SvSortData*, _pSortDa
}
// -----------------------------------------------------------------------------
-void SbaTableQueryBrowser::implAdministrate( SvLBoxEntry* _pApplyTo )
+void SbaTableQueryBrowser::implAdministrate( SvTreeListEntry* _pApplyTo )
{
OSL_PRECOND( _pApplyTo, "SbaTableQueryBrowser::implAdministrate: illegal entry!" );
if ( !_pApplyTo )
@@ -3518,7 +3518,7 @@ void SbaTableQueryBrowser::implAdministrate( SvLBoxEntry* _pApplyTo )
if ( xFrameLoader.is() )
{
// the initial selection
- SvLBoxEntry* pTopLevelSelected = _pApplyTo;
+ SvTreeListEntry* pTopLevelSelected = _pApplyTo;
while (pTopLevelSelected && m_pTreeView->getListBox().GetParent(pTopLevelSelected))
pTopLevelSelected = m_pTreeView->getListBox().GetParent(pTopLevelSelected);
::rtl::OUString sInitialSelection;
@@ -3557,7 +3557,7 @@ void SbaTableQueryBrowser::implAdministrate( SvLBoxEntry* _pApplyTo )
}
// -----------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::requestQuickHelp( const SvLBoxEntry* _pEntry, String& _rText ) const
+sal_Bool SbaTableQueryBrowser::requestQuickHelp( const SvTreeListEntry* _pEntry, String& _rText ) const
{
const DBTreeListUserData* pData = static_cast< const DBTreeListUserData* >( _pEntry->GetUserData() );
if ( ( pData->eType == etDatasource ) && pData->sAccessor.Len() )
@@ -3600,7 +3600,7 @@ Any SbaTableQueryBrowser::getCurrentSelection( Control& _rControl ) const
if ( &m_pTreeView->getListBox() != &_rControl )
return Any();
- SvLBoxEntry* pSelected = m_pTreeView->getListBox().FirstSelected();
+ SvTreeListEntry* pSelected = m_pTreeView->getListBox().FirstSelected();
if ( !pSelected )
return Any();
@@ -3736,9 +3736,9 @@ void SbaTableQueryBrowser::loadMenu(const Reference< XFrame >& _xFrame)
::rtl::OUString sTitle;
if ( m_pCurrentlyDisplayed )
{
- SvLBoxEntry* pContainer = m_pTreeModel->GetParent(m_pCurrentlyDisplayed);
+ SvTreeListEntry* pContainer = m_pTreeModel->GetParent(m_pCurrentlyDisplayed);
// get the entry for the datasource
- SvLBoxEntry* pConnection = implGetConnectionEntry(pContainer);
+ SvTreeListEntry* pConnection = implGetConnectionEntry(pContainer);
::rtl::OUString sName = m_pTreeView->getListBox().GetEntryText(m_pCurrentlyDisplayed);
sTitle = GetEntryText( pConnection );
INetURLObject aURL(sTitle);
@@ -3773,8 +3773,8 @@ sal_Bool SbaTableQueryBrowser::preReloadForm()
extractDescriptorProps(aDesc, sDataSource, sCommand, nCommandType, bEscapeProcessing);
if ( !sDataSource.isEmpty() && !sCommand.isEmpty() && (-1 != nCommandType) )
{
- SvLBoxEntry* pDataSource = NULL;
- SvLBoxEntry* pCommandType = NULL;
+ SvTreeListEntry* pDataSource = NULL;
+ SvTreeListEntry* pCommandType = NULL;
m_pCurrentlyDisplayed = getObjectEntry( sDataSource, sCommand, nCommandType, &pDataSource, &pCommandType, sal_True, SharedConnection() );
bIni = sal_True;
}
@@ -3840,7 +3840,7 @@ void SAL_CALL SbaTableQueryBrowser::registeredDatabaseLocation( const DatabaseRe
void SbaTableQueryBrowser::impl_cleanupDataSourceEntry( const String& _rDataSourceName )
{
// get the top-level representing the removed data source
- SvLBoxEntry* pDataSourceEntry = m_pTreeView->getListBox().FirstChild( NULL );
+ SvTreeListEntry* pDataSourceEntry = m_pTreeView->getListBox().FirstChild( NULL );
while ( pDataSourceEntry )
{
if ( m_pTreeView->getListBox().GetEntryText( pDataSourceEntry ) == _rDataSourceName )
@@ -3866,16 +3866,17 @@ void SbaTableQueryBrowser::impl_cleanupDataSourceEntry( const String& _rDataSour
"SbaTableQueryBrowser::impl_cleanupDataSourceEntry: inconsistence (2)!");
// delete any user data of the child entries of the to-be-removed entry
- SvTreeEntryList* pList = m_pTreeModel->GetChildList( pDataSourceEntry );
- if ( pList )
+ std::pair<SvTreeListEntries::iterator, SvTreeListEntries::iterator> aIters =
+ m_pTreeModel->GetChildIterators(pDataSourceEntry);
+
+ SvTreeListEntries::iterator it = aIters.first, itEnd = aIters.second;
+
+ for (; it != itEnd; ++it)
{
- for ( size_t i = 0, n = pList->size(); i < n; ++i )
- {
- SvLBoxEntry* pEntryLoop = static_cast<SvLBoxEntry*>((*pList)[ i ]);
- DBTreeListUserData* pData = static_cast< DBTreeListUserData* >( pEntryLoop->GetUserData() );
- pEntryLoop->SetUserData( NULL );
- delete pData;
- }
+ SvTreeListEntry* pEntry = &(*it);
+ const DBTreeListUserData* pData = static_cast<const DBTreeListUserData*>(pEntry->GetUserData());
+ pEntry->SetUserData(NULL);
+ delete pData;
}
// remove the entry
diff --git a/dbaccess/source/ui/control/dbtreelistbox.cxx b/dbaccess/source/ui/control/dbtreelistbox.cxx
index d73a435fe9e5..1c53330cb4a4 100644
--- a/dbaccess/source/ui/control/dbtreelistbox.cxx
+++ b/dbaccess/source/ui/control/dbtreelistbox.cxx
@@ -108,39 +108,40 @@ DBTreeListBox::~DBTreeListBox()
implStopSelectionTimer();
}
//------------------------------------------------------------------------
-SvLBoxEntry* DBTreeListBox::GetEntryPosByName( const String& aName, SvLBoxEntry* pStart, const IEntryFilter* _pFilter ) const
+SvTreeListEntry* DBTreeListBox::GetEntryPosByName( const String& aName, SvTreeListEntry* pStart, const IEntryFilter* _pFilter ) const
{
- SvLBoxTreeList* myModel = GetModel();
- SvTreeEntryList* pChildren = myModel->GetChildList(pStart);
- SvLBoxEntry* pEntry = NULL;
- if ( pChildren )
+ SvTreeList* myModel = GetModel();
+ std::pair<SvTreeListEntries::iterator,SvTreeListEntries::iterator> aIters =
+ myModel->GetChildIterators(pStart);
+
+ SvTreeListEntry* pEntry = NULL;
+ SvTreeListEntries::iterator it = aIters.first, itEnd = aIters.second;
+ for (; it != itEnd; ++it)
{
- size_t nCount = pChildren->size();
- for (size_t i = 0; i < nCount; ++i)
+ pEntry = &(*it);
+ const SvLBoxString* pItem = static_cast<const SvLBoxString*>(
+ pEntry->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
+
+ if (pItem && pItem->GetText().equals(aName))
{
- pEntry = static_cast<SvLBoxEntry*>((*pChildren)[ i ]);
- SvLBoxString* pItem = (SvLBoxString*)(pEntry->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
- if ( pItem->GetText().equals(aName) )
- {
- if ( !_pFilter || _pFilter->includeEntry( pEntry ) )
- // found
- break;
- }
- pEntry = NULL;
+ if (!_pFilter || _pFilter->includeEntry(pEntry))
+ // found
+ break;
}
+ pEntry = NULL;
}
return pEntry;
}
// -------------------------------------------------------------------------
-void DBTreeListBox::EnableExpandHandler(SvLBoxEntry* _pEntry)
+void DBTreeListBox::EnableExpandHandler(SvTreeListEntry* _pEntry)
{
LINK(this, DBTreeListBox, OnResetEntry).Call(_pEntry);
}
// -------------------------------------------------------------------------
-void DBTreeListBox::RequestingChildren( SvLBoxEntry* pParent )
+void DBTreeListBox::RequestingChildren( SvTreeListEntry* pParent )
{
if (m_aPreExpandHandler.IsSet())
{
@@ -155,7 +156,7 @@ void DBTreeListBox::RequestingChildren( SvLBoxEntry* pParent )
}
// -------------------------------------------------------------------------
-void DBTreeListBox::InitEntry( SvLBoxEntry* _pEntry, const XubString& aStr, const Image& _rCollEntryBmp, const Image& _rExpEntryBmp, SvLBoxButtonKind eButtonKind)
+void DBTreeListBox::InitEntry(SvTreeListEntry* _pEntry, const OUString& aStr, const Image& _rCollEntryBmp, const Image& _rExpEntryBmp, SvLBoxButtonKind eButtonKind)
{
SvTreeListBox::InitEntry( _pEntry, aStr, _rCollEntryBmp,_rExpEntryBmp, eButtonKind);
SvLBoxItem* pTextItem(_pEntry->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
@@ -204,7 +205,7 @@ void DBTreeListBox::MouseButtonDown( const MouseEvent& rMEvt )
}
// -------------------------------------------------------------------------
-IMPL_LINK(DBTreeListBox, OnResetEntry, SvLBoxEntry*, pEntry)
+IMPL_LINK(DBTreeListBox, OnResetEntry, SvTreeListEntry*, pEntry)
{
// set the flag which allows if the entry can be expanded
pEntry->SetFlags( (pEntry->GetFlags() & ~(SV_ENTRYFLAG_NO_NODEBMP | SV_ENTRYFLAG_HAD_CHILDREN)) | SV_ENTRYFLAG_CHILDREN_ON_DEMAND );
@@ -213,29 +214,31 @@ IMPL_LINK(DBTreeListBox, OnResetEntry, SvLBoxEntry*, pEntry)
return 0L;
}
// -----------------------------------------------------------------------------
-void DBTreeListBox::ModelHasEntryInvalidated( SvListEntry* _pEntry )
+void DBTreeListBox::ModelHasEntryInvalidated( SvTreeListEntry* _pEntry )
{
SvTreeListBox::ModelHasEntryInvalidated( _pEntry );
- if ( m_aSelectedEntries.find( _pEntry ) != m_aSelectedEntries.end() )
+ SvTreeListEntry* pLBEntry = static_cast<SvTreeListEntry*>(_pEntry);
+ if (m_aSelectedEntries.find(pLBEntry) != m_aSelectedEntries.end())
{
- SvLBoxItem* pTextItem = static_cast< SvLBoxEntry* >( _pEntry )->GetFirstItem( SV_ITEM_ID_BOLDLBSTRING );
+ SvLBoxItem* pTextItem = pLBEntry->GetFirstItem(SV_ITEM_ID_BOLDLBSTRING);
if ( pTextItem && !static_cast< OBoldListboxString* >( pTextItem )->isEmphasized() )
{
implStopSelectionTimer();
- m_aSelectedEntries.erase( _pEntry );
+ m_aSelectedEntries.erase(pLBEntry);
// ehm - why?
}
}
}
// -------------------------------------------------------------------------
-void DBTreeListBox::ModelHasRemoved( SvListEntry* _pEntry )
+void DBTreeListBox::ModelHasRemoved( SvTreeListEntry* _pEntry )
{
SvTreeListBox::ModelHasRemoved(_pEntry);
- if ( m_aSelectedEntries.find( _pEntry ) != m_aSelectedEntries.end() )
+ SvTreeListEntry* pLBEntry = static_cast<SvTreeListEntry*>(_pEntry);
+ if (m_aSelectedEntries.find(pLBEntry) != m_aSelectedEntries.end())
{
implStopSelectionTimer();
- m_aSelectedEntries.erase( _pEntry );
+ m_aSelectedEntries.erase(pLBEntry);
}
}
@@ -245,9 +248,9 @@ sal_Int8 DBTreeListBox::AcceptDrop( const AcceptDropEvent& _rEvt )
sal_Int8 nDropOption = DND_ACTION_NONE;
if ( m_pActionListener )
{
- SvLBoxEntry* pDroppedEntry = GetEntry(_rEvt.maPosPixel);
+ SvTreeListEntry* pDroppedEntry = GetEntry(_rEvt.maPosPixel);
// check if drag is on child entry, which is not allowed
- SvLBoxEntry* pParent = NULL;
+ SvTreeListEntry* pParent = NULL;
if ( _rEvt.mnAction & DND_ACTION_MOVE )
{
if ( !m_pDragedEntry ) // no entry to move
@@ -317,7 +320,7 @@ void DBTreeListBox::RequestHelp( const HelpEvent& rHEvt )
if( rHEvt.GetMode() & HELPMODE_QUICK )
{
Point aPos( ScreenToOutputPixel( rHEvt.GetMousePosPixel() ));
- SvLBoxEntry* pEntry = GetEntry( aPos );
+ SvTreeListEntry* pEntry = GetEntry( aPos );
if( pEntry )
{
String sQuickHelpText;
@@ -400,12 +403,12 @@ void DBTreeListBox::KeyInput( const KeyEvent& rKEvt )
SvTreeListBox::KeyInput(rKEvt);
}
// -----------------------------------------------------------------------------
-sal_Bool DBTreeListBox::EditingEntry( SvLBoxEntry* pEntry, Selection& /*_aSelection*/)
+sal_Bool DBTreeListBox::EditingEntry( SvTreeListEntry* pEntry, Selection& /*_aSelection*/)
{
return m_aEditingHandler.Call(pEntry) != 0;
}
// -----------------------------------------------------------------------------
-sal_Bool DBTreeListBox::EditedEntry( SvLBoxEntry* pEntry, const rtl::OUString& rNewText )
+sal_Bool DBTreeListBox::EditedEntry( SvTreeListEntry* pEntry, const rtl::OUString& rNewText )
{
DBTreeEditedEntry aEntry;
aEntry.pEntry = pEntry;
@@ -431,7 +434,7 @@ sal_Bool DBTreeListBox::DoubleClickHdl()
// -----------------------------------------------------------------------------
void scrollWindow(DBTreeListBox* _pListBox, const Point& _rPos,sal_Bool _bUp)
{
- SvLBoxEntry* pEntry = _pListBox->GetEntry( _rPos );
+ SvTreeListEntry* pEntry = _pListBox->GetEntry( _rPos );
if( pEntry && pEntry != _pListBox->Last() )
{
_pListBox->ScrollOutputArea( _bUp ? -1 : 1 );
diff --git a/dbaccess/source/ui/control/listviewitems.cxx b/dbaccess/source/ui/control/listviewitems.cxx
index aaf208db812c..07b2b0aab880 100644
--- a/dbaccess/source/ui/control/listviewitems.cxx
+++ b/dbaccess/source/ui/control/listviewitems.cxx
@@ -28,7 +28,7 @@ namespace dbaui
// class OBoldListboxString
//========================================================================
//------------------------------------------------------------------------
- void OBoldListboxString::InitViewData( SvTreeListBox* pView,SvLBoxEntry* pEntry, SvViewDataItem* _pViewData)
+ void OBoldListboxString::InitViewData( SvTreeListBox* pView,SvTreeListEntry* pEntry, SvViewDataItem* _pViewData)
{
SvLBoxString::InitViewData( pView, pEntry, _pViewData );
if ( !m_bEmphasized )
@@ -50,7 +50,7 @@ namespace dbaui
}
//------------------------------------------------------------------------
- void OBoldListboxString::Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry )
+ void OBoldListboxString::Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 nFlags, SvTreeListEntry* pEntry )
{
if (m_bEmphasized)
{
diff --git a/dbaccess/source/ui/control/marktree.cxx b/dbaccess/source/ui/control/marktree.cxx
index 07367d8319c5..a62ee25bc4be 100644
--- a/dbaccess/source/ui/control/marktree.cxx
+++ b/dbaccess/source/ui/control/marktree.cxx
@@ -82,7 +82,7 @@ void OMarkableTreeListBox::KeyInput( const KeyEvent& rKEvt )
// only if there are spaces
if (rKEvt.GetKeyCode().GetCode() == KEY_SPACE && !rKEvt.GetKeyCode().IsShift() && !rKEvt.GetKeyCode().IsMod1())
{
- SvLBoxEntry* pCurrentHandlerEntry = GetHdlEntry();
+ SvTreeListEntry* pCurrentHandlerEntry = GetHdlEntry();
if(pCurrentHandlerEntry)
{
SvButtonState eState = GetCheckButtonState( pCurrentHandlerEntry);
@@ -100,7 +100,7 @@ void OMarkableTreeListBox::KeyInput( const KeyEvent& rKEvt )
DBTreeListBox::KeyInput(rKEvt);
}
-SvButtonState OMarkableTreeListBox::implDetermineState(SvLBoxEntry* _pEntry)
+SvButtonState OMarkableTreeListBox::implDetermineState(SvTreeListEntry* _pEntry)
{
SvButtonState eState = GetCheckButtonState(_pEntry);
if (!GetModel()->HasChildren(_pEntry))
@@ -114,7 +114,7 @@ SvButtonState OMarkableTreeListBox::implDetermineState(SvLBoxEntry* _pEntry)
sal_uInt16 nCheckedChildren = 0;
sal_uInt16 nChildrenOverall = 0;
- SvLBoxEntry* pChildLoop = GetModel()->FirstChild(_pEntry);
+ SvTreeListEntry* pChildLoop = GetModel()->FirstChild(_pEntry);
while (pChildLoop)
{
#ifdef DBG_UTIL
@@ -167,7 +167,7 @@ SvButtonState OMarkableTreeListBox::implDetermineState(SvLBoxEntry* _pEntry)
void OMarkableTreeListBox::CheckButtons()
{
- SvLBoxEntry* pEntry = GetModel()->First();
+ SvTreeListEntry* pEntry = GetModel()->First();
while (pEntry)
{
implDetermineState(pEntry);
@@ -182,13 +182,13 @@ void OMarkableTreeListBox::CheckButtonHdl()
m_aCheckButtonHandler.Call(this);
}
-void OMarkableTreeListBox::checkedButton_noBroadcast(SvLBoxEntry* _pEntry)
+void OMarkableTreeListBox::checkedButton_noBroadcast(SvTreeListEntry* _pEntry)
{
SvButtonState eState = GetCheckButtonState( _pEntry);
if (GetModel()->HasChildren(_pEntry)) // if it has children, check those too
{
- SvLBoxEntry* pChildEntry = GetModel()->Next(_pEntry);
- SvLBoxEntry* pSiblingEntry = GetModel()->NextSibling(_pEntry);
+ SvTreeListEntry* pChildEntry = GetModel()->Next(_pEntry);
+ SvTreeListEntry* pSiblingEntry = GetModel()->NextSibling(_pEntry);
while(pChildEntry && pChildEntry != pSiblingEntry)
{
SetCheckButtonState(pChildEntry, eState);
@@ -196,14 +196,14 @@ void OMarkableTreeListBox::checkedButton_noBroadcast(SvLBoxEntry* _pEntry)
}
}
- SvLBoxEntry* pEntry = IsSelected(_pEntry) ? FirstSelected() : NULL;
+ SvTreeListEntry* pEntry = IsSelected(_pEntry) ? FirstSelected() : NULL;
while(pEntry)
{
SetCheckButtonState(pEntry,eState);
if(GetModel()->HasChildren(pEntry)) // if it has children, check those too
{
- SvLBoxEntry* pChildEntry = GetModel()->Next(pEntry);
- SvLBoxEntry* pSiblingEntry = GetModel()->NextSibling(pEntry);
+ SvTreeListEntry* pChildEntry = GetModel()->Next(pEntry);
+ SvTreeListEntry* pSiblingEntry = GetModel()->NextSibling(pEntry);
while(pChildEntry && pChildEntry != pSiblingEntry)
{
SetCheckButtonState(pChildEntry,eState);
diff --git a/dbaccess/source/ui/control/tabletree.cxx b/dbaccess/source/ui/control/tabletree.cxx
index 239a0a2511a8..a2d41151c00e 100644
--- a/dbaccess/source/ui/control/tabletree.cxx
+++ b/dbaccess/source/ui/control/tabletree.cxx
@@ -101,7 +101,7 @@ void OTableTreeListBox::implSetDefaultImages()
}
// -----------------------------------------------------------------------------
-bool OTableTreeListBox::isFolderEntry( const SvLBoxEntry* _pEntry ) const
+bool OTableTreeListBox::isFolderEntry( const SvTreeListEntry* _pEntry ) const
{
sal_Int32 nEntryType = reinterpret_cast< sal_IntPtr >( _pEntry->GetUserData() );
if ( ( nEntryType == DatabaseObjectContainer::TABLES )
@@ -117,7 +117,7 @@ void OTableTreeListBox::notifyHiContrastChanged()
{
implSetDefaultImages();
- SvLBoxEntry* pEntryLoop = First();
+ SvTreeListEntry* pEntryLoop = First();
while (pEntryLoop)
{
sal_uInt16 nCount = pEntryLoop->ItemCount();
@@ -325,13 +325,13 @@ void OTableTreeListBox::UpdateTableList( const Reference< XConnection >& _rxConn
bCatalogs ? xMeta->getCatalogs() : xMeta->getSchemas(), 1 ) );
sal_Int32 nFolderType = bCatalogs ? DatabaseObjectContainer::CATALOG : DatabaseObjectContainer::SCHEMA;
- SvLBoxEntry* pRootEntry = getAllObjectsEntry();
+ SvTreeListEntry* pRootEntry = getAllObjectsEntry();
for ( ::std::vector< ::rtl::OUString >::const_iterator folder = aFolderNames.begin();
folder != aFolderNames.end();
++folder
)
{
- SvLBoxEntry* pFolder = GetEntryPosByName( *folder, pRootEntry );
+ SvTreeListEntry* pFolder = GetEntryPosByName( *folder, pRootEntry );
if ( !pFolder )
pFolder = InsertEntry( *folder, pRootEntry, sal_False, LIST_APPEND, reinterpret_cast< void* >( nFolderType ) );
}
@@ -344,7 +344,7 @@ void OTableTreeListBox::UpdateTableList( const Reference< XConnection >& _rxConn
}
}
//------------------------------------------------------------------------
-sal_Bool OTableTreeListBox::isWildcardChecked(SvLBoxEntry* _pEntry) const
+sal_Bool OTableTreeListBox::isWildcardChecked(SvTreeListEntry* _pEntry) const
{
if (_pEntry)
{
@@ -356,20 +356,20 @@ sal_Bool OTableTreeListBox::isWildcardChecked(SvLBoxEntry* _pEntry) const
}
//------------------------------------------------------------------------
-void OTableTreeListBox::checkWildcard(SvLBoxEntry* _pEntry)
+void OTableTreeListBox::checkWildcard(SvTreeListEntry* _pEntry)
{
SetCheckButtonState(_pEntry, SV_BUTTON_CHECKED);
checkedButton_noBroadcast(_pEntry);
}
//------------------------------------------------------------------------
-SvLBoxEntry* OTableTreeListBox::getAllObjectsEntry() const
+SvTreeListEntry* OTableTreeListBox::getAllObjectsEntry() const
{
return haveVirtualRoot() ? First() : NULL;
}
//------------------------------------------------------------------------
-void OTableTreeListBox::checkedButton_noBroadcast(SvLBoxEntry* _pEntry)
+void OTableTreeListBox::checkedButton_noBroadcast(SvTreeListEntry* _pEntry)
{
OMarkableTreeListBox::checkedButton_noBroadcast(_pEntry);
@@ -383,7 +383,7 @@ void OTableTreeListBox::checkedButton_noBroadcast(SvLBoxEntry* _pEntry)
}
//------------------------------------------------------------------------
-void OTableTreeListBox::implEmphasize(SvLBoxEntry* _pEntry, sal_Bool _bChecked, sal_Bool _bUpdateDescendants, sal_Bool _bUpdateAncestors)
+void OTableTreeListBox::implEmphasize(SvTreeListEntry* _pEntry, sal_Bool _bChecked, sal_Bool _bUpdateDescendants, sal_Bool _bUpdateAncestors)
{
OSL_ENSURE(_pEntry, "OTableTreeListBox::implEmphasize: invalid entry (NULL)!");
@@ -404,7 +404,7 @@ void OTableTreeListBox::implEmphasize(SvLBoxEntry* _pEntry, sal_Bool _bChecked,
if (_bUpdateDescendants)
{
// remove the mark for all children of the checked entry
- SvLBoxEntry* pChildLoop = FirstChild(_pEntry);
+ SvTreeListEntry* pChildLoop = FirstChild(_pEntry);
while (pChildLoop)
{
if (GetModel()->HasChildren(pChildLoop))
@@ -422,7 +422,7 @@ void OTableTreeListBox::implEmphasize(SvLBoxEntry* _pEntry, sal_Bool _bChecked,
}
//------------------------------------------------------------------------
-void OTableTreeListBox::InitEntry(SvLBoxEntry* _pEntry, const XubString& _rString, const Image& _rCollapsedBitmap, const Image& _rExpandedBitmap, SvLBoxButtonKind _eButtonKind)
+void OTableTreeListBox::InitEntry(SvTreeListEntry* _pEntry, const OUString& _rString, const Image& _rCollapsedBitmap, const Image& _rExpandedBitmap, SvLBoxButtonKind _eButtonKind)
{
OMarkableTreeListBox::InitEntry(_pEntry, _rString, _rCollapsedBitmap, _rExpandedBitmap, _eButtonKind);
@@ -436,7 +436,7 @@ void OTableTreeListBox::InitEntry(SvLBoxEntry* _pEntry, const XubString& _rStrin
}
//------------------------------------------------------------------------
-SvLBoxEntry* OTableTreeListBox::implAddEntry(
+SvTreeListEntry* OTableTreeListBox::implAddEntry(
const Reference< XDatabaseMetaData >& _rxMeta,
const ::rtl::OUString& _rTableName,
sal_Bool _bCheckName
@@ -450,7 +450,7 @@ SvLBoxEntry* OTableTreeListBox::implAddEntry(
::rtl::OUString sCatalog, sSchema, sName;
qualifiedNameComponents( _rxMeta, _rTableName, sCatalog, sSchema, sName, ::dbtools::eInDataManipulation );
- SvLBoxEntry* pParentEntry = getAllObjectsEntry();
+ SvTreeListEntry* pParentEntry = getAllObjectsEntry();
// if the DB uses catalog at the start of identifiers, then our hierarchy is
// catalog
@@ -468,7 +468,7 @@ SvLBoxEntry* OTableTreeListBox::implAddEntry(
if ( !rFirstName.isEmpty() )
{
- SvLBoxEntry* pFolder = GetEntryPosByName( rFirstName, pParentEntry );
+ SvTreeListEntry* pFolder = GetEntryPosByName( rFirstName, pParentEntry );
if ( !pFolder )
pFolder = InsertEntry( rFirstName, pParentEntry, sal_False, LIST_APPEND, reinterpret_cast< void* >( nFirstFolderType ) );
pParentEntry = pFolder;
@@ -476,13 +476,13 @@ SvLBoxEntry* OTableTreeListBox::implAddEntry(
if ( !rSecondName.isEmpty() )
{
- SvLBoxEntry* pFolder = GetEntryPosByName( rSecondName, pParentEntry );
+ SvTreeListEntry* pFolder = GetEntryPosByName( rSecondName, pParentEntry );
if ( !pFolder )
pFolder = InsertEntry( rSecondName, pParentEntry, sal_False, LIST_APPEND, reinterpret_cast< void* >( nSecondFolderType ) );
pParentEntry = pFolder;
}
- SvLBoxEntry* pRet = NULL;
+ SvTreeListEntry* pRet = NULL;
if ( !_bCheckName || !GetEntryPosByName( sName, pParentEntry ) )
{
pRet = InsertEntry( sName, pParentEntry, sal_False, LIST_APPEND );
@@ -497,7 +497,7 @@ SvLBoxEntry* OTableTreeListBox::implAddEntry(
}
//------------------------------------------------------------------------
-NamedDatabaseObject OTableTreeListBox::describeObject( SvLBoxEntry* _pEntry )
+NamedDatabaseObject OTableTreeListBox::describeObject( SvTreeListEntry* _pEntry )
{
NamedDatabaseObject aObject;
@@ -511,7 +511,7 @@ NamedDatabaseObject OTableTreeListBox::describeObject( SvLBoxEntry* _pEntry )
|| ( nEntryType == DatabaseObjectContainer::SCHEMA )
)
{
- SvLBoxEntry* pParent = GetParent( _pEntry );
+ SvTreeListEntry* pParent = GetParent( _pEntry );
sal_Int32 nParentEntryType = pParent ? reinterpret_cast< sal_IntPtr >( pParent->GetUserData() ) : -1;
::rtl::OUStringBuffer buffer;
@@ -544,7 +544,7 @@ NamedDatabaseObject OTableTreeListBox::describeObject( SvLBoxEntry* _pEntry )
}
//------------------------------------------------------------------------
-SvLBoxEntry* OTableTreeListBox::addedTable( const ::rtl::OUString& _rName )
+SvTreeListEntry* OTableTreeListBox::addedTable( const ::rtl::OUString& _rName )
{
try
{
@@ -569,7 +569,7 @@ bool OTableTreeListBox::impl_getAndAssertMetaData( Reference< XDatabaseMetaData
}
//------------------------------------------------------------------------
-String OTableTreeListBox::getQualifiedTableName( SvLBoxEntry* _pEntry ) const
+String OTableTreeListBox::getQualifiedTableName( SvTreeListEntry* _pEntry ) const
{
OSL_PRECOND( !isFolderEntry( _pEntry ), "OTableTreeListBox::getQualifiedTableName: folder entries not allowed here!" );
@@ -583,10 +583,10 @@ String OTableTreeListBox::getQualifiedTableName( SvLBoxEntry* _pEntry ) const
::rtl::OUString sSchema;
::rtl::OUString sTable;
- SvLBoxEntry* pSchema = GetParent( _pEntry );
+ SvTreeListEntry* pSchema = GetParent( _pEntry );
if ( pSchema )
{
- SvLBoxEntry* pCatalog = GetParent( pSchema );
+ SvTreeListEntry* pCatalog = GetParent( pSchema );
if ( pCatalog
|| ( xMeta->supportsCatalogsInDataManipulation()
&& !xMeta->supportsSchemasInDataManipulation()
@@ -615,7 +615,7 @@ String OTableTreeListBox::getQualifiedTableName( SvLBoxEntry* _pEntry ) const
}
//------------------------------------------------------------------------
-SvLBoxEntry* OTableTreeListBox::getEntryByQualifiedName( const ::rtl::OUString& _rName )
+SvTreeListEntry* OTableTreeListBox::getEntryByQualifiedName( const ::rtl::OUString& _rName )
{
try
{
@@ -627,9 +627,9 @@ SvLBoxEntry* OTableTreeListBox::getEntryByQualifiedName( const ::rtl::OUString&
::rtl::OUString sCatalog, sSchema, sName;
qualifiedNameComponents(xMeta, _rName, sCatalog, sSchema, sName,::dbtools::eInDataManipulation);
- SvLBoxEntry* pParent = getAllObjectsEntry();
- SvLBoxEntry* pCat = NULL;
- SvLBoxEntry* pSchema = NULL;
+ SvTreeListEntry* pParent = getAllObjectsEntry();
+ SvTreeListEntry* pCat = NULL;
+ SvTreeListEntry* pSchema = NULL;
if ( !sCatalog.isEmpty() )
{
pCat = GetEntryPosByName(sCatalog, pParent);
@@ -657,7 +657,7 @@ void OTableTreeListBox::removedTable( const ::rtl::OUString& _rName )
{
try
{
- SvLBoxEntry* pEntry = getEntryByQualifiedName( _rName );
+ SvTreeListEntry* pEntry = getEntryByQualifiedName( _rName );
if ( pEntry )
GetModel()->Remove( pEntry );
}
diff --git a/dbaccess/source/ui/dlg/ConnectionHelper.cxx b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
index ac7e55f21a55..c33685de305a 100644
--- a/dbaccess/source/ui/dlg/ConnectionHelper.cxx
+++ b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
@@ -45,7 +45,7 @@
#include "dsselect.hxx"
#include <svl/filenotation.hxx>
#include "dbustrings.hrc"
-#include <com/sun/star/ui/dialogs/XFolderPicker.hpp>
+#include <com/sun/star/ui/dialogs/FolderPicker.hpp>
#include <com/sun/star/ui/dialogs/TemplateDescription.hpp>
#include <com/sun/star/sdbc/XRow.hpp>
#include <com/sun/star/awt/XWindow.hpp>
@@ -172,13 +172,7 @@ DBG_NAME(OConnectionHelper)
{
try
{
- ::rtl::OUString sFolderPickerService(SERVICE_UI_FOLDERPICKER);
- Reference< XFolderPicker > xFolderPicker(m_xORB->createInstance(sFolderPickerService), UNO_QUERY);
- if (!xFolderPicker.is())
- {
- ShowServiceNotAvailableError(GetParent(), sFolderPickerService, sal_True);
- break;
- }
+ Reference< XFolderPicker2 > xFolderPicker = FolderPicker::create(comphelper::getComponentContext(m_xORB));
sal_Bool bDoBrowse = sal_False;
String sOldPath = getURLNoPrefix();
diff --git a/dbaccess/source/ui/dlg/adtabdlg.cxx b/dbaccess/source/ui/dlg/adtabdlg.cxx
index 580791a345a0..55fbf4b1dfff 100644
--- a/dbaccess/source/ui/dlg/adtabdlg.cxx
+++ b/dbaccess/source/ui/dlg/adtabdlg.cxx
@@ -96,15 +96,15 @@ TableListFacade::~TableListFacade()
String TableListFacade::getSelectedName( String& _out_rAliasName ) const
{
- SvLBoxEntry* pEntry = m_rTableList.FirstSelected();
+ SvTreeListEntry* pEntry = m_rTableList.FirstSelected();
if ( !pEntry )
return String();
::rtl::OUString aCatalog, aSchema, aTableName;
- SvLBoxEntry* pSchema = m_rTableList.GetParent(pEntry);
+ SvTreeListEntry* pSchema = m_rTableList.GetParent(pEntry);
if(pSchema && pSchema != m_rTableList.getAllObjectsEntry())
{
- SvLBoxEntry* pCatalog = m_rTableList.GetParent(pSchema);
+ SvTreeListEntry* pCatalog = m_rTableList.GetParent(pSchema);
if(pCatalog && pCatalog != m_rTableList.getAllObjectsEntry())
aCatalog = m_rTableList.GetEntryText(pCatalog);
aSchema = m_rTableList.GetEntryText(pSchema);
@@ -200,7 +200,7 @@ void TableListFacade::updateTableObjectList( bool _bAllowViews )
}
m_rTableList.UpdateTableList( m_xConnection, sTables, sViews );
- SvLBoxEntry* pEntry = m_rTableList.First();
+ SvTreeListEntry* pEntry = m_rTableList.First();
while( pEntry && m_rTableList.GetModel()->HasChildren( pEntry ) )
{
m_rTableList.Expand( pEntry );
@@ -217,7 +217,7 @@ void TableListFacade::updateTableObjectList( bool _bAllowViews )
bool TableListFacade::isLeafSelected() const
{
- SvLBoxEntry* pEntry = m_rTableList.FirstSelected();
+ SvTreeListEntry* pEntry = m_rTableList.FirstSelected();
return pEntry && !m_rTableList.GetModel()->HasChildren( pEntry );
}
@@ -306,7 +306,7 @@ void QueryListFacade::updateTableObjectList( bool /*_bAllowViews*/ )
String QueryListFacade::getSelectedName( String& _out_rAliasName ) const
{
String sSelected;
- SvLBoxEntry* pEntry = m_rQueryList.FirstSelected();
+ SvTreeListEntry* pEntry = m_rQueryList.FirstSelected();
if ( pEntry )
sSelected = _out_rAliasName = m_rQueryList.GetEntryText( pEntry );
return sSelected;
@@ -314,7 +314,7 @@ String QueryListFacade::getSelectedName( String& _out_rAliasName ) const
bool QueryListFacade::isLeafSelected() const
{
- SvLBoxEntry* pEntry = m_rQueryList.FirstSelected();
+ SvTreeListEntry* pEntry = m_rQueryList.FirstSelected();
return pEntry && !m_rQueryList.GetModel()->HasChildren( pEntry );
}
diff --git a/dbaccess/source/ui/dlg/indexdialog.cxx b/dbaccess/source/ui/dlg/indexdialog.cxx
index 7b64a5dfcafb..73e8624875e3 100644
--- a/dbaccess/source/ui/dlg/indexdialog.cxx
+++ b/dbaccess/source/ui/dlg/indexdialog.cxx
@@ -95,7 +95,7 @@ namespace dbaui
extern sal_Bool isCharOk(sal_Unicode _cChar,sal_Bool _bFirstChar,sal_Bool _bUpperCase,const ::rtl::OUString& _sAllowedChars);
//------------------------------------------------------------------
- sal_Bool DbaIndexList::EditedEntry( SvLBoxEntry* _pEntry, const rtl::OUString& _rNewText )
+ sal_Bool DbaIndexList::EditedEntry( SvTreeListEntry* _pEntry, const rtl::OUString& _rNewText )
{
// first check if this is valid SQL92 name
if ( isSQL92CheckEnabled(m_xConnection) )
@@ -146,7 +146,7 @@ namespace dbaui
}
//------------------------------------------------------------------
- void DbaIndexList::SelectNoHandlerCall( SvLBoxEntry* _pEntry )
+ void DbaIndexList::SelectNoHandlerCall( SvTreeListEntry* _pEntry )
{
disableSelectHandler();
Select(_pEntry, sal_True);
@@ -154,7 +154,7 @@ namespace dbaui
}
//------------------------------------------------------------------
- sal_Bool DbaIndexList::Select( SvLBoxEntry* pEntry, sal_Bool _bSelect )
+ sal_Bool DbaIndexList::Select( SvTreeListEntry* pEntry, sal_Bool _bSelect )
{
sal_Bool bReturn = SvTreeListBox::Select(pEntry, _bSelect);
@@ -273,7 +273,7 @@ DBG_NAME(DbaIndexDialog)
{
m_aActions.EnableItem(ID_INDEX_NEW, !m_aIndexes.IsEditingActive());
- SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
+ SvTreeListEntry* pSelected = m_aIndexes.FirstSelected();
sal_Bool bSelectedAnything = NULL != pSelected;
@@ -304,7 +304,7 @@ DBG_NAME(DbaIndexDialog)
Indexes::iterator aEnd = m_pIndexes->end();
for (; aIndexLoop != aEnd; ++aIndexLoop)
{
- SvLBoxEntry* pNewEntry = NULL;
+ SvTreeListEntry* pNewEntry = NULL;
if (aIndexLoop->bPrimaryKey)
pNewEntry = m_aIndexes.InsertEntry(aIndexLoop->sName, aPKeyIcon, aPKeyIcon);
else
@@ -327,7 +327,7 @@ DBG_NAME(DbaIndexDialog)
}
//------------------------------------------------------------------
- sal_Bool DbaIndexDialog::implCommit(SvLBoxEntry* _pEntry)
+ sal_Bool DbaIndexDialog::implCommit(SvTreeListEntry* _pEntry)
{
OSL_ENSURE(_pEntry, "DbaIndexDialog::implCommit: invalid entry!");
@@ -389,12 +389,12 @@ DBG_NAME(DbaIndexDialog)
return;
}
- SvLBoxEntry* pNewEntry = m_aIndexes.InsertEntry(sNewIndexName);
+ SvTreeListEntry* pNewEntry = m_aIndexes.InsertEntry(sNewIndexName);
m_pIndexes->insert(sNewIndexName);
// update the user data on the entries in the list box:
// they're iterators of the index collection, and thus they have changed when removing the index
- for (SvLBoxEntry* pAdjust = m_aIndexes.First(); pAdjust; pAdjust = m_aIndexes.Next(pAdjust))
+ for (SvTreeListEntry* pAdjust = m_aIndexes.First(); pAdjust; pAdjust = m_aIndexes.Next(pAdjust))
{
Indexes::iterator aAfterInsertPos = m_pIndexes->find(m_aIndexes.GetEntryText(pAdjust));
OSL_ENSURE(aAfterInsertPos != m_pIndexes->end(), "DbaIndexDialog::OnNewIndex: problems with on of the entries!");
@@ -412,7 +412,7 @@ DBG_NAME(DbaIndexDialog)
void DbaIndexDialog::OnDropIndex(sal_Bool _bConfirm)
{
// the selected index
- SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
+ SvTreeListEntry* pSelected = m_aIndexes.FirstSelected();
OSL_ENSURE(pSelected, "DbaIndexDialog::OnDropIndex: invalid call!");
if (pSelected)
{
@@ -435,7 +435,7 @@ DBG_NAME(DbaIndexDialog)
}
//------------------------------------------------------------------
- sal_Bool DbaIndexDialog::implDropIndex(SvLBoxEntry* _pEntry, sal_Bool _bRemoveFromCollection)
+ sal_Bool DbaIndexDialog::implDropIndex(SvTreeListEntry* _pEntry, sal_Bool _bRemoveFromCollection)
{
// do the drop
Indexes::iterator aDropPos = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(_pEntry->GetUserData());
@@ -458,7 +458,7 @@ DBG_NAME(DbaIndexDialog)
showError(aExceptionInfo, this, m_xORB);
else if (bSuccess && _bRemoveFromCollection)
{
- SvLBoxTreeList* pModel = m_aIndexes.GetModel();
+ SvTreeList* pModel = m_aIndexes.GetModel();
m_aIndexes.disableSelectHandler();
pModel->Remove(_pEntry);
@@ -466,7 +466,7 @@ DBG_NAME(DbaIndexDialog)
// update the user data on the entries in the list box:
// they're iterators of the index collection, and thus they have changed when removing the index
- for (SvLBoxEntry* pAdjust = m_aIndexes.First(); pAdjust; pAdjust = m_aIndexes.Next(pAdjust))
+ for (SvTreeListEntry* pAdjust = m_aIndexes.First(); pAdjust; pAdjust = m_aIndexes.Next(pAdjust))
{
Indexes::iterator aAfterDropPos = m_pIndexes->find(m_aIndexes.GetEntryText(pAdjust));
OSL_ENSURE(aAfterDropPos != m_pIndexes->end(), "DbaIndexDialog::OnDropIndex: problems with on of the remaining entries!");
@@ -489,7 +489,7 @@ DBG_NAME(DbaIndexDialog)
void DbaIndexDialog::OnRenameIndex()
{
// the selected index
- SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
+ SvTreeListEntry* pSelected = m_aIndexes.FirstSelected();
OSL_ENSURE(pSelected, "DbaIndexDialog::OnRenameIndex: invalid call!");
// save the changes made 'til here
@@ -506,7 +506,7 @@ DBG_NAME(DbaIndexDialog)
{
// the selected index
#if OSL_DEBUG_LEVEL > 0
- SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
+ SvTreeListEntry* pSelected = m_aIndexes.FirstSelected();
OSL_ENSURE( pSelected, "DbaIndexDialog::OnSaveIndex: invalid call!" );
#endif
@@ -518,7 +518,7 @@ DBG_NAME(DbaIndexDialog)
void DbaIndexDialog::OnResetIndex()
{
// the selected index
- SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
+ SvTreeListEntry* pSelected = m_aIndexes.FirstSelected();
OSL_ENSURE(pSelected, "DbaIndexDialog::OnResetIndex: invalid call!");
Indexes::iterator aResetPos = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(pSelected->GetUserData());
@@ -587,7 +587,7 @@ DBG_NAME(DbaIndexDialog)
}
// the currently selected entry
- const SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
+ const SvTreeListEntry* pSelected = m_aIndexes.FirstSelected();
OSL_ENSURE(pSelected == m_pPreviousSelection, "DbaIndexDialog::OnCloseDialog: inconsistence!");
sal_Int32 nResponse = RET_NO;
@@ -621,7 +621,7 @@ DBG_NAME(DbaIndexDialog)
}
//------------------------------------------------------------------
- IMPL_LINK( DbaIndexDialog, OnEditIndexAgain, SvLBoxEntry*, _pEntry )
+ IMPL_LINK( DbaIndexDialog, OnEditIndexAgain, SvTreeListEntry*, _pEntry )
{
m_bEditAgain = sal_False;
m_aIndexes.EditEntry(_pEntry);
@@ -629,7 +629,7 @@ DBG_NAME(DbaIndexDialog)
}
//------------------------------------------------------------------
- IMPL_LINK( DbaIndexDialog, OnEntryEdited, SvLBoxEntry*, _pEntry )
+ IMPL_LINK( DbaIndexDialog, OnEntryEdited, SvTreeListEntry*, _pEntry )
{
Indexes::iterator aPosition = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(_pEntry->GetUserData());
@@ -767,7 +767,7 @@ DBG_NAME(DbaIndexDialog)
}
//------------------------------------------------------------------
- void DbaIndexDialog::updateControls(const SvLBoxEntry* _pEntry)
+ void DbaIndexDialog::updateControls(const SvTreeListEntry* _pEntry)
{
if (_pEntry)
{
@@ -823,7 +823,7 @@ DBG_NAME(DbaIndexDialog)
m_aFieldsLabel.Enable(bHaveSelection);
m_pFields->Enable(bHaveSelection);
- SvLBoxEntry* pNewSelection = m_aIndexes.FirstSelected();
+ SvTreeListEntry* pNewSelection = m_aIndexes.FirstSelected();
updateControls(pNewSelection);
if (bHaveSelection)
m_aIndexes.GrabFocus();
diff --git a/dbaccess/source/ui/dlg/paramdialog.cxx b/dbaccess/source/ui/dlg/paramdialog.cxx
index 94895690ea92..1453c8434291 100644
--- a/dbaccess/source/ui/dlg/paramdialog.cxx
+++ b/dbaccess/source/ui/dlg/paramdialog.cxx
@@ -56,19 +56,6 @@ namespace dbaui
//==================================================================
//------------------------------------------------------------------------------
- #define INIT_MEMBERS() \
- :ModalDialog( pParent, ModuleRes(DLG_PARAMETERS)) \
- ,m_aNamesFrame (this, ModuleRes(FL_PARAMS)) \
- ,m_aAllParams (this, ModuleRes(LB_ALLPARAMS)) \
- ,m_aValueFrame (this, ModuleRes(FT_VALUE)) \
- ,m_aParam (this, ModuleRes(ET_PARAM)) \
- ,m_aTravelNext (this, ModuleRes(BT_TRAVELNEXT)) \
- ,m_aOKBtn (this, ModuleRes(BT_OK)) \
- ,m_aCancelBtn (this, ModuleRes(BT_CANCEL)) \
- ,m_nCurrentlySelected(LISTBOX_ENTRY_NOTFOUND) \
- ,m_xConnection(_rxConnection) \
- ,m_aPredicateInput( _rxORB, _rxConnection, getParseContext() ) \
- ,m_bNeedErrorOnCurrent(sal_True) \
//------------------------------------------------------------------------------
@@ -76,13 +63,24 @@ DBG_NAME(OParameterDialog)
OParameterDialog::OParameterDialog(
Window* pParent, const Reference< XIndexAccess > & rParamContainer,
- const Reference< XConnection > & _rxConnection, const Reference< XMultiServiceFactory >& _rxORB)
- INIT_MEMBERS()
+ const Reference< XConnection > & _rxConnection, const Reference< XComponentContext >& rxContext)
+ :ModalDialog( pParent, ModuleRes(DLG_PARAMETERS))
+ ,m_aNamesFrame (this, ModuleRes(FL_PARAMS))
+ ,m_aAllParams (this, ModuleRes(LB_ALLPARAMS))
+ ,m_aValueFrame (this, ModuleRes(FT_VALUE))
+ ,m_aParam (this, ModuleRes(ET_PARAM))
+ ,m_aTravelNext (this, ModuleRes(BT_TRAVELNEXT))
+ ,m_aOKBtn (this, ModuleRes(BT_OK))
+ ,m_aCancelBtn (this, ModuleRes(BT_CANCEL))
+ ,m_nCurrentlySelected(LISTBOX_ENTRY_NOTFOUND)
+ ,m_xConnection(_rxConnection)
+ ,m_aPredicateInput( rxContext, _rxConnection, getParseContext() )
+ ,m_bNeedErrorOnCurrent(sal_True)
{
DBG_CTOR(OParameterDialog,NULL);
- if (_rxORB.is())
- m_xFormatter = Reference< XNumberFormatter>( NumberFormatter::create(comphelper::getComponentContext(_rxORB)), UNO_QUERY_THROW);
+ if (rxContext.is())
+ m_xFormatter = Reference< XNumberFormatter>( NumberFormatter::create( rxContext ), UNO_QUERY_THROW);
else {
OSL_FAIL("OParameterDialog::OParameterDialog: need a service factory!");
}
diff --git a/dbaccess/source/ui/dlg/queryfilter.cxx b/dbaccess/source/ui/dlg/queryfilter.cxx
index a8696374338d..c6a38f75ba16 100644
--- a/dbaccess/source/ui/dlg/queryfilter.cxx
+++ b/dbaccess/source/ui/dlg/queryfilter.cxx
@@ -66,7 +66,7 @@ void Replace_SQL_PlaceHolder(String& aString)
DBG_NAME(DlgFilterCrit);
DlgFilterCrit::DlgFilterCrit(Window * pParent,
- const Reference< XMultiServiceFactory >& _rxORB,
+ const Reference< XComponentContext >& rxContext,
const Reference< XConnection>& _rxConnection,
const Reference< XSingleSelectQueryComposer >& _rxComposer,
const Reference< XNameAccess>& _rxCols
@@ -97,7 +97,7 @@ DlgFilterCrit::DlgFilterCrit(Window * pParent,
,m_xColumns( _rxCols )
,m_xConnection( _rxConnection )
,m_xMetaData( _rxConnection->getMetaData() )
- ,m_aPredicateInput( _rxORB, _rxConnection, getParseContext() )
+ ,m_aPredicateInput( rxContext, _rxConnection, getParseContext() )
{
DBG_CTOR(DlgFilterCrit,NULL);
// Write the String for noEntry into the ListBoxes of the field names
diff --git a/dbaccess/source/ui/dlg/sqlmessage.cxx b/dbaccess/source/ui/dlg/sqlmessage.cxx
index 323d819ef61d..f0b5d32c643a 100644
--- a/dbaccess/source/ui/dlg/sqlmessage.cxx
+++ b/dbaccess/source/ui/dlg/sqlmessage.cxx
@@ -296,7 +296,7 @@ namespace
void lcl_insertExceptionEntry( SvTreeListBox& _rList, size_t _nElementPos, const ExceptionDisplayInfo& _rEntry )
{
Image aEntryImage( _rEntry.pImageProvider->getImage() );
- SvLBoxEntry* pListEntry =
+ SvTreeListEntry* pListEntry =
_rList.InsertEntry( _rEntry.pLabelProvider->getLabel(), aEntryImage, aEntryImage );
pListEntry->SetUserData( reinterpret_cast< void* >( _nElementPos ) );
}
@@ -390,7 +390,7 @@ OExceptionChainDialog::~OExceptionChainDialog()
//------------------------------------------------------------------------------
IMPL_LINK_NOARG(OExceptionChainDialog, OnExceptionSelected)
{
- SvLBoxEntry* pSelected = m_aExceptionList.FirstSelected();
+ SvTreeListEntry* pSelected = m_aExceptionList.FirstSelected();
OSL_ENSURE(!pSelected || !m_aExceptionList.NextSelected(pSelected), "OExceptionChainDialog::OnExceptionSelected : multi selection ?");
String sText;
diff --git a/dbaccess/source/ui/dlg/tablespage.cxx b/dbaccess/source/ui/dlg/tablespage.cxx
index 3259a87d3f28..c58e5c4c6640 100644
--- a/dbaccess/source/ui/dlg/tablespage.cxx
+++ b/dbaccess/source/ui/dlg/tablespage.cxx
@@ -173,7 +173,7 @@ DBG_NAME(OTableSubscriptionPage)
String aListBoxTable;
::rtl::OUString sCatalog, sSchema, sName;
- SvLBoxEntry* pRootEntry = m_aTablesList.getAllObjectsEntry();
+ SvTreeListEntry* pRootEntry = m_aTablesList.getAllObjectsEntry();
sal_Bool bAllTables = sal_False;
sal_Bool bAllSchemas = sal_False;
@@ -189,7 +189,7 @@ DBG_NAME(OTableSubscriptionPage)
bAllSchemas = (1 == sSchema.getLength()) && ('%' == sSchema[0]);
// the catalog entry
- SvLBoxEntry* pCatalog = m_aTablesList.GetEntryPosByName(sCatalog, pRootEntry);
+ SvTreeListEntry* pCatalog = m_aTablesList.GetEntryPosByName(sCatalog, pRootEntry);
if (!(pCatalog || sCatalog.isEmpty()))
// the table (resp. its catalog) refered in this filter entry does not exist anymore
continue;
@@ -201,7 +201,7 @@ DBG_NAME(OTableSubscriptionPage)
}
// the schema entry
- SvLBoxEntry* pSchema = m_aTablesList.GetEntryPosByName(sSchema, (pCatalog ? pCatalog : pRootEntry));
+ SvTreeListEntry* pSchema = m_aTablesList.GetEntryPosByName(sSchema, (pCatalog ? pCatalog : pRootEntry));
if (!(pSchema || sSchema.isEmpty()))
// the table (resp. its schema) refered in this filter entry does not exist anymore
continue;
@@ -212,7 +212,7 @@ DBG_NAME(OTableSubscriptionPage)
continue;
}
- SvLBoxEntry* pEntry = m_aTablesList.GetEntryPosByName(sName, pSchema ? pSchema : (pCatalog ? pCatalog : pRootEntry) );
+ SvTreeListEntry* pEntry = m_aTablesList.GetEntryPosByName(sName, pSchema ? pSchema : (pCatalog ? pCatalog : pRootEntry) );
if (pEntry)
m_aTablesList.SetCheckButtonState(pEntry, SV_BUTTON_CHECKED);
}
@@ -384,7 +384,7 @@ DBG_NAME(OTableSubscriptionPage)
implCompleteTablesCheck( aTableFilter );
// expand the first entry by default
- SvLBoxEntry* pExpand = m_aTablesList.getAllObjectsEntry();
+ SvTreeListEntry* pExpand = m_aTablesList.getAllObjectsEntry();
while (pExpand)
{
m_aTablesList.Expand(pExpand);
@@ -401,7 +401,7 @@ DBG_NAME(OTableSubscriptionPage)
void OTableSubscriptionPage::CheckAll( sal_Bool _bCheck )
{
SvButtonState eState = _bCheck ? SV_BUTTON_CHECKED : SV_BUTTON_UNCHECKED;
- SvLBoxEntry* pEntry = m_aTablesList.First();
+ SvTreeListEntry* pEntry = m_aTablesList.First();
while (pEntry)
{
m_aTablesList.SetCheckButtonState( pEntry, eState);
@@ -434,12 +434,12 @@ DBG_NAME(OTableSubscriptionPage)
//------------------------------------------------------------------------
IMPL_LINK( OTableSubscriptionPage, OnTreeEntryCompare, const SvSortData*, _pSortData )
{
- SvLBoxEntry* pLHS = static_cast<SvLBoxEntry*>(_pSortData->pLeft);
- SvLBoxEntry* pRHS = static_cast<SvLBoxEntry*>(_pSortData->pRight);
+ const SvTreeListEntry* pLHS = static_cast<const SvTreeListEntry*>(_pSortData->pLeft);
+ const SvTreeListEntry* pRHS = static_cast<const SvTreeListEntry*>(_pSortData->pRight);
OSL_ENSURE(pLHS && pRHS, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid tree entries!");
- SvLBoxString* pLeftTextItem = static_cast<SvLBoxString*>(pLHS->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
- SvLBoxString* pRightTextItem = static_cast<SvLBoxString*>(pRHS->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
+ const SvLBoxString* pLeftTextItem = static_cast<const SvLBoxString*>(pLHS->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
+ const SvLBoxString* pRightTextItem = static_cast<const SvLBoxString*>(pRHS->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
OSL_ENSURE(pLeftTextItem && pRightTextItem, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid text items!");
String sLeftText = pLeftTextItem->GetText();
@@ -472,16 +472,16 @@ DBG_NAME(OTableSubscriptionPage)
static const ::rtl::OUString sWildcard(RTL_CONSTASCII_USTRINGPARAM("%"));
::rtl::OUString sComposedName;
- const SvLBoxEntry* pAllObjectsEntry = m_aTablesList.getAllObjectsEntry();
+ const SvTreeListEntry* pAllObjectsEntry = m_aTablesList.getAllObjectsEntry();
if (!pAllObjectsEntry)
return aTableFilter;
- SvLBoxEntry* pEntry = m_aTablesList.GetModel()->Next(const_cast<SvLBoxEntry*>(pAllObjectsEntry));
+ SvTreeListEntry* pEntry = m_aTablesList.GetModel()->Next(const_cast<SvTreeListEntry*>(pAllObjectsEntry));
while(pEntry)
{
sal_Bool bCatalogWildcard = sal_False;
sal_Bool bSchemaWildcard = sal_False;
- SvLBoxEntry* pSchema = NULL;
- SvLBoxEntry* pCatalog = NULL;
+ SvTreeListEntry* pSchema = NULL;
+ SvTreeListEntry* pCatalog = NULL;
if (m_aTablesList.GetCheckButtonState(pEntry) == SV_BUTTON_CHECKED && !m_aTablesList.GetModel()->HasChildren(pEntry))
{ // checked and a leaf, which means it's no catalog, no schema, but a real table
@@ -559,9 +559,9 @@ DBG_NAME(OTableSubscriptionPage)
}
//------------------------------------------------------------------------
- SvLBoxEntry* OTableSubscriptionPage::implNextSibling(SvLBoxEntry* _pEntry) const
+ SvTreeListEntry* OTableSubscriptionPage::implNextSibling(SvTreeListEntry* _pEntry) const
{
- SvLBoxEntry* pReturn = NULL;
+ SvTreeListEntry* pReturn = NULL;
if (_pEntry)
{
pReturn = m_aTablesList.NextSibling(_pEntry);
diff --git a/dbaccess/source/ui/dlg/tablespage.hxx b/dbaccess/source/ui/dlg/tablespage.hxx
index 02c9aa4c45f4..6a64c2e2c31c 100644
--- a/dbaccess/source/ui/dlg/tablespage.hxx
+++ b/dbaccess/source/ui/dlg/tablespage.hxx
@@ -88,7 +88,7 @@ namespace dbaui
void implCheckTables(const ::com::sun::star::uno::Sequence< ::rtl::OUString >& _rTables);
/// returns the next sibling, if not available, the next sibling of the parent, a.s.o.
- SvLBoxEntry* implNextSibling(SvLBoxEntry* _pEntry) const;
+ SvTreeListEntry* implNextSibling(SvTreeListEntry* _pEntry) const;
/** return the current selection in <member>m_aTablesList</member>
*/
diff --git a/dbaccess/source/ui/inc/TableCopyHelper.hxx b/dbaccess/source/ui/inc/TableCopyHelper.hxx
index a7d15480e972..65326d9a1b74 100644
--- a/dbaccess/source/ui/inc/TableCopyHelper.hxx
+++ b/dbaccess/source/ui/inc/TableCopyHelper.hxx
@@ -28,7 +28,7 @@
#include <com/sun/star/sdbc/XResultSet.hpp>
#include <functional>
-class SvLBoxEntry;
+class SvTreeListEntry;
//........................................................................
namespace dbaui
{
@@ -79,7 +79,7 @@ namespace dbaui
String aUrl;
SotStorageStreamRef aHtmlRtfStorage;
ElementType nType;
- SvLBoxEntry* pDroppedAt;
+ SvTreeListEntry* pDroppedAt;
sal_Int8 nAction;
sal_Bool bHtml;
sal_Bool bError;
diff --git a/dbaccess/source/ui/inc/TableWindow.hxx b/dbaccess/source/ui/inc/TableWindow.hxx
index ecdfcae164f2..bffde7216eb0 100644
--- a/dbaccess/source/ui/inc/TableWindow.hxx
+++ b/dbaccess/source/ui/inc/TableWindow.hxx
@@ -31,7 +31,7 @@
#include <comphelper/containermultiplexer.hxx>
#include "cppuhelper/basemutex.hxx"
-class SvLBoxEntry;
+class SvTreeListEntry;
namespace dbaui
{
//////////////////////////////////////////////////////////////////////////
@@ -88,7 +88,7 @@ namespace dbaui
sal_Bool FillListBox();
// wird in JEDEM Init aufgerufen
- virtual void OnEntryDoubleClicked(SvLBoxEntry* /*pEntry*/) { }
+ virtual void OnEntryDoubleClicked(SvTreeListEntry* /*pEntry*/) { }
// wird aus dem DoubleClickHdl der ListBox heraus aufgerufen
/** HandleKeyInput triues to handle the KeyEvent. Movement or deletion
diff --git a/dbaccess/source/ui/inc/TableWindowListBox.hxx b/dbaccess/source/ui/inc/TableWindowListBox.hxx
index 890f69887e6e..e42658f23363 100644
--- a/dbaccess/source/ui/inc/TableWindowListBox.hxx
+++ b/dbaccess/source/ui/inc/TableWindowListBox.hxx
@@ -31,7 +31,7 @@ namespace dbaui
{
public:
OTableWindowListBox* pListBox; // die ListBox innerhalb desselben (daraus kann man sich das TabWin und daraus den WinName besorgen)
- SvLBoxEntry* pEntry; // der Eintrag, der gedraggt oder auf den gedroppt wurde
+ SvTreeListEntry* pEntry; // der Eintrag, der gedraggt oder auf den gedroppt wurde
OJoinExchangeData(OTableWindowListBox* pBox);
OJoinExchangeData() : pListBox(NULL), pEntry(NULL) { }
@@ -88,7 +88,7 @@ namespace dbaui
virtual void Command(const CommandEvent& rEvt);
OTableWindow* GetTabWin(){ return m_pTabWin; }
- SvLBoxEntry* GetEntryFromText( const String& rEntryText );
+ SvTreeListEntry* GetEntryFromText( const String& rEntryText );
private:
using SvTreeListBox::ExecuteDrop;
diff --git a/dbaccess/source/ui/inc/WNameMatch.hxx b/dbaccess/source/ui/inc/WNameMatch.hxx
index ba5cb519f565..0beb95559bee 100644
--- a/dbaccess/source/ui/inc/WNameMatch.hxx
+++ b/dbaccess/source/ui/inc/WNameMatch.hxx
@@ -35,14 +35,14 @@ namespace dbaui
{
sal_Bool m_bReadOnly;
protected:
- virtual void InitEntry(SvLBoxEntry* pEntry, const String& rStr, const Image& rImg1, const Image& rImg2, SvLBoxButtonKind eButtonKind);
+ virtual void InitEntry(SvTreeListEntry* pEntry, const OUString& rStr, const Image& rImg1, const Image& rImg2, SvLBoxButtonKind eButtonKind);
public:
OColumnTreeBox( Window* pParent, const ResId& rResId );
void FillListBox( const ODatabaseExport::TColumnVector& _rList);
void SetReadOnly(sal_Bool _bRo=sal_True) { m_bReadOnly = _bRo; }
- virtual sal_Bool Select( SvLBoxEntry* pEntry, sal_Bool bSelect=sal_True );
+ virtual sal_Bool Select( SvTreeListEntry* pEntry, sal_Bool bSelect=sal_True );
private:
using OMarkableTreeListBox::Select;
diff --git a/dbaccess/source/ui/inc/callbacks.hxx b/dbaccess/source/ui/inc/callbacks.hxx
index b49b7aadc3ba..9aaf4a1fc96a 100644
--- a/dbaccess/source/ui/inc/callbacks.hxx
+++ b/dbaccess/source/ui/inc/callbacks.hxx
@@ -24,7 +24,7 @@
#include <sot/formats.hxx>
#include <com/sun/star/container/XContainer.hpp>
-class SvLBoxEntry;
+class SvTreeListEntry;
class String;
class Point;
class PopupMenu;
@@ -49,7 +49,7 @@ namespace dbaui
/** requests a quick help text to display
@return <FALSE/> if the default quick help text should be used
*/
- virtual sal_Bool requestQuickHelp( const SvLBoxEntry* _pEntry, String& _rText ) const = 0;
+ virtual sal_Bool requestQuickHelp( const SvTreeListEntry* _pEntry, String& _rText ) const = 0;
/** handler for StartDrag requests
@return <TRUE/> if a drag operation was started
diff --git a/dbaccess/source/ui/inc/dbtreelistbox.hxx b/dbaccess/source/ui/inc/dbtreelistbox.hxx
index f5948baee4cd..f61c8ad7e30b 100644
--- a/dbaccess/source/ui/inc/dbtreelistbox.hxx
+++ b/dbaccess/source/ui/inc/dbtreelistbox.hxx
@@ -34,14 +34,14 @@ namespace dbaui
{
struct DBTreeEditedEntry
{
- SvLBoxEntry* pEntry;
+ SvTreeListEntry* pEntry;
XubString aNewText;
};
class IEntryFilter
{
public:
- virtual bool includeEntry( SvLBoxEntry* _pEntry ) const = 0;
+ virtual bool includeEntry( SvTreeListEntry* _pEntry ) const = 0;
protected:
~IEntryFilter() {}
@@ -56,8 +56,8 @@ namespace dbaui
OScrollHelper m_aScrollHelper;
Timer m_aTimer; // is needed for table updates
Point m_aMousePos;
- ::std::set< SvListEntry* > m_aSelectedEntries;
- SvLBoxEntry* m_pDragedEntry;
+ std::set<SvTreeListEntry*> m_aSelectedEntries;
+ SvTreeListEntry* m_pDragedEntry;
IControlActionListener* m_pActionListener;
IContextMenuProvider*
m_pContextMenuProvider;
@@ -81,7 +81,7 @@ namespace dbaui
private:
void init();
DECL_LINK( OnTimeOut, void* );
- DECL_LINK( OnResetEntry, SvLBoxEntry* );
+ DECL_LINK( OnResetEntry, SvTreeListEntry* );
DECL_LINK( ScrollUpHdl, SvTreeListBox* );
DECL_LINK( ScrollDownHdl, SvTreeListBox* );
@@ -113,21 +113,21 @@ namespace dbaui
// modified the given entry so that the expand handler is called whenever the entry is expanded
// (normally, the expand handler is called only once)
- void EnableExpandHandler(SvLBoxEntry* _pEntry);
+ void EnableExpandHandler(SvTreeListEntry* _pEntry);
- SvLBoxEntry* GetEntryPosByName( const String& aName, SvLBoxEntry* pStart = NULL, const IEntryFilter* _pFilter = NULL ) const;
- virtual void RequestingChildren( SvLBoxEntry* pParent );
+ SvTreeListEntry* GetEntryPosByName( const String& aName, SvTreeListEntry* pStart = NULL, const IEntryFilter* _pFilter = NULL ) const;
+ virtual void RequestingChildren( SvTreeListEntry* pParent );
virtual void SelectHdl();
virtual void DeselectHdl();
// Window
virtual void KeyInput( const KeyEvent& rKEvt );
virtual void StateChanged( StateChangedType nStateChange );
- virtual void InitEntry( SvLBoxEntry* pEntry, const XubString& aStr, const Image& aCollEntryBmp, const Image& aExpEntryBmp, SvLBoxButtonKind eButtonKind);
+ virtual void InitEntry(SvTreeListEntry* pEntry, const OUString& aStr, const Image& aCollEntryBmp, const Image& aExpEntryBmp, SvLBoxButtonKind eButtonKind);
// enable editing for tables/views and queries
- virtual sal_Bool EditingEntry( SvLBoxEntry* pEntry, Selection& );
- virtual sal_Bool EditedEntry( SvLBoxEntry* pEntry, const rtl::OUString& rNewText );
+ virtual sal_Bool EditingEntry( SvTreeListEntry* pEntry, Selection& );
+ virtual sal_Bool EditedEntry( SvTreeListEntry* pEntry, const rtl::OUString& rNewText );
virtual sal_Bool DoubleClickHdl();
@@ -148,8 +148,8 @@ namespace dbaui
virtual sal_Int8 AcceptDrop( const AcceptDropEvent& _rEvt );
virtual sal_Int8 ExecuteDrop( const ExecuteDropEvent& _rEvt );
- virtual void ModelHasRemoved( SvListEntry* pEntry );
- virtual void ModelHasEntryInvalidated( SvListEntry* pEntry );
+ virtual void ModelHasRemoved( SvTreeListEntry* pEntry );
+ virtual void ModelHasEntryInvalidated( SvTreeListEntry* pEntry );
void implStopSelectionTimer();
void implStartSelectionTimer();
diff --git a/dbaccess/source/ui/inc/indexdialog.hxx b/dbaccess/source/ui/inc/indexdialog.hxx
index 61ae42971402..b8f2bd64be54 100644
--- a/dbaccess/source/ui/inc/indexdialog.hxx
+++ b/dbaccess/source/ui/inc/indexdialog.hxx
@@ -59,12 +59,12 @@ namespace dbaui
void SetEndEditHdl(const Link& _rHdl) { m_aEndEditHdl = _rHdl; }
Link GetEndEditHdl() const { return m_aEndEditHdl; }
- virtual sal_Bool Select( SvLBoxEntry* pEntry, sal_Bool bSelect );
+ virtual sal_Bool Select( SvTreeListEntry* pEntry, sal_Bool bSelect );
void enableSelectHandler();
void disableSelectHandler();
- void SelectNoHandlerCall( SvLBoxEntry* pEntry );
+ void SelectNoHandlerCall( SvTreeListEntry* pEntry );
inline void setConnection(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _rxConnection)
{
@@ -72,7 +72,7 @@ namespace dbaui
}
protected:
- virtual sal_Bool EditedEntry( SvLBoxEntry* pEntry, const rtl::OUString& rNewText );
+ virtual sal_Bool EditedEntry( SvTreeListEntry* pEntry, const rtl::OUString& rNewText );
private:
using SvTreeListBox::Select;
@@ -102,7 +102,7 @@ namespace dbaui
HelpButton m_aHelp;
OIndexCollection* m_pIndexes;
- SvLBoxEntry* m_pPreviousSelection;
+ SvTreeListEntry* m_pPreviousSelection;
sal_Bool m_bEditAgain;
::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >
@@ -136,16 +136,16 @@ namespace dbaui
protected:
void fillIndexList();
void updateToolbox();
- void updateControls(const SvLBoxEntry* _pEntry);
+ void updateControls(const SvTreeListEntry* _pEntry);
protected:
DECL_LINK( OnIndexSelected, DbaIndexList* );
DECL_LINK( OnIndexAction, ToolBox* );
- DECL_LINK( OnEntryEdited, SvLBoxEntry* );
+ DECL_LINK( OnEntryEdited, SvTreeListEntry* );
DECL_LINK( OnModified, void* );
DECL_LINK( OnCloseDialog, void* );
- DECL_LINK( OnEditIndexAgain, SvLBoxEntry* );
+ DECL_LINK( OnEditIndexAgain, SvTreeListEntry* );
private:
void OnNewIndex();
@@ -154,11 +154,11 @@ namespace dbaui
void OnSaveIndex();
void OnResetIndex();
- sal_Bool implCommit(SvLBoxEntry* _pEntry);
+ sal_Bool implCommit(SvTreeListEntry* _pEntry);
sal_Bool implSaveModified(sal_Bool _bPlausibility = sal_True);
sal_Bool implCommitPreviouslySelected();
- sal_Bool implDropIndex(SvLBoxEntry* _pEntry, sal_Bool _bRemoveFromCollection);
+ sal_Bool implDropIndex(SvTreeListEntry* _pEntry, sal_Bool _bRemoveFromCollection);
sal_Bool implCheckPlausibility(const ConstIndexesIterator& _rPos);
diff --git a/dbaccess/source/ui/inc/listviewitems.hxx b/dbaccess/source/ui/inc/listviewitems.hxx
index 99aca2095a40..c9d076cc9ca4 100644
--- a/dbaccess/source/ui/inc/listviewitems.hxx
+++ b/dbaccess/source/ui/inc/listviewitems.hxx
@@ -37,7 +37,7 @@ namespace dbaui
sal_Bool m_bEmphasized;
public:
- OBoldListboxString(SvLBoxEntry* _pEntry, sal_uInt16 _nFlags, const XubString& _rStr)
+ OBoldListboxString(SvTreeListEntry* _pEntry, sal_uInt16 _nFlags, const XubString& _rStr)
:SvLBoxString(_pEntry, _nFlags, _rStr)
,m_bEmphasized(sal_False)
{
@@ -45,8 +45,8 @@ namespace dbaui
virtual sal_uInt16 IsA();
- virtual void Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry);
- virtual void InitViewData( SvTreeListBox* pView,SvLBoxEntry* pEntry, SvViewDataItem* _pViewData);
+ virtual void Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 nFlags, SvTreeListEntry* pEntry);
+ virtual void InitViewData( SvTreeListBox* pView,SvTreeListEntry* pEntry, SvViewDataItem* _pViewData);
sal_Bool isEmphasized() const { return m_bEmphasized; }
void emphasize(sal_Bool _bEmphasize) { m_bEmphasized = _bEmphasize; }
diff --git a/dbaccess/source/ui/inc/marktree.hxx b/dbaccess/source/ui/inc/marktree.hxx
index adda68952197..0567e22d8947 100644
--- a/dbaccess/source/ui/inc/marktree.hxx
+++ b/dbaccess/source/ui/inc/marktree.hxx
@@ -60,9 +60,9 @@ public:
protected:
virtual void Paint(const Rectangle& _rRect);
- virtual void checkedButton_noBroadcast(SvLBoxEntry* _pEntry);
+ virtual void checkedButton_noBroadcast(SvTreeListEntry* _pEntry);
- SvButtonState implDetermineState(SvLBoxEntry* _pEntry);
+ SvButtonState implDetermineState(SvTreeListEntry* _pEntry);
// determines the check state of the given entry, by analyzing the states of all descendants
private:
diff --git a/dbaccess/source/ui/inc/paramdialog.hxx b/dbaccess/source/ui/inc/paramdialog.hxx
index 34b783a82cdb..45596df04ebb 100644
--- a/dbaccess/source/ui/inc/paramdialog.hxx
+++ b/dbaccess/source/ui/inc/paramdialog.hxx
@@ -88,7 +88,7 @@ namespace dbaui
OParameterDialog(Window* _pParent,
const ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > & _rParamContainer,
const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection > & _rxConnection,
- const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxORB);
+ const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext);
~OParameterDialog();
::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >
diff --git a/dbaccess/source/ui/inc/queryfilter.hxx b/dbaccess/source/ui/inc/queryfilter.hxx
index 29bf4667bf29..04856f0a7ac3 100644
--- a/dbaccess/source/ui/inc/queryfilter.hxx
+++ b/dbaccess/source/ui/inc/queryfilter.hxx
@@ -119,7 +119,7 @@ namespace dbaui
public:
DlgFilterCrit( Window * pParent,
- const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxORB,
+ const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext >& rxContext,
const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection>& _rxConnection,
const ::com::sun::star::uno::Reference< ::com::sun::star::sdb::XSingleSelectQueryComposer>& _rxComposer,
const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess>& _rxCols
diff --git a/dbaccess/source/ui/inc/tabletree.hxx b/dbaccess/source/ui/inc/tabletree.hxx
index e545ef081a67..960f426d7e04 100644
--- a/dbaccess/source/ui/inc/tabletree.hxx
+++ b/dbaccess/source/ui/inc/tabletree.hxx
@@ -77,11 +77,11 @@ public:
/** determines whether the given entry denotes a tables folder
*/
- bool isFolderEntry( const SvLBoxEntry* _pEntry ) const;
+ bool isFolderEntry( const SvTreeListEntry* _pEntry ) const;
/** determines whether the given entry denotes a table or view
*/
- bool isTableOrViewEntry( const SvLBoxEntry* _pEntry ) const
+ bool isTableOrViewEntry( const SvTreeListEntry* _pEntry ) const
{
return !isFolderEntry( _pEntry );
}
@@ -112,11 +112,11 @@ public:
/** returns a NamedDatabaseObject record which describes the given entry
*/
::com::sun::star::sdb::application::NamedDatabaseObject
- describeObject( SvLBoxEntry* _pEntry );
+ describeObject( SvTreeListEntry* _pEntry );
/** to be used if a foreign instance added a table
*/
- SvLBoxEntry* addedTable( const ::rtl::OUString& _rName );
+ SvTreeListEntry* addedTable( const ::rtl::OUString& _rName );
/** to be used if a foreign instance removed a table
*/
@@ -126,37 +126,37 @@ public:
@param _pEntry
the entry whose name is to be obtained. Must not denote a folder entry.
*/
- String getQualifiedTableName( SvLBoxEntry* _pEntry ) const;
+ String getQualifiedTableName( SvTreeListEntry* _pEntry ) const;
- SvLBoxEntry* getEntryByQualifiedName( const ::rtl::OUString& _rName );
+ SvTreeListEntry* getEntryByQualifiedName( const ::rtl::OUString& _rName );
- SvLBoxEntry* getAllObjectsEntry() const;
+ SvTreeListEntry* getAllObjectsEntry() const;
/** does a wildcard check of the given entry
<p>There are two different 'checked' states: If the user checks all children of an entry, this is different
from checking the entry itself. The second is called 'wildcard' checking, 'cause in the resulting
table filter it's represented by a wildcard.</p>
*/
- void checkWildcard(SvLBoxEntry* _pEntry);
+ void checkWildcard(SvTreeListEntry* _pEntry);
/** determine if the given entry is 'wildcard checked'
@see checkWildcard
*/
- sal_Bool isWildcardChecked(SvLBoxEntry* _pEntry) const;
+ sal_Bool isWildcardChecked(SvTreeListEntry* _pEntry) const;
protected:
- virtual void InitEntry(SvLBoxEntry* _pEntry, const XubString& _rString, const Image& _rCollapsedBitmap, const Image& _rExpandedBitmap, SvLBoxButtonKind _eButtonKind);
+ virtual void InitEntry(SvTreeListEntry* _pEntry, const OUString& _rString, const Image& _rCollapsedBitmap, const Image& _rExpandedBitmap, SvLBoxButtonKind _eButtonKind);
- virtual void checkedButton_noBroadcast(SvLBoxEntry* _pEntry);
+ virtual void checkedButton_noBroadcast(SvTreeListEntry* _pEntry);
- void implEmphasize(SvLBoxEntry* _pEntry, sal_Bool _bChecked, sal_Bool _bUpdateDescendants = sal_True, sal_Bool _bUpdateAncestors = sal_True);
+ void implEmphasize(SvTreeListEntry* _pEntry, sal_Bool _bChecked, sal_Bool _bUpdateDescendants = sal_True, sal_Bool _bUpdateAncestors = sal_True);
/** adds the given entry to our list
@precond
our image provider must already have been reset to the connection to which the meta data
belong.
*/
- SvLBoxEntry* implAddEntry(
+ SvTreeListEntry* implAddEntry(
const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDatabaseMetaData >& _rxMeta,
const ::rtl::OUString& _rTableName,
sal_Bool _bCheckName = sal_True
diff --git a/dbaccess/source/ui/inc/unodatbr.hxx b/dbaccess/source/ui/inc/unodatbr.hxx
index 323b98c54ef8..5d6fbe63f6a1 100644
--- a/dbaccess/source/ui/inc/unodatbr.hxx
+++ b/dbaccess/source/ui/inc/unodatbr.hxx
@@ -44,13 +44,13 @@
#include "commontypes.hxx"
// =========================================================================
-class SvLBoxEntry;
+class SvTreeListEntry;
class Splitter;
struct SvSortData;
namespace com { namespace sun{ namespace star { namespace container { class XNameContainer; } } } }
-class SvLBoxTreeList;
+class SvTreeList;
// .........................................................................
namespace dbaui
{
@@ -109,8 +109,8 @@ namespace dbaui
DBTreeView* m_pTreeView;
Splitter* m_pSplitter;
- SvLBoxTreeList* m_pTreeModel; // contains the datasources of the registry
- SvLBoxEntry* m_pCurrentlyDisplayed;
+ SvTreeList* m_pTreeModel; // contains the datasources of the registry
+ SvTreeListEntry* m_pCurrentlyDisplayed;
sal_uLong m_nAsyncDrop;
sal_Int16 m_nBorder; // sal_True when border should be shown
@@ -234,7 +234,7 @@ namespace dbaui
virtual void Execute(sal_uInt16 nId, const ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue>& aArgs);
// IControlActionListener overridables
- virtual sal_Bool requestQuickHelp( const SvLBoxEntry* _pEntry, String& _rText ) const;
+ virtual sal_Bool requestQuickHelp( const SvTreeListEntry* _pEntry, String& _rText ) const;
virtual sal_Bool requestDrag( sal_Int8 _nAction, const Point& _rPosPixel );
virtual sal_Int8 queryDrop( const AcceptDropEvent& _rEvt, const DataFlavorExVector& _rFlavors );
virtual sal_Int8 executeDrop( const ExecuteDropEvent& _rEvt );
@@ -262,11 +262,11 @@ namespace dbaui
// methods for handling the 'selection' (paintin them bold) of SvLBoxEntries
// returns <TRUE/> if the entry is selected (which means it's part of the selected path)
- sal_Bool isSelected(SvLBoxEntry* _pEntry) const;
+ sal_Bool isSelected(SvTreeListEntry* _pEntry) const;
// select the entry (and only the entry, not the whole path)
- void select(SvLBoxEntry* _pEntry, sal_Bool _bSelect = sal_True);
+ void select(SvTreeListEntry* _pEntry, sal_Bool _bSelect = sal_True);
// select the path of the entry (which must be an entry without children)
- void selectPath(SvLBoxEntry* _pEntry, sal_Bool _bSelect = sal_True);
+ void selectPath(SvTreeListEntry* _pEntry, sal_Bool _bSelect = sal_True);
virtual void loadMenu(const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& _xFrame);
@@ -311,52 +311,52 @@ namespace dbaui
void unloadAndCleanup( sal_Bool _bDisposeConnection = sal_True );
// disposes the connection associated with the given entry (which must represent a data source)
- void disposeConnection( SvLBoxEntry* _pDSEntry );
+ void disposeConnection( SvTreeListEntry* _pDSEntry );
/// flushs and disposes the given connection, and de-registers as listener
void impl_releaseConnection( SharedConnection& _rxConnection );
/** close the connection (and collapse the list entries) of the given list entries
*/
- void closeConnection(SvLBoxEntry* _pEntry,sal_Bool _bDisposeConnection = sal_True);
+ void closeConnection(SvTreeListEntry* _pEntry,sal_Bool _bDisposeConnection = sal_True);
- void populateTree(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess>& _xNameAccess, SvLBoxEntry* _pParent, EntryType _eEntryType);
+ void populateTree(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess>& _xNameAccess, SvTreeListEntry* _pParent, EntryType _eEntryType);
void initializeTreeModel();
/** search in the tree for query- or tablecontainer equal to this interface and return
this container entry
*/
- SvLBoxEntry* getEntryFromContainer(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess>& _rxNameAccess);
+ SvTreeListEntry* getEntryFromContainer(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess>& _rxNameAccess);
// return true when there is connection available
- sal_Bool ensureConnection(SvLBoxEntry* _pDSEntry, void * pDSData, SharedConnection& _rConnection );
- sal_Bool ensureConnection(SvLBoxEntry* _pAnyEntry, SharedConnection& _rConnection );
+ sal_Bool ensureConnection(SvTreeListEntry* _pDSEntry, void * pDSData, SharedConnection& _rConnection );
+ sal_Bool ensureConnection(SvTreeListEntry* _pAnyEntry, SharedConnection& _rConnection );
- sal_Bool getExistentConnectionFor( SvLBoxEntry* _pDSEntry, SharedConnection& _rConnection );
+ sal_Bool getExistentConnectionFor( SvTreeListEntry* _pDSEntry, SharedConnection& _rConnection );
/** returns an image provider which works with the connection belonging to the given entry
*/
::std::auto_ptr< ImageProvider >
- getImageProviderFor( SvLBoxEntry* _pAnyEntry );
+ getImageProviderFor( SvTreeListEntry* _pAnyEntry );
- void implAdministrate( SvLBoxEntry* _pApplyTo );
+ void implAdministrate( SvTreeListEntry* _pApplyTo );
TransferableHelper*
- implCopyObject( SvLBoxEntry* _pApplyTo, sal_Int32 _nCommandType, sal_Bool _bAllowConnection = sal_True );
+ implCopyObject( SvTreeListEntry* _pApplyTo, sal_Int32 _nCommandType, sal_Bool _bAllowConnection = sal_True );
- EntryType getEntryType( SvLBoxEntry* _pEntry ) const;
- EntryType getChildType( SvLBoxEntry* _pEntry ) const;
+ EntryType getEntryType( const SvTreeListEntry* _pEntry ) const;
+ EntryType getChildType( SvTreeListEntry* _pEntry ) const;
sal_Bool isObject( EntryType _eType ) const { return ( etTableOrView== _eType ) || ( etQuery == _eType ); }
sal_Bool isContainer( EntryType _eType ) const { return (etTableContainer == _eType) || (etQueryContainer == _eType); }
- sal_Bool isContainer( SvLBoxEntry* _pEntry ) const { return isContainer( getEntryType( _pEntry ) ); }
+ bool isContainer( const SvTreeListEntry* _pEntry ) const { return isContainer( getEntryType( _pEntry ) ); }
// ensure that the xObject for the given entry is set on the user data
- sal_Bool ensureEntryObject( SvLBoxEntry* _pEntry );
+ sal_Bool ensureEntryObject( SvTreeListEntry* _pEntry );
// get the display text of the entry given
- String GetEntryText( SvLBoxEntry* _pEntry ) const;
+ String GetEntryText( SvTreeListEntry* _pEntry ) const;
// is called when a table or a query was selected
DECL_LINK( OnSelectionChange, void* );
- DECL_LINK( OnExpandEntry, SvLBoxEntry* );
+ DECL_LINK( OnExpandEntry, SvTreeListEntry* );
DECL_LINK( OnCopyEntry, void* );
@@ -367,7 +367,7 @@ namespace dbaui
void implRemoveStatusListeners();
sal_Bool implSelect(const ::svx::ODataAccessDescriptor& _rDescriptor,sal_Bool _bSelectDirect = sal_False);
- bool implSelect( SvLBoxEntry* _pEntry );
+ bool implSelect( SvTreeListEntry* _pEntry );
/// selects the entry given and loads the grid control with the object's data
sal_Bool implSelect(
@@ -379,10 +379,10 @@ namespace dbaui
sal_Bool _bSelectDirect = sal_False
);
- SvLBoxEntry* implGetConnectionEntry(SvLBoxEntry* _pEntry) const;
+ SvTreeListEntry* implGetConnectionEntry(SvTreeListEntry* _pEntry) const;
/// inserts an entry into the tree
- SvLBoxEntry* implAppendEntry(
- SvLBoxEntry* _pParent,
+ SvTreeListEntry* implAppendEntry(
+ SvTreeListEntry* _pParent,
const String& _rName,
void* _pUserData,
EntryType _eEntryType
@@ -402,8 +402,8 @@ namespace dbaui
@param _bExpandAncestors
If <TRUE/>, all ancestor on the way to the entry will be expanded
*/
- SvLBoxEntry* getObjectEntry(const ::svx::ODataAccessDescriptor& _rDescriptor,
- SvLBoxEntry** _ppDataSourceEntry = NULL, SvLBoxEntry** _ppContainerEntry = NULL,
+ SvTreeListEntry* getObjectEntry(const ::svx::ODataAccessDescriptor& _rDescriptor,
+ SvTreeListEntry** _ppDataSourceEntry = NULL, SvTreeListEntry** _ppContainerEntry = NULL,
sal_Bool _bExpandAncestors = sal_True
);
/** retrieves the tree entry for the object described by data source name, command and command type
@@ -422,9 +422,9 @@ namespace dbaui
@param _bExpandAncestors
If <TRUE/>, all ancestor on the way to the entry will be expanded
*/
- SvLBoxEntry* getObjectEntry(
+ SvTreeListEntry* getObjectEntry(
const ::rtl::OUString& _rDataSource, const ::rtl::OUString& _rCommand, sal_Int32 _nCommandType,
- SvLBoxEntry** _ppDataSourceEntry = NULL, SvLBoxEntry** _ppContainerEntry = NULL,
+ SvTreeListEntry** _ppDataSourceEntry = NULL, SvTreeListEntry** _ppContainerEntry = NULL,
sal_Bool _bExpandAncestors = sal_True,
const SharedConnection& _rxConnection = SharedConnection()
);
@@ -444,20 +444,20 @@ namespace dbaui
#if OSL_DEBUG_LEVEL > 0
// checks whether the given tree entry denotes a data source
- bool impl_isDataSourceEntry( SvLBoxEntry* _pEntry ) const;
+ bool impl_isDataSourceEntry( SvTreeListEntry* _pEntry ) const;
#endif
/// retrieves the data source URL/name for the given entry representing a data source
- String getDataSourceAcessor( SvLBoxEntry* _pDataSourceEntry ) const;
+ String getDataSourceAcessor( SvTreeListEntry* _pDataSourceEntry ) const;
/** get the signature (command/escape processing) of the query the form is based on
<p>If the for is not based on a query or not even loaded, nothing happens and <FALSE/> is returned.</p>
*/
sal_Bool implGetQuerySignature( ::rtl::OUString& _rCommand, sal_Bool& _bEscapeProcessing );
- sal_Bool isEntryCopyAllowed(SvLBoxEntry* _pEntry) const;
+ sal_Bool isEntryCopyAllowed(SvTreeListEntry* _pEntry) const;
- void copyEntry(SvLBoxEntry* _pEntry);
+ void copyEntry(SvTreeListEntry* _pEntry);
// remove all grid columns and dispose them
void clearGridColumns(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameContainer >& _xColContainer);
@@ -470,7 +470,7 @@ namespace dbaui
@return
<TRUE/> if it is the currently displayed otherwise <FALSE/>
*/
- sal_Bool isCurrentlyDisplayedChanged(const String& _sName,SvLBoxEntry* _pContainer);
+ sal_Bool isCurrentlyDisplayedChanged(const String& _sName,SvTreeListEntry* _pContainer);
/** called whenever the content of the browser is used for preview, as the very last action
of the load process
diff --git a/dbaccess/source/ui/misc/WNameMatch.cxx b/dbaccess/source/ui/misc/WNameMatch.cxx
index b68b329a3162..6a40a71f7f4e 100644
--- a/dbaccess/source/ui/misc/WNameMatch.cxx
+++ b/dbaccess/source/ui/misc/WNameMatch.cxx
@@ -138,8 +138,8 @@ sal_Bool OWizNameMatching::LeavePage()
sal_Int32 nParamPos = 0;
- SvLBoxEntry* pLeftEntry = m_CTRL_LEFT.GetModel()->First();
- SvLBoxEntry* pRightEntry = m_CTRL_RIGHT.GetModel()->First();
+ SvTreeListEntry* pLeftEntry = m_CTRL_LEFT.GetModel()->First();
+ SvTreeListEntry* pRightEntry = m_CTRL_RIGHT.GetModel()->First();
while(pLeftEntry && pRightEntry)
{
OFieldDescription* pSrcField = static_cast<OFieldDescription*>(pLeftEntry->GetUserData());
@@ -189,7 +189,7 @@ String OWizNameMatching::GetTitle() const { return String(ModuleRes(STR_WIZ_NAME
// -----------------------------------------------------------------------
IMPL_LINK( OWizNameMatching, ButtonClickHdl, Button *, pButton )
{
- SvLBoxEntry* pEntry = m_CTRL_LEFT.FirstSelected();
+ SvTreeListEntry* pEntry = m_CTRL_LEFT.FirstSelected();
if ( pEntry )
{
sal_Int32 nPos = m_CTRL_LEFT.GetModel()->GetAbsPos(pEntry);
@@ -219,7 +219,7 @@ IMPL_LINK( OWizNameMatching, ButtonClickHdl, Button *, pButton )
//------------------------------------------------------------------------------
IMPL_LINK( OWizNameMatching, RightButtonClickHdl, Button *, pButton )
{
- SvLBoxEntry* pEntry = m_CTRL_RIGHT.FirstSelected();
+ SvTreeListEntry* pEntry = m_CTRL_RIGHT.FirstSelected();
if ( pEntry )
{
sal_Int32 nPos = m_CTRL_RIGHT.GetModel()->GetAbsPos(pEntry);
@@ -243,11 +243,11 @@ IMPL_LINK( OWizNameMatching, RightButtonClickHdl, Button *, pButton )
//------------------------------------------------------------------------------
IMPL_LINK( OWizNameMatching, TableListClickHdl, void*, /*NOTINTERESTEDIN*/ )
{
- SvLBoxEntry* pEntry = m_CTRL_LEFT.FirstSelected();
+ SvTreeListEntry* pEntry = m_CTRL_LEFT.FirstSelected();
if(pEntry)
{
sal_uLong nPos = m_CTRL_LEFT.GetModel()->GetAbsPos(pEntry);
- SvLBoxEntry* pOldEntry = m_CTRL_RIGHT.FirstSelected();
+ SvTreeListEntry* pOldEntry = m_CTRL_RIGHT.FirstSelected();
if(pOldEntry && nPos != m_CTRL_RIGHT.GetModel()->GetAbsPos(pOldEntry))
{
if(pOldEntry)
@@ -277,11 +277,11 @@ IMPL_LINK( OWizNameMatching, TableListClickHdl, void*, /*NOTINTERESTEDIN*/ )
//------------------------------------------------------------------------------
IMPL_LINK( OWizNameMatching, TableListRightSelectHdl, void*, /*NOTINTERESTEDIN*/ )
{
- SvLBoxEntry* pEntry = m_CTRL_RIGHT.FirstSelected();
+ SvTreeListEntry* pEntry = m_CTRL_RIGHT.FirstSelected();
if(pEntry)
{
sal_uLong nPos = m_CTRL_RIGHT.GetModel()->GetAbsPos(pEntry);
- SvLBoxEntry* pOldEntry = m_CTRL_LEFT.FirstSelected();
+ SvTreeListEntry* pOldEntry = m_CTRL_LEFT.FirstSelected();
if(pOldEntry && nPos != m_CTRL_LEFT.GetModel()->GetAbsPos(pOldEntry))
{
if(pOldEntry)
@@ -312,7 +312,7 @@ IMPL_LINK( OWizNameMatching, TableListRightSelectHdl, void*, /*NOTINTERESTEDIN*/
IMPL_LINK( OWizNameMatching, AllNoneClickHdl, Button *, pButton )
{
sal_Bool bAll = pButton == &m_pbAll;
- SvLBoxEntry* pEntry = m_CTRL_LEFT.First();
+ SvTreeListEntry* pEntry = m_CTRL_LEFT.First();
while(pEntry)
{
m_CTRL_LEFT.SetCheckButtonState( pEntry, bAll ? SV_BUTTON_CHECKED : SV_BUTTON_UNCHECKED);
@@ -329,16 +329,16 @@ class OColumnString : public SvLBoxString
{
sal_Bool m_bReadOnly;
public:
- OColumnString( SvLBoxEntry* pEntry, sal_uInt16 nFlags, const String& rStr,sal_Bool _RO)
+ OColumnString( SvTreeListEntry* pEntry, sal_uInt16 nFlags, const String& rStr,sal_Bool _RO)
:SvLBoxString(pEntry,nFlags,rStr)
,m_bReadOnly(_RO)
{
}
- virtual void Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry);
+ virtual void Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 nFlags, SvTreeListEntry* pEntry);
};
//------------------------------------------------------------------------
-void OColumnString::Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 /*nFlags*/, SvLBoxEntry* /*pEntry*/ )
+void OColumnString::Paint(const Point& rPos, SvTreeListBox& rDev, sal_uInt16 /*nFlags*/, SvTreeListEntry* /*pEntry*/ )
{
if(m_bReadOnly)
{
@@ -358,15 +358,15 @@ OColumnTreeBox::OColumnTreeBox( Window* pParent, const ResId& rResId )
SetSelectionMode( SINGLE_SELECTION );
}
//------------------------------------------------------------------------
-void OColumnTreeBox::InitEntry(SvLBoxEntry* pEntry, const String& rStr, const Image& rImg1, const Image& rImg2, SvLBoxButtonKind eButtonKind)
+void OColumnTreeBox::InitEntry(SvTreeListEntry* pEntry, const OUString& rStr, const Image& rImg1, const Image& rImg2, SvLBoxButtonKind eButtonKind)
{
- DBTreeListBox::InitEntry( pEntry, rStr, rImg1, rImg2, eButtonKind );
+ DBTreeListBox::InitEntry(pEntry, rStr, rImg1, rImg2, eButtonKind);
SvLBoxString* pString = new OColumnString(pEntry, 0, rStr,sal_False);
if (pString)
pEntry->ReplaceItem( pString, pEntry->ItemCount() - 1 );
}
//------------------------------------------------------------------------
-sal_Bool OColumnTreeBox::Select( SvLBoxEntry* pEntry, sal_Bool bSelect )
+sal_Bool OColumnTreeBox::Select( SvTreeListEntry* pEntry, sal_Bool bSelect )
{
if(bSelect)
{
@@ -386,7 +386,7 @@ void OColumnTreeBox::FillListBox( const ODatabaseExport::TColumnVector& _rList)
ODatabaseExport::TColumnVector::const_iterator aEnd = _rList.end();
for(;aIter != aEnd;++aIter)
{
- SvLBoxEntry* pEntry = InsertEntry((*aIter)->first,0,sal_False,LIST_APPEND,(*aIter)->second);
+ SvTreeListEntry* pEntry = InsertEntry((*aIter)->first,0,sal_False,LIST_APPEND,(*aIter)->second);
SvButtonState eState = !(m_bReadOnly && (*aIter)->second->IsAutoIncrement()) ? SV_BUTTON_CHECKED : SV_BUTTON_UNCHECKED;
SetCheckButtonState( pEntry, eState );
}
diff --git a/dbaccess/source/ui/querydesign/ConnectionLine.cxx b/dbaccess/source/ui/querydesign/ConnectionLine.cxx
index 10c0cad4701c..89df41cae188 100644
--- a/dbaccess/source/ui/querydesign/ConnectionLine.cxx
+++ b/dbaccess/source/ui/querydesign/ConnectionLine.cxx
@@ -82,7 +82,7 @@ namespace
@param _rNewConPos (in/out) the connection pos
@param _rNewDescrPos (in/out) the description pos
*/
- void calcPointsYValue(const OTableWindow* _pWin,SvLBoxEntry* _pEntry,Point& _rNewConPos,Point& _rNewDescrPos)
+ void calcPointsYValue(const OTableWindow* _pWin,SvTreeListEntry* _pEntry,Point& _rNewConPos,Point& _rNewDescrPos)
{
const OTableWindowListBox* pListBox = _pWin->GetListBox();
_rNewConPos.Y() = _pWin->GetPosPixel().Y();
@@ -232,8 +232,8 @@ sal_Bool OConnectionLine::RecalcLine()
if( !pSourceWin || !pDestWin )
return sal_False;
- SvLBoxEntry* pSourceEntry = pSourceWin->GetListBox()->GetEntryFromText( GetData()->GetSourceFieldName() );
- SvLBoxEntry* pDestEntry = pDestWin->GetListBox()->GetEntryFromText( GetData()->GetDestFieldName() );
+ SvTreeListEntry* pSourceEntry = pSourceWin->GetListBox()->GetEntryFromText( GetData()->GetSourceFieldName() );
+ SvTreeListEntry* pDestEntry = pDestWin->GetListBox()->GetEntryFromText( GetData()->GetDestFieldName() );
//////////////////////////////////////////////////////////////////////
// X-Koordinaten bestimmen
diff --git a/dbaccess/source/ui/querydesign/JoinTableView.cxx b/dbaccess/source/ui/querydesign/JoinTableView.cxx
index 022f38668a91..de041132fb80 100644
--- a/dbaccess/source/ui/querydesign/JoinTableView.cxx
+++ b/dbaccess/source/ui/querydesign/JoinTableView.cxx
@@ -968,8 +968,8 @@ void OJoinTableView::SelectConn(OTableConnection* pConn)
pSourceBox->SelectAll(sal_False);
pDestBox->SelectAll(sal_False);
- SvLBoxEntry* pFirstSourceVisible = pSourceBox->GetFirstEntryInView();
- SvLBoxEntry* pFirstDestVisible = pDestBox->GetFirstEntryInView();
+ SvTreeListEntry* pFirstSourceVisible = pSourceBox->GetFirstEntryInView();
+ SvTreeListEntry* pFirstDestVisible = pDestBox->GetFirstEntryInView();
const ::std::vector<OConnectionLine*>* pLines = pConn->GetConnLineList();
::std::vector<OConnectionLine*>::const_reverse_iterator aIter = pLines->rbegin();
@@ -977,14 +977,14 @@ void OJoinTableView::SelectConn(OTableConnection* pConn)
{
if ((*aIter)->IsValid())
{
- SvLBoxEntry* pSourceEntry = pSourceBox->GetEntryFromText((*aIter)->GetData()->GetSourceFieldName());
+ SvTreeListEntry* pSourceEntry = pSourceBox->GetEntryFromText((*aIter)->GetData()->GetSourceFieldName());
if (pSourceEntry)
{
pSourceBox->Select(pSourceEntry, sal_True);
pSourceBox->MakeVisible(pSourceEntry);
}
- SvLBoxEntry* pDestEntry = pDestBox->GetEntryFromText((*aIter)->GetData()->GetDestFieldName());
+ SvTreeListEntry* pDestEntry = pDestBox->GetEntryFromText((*aIter)->GetData()->GetDestFieldName());
if (pDestEntry)
{
pDestBox->Select(pDestEntry, sal_True);
diff --git a/dbaccess/source/ui/querydesign/QTableWindow.cxx b/dbaccess/source/ui/querydesign/QTableWindow.cxx
index 0bcbb0e0ed48..d07ab1eb3408 100644
--- a/dbaccess/source/ui/querydesign/QTableWindow.cxx
+++ b/dbaccess/source/ui/querydesign/QTableWindow.cxx
@@ -151,7 +151,7 @@ void OQueryTableWindow::deleteUserData(void*& _pUserData)
_pUserData = NULL;
}
//------------------------------------------------------------------------------
-void OQueryTableWindow::OnEntryDoubleClicked(SvLBoxEntry* pEntry)
+void OQueryTableWindow::OnEntryDoubleClicked(SvTreeListEntry* pEntry)
{
OSL_ENSURE(pEntry != NULL, "OQueryTableWindow::OnEntryDoubleClicked : pEntry darf nicht NULL sein !");
// man koennte das auch abfragen und dann ein return hinsetzen, aber so weist es vielleicht auf Fehler bei Aufrufer hin
@@ -182,7 +182,7 @@ sal_Bool OQueryTableWindow::ExistsField(const ::rtl::OUString& strFieldName, OTa
sal_Bool bExists = sal_False;
if(xConnection.is())
{
- SvLBoxEntry* pEntry = m_pListBox->First();
+ SvTreeListEntry* pEntry = m_pListBox->First();
try
{
Reference<XDatabaseMetaData> xMeta = xConnection->getMetaData();
diff --git a/dbaccess/source/ui/querydesign/QTableWindow.hxx b/dbaccess/source/ui/querydesign/QTableWindow.hxx
index 7f6b8921cb0c..247bb68ec375 100644
--- a/dbaccess/source/ui/querydesign/QTableWindow.hxx
+++ b/dbaccess/source/ui/querydesign/QTableWindow.hxx
@@ -57,7 +57,7 @@ namespace dbaui
protected:
virtual void KeyInput( const KeyEvent& rEvt );
- virtual void OnEntryDoubleClicked(SvLBoxEntry* pEntry);
+ virtual void OnEntryDoubleClicked(SvTreeListEntry* pEntry);
// wird aus dem DoubleClickHdl der ListBox heraus aufgerufen
/** delete the user data with the equal type as created within createUserData
@param _pUserData
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index ebddbfc41813..13446b2d9c53 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -3085,7 +3085,10 @@ OSQLParseNode* OQueryDesignView::getPredicateTreeFromEntry(OTableFieldDescRef pE
nType,
sal_False,
sal_False,
- xMeta.is() && xMeta->supportsMixedCaseQuotedIdentifiers());
+ xMeta.is() && xMeta->supportsMixedCaseQuotedIdentifiers(),
+ ::rtl::OUString(),
+ ::rtl::OUString(),
+ ::rtl::OUString());
_rxColumn = pColumn;
pColumn->setFunction(sal_True);
pColumn->setRealName(pEntry->GetField());
diff --git a/dbaccess/source/ui/querydesign/TableWindow.cxx b/dbaccess/source/ui/querydesign/TableWindow.cxx
index a78a05c22638..27cd818442fb 100644
--- a/dbaccess/source/ui/querydesign/TableWindow.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindow.cxx
@@ -183,7 +183,7 @@ sal_Bool OTableWindow::FillListBox()
if (GetData()->IsShowAll())
{
- SvLBoxEntry* pEntry = m_pListBox->InsertEntry( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("*")) );
+ SvTreeListEntry* pEntry = m_pListBox->InsertEntry( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("*")) );
pEntry->SetUserData( createUserData(NULL,false) );
}
@@ -205,7 +205,7 @@ sal_Bool OTableWindow::FillListBox()
const ::rtl::OUString* pIter = aColumns.getConstArray();
const ::rtl::OUString* pEnd = pIter + aColumns.getLength();
- SvLBoxEntry* pEntry = NULL;
+ SvTreeListEntry* pEntry = NULL;
for (; pIter != pEnd; ++pIter)
{
bool bPrimaryKeyColumn = xPKeyColumns.is() && xPKeyColumns->hasByName( *pIter );
@@ -244,13 +244,13 @@ void OTableWindow::clearListBox()
{
if ( m_pListBox )
{
- SvLBoxEntry* pEntry = m_pListBox->First();
+ SvTreeListEntry* pEntry = m_pListBox->First();
while(pEntry)
{
void* pUserData = pEntry->GetUserData();
deleteUserData(pUserData);
- SvLBoxEntry* pNextEntry = m_pListBox->Next(pEntry);
+ SvTreeListEntry* pNextEntry = m_pListBox->Next(pEntry);
m_pListBox->GetModel()->Remove(pEntry);
pEntry = pNextEntry;
}
@@ -563,7 +563,7 @@ void OTableWindow::EnumValidFields(::std::vector< ::rtl::OUString>& arrstrFields
if ( m_pListBox )
{
arrstrFields.reserve(m_pListBox->GetEntryCount());
- SvLBoxEntry* pEntryLoop = m_pListBox->First();
+ SvTreeListEntry* pEntryLoop = m_pListBox->First();
while (pEntryLoop)
{
arrstrFields.push_back(m_pListBox->GetEntryText(pEntryLoop));
@@ -613,7 +613,7 @@ void OTableWindow::Command(const CommandEvent& rEvt)
ptWhere = rEvt.GetMousePosPixel();
else
{
- SvLBoxEntry* pCurrent = m_pListBox->GetCurEntry();
+ SvTreeListEntry* pCurrent = m_pListBox->GetCurEntry();
if ( pCurrent )
ptWhere = m_pListBox->GetEntryPosition(pCurrent);
else
diff --git a/dbaccess/source/ui/querydesign/TableWindowListBox.cxx b/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
index 87ca37dbba6b..ab97283db94a 100644
--- a/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
@@ -86,12 +86,12 @@ OTableWindowListBox::~OTableWindowListBox()
}
//------------------------------------------------------------------------------
-SvLBoxEntry* OTableWindowListBox::GetEntryFromText( const String& rEntryText )
+SvTreeListEntry* OTableWindowListBox::GetEntryFromText( const String& rEntryText )
{
//////////////////////////////////////////////////////////////////////
// Liste durchiterieren
SvTreeList* pTreeList = GetModel();
- SvLBoxEntry* pEntry = (SvLBoxEntry*)pTreeList->First();
+ SvTreeListEntry* pEntry = pTreeList->First();
OJoinDesignView* pView = m_pTabWin->getDesignView();
OJoinController& rController = pView->getController();
@@ -111,7 +111,7 @@ SvLBoxEntry* OTableWindowListBox::GetEntryFromText( const String& rEntryText )
{
return pEntry;
}
- pEntry = (SvLBoxEntry*)pTreeList->Next( pEntry );
+ pEntry = pTreeList->Next(pEntry);
}
}
catch(SQLException&)
@@ -174,7 +174,7 @@ long OTableWindowListBox::PreNotify(NotifyEvent& rNEvt)
//------------------------------------------------------------------------------
IMPL_LINK( OTableWindowListBox, ScrollUpHdl, SvTreeListBox*, /*pBox*/ )
{
- SvLBoxEntry* pEntry = GetEntry( m_aMousePos );
+ SvTreeListEntry* pEntry = GetEntry( m_aMousePos );
if( !pEntry )
return 0;
@@ -191,7 +191,7 @@ IMPL_LINK( OTableWindowListBox, ScrollUpHdl, SvTreeListBox*, /*pBox*/ )
//------------------------------------------------------------------------------
IMPL_LINK( OTableWindowListBox, ScrollDownHdl, SvTreeListBox*, /*pBox*/ )
{
- SvLBoxEntry* pEntry = GetEntry( m_aMousePos );
+ SvTreeListEntry* pEntry = GetEntry( m_aMousePos );
if( !pEntry )
return 0;
@@ -240,7 +240,7 @@ sal_Int8 OTableWindowListBox::AcceptDrop( const AcceptDropEvent& _rEvt )
// hit test
m_aMousePos = _rEvt.maPosPixel;
Size aOutputSize = GetOutputSizePixel();
- SvLBoxEntry* pEntry = GetEntry( m_aMousePos );
+ SvTreeListEntry* pEntry = GetEntry( m_aMousePos );
if( !pEntry )
return DND_ACTION_NONE;
diff --git a/dbaccess/source/ui/querydesign/querycontroller.cxx b/dbaccess/source/ui/querydesign/querycontroller.cxx
index 9bdd3a7f6208..752031dc377e 100644
--- a/dbaccess/source/ui/querydesign/querycontroller.cxx
+++ b/dbaccess/source/ui/querydesign/querycontroller.cxx
@@ -141,7 +141,7 @@ namespace dbaui
namespace
{
// -----------------------------------------------------------------------------
- void insertParseTree(SvTreeListBox* _pBox,::connectivity::OSQLParseNode* _pNode,SvLBoxEntry* _pParent = NULL)
+ void insertParseTree(SvTreeListBox* _pBox,::connectivity::OSQLParseNode* _pNode,SvTreeListEntry* _pParent = NULL)
{
::rtl::OUString rString;
if (!_pNode->isToken())
@@ -324,7 +324,7 @@ OQueryController::OQueryController(const Reference< XMultiServiceFactory >& _rM)
:OJoinController(_rM)
,OQueryController_PBase( getBroadcastHelper() )
,m_pParseContext( new svxform::OSystemParseContext )
- ,m_aSqlParser( _rM, m_pParseContext )
+ ,m_aSqlParser( comphelper::getComponentContext(_rM), m_pParseContext )
,m_pSqlIterator(NULL)
,m_nVisibleRows(0x400)
,m_nSplitPos(-1)
@@ -1598,7 +1598,7 @@ struct CommentStrip
static ::std::vector< CommentStrip > getComment( const ::rtl::OUString& rQuery )
{
::std::vector< CommentStrip > aRet;
- // First a quick search if there is any "--" or "//" or "/*", if not then
+ // First a quick search if there is any "--" or "//" or "/*", if not then
// the whole copying loop is pointless.
if (rQuery.indexOfAsciiL( "--", 2, 0) < 0 && rQuery.indexOfAsciiL( "//", 2, 0) < 0 &&
rQuery.indexOfAsciiL( "/*", 2, 0) < 0)
@@ -1667,10 +1667,10 @@ static ::std::vector< CommentStrip > getComment( const ::rtl::OUString& rQuery )
/** Concat/insert comments that were previously obtained with getComment().
- NOTE: The current parser implementation does not preserve newlines, so all
- comments are always appended to the entire query, also inline comments
- that would need positioning anyway that can't be obtained after
- recomposition. This is ugly but at least allows commented queries while
+ NOTE: The current parser implementation does not preserve newlines, so all
+ comments are always appended to the entire query, also inline comments
+ that would need positioning anyway that can't be obtained after
+ recomposition. This is ugly but at least allows commented queries while
preserving the comments _somehow_.
*/
static ::rtl::OUString concatComment( const ::rtl::OUString& rQuery, const ::std::vector< CommentStrip >& rComments )
diff --git a/dbaccess/source/ui/uno/composerdialogs.cxx b/dbaccess/source/ui/uno/composerdialogs.cxx
index ca5fdd188ec6..0a2cb1e87274 100644
--- a/dbaccess/source/ui/uno/composerdialogs.cxx
+++ b/dbaccess/source/ui/uno/composerdialogs.cxx
@@ -146,7 +146,7 @@ namespace dbaui
//---------------------------------------------------------------------
Dialog* RowsetFilterDialog::createComposerDialog( Window* _pParent, const Reference< XConnection >& _rxConnection, const Reference< XNameAccess >& _rxColumns )
{
- return new DlgFilterCrit( _pParent, m_aContext.getLegacyServiceFactory(), _rxConnection, m_xComposer, _rxColumns );
+ return new DlgFilterCrit( _pParent, m_aContext.getUNOContext(), _rxConnection, m_xComposer, _rxColumns );
}
//---------------------------------------------------------------------
diff --git a/dbaccess/source/ui/uno/dbinteraction.cxx b/dbaccess/source/ui/uno/dbinteraction.cxx
index 8cb12b91397a..e992ae06de5d 100644
--- a/dbaccess/source/ui/uno/dbinteraction.cxx
+++ b/dbaccess/source/ui/uno/dbinteraction.cxx
@@ -139,7 +139,7 @@ namespace dbaui
xParamCallback = Reference< XInteractionSupplyParameters >(_rContinuations[nParamPos], UNO_QUERY);
OSL_ENSURE(xParamCallback.is(), "BasicInteractionHandler::implHandle(ParametersRequest): can't set the parameters without an appropriate interaction handler!s");
- OParameterDialog aDlg(NULL, _rParamRequest.Parameters, _rParamRequest.Connection, m_xORB);
+ OParameterDialog aDlg(NULL, _rParamRequest.Parameters, _rParamRequest.Connection, comphelper::getComponentContext(m_xORB));
sal_Int16 nResult = aDlg.Execute();
try
{
diff --git a/dbaccess/uiconfig/dbapp/menubar/menubar.xml b/dbaccess/uiconfig/dbapp/menubar/menubar.xml
index 84e999a0d073..1ddbe5a2c73b 100644
--- a/dbaccess/uiconfig/dbapp/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbapp/menubar/menubar.xml
@@ -29,6 +29,9 @@
<menu:menuitem menu:id=".uno:Save"/>
<menu:menuitem menu:id=".uno:SaveAs"/>
<menu:menuitem menu:id=".uno:SaveAll"/>
+ <menu:menuitem menu:id=".uno:CheckOut"/>
+ <menu:menuitem menu:id=".uno:CancelCheckOut"/>
+ <menu:menuitem menu:id=".uno:CheckIn"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:ExportTo"/>
<menu:menu menu:id=".uno:SendToMenu">
diff --git a/dbaccess/uiconfig/dbquery/menubar/menubar.xml b/dbaccess/uiconfig/dbquery/menubar/menubar.xml
index 4e980800dd19..dd84ef30e99a 100644
--- a/dbaccess/uiconfig/dbquery/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbquery/menubar/menubar.xml
@@ -27,6 +27,9 @@
<menu:menuitem menu:id=".uno:SaveAll"/>
<menu:menuitem menu:id=".uno:Save"/>
<menu:menuitem menu:id=".uno:SaveAs"/>
+ <menu:menuitem menu:id=".uno:CheckOut"/>
+ <menu:menuitem menu:id=".uno:CancelCheckOut"/>
+ <menu:menuitem menu:id=".uno:CheckIn"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Quit"/>
</menu:menupopup>
diff --git a/dbaccess/uiconfig/dbrelation/menubar/menubar.xml b/dbaccess/uiconfig/dbrelation/menubar/menubar.xml
index 688ecf2b68d0..f4a9ffc1e493 100644
--- a/dbaccess/uiconfig/dbrelation/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbrelation/menubar/menubar.xml
@@ -26,6 +26,9 @@
<menu:menuitem menu:id=".uno:CloseDoc"/>
<menu:menuitem menu:id=".uno:SaveAll"/>
<menu:menuitem menu:id=".uno:Save"/>
+ <menu:menuitem menu:id=".uno:CheckOut"/>
+ <menu:menuitem menu:id=".uno:CancelCheckOut"/>
+ <menu:menuitem menu:id=".uno:CheckIn"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Quit"/>
</menu:menupopup>
diff --git a/dbaccess/uiconfig/dbtable/menubar/menubar.xml b/dbaccess/uiconfig/dbtable/menubar/menubar.xml
index 5fa12003a709..63982adf15f0 100644
--- a/dbaccess/uiconfig/dbtable/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbtable/menubar/menubar.xml
@@ -27,6 +27,9 @@
<menu:menuitem menu:id=".uno:SaveAll"/>
<menu:menuitem menu:id=".uno:Save"/>
<menu:menuitem menu:id=".uno:SaveAs"/>
+ <menu:menuitem menu:id=".uno:CheckOut"/>
+ <menu:menuitem menu:id=".uno:CancelCheckOut"/>
+ <menu:menuitem menu:id=".uno:CheckIn"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Quit"/>
</menu:menupopup>
diff --git a/dbaccess/uiconfig/dbtdata/menubar/menubar.xml b/dbaccess/uiconfig/dbtdata/menubar/menubar.xml
index 5f35b46de3e3..95c327e9c900 100644
--- a/dbaccess/uiconfig/dbtdata/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbtdata/menubar/menubar.xml
@@ -27,6 +27,9 @@
<menu:menuitem menu:id=".uno:SaveAll"/>
<menu:menuitem menu:id=".uno:Save"/>
<menu:menuitem menu:id=".uno:SaveAs"/>
+ <menu:menuitem menu:id=".uno:CheckOut"/>
+ <menu:menuitem menu:id=".uno:CancelCheckOut"/>
+ <menu:menuitem menu:id=".uno:CheckIn"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:Quit"/>
</menu:menupopup>