summaryrefslogtreecommitdiff
path: root/dbaccess
diff options
context:
space:
mode:
Diffstat (limited to 'dbaccess')
-rw-r--r--dbaccess/AllLangResTarget_dba.mk55
-rw-r--r--dbaccess/AllLangResTarget_dbmm.mk54
-rw-r--r--dbaccess/AllLangResTarget_dbu.mk95
-rw-r--r--dbaccess/AllLangResTarget_sdbt.mk57
-rw-r--r--dbaccess/Executable_odbcconfig.mk71
-rw-r--r--dbaccess/JunitTest_dbaccess_unoapi.mk63
-rw-r--r--dbaccess/Library_adabasui.mk71
-rw-r--r--dbaccess/Library_dba.mk260
-rw-r--r--dbaccess/Library_dbaxml.mk144
-rw-r--r--dbaccess/Library_dbmm.mk111
-rw-r--r--dbaccess/Library_dbu.mk321
-rw-r--r--dbaccess/Library_sdbt.mk95
-rw-r--r--dbaccess/Module_dbaccess.mk76
-rw-r--r--dbaccess/Package_inc.mk62
-rw-r--r--dbaccess/Package_uiconfig.mk54
-rw-r--r--dbaccess/inc/AsyncronousLink.hxx2
-rw-r--r--dbaccess/inc/IController.hxx9
-rw-r--r--dbaccess/inc/IReference.hxx2
-rw-r--r--dbaccess/inc/ToolBoxHelper.hxx16
-rw-r--r--dbaccess/inc/controllerframe.hxx3
-rw-r--r--dbaccess/inc/dataview.hxx3
-rw-r--r--dbaccess/inc/dbaccessdllapi.h2
-rw-r--r--[-rwxr-xr-x]dbaccess/inc/dbaundomanager.hxx0
-rw-r--r--dbaccess/inc/dbsubcomponentcontroller.hxx2
-rw-r--r--dbaccess/inc/genericcontroller.hxx2
-rw-r--r--dbaccess/inc/makefile.mk47
-rw-r--r--dbaccess/inc/pch/precompiled_dbaccess.cxx2
-rw-r--r--dbaccess/inc/pch/precompiled_dbaccess.hxx9
-rw-r--r--dbaccess/prj/build.lst5
-rwxr-xr-x[-rw-r--r--]dbaccess/prj/makefile.mk2
-rw-r--r--dbaccess/qa/complex/dbaccess/DatabaseDocument.java2
-rw-r--r--dbaccess/qa/complex/dbaccess/RowSet.java5
-rw-r--r--dbaccess/qa/unoapi/makefile.mk48
-rw-r--r--dbaccess/source/core/api/BookmarkSet.cxx38
-rw-r--r--dbaccess/source/core/api/BookmarkSet.hxx6
-rw-r--r--dbaccess/source/core/api/CIndexColumn.hxx5
-rw-r--r--dbaccess/source/core/api/CIndexes.cxx31
-rw-r--r--dbaccess/source/core/api/CIndexes.hxx5
-rw-r--r--dbaccess/source/core/api/CRowSetColumn.cxx20
-rw-r--r--dbaccess/source/core/api/CRowSetColumn.hxx11
-rw-r--r--dbaccess/source/core/api/CRowSetDataColumn.cxx69
-rw-r--r--dbaccess/source/core/api/CRowSetDataColumn.hxx11
-rw-r--r--dbaccess/source/core/api/CacheSet.cxx208
-rw-r--r--dbaccess/source/core/api/CacheSet.hxx2
-rw-r--r--dbaccess/source/core/api/FilteredContainer.cxx31
-rw-r--r--dbaccess/source/core/api/HelperCollections.cxx25
-rw-r--r--dbaccess/source/core/api/HelperCollections.hxx23
-rw-r--r--dbaccess/source/core/api/KeySet.cxx249
-rw-r--r--dbaccess/source/core/api/KeySet.hxx24
-rw-r--r--dbaccess/source/core/api/OptimisticSet.cxx80
-rw-r--r--dbaccess/source/core/api/OptimisticSet.hxx7
-rw-r--r--dbaccess/source/core/api/PrivateRow.cxx2
-rw-r--r--dbaccess/source/core/api/PrivateRow.hxx6
-rw-r--r--dbaccess/source/core/api/RowSet.cxx416
-rw-r--r--dbaccess/source/core/api/RowSet.hxx10
-rw-r--r--dbaccess/source/core/api/RowSetBase.cxx311
-rw-r--r--dbaccess/source/core/api/RowSetBase.hxx47
-rw-r--r--dbaccess/source/core/api/RowSetCache.cxx211
-rw-r--r--dbaccess/source/core/api/RowSetCache.hxx51
-rw-r--r--dbaccess/source/core/api/RowSetCacheIterator.cxx37
-rw-r--r--dbaccess/source/core/api/RowSetCacheIterator.hxx7
-rw-r--r--dbaccess/source/core/api/RowSetRow.hxx20
-rw-r--r--dbaccess/source/core/api/SingleSelectQueryComposer.cxx151
-rw-r--r--dbaccess/source/core/api/StaticSet.cxx89
-rw-r--r--dbaccess/source/core/api/StaticSet.hxx4
-rw-r--r--dbaccess/source/core/api/TableDeco.cxx131
-rw-r--r--dbaccess/source/core/api/View.cxx20
-rw-r--r--dbaccess/source/core/api/WrappedResultSet.cxx40
-rw-r--r--dbaccess/source/core/api/WrappedResultSet.hxx7
-rw-r--r--dbaccess/source/core/api/callablestatement.cxx46
-rw-r--r--dbaccess/source/core/api/column.cxx47
-rw-r--r--dbaccess/source/core/api/columnsettings.cxx15
-rw-r--r--dbaccess/source/core/api/datacolumn.cxx73
-rw-r--r--dbaccess/source/core/api/datacolumn.hxx14
-rw-r--r--dbaccess/source/core/api/datasettings.cxx37
-rw-r--r--dbaccess/source/core/api/definitioncolumn.cxx76
-rw-r--r--dbaccess/source/core/api/makefile.mk82
-rw-r--r--dbaccess/source/core/api/preparedstatement.cxx45
-rw-r--r--dbaccess/source/core/api/query.cxx95
-rw-r--r--dbaccess/source/core/api/query.hxx16
-rw-r--r--dbaccess/source/core/api/querycomposer.cxx105
-rw-r--r--dbaccess/source/core/api/querycontainer.cxx93
-rw-r--r--dbaccess/source/core/api/querydescriptor.cxx72
-rw-r--r--dbaccess/source/core/api/querydescriptor.hxx26
-rw-r--r--dbaccess/source/core/api/resultcolumn.cxx48
-rw-r--r--dbaccess/source/core/api/resultcolumn.hxx6
-rw-r--r--dbaccess/source/core/api/resultset.cxx170
-rw-r--r--dbaccess/source/core/api/resultset.hxx42
-rw-r--r--dbaccess/source/core/api/statement.cxx76
-rw-r--r--dbaccess/source/core/api/table.cxx53
-rw-r--r--dbaccess/source/core/api/tablecontainer.cxx56
-rw-r--r--dbaccess/source/core/api/viewcontainer.cxx34
-rw-r--r--dbaccess/source/core/dataaccess/ComponentDefinition.cxx70
-rw-r--r--dbaccess/source/core/dataaccess/ComponentDefinition.hxx29
-rw-r--r--dbaccess/source/core/dataaccess/ContentHelper.cxx187
-rw-r--r--dbaccess/source/core/dataaccess/ModelImpl.cxx114
-rw-r--r--dbaccess/source/core/dataaccess/ModelImpl.hxx11
-rw-r--r--dbaccess/source/core/dataaccess/SharedConnection.cxx53
-rw-r--r--dbaccess/source/core/dataaccess/SharedConnection.hxx41
-rw-r--r--dbaccess/source/core/dataaccess/bookmarkcontainer.cxx67
-rw-r--r--dbaccess/source/core/dataaccess/bookmarkcontainer.hxx33
-rw-r--r--dbaccess/source/core/dataaccess/commandcontainer.cxx26
-rw-r--r--dbaccess/source/core/dataaccess/commandcontainer.hxx14
-rw-r--r--dbaccess/source/core/dataaccess/commanddefinition.cxx26
-rw-r--r--dbaccess/source/core/dataaccess/commanddefinition.hxx25
-rw-r--r--dbaccess/source/core/dataaccess/connection.cxx98
-rw-r--r--dbaccess/source/core/dataaccess/connection.hxx2
-rw-r--r--dbaccess/source/core/dataaccess/dataaccessdescriptor.cxx26
-rw-r--r--dbaccess/source/core/dataaccess/databasecontext.cxx84
-rw-r--r--dbaccess/source/core/dataaccess/databasecontext.hxx3
-rw-r--r--dbaccess/source/core/dataaccess/databasedocument.cxx191
-rw-r--r--dbaccess/source/core/dataaccess/databasedocument.hxx10
-rw-r--r--dbaccess/source/core/dataaccess/databaseregistrations.cxx32
-rw-r--r--dbaccess/source/core/dataaccess/databaseregistrations.hxx7
-rw-r--r--dbaccess/source/core/dataaccess/datasource.cxx150
-rw-r--r--dbaccess/source/core/dataaccess/datasource.hxx72
-rw-r--r--dbaccess/source/core/dataaccess/definitioncontainer.cxx109
-rw-r--r--dbaccess/source/core/dataaccess/documentcontainer.cxx108
-rw-r--r--dbaccess/source/core/dataaccess/documentcontainer.hxx26
-rw-r--r--dbaccess/source/core/dataaccess/documentdefinition.cxx350
-rw-r--r--dbaccess/source/core/dataaccess/documentdefinition.hxx30
-rw-r--r--dbaccess/source/core/dataaccess/documenteventexecutor.cxx27
-rw-r--r--dbaccess/source/core/dataaccess/documenteventexecutor.hxx7
-rw-r--r--dbaccess/source/core/dataaccess/documenteventnotifier.cxx23
-rw-r--r--dbaccess/source/core/dataaccess/documenteventnotifier.hxx7
-rw-r--r--dbaccess/source/core/dataaccess/documentevents.cxx22
-rw-r--r--dbaccess/source/core/dataaccess/documentevents.hxx7
-rw-r--r--dbaccess/source/core/dataaccess/intercept.cxx17
-rw-r--r--dbaccess/source/core/dataaccess/intercept.hxx25
-rw-r--r--dbaccess/source/core/dataaccess/makefile.mk69
-rw-r--r--dbaccess/source/core/dataaccess/myucp_datasupplier.cxx43
-rw-r--r--dbaccess/source/core/dataaccess/myucp_datasupplier.hxx9
-rw-r--r--dbaccess/source/core/dataaccess/myucp_resultset.cxx11
-rw-r--r--dbaccess/source/core/dataaccess/myucp_resultset.hxx9
-rw-r--r--dbaccess/source/core/inc/ContainerListener.hxx16
-rw-r--r--dbaccess/source/core/inc/ContainerMediator.hxx26
-rw-r--r--dbaccess/source/core/inc/ContentHelper.hxx50
-rw-r--r--dbaccess/source/core/inc/DatabaseDataProvider.hxx3
-rw-r--r--dbaccess/source/core/inc/FilteredContainer.hxx3
-rw-r--r--dbaccess/source/core/inc/PropertyForward.hxx19
-rw-r--r--dbaccess/source/core/inc/RefreshListener.hxx9
-rw-r--r--dbaccess/source/core/inc/SingleSelectQueryComposer.hxx5
-rw-r--r--dbaccess/source/core/inc/TableDeco.hxx38
-rw-r--r--dbaccess/source/core/inc/View.hxx10
-rw-r--r--dbaccess/source/core/inc/callablestatement.hxx8
-rw-r--r--dbaccess/source/core/inc/column.hxx9
-rw-r--r--dbaccess/source/core/inc/columnsettings.hxx7
-rw-r--r--dbaccess/source/core/inc/commandbase.hxx11
-rw-r--r--dbaccess/source/core/inc/composertools.hxx8
-rw-r--r--dbaccess/source/core/inc/containerapprove.hxx8
-rw-r--r--dbaccess/source/core/inc/core_resource.hrc3
-rw-r--r--dbaccess/source/core/inc/core_resource.hxx11
-rw-r--r--dbaccess/source/core/inc/datasettings.hxx18
-rw-r--r--dbaccess/source/core/inc/definitioncolumn.hxx2
-rw-r--r--dbaccess/source/core/inc/definitioncontainer.hxx45
-rw-r--r--dbaccess/source/core/inc/module_dba.hxx6
-rw-r--r--dbaccess/source/core/inc/object.hxx2
-rw-r--r--dbaccess/source/core/inc/objectnameapproval.hxx11
-rw-r--r--dbaccess/source/core/inc/preparedstatement.hxx18
-rw-r--r--dbaccess/source/core/inc/querycomposer.hxx29
-rw-r--r--dbaccess/source/core/inc/querycontainer.hxx52
-rw-r--r--dbaccess/source/core/inc/recovery/dbdocrecovery.hxx7
-rw-r--r--dbaccess/source/core/inc/sdbcoretools.hxx10
-rw-r--r--dbaccess/source/core/inc/statement.hxx30
-rw-r--r--dbaccess/source/core/inc/table.hxx3
-rw-r--r--dbaccess/source/core/inc/tablecontainer.hxx34
-rw-r--r--dbaccess/source/core/inc/userinformation.hxx6
-rw-r--r--dbaccess/source/core/inc/veto.hxx10
-rw-r--r--dbaccess/source/core/inc/viewcontainer.hxx28
-rw-r--r--dbaccess/source/core/misc/ContainerListener.cxx5
-rw-r--r--dbaccess/source/core/misc/ContainerMediator.cxx27
-rw-r--r--dbaccess/source/core/misc/DatabaseDataProvider.cxx25
-rw-r--r--dbaccess/source/core/misc/PropertyForward.cxx2
-rw-r--r--dbaccess/source/core/misc/apitools.cxx12
-rw-r--r--dbaccess/source/core/misc/dbastrings.cxx5
-rw-r--r--dbaccess/source/core/misc/dsntypes.cxx44
-rw-r--r--dbaccess/source/core/misc/makefile.mk60
-rw-r--r--dbaccess/source/core/misc/module_dba.cxx2
-rw-r--r--dbaccess/source/core/misc/objectnameapproval.cxx16
-rw-r--r--dbaccess/source/core/misc/sdbcoretools.cxx2
-rw-r--r--dbaccess/source/core/misc/services.cxx31
-rw-r--r--dbaccess/source/core/misc/userinformation.cxx12
-rw-r--r--dbaccess/source/core/misc/veto.cxx4
-rw-r--r--dbaccess/source/core/recovery/dbdocrecovery.cxx18
-rw-r--r--dbaccess/source/core/recovery/makefile.mk58
-rw-r--r--dbaccess/source/core/recovery/settingsimport.cxx25
-rw-r--r--dbaccess/source/core/recovery/settingsimport.hxx3
-rw-r--r--dbaccess/source/core/recovery/storagestream.cxx3
-rw-r--r--dbaccess/source/core/recovery/storagestream.hxx3
-rw-r--r--dbaccess/source/core/recovery/storagetextstream.cxx3
-rw-r--r--dbaccess/source/core/recovery/storagetextstream.hxx3
-rw-r--r--dbaccess/source/core/recovery/storagexmlstream.cxx3
-rw-r--r--dbaccess/source/core/recovery/storagexmlstream.hxx3
-rw-r--r--dbaccess/source/core/recovery/subcomponentloader.cxx3
-rw-r--r--dbaccess/source/core/recovery/subcomponentloader.hxx3
-rw-r--r--dbaccess/source/core/recovery/subcomponentrecovery.cxx29
-rw-r--r--dbaccess/source/core/recovery/subcomponentrecovery.hxx3
-rw-r--r--dbaccess/source/core/recovery/subcomponents.hxx7
-rw-r--r--dbaccess/source/core/resource/core_resource.cxx6
-rw-r--r--dbaccess/source/core/resource/makefile.mk48
-rw-r--r--dbaccess/source/core/resource/strings.src49
-rw-r--r--dbaccess/source/ext/adabas/ANewDb.cxx18
-rw-r--r--dbaccess/source/ext/adabas/ANewDb.hxx9
-rw-r--r--dbaccess/source/ext/adabas/ASQLNameEdit.hxx6
-rw-r--r--dbaccess/source/ext/adabas/ASqlNameEdit.cxx4
-rw-r--r--dbaccess/source/ext/adabas/Acomponentmodule.cxx22
-rw-r--r--dbaccess/source/ext/adabas/Acomponentmodule.hxx18
-rw-r--r--dbaccess/source/ext/adabas/AdabasNewDb.cxx64
-rw-r--r--dbaccess/source/ext/adabas/AdabasNewDb.hxx18
-rw-r--r--dbaccess/source/ext/adabas/AdabasNewDb.src82
-rw-r--r--dbaccess/source/ext/adabas/Aservices.cxx12
-rw-r--r--dbaccess/source/ext/adabas/Astringconstants.cxx2
-rw-r--r--dbaccess/source/ext/adabas/adabasuistrings.cxx4
-rw-r--r--dbaccess/source/ext/adabas/makefile.mk100
-rw-r--r--dbaccess/source/ext/macromigration/dbmm_module.cxx2
-rw-r--r--dbaccess/source/ext/macromigration/dbmm_module.hxx2
-rw-r--r--dbaccess/source/ext/macromigration/dbmm_services.cxx14
-rw-r--r--dbaccess/source/ext/macromigration/dbmm_types.cxx3
-rw-r--r--dbaccess/source/ext/macromigration/dbmm_types.hxx4
-rw-r--r--dbaccess/source/ext/macromigration/docinteraction.cxx3
-rw-r--r--dbaccess/source/ext/macromigration/docinteraction.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/macromigration.src3
-rw-r--r--dbaccess/source/ext/macromigration/macromigrationdialog.cxx9
-rw-r--r--dbaccess/source/ext/macromigration/macromigrationdialog.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/macromigrationpages.cxx3
-rw-r--r--dbaccess/source/ext/macromigration/macromigrationpages.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/macromigrationwizard.cxx3
-rw-r--r--dbaccess/source/ext/macromigration/makefile.mk109
-rw-r--r--dbaccess/source/ext/macromigration/migrationengine.cxx35
-rw-r--r--dbaccess/source/ext/macromigration/migrationengine.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/migrationerror.hxx2
-rw-r--r--dbaccess/source/ext/macromigration/migrationlog.cxx9
-rw-r--r--dbaccess/source/ext/macromigration/migrationlog.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/migrationprogress.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/progresscapture.cxx17
-rw-r--r--dbaccess/source/ext/macromigration/progresscapture.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/progressmixer.cxx3
-rw-r--r--dbaccess/source/ext/macromigration/progressmixer.hxx3
-rw-r--r--dbaccess/source/ext/macromigration/rangeprogressbar.hxx3
-rw-r--r--dbaccess/source/filter/xml/dbloader2.cxx30
-rw-r--r--dbaccess/source/filter/xml/makefile.mk122
-rw-r--r--dbaccess/source/filter/xml/xmlAutoStyle.cxx13
-rw-r--r--dbaccess/source/filter/xml/xmlAutoStyle.hxx10
-rw-r--r--dbaccess/source/filter/xml/xmlColumn.cxx40
-rw-r--r--dbaccess/source/filter/xml/xmlColumn.hxx3
-rw-r--r--dbaccess/source/filter/xml/xmlComponent.cxx25
-rw-r--r--dbaccess/source/filter/xml/xmlComponent.hxx7
-rw-r--r--dbaccess/source/filter/xml/xmlConnectionData.cxx23
-rw-r--r--dbaccess/source/filter/xml/xmlConnectionData.hxx7
-rw-r--r--dbaccess/source/filter/xml/xmlConnectionResource.cxx23
-rw-r--r--dbaccess/source/filter/xml/xmlConnectionResource.hxx6
-rw-r--r--dbaccess/source/filter/xml/xmlDataSource.cxx45
-rw-r--r--dbaccess/source/filter/xml/xmlDataSource.hxx7
-rw-r--r--dbaccess/source/filter/xml/xmlDataSourceInfo.cxx25
-rw-r--r--dbaccess/source/filter/xml/xmlDataSourceInfo.hxx5
-rw-r--r--dbaccess/source/filter/xml/xmlDataSourceSetting.cxx31
-rw-r--r--dbaccess/source/filter/xml/xmlDataSourceSetting.hxx9
-rw-r--r--dbaccess/source/filter/xml/xmlDataSourceSettings.cxx23
-rw-r--r--dbaccess/source/filter/xml/xmlDataSourceSettings.hxx5
-rw-r--r--dbaccess/source/filter/xml/xmlDatabase.cxx3
-rw-r--r--dbaccess/source/filter/xml/xmlDatabase.hxx5
-rw-r--r--dbaccess/source/filter/xml/xmlDatabaseDescription.cxx19
-rw-r--r--dbaccess/source/filter/xml/xmlDatabaseDescription.hxx7
-rw-r--r--dbaccess/source/filter/xml/xmlDocuments.cxx26
-rw-r--r--dbaccess/source/filter/xml/xmlDocuments.hxx9
-rw-r--r--dbaccess/source/filter/xml/xmlEnums.hxx3
-rw-r--r--dbaccess/source/filter/xml/xmlExport.cxx77
-rw-r--r--dbaccess/source/filter/xml/xmlExport.hxx45
-rw-r--r--dbaccess/source/filter/xml/xmlFileBasedDatabase.cxx23
-rw-r--r--dbaccess/source/filter/xml/xmlFileBasedDatabase.hxx7
-rw-r--r--dbaccess/source/filter/xml/xmlHelper.cxx52
-rw-r--r--dbaccess/source/filter/xml/xmlHelper.hxx8
-rw-r--r--dbaccess/source/filter/xml/xmlHierarchyCollection.cxx35
-rw-r--r--dbaccess/source/filter/xml/xmlHierarchyCollection.hxx3
-rw-r--r--dbaccess/source/filter/xml/xmlLogin.cxx29
-rw-r--r--dbaccess/source/filter/xml/xmlLogin.hxx5
-rw-r--r--dbaccess/source/filter/xml/xmlQuery.cxx29
-rw-r--r--dbaccess/source/filter/xml/xmlQuery.hxx7
-rw-r--r--dbaccess/source/filter/xml/xmlServerDatabase.cxx23
-rw-r--r--dbaccess/source/filter/xml/xmlServerDatabase.hxx6
-rw-r--r--dbaccess/source/filter/xml/xmlStyleImport.cxx45
-rw-r--r--dbaccess/source/filter/xml/xmlStyleImport.hxx24
-rw-r--r--dbaccess/source/filter/xml/xmlTable.cxx39
-rw-r--r--dbaccess/source/filter/xml/xmlTable.hxx9
-rw-r--r--dbaccess/source/filter/xml/xmlTableFilterList.cxx27
-rw-r--r--dbaccess/source/filter/xml/xmlTableFilterList.hxx5
-rw-r--r--dbaccess/source/filter/xml/xmlTableFilterPattern.cxx9
-rw-r--r--dbaccess/source/filter/xml/xmlTableFilterPattern.hxx5
-rw-r--r--dbaccess/source/filter/xml/xmlfilter.cxx124
-rw-r--r--dbaccess/source/filter/xml/xmlfilter.hxx41
-rw-r--r--dbaccess/source/filter/xml/xmlservices.cxx8
-rw-r--r--[-rwxr-xr-x]dbaccess/source/inc/OAuthenticationContinuation.hxx2
-rw-r--r--dbaccess/source/inc/apitools.hxx16
-rw-r--r--dbaccess/source/inc/constasciistring.hxx3
-rw-r--r--dbaccess/source/inc/dbadllapi.hxx3
-rw-r--r--dbaccess/source/inc/dbu_reghelper.hxx14
-rw-r--r--dbaccess/source/inc/dsntypes.hxx4
-rw-r--r--dbaccess/source/inc/flt_reghelper.hxx14
-rw-r--r--dbaccess/source/inc/registrationhelper.hxx2
-rw-r--r--dbaccess/source/inc/stringconstants.hrc2
-rw-r--r--dbaccess/source/inc/stringconstants.inc1
-rw-r--r--dbaccess/source/sdbtools/connection/connectiondependent.hxx2
-rw-r--r--dbaccess/source/sdbtools/connection/connectiontools.cxx12
-rw-r--r--dbaccess/source/sdbtools/connection/connectiontools.hxx18
-rw-r--r--dbaccess/source/sdbtools/connection/datasourcemetadata.cxx8
-rw-r--r--dbaccess/source/sdbtools/connection/datasourcemetadata.hxx9
-rw-r--r--dbaccess/source/sdbtools/connection/makefile.mk49
-rw-r--r--dbaccess/source/sdbtools/connection/objectnames.cxx10
-rw-r--r--dbaccess/source/sdbtools/connection/objectnames.hxx2
-rw-r--r--dbaccess/source/sdbtools/connection/tablename.cxx7
-rw-r--r--dbaccess/source/sdbtools/connection/tablename.hxx8
-rw-r--r--dbaccess/source/sdbtools/inc/module_sdbt.hxx4
-rw-r--r--dbaccess/source/sdbtools/misc/makefile.mk47
-rw-r--r--dbaccess/source/sdbtools/misc/module_sdbt.cxx4
-rw-r--r--dbaccess/source/sdbtools/misc/sdbt_services.cxx4
-rw-r--r--dbaccess/source/sdbtools/resource/makefile.mk45
-rw-r--r--dbaccess/source/shared/dbu_reghelper.cxx6
-rw-r--r--dbaccess/source/shared/dbustrings.cxx3
-rw-r--r--dbaccess/source/shared/flt_reghelper.cxx9
-rw-r--r--dbaccess/source/shared/makefile.mk69
-rw-r--r--dbaccess/source/shared/registrationhelper.cxx6
-rw-r--r--dbaccess/source/shared/sdbtstrings.cxx3
-rw-r--r--dbaccess/source/shared/xmlstrings.cxx2
-rw-r--r--dbaccess/source/ui/app/AppController.cxx65
-rw-r--r--dbaccess/source/ui/app/AppController.hxx2
-rw-r--r--dbaccess/source/ui/app/AppControllerDnD.cxx160
-rw-r--r--dbaccess/source/ui/app/AppControllerGen.cxx40
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.cxx199
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.hxx39
-rw-r--r--dbaccess/source/ui/app/AppDetailView.cxx120
-rw-r--r--dbaccess/source/ui/app/AppDetailView.hxx29
-rw-r--r--dbaccess/source/ui/app/AppIconControl.cxx35
-rw-r--r--dbaccess/source/ui/app/AppIconControl.hxx6
-rw-r--r--dbaccess/source/ui/app/AppSwapWindow.cxx25
-rw-r--r--dbaccess/source/ui/app/AppSwapWindow.hxx10
-rw-r--r--dbaccess/source/ui/app/AppTitleWindow.cxx18
-rw-r--r--dbaccess/source/ui/app/AppTitleWindow.hxx4
-rw-r--r--dbaccess/source/ui/app/AppView.cxx72
-rw-r--r--dbaccess/source/ui/app/AppView.hxx20
-rw-r--r--dbaccess/source/ui/app/IApplicationController.hxx3
-rw-r--r--dbaccess/source/ui/app/app.src25
-rw-r--r--dbaccess/source/ui/app/makefile.mk70
-rw-r--r--dbaccess/source/ui/app/subcomponentmanager.cxx10
-rw-r--r--dbaccess/source/ui/app/subcomponentmanager.hxx3
-rw-r--r--dbaccess/source/ui/browser/AsyncronousLink.cxx9
-rw-r--r--dbaccess/source/ui/browser/bcommon.src1
-rw-r--r--dbaccess/source/ui/browser/brwctrlr.cxx189
-rw-r--r--dbaccess/source/ui/browser/brwview.cxx37
-rw-r--r--dbaccess/source/ui/browser/dataview.cxx21
-rw-r--r--dbaccess/source/ui/browser/dbexchange.cxx2
-rw-r--r--dbaccess/source/ui/browser/dbloader.cxx27
-rw-r--r--dbaccess/source/ui/browser/dbtreemodel.cxx9
-rw-r--r--dbaccess/source/ui/browser/dbtreemodel.hxx13
-rw-r--r--dbaccess/source/ui/browser/dbtreeview.cxx10
-rw-r--r--dbaccess/source/ui/browser/dbtreeview.hxx6
-rw-r--r--dbaccess/source/ui/browser/dsEntriesNoExp.cxx50
-rw-r--r--dbaccess/source/ui/browser/dsbrowserDnD.cxx10
-rw-r--r--dbaccess/source/ui/browser/exsrcbrw.cxx76
-rw-r--r--dbaccess/source/ui/browser/formadapter.cxx55
-rw-r--r--dbaccess/source/ui/browser/genericcontroller.cxx150
-rw-r--r--dbaccess/source/ui/browser/makefile.mk71
-rw-r--r--dbaccess/source/ui/browser/sbabrw.src17
-rw-r--r--dbaccess/source/ui/browser/sbagrid.cxx244
-rw-r--r--dbaccess/source/ui/browser/sbagrid.src5
-rw-r--r--dbaccess/source/ui/browser/sbamultiplex.cxx4
-rw-r--r--dbaccess/source/ui/browser/unodatbr.cxx197
-rw-r--r--dbaccess/source/ui/control/ColumnControlWindow.cxx17
-rw-r--r--dbaccess/source/ui/control/FieldDescControl.cxx40
-rw-r--r--dbaccess/source/ui/control/RelationControl.cxx48
-rw-r--r--dbaccess/source/ui/control/ScrollHelper.cxx6
-rw-r--r--dbaccess/source/ui/control/SqlNameEdit.cxx4
-rw-r--r--dbaccess/source/ui/control/TableGrantCtrl.cxx20
-rw-r--r--dbaccess/source/ui/control/TableGrantCtrl.src28
-rw-r--r--dbaccess/source/ui/control/VertSplitView.cxx7
-rw-r--r--dbaccess/source/ui/control/charsetlistbox.cxx10
-rw-r--r--dbaccess/source/ui/control/curledit.cxx9
-rw-r--r--dbaccess/source/ui/control/dbtreelistbox.cxx61
-rw-r--r--dbaccess/source/ui/control/listviewitems.cxx4
-rw-r--r--dbaccess/source/ui/control/makefile.mk78
-rw-r--r--dbaccess/source/ui/control/marktree.cxx17
-rw-r--r--dbaccess/source/ui/control/opendoccontrols.cxx46
-rw-r--r--dbaccess/source/ui/control/sqledit.cxx3
-rw-r--r--dbaccess/source/ui/control/statusbarontroller.cxx5
-rw-r--r--dbaccess/source/ui/control/tabletree.cxx105
-rw-r--r--dbaccess/source/ui/control/tabletree.src7
-rw-r--r--dbaccess/source/ui/control/toolboxcontroller.cxx56
-rw-r--r--dbaccess/source/ui/control/undosqledit.cxx6
-rw-r--r--dbaccess/source/ui/control/undosqledit.src31
-rw-r--r--dbaccess/source/ui/dlg/AdabasStat.cxx62
-rw-r--r--dbaccess/source/ui/dlg/AdabasStat.hxx16
-rw-r--r--dbaccess/source/ui/dlg/AdabasStat.src30
-rw-r--r--dbaccess/source/ui/dlg/AutoControls.src9
-rw-r--r--dbaccess/source/ui/dlg/CollectionView.cxx61
-rw-r--r--dbaccess/source/ui/dlg/CollectionView.src16
-rw-r--r--dbaccess/source/ui/dlg/ConnectionHelper.cxx51
-rw-r--r--dbaccess/source/ui/dlg/ConnectionHelper.hxx12
-rw-r--r--dbaccess/source/ui/dlg/ConnectionPage.cxx96
-rw-r--r--dbaccess/source/ui/dlg/ConnectionPage.hxx11
-rw-r--r--dbaccess/source/ui/dlg/ConnectionPage.src8
-rw-r--r--dbaccess/source/ui/dlg/ConnectionPageSetup.cxx7
-rw-r--r--dbaccess/source/ui/dlg/ConnectionPageSetup.hxx21
-rw-r--r--dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx67
-rw-r--r--dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx6
-rw-r--r--dbaccess/source/ui/dlg/DbAdminImpl.cxx89
-rw-r--r--dbaccess/source/ui/dlg/DbAdminImpl.hxx26
-rw-r--r--dbaccess/source/ui/dlg/DriverSettings.cxx3
-rw-r--r--dbaccess/source/ui/dlg/DriverSettings.hxx4
-rw-r--r--dbaccess/source/ui/dlg/RelationDlg.cxx37
-rw-r--r--dbaccess/source/ui/dlg/RelationDlg.src7
-rw-r--r--dbaccess/source/ui/dlg/TablesSingleDlg.cxx14
-rw-r--r--dbaccess/source/ui/dlg/TextConnectionHelper.cxx77
-rw-r--r--dbaccess/source/ui/dlg/TextConnectionHelper.hxx20
-rw-r--r--dbaccess/source/ui/dlg/UserAdmin.cxx45
-rw-r--r--dbaccess/source/ui/dlg/UserAdmin.hxx21
-rw-r--r--dbaccess/source/ui/dlg/UserAdmin.src29
-rw-r--r--dbaccess/source/ui/dlg/UserAdminDlg.cxx13
-rw-r--r--dbaccess/source/ui/dlg/UserAdminDlg.src1
-rw-r--r--[-rwxr-xr-x]dbaccess/source/ui/dlg/admincontrols.cxx5
-rw-r--r--[-rwxr-xr-x]dbaccess/source/ui/dlg/admincontrols.hxx3
-rw-r--r--[-rwxr-xr-x]dbaccess/source/ui/dlg/admincontrols.src0
-rw-r--r--dbaccess/source/ui/dlg/adminpages.cxx4
-rw-r--r--dbaccess/source/ui/dlg/adminpages.hxx16
-rw-r--r--dbaccess/source/ui/dlg/adodatalinks.cxx5
-rw-r--r--dbaccess/source/ui/dlg/adodatalinks.hxx6
-rw-r--r--dbaccess/source/ui/dlg/adtabdlg.cxx13
-rw-r--r--dbaccess/source/ui/dlg/adtabdlg.src3
-rw-r--r--dbaccess/source/ui/dlg/advancedsettings.cxx5
-rw-r--r--dbaccess/source/ui/dlg/advancedsettings.hxx3
-rw-r--r--dbaccess/source/ui/dlg/dbadmin.cxx8
-rw-r--r--dbaccess/source/ui/dlg/dbadmin.src5
-rw-r--r--dbaccess/source/ui/dlg/dbadmin2.src6
-rw-r--r--dbaccess/source/ui/dlg/dbadminsetup.hrc1
-rw-r--r--dbaccess/source/ui/dlg/dbadminsetup.src33
-rw-r--r--dbaccess/source/ui/dlg/dbfindex.cxx43
-rw-r--r--dbaccess/source/ui/dlg/dbfindex.hxx14
-rw-r--r--dbaccess/source/ui/dlg/dbfindex.src65
-rw-r--r--dbaccess/source/ui/dlg/dbwiz.cxx45
-rw-r--r--dbaccess/source/ui/dlg/dbwizsetup.cxx94
-rw-r--r--dbaccess/source/ui/dlg/detailpages.cxx39
-rw-r--r--dbaccess/source/ui/dlg/detailpages.hxx21
-rw-r--r--dbaccess/source/ui/dlg/directsql.cxx26
-rw-r--r--dbaccess/source/ui/dlg/directsql.src1
-rw-r--r--dbaccess/source/ui/dlg/dlgattr.cxx52
-rw-r--r--dbaccess/source/ui/dlg/dlgattr.src33
-rw-r--r--dbaccess/source/ui/dlg/dlgsave.cxx44
-rw-r--r--dbaccess/source/ui/dlg/dlgsave.src1
-rw-r--r--dbaccess/source/ui/dlg/dlgsize.cxx10
-rw-r--r--dbaccess/source/ui/dlg/dlgsize.src31
-rw-r--r--dbaccess/source/ui/dlg/dsnItem.hxx2
-rw-r--r--dbaccess/source/ui/dlg/dsselect.cxx49
-rw-r--r--dbaccess/source/ui/dlg/dsselect.hxx2
-rw-r--r--dbaccess/source/ui/dlg/dsselect.src2
-rw-r--r--dbaccess/source/ui/dlg/finteraction.cxx11
-rw-r--r--dbaccess/source/ui/dlg/finteraction.hxx6
-rw-r--r--dbaccess/source/ui/dlg/generalpage.cxx16
-rw-r--r--dbaccess/source/ui/dlg/generalpage.hxx13
-rw-r--r--dbaccess/source/ui/dlg/indexdialog.cxx83
-rw-r--r--dbaccess/source/ui/dlg/indexdialog.src12
-rw-r--r--dbaccess/source/ui/dlg/indexfieldscontrol.cxx19
-rw-r--r--dbaccess/source/ui/dlg/makefile.mk154
-rw-r--r--dbaccess/source/ui/dlg/odbcconfig.cxx41
-rw-r--r--dbaccess/source/ui/dlg/odbcconfig.hxx6
-rw-r--r--dbaccess/source/ui/dlg/optionalboolitem.cxx3
-rw-r--r--dbaccess/source/ui/dlg/optionalboolitem.hxx3
-rw-r--r--dbaccess/source/ui/dlg/paramdialog.cxx49
-rw-r--r--dbaccess/source/ui/dlg/paramdialog.src2
-rw-r--r--dbaccess/source/ui/dlg/queryfilter.cxx70
-rw-r--r--dbaccess/source/ui/dlg/queryfilter.src13
-rw-r--r--dbaccess/source/ui/dlg/queryorder.cxx36
-rw-r--r--dbaccess/source/ui/dlg/queryorder.src37
-rw-r--r--dbaccess/source/ui/dlg/sqlmessage.cxx79
-rw-r--r--dbaccess/source/ui/dlg/sqlmessage.src23
-rw-r--r--dbaccess/source/ui/dlg/tablespage.cxx79
-rw-r--r--dbaccess/source/ui/dlg/tablespage.hxx16
-rw-r--r--dbaccess/source/ui/dlg/textconnectionsettings.cxx3
-rw-r--r--dbaccess/source/ui/imagelists/dbimagelists.src105
-rw-r--r--dbaccess/source/ui/imagelists/makefile.mk49
-rw-r--r--dbaccess/source/ui/inc/AccessibleBaseIFace.hxx5
-rw-r--r--dbaccess/source/ui/inc/AppElementType.hxx2
-rw-r--r--dbaccess/source/ui/inc/CollectionView.hxx14
-rw-r--r--dbaccess/source/ui/inc/ColumnControlWindow.hxx11
-rw-r--r--dbaccess/source/ui/inc/ConnectionLine.hxx11
-rw-r--r--dbaccess/source/ui/inc/ConnectionLineAccess.hxx9
-rw-r--r--dbaccess/source/ui/inc/ConnectionLineData.hxx21
-rw-r--r--dbaccess/source/ui/inc/DExport.hxx7
-rw-r--r--dbaccess/source/ui/inc/FieldControls.hxx12
-rw-r--r--dbaccess/source/ui/inc/FieldDescControl.hxx12
-rw-r--r--dbaccess/source/ui/inc/FieldDescriptions.hxx14
-rw-r--r--dbaccess/source/ui/inc/GeneralUndo.hxx6
-rw-r--r--dbaccess/source/ui/inc/HtmlReader.hxx14
-rw-r--r--dbaccess/source/ui/inc/IClipBoardTest.hxx5
-rw-r--r--dbaccess/source/ui/inc/IItemSetHelper.hxx8
-rw-r--r--dbaccess/source/ui/inc/IUpdateHelper.hxx2
-rw-r--r--dbaccess/source/ui/inc/JAccess.hxx7
-rw-r--r--dbaccess/source/ui/inc/JoinController.hxx6
-rw-r--r--dbaccess/source/ui/inc/JoinDesignView.hxx8
-rw-r--r--dbaccess/source/ui/inc/JoinExchange.hxx12
-rw-r--r--dbaccess/source/ui/inc/JoinTableView.hxx17
-rw-r--r--dbaccess/source/ui/inc/QEnumTypes.hxx2
-rw-r--r--dbaccess/source/ui/inc/QueryDesignView.hxx16
-rw-r--r--dbaccess/source/ui/inc/QueryTableView.hxx8
-rw-r--r--dbaccess/source/ui/inc/QueryTextView.hxx6
-rw-r--r--dbaccess/source/ui/inc/QueryViewSwitch.hxx2
-rw-r--r--dbaccess/source/ui/inc/RTableConnectionData.hxx10
-rw-r--r--dbaccess/source/ui/inc/RefFunctor.hxx16
-rw-r--r--dbaccess/source/ui/inc/RelControliFace.hxx5
-rw-r--r--dbaccess/source/ui/inc/RelationControl.hxx9
-rw-r--r--dbaccess/source/ui/inc/RelationController.hxx6
-rw-r--r--dbaccess/source/ui/inc/RelationDesignView.hxx10
-rw-r--r--dbaccess/source/ui/inc/RelationDlg.hxx19
-rw-r--r--dbaccess/source/ui/inc/RelationTableView.hxx2
-rw-r--r--dbaccess/source/ui/inc/RtfReader.hxx8
-rw-r--r--dbaccess/source/ui/inc/ScrollHelper.hxx8
-rw-r--r--dbaccess/source/ui/inc/SqlNameEdit.hxx6
-rw-r--r--dbaccess/source/ui/inc/TableConnection.hxx16
-rw-r--r--dbaccess/source/ui/inc/TableConnectionData.hxx9
-rw-r--r--dbaccess/source/ui/inc/TableController.hxx2
-rw-r--r--dbaccess/source/ui/inc/TableCopyHelper.hxx20
-rw-r--r--dbaccess/source/ui/inc/TableDesignControl.hxx10
-rw-r--r--dbaccess/source/ui/inc/TableDesignHelpBar.hxx12
-rw-r--r--dbaccess/source/ui/inc/TableDesignView.hxx12
-rw-r--r--dbaccess/source/ui/inc/TableFieldDescription.hxx18
-rw-r--r--dbaccess/source/ui/inc/TableGrantCtrl.hxx15
-rw-r--r--dbaccess/source/ui/inc/TableRow.hxx15
-rw-r--r--dbaccess/source/ui/inc/TableRowExchange.hxx8
-rw-r--r--dbaccess/source/ui/inc/TableWindow.hxx2
-rw-r--r--dbaccess/source/ui/inc/TableWindowAccess.hxx9
-rw-r--r--dbaccess/source/ui/inc/TableWindowData.hxx4
-rw-r--r--dbaccess/source/ui/inc/TableWindowListBox.hxx2
-rw-r--r--dbaccess/source/ui/inc/TableWindowTitle.hxx4
-rw-r--r--dbaccess/source/ui/inc/TablesSingleDlg.hxx10
-rw-r--r--dbaccess/source/ui/inc/TokenWriter.hxx16
-rw-r--r--dbaccess/source/ui/inc/TypeInfo.hxx10
-rw-r--r--dbaccess/source/ui/inc/UITools.hxx22
-rw-r--r--dbaccess/source/ui/inc/UserAdminDlg.hxx13
-rw-r--r--dbaccess/source/ui/inc/VertSplitView.hxx4
-rw-r--r--dbaccess/source/ui/inc/WCPage.hxx16
-rw-r--r--dbaccess/source/ui/inc/WColumnSelect.hxx8
-rw-r--r--dbaccess/source/ui/inc/WCopyTable.hxx3
-rw-r--r--dbaccess/source/ui/inc/WExtendPages.hxx4
-rw-r--r--dbaccess/source/ui/inc/WNameMatch.hxx14
-rw-r--r--dbaccess/source/ui/inc/WTabPage.hxx6
-rw-r--r--dbaccess/source/ui/inc/WTypeSelect.hxx2
-rw-r--r--dbaccess/source/ui/inc/adtabdlg.hxx19
-rw-r--r--dbaccess/source/ui/inc/advancedsettingsdlg.hxx3
-rw-r--r--dbaccess/source/ui/inc/asyncmodaldialog.hxx4
-rw-r--r--dbaccess/source/ui/inc/browserids.hxx7
-rw-r--r--dbaccess/source/ui/inc/brwctrlr.hxx4
-rw-r--r--dbaccess/source/ui/inc/brwview.hxx12
-rw-r--r--dbaccess/source/ui/inc/callbacks.hxx8
-rw-r--r--dbaccess/source/ui/inc/charsetlistbox.hxx3
-rw-r--r--dbaccess/source/ui/inc/charsets.hxx10
-rw-r--r--dbaccess/source/ui/inc/commontypes.hxx6
-rw-r--r--dbaccess/source/ui/inc/curledit.hxx8
-rw-r--r--dbaccess/source/ui/inc/databaseobjectview.hxx26
-rw-r--r--dbaccess/source/ui/inc/datasourceconnector.hxx10
-rw-r--r--dbaccess/source/ui/inc/datasourcemap.hxx14
-rw-r--r--dbaccess/source/ui/inc/dbadmin.hxx13
-rw-r--r--dbaccess/source/ui/inc/dbexchange.hxx18
-rw-r--r--dbaccess/source/ui/inc/dbtreelistbox.hxx3
-rw-r--r--dbaccess/source/ui/inc/dbu_resource.hrc61
-rw-r--r--dbaccess/source/ui/inc/dbwiz.hxx16
-rw-r--r--dbaccess/source/ui/inc/dbwizsetup.hxx20
-rw-r--r--dbaccess/source/ui/inc/defaultobjectnamecheck.hxx10
-rw-r--r--dbaccess/source/ui/inc/directsql.hxx24
-rw-r--r--dbaccess/source/ui/inc/dlgattr.hxx8
-rw-r--r--dbaccess/source/ui/inc/dlgsave.hxx10
-rw-r--r--dbaccess/source/ui/inc/dlgsize.hxx10
-rw-r--r--dbaccess/source/ui/inc/dsitems.hxx2
-rw-r--r--dbaccess/source/ui/inc/dsmeta.hxx3
-rw-r--r--dbaccess/source/ui/inc/exsrcbrw.hxx3
-rw-r--r--dbaccess/source/ui/inc/formadapter.hxx78
-rw-r--r--dbaccess/source/ui/inc/imageprovider.hxx48
-rw-r--r--dbaccess/source/ui/inc/indexcollection.hxx10
-rw-r--r--dbaccess/source/ui/inc/indexdialog.hxx30
-rw-r--r--dbaccess/source/ui/inc/indexes.hxx6
-rw-r--r--dbaccess/source/ui/inc/indexfieldscontrol.hxx10
-rw-r--r--dbaccess/source/ui/inc/linkeddocuments.hxx22
-rw-r--r--dbaccess/source/ui/inc/listviewitems.hxx4
-rw-r--r--dbaccess/source/ui/inc/localresaccess.hxx6
-rw-r--r--dbaccess/source/ui/inc/makefile.mk43
-rw-r--r--dbaccess/source/ui/inc/marktree.hxx4
-rw-r--r--dbaccess/source/ui/inc/moduledbu.hxx7
-rw-r--r--dbaccess/source/ui/inc/objectnamecheck.hxx3
-rw-r--r--dbaccess/source/ui/inc/opendoccontrols.hxx8
-rw-r--r--dbaccess/source/ui/inc/paramdialog.hxx30
-rw-r--r--dbaccess/source/ui/inc/propertysetitem.hxx6
-rw-r--r--dbaccess/source/ui/inc/propertystorage.hxx3
-rw-r--r--dbaccess/source/ui/inc/querycontainerwindow.hxx14
-rw-r--r--dbaccess/source/ui/inc/querycontroller.hxx2
-rw-r--r--dbaccess/source/ui/inc/queryfilter.hxx18
-rw-r--r--dbaccess/source/ui/inc/queryorder.hxx12
-rw-r--r--dbaccess/source/ui/inc/queryview.hxx5
-rw-r--r--dbaccess/source/ui/inc/sbagrid.hrc18
-rw-r--r--dbaccess/source/ui/inc/sbagrid.hxx22
-rw-r--r--dbaccess/source/ui/inc/sbamultiplex.hxx54
-rw-r--r--[-rwxr-xr-x]dbaccess/source/ui/inc/singledoccontroller.hxx0
-rw-r--r--dbaccess/source/ui/inc/sqledit.hxx2
-rw-r--r--dbaccess/source/ui/inc/sqlmessage.hxx10
-rw-r--r--dbaccess/source/ui/inc/statusbarontroller.hxx12
-rw-r--r--dbaccess/source/ui/inc/stringlistitem.hxx8
-rw-r--r--dbaccess/source/ui/inc/tabletree.hxx16
-rw-r--r--dbaccess/source/ui/inc/textconnectionsettings.hxx3
-rw-r--r--dbaccess/source/ui/inc/toolboxcontroller.hxx14
-rw-r--r--dbaccess/source/ui/inc/undosqledit.hxx6
-rw-r--r--dbaccess/source/ui/inc/unoadmin.hxx10
-rw-r--r--dbaccess/source/ui/inc/unodatbr.hxx51
-rw-r--r--dbaccess/source/ui/inc/unosqlmessage.hxx6
-rw-r--r--dbaccess/source/ui/misc/DExport.cxx20
-rw-r--r--dbaccess/source/ui/misc/HtmlReader.cxx21
-rw-r--r--dbaccess/source/ui/misc/ModuleHelper.cxx4
-rw-r--r--dbaccess/source/ui/misc/RowSetDrop.cxx18
-rw-r--r--dbaccess/source/ui/misc/RtfReader.cxx12
-rw-r--r--dbaccess/source/ui/misc/TableCopyHelper.cxx87
-rw-r--r--dbaccess/source/ui/misc/TokenWriter.cxx128
-rw-r--r--dbaccess/source/ui/misc/ToolBoxHelper.cxx27
-rw-r--r--dbaccess/source/ui/misc/UITools.cxx299
-rw-r--r--dbaccess/source/ui/misc/UpdateHelperImpl.hxx2
-rw-r--r--dbaccess/source/ui/misc/WCPage.cxx43
-rw-r--r--dbaccess/source/ui/misc/WColumnSelect.cxx46
-rw-r--r--dbaccess/source/ui/misc/WCopyTable.cxx43
-rw-r--r--dbaccess/source/ui/misc/WExtendPages.cxx10
-rw-r--r--dbaccess/source/ui/misc/WNameMatch.cxx48
-rw-r--r--dbaccess/source/ui/misc/WTypeSelect.cxx39
-rw-r--r--dbaccess/source/ui/misc/WizardPages.src92
-rw-r--r--dbaccess/source/ui/misc/asyncmodaldialog.cxx10
-rw-r--r--dbaccess/source/ui/misc/charsets.cxx26
-rw-r--r--dbaccess/source/ui/misc/controllerframe.cxx10
-rw-r--r--dbaccess/source/ui/misc/databaseobjectview.cxx8
-rw-r--r--dbaccess/source/ui/misc/datasourceconnector.cxx46
-rw-r--r--[-rwxr-xr-x]dbaccess/source/ui/misc/dbaundomanager.cxx5
-rw-r--r--dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx2
-rw-r--r--dbaccess/source/ui/misc/dbumiscres.src2
-rw-r--r--dbaccess/source/ui/misc/defaultobjectnamecheck.cxx30
-rw-r--r--dbaccess/source/ui/misc/dsmeta.cxx7
-rw-r--r--dbaccess/source/ui/misc/imageprovider.cxx62
-rw-r--r--dbaccess/source/ui/misc/indexcollection.cxx52
-rw-r--r--dbaccess/source/ui/misc/linkeddocuments.cxx83
-rw-r--r--dbaccess/source/ui/misc/makefile.mk88
-rw-r--r--dbaccess/source/ui/misc/moduledbu.cxx10
-rw-r--r--dbaccess/source/ui/misc/propertysetitem.cxx4
-rw-r--r--dbaccess/source/ui/misc/propertystorage.cxx7
-rw-r--r--[-rwxr-xr-x]dbaccess/source/ui/misc/singledoccontroller.cxx4
-rw-r--r--dbaccess/source/ui/misc/stringlistitem.cxx4
-rw-r--r--dbaccess/source/ui/misc/uiservices.cxx15
-rw-r--r--dbaccess/source/ui/querydesign/ConnectionData.hxx63
-rw-r--r--dbaccess/source/ui/querydesign/ConnectionLine.cxx22
-rw-r--r--dbaccess/source/ui/querydesign/ConnectionLineAccess.cxx27
-rw-r--r--dbaccess/source/ui/querydesign/ConnectionLineData.cxx8
-rw-r--r--dbaccess/source/ui/querydesign/JAccess.cxx20
-rw-r--r--dbaccess/source/ui/querydesign/JoinController.cxx88
-rw-r--r--dbaccess/source/ui/querydesign/JoinDesignView.cxx46
-rw-r--r--dbaccess/source/ui/querydesign/JoinExchange.cxx13
-rw-r--r--dbaccess/source/ui/querydesign/JoinTableView.cxx78
-rw-r--r--dbaccess/source/ui/querydesign/QTableConnection.cxx20
-rw-r--r--dbaccess/source/ui/querydesign/QTableConnection.hxx9
-rw-r--r--dbaccess/source/ui/querydesign/QTableConnectionData.cxx13
-rw-r--r--dbaccess/source/ui/querydesign/QTableConnectionData.hxx14
-rw-r--r--dbaccess/source/ui/querydesign/QTableWindow.cxx63
-rw-r--r--dbaccess/source/ui/querydesign/QTableWindow.hxx10
-rw-r--r--dbaccess/source/ui/querydesign/QTableWindowData.cxx6
-rw-r--r--dbaccess/source/ui/querydesign/QTableWindowData.hxx8
-rw-r--r--dbaccess/source/ui/querydesign/QueryAddTabConnUndoAction.hxx4
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignFieldUndoAct.hxx8
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignUndoAction.hxx4
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx191
-rw-r--r--dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.cxx8
-rw-r--r--dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.hxx8
-rw-r--r--dbaccess/source/ui/querydesign/QuerySizeTabWinUndoAct.hxx6
-rw-r--r--dbaccess/source/ui/querydesign/QueryTabConnUndoAction.cxx17
-rw-r--r--dbaccess/source/ui/querydesign/QueryTabConnUndoAction.hxx4
-rw-r--r--dbaccess/source/ui/querydesign/QueryTabWinShowUndoAct.hxx4
-rw-r--r--dbaccess/source/ui/querydesign/QueryTabWinUndoAct.cxx22
-rw-r--r--dbaccess/source/ui/querydesign/QueryTabWinUndoAct.hxx4
-rw-r--r--dbaccess/source/ui/querydesign/QueryTableView.cxx95
-rw-r--r--dbaccess/source/ui/querydesign/QueryTextView.cxx32
-rw-r--r--dbaccess/source/ui/querydesign/QueryViewSwitch.cxx23
-rw-r--r--dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx179
-rw-r--r--dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx23
-rw-r--r--dbaccess/source/ui/querydesign/TableConnection.cxx14
-rw-r--r--dbaccess/source/ui/querydesign/TableConnectionData.cxx16
-rw-r--r--dbaccess/source/ui/querydesign/TableFieldDescription.cxx10
-rw-r--r--dbaccess/source/ui/querydesign/TableFieldInfo.cxx6
-rw-r--r--dbaccess/source/ui/querydesign/TableFieldInfo.hxx6
-rw-r--r--dbaccess/source/ui/querydesign/TableWindow.cxx47
-rw-r--r--dbaccess/source/ui/querydesign/TableWindowAccess.cxx35
-rw-r--r--dbaccess/source/ui/querydesign/TableWindowData.cxx7
-rw-r--r--dbaccess/source/ui/querydesign/TableWindowListBox.cxx37
-rw-r--r--dbaccess/source/ui/querydesign/TableWindowTitle.cxx42
-rw-r--r--dbaccess/source/ui/querydesign/makefile.mk89
-rw-r--r--dbaccess/source/ui/querydesign/query.src39
-rw-r--r--dbaccess/source/ui/querydesign/querycontainerwindow.cxx37
-rw-r--r--dbaccess/source/ui/querydesign/querycontroller.cxx140
-rw-r--r--dbaccess/source/ui/querydesign/querydlg.cxx34
-rw-r--r--dbaccess/source/ui/querydesign/querydlg.hxx16
-rw-r--r--dbaccess/source/ui/querydesign/querydlg.src4
-rw-r--r--dbaccess/source/ui/querydesign/queryview.cxx8
-rw-r--r--dbaccess/source/ui/relationdesign/RTableConnection.cxx13
-rw-r--r--dbaccess/source/ui/relationdesign/RTableConnection.hxx6
-rw-r--r--dbaccess/source/ui/relationdesign/RTableConnectionData.cxx10
-rw-r--r--dbaccess/source/ui/relationdesign/RTableWindow.hxx4
-rw-r--r--dbaccess/source/ui/relationdesign/RelationController.cxx27
-rw-r--r--dbaccess/source/ui/relationdesign/RelationDesignView.cxx42
-rw-r--r--dbaccess/source/ui/relationdesign/RelationTableView.cxx29
-rw-r--r--dbaccess/source/ui/relationdesign/makefile.mk58
-rw-r--r--dbaccess/source/ui/relationdesign/relation.src57
-rw-r--r--dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx29
-rw-r--r--dbaccess/source/ui/tabledesign/FieldDescGenWin.hxx6
-rw-r--r--dbaccess/source/ui/tabledesign/FieldDescriptions.cxx27
-rw-r--r--dbaccess/source/ui/tabledesign/TEditControl.cxx107
-rw-r--r--dbaccess/source/ui/tabledesign/TEditControl.hxx14
-rw-r--r--dbaccess/source/ui/tabledesign/TableController.cxx48
-rw-r--r--dbaccess/source/ui/tabledesign/TableDesignControl.cxx25
-rw-r--r--dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx11
-rw-r--r--dbaccess/source/ui/tabledesign/TableDesignView.cxx29
-rw-r--r--dbaccess/source/ui/tabledesign/TableFieldControl.cxx29
-rw-r--r--dbaccess/source/ui/tabledesign/TableFieldControl.hxx4
-rw-r--r--dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx25
-rw-r--r--dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx10
-rw-r--r--dbaccess/source/ui/tabledesign/TableRow.cxx12
-rw-r--r--dbaccess/source/ui/tabledesign/TableRowExchange.cxx17
-rw-r--r--dbaccess/source/ui/tabledesign/TableUndo.cxx23
-rw-r--r--dbaccess/source/ui/tabledesign/TableUndo.hxx10
-rw-r--r--dbaccess/source/ui/tabledesign/makefile.mk65
-rw-r--r--dbaccess/source/ui/tabledesign/table.src115
-rw-r--r--dbaccess/source/ui/uno/AdabasSettingsDlg.cxx8
-rw-r--r--dbaccess/source/ui/uno/AdabasSettingsDlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx3
-rw-r--r--dbaccess/source/ui/uno/ColumnControl.cxx15
-rw-r--r--dbaccess/source/ui/uno/ColumnControl.hxx7
-rw-r--r--dbaccess/source/ui/uno/ColumnModel.cxx24
-rw-r--r--dbaccess/source/ui/uno/ColumnModel.hxx25
-rw-r--r--dbaccess/source/ui/uno/ColumnPeer.cxx23
-rw-r--r--dbaccess/source/ui/uno/ColumnPeer.hxx10
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlg.cxx8
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx18
-rw-r--r--dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx2
-rw-r--r--dbaccess/source/ui/uno/TableFilterDlg.cxx8
-rw-r--r--dbaccess/source/ui/uno/TableFilterDlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/UserSettingsDlg.cxx8
-rw-r--r--dbaccess/source/ui/uno/UserSettingsDlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/admindlg.cxx8
-rw-r--r--dbaccess/source/ui/uno/admindlg.hxx2
-rw-r--r--dbaccess/source/ui/uno/composerdialogs.cxx26
-rw-r--r--dbaccess/source/ui/uno/composerdialogs.hxx18
-rw-r--r--dbaccess/source/ui/uno/copytablewizard.cxx19
-rw-r--r--dbaccess/source/ui/uno/copytablewizard.src3
-rw-r--r--[-rwxr-xr-x]dbaccess/source/ui/uno/dbinteraction.cxx76
-rw-r--r--dbaccess/source/ui/uno/dbinteraction.hxx6
-rw-r--r--dbaccess/source/ui/uno/makefile.mk76
-rw-r--r--dbaccess/source/ui/uno/textconnectionsettings_uno.cxx2
-rw-r--r--dbaccess/source/ui/uno/unoDirectSql.cxx22
-rw-r--r--dbaccess/source/ui/uno/unoDirectSql.hxx16
-rw-r--r--dbaccess/source/ui/uno/unoadmin.cxx26
-rw-r--r--dbaccess/source/ui/uno/unosqlmessage.cxx20
-rw-r--r--dbaccess/uiconfig/dbapp/menubar/menubar.xml4
-rw-r--r--dbaccess/uiconfig/dbquery/menubar/menubar.xml4
-rw-r--r--dbaccess/uiconfig/dbrelation/menubar/menubar.xml4
-rw-r--r--dbaccess/uiconfig/dbtable/menubar/menubar.xml4
-rw-r--r--dbaccess/uiconfig/dbtdata/menubar/menubar.xml4
-rw-r--r--dbaccess/util/makefile.mk261
-rw-r--r--dbaccess/win32/source/odbcconfig/makefile.mk54
-rw-r--r--dbaccess/win32/source/odbcconfig/odbcconfig.cxx2
764 files changed, 6005 insertions, 16648 deletions
diff --git a/dbaccess/AllLangResTarget_dba.mk b/dbaccess/AllLangResTarget_dba.mk
index 116bb459dcdb..7c2d73081e73 100644
--- a/dbaccess/AllLangResTarget_dba.mk
+++ b/dbaccess/AllLangResTarget_dba.mk
@@ -1,47 +1,48 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platdbam office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS dba A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 dba more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# dba a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_AllLangResTarget_AllLangResTarget,dba))
$(eval $(call gb_AllLangResTarget_set_reslocation,dba,dbaccess))
-$(eval $(call gb_AllLangResTarget_add_srs,dba,dbaccess/dba))
+$(eval $(call gb_AllLangResTarget_add_srs,dba,\
+ dbaccess/dba \
+))
$(eval $(call gb_SrsTarget_SrsTarget,dbaccess/dba))
$(eval $(call gb_SrsTarget_set_include,dbaccess/dba,\
- $$(INCLUDE) \
- -I$(OUTDIR)/inc \
- -I$(SRCDIR)/dbaccess/source/core/inc \
- -I$(SRCDIR)/dbaccess/inc \
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/core/inc) \
+ -I$(OUTDIR)/inc \
))
$(eval $(call gb_SrsTarget_add_files,dbaccess/dba,\
- dbaccess/source/core/resource/strings.src \
+ dbaccess/source/core/resource/strings.src \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/AllLangResTarget_dbmm.mk b/dbaccess/AllLangResTarget_dbmm.mk
index 0b4ae9712795..6c233d015dea 100644
--- a/dbaccess/AllLangResTarget_dbmm.mk
+++ b/dbaccess/AllLangResTarget_dbmm.mk
@@ -1,47 +1,47 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_AllLangResTarget_AllLangResTarget,dbmm))
$(eval $(call gb_AllLangResTarget_set_reslocation,dbmm,dbaccess))
-$(eval $(call gb_AllLangResTarget_add_srs,dbmm,dbaccess/dbmm))
+$(eval $(call gb_AllLangResTarget_add_srs,dbmm,\
+ dbaccess/dbmm \
+))
$(eval $(call gb_SrsTarget_SrsTarget,dbaccess/dbmm))
$(eval $(call gb_SrsTarget_set_include,dbaccess/dbmm,\
- $$(INCLUDE) \
- -I$(OUTDIR)/inc \
- -I$(SRCDIR)/dbaccess/source/ext/macromigration \
- -I$(SRCDIR)/dbaccess/inc \
+ $$(INCLUDE) \
+ -I$(OUTDIR)/inc \
))
$(eval $(call gb_SrsTarget_add_files,dbaccess/dbmm,\
- dbaccess/source/ext/macromigration/macromigration.src \
+ dbaccess/source/ext/macromigration/macromigration.src \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/AllLangResTarget_dbu.mk b/dbaccess/AllLangResTarget_dbu.mk
new file mode 100644
index 000000000000..fc7fbe1b8fdb
--- /dev/null
+++ b/dbaccess/AllLangResTarget_dbu.mk
@@ -0,0 +1,95 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_AllLangResTarget_AllLangResTarget,dbu))
+
+$(eval $(call gb_AllLangResTarget_set_reslocation,dbu,dbaccess))
+
+$(eval $(call gb_AllLangResTarget_add_srs,dbu,\
+ dbaccess/dbu \
+))
+
+$(eval $(call gb_SrsTarget_SrsTarget,dbaccess/dbu))
+
+$(eval $(call gb_SrsTarget_set_include,dbaccess/dbu,\
+ $$(INCLUDE) \
+ -I$(WORKDIR)/inc/dbaccess \
+ -I$(realpath $(SRCDIR)/dbaccess/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/ui/inc) \
+))
+
+$(eval $(call gb_SrsTarget_add_files,dbaccess/dbu,\
+ dbaccess/source/ui/app/app.src \
+ dbaccess/source/ui/browser/sbabrw.src \
+ dbaccess/source/ui/browser/sbagrid.src \
+ dbaccess/source/ui/control/TableGrantCtrl.src \
+ dbaccess/source/ui/control/tabletree.src \
+ dbaccess/source/ui/control/undosqledit.src \
+ dbaccess/source/ui/dlg/AdabasStat.src \
+ dbaccess/source/ui/dlg/admincontrols.src \
+ dbaccess/source/ui/dlg/adtabdlg.src \
+ dbaccess/source/ui/dlg/advancedsettings.src \
+ dbaccess/source/ui/dlg/AutoControls.src \
+ dbaccess/source/ui/dlg/CollectionView.src \
+ dbaccess/source/ui/dlg/ConnectionPage.src \
+ dbaccess/source/ui/dlg/dbadmin2.src \
+ dbaccess/source/ui/dlg/dbadminsetup.src \
+ dbaccess/source/ui/dlg/dbadmin.src \
+ dbaccess/source/ui/dlg/dbfindex.src \
+ dbaccess/source/ui/dlg/directsql.src \
+ dbaccess/source/ui/dlg/dlgattr.src \
+ dbaccess/source/ui/dlg/dlgsave.src \
+ dbaccess/source/ui/dlg/dlgsize.src \
+ dbaccess/source/ui/dlg/dsselect.src \
+ dbaccess/source/ui/dlg/indexdialog.src \
+ dbaccess/source/ui/dlg/paramdialog.src \
+ dbaccess/source/ui/dlg/queryfilter.src \
+ dbaccess/source/ui/dlg/queryorder.src \
+ dbaccess/source/ui/dlg/RelationDlg.src \
+ dbaccess/source/ui/dlg/sqlmessage.src \
+ dbaccess/source/ui/dlg/textconnectionsettings.src \
+ dbaccess/source/ui/dlg/UserAdminDlg.src \
+ dbaccess/source/ui/dlg/UserAdmin.src \
+ dbaccess/source/ui/imagelists/dbimagelists.src \
+ dbaccess/source/ui/misc/dbumiscres.src \
+ dbaccess/source/ui/misc/WizardPages.src \
+ dbaccess/source/ui/querydesign/querydlg.src \
+ dbaccess/source/ui/querydesign/query.src \
+ dbaccess/source/ui/relationdesign/relation.src \
+ dbaccess/source/ui/tabledesign/table.src \
+ dbaccess/source/ui/uno/copytablewizard.src \
+ dbaccess/source/ui/uno/dbinteraction.src \
+))
+
+$(eval $(call gb_SrsTarget_add_templates,dbaccess/dbu,\
+ dbaccess/source/ui/dlg/AutoControls_tmpl.hrc \
+ dbaccess/source/ui/inc/toolbox_tmpl.hrc \
+))
+
+$(call gb_SrsTarget_get_target,dbaccess/dbu) :| $(OUTDIR)/inc/svx/globlmn.hrc
+
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/AllLangResTarget_sdbt.mk b/dbaccess/AllLangResTarget_sdbt.mk
index 633c87f0826e..20ba240f1dc5 100644
--- a/dbaccess/AllLangResTarget_sdbt.mk
+++ b/dbaccess/AllLangResTarget_sdbt.mk
@@ -1,47 +1,50 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_AllLangResTarget_AllLangResTarget,sdbt))
$(eval $(call gb_AllLangResTarget_set_reslocation,sdbt,dbaccess))
-$(eval $(call gb_AllLangResTarget_add_srs,sdbt,dbaccess/sdbt))
+$(eval $(call gb_AllLangResTarget_add_srs,sdbt,\
+ dbaccess/sdbt \
+))
$(eval $(call gb_SrsTarget_SrsTarget,dbaccess/sdbt))
$(eval $(call gb_SrsTarget_set_include,dbaccess/sdbt,\
- $$(INCLUDE) \
- -I$(OUTDIR)/inc \
- -I$(SRCDIR)/dbaccess/source/sdbtools/inc \
- -I$(SRCDIR)/dbaccess/inc \
+ $$(INCLUDE) \
+ -I$(WORKDIR)/inc/dbaccess \
+ -I$(realpath $(SRCDIR)/dbaccess/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/sdbtools/inc) \
+ -I$(OUTDIR)/inc \
))
$(eval $(call gb_SrsTarget_add_files,dbaccess/sdbt,\
- dbaccess/source/sdbtools/resource/sdbt_strings.src \
+ dbaccess/source/sdbtools/resource/sdbt_strings.src \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Executable_odbcconfig.mk b/dbaccess/Executable_odbcconfig.mk
index c84c2c4c0079..9afc9ac40c5a 100644
--- a/dbaccess/Executable_odbcconfig.mk
+++ b/dbaccess/Executable_odbcconfig.mk
@@ -1,55 +1,54 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# OpenOffice.org - a multi-platform office productivity suite
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# This file is part of OpenOffice.org.
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# Major Contributor(s):
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
+# For minor contributions see the git repository.
#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Executable_Executable,odbcconfig))
-$(eval $(call gb_Executable_set_targettype_gui,odbcconfig,YES))
+$(eval $(call gb_Executable_add_precompiled_header,odbcconfig,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaccess))
$(eval $(call gb_Executable_set_include,odbcconfig,\
- $$(INCLUDE) \
- -I$(WORKDIR)/inc/ \
- -I$(OUTDIR)/inc/ \
- -I$(SRCDIR)/dbaccess/inc \
- -I$(SRCDIR)/dbaccess/inc/dbaccess \
- -I$(SRCDIR)/dbaccess/inc/pch \
- -I$(OUTDIR)/inc/offuh \
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc/pch) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_Executable_add_linked_libs,odbcconfig,\
+ $(gb_STDLIBS) \
))
+ifeq ($(OS),WNT)
$(eval $(call gb_Executable_add_linked_libs,odbcconfig,\
- sal \
- stl \
- tl \
- vcl \
- vos3 \
- $(gb_Library_PLAINLIBS_NONE) \
+ user32 \
))
+endif
$(eval $(call gb_Executable_add_exception_objects,odbcconfig,\
- dbaccess/win32/source/odbcconfig/odbcconfig \
+ dbaccess/win32/source/odbcconfig/odbcconfig \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/JunitTest_dbaccess_unoapi.mk b/dbaccess/JunitTest_dbaccess_unoapi.mk
index 24bbc88c26ab..f51d382087a2 100644
--- a/dbaccess/JunitTest_dbaccess_unoapi.mk
+++ b/dbaccess/JunitTest_dbaccess_unoapi.mk
@@ -1,46 +1,45 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# Bjoern Michaelsen, Canonical Ltd. <bjoern.michaelsen@canonical.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
-$(eval $(call gb_JunitTest_JunitTest,dbaccess_unoapi,SRCDIR))
+$(eval $(call gb_JunitTest_JunitTest,dbaccess_unoapi))
$(eval $(call gb_JunitTest_set_defs,dbaccess_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.ini=$(SRCDIR)/dbaccess/qa/unoapi/dbaccess.props \
- -Dorg.openoffice.test.arg.tdoc=$(SRCDIR)/dbaccess/qa/unoapi/testdocuments \
+ $$(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_add_jars,dbaccess_unoapi,\
- $(OUTDIR)/bin/OOoRunner.jar \
- $(OUTDIR)/bin/ridl.jar \
- $(OUTDIR)/bin/test.jar \
- $(OUTDIR)/bin/unoil.jar \
- $(OUTDIR)/bin/jurt.jar \
+ $(OUTDIR)/bin/OOoRunner.jar \
+ $(OUTDIR)/bin/ridl.jar \
+ $(OUTDIR)/bin/test.jar \
+ $(OUTDIR)/bin/unoil.jar \
+ $(OUTDIR)/bin/jurt.jar \
))
$(eval $(call gb_JunitTest_add_sourcefiles,dbaccess_unoapi,\
@@ -48,7 +47,7 @@ $(eval $(call gb_JunitTest_add_sourcefiles,dbaccess_unoapi,\
))
$(eval $(call gb_JunitTest_add_classes,dbaccess_unoapi,\
- org.openoffice.dbaccess.qa.unoapi.Test \
+ org.openoffice.test.UnoApiTest \
))
# vim: set noet sw=4 ts=4:
diff --git a/dbaccess/Library_adabasui.mk b/dbaccess/Library_adabasui.mk
deleted file mode 100644
index 16cefaafafd5..000000000000
--- a/dbaccess/Library_adabasui.mk
+++ /dev/null
@@ -1,71 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-$(eval $(call gb_Library_Library,adabasui))
-$(eval $(call gb_Library_add_package_headers,adabasui,dbaccess_inc))
-
-$(eval $(call gb_Library_set_componentfile,adabasui,dbaccess/source/ext/adabas/adabasui))
-
-$(eval $(call gb_Library_set_include,adabasui,\
- -I$(SRCDIR)/dbaccess/inc \
- -I$(SRCDIR)/dbaccess/source/ext/adabas \
- $$(SOLARINC) \
- -I$(OUTDIR)/inc/offuh \
-))
-
-$(eval $(call gb_Library_add_defs,adabasui,\
- -DCOMPMOD_NAMESPACE=adabasui \
-))
-
-$(eval $(call gb_Library_add_linked_libs,adabasui,\
- tl \
- svt \
- svl \
- cppuhelper \
- cppu \
- comphelper \
- utl \
- ucbhelper \
- vcl \
- sal \
- stl \
- sfx \
- tk \
- dbtools \
- $(gb_STDLIBS) \
-))
-
-$(eval $(call gb_Library_add_exception_objects,adabasui,\
- dbaccess/source/ext/adabas/ASqlNameEdit \
- dbaccess/source/ext/adabas/AdabasNewDb \
- dbaccess/source/ext/adabas/ANewDb \
- dbaccess/source/ext/adabas/Aservices \
- dbaccess/source/ext/adabas/adabasuistrings \
- dbaccess/source/ext/adabas/Acomponentmodule \
-))
-
-# vim: set noet sw=4 ts=4:
diff --git a/dbaccess/Library_dba.mk b/dbaccess/Library_dba.mk
index dd6d101f8df1..368eaa192e4a 100644
--- a/dbaccess/Library_dba.mk
+++ b/dbaccess/Library_dba.mk
@@ -1,151 +1,155 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Library_Library,dba))
-$(eval $(call gb_Library_add_package_headers,dba,dbaccess_inc))
-$(eval $(call gb_Library_add_precompiled_header,dba,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaccess))
-$(eval $(call gb_Library_set_componentfile,dba,dbaccess/util/dba))
+$(eval $(call gb_Library_add_package_headers,dba,\
+ dbaccess_inc \
+))
+
+$(eval $(call gb_Library_add_precompiled_header,dba,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaccess))
$(eval $(call gb_Library_set_include,dba,\
- -I$(SRCDIR)/dbaccess/inc \
- -I$(SRCDIR)/dbaccess/source/core/inc \
- -I$(SRCDIR)/dbaccess/source/inc \
- -I$(SRCDIR)/dbaccess/inc/pch \
- $$(SOLARINC) \
- -I$(OUTDIR)/inc/offuh \
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc/pch) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/core/inc) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
))
$(eval $(call gb_Library_add_defs,dba,\
- -DOOO_DLLIMPLEMENTATION_DBA \
+ -DOOO_DLLIMPLEMENTATION_DBA \
))
$(eval $(call gb_Library_add_linked_libs,dba,\
- sb \
- tl \
- svt \
- svl \
- cppuhelper \
- cppu \
- comphelper \
- dbtools \
- utl \
- vcl \
- sal \
- stl \
- i18nisolang1 \
- ucbhelper \
- sfx \
- salhelper \
- xo \
- fwe \
+ comphelper \
+ cppu \
+ cppuhelper \
+ dbtools \
+ fwe \
+ i18nisolang1 \
+ sal \
+ salhelper \
+ sb \
+ sfx \
+ svl \
+ svt \
+ tl \
+ ucbhelper \
+ utl \
+ vcl \
+ xo \
$(gb_STDLIBS) \
))
+$(eval $(call gb_Library_set_componentfile,dba,dbaccess/util/dba))
+
$(eval $(call gb_Library_add_exception_objects,dba,\
- dbaccess/source/core/api/querydescriptor \
- dbaccess/source/core/api/FilteredContainer \
- dbaccess/source/core/api/TableDeco \
- dbaccess/source/core/api/RowSetCacheIterator \
- dbaccess/source/core/api/RowSet \
- dbaccess/source/core/api/column \
- dbaccess/source/core/api/RowSetBase \
- dbaccess/source/core/api/CRowSetDataColumn \
- dbaccess/source/core/api/CRowSetColumn \
- dbaccess/source/core/api/querycomposer \
- dbaccess/source/core/api/CIndexes \
- dbaccess/source/core/api/BookmarkSet \
- dbaccess/source/core/api/KeySet \
- dbaccess/source/core/api/StaticSet \
- dbaccess/source/core/api/CacheSet \
- dbaccess/source/core/api/RowSetCache \
- dbaccess/source/core/api/definitioncolumn \
- dbaccess/source/core/api/resultcolumn \
- dbaccess/source/core/api/datacolumn \
- dbaccess/source/core/api/resultset \
- dbaccess/source/core/api/statement \
- dbaccess/source/core/api/preparedstatement \
- dbaccess/source/core/api/callablestatement \
- dbaccess/source/core/api/query \
- dbaccess/source/core/api/querycontainer \
- dbaccess/source/core/api/table \
- dbaccess/source/core/api/viewcontainer \
- dbaccess/source/core/api/tablecontainer \
- dbaccess/source/core/api/SingleSelectQueryComposer \
- dbaccess/source/core/api/HelperCollections \
- dbaccess/source/core/api/datasettings \
- dbaccess/source/core/api/View \
- dbaccess/source/core/api/WrappedResultSet \
- dbaccess/source/core/api/OptimisticSet \
- dbaccess/source/core/api/PrivateRow \
- dbaccess/source/core/api/columnsettings \
- dbaccess/source/core/dataaccess/SharedConnection \
- dbaccess/source/core/dataaccess/ContentHelper \
- dbaccess/source/core/dataaccess/bookmarkcontainer \
- dbaccess/source/core/dataaccess/definitioncontainer \
- dbaccess/source/core/dataaccess/commanddefinition \
- dbaccess/source/core/dataaccess/documentcontainer \
- dbaccess/source/core/dataaccess/commandcontainer \
- dbaccess/source/core/dataaccess/documentdefinition \
- dbaccess/source/core/dataaccess/ComponentDefinition \
- dbaccess/source/core/dataaccess/databasecontext \
- dbaccess/source/core/dataaccess/connection \
- dbaccess/source/core/dataaccess/datasource \
- dbaccess/source/core/dataaccess/databaseregistrations \
- dbaccess/source/core/dataaccess/intercept \
- dbaccess/source/core/dataaccess/myucp_datasupplier \
- dbaccess/source/core/dataaccess/myucp_resultset \
- dbaccess/source/core/dataaccess/databasedocument \
- dbaccess/source/core/dataaccess/dataaccessdescriptor \
- dbaccess/source/core/dataaccess/ModelImpl \
- dbaccess/source/core/dataaccess/documentevents \
- dbaccess/source/core/dataaccess/documenteventexecutor \
- dbaccess/source/core/dataaccess/documenteventnotifier \
- dbaccess/source/core/misc/sdbcoretools \
- dbaccess/source/core/misc/services \
- dbaccess/source/core/misc/PropertyForward \
- dbaccess/source/core/misc/ContainerMediator \
- dbaccess/source/core/misc/userinformation \
- dbaccess/source/core/misc/ContainerListener \
- dbaccess/source/core/misc/objectnameapproval \
- dbaccess/source/core/misc/DatabaseDataProvider \
- dbaccess/source/core/misc/module_dba \
- dbaccess/source/core/misc/dsntypes \
- dbaccess/source/core/misc/veto \
- dbaccess/source/core/misc/apitools \
- dbaccess/source/core/misc/dbastrings \
- dbaccess/source/core/recovery/dbdocrecovery \
- dbaccess/source/core/recovery/subcomponentloader \
- dbaccess/source/core/recovery/storagestream \
- dbaccess/source/core/recovery/storagexmlstream \
- dbaccess/source/core/recovery/storagetextstream \
- dbaccess/source/core/recovery/subcomponentrecovery \
- dbaccess/source/core/recovery/settingsimport \
- dbaccess/source/core/resource/core_resource \
+ dbaccess/source/core/api/BookmarkSet \
+ dbaccess/source/core/api/CacheSet \
+ dbaccess/source/core/api/callablestatement \
+ dbaccess/source/core/api/CIndexes \
+ dbaccess/source/core/api/column \
+ dbaccess/source/core/api/columnsettings \
+ dbaccess/source/core/api/CRowSetColumn \
+ dbaccess/source/core/api/CRowSetDataColumn \
+ dbaccess/source/core/api/datacolumn \
+ dbaccess/source/core/api/datasettings \
+ dbaccess/source/core/api/definitioncolumn \
+ dbaccess/source/core/api/FilteredContainer \
+ dbaccess/source/core/api/HelperCollections \
+ dbaccess/source/core/api/KeySet \
+ dbaccess/source/core/api/OptimisticSet \
+ dbaccess/source/core/api/preparedstatement \
+ dbaccess/source/core/api/PrivateRow \
+ dbaccess/source/core/api/query \
+ dbaccess/source/core/api/querycomposer \
+ dbaccess/source/core/api/querycontainer \
+ dbaccess/source/core/api/querydescriptor \
+ dbaccess/source/core/api/resultcolumn \
+ dbaccess/source/core/api/resultset \
+ dbaccess/source/core/api/RowSet \
+ dbaccess/source/core/api/RowSetBase \
+ dbaccess/source/core/api/RowSetCache \
+ dbaccess/source/core/api/RowSetCacheIterator \
+ dbaccess/source/core/api/SingleSelectQueryComposer \
+ dbaccess/source/core/api/statement \
+ dbaccess/source/core/api/StaticSet \
+ dbaccess/source/core/api/table \
+ dbaccess/source/core/api/tablecontainer \
+ dbaccess/source/core/api/TableDeco \
+ dbaccess/source/core/api/View \
+ dbaccess/source/core/api/viewcontainer \
+ dbaccess/source/core/api/WrappedResultSet \
+ dbaccess/source/core/dataaccess/bookmarkcontainer \
+ dbaccess/source/core/dataaccess/commandcontainer \
+ dbaccess/source/core/dataaccess/commanddefinition \
+ dbaccess/source/core/dataaccess/ComponentDefinition \
+ dbaccess/source/core/dataaccess/connection \
+ dbaccess/source/core/dataaccess/ContentHelper \
+ dbaccess/source/core/dataaccess/dataaccessdescriptor \
+ dbaccess/source/core/dataaccess/databasecontext \
+ dbaccess/source/core/dataaccess/databasedocument \
+ dbaccess/source/core/dataaccess/databaseregistrations \
+ dbaccess/source/core/dataaccess/datasource \
+ dbaccess/source/core/dataaccess/definitioncontainer \
+ dbaccess/source/core/dataaccess/documentcontainer \
+ dbaccess/source/core/dataaccess/documentdefinition \
+ dbaccess/source/core/dataaccess/documenteventexecutor \
+ dbaccess/source/core/dataaccess/documenteventnotifier \
+ dbaccess/source/core/dataaccess/documentevents \
+ dbaccess/source/core/dataaccess/intercept \
+ dbaccess/source/core/dataaccess/ModelImpl \
+ dbaccess/source/core/dataaccess/myucp_datasupplier \
+ dbaccess/source/core/dataaccess/myucp_resultset \
+ dbaccess/source/core/dataaccess/SharedConnection \
+ dbaccess/source/core/misc/apitools \
+ dbaccess/source/core/misc/ContainerListener \
+ dbaccess/source/core/misc/ContainerMediator \
+ dbaccess/source/core/misc/DatabaseDataProvider \
+ dbaccess/source/core/misc/dbastrings \
+ dbaccess/source/core/misc/dsntypes \
+ dbaccess/source/core/misc/module_dba \
+ dbaccess/source/core/misc/objectnameapproval \
+ dbaccess/source/core/misc/PropertyForward \
+ dbaccess/source/core/misc/sdbcoretools \
+ dbaccess/source/core/misc/services \
+ dbaccess/source/core/misc/userinformation \
+ dbaccess/source/core/misc/veto \
+ dbaccess/source/core/recovery/dbdocrecovery \
+ dbaccess/source/core/recovery/settingsimport \
+ dbaccess/source/core/recovery/storagestream \
+ dbaccess/source/core/recovery/storagetextstream \
+ dbaccess/source/core/recovery/storagexmlstream \
+ dbaccess/source/core/recovery/subcomponentloader \
+ dbaccess/source/core/recovery/subcomponentrecovery \
+ dbaccess/source/core/resource/core_resource \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Library_dbaxml.mk b/dbaccess/Library_dbaxml.mk
index 2f16d684d3f7..e0a190898c24 100644
--- a/dbaccess/Library_dbaxml.mk
+++ b/dbaccess/Library_dbaxml.mk
@@ -1,95 +1,93 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Library_Library,dbaxml))
-$(eval $(call gb_Library_add_precompiled_header,dbaxml,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaxml))
-$(eval $(call gb_Library_set_componentfile,dbaxml,dbaccess/source/filter/xml/dbaxml))
+$(eval $(call gb_Library_add_precompiled_header,dbaxml,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaccess))
$(eval $(call gb_Library_set_include,dbaxml,\
- -I$(SRCDIR)/dbaccess/inc \
- -I$(SRCDIR)/dbaccess/source/filter/xml \
- -I$(SRCDIR)/dbaccess/source/inc \
- -I$(SRCDIR)/dbaccess/inc/pch \
- $$(SOLARINC) \
- -I$(OUTDIR)/inc/offuh \
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc/pch) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/inc) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
))
$(eval $(call gb_Library_add_linked_libs,dbaxml,\
- tl \
- svl \
- cppuhelper \
- cppu \
- comphelper \
- utl \
- vcl \
- sal \
- sfx \
- dbtools \
- xo \
- sot \
- tk \
- dba \
- stl \
+ comphelper \
+ cppu \
+ cppuhelper \
+ dba \
+ dbtools \
+ sal \
+ sfx \
+ svl \
+ tk \
+ tl \
+ utl \
+ vcl \
+ xo \
$(gb_STDLIBS) \
))
+$(eval $(call gb_Library_set_componentfile,dbaxml,dbaccess/source/filter/xml/dbaxml))
+
$(eval $(call gb_Library_add_exception_objects,dbaxml,\
- dbaccess/source/filter/xml/xmlfilter \
- dbaccess/source/filter/xml/dbloader2 \
- dbaccess/source/filter/xml/xmlDatabase \
- dbaccess/source/filter/xml/xmlDataSource \
- dbaccess/source/filter/xml/xmlTableFilterPattern \
- dbaccess/source/filter/xml/xmlTableFilterList \
- dbaccess/source/filter/xml/xmlDataSourceInfo \
- dbaccess/source/filter/xml/xmlDataSourceSetting \
- dbaccess/source/filter/xml/xmlDataSourceSettings \
- dbaccess/source/filter/xml/xmlDocuments \
- dbaccess/source/filter/xml/xmlComponent \
- dbaccess/source/filter/xml/xmlHierarchyCollection \
- dbaccess/source/filter/xml/xmlLogin \
- dbaccess/source/filter/xml/xmlExport \
- dbaccess/source/filter/xml/xmlQuery \
- dbaccess/source/filter/xml/xmlTable \
- dbaccess/source/filter/xml/xmlColumn \
- dbaccess/source/filter/xml/xmlStyleImport \
- dbaccess/source/filter/xml/xmlHelper \
- dbaccess/source/filter/xml/xmlAutoStyle \
- dbaccess/source/filter/xml/xmlConnectionData \
- dbaccess/source/filter/xml/xmlDatabaseDescription \
- dbaccess/source/filter/xml/xmlFileBasedDatabase \
- dbaccess/source/filter/xml/xmlServerDatabase \
- dbaccess/source/filter/xml/xmlConnectionResource \
- dbaccess/source/filter/xml/xmlservices \
+ dbaccess/source/filter/xml/dbloader2 \
+ dbaccess/source/filter/xml/xmlAutoStyle \
+ dbaccess/source/filter/xml/xmlColumn \
+ dbaccess/source/filter/xml/xmlComponent \
+ dbaccess/source/filter/xml/xmlConnectionData \
+ dbaccess/source/filter/xml/xmlConnectionResource \
+ dbaccess/source/filter/xml/xmlDatabase \
+ dbaccess/source/filter/xml/xmlDatabaseDescription \
+ dbaccess/source/filter/xml/xmlDataSource \
+ dbaccess/source/filter/xml/xmlDataSourceInfo \
+ dbaccess/source/filter/xml/xmlDataSourceSetting \
+ dbaccess/source/filter/xml/xmlDataSourceSettings \
+ dbaccess/source/filter/xml/xmlDocuments \
+ dbaccess/source/filter/xml/xmlExport \
+ dbaccess/source/filter/xml/xmlFileBasedDatabase \
+ dbaccess/source/filter/xml/xmlfilter \
+ dbaccess/source/filter/xml/xmlHelper \
+ dbaccess/source/filter/xml/xmlHierarchyCollection \
+ dbaccess/source/filter/xml/xmlLogin \
+ dbaccess/source/filter/xml/xmlQuery \
+ dbaccess/source/filter/xml/xmlServerDatabase \
+ dbaccess/source/filter/xml/xmlservices \
+ dbaccess/source/filter/xml/xmlStyleImport \
+ dbaccess/source/filter/xml/xmlTable \
+ dbaccess/source/filter/xml/xmlTableFilterList \
+ dbaccess/source/filter/xml/xmlTableFilterPattern \
+ dbaccess/source/shared/flt_reghelper \
))
-$(eval $(call gb_Library_add_noexception_objects,dbaxml, \
- dbaccess/source/shared/flt_reghelper \
- dbaccess/source/shared/xmlstrings \
+$(eval $(call gb_Library_add_noexception_objects,dbaxml,\
+ dbaccess/source/shared/xmlstrings \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Library_dbmm.mk b/dbaccess/Library_dbmm.mk
index ef918f89afa8..db6b152b2d4f 100644
--- a/dbaccess/Library_dbmm.mk
+++ b/dbaccess/Library_dbmm.mk
@@ -1,74 +1,77 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Library_Library,dbmm))
-$(eval $(call gb_Library_add_package_headers,dbmm,dbaccess_inc))
-$(eval $(call gb_Library_add_precompiled_header,dbmm,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbmm))
-$(eval $(call gb_Library_set_componentfile,dbmm,dbaccess/source/ext/macromigration/dbmm))
+$(eval $(call gb_Library_add_package_headers,dbmm,\
+ dbaccess_inc \
+))
+
+$(eval $(call gb_Library_add_precompiled_header,dbmm,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaccess))
$(eval $(call gb_Library_set_include,dbmm,\
- -I$(SRCDIR)/dbaccess/inc \
- -I$(SRCDIR)/dbaccess/source/ext/macromigration \
- -I$(SRCDIR)/dbaccess/inc/pch \
- $$(SOLARINC) \
- -I$(OUTDIR)/inc/offuh \
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc/pch) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
))
$(eval $(call gb_Library_add_linked_libs,dbmm,\
- cppu \
- cppuhelper \
- comphelper \
- utl \
- tl \
- sal \
- svt \
- svl \
- vcl \
- svxcore \
- svx \
- ucbhelper \
- stl \
- xcr \
+ comphelper \
+ cppu \
+ cppuhelper \
+ sal \
+ svl \
+ svt \
+ svxcore \
+ svx \
+ tl \
+ ucbhelper \
+ utl \
+ vcl \
+ xcr \
$(gb_STDLIBS) \
))
+$(eval $(call gb_Library_set_componentfile,dbmm,dbaccess/source/ext/macromigration/dbmm))
+
$(eval $(call gb_Library_add_exception_objects,dbmm,\
- dbaccess/source/ext/macromigration/macromigrationwizard \
- dbaccess/source/ext/macromigration/macromigrationdialog \
- dbaccess/source/ext/macromigration/macromigrationpages \
- dbaccess/source/ext/macromigration/dbmm_module \
- dbaccess/source/ext/macromigration/dbmm_services \
- dbaccess/source/ext/macromigration/migrationengine \
- dbaccess/source/ext/macromigration/docinteraction \
- dbaccess/source/ext/macromigration/progresscapture \
- dbaccess/source/ext/macromigration/progressmixer \
- dbaccess/source/ext/macromigration/migrationlog \
- dbaccess/source/ext/macromigration/dbmm_types \
+ dbaccess/source/ext/macromigration/dbmm_module \
+ dbaccess/source/ext/macromigration/dbmm_services \
+ dbaccess/source/ext/macromigration/dbmm_types \
+ dbaccess/source/ext/macromigration/docinteraction \
+ dbaccess/source/ext/macromigration/macromigrationdialog \
+ dbaccess/source/ext/macromigration/macromigrationpages \
+ dbaccess/source/ext/macromigration/macromigrationwizard \
+ dbaccess/source/ext/macromigration/migrationengine \
+ dbaccess/source/ext/macromigration/migrationlog \
+ dbaccess/source/ext/macromigration/progresscapture \
+ dbaccess/source/ext/macromigration/progressmixer \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Library_dbu.mk b/dbaccess/Library_dbu.mk
new file mode 100644
index 000000000000..7f8c6db47b3c
--- /dev/null
+++ b/dbaccess/Library_dbu.mk
@@ -0,0 +1,321 @@
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
+#
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
+#
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
+#
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
+#
+# Major Contributor(s):
+#
+# For minor contributions see the git repository.
+#
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
+
+$(eval $(call gb_Library_Library,dbu))
+
+$(eval $(call gb_Library_add_precompiled_header,dbu,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaccess))
+
+$(eval $(call gb_Library_set_include,dbu,\
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc/pch) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/ui/inc) \
+ -I$(WORKDIR)/inc/dbaccess \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
+))
+
+$(eval $(call gb_Library_set_defs,dbu,\
+ $$(DEFS) \
+ -DDBACCESS_DLLIMPLEMENTATION \
+ $(if $(filter YES,$(SYSTEM_ODBC_HEADERS)),-DSYSTEM_ODBC_HEADERS) \
+))
+
+ifeq (,$(strip $(PROF_EDITION)))
+$(eval $(call gb_Library_set_defs,dbu,\
+ $$(DEFS) \
+ -DWINDOWS_VISTA_PSDK \
+))
+endif
+
+ifeq ($(GUI)$(COM),WNTGCC) # for adoint.h
+$(eval $(call gb_Library_set_cflags,dbu,\
+ $$(CFLAGS) \
+ -fpermissive \
+))
+endif
+
+$(eval $(call gb_Library_add_linked_libs,dbu,\
+ comphelper \
+ cppu \
+ cppuhelper \
+ dba \
+ dbtools \
+ editeng \
+ fwe \
+ sal \
+ salhelper \
+ sfx \
+ sot \
+ svl \
+ svt \
+ svxcore \
+ svx \
+ tk \
+ tl \
+ ucbhelper \
+ utl \
+ vcl \
+ $(gb_STDLIBS) \
+))
+
+ifeq ($(GUI),WNT)
+$(eval $(call gb_Library_add_linked_libs,dbu,\
+ ole32 \
+ oleaut32 \
+ uuid \
+))
+endif
+
+$(eval $(call gb_Library_set_componentfile,dbu,dbaccess/util/dbu))
+
+$(eval $(call gb_Library_add_exception_objects,dbu,\
+ dbaccess/source/shared/dbu_reghelper \
+ dbaccess/source/ui/app/AppController \
+ dbaccess/source/ui/app/AppControllerDnD \
+ dbaccess/source/ui/app/AppControllerGen \
+ dbaccess/source/ui/app/AppDetailPageHelper \
+ dbaccess/source/ui/app/AppDetailView \
+ dbaccess/source/ui/app/AppIconControl \
+ dbaccess/source/ui/app/AppSwapWindow \
+ dbaccess/source/ui/app/AppTitleWindow \
+ dbaccess/source/ui/app/AppView \
+ dbaccess/source/ui/app/closeveto \
+ dbaccess/source/ui/app/subcomponentmanager \
+ dbaccess/source/ui/browser/AsyncronousLink \
+ dbaccess/source/ui/browser/brwctrlr \
+ dbaccess/source/ui/browser/brwview \
+ dbaccess/source/ui/browser/dataview \
+ dbaccess/source/ui/browser/dbexchange \
+ dbaccess/source/ui/browser/dbloader \
+ dbaccess/source/ui/browser/dbtreemodel \
+ dbaccess/source/ui/browser/dbtreeview \
+ dbaccess/source/ui/browser/dsbrowserDnD \
+ dbaccess/source/ui/browser/dsEntriesNoExp \
+ dbaccess/source/ui/browser/exsrcbrw \
+ dbaccess/source/ui/browser/formadapter \
+ dbaccess/source/ui/browser/genericcontroller \
+ dbaccess/source/ui/browser/sbagrid \
+ dbaccess/source/ui/browser/sbamultiplex \
+ dbaccess/source/ui/browser/unodatbr \
+ dbaccess/source/ui/control/charsetlistbox \
+ dbaccess/source/ui/control/ColumnControlWindow \
+ dbaccess/source/ui/control/curledit \
+ dbaccess/source/ui/control/dbtreelistbox \
+ dbaccess/source/ui/control/FieldDescControl \
+ dbaccess/source/ui/control/listviewitems \
+ dbaccess/source/ui/control/marktree \
+ dbaccess/source/ui/control/opendoccontrols \
+ dbaccess/source/ui/control/RelationControl \
+ dbaccess/source/ui/control/sqledit \
+ dbaccess/source/ui/control/SqlNameEdit \
+ dbaccess/source/ui/control/statusbarontroller \
+ dbaccess/source/ui/control/TableGrantCtrl \
+ dbaccess/source/ui/control/tabletree \
+ dbaccess/source/ui/control/toolboxcontroller \
+ dbaccess/source/ui/control/undosqledit \
+ dbaccess/source/ui/control/VertSplitView \
+ dbaccess/source/ui/dlg/AdabasStat \
+ dbaccess/source/ui/dlg/admincontrols \
+ dbaccess/source/ui/dlg/adminpages \
+ dbaccess/source/ui/dlg/adtabdlg \
+ dbaccess/source/ui/dlg/advancedsettings \
+ dbaccess/source/ui/dlg/CollectionView \
+ dbaccess/source/ui/dlg/ConnectionHelper \
+ dbaccess/source/ui/dlg/ConnectionPage \
+ dbaccess/source/ui/dlg/ConnectionPageSetup \
+ dbaccess/source/ui/dlg/dbadmin \
+ dbaccess/source/ui/dlg/DbAdminImpl \
+ dbaccess/source/ui/dlg/dbfindex \
+ dbaccess/source/ui/dlg/DBSetupConnectionPages \
+ dbaccess/source/ui/dlg/dbwiz \
+ dbaccess/source/ui/dlg/dbwizsetup \
+ dbaccess/source/ui/dlg/detailpages \
+ dbaccess/source/ui/dlg/directsql \
+ dbaccess/source/ui/dlg/dlgattr \
+ dbaccess/source/ui/dlg/dlgsave \
+ dbaccess/source/ui/dlg/dlgsize \
+ dbaccess/source/ui/dlg/DriverSettings \
+ dbaccess/source/ui/dlg/dsselect \
+ dbaccess/source/ui/dlg/finteraction \
+ dbaccess/source/ui/dlg/generalpage \
+ dbaccess/source/ui/dlg/indexdialog \
+ dbaccess/source/ui/dlg/indexfieldscontrol \
+ dbaccess/source/ui/dlg/odbcconfig \
+ dbaccess/source/ui/dlg/paramdialog \
+ dbaccess/source/ui/dlg/queryfilter \
+ dbaccess/source/ui/dlg/queryorder \
+ dbaccess/source/ui/dlg/RelationDlg \
+ dbaccess/source/ui/dlg/sqlmessage \
+ dbaccess/source/ui/dlg/tablespage \
+ dbaccess/source/ui/dlg/TablesSingleDlg \
+ dbaccess/source/ui/dlg/TextConnectionHelper \
+ dbaccess/source/ui/dlg/textconnectionsettings \
+ dbaccess/source/ui/dlg/UserAdmin \
+ dbaccess/source/ui/dlg/UserAdminDlg \
+ dbaccess/source/ui/misc/asyncmodaldialog \
+ dbaccess/source/ui/misc/charsets \
+ dbaccess/source/ui/misc/controllerframe \
+ dbaccess/source/ui/misc/databaseobjectview \
+ dbaccess/source/ui/misc/datasourceconnector \
+ dbaccess/source/ui/misc/dbaundomanager \
+ dbaccess/source/ui/misc/dbsubcomponentcontroller \
+ dbaccess/source/ui/misc/defaultobjectnamecheck \
+ dbaccess/source/ui/misc/DExport \
+ dbaccess/source/ui/misc/dsmeta \
+ dbaccess/source/ui/misc/HtmlReader \
+ dbaccess/source/ui/misc/imageprovider \
+ dbaccess/source/ui/misc/indexcollection \
+ dbaccess/source/ui/misc/linkeddocuments \
+ dbaccess/source/ui/misc/moduledbu \
+ dbaccess/source/ui/misc/propertysetitem \
+ dbaccess/source/ui/misc/propertystorage \
+ dbaccess/source/ui/misc/RowSetDrop \
+ dbaccess/source/ui/misc/RtfReader \
+ dbaccess/source/ui/misc/singledoccontroller \
+ dbaccess/source/ui/misc/stringlistitem \
+ dbaccess/source/ui/misc/TableCopyHelper \
+ dbaccess/source/ui/misc/TokenWriter \
+ dbaccess/source/ui/misc/ToolBoxHelper \
+ dbaccess/source/ui/misc/uiservices \
+ dbaccess/source/ui/misc/UITools \
+ dbaccess/source/ui/misc/WColumnSelect \
+ dbaccess/source/ui/misc/WCopyTable \
+ dbaccess/source/ui/misc/WCPage \
+ dbaccess/source/ui/misc/WExtendPages \
+ dbaccess/source/ui/misc/WNameMatch \
+ dbaccess/source/ui/misc/WTypeSelect \
+ dbaccess/source/ui/querydesign/ConnectionLine \
+ dbaccess/source/ui/querydesign/ConnectionLineAccess \
+ dbaccess/source/ui/querydesign/JAccess \
+ dbaccess/source/ui/querydesign/JoinController \
+ dbaccess/source/ui/querydesign/JoinDesignView \
+ dbaccess/source/ui/querydesign/JoinExchange \
+ dbaccess/source/ui/querydesign/JoinTableView \
+ dbaccess/source/ui/querydesign/QTableConnection \
+ dbaccess/source/ui/querydesign/QTableConnectionData \
+ dbaccess/source/ui/querydesign/QTableWindow \
+ dbaccess/source/ui/querydesign/QTableWindowData \
+ dbaccess/source/ui/querydesign/querycontainerwindow \
+ dbaccess/source/ui/querydesign/querycontroller \
+ dbaccess/source/ui/querydesign/QueryDesignView \
+ dbaccess/source/ui/querydesign/querydlg \
+ dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct \
+ dbaccess/source/ui/querydesign/QueryTabConnUndoAction \
+ dbaccess/source/ui/querydesign/QueryTableView \
+ dbaccess/source/ui/querydesign/QueryTabWinUndoAct \
+ dbaccess/source/ui/querydesign/QueryTextView \
+ dbaccess/source/ui/querydesign/queryview \
+ dbaccess/source/ui/querydesign/QueryViewSwitch \
+ dbaccess/source/ui/querydesign/SelectionBrowseBox \
+ dbaccess/source/ui/querydesign/TableConnection \
+ dbaccess/source/ui/querydesign/TableConnectionData \
+ dbaccess/source/ui/querydesign/TableFieldDescription \
+ dbaccess/source/ui/querydesign/TableWindow \
+ dbaccess/source/ui/querydesign/TableWindowAccess \
+ dbaccess/source/ui/querydesign/TableWindowData \
+ dbaccess/source/ui/querydesign/TableWindowListBox \
+ dbaccess/source/ui/querydesign/TableWindowTitle \
+ dbaccess/source/ui/relationdesign/RelationController \
+ dbaccess/source/ui/relationdesign/RelationDesignView \
+ dbaccess/source/ui/relationdesign/RelationTableView \
+ dbaccess/source/ui/relationdesign/RTableConnection \
+ dbaccess/source/ui/relationdesign/RTableConnectionData \
+ dbaccess/source/ui/tabledesign/FieldDescGenWin \
+ dbaccess/source/ui/tabledesign/FieldDescriptions \
+ dbaccess/source/ui/tabledesign/TableController \
+ dbaccess/source/ui/tabledesign/TableDesignControl \
+ dbaccess/source/ui/tabledesign/TableDesignHelpBar \
+ dbaccess/source/ui/tabledesign/TableDesignView \
+ dbaccess/source/ui/tabledesign/TableFieldControl \
+ dbaccess/source/ui/tabledesign/TableFieldDescWin \
+ dbaccess/source/ui/tabledesign/TableRow \
+ dbaccess/source/ui/tabledesign/TableRowExchange \
+ dbaccess/source/ui/tabledesign/TableUndo \
+ dbaccess/source/ui/tabledesign/TEditControl \
+ dbaccess/source/ui/uno/admindlg \
+ dbaccess/source/ui/uno/AdvancedSettingsDlg \
+ dbaccess/source/ui/uno/ColumnControl \
+ dbaccess/source/ui/uno/ColumnModel \
+ dbaccess/source/ui/uno/ColumnPeer \
+ dbaccess/source/ui/uno/composerdialogs \
+ dbaccess/source/ui/uno/dbinteraction \
+ dbaccess/source/ui/uno/DBTypeWizDlg \
+ dbaccess/source/ui/uno/DBTypeWizDlgSetup \
+ dbaccess/source/ui/uno/TableFilterDlg \
+ dbaccess/source/ui/uno/textconnectionsettings_uno \
+ dbaccess/source/ui/uno/unoadmin \
+ dbaccess/source/ui/uno/unoDirectSql \
+ dbaccess/source/ui/uno/unosqlmessage \
+ dbaccess/source/ui/uno/UserSettingsDlg \
+))
+
+$(eval $(call gb_Library_add_noexception_objects,dbu,\
+ dbaccess/source/shared/dbustrings \
+ dbaccess/source/ui/control/ScrollHelper \
+ dbaccess/source/ui/dlg/optionalboolitem \
+ dbaccess/source/ui/querydesign/ConnectionLineData \
+ dbaccess/source/ui/querydesign/TableFieldInfo \
+))
+
+ifeq ($(GUI),WNT)
+ifneq (,$(strip $(WINDOWS_VISTA_PSDK)))
+ifeq (,$(strip $(PROF_EDITION)))
+dbu_DISABLE_ADO := $(true)
+endif
+endif
+ifneq ($(dbu_DISABLE_ADO),$(true))
+$(eval $(call gb_Library_add_noexception_objects,dbu,\
+ dbaccess/source/ui/dlg/adodatalinks \
+))
+endif
+endif
+
+# workaround for issue http://qa.openoffice.org/issues/show_bug.cgi?id=102305 Linux specific
+ifeq ($(COM),GCC)
+$(eval $(call gb_Library_add_cxxobjects,dbu,\
+ dbaccess/source/ui/uno/copytablewizard \
+ , $(gb_LinkTarget_EXCEPTIONFLAGS) $(gb_COMPILERNOOPTFLAGS) \
+))
+else
+$(eval $(call gb_Library_add_exception_objects,dbu,\
+ dbaccess/source/ui/uno/copytablewizard \
+))
+endif
+
+$(foreach object,\
+ dbaccess/source/ui/dlg/ConnectionHelper \
+ dbaccess/source/ui/dlg/ConnectionPage \
+ dbaccess/source/ui/dlg/ConnectionPageSetup \
+ dbaccess/source/ui/dlg/DBSetupConnectionPages \
+ dbaccess/source/ui/dlg/detailpages \
+ dbaccess/source/ui/dlg/tablespage \
+ dbaccess/source/ui/dlg/TextConnectionHelper \
+ ,$(eval $(call gb_CxxObject_get_target,$(object)) : $(WORKDIR)/inc/dbaccess/AutoControls.hrc))
+
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Library_sdbt.mk b/dbaccess/Library_sdbt.mk
index cecbc00d067f..a93bc256bdc0 100644
--- a/dbaccess/Library_sdbt.mk
+++ b/dbaccess/Library_sdbt.mk
@@ -1,67 +1,72 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Library_Library,sdbt))
-$(eval $(call gb_Library_add_package_headers,sdbt,dbaccess_inc))
-$(eval $(call gb_Library_set_componentfile,sdbt,dbaccess/util/sdbt))
+$(eval $(call gb_Library_add_package_headers,sdbt,\
+ dbaccess_inc \
+))
+
+$(eval $(call gb_Library_add_precompiled_header,sdbt,$(SRCDIR)/dbaccess/inc/pch/precompiled_dbaccess))
$(eval $(call gb_Library_set_include,sdbt,\
- -I$(SRCDIR)/dbaccess/inc \
- -I$(SRCDIR)/dbaccess/source/sdbtools/inc \
- -I$(SRCDIR)/dbaccess/source/inc \
- -I$(SRCDIR)/dbaccess/inc/pch \
- $$(SOLARINC) \
- -I$(OUTDIR)/inc/offuh \
+ $$(INCLUDE) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc) \
+ -I$(realpath $(SRCDIR)/dbaccess/inc/pch) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/inc/) \
+ -I$(realpath $(SRCDIR)/dbaccess/source/sdbtools/inc) \
+ -I$(OUTDIR)/inc \
+ -I$(OUTDIR)/inc/offuh \
))
$(eval $(call gb_Library_add_linked_libs,sdbt,\
- tl \
- cppuhelper \
- cppu \
- comphelper \
- utl \
- sal \
- stl \
- dbtools \
+ comphelper \
+ cppu \
+ cppuhelper \
+ dbtools \
+ sal \
+ tl \
+ utl \
$(gb_STDLIBS) \
))
+$(eval $(call gb_Library_set_componentfile,sdbt,dbaccess/util/sdbt))
+
$(eval $(call gb_Library_add_exception_objects,sdbt,\
- dbaccess/source/sdbtools/connection/connectiontools \
- dbaccess/source/sdbtools/connection/tablename \
- dbaccess/source/sdbtools/connection/objectnames \
- dbaccess/source/sdbtools/connection/datasourcemetadata \
- dbaccess/source/sdbtools/misc/sdbt_services \
- dbaccess/source/sdbtools/misc/module_sdbt \
+ dbaccess/source/sdbtools/connection/connectiontools \
+ dbaccess/source/sdbtools/connection/datasourcemetadata \
+ dbaccess/source/sdbtools/connection/objectnames \
+ dbaccess/source/sdbtools/connection/tablename \
+ dbaccess/source/sdbtools/misc/module_sdbt \
+ dbaccess/source/sdbtools/misc/sdbt_services \
))
-$(eval $(call gb_Library_add_noexception_objects,sdbt, \
- dbaccess/source/shared/sdbtstrings \
+$(eval $(call gb_Library_add_noexception_objects,sdbt,\
+ dbaccess/source/shared/sdbtstrings \
))
-# vim: set noet sw=4 ts=4:
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Module_dbaccess.mk b/dbaccess/Module_dbaccess.mk
index 2f41e13c7e3e..51fe77bd9c43 100644
--- a/dbaccess/Module_dbaccess.mk
+++ b/dbaccess/Module_dbaccess.mk
@@ -1,58 +1,52 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# Bjoern Michaelsen, Canonical Ltd. <bjoern.michaelsen@canonical.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Module_Module,dbaccess))
$(eval $(call gb_Module_add_targets,dbaccess,\
- AllLangResTarget_adabasui \
- AllLangResTarget_dba \
- AllLangResTarget_dbmm \
- AllLangResTarget_dbui \
- AllLangResTarget_sdbt \
- Library_adabasui \
- Library_dba \
- Library_dbaxml \
- Library_dbmm \
- Library_dbui \
- Library_sdbt \
- Package_inc \
- Package_uiconfig \
- Package_xml \
-))
-
-ifeq ($(GUI),WNT)
-$(eval $(call gb_Module_add_targets,dbaccess,\
- Executable_odbcconfig \
+ $(if $(filter WNT,$(GUI)),Executable_odbcconfig) \
+ AllLangResTarget_adabasui \
+ AllLangResTarget_dba \
+ AllLangResTarget_dbmm \
+ AllLangResTarget_dbu \
+ AllLangResTarget_sdbt \
+ Library_adabasui \
+ Library_dba \
+ Library_dbaxml \
+ Library_dbmm \
+ Library_dbu \
+ Library_sdbt \
+ Package_inc \
+ Package_uiconfig \
))
-endif
$(eval $(call gb_Module_add_subsequentcheck_targets,dbaccess,\
JunitTest_dbaccess_complex \
- JunitTest_dbaccess_unoapi \
+ JunitTest_dbaccess_unoapi \
))
# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Package_inc.mk b/dbaccess/Package_inc.mk
index 753fd9c6949a..7ea77cd4b1ad 100644
--- a/dbaccess/Package_inc.mk
+++ b/dbaccess/Package_inc.mk
@@ -1,39 +1,41 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# OpenOffice.org - a multi-platform office productivity suite
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# This file is part of OpenOffice.org.
+# Major Contributor(s):
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# For minor contributions see the git repository.
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Package_Package,dbaccess_inc,$(SRCDIR)/dbaccess/inc))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/AsyncronousLink.hxx ,AsyncronousLink.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/IController.hxx ,IController.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/IReference.hxx ,IReference.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/ToolBoxHelper.hxx ,ToolBoxHelper.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/controllerframe.hxx ,controllerframe.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dataview.hxx ,dataview.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dbaundomanager.hxx ,dbaundomanager.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dbaccessdllapi.h ,dbaccessdllapi.h ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dbsubcomponentcontroller.hxx ,dbsubcomponentcontroller.hxx ))
-$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/genericcontroller.hxx ,genericcontroller.hxx ))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/AsyncronousLink.hxx,AsyncronousLink.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/IController.hxx,IController.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/IReference.hxx,IReference.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/ToolBoxHelper.hxx,ToolBoxHelper.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/controllerframe.hxx,controllerframe.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dataview.hxx,dataview.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dbaccessdllapi.h,dbaccessdllapi.h))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dbaundomanager.hxx,dbaundomanager.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/dbsubcomponentcontroller.hxx,dbsubcomponentcontroller.hxx))
+$(eval $(call gb_Package_add_file,dbaccess_inc,inc/dbaccess/genericcontroller.hxx,genericcontroller.hxx))
+
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/Package_uiconfig.mk b/dbaccess/Package_uiconfig.mk
index 5596c9d7ab56..91890f4be863 100644
--- a/dbaccess/Package_uiconfig.mk
+++ b/dbaccess/Package_uiconfig.mk
@@ -1,48 +1,50 @@
-#*************************************************************************
+# Version: MPL 1.1 / GPLv3+ / LGPLv3+
#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2011 Oracle and/or its affiliates.
+# The contents of this file are subject to the Mozilla Public License Version
+# 1.1 (the "License"); you may not use this file except in compliance with
+# the License or as specified alternatively below. You may obtain a copy of
+# the License at http://www.mozilla.org/MPL/
#
-# OpenOffice.org - a multi-platform office productivity suite
+# Software distributed under the License is distributed on an "AS IS" basis,
+# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
+# for the specific language governing rights and limitations under the
+# License.
#
-# This file is part of OpenOffice.org.
+# The Initial Developer of the Original Code is
+# David Tardon, Red Hat Inc. <dtardon@redhat.com>
+# Portions created by the Initial Developer are Copyright (C) 2010 the
+# Initial Developer. All Rights Reserved.
#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
+# Major Contributor(s):
#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
+# For minor contributions see the git repository.
#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
+# Alternatively, the contents of this file may be used under the terms of
+# either the GNU General Public License Version 3 or later (the "GPLv3+"), or
+# the GNU Lesser General Public License Version 3 or later (the "LGPLv3+"),
+# in which case the provisions of the GPLv3+ or the LGPLv3+ are applicable
+# instead of those above.
$(eval $(call gb_Package_Package,dbaccess_uiconfig,$(SRCDIR)/dbaccess/uiconfig))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/menubar/menubar.xml,dbapp/menubar/menubar.xml))
-$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbtdata/menubar/menubar.xml,dbtdata/menubar/menubar.xml))
-$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbquery/menubar/menubar.xml,dbquery/menubar/menubar.xml))
-$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbrelation/menubar/menubar.xml,dbrelation/menubar/menubar.xml))
-$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbtable/menubar/menubar.xml,dbtable/menubar/menubar.xml))
+$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/statusbar/statusbar.xml,dbapp/statusbar/statusbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/toolbar/formobjectbar.xml,dbapp/toolbar/formobjectbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/toolbar/queryobjectbar.xml,dbapp/toolbar/queryobjectbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/toolbar/reportobjectbar.xml,dbapp/toolbar/reportobjectbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/toolbar/tableobjectbar.xml,dbapp/toolbar/tableobjectbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/toolbar/toolbar.xml,dbapp/toolbar/toolbar.xml))
-$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbapp/statusbar/statusbar.xml,dbapp/statusbar/statusbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbbrowser/menubar/compat.xml,dbbrowser/menubar/compat.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbbrowser/toolbar/toolbar.xml,dbbrowser/toolbar/toolbar.xml))
-$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbtdata/toolbar/toolbar.xml,dbtdata/toolbar/toolbar.xml))
+$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbquery/menubar/menubar.xml,dbquery/menubar/menubar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbquery/toolbar/designobjectbar.xml,dbquery/toolbar/designobjectbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbquery/toolbar/sqlobjectbar.xml,dbquery/toolbar/sqlobjectbar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbquery/toolbar/toolbar.xml,dbquery/toolbar/toolbar.xml))
+$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbrelation/menubar/menubar.xml,dbrelation/menubar/menubar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbrelation/toolbar/toolbar.xml,dbrelation/toolbar/toolbar.xml))
+$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbtable/menubar/menubar.xml,dbtable/menubar/menubar.xml))
$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbtable/toolbar/toolbar.xml,dbtable/toolbar/toolbar.xml))
+$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbtdata/menubar/menubar.xml,dbtdata/menubar/menubar.xml))
+$(eval $(call gb_Package_add_file,dbaccess_uiconfig,xml/uiconfig/modules/dbtdata/toolbar/toolbar.xml,dbtdata/toolbar/toolbar.xml))
+
+# vim: set noet ts=4 sw=4:
diff --git a/dbaccess/inc/AsyncronousLink.hxx b/dbaccess/inc/AsyncronousLink.hxx
index 576f1a1a90af..3fff1f7deb20 100644
--- a/dbaccess/inc/AsyncronousLink.hxx
+++ b/dbaccess/inc/AsyncronousLink.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -69,3 +70,4 @@ namespace dbaui
}
#endif // DBAUI_ASYNCRONOUSLINK_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/IController.hxx b/dbaccess/inc/IController.hxx
index 46d5a78922f3..962782ea5e18 100644
--- a/dbaccess/inc/IController.hxx
+++ b/dbaccess/inc/IController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
#ifndef DBAUI_ICONTROLLER_HXX
#define DBAUI_ICONTROLLER_HXX
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef DBAUI_IREFERENCE_HXX
#include "IReference.hxx"
-#endif
#include "dbaccessdllapi.h"
namespace com { namespace sun { namespace star {
@@ -138,3 +133,5 @@ namespace dbaui
};
}
#endif // DBAUI_ICONTROLLER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/IReference.hxx b/dbaccess/inc/IReference.hxx
index ba78811e1e85..01534f6063e0 100644
--- a/dbaccess/inc/IReference.hxx
+++ b/dbaccess/inc/IReference.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,3 +43,4 @@ namespace dbaui
#endif // DBAUI_IREFERENCE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/ToolBoxHelper.hxx b/dbaccess/inc/ToolBoxHelper.hxx
index 0bb93681d8c6..280d523a8ca0 100644
--- a/dbaccess/inc/ToolBoxHelper.hxx
+++ b/dbaccess/inc/ToolBoxHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef DBAUI_TOOLBOXHELPER_HXX
#define DBAUI_TOOLBOXHELPER_HXX
-#ifndef _SAL_TYPES_H_
#include <sal/types.h>
-#endif
-#ifndef _LINK_HXX
#include <tools/link.hxx>
-#endif
-#ifndef _SV_GEN_HXX
#include <tools/gen.hxx>
-#endif
-#ifndef _SV_IMAGE_HXX
#include <vcl/image.hxx>
-#endif
#include "dbaccessdllapi.h"
class SvtMiscOptions;
@@ -50,7 +43,6 @@ namespace dbaui
{
class DBACCESS_DLLPUBLIC OToolBoxHelper
{
- sal_Bool m_bIsHiContrast;// true when the toolbox is in hi contrast mode
sal_Int16 m_nSymbolsSize; // shows the toolbox large or small bitmaps
ToolBox* m_pToolBox; // our toolbox (may be NULL)
public:
@@ -69,7 +61,7 @@ namespace dbaui
@param _bHiContast
<TRUE/> when in high contrast mode.
*/
- virtual ImageList getImageList(sal_Int16 _eSymbolsSize,sal_Bool _bHiContast) const = 0;
+ virtual ImageList getImageList(sal_Int16 _eSymbolsSize) const = 0;
/** only the member will be set, derived classes can overload this function and do what need to be done.
@param _pTB
@@ -79,13 +71,12 @@ namespace dbaui
*/
virtual void setToolBox(ToolBox* _pTB);
- inline ToolBox* getToolBox() const { return m_pToolBox; }
+ inline ToolBox* getToolBox() const { return m_pToolBox; }
/** checks if the toolbox needs a new imagelist.
*/
void checkImageList();
- inline sal_Bool isToolBoxHiContrast() const { return m_bIsHiContrast; }
protected:
DECL_LINK(ConfigOptionsChanged, SvtMiscOptions*);
DECL_LINK(SettingsChanged, VclWindowEvent* );
@@ -93,3 +84,4 @@ namespace dbaui
}
#endif // DBAUI_TOOLBOXHELPER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/controllerframe.hxx b/dbaccess/inc/controllerframe.hxx
index 942bdc42da64..19daaebb3d69 100644
--- a/dbaccess/inc/controllerframe.hxx
+++ b/dbaccess/inc/controllerframe.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -82,3 +83,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_CONTROLLERFRAME_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/dataview.hxx b/dbaccess/inc/dataview.hxx
index fdb99014433a..813faa4a8dd4 100644
--- a/dbaccess/inc/dataview.hxx
+++ b/dbaccess/inc/dataview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,6 +32,7 @@
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <svtools/acceleratorexecute.hxx>
+#include <sal/macros.h>
#include <vcl/fixed.hxx>
#include <memory>
@@ -90,3 +92,4 @@ namespace dbaui
}
#endif // DBAUI_DATAVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/dbaccessdllapi.h b/dbaccess/inc/dbaccessdllapi.h
index 7edac96cf07c..7365d0c4c84f 100644
--- a/dbaccess/inc/dbaccessdllapi.h
+++ b/dbaccess/inc/dbaccessdllapi.h
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,3 +42,4 @@
#endif /* INCLUDED_DBACCESSDLLAPI_H */
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/dbaundomanager.hxx b/dbaccess/inc/dbaundomanager.hxx
index 1b8627f66326..1b8627f66326 100755..100644
--- a/dbaccess/inc/dbaundomanager.hxx
+++ b/dbaccess/inc/dbaundomanager.hxx
diff --git a/dbaccess/inc/dbsubcomponentcontroller.hxx b/dbaccess/inc/dbsubcomponentcontroller.hxx
index cd93a29df321..a4d24359cebc 100644
--- a/dbaccess/inc/dbsubcomponentcontroller.hxx
+++ b/dbaccess/inc/dbsubcomponentcontroller.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -211,3 +212,4 @@ namespace dbaui
#endif // DBAUI_SUBCOMPONENTCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/genericcontroller.hxx b/dbaccess/inc/genericcontroller.hxx
index 6c47ca6f397f..3dad26798ec1 100644
--- a/dbaccess/inc/genericcontroller.hxx
+++ b/dbaccess/inc/genericcontroller.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -540,3 +541,4 @@ namespace dbaui
#endif //DBAUI_GENERICCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/makefile.mk b/dbaccess/inc/makefile.mk
deleted file mode 100644
index 5aa9bfe11018..000000000000
--- a/dbaccess/inc/makefile.mk
+++ /dev/null
@@ -1,47 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-PRJ=..
-
-PRJNAME=dbaccess
-TARGET=inc
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files --------------------------------------------------------
-# --- Targets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
-.IF "$(ENABLE_PCH)"!=""
-ALLTAR : \
- $(SLO)$/precompiled.pch \
- $(SLO)$/precompiled_ex.pch
-
-.ENDIF # "$(ENABLE_PCH)"!=""
-
diff --git a/dbaccess/inc/pch/precompiled_dbaccess.cxx b/dbaccess/inc/pch/precompiled_dbaccess.cxx
index 1ef5d4b9c7a5..0fe2c43d1189 100644
--- a/dbaccess/inc/pch/precompiled_dbaccess.cxx
+++ b/dbaccess/inc/pch/precompiled_dbaccess.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,3 +28,4 @@
#include "precompiled_dbaccess.hxx"
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/inc/pch/precompiled_dbaccess.hxx b/dbaccess/inc/pch/precompiled_dbaccess.hxx
index 099adaf03988..daa7a324ab60 100644
--- a/dbaccess/inc/pch/precompiled_dbaccess.hxx
+++ b/dbaccess/inc/pch/precompiled_dbaccess.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -476,6 +477,8 @@
#include "editeng/svxenum.hxx"
#include "svx/svxids.hrc"
+#include "rtl/ref.hxx"
+#include "salhelper/simplereferenceobject.hxx"
#include "tools/diagnose_ex.h"
@@ -498,10 +501,7 @@
#include "unotools/processfactory.hxx"
-#include "vos/mutex.hxx"
-#include "vos/ref.hxx"
-#include "vos/refernce.hxx"
-#include "vos/thread.hxx"
+#include "osl/mutex.hxx"
#include "xmloff/ProgressBarHelper.hxx"
#include "xmloff/XMLConstantsPropertyHandler.hxx"
@@ -518,3 +518,4 @@
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/prj/build.lst b/dbaccess/prj/build.lst
index a9ab550339a5..45372a76e18a 100644
--- a/dbaccess/prj/build.lst
+++ b/dbaccess/prj/build.lst
@@ -1,2 +1,3 @@
-ba dbaccess : L10N:l10n BOOST:boost connectivity svx stoc qadevOOo xmlscript LIBXSLT:libxslt test NULL
-ba dbaccess\prj nmake - all ba_prj NULL \ No newline at end of file
+ba dbaccess : TRANSLATIONS:translations BOOST:boost connectivity svx stoc qadevOOo xmlscript LIBXSLT:libxslt test NULL
+ba dbaccess usr1 - all ba_mkout NULL
+ba dbaccess\prj nmake - all ba_prj NULL
diff --git a/dbaccess/prj/makefile.mk b/dbaccess/prj/makefile.mk
index 88cd9dfe08b8..e312a7ccab65 100644..100755
--- a/dbaccess/prj/makefile.mk
+++ b/dbaccess/prj/makefile.mk
@@ -37,4 +37,4 @@ VERBOSEFLAG := -s
.ENDIF
all:
- cd $(PRJ) && $(GNUMAKE) $(VERBOSEFLAG) -r -j$(MAXPROCESS) $(gb_MAKETARGET) && $(GNUMAKE) $(VERBOSEFLAG) -r deliverlog
+ cd $(PRJ) && $(GNUMAKE) $(VERBOSEFLAG) -r -j$(MAXPROCESS) $(gb_MAKETARGET) && $(GNUMAKE) $(VERBOSEFLAG) -r deliverlog
diff --git a/dbaccess/qa/complex/dbaccess/DatabaseDocument.java b/dbaccess/qa/complex/dbaccess/DatabaseDocument.java
index d0c60eb9c4fb..b22671fa2f18 100644
--- a/dbaccess/qa/complex/dbaccess/DatabaseDocument.java
+++ b/dbaccess/qa/complex/dbaccess/DatabaseDocument.java
@@ -627,7 +627,7 @@ public class DatabaseDocument extends TestCase implements com.sun.star.document.
" oEvent.EventName = \"OnLoad\"\n" +
" oEvent.Source = ThisComponent\n" +
"\n" +
- " oCallback.documentEventOccured( oEvent )\n" +
+ " oCallback.documentEventOccurred( oEvent )\n" +
"End Sub\n";
XModel databaseDoc = impl_createDocWithMacro( libName, moduleName, eventHandlerCode );
final String documentURL = databaseDoc.getURL();
diff --git a/dbaccess/qa/complex/dbaccess/RowSet.java b/dbaccess/qa/complex/dbaccess/RowSet.java
index 921aff2046ef..482da7335941 100644
--- a/dbaccess/qa/complex/dbaccess/RowSet.java
+++ b/dbaccess/qa/complex/dbaccess/RowSet.java
@@ -101,11 +101,7 @@ public class RowSet extends TestCase
for (int i = 0; m_resultSet.next(); ++i)
{
int pos = m_resultSet.getRow();
- // final int val = m_row.getInt(1);
-// System.out.println("Clone Move(" + m_id +") before i: " + (i+1) + " Pos: " + pos + " Val: " + val);
testPosition(m_resultSet, m_row, i + 1, "clone move(" + m_id + ")");
-// val = m_row.getInt(1);
-// System.out.println("Clone Move(" + m_id +") after i: " + (i+1) + " Pos: " + pos + " Val: " + val);
int pos2 = m_resultSet.getRow();
assertTrue("ResultSetMovementStress wrong position: " + i + " Pos1: " + pos + " Pos2: " + pos2, pos == pos2);
}
@@ -358,7 +354,6 @@ public class RowSet extends TestCase
System.out.println("testing Thread");
try
{
- // final XRow _row = (XRow)UnoRuntime.queryInterface(XRow.class,_resultSet);
_resultSet.beforeFirst();
final int numberOfThreads = 10;
diff --git a/dbaccess/qa/unoapi/makefile.mk b/dbaccess/qa/unoapi/makefile.mk
deleted file mode 100644
index 41ed9480f526..000000000000
--- a/dbaccess/qa/unoapi/makefile.mk
+++ /dev/null
@@ -1,48 +0,0 @@
-#*************************************************************************
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#***********************************************************************/
-
-.IF "$(OOO_SUBSEQUENT_TESTS)" == ""
-nothing .PHONY:
-.ELSE
-
-PRJ = ../..
-PRJNAME = dbaccess
-TARGET = qa_unoapi
-
-.IF "$(OOO_JUNIT_JAR)" != ""
-PACKAGE = org/openoffice/dbaccess/qa/unoapi
-JAVATESTFILES = Test.java
-JAVAFILES = $(JAVATESTFILES)
-JARFILES = OOoRunner.jar ridl.jar test.jar
-EXTRAJARFILES = $(OOO_JUNIT_JAR)
-.END
-
-.INCLUDE: settings.mk
-.INCLUDE: target.mk
-.INCLUDE: installationtest.mk
-
-ALLTAR : javatest
-
-.END
diff --git a/dbaccess/source/core/api/BookmarkSet.cxx b/dbaccess/source/core/api/BookmarkSet.cxx
index c28363ad0cf1..f9cf63233a67 100644
--- a/dbaccess/source/core/api/BookmarkSet.cxx
+++ b/dbaccess/source/core/api/BookmarkSet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,11 +43,9 @@ using namespace ::dbtools;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::sdbc;
-// using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::sdbcx;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::lang;
-// using namespace ::cppu;
using namespace ::osl;
void OBookmarkSet::construct(const Reference< XResultSet>& _xDriverSet,const ::rtl::OUString& i_sRowSetFilter)
@@ -55,43 +54,43 @@ void OBookmarkSet::construct(const Reference< XResultSet>& _xDriverSet,const ::r
OCacheSet::construct(_xDriverSet,i_sRowSetFilter);
m_xRowLocate.set(_xDriverSet,UNO_QUERY);
}
-// -----------------------------------------------------------------------------
+
Any SAL_CALL OBookmarkSet::getBookmark() throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::getBookmark" );
return m_xRowLocate->getBookmark();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OBookmarkSet::moveToBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::moveToBookmark" );
return m_xRowLocate->moveToBookmark(bookmark);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OBookmarkSet::moveRelativeToBookmark( const Any& bookmark, sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::moveRelativeToBookmark" );
return m_xRowLocate->moveRelativeToBookmark(bookmark,rows);
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OBookmarkSet::compareBookmarks( const Any& _first, const Any& _second ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::compareBookmarks" );
return m_xRowLocate->compareBookmarks(_first,_second);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OBookmarkSet::hasOrderedBookmarks( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::hasOrderedBookmarks" );
return m_xRowLocate->hasOrderedBookmarks();
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OBookmarkSet::hashBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::hashBookmark" );
return m_xRowLocate->hashBookmark(bookmark);
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XDeleteRows
Sequence< sal_Int32 > SAL_CALL OBookmarkSet::deleteRows( const Sequence< Any >& rows ,const connectivity::OSQLTable& /*_xTable*/) throw(SQLException, RuntimeException)
{
@@ -103,7 +102,7 @@ Sequence< sal_Int32 > SAL_CALL OBookmarkSet::deleteRows( const Sequence< Any >&
}
return Sequence< sal_Int32 >();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OBookmarkSet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::insertRow" );
@@ -128,11 +127,10 @@ void SAL_CALL OBookmarkSet::insertRow( const ORowSetRow& _rInsertRow,const conne
else
::dbtools::throwSQLException( DBACORE_RESSTRING( RID_STR_NO_XRESULTSETUPDATE ), SQL_GENERAL_ERROR, *this );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OBookmarkSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrginalRow,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::updateRow" );
- // OCacheSet::updateRow( _rInsertRow,_rOrginalRow,_xTable);
Reference<XRowUpdate> xUpdRow(m_xRowLocate,UNO_QUERY);
if(!xUpdRow.is())
::dbtools::throwSQLException( DBACORE_RESSTRING( RID_STR_NO_XROWUPDATE ), SQL_GENERAL_ERROR, *this );
@@ -153,7 +151,7 @@ void SAL_CALL OBookmarkSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowS
else
::dbtools::throwSQLException( DBACORE_RESSTRING( RID_STR_NO_XRESULTSETUPDATE ), SQL_GENERAL_ERROR, *this );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OBookmarkSet::deleteRow(const ORowSetRow& /*_rDeleteRow*/ ,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::deleteRow" );
@@ -161,12 +159,12 @@ void SAL_CALL OBookmarkSet::deleteRow(const ORowSetRow& /*_rDeleteRow*/ ,const c
xUpd->deleteRow();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OBookmarkSet::cancelRowUpdates( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::cancelRowUpdates" );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OBookmarkSet::moveToInsertRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::moveToInsertRow" );
@@ -174,18 +172,18 @@ void SAL_CALL OBookmarkSet::moveToInsertRow( ) throw(SQLException, RuntimeExcep
if(xUpd.is())
xUpd->moveToInsertRow();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OBookmarkSet::moveToCurrentRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::moveToCurrentRow" );
}
-// -------------------------------------------------------------------------
+
void OBookmarkSet::fillValueRow(ORowSetRow& _rRow,sal_Int32 _nPosition)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::fillValueRow" );
OCacheSet::fillValueRow(_rRow,_nPosition);
}
-// -------------------------------------------------------------------------
+
void OBookmarkSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xParameter,const ORowSetValue& _rValue)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OBookmarkSet::updateColumn" );
@@ -204,8 +202,6 @@ void OBookmarkSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xParamet
break;
case DataType::CHAR:
case DataType::VARCHAR:
- //case DataType::DECIMAL:
- //case DataType::NUMERIC:
_xParameter->updateString(nPos,_rValue);
break;
case DataType::BIGINT:
@@ -265,4 +261,4 @@ void OBookmarkSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xParamet
}
}
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/BookmarkSet.hxx b/dbaccess/source/core/api/BookmarkSet.hxx
index 2bf9b4cfd0fa..1b7b8052c285 100644
--- a/dbaccess/source/core/api/BookmarkSet.hxx
+++ b/dbaccess/source/core/api/BookmarkSet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef DBACCESS_CORE_API_BOOKMARKSET_HXX
#define DBACCESS_CORE_API_BOOKMARKSET_HXX
-#ifndef DBACCESS_CORE_API_CACHESET_HXX
#include "CacheSet.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWUPDATE_HPP_
#include <com/sun/star/sdbc/XRowUpdate.hpp>
-#endif
namespace dbaccess
{
@@ -73,3 +70,4 @@ namespace dbaccess
}
#endif // DBACCESS_CORE_API_BOOKMARKSET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CIndexColumn.hxx b/dbaccess/source/core/api/CIndexColumn.hxx
index 948d472ef88c..2ac731919703 100644
--- a/dbaccess/source/core/api/CIndexColumn.hxx
+++ b/dbaccess/source/core/api/CIndexColumn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBACCESS_INDEXCOLUMN_HXX_
#define DBACCESS_INDEXCOLUMN_HXX_
-#ifndef _CONNECTIVITY_ADABAS_COLUMN_HXX_
#include "adabas/BColumn.hxx"
-#endif
namespace connectivity
{
@@ -57,3 +56,5 @@ namespace connectivity
}
}
#endif // DBACCESS_INDEXCOLUMN_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CIndexes.cxx b/dbaccess/source/core/api/CIndexes.cxx
index 3fdd9cc4de1a..8ea223cfff18 100644
--- a/dbaccess/source/core/api/CIndexes.cxx
+++ b/dbaccess/source/core/api/CIndexes.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_INDEXES_HXX_
#include "CIndexes.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSET_HPP_
#include <com/sun/star/sdbc/XResultSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_INDEXTYPE_HPP_
#include <com/sun/star/sdbc/IndexType.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace connectivity;
@@ -75,7 +60,7 @@ ObjectType OIndexes::createObject(const ::rtl::OUString& _rName)
return xRet;
}
-// -------------------------------------------------------------------------
+
Reference< XPropertySet > OIndexes::createDescriptor()
{
Reference<XDataDescriptorFactory> xData( m_xIndexes,UNO_QUERY);
@@ -84,7 +69,7 @@ Reference< XPropertySet > OIndexes::createDescriptor()
else
return OIndexesHelper::createDescriptor();
}
-// -------------------------------------------------------------------------
+
// XAppend
ObjectType OIndexes::appendObject( const ::rtl::OUString& _rForName, const Reference< XPropertySet >& descriptor )
{
@@ -95,7 +80,7 @@ ObjectType OIndexes::appendObject( const ::rtl::OUString& _rForName, const Refer
xData->appendByDescriptor(descriptor);
return createObject( _rForName );
}
-// -------------------------------------------------------------------------
+
// XDrop
void OIndexes::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName)
{
@@ -108,7 +93,7 @@ void OIndexes::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName)
else
OIndexesHelper::dropObject(_nPos,_sElementName);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OIndexes::disposing(void)
{
if ( m_xIndexes.is() )
@@ -116,8 +101,4 @@ void SAL_CALL OIndexes::disposing(void)
else
OIndexesHelper::disposing();
}
-// -----------------------------------------------------------------------------
-
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CIndexes.hxx b/dbaccess/source/core/api/CIndexes.hxx
index c461204754be..ec58d93f9160 100644
--- a/dbaccess/source/core/api/CIndexes.hxx
+++ b/dbaccess/source/core/api/CIndexes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBACCESS_INDEXES_HXX_
#define DBACCESS_INDEXES_HXX_
-#ifndef CONNECTIVITY_INDEXESHELPER_HXX
#include "connectivity/TIndexes.hxx"
-#endif
namespace dbaccess
{
@@ -56,3 +55,5 @@ namespace dbaccess
}
#endif // DBACCESS_INDEXES_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CRowSetColumn.cxx b/dbaccess/source/core/api/CRowSetColumn.cxx
index 12a7d16e8716..161525667d1b 100644
--- a/dbaccess/source/core/api/CRowSetColumn.cxx
+++ b/dbaccess/source/core/api/CRowSetColumn.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,25 +44,18 @@ using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::beans;
-//..............................................................................
namespace dbaccess
{
-//..............................................................................
-//------------------------------------------------------------------------------
ORowSetColumn::ORowSetColumn( const Reference < XResultSetMetaData >& _xMetaData, const Reference < XRow >& _xRow, sal_Int32 _nPos,
const Reference< XDatabaseMetaData >& _rxDBMeta, const ::rtl::OUString& _rDescription, const ::rtl::OUString& i_sLabel,ORowSetCacheIterator& _rColumnValue )
:ORowSetDataColumn( _xMetaData, _xRow, NULL, _nPos, _rxDBMeta, _rDescription, i_sLabel,_rColumnValue )
{
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* ORowSetColumn::createArrayHelper( ) const
{
- const sal_Int32 nDerivedProperties = 21;
- Sequence< Property> aDerivedProperties( nDerivedProperties );
- Property* pDesc = aDerivedProperties.getArray();
- sal_Int32 nPos = 0;
+ BEGIN_PROPERTY_SEQUENCE(21)
DECL_PROP1( CATALOGNAME, ::rtl::OUString, READONLY );
DECL_PROP1( DISPLAYSIZE, sal_Int32, READONLY );
@@ -84,21 +78,20 @@ ORowSetColumn::ORowSetColumn( const Reference < XResultSetMetaData >& _xMetaDa
DECL_PROP1( TYPE, sal_Int32, READONLY );
DECL_PROP1( TYPENAME, ::rtl::OUString, READONLY );
DECL_PROP2( VALUE, Any, READONLY, BOUND );
- OSL_ENSURE( nPos == nDerivedProperties, "ORowSetColumn::createArrayHelper: inconsistency!" );
+
+ END_PROPERTY_SEQUENCE()
Sequence< Property > aRegisteredProperties;
describeProperties( aRegisteredProperties );
- return new ::cppu::OPropertyArrayHelper( ::comphelper::concatSequences( aDerivedProperties, aRegisteredProperties ), sal_False );
+ return new ::cppu::OPropertyArrayHelper( ::comphelper::concatSequences( aDescriptor, aRegisteredProperties ), sal_False );
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& ORowSetColumn::getInfoHelper()
{
return *static_cast< ::comphelper::OPropertyArrayUsageHelper< ORowSetColumn >* >(this)->getArrayHelper();
}
-//------------------------------------------------------------------------------
void SAL_CALL ORowSetColumn::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue )throw (Exception)
{
OSL_ENSURE( nHandle != PROPERTY_ID_VALUE, "ORowSetColumn::setFastPropertyValue_NoBroadcast: hmm? This property is marked as READONLY!" );
@@ -106,6 +99,5 @@ void SAL_CALL ORowSetColumn::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,
ORowSetDataColumn::setFastPropertyValue_NoBroadcast( nHandle, rValue );
}
-//..............................................................................
} // namespace dbaccess
-//..............................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CRowSetColumn.hxx b/dbaccess/source/core/api/CRowSetColumn.hxx
index 043837f44589..2d6fe45a4006 100644
--- a/dbaccess/source/core/api/CRowSetColumn.hxx
+++ b/dbaccess/source/core/api/CRowSetColumn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
#ifndef DBACCESS_CORE_API_CROWSETCOLUMN_HXX
#define DBACCESS_CORE_API_CROWSETCOLUMN_HXX
-#ifndef DBACCESS_CORE_API_ROWSETROW_HXX
#include "RowSetRow.hxx"
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef DBACCESS_CORE_API_CROWSETDATACOLUMN_HXX
#include "CRowSetDataColumn.hxx"
-#endif
namespace dbaccess
{
@@ -64,3 +57,5 @@ namespace dbaccess
}
#endif // DBACCESS_CORE_API_CROWSETCOLUMN_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CRowSetDataColumn.cxx b/dbaccess/source/core/api/CRowSetDataColumn.cxx
index 9bdcda88c93d..2aa99a9ff767 100644
--- a/dbaccess/source/core/api/CRowSetDataColumn.cxx
+++ b/dbaccess/source/core/api/CRowSetDataColumn.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,34 +29,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBACORE_DATACOLUMN_HXX_
#include "CRowSetDataColumn.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace dbaccess;
using namespace comphelper;
using namespace connectivity;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
-// using namespace ::com::sun::star::sdbcx;
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::lang;
@@ -64,7 +50,7 @@ using namespace cppu;
using namespace osl;
DBG_NAME(ORowSetDataColumn)
-// -------------------------------------------------------------------------
+
ORowSetDataColumn::ORowSetDataColumn( const Reference < XResultSetMetaData >& _xMetaData,
const Reference < XRow >& _xRow,
const Reference < XRowUpdate >& _xRowUpdate,
@@ -82,20 +68,16 @@ ORowSetDataColumn::ORowSetDataColumn( const Reference < XResultSetMetaData >&
OColumnSettings::registerProperties( *this );
registerProperty( PROPERTY_DESCRIPTION, PROPERTY_ID_DESCRIPTION, PropertyAttribute::READONLY, &m_aDescription, ::getCppuType( &m_aDescription ) );
}
-// -------------------------------------------------------------------------
+
ORowSetDataColumn::~ORowSetDataColumn()
{
DBG_DTOR(ORowSetDataColumn,NULL);
}
-// -------------------------------------------------------------------------
+
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* ORowSetDataColumn::createArrayHelper( ) const
{
- const sal_Int32 nDerivedProperties = 21;
- Sequence< Property> aDerivedProperties( nDerivedProperties );
- Property* pDesc = aDerivedProperties.getArray();
- sal_Int32 nPos = 0;
+ BEGIN_PROPERTY_SEQUENCE(21)
DECL_PROP1( CATALOGNAME, ::rtl::OUString, READONLY );
DECL_PROP1( DISPLAYSIZE, sal_Int32, READONLY );
@@ -118,26 +100,26 @@ ORowSetDataColumn::~ORowSetDataColumn()
DECL_PROP1( TYPE, sal_Int32, READONLY );
DECL_PROP1( TYPENAME, ::rtl::OUString, READONLY );
DECL_PROP1( VALUE, Any, BOUND );
- OSL_ENSURE( nPos == nDerivedProperties, "ORowSetDataColumn::createArrayHelper: inconsistency!" );
+
+ END_PROPERTY_SEQUENCE()
Sequence< Property > aRegisteredProperties;
describeProperties( aRegisteredProperties );
- return new ::cppu::OPropertyArrayHelper( ::comphelper::concatSequences( aDerivedProperties, aRegisteredProperties ), sal_False );
+ return new ::cppu::OPropertyArrayHelper( ::comphelper::concatSequences( aDescriptor, aRegisteredProperties ), sal_False );
}
// cppu::OPropertySetHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& ORowSetDataColumn::getInfoHelper()
{
return *static_cast< ::comphelper::OPropertyArrayUsageHelper< ORowSetDataColumn >* >(this)->getArrayHelper();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSetDataColumn::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
{
if ( PROPERTY_ID_VALUE == nHandle )
{
- if ( !m_aColumnValue.isNull() && m_aColumnValue->isValid() )
+ if ( !m_aColumnValue.isNull() && m_aColumnValue->is() )
{
::osl::Mutex* pMutex = m_aColumnValue.getMutex();
::osl::MutexGuard aGuard( *pMutex );
@@ -154,7 +136,6 @@ void SAL_CALL ORowSetDataColumn::getFastPropertyValue( Any& rValue, sal_Int32 nH
ODataColumn::getFastPropertyValue( rValue, nHandle );
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSetDataColumn::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue )throw (Exception)
{
switch( nHandle )
@@ -174,7 +155,7 @@ void SAL_CALL ORowSetDataColumn::setFastPropertyValue_NoBroadcast(sal_Int32 nHan
break;
}
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetDataColumn::convertFastPropertyValue( Any & rConvertedValue,
Any & rOldValue,
sal_Int32 nHandle,
@@ -204,7 +185,7 @@ sal_Bool SAL_CALL ORowSetDataColumn::convertFastPropertyValue( Any & rConvertedV
return bModified;
}
-//--------------------------------------------------------------------------
+
Sequence< sal_Int8 > ORowSetDataColumn::getImplementationId() throw (RuntimeException)
{
static OImplementationId * pId = 0;
@@ -219,10 +200,10 @@ Sequence< sal_Int8 > ORowSetDataColumn::getImplementationId() throw (RuntimeExce
}
return pId->getImplementationId();
}
-// -------------------------------------------------------------------------
+
void ORowSetDataColumn::fireValueChange(const ORowSetValue& _rOldValue)
{
- if ( !m_aColumnValue.isNull() && m_aColumnValue->isValid() && (!(((*m_aColumnValue)->get())[m_nPos] == _rOldValue)) )
+ if ( !m_aColumnValue.isNull() && m_aColumnValue->is() && (!(((*m_aColumnValue)->get())[m_nPos] == _rOldValue)) )
{
sal_Int32 nHandle = PROPERTY_ID_VALUE;
m_aOldValue = _rOldValue.makeAny();
@@ -239,11 +220,11 @@ void ORowSetDataColumn::fireValueChange(const ORowSetValue& _rOldValue)
fire(&nHandle, &aNew, &m_aOldValue, 1, sal_False );
}
}
-// -----------------------------------------------------------------------------
+
DBG_NAME(ORowSetDataColumns )
ORowSetDataColumns::ORowSetDataColumns(
sal_Bool _bCase,
- const ::vos::ORef< ::connectivity::OSQLColumns>& _rColumns,
+ const ::rtl::Reference< ::connectivity::OSQLColumns>& _rColumns,
::cppu::OWeakObject& _rParent,
::osl::Mutex& _rMutex,
const ::std::vector< ::rtl::OUString> &_rVector
@@ -252,12 +233,12 @@ ORowSetDataColumns::ORowSetDataColumns(
{
DBG_CTOR(ORowSetDataColumns ,NULL);
}
-// -----------------------------------------------------------------------------
+
ORowSetDataColumns::~ORowSetDataColumns()
{
DBG_DTOR(ORowSetDataColumns ,NULL);
}
-// -----------------------------------------------------------------------------
+
sdbcx::ObjectType ORowSetDataColumns::createObject(const ::rtl::OUString& _rName)
{
connectivity::sdbcx::ObjectType xNamed;
@@ -269,24 +250,20 @@ sdbcx::ObjectType ORowSetDataColumns::createObject(const ::rtl::OUString& _rName
return xNamed;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ORowSetDataColumns::disposing(void)
{
- // clear_NoDispose();
ORowSetDataColumns_BASE::disposing();
m_aColumns = NULL;
- // m_aColumns.clear();
}
-// -----------------------------------------------------------------------------
-void ORowSetDataColumns::assign(const ::vos::ORef< ::connectivity::OSQLColumns>& _rColumns,const ::std::vector< ::rtl::OUString> &_rVector)
+
+void ORowSetDataColumns::assign(const ::rtl::Reference< ::connectivity::OSQLColumns>& _rColumns,const ::std::vector< ::rtl::OUString> &_rVector)
{
m_aColumns = _rColumns;
reFill(_rVector);
}
-// -----------------------------------------------------------------------------
+
void ORowSetDataColumns::impl_refresh() throw(::com::sun::star::uno::RuntimeException)
{
}
-// -----------------------------------------------------------------------------
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CRowSetDataColumn.hxx b/dbaccess/source/core/api/CRowSetDataColumn.hxx
index e5009d4d6f7c..8cf0aa5f2c95 100644
--- a/dbaccess/source/core/api/CRowSetDataColumn.hxx
+++ b/dbaccess/source/core/api/CRowSetDataColumn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,21 +84,18 @@ namespace dbaccess
protected:
using ODataColumn::getFastPropertyValue;
};
- // -------------------------------------------------------------------------
-// typedef connectivity::ORefVector< ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet> >
-// ORowSetDataColumns_COLLECTION;
typedef connectivity::sdbcx::OCollection ORowSetDataColumns_BASE;
class ORowSetDataColumns : public ORowSetDataColumns_BASE
{
- ::vos::ORef< ::connectivity::OSQLColumns> m_aColumns;
+ ::rtl::Reference< ::connectivity::OSQLColumns> m_aColumns;
protected:
virtual connectivity::sdbcx::ObjectType createObject(const ::rtl::OUString& _rName);
virtual void impl_refresh() throw(::com::sun::star::uno::RuntimeException);
public:
ORowSetDataColumns(
sal_Bool _bCase,
- const ::vos::ORef< ::connectivity::OSQLColumns>& _rColumns,
+ const ::rtl::Reference< ::connectivity::OSQLColumns>& _rColumns,
::cppu::OWeakObject& _rParent,
::osl::Mutex& _rMutex,
const ::std::vector< ::rtl::OUString> &_rVector
@@ -105,9 +103,10 @@ namespace dbaccess
virtual ~ORowSetDataColumns();
// only the name is identical to ::cppu::OComponentHelper
virtual void SAL_CALL disposing(void);
- void assign(const ::vos::ORef< ::connectivity::OSQLColumns>& _rColumns,const ::std::vector< ::rtl::OUString> &_rVector);
+ void assign(const ::rtl::Reference< ::connectivity::OSQLColumns>& _rColumns,const ::std::vector< ::rtl::OUString> &_rVector);
};
}
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CacheSet.cxx b/dbaccess/source/core/api/CacheSet.cxx
index 1c21ed2dbfa0..f1e5f3e0dfdb 100644
--- a/dbaccess/source/core/api/CacheSet.cxx
+++ b/dbaccess/source/core/api/CacheSet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,64 +28,28 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_CORE_API_CACHESET_HXX
#include "CacheSet.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HXX_
#include "core_resource.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HRC_
#include "core_resource.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_COMPAREBOOKMARK_HPP_
#include <com/sun/star/sdbcx/CompareBookmark.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPREPAREDSTATEMENT_HPP_
#include <com/sun/star/sdbc/XPreparedStatement.hpp>
-#endif
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#ifndef _COM_SUN_STAR_SDBC_XPARAMETERS_HPP_
#include <com/sun/star/sdbc/XParameters.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XKEYSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XINDEXESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XIndexesSupplier.hpp>
-#endif
#include <limits>
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_KEYTYPE_HPP_
#include <com/sun/star/sdbcx/KeyType.hpp>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_IO_XINPUTSTREAM_HPP_
#include <com/sun/star/io/XInputStream.hpp>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#include <rtl/ustrbuf.hxx>
#include <rtl/logfile.hxx>
@@ -96,16 +61,14 @@ using namespace connectivity;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::sdbc;
-// using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::sdbcx;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::io;
-// using namespace ::cppu;
using namespace ::osl;
DBG_NAME(OCacheSet)
-// -------------------------------------------------------------------------
+
OCacheSet::OCacheSet(sal_Int32 i_nMaxRows)
:m_nMaxRows(i_nMaxRows)
,m_bInserted(sal_False)
@@ -116,7 +79,7 @@ OCacheSet::OCacheSet(sal_Int32 i_nMaxRows)
DBG_CTOR(OCacheSet,NULL);
}
-// -------------------------------------------------------------------------
+
::rtl::OUString OCacheSet::getIdentifierQuoteString() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getIdentifierQuoteString" );
@@ -126,7 +89,7 @@ OCacheSet::OCacheSet(sal_Int32 i_nMaxRows)
sQuote = xMeta->getIdentifierQuoteString();
return sQuote;
}
-// -------------------------------------------------------------------------
+
void OCacheSet::construct( const Reference< XResultSet>& _xDriverSet,const ::rtl::OUString& /*i_sRowSetFilter*/)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::construct" );
@@ -163,7 +126,7 @@ void OCacheSet::construct( const Reference< XResultSet>& _xDriverSet,const ::rt
}
}
}
-// -------------------------------------------------------------------------
+
OCacheSet::~OCacheSet()
{
try
@@ -175,16 +138,16 @@ OCacheSet::~OCacheSet()
}
catch(Exception&)
{
- OSL_ENSURE(0,"Exception occured");
+ OSL_FAIL("Exception occurred");
}
catch(...)
{
- OSL_ENSURE(0,"Unknown Exception occured");
+ OSL_FAIL("Unknown Exception occurred");
}
DBG_DTOR(OCacheSet,NULL);
}
-// -----------------------------------------------------------------------------
+
void OCacheSet::fillTableName(const Reference<XPropertySet>& _xTable) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::fillTableName" );
@@ -200,7 +163,7 @@ void OCacheSet::fillTableName(const Reference<XPropertySet>& _xTable) throw(SQL
,::dbtools::eInDataManipulation);
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OCacheSet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::insertRow" );
@@ -209,9 +172,9 @@ void SAL_CALL OCacheSet::insertRow( const ORowSetRow& _rInsertRow,const connecti
fillTableName(xSet);
aSql.append(m_aComposedTableName);
- aSql.append(::rtl::OUString::createFromAscii(" ( "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" ( ")));
// set values and column names
- ::rtl::OUStringBuffer aValues = ::rtl::OUString::createFromAscii(" VALUES ( ");
+ ::rtl::OUStringBuffer aValues = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" VALUES ( "));
static ::rtl::OUString aPara(RTL_CONSTASCII_USTRINGPARAM("?,"));
::rtl::OUString aQuote = getIdentifierQuoteString();
static ::rtl::OUString aComma(RTL_CONSTASCII_USTRINGPARAM(","));
@@ -245,24 +208,9 @@ void SAL_CALL OCacheSet::insertRow( const ORowSetRow& _rInsertRow,const connecti
m_bInserted = xPrep->executeUpdate() > 0;
}
-// ::rtl::OUString aCountSql = ::rtl::OUString::createFromAscii("SELECT COUNT(*) FROM ");
-// aCountSql += m_aComposedTableName;
-// try
-// {
-// Reference< XStatement > xStmt(m_xConnection->createStatement());
-// Reference<XResultSet> xRes(xStmt->executeQuery(aCountSql));
-// if(xRes.is() && xRes->next())
-// {
-// Reference<XRow> xRow(xRes,UNO_QUERY);
-// }
-// }
-// catch(SQLException&)
-// {
-// }
-
// TODO set the bookmark in the insert row
}
-// -------------------------------------------------------------------------
+
void OCacheSet::fillParameters( const ORowSetRow& _rRow
,const connectivity::OSQLTable& _xTable
,::rtl::OUStringBuffer& _sCondition
@@ -270,7 +218,7 @@ void OCacheSet::fillParameters( const ORowSetRow& _rRow
,::std::list< sal_Int32>& _rOrgValues)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::fillParameters" );
- // use keys and indexes for excat postioning
+ // use keys and indexes for exact positioning
// first the keys
Reference<XPropertySet> xSet(_xTable,UNO_QUERY);
const Reference<XNameAccess> xPrimaryKeyColumns = getPrimaryKeyColumns_throw(xSet);
@@ -299,8 +247,8 @@ void OCacheSet::fillParameters( const ORowSetRow& _rRow
::rtl::OUString aColumnName;
- static ::rtl::OUString aPara = ::rtl::OUString::createFromAscii("?,");
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aPara(RTL_CONSTASCII_USTRINGPARAM("?,"));
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
::rtl::OUString aQuote = getIdentifierQuoteString();
@@ -324,7 +272,7 @@ void OCacheSet::fillParameters( const ORowSetRow& _rRow
_sCondition.append(aAnd);
_rOrgValues.push_back(nCheckCount);
- } // if(xPrimaryKeyColumns.is() && xPrimaryKeyColumns->hasByName(aColumnName))
+ }
::std::vector< Reference<XNameAccess> >::const_iterator aIndexEnd = aAllIndexColumns.end();
for( ::std::vector< Reference<XNameAccess> >::const_iterator aIndexIter = aAllIndexColumns.begin();
aIndexIter != aIndexEnd;++aIndexIter)
@@ -348,16 +296,16 @@ void OCacheSet::fillParameters( const ORowSetRow& _rRow
}
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OCacheSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrginalRow,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::updateRow" );
Reference<XPropertySet> xSet(_xTable,UNO_QUERY);
fillTableName(xSet);
- ::rtl::OUStringBuffer aSql = ::rtl::OUString::createFromAscii("UPDATE ");
+ ::rtl::OUStringBuffer aSql = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UPDATE "));
aSql.append(m_aComposedTableName);
- aSql.append(::rtl::OUString::createFromAscii(" SET "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" SET ")));
// list all cloumns that should be set
::rtl::OUStringBuffer aCondition;
@@ -368,7 +316,7 @@ void SAL_CALL OCacheSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetR
{
aCondition.setLength(aCondition.getLength()-5);
- aSql.append(::rtl::OUString::createFromAscii(" WHERE "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" WHERE ")));
aSql.append(aCondition.makeStringAndClear());
}
else
@@ -387,7 +335,7 @@ void SAL_CALL OCacheSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetR
setParameter(i,xParameter,*aIter,m_xSetMetaData->getColumnType(i),m_xSetMetaData->getScale(i));
++i;
}
- } // for(ORowVector< ORowSetValue >::Vector::const_iterator aIter = _rInsertRow->get().begin()+1; aIter != aEnd;++aIter)
+ }
::std::list< sal_Int32>::const_iterator aOrgValueEnd = aOrgValues.end();
for(::std::list< sal_Int32>::const_iterator aOrgValue = aOrgValues.begin(); aOrgValue != aOrgValueEnd;++aOrgValue,++i)
{
@@ -396,22 +344,22 @@ void SAL_CALL OCacheSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetR
m_bUpdated = xPrep->executeUpdate() > 0;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OCacheSet::deleteRow(const ORowSetRow& _rDeleteRow ,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::deleteRow" );
Reference<XPropertySet> xSet(_xTable,UNO_QUERY);
fillTableName(xSet);
- ::rtl::OUStringBuffer aSql = ::rtl::OUString::createFromAscii("DELETE FROM ");
+ ::rtl::OUStringBuffer aSql = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DELETE FROM "));
aSql.append(m_aComposedTableName);
- aSql.append(::rtl::OUString::createFromAscii(" WHERE "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" WHERE ")));
// list all cloumns that should be set
::rtl::OUString aQuote = getIdentifierQuoteString();
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
- // use keys and indexes for excat postioning
+ // use keys and indexes for exact positioning
// first the keys
const Reference<XNameAccess> xPrimaryKeyColumns = getPrimaryKeyColumns_throw(xSet);
// second the indexes
@@ -443,7 +391,7 @@ void SAL_CALL OCacheSet::deleteRow(const ORowSetRow& _rDeleteRow ,const connecti
aSql.setLength(aSql.getLength()-5);
- // now create end execute the prepared statement
+ // now create and execute the prepared statement
Reference< XPreparedStatement > xPrep(m_xConnection->prepareStatement(aSql.makeStringAndClear()));
Reference< XParameters > xParameter(xPrep,UNO_QUERY);
sal_Int32 i = 1;
@@ -455,7 +403,7 @@ void SAL_CALL OCacheSet::deleteRow(const ORowSetRow& _rDeleteRow ,const connecti
m_bDeleted = xPrep->executeUpdate() > 0;
}
-// -------------------------------------------------------------------------
+
void OCacheSet::setParameter(sal_Int32 nPos
,const Reference< XParameters >& _xParameter
,const ORowSetValue& _rValue
@@ -466,7 +414,7 @@ void OCacheSet::setParameter(sal_Int32 nPos
sal_Int32 nType = ( _nType != DataType::OTHER ) ? _nType : _rValue.getTypeKind();
::dbtools::setObjectWithInfo(_xParameter,nPos,_rValue,nType,_nScale);
}
-// -------------------------------------------------------------------------
+
void OCacheSet::fillValueRow(ORowSetRow& _rRow,sal_Int32 _nPosition)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::fillValueRow" );
@@ -484,127 +432,127 @@ void OCacheSet::fillValueRow(ORowSetRow& _rRow,sal_Int32 _nPosition)
aIter->fill(i,m_aColumnTypes[i-1],m_aNullable[i-1],this);
}
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::wasNull( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::wasNull" );
return m_xDriverRow->wasNull();
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OCacheSet::getString( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getString" );
return m_xDriverRow->getString(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::getBoolean( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getBoolean" );
return m_xDriverRow->getBoolean(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int8 SAL_CALL OCacheSet::getByte( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getByte" );
return m_xDriverRow->getByte(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int16 SAL_CALL OCacheSet::getShort( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getShort" );
return m_xDriverRow->getShort(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OCacheSet::getInt( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getInt" );
return m_xDriverRow->getInt(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int64 SAL_CALL OCacheSet::getLong( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getLong" );
return m_xDriverRow->getLong(columnIndex);
}
-// -------------------------------------------------------------------------
+
float SAL_CALL OCacheSet::getFloat( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getFloat" );
return m_xDriverRow->getFloat(columnIndex);
}
-// -------------------------------------------------------------------------
+
double SAL_CALL OCacheSet::getDouble( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getDouble" );
return m_xDriverRow->getDouble(columnIndex);
}
-// -------------------------------------------------------------------------
+
Sequence< sal_Int8 > SAL_CALL OCacheSet::getBytes( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getBytes" );
return m_xDriverRow->getBytes(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Date SAL_CALL OCacheSet::getDate( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getDate" );
return m_xDriverRow->getDate(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Time SAL_CALL OCacheSet::getTime( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getTime" );
return m_xDriverRow->getTime(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::DateTime SAL_CALL OCacheSet::getTimestamp( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getTimestamp" );
return m_xDriverRow->getTimestamp(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL OCacheSet::getBinaryStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getBinaryStream" );
return m_xDriverRow->getBinaryStream(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL OCacheSet::getCharacterStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getCharacterStream" );
return m_xDriverRow->getCharacterStream(columnIndex);
}
-// -------------------------------------------------------------------------
+
Any SAL_CALL OCacheSet::getObject( sal_Int32 columnIndex, const Reference< ::com::sun::star::container::XNameAccess >& typeMap ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getObject" );
return m_xDriverRow->getObject(columnIndex,typeMap);
}
-// -------------------------------------------------------------------------
+
Reference< XRef > SAL_CALL OCacheSet::getRef( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getRef" );
return m_xDriverRow->getRef(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< XBlob > SAL_CALL OCacheSet::getBlob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getBlob" );
return m_xDriverRow->getBlob(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< XClob > SAL_CALL OCacheSet::getClob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getClob" );
return m_xDriverRow->getClob(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< XArray > SAL_CALL OCacheSet::getArray( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getArray" );
return m_xDriverRow->getArray(columnIndex);
}
-// -------------------------------------------------------------------------
+
// XResultSet
sal_Bool SAL_CALL OCacheSet::next( ) throw(SQLException, RuntimeException)
{
@@ -612,157 +560,157 @@ sal_Bool SAL_CALL OCacheSet::next( ) throw(SQLException, RuntimeException)
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return m_xDriverSet->next();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::isBeforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::isBeforeFirst" );
return m_xDriverSet->isBeforeFirst();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::isAfterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::isAfterLast" );
return m_xDriverSet->isAfterLast();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::isFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::isFirst" );
return m_xDriverSet->isFirst();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::isLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::isLast" );
return m_xDriverSet->isLast();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OCacheSet::beforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::beforeFirst" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
m_xDriverSet->beforeFirst();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OCacheSet::afterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::afterLast" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
m_xDriverSet->afterLast();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::first( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::first" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return m_xDriverSet->first();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::last( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::last" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return m_xDriverSet->last();
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OCacheSet::getRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getRow" );
return m_xDriverSet->getRow();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::absolute( sal_Int32 row ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::absolute" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return m_xDriverSet->absolute(row);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::relative( sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::relative" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return m_xDriverSet->relative(rows);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::previous( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::previous" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return m_xDriverSet->previous();
}
+
sal_Bool OCacheSet::last_checked( sal_Bool /*i_bFetchRow*/)
{
return last();
}
-// -------------------------------------------------------------------------
+
sal_Bool OCacheSet::previous_checked( sal_Bool /*i_bFetchRow*/ )
{
return previous();
}
-// -------------------------------------------------------------------------
+
sal_Bool OCacheSet::absolute_checked( sal_Int32 row,sal_Bool /*i_bFetchRow*/ )
{
return absolute(row);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OCacheSet::refreshRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::refreshRow" );
m_xDriverSet->refreshRow();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::rowUpdated( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::rowUpdated" );
return m_xDriverSet->rowUpdated();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::rowInserted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::rowInserted" );
return m_xDriverSet->rowInserted();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OCacheSet::rowDeleted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::rowDeleted" );
return m_xDriverSet->rowDeleted();
}
-// -------------------------------------------------------------------------
+
Reference< XInterface > SAL_CALL OCacheSet::getStatement( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCacheSet::getStatement" );
return m_xDriverSet->getStatement();
}
-// -----------------------------------------------------------------------------
+
bool OCacheSet::isResultSetChanged() const
{
return false;
}
-// -----------------------------------------------------------------------------
+
void OCacheSet::reset(const Reference< XResultSet>& /*_xDriverSet*/)
{
- OSL_ENSURE(0,"Illegal call!");
+ OSL_FAIL("Illegal call!");
}
-// -----------------------------------------------------------------------------
+
void OCacheSet::mergeColumnValues(sal_Int32 i_nColumnIndex,ORowSetValueVector::Vector& /*io_aInsertRow*/,ORowSetValueVector::Vector& /*io_aRow*/,::std::vector<sal_Int32>& o_aChangedColumns)
{
o_aChangedColumns.push_back(i_nColumnIndex);
}
-// -----------------------------------------------------------------------------
+
bool OCacheSet::columnValuesUpdated(ORowSetValueVector::Vector& /*io_aCachedRow*/,const ORowSetValueVector::Vector& /*io_aRow*/)
{
return false;
}
-// -----------------------------------------------------------------------------
+
bool OCacheSet::updateColumnValues(const ORowSetValueVector::Vector& /*io_aCachedRow*/,ORowSetValueVector::Vector& /*io_aRow*/,const ::std::vector<sal_Int32>& /*i_aChangedColumns*/)
{
return true;
}
-// -----------------------------------------------------------------------------
+
void OCacheSet::fillMissingValues(ORowSetValueVector::Vector& /*io_aRow*/) const
{
}
-// -----------------------------------------------------------------------------
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/CacheSet.hxx b/dbaccess/source/core/api/CacheSet.hxx
index 0c83362983e2..0951b3de8ac2 100644
--- a/dbaccess/source/core/api/CacheSet.hxx
+++ b/dbaccess/source/core/api/CacheSet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -160,3 +161,4 @@ namespace dbaccess
}
#endif //DBACCESS_CORE_API_CACHESET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/FilteredContainer.cxx b/dbaccess/source/core/api/FilteredContainer.cxx
index aa20bf080e4d..d9ead8aa4f79 100644
--- a/dbaccess/source/core/api/FilteredContainer.cxx
+++ b/dbaccess/source/core/api/FilteredContainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,7 +57,6 @@ namespace dbaccess
using namespace ::cppu;
using namespace ::connectivity::sdbcx;
-//------------------------------------------------------------------------------
/** creates a vector of WildCards and reduce the _rTableFilter of the length of WildsCards
*/
sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std::vector< WildCard >& _rOut)
@@ -87,7 +87,6 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
return nShiftPos;
}
- // -------------------------------------------------------------------------
bool lcl_isElementAllowed( const ::rtl::OUString& _rName,
const Sequence< ::rtl::OUString >& _rTableFilter,
const ::std::vector< WildCard >& _rWCSearch )
@@ -110,7 +109,6 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
return bFilterMatch;
}
- //--------------------------------------------------------------------------
typedef ::boost::optional< ::rtl::OUString > OptionalString;
struct TableInfo
{
@@ -137,7 +135,6 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
};
typedef ::std::vector< TableInfo > TableInfos;
- //--------------------------------------------------------------------------
void lcl_ensureComposedName( TableInfo& _io_tableInfo, const Reference< XDatabaseMetaData >& _metaData )
{
if ( !_metaData.is() )
@@ -154,7 +151,6 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
}
}
- //--------------------------------------------------------------------------
void lcl_ensureType( TableInfo& _io_tableInfo, const Reference< XDatabaseMetaData >& _metaData, const Reference< XNameAccess >& _masterContainer )
{
if ( !!_io_tableInfo.sType )
@@ -178,7 +174,6 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
_io_tableInfo.sType = OptionalString( sTypeName );
}
- //--------------------------------------------------------------------------
connectivity::TStringVector lcl_filter( const TableInfos& _unfilteredTables,
const Sequence< ::rtl::OUString >& _tableFilter, const Sequence< ::rtl::OUString >& _tableTypeFilter,
const Reference< XDatabaseMetaData >& _metaData, const Reference< XNameAccess >& _masterContainer )
@@ -194,7 +189,7 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
}
else
{
- // for wildcard search : remove all table filters which are a wildcard expression and build a WilCard
+ // for wildcard search : remove all table filters which are a wildcard expression and build a WildCard
// for them
::std::vector< WildCard > aWildCardTableFilter;
Sequence< ::rtl::OUString > aNonWildCardTableFilter = _tableFilter;
@@ -271,7 +266,7 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
,m_xConnection(_xCon)
{
}
- // -------------------------------------------------------------------------
+
void OFilteredContainer::construct(const Reference< XNameAccess >& _rxMasterContainer,
const Sequence< ::rtl::OUString >& _rTableFilter,
const Sequence< ::rtl::OUString >& _rTableTypeFilter)
@@ -311,17 +306,16 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
construct( _rTableFilter, _rTableTypeFilter );
}
}
- //------------------------------------------------------------------------------
+
void OFilteredContainer::construct(const Sequence< ::rtl::OUString >& _rTableFilter, const Sequence< ::rtl::OUString >& _rTableTypeFilter)
{
// build sorted versions of the filter sequences, so the visibility decision is faster
Sequence< ::rtl::OUString > aTableFilter(_rTableFilter);
- sal_Int32 nTableFilterLen = aTableFilter.getLength();
- // for wildcard search : remove all table filters which are a wildcard expression and build a WilCard
+ // for wildcard search : remove all table filters which are a wildcard expression and build a WildCard
// for them
::std::vector< WildCard > aWCSearch;
- nTableFilterLen = createWildCardVector(aTableFilter,aWCSearch);
+ createWildCardVector(aTableFilter,aWCSearch);
try
{
@@ -367,7 +361,7 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
}
}
- static const ::rtl::OUString sAll = ::rtl::OUString::createFromAscii("%");
+ static const ::rtl::OUString sAll(RTL_CONSTASCII_USTRINGPARAM("%"));
Reference< XResultSet > xTables = m_xMetaData->getTables( Any(), sAll, sAll, aTableTypeFilter );
Reference< XRow > xCurrentRow( xTables, UNO_QUERY_THROW );
@@ -399,7 +393,6 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
m_bConstructed = sal_True;
}
- //------------------------------------------------------------------------------
void OFilteredContainer::disposing()
{
OCollection::disposing();
@@ -414,7 +407,6 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
m_bConstructed = sal_False;
}
- // -------------------------------------------------------------------------
void OFilteredContainer::impl_refresh() throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OFilteredContainer::impl_refresh" );
@@ -428,14 +420,12 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
}
}
- // -----------------------------------------------------------------------------
::rtl::OUString OFilteredContainer::getNameForObject(const ObjectType& _xObject)
{
OSL_ENSURE( _xObject.is(), "OFilteredContainer::getNameForObject: Object is NULL!" );
return ::dbtools::composeTableName( m_xMetaData, _xObject, ::dbtools::eInDataManipulation, false, false, false );
}
- // -----------------------------------------------------------------------------
// multiple to obtain all tables from XDatabaseMetaData::getTables, via passing a particular
// table type filter:
// adhere to the standard, which requests to pass a NULL table type filter, if
@@ -469,7 +459,7 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
switch ( nFilterMode )
{
default:
- OSL_ENSURE( sal_False, "OTableContainer::getAllTableTypeFilter: unknown TableTypeFilterMode!" );
+ OSL_FAIL( "OTableContainer::getAllTableTypeFilter: unknown TableTypeFilterMode!" );
case FILTER_MODE_MIX_ALL:
_rFilter.realloc( 3 );
_rFilter[0] = sView;
@@ -491,8 +481,5 @@ sal_Int32 createWildCardVector(Sequence< ::rtl::OUString >& _rTableFilter, ::std
}
}
-// ..............................................................................
} // namespace
-// ..............................................................................
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/HelperCollections.cxx b/dbaccess/source/core/api/HelperCollections.cxx
index 2e536b5c2e26..acc2d3ef337f 100644
--- a/dbaccess/source/core/api/HelperCollections.cxx
+++ b/dbaccess/source/core/api/HelperCollections.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,13 +28,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBA_HELPERCOLLECTIONS_HXX
#include "HelperCollections.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
namespace dbaccess
{
@@ -50,8 +47,8 @@ namespace dbaccess
using namespace ::com::sun::star::script;
using namespace ::cppu;
using namespace ::osl;
- // -----------------------------------------------------------------------------
- OPrivateColumns::OPrivateColumns(const ::vos::ORef< ::connectivity::OSQLColumns>& _rColumns,
+
+ OPrivateColumns::OPrivateColumns(const ::rtl::Reference< ::connectivity::OSQLColumns>& _rColumns,
sal_Bool _bCase,
::cppu::OWeakObject& _rParent,
::osl::Mutex& _rMutex,
@@ -62,8 +59,7 @@ namespace dbaccess
{
}
- // -------------------------------------------------------------------------
- OPrivateColumns* OPrivateColumns::createWithIntrinsicNames( const ::vos::ORef< ::connectivity::OSQLColumns >& _rColumns,
+ OPrivateColumns* OPrivateColumns::createWithIntrinsicNames( const ::rtl::Reference< ::connectivity::OSQLColumns >& _rColumns,
sal_Bool _bCase, ::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex )
{
::std::vector< ::rtl::OUString > aNames; aNames.reserve( _rColumns->get().size() );
@@ -81,7 +77,6 @@ namespace dbaccess
return new OPrivateColumns( _rColumns, _bCase, _rParent, _rMutex, aNames, sal_False );
}
- // -------------------------------------------------------------------------
void SAL_CALL OPrivateColumns::disposing(void)
{
m_aColumns = NULL;
@@ -90,10 +85,10 @@ namespace dbaccess
// So we're not allowed to dispose our elements.
OPrivateColumns_Base::disposing();
}
- // -------------------------------------------------------------------------
+
connectivity::sdbcx::ObjectType OPrivateColumns::createObject(const ::rtl::OUString& _rName)
{
- if ( m_aColumns.isValid() )
+ if ( m_aColumns.is() )
{
::connectivity::OSQLColumns::Vector::const_iterator aIter = find(m_aColumns->get().begin(),m_aColumns->get().end(),_rName,isCaseSensitive());
if(aIter == m_aColumns->get().end())
@@ -102,11 +97,11 @@ namespace dbaccess
if(aIter != m_aColumns->get().end())
return connectivity::sdbcx::ObjectType(*aIter,UNO_QUERY);
- OSL_ENSURE(0,"Column not found in collection!");
+ OSL_FAIL("Column not found in collection!");
}
return NULL;
}
- // -------------------------------------------------------------------------
+
connectivity::sdbcx::ObjectType OPrivateTables::createObject(const ::rtl::OUString& _rName)
{
if ( !m_aTables.empty() )
@@ -114,9 +109,11 @@ namespace dbaccess
OSQLTables::iterator aIter = m_aTables.find(_rName);
OSL_ENSURE(aIter != m_aTables.end(),"Table not found!");
OSL_ENSURE(aIter->second.is(),"Table is null!");
+ (void)aIter;
return connectivity::sdbcx::ObjectType(m_aTables.find(_rName)->second,UNO_QUERY);
}
return NULL;
}
- // -----------------------------------------------------------------------------
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/HelperCollections.hxx b/dbaccess/source/core/api/HelperCollections.hxx
index 1169a20b0750..f88024bc9b7a 100644
--- a/dbaccess/source/core/api/HelperCollections.hxx
+++ b/dbaccess/source/core/api/HelperCollections.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
#ifndef DBA_HELPERCOLLECTIONS_HXX
#define DBA_HELPERCOLLECTIONS_HXX
-#ifndef _CONNECTIVITY_SDBCX_COLLECTION_HXX_
#include "connectivity/sdbcx/VCollection.hxx"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBHELPER_DBCONVERSION_HXX_
#include <connectivity/dbconversion.hxx>
-#endif
-#ifndef _CONNECTIVITY_SDBCX_COLUMN_HXX_
#include <connectivity/PColumn.hxx>
-#endif
-#ifndef _VOS_REF_HXX_
-#include <vos/ref.hxx>
-#endif
+#include <rtl/ref.hxx>
namespace dbaccess
{
@@ -58,11 +49,11 @@ namespace dbaccess
using namespace ::com::sun::star::script;
using namespace ::cppu;
using namespace ::osl;
- // -----------------------------------------------------------------------------
+
typedef connectivity::sdbcx::OCollection OPrivateColumns_Base;
class OPrivateColumns : public OPrivateColumns_Base
{
- ::vos::ORef< ::connectivity::OSQLColumns> m_aColumns;
+ ::rtl::Reference< ::connectivity::OSQLColumns> m_aColumns;
protected:
virtual connectivity::sdbcx::ObjectType createObject(const ::rtl::OUString& _rName);
virtual void impl_refresh() throw(RuntimeException) {}
@@ -71,7 +62,7 @@ namespace dbaccess
return NULL;
}
public:
- OPrivateColumns(const ::vos::ORef< ::connectivity::OSQLColumns>& _rColumns,
+ OPrivateColumns(const ::rtl::Reference< ::connectivity::OSQLColumns>& _rColumns,
sal_Bool _bCase,
::cppu::OWeakObject& _rParent,
::osl::Mutex& _rMutex,
@@ -82,7 +73,7 @@ namespace dbaccess
/** creates a columns instance as above, but taking the names from the columns itself
*/
static OPrivateColumns* createWithIntrinsicNames(
- const ::vos::ORef< ::connectivity::OSQLColumns >& _rColumns,
+ const ::rtl::Reference< ::connectivity::OSQLColumns >& _rColumns,
sal_Bool _bCase,
::cppu::OWeakObject& _rParent,
::osl::Mutex& _rMutex
@@ -126,3 +117,5 @@ namespace dbaccess
};
}
#endif // DBA_HELPERCOLLECTIONS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/KeySet.cxx b/dbaccess/source/core/api/KeySet.cxx
index 21dc7d8443e6..f5e8e9c7df27 100644
--- a/dbaccess/source/core/api/KeySet.cxx
+++ b/dbaccess/source/core/api/KeySet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,85 +29,35 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_CORE_API_KEYSET_HXX
#include "KeySet.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HXX_
#include "core_resource.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HRC_
#include "core_resource.hrc"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#ifndef _COM_SUN_STAR_SDBC_XPREPAREDSTATEMENT_HPP_
#include <com/sun/star/sdbc/XPreparedStatement.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCxParameterS_HPP_
#include <com/sun/star/sdbc/XParameters.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XGENERATEDRESULTSET_HPP_
#include <com/sun/star/sdbc/XGeneratedResultSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCOLUMNLOCATE_HPP_
#include <com/sun/star/sdbc/XColumnLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XKEYSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XINDEXESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XIndexesSupplier.hpp>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_KEYTYPE_HPP_
#include <com/sun/star/sdbcx/KeyType.hpp>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
#include <list>
#include <algorithm>
#include <string.h>
-#ifndef _COM_SUN_STAR_IO_XINPUTSTREAM_HPP_
#include <com/sun/star/io/XInputStream.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef DBACCESS_CORE_API_QUERYCOMPOSER_HXX
#include "querycomposer.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_CORE_INC_COMPOSERTOOLS_HXX
#include "composertools.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#include <string.h>
#include <rtl/logfile.hxx>
#include "PrivateRow.hxx"
@@ -148,7 +99,7 @@ namespace
}
}
DBG_NAME(OKeySet)
-// -------------------------------------------------------------------------
+
OKeySet::OKeySet(const connectivity::OSQLTable& _xTable,
const Reference< XIndexAccess>& _xTableKeys,
const ::rtl::OUString& _rUpdateTableName, // this can be the alias or the full qualified name
@@ -173,20 +124,20 @@ OKeySet::OKeySet(const connectivity::OSQLTable& _xTable,
DBG_CTOR(OKeySet,NULL);
}
-// -----------------------------------------------------------------------------
+
OKeySet::~OKeySet()
{
try
{
::comphelper::disposeComponent(m_xStatement);
}
- catch(Exception&)
+ catch(const Exception&)
{
m_xStatement = NULL;
}
catch(...)
{
- OSL_ENSURE(0,"Unknown Exception occured");
+ OSL_FAIL("Unknown Exception occurred");
}
m_xComposer = NULL;
@@ -229,7 +180,7 @@ void OKeySet::findTableColumnsMatching_throw( const Any& i_aTable,
::rtl::OUString sUpdateTableName( i_rUpdateTableName );
if ( sUpdateTableName.getLength() == 0 )
{
- OSL_ENSURE( false, "OKeySet::findTableColumnsMatching_throw: This is a fallback only - it won't work when the table has an alias name." );
+ OSL_FAIL( "OKeySet::findTableColumnsMatching_throw: This is a fallback only - it won't work when the table has an alias name." );
// If i_aTable originates from a query composer, and is a table which appears with an alias in the SELECT statement,
// then the below code will not produce correct results.
// For instance, imagine a "SELECT alias.col FROM table AS alias". Now i_aTable would be the table named
@@ -272,7 +223,7 @@ void OKeySet::findTableColumnsMatching_throw( const Any& i_aTable,
}
::rtl::OUStringBuffer OKeySet::createKeyFilter()
{
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
const ::rtl::OUString aQuote = getIdentifierQuoteString();
::rtl::OUStringBuffer aFilter;
static ::rtl::OUString s_sDot(RTL_CONSTASCII_USTRINGPARAM("."));
@@ -292,7 +243,7 @@ void OKeySet::findTableColumnsMatching_throw( const Any& i_aTable,
}
return aFilter;
}
-// -----------------------------------------------------------------------------
+
void OKeySet::construct(const Reference< XResultSet>& _xDriverSet,const ::rtl::OUString& i_sRowSetFilter)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::construct" );
@@ -321,7 +272,7 @@ void OKeySet::construct(const Reference< XResultSet>& _xDriverSet,const ::rtl::O
const Sequence< ::rtl::OUString> aSeq = xSelectTables->getElementNames();
if ( aSeq.getLength() > 1 ) // special handling for join
{
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
const ::rtl::OUString aQuote = getIdentifierQuoteString();
static ::rtl::OUString s_sDot(RTL_CONSTASCII_USTRINGPARAM("."));
static ::rtl::OUString s_sParam(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
@@ -341,20 +292,17 @@ void OKeySet::construct(const Reference< XResultSet>& _xDriverSet,const ::rtl::O
for(SelectColumnsMetaData::iterator aPosIter = (*m_pForeignColumnNames).begin();aPosIter != aPosEnd;++aPosIter)
{
// look for columns not in the source columns to use them as filter as well
- // if ( !xSourceColumns->hasByName(aPosIter->first) )
- {
if ( aFilter.getLength() )
aFilter.append(aAnd);
aFilter.append(::dbtools::quoteName( aQuote,sSelectTableName));
aFilter.append(s_sDot);
aFilter.append(::dbtools::quoteName( aQuote,aPosIter->second.sRealName));
aFilter.append(s_sParam);
- }
}
break;
}
}
- } // if ( aSeq.getLength() > 1 ) // special handling for join
+ }
executeStatement(aFilter,i_sRowSetFilter,xAnalyzer);
}
void OKeySet::executeStatement(::rtl::OUStringBuffer& io_aFilter,const ::rtl::OUString& i_sRowSetFilter,Reference<XSingleSelectQueryComposer>& io_xAnalyzer)
@@ -380,7 +328,7 @@ void OKeySet::executeStatement(::rtl::OUStringBuffer& io_aFilter,const ::rtl::OU
for(;pAnd != pAndEnd;++pAnd)
{
::rtl::OUString sValue;
- if ( !(pAnd->Value >>= sValue) || !(sValue.equalsAscii("?") || sValue.matchAsciiL(":",1,0)) )
+ if ( !(pAnd->Value >>= sValue) || !(sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("?")) || sValue.matchAsciiL(":",1,0)) )
{ // we have a criteria which has to be taken into account for updates
m_aFilterColumns.push_back(pAnd->Name);
}
@@ -390,7 +338,7 @@ void OKeySet::executeStatement(::rtl::OUStringBuffer& io_aFilter,const ::rtl::OU
m_xStatement = m_xConnection->prepareStatement(io_xAnalyzer->getQueryWithSubstitution());
::comphelper::disposeComponent(io_xAnalyzer);
}
-// -------------------------------------------------------------------------
+
Any SAL_CALL OKeySet::getBookmark() throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getBookmark" );
@@ -399,7 +347,6 @@ Any SAL_CALL OKeySet::getBookmark() throw(SQLException, RuntimeException)
return makeAny(m_aKeyIter->first);
}
-// -------------------------------------------------------------------------
sal_Bool SAL_CALL OKeySet::moveToBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::moveToBookmark" );
@@ -407,7 +354,7 @@ sal_Bool SAL_CALL OKeySet::moveToBookmark( const Any& bookmark ) throw(SQLExcept
m_aKeyIter = m_aKeyMap.find(::comphelper::getINT32(bookmark));
return m_aKeyIter != m_aKeyMap.end();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::moveRelativeToBookmark( const Any& bookmark, sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::moveRelativeToBookmark" );
@@ -420,7 +367,7 @@ sal_Bool SAL_CALL OKeySet::moveRelativeToBookmark( const Any& bookmark, sal_Int3
return !isBeforeFirst() && !isAfterLast();
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OKeySet::compareBookmarks( const Any& _first, const Any& _second ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::compareBookmarks" );
@@ -430,19 +377,19 @@ sal_Int32 SAL_CALL OKeySet::compareBookmarks( const Any& _first, const Any& _sec
return (nFirst != nSecond) ? CompareBookmark::NOT_EQUAL : CompareBookmark::EQUAL;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::hasOrderedBookmarks( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::hasOrderedBookmarks" );
return sal_True;
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OKeySet::hashBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::hashBookmark" );
return ::comphelper::getINT32(bookmark);
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XDeleteRows
Sequence< sal_Int32 > SAL_CALL OKeySet::deleteRows( const Sequence< Any >& rows ,const connectivity::OSQLTable& _xTable) throw(SQLException, RuntimeException)
{
@@ -450,22 +397,22 @@ Sequence< sal_Int32 > SAL_CALL OKeySet::deleteRows( const Sequence< Any >& rows
Reference<XPropertySet> xSet(_xTable,UNO_QUERY);
fillTableName(xSet);
- ::rtl::OUStringBuffer aSql = ::rtl::OUString::createFromAscii("DELETE FROM ");
+ ::rtl::OUStringBuffer aSql = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DELETE FROM "));
aSql.append(m_aComposedTableName);
- aSql.append(::rtl::OUString::createFromAscii(" WHERE "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" WHERE ")));
// list all cloumns that should be set
const ::rtl::OUString aQuote = getIdentifierQuoteString();
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
- static ::rtl::OUString aOr = ::rtl::OUString::createFromAscii(" OR ");
- static ::rtl::OUString aEqual = ::rtl::OUString::createFromAscii(" = ?");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
+ static ::rtl::OUString aOr(RTL_CONSTASCII_USTRINGPARAM(" OR "));
+ static ::rtl::OUString aEqual(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
// use keys and indexes for excat postioning
// first the keys
Reference<XNameAccess> xKeyColumns = getKeyColumns();
- ::rtl::OUStringBuffer aCondition = ::rtl::OUString::createFromAscii("( ");
+ ::rtl::OUStringBuffer aCondition = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("( "));
SelectColumnsMetaData::const_iterator aIter = (*m_pKeyColumnNames).begin();
SelectColumnsMetaData::const_iterator aPosEnd = (*m_pKeyColumnNames).end();
@@ -531,20 +478,20 @@ Sequence< sal_Int32 > SAL_CALL OKeySet::deleteRows( const Sequence< Any >& rows
}
return aRet;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OKeySet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrginalRow,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::updateRow" );
Reference<XPropertySet> xSet(_xTable,UNO_QUERY);
fillTableName(xSet);
- ::rtl::OUStringBuffer aSql = ::rtl::OUString::createFromAscii("UPDATE ");
+ ::rtl::OUStringBuffer aSql = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UPDATE "));
aSql.append(m_aComposedTableName);
- aSql.append(::rtl::OUString::createFromAscii(" SET "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" SET ")));
// list all cloumns that should be set
- static ::rtl::OUString aPara = ::rtl::OUString::createFromAscii(" = ?,");
+ static ::rtl::OUString aPara(RTL_CONSTASCII_USTRINGPARAM(" = ?,"));
::rtl::OUString aQuote = getIdentifierQuoteString();
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
::rtl::OUString sIsNull(RTL_CONSTASCII_USTRINGPARAM(" IS NULL"));
::rtl::OUString sParam(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
@@ -573,7 +520,6 @@ void SAL_CALL OKeySet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow
SelectColumnsMetaData::const_iterator aEnd = m_pColumnNames->end();
for(;aIter != aEnd;++aIter,++i)
{
- //if(xKeyColumns.is() && xKeyColumns->hasByName(aIter->first))
if ( m_pKeyColumnNames->find(aIter->first) != m_pKeyColumnNames->end() )
{
sKeyCondition.append(::dbtools::quoteName( aQuote,aIter->second.sRealName));
@@ -620,7 +566,7 @@ void SAL_CALL OKeySet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow
if(sKeyCondition.getLength() || sIndexCondition.getLength())
{
- aSql.append(::rtl::OUString::createFromAscii(" WHERE "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" WHERE ")));
if(sKeyCondition.getLength() && sIndexCondition.getLength())
{
aSql.append(sKeyCondition.makeStringAndClear());
@@ -640,11 +586,10 @@ void SAL_CALL OKeySet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow
::dbtools::throwSQLException( DBACORE_RESSTRING( RID_STR_NO_CONDITION_FOR_PK ), SQL_GENERAL_ERROR, m_xConnection );
// now create end execute the prepared statement
-
::rtl::OUString sEmpty;
executeUpdate(_rInsertRow ,_rOrginalRow,aSql.makeStringAndClear(),sEmpty,aIndexColumnPositions);
}
-// -----------------------------------------------------------------------------
+
void OKeySet::executeUpdate(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrginalRow,const ::rtl::OUString& i_sSQL,const ::rtl::OUString& i_sTableName,const ::std::vector<sal_Int32>& _aIndexColumnPositions)
{
// now create end execute the prepared statement
@@ -710,16 +655,16 @@ void OKeySet::executeUpdate(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rO
tryRefetch(_rInsertRow,bRefetch);
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OKeySet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::insertRow" );
- ::rtl::OUStringBuffer aSql(::rtl::OUString::createFromAscii("INSERT INTO "));
+ ::rtl::OUStringBuffer aSql(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("INSERT INTO ")));
Reference<XPropertySet> xSet(_xTable,UNO_QUERY);
fillTableName(xSet);
aSql.append(m_aComposedTableName);
- aSql.append(::rtl::OUString::createFromAscii(" ( "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" ( ")));
// set values and column names
::rtl::OUStringBuffer aValues(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" VALUES ( ")));
static ::rtl::OUString aPara(RTL_CONSTASCII_USTRINGPARAM("?,"));
@@ -755,7 +700,7 @@ void SAL_CALL OKeySet::insertRow( const ORowSetRow& _rInsertRow,const connectivi
::rtl::OUString sEmpty;
executeInsert(_rInsertRow,aSql.makeStringAndClear(),sEmpty,bRefetch);
}
-// -------------------------------------------------------------------------
+
void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const ::rtl::OUString& i_sSQL,const ::rtl::OUString& i_sTableName,bool bRefetch )
{
// now create,fill and execute the prepared statement
@@ -821,9 +766,9 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const ::rtl::OUString
}
}
}
- catch(Exception&)
+ catch(const Exception&)
{
- OSL_ENSURE(0,"Could not execute GeneratedKeys() stmt");
+ OSL_FAIL("Could not execute GeneratedKeys() stmt");
}
}
@@ -854,10 +799,10 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const ::rtl::OUString
if(sMaxStmt.getLength())
{
- sMaxStmt = sMaxStmt.replaceAt(sMaxStmt.getLength()-1,1,::rtl::OUString::createFromAscii(" "));
- ::rtl::OUString sStmt = ::rtl::OUString::createFromAscii("SELECT ");
+ sMaxStmt = sMaxStmt.replaceAt(sMaxStmt.getLength()-1,1,::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" ")));
+ ::rtl::OUString sStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT "));
sStmt += sMaxStmt;
- sStmt += ::rtl::OUString::createFromAscii("FROM ");
+ sStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FROM "));
::rtl::OUString sCatalog,sSchema,sTable;
::dbtools::qualifiedNameComponents(m_xConnection->getMetaData(),m_sUpdateTableName,sCatalog,sSchema,sTable,::dbtools::eInDataManipulation);
sStmt += ::dbtools::composeTableNameForSelect( m_xConnection, sCatalog, sSchema, sTable );
@@ -882,7 +827,7 @@ void OKeySet::executeInsert( const ORowSetRow& _rInsertRow,const ::rtl::OUString
}
catch(SQLException&)
{
- OSL_ENSURE(0,"Could not fetch with MAX() ");
+ OSL_FAIL("Could not fetch with MAX() ");
}
}
}
@@ -943,7 +888,7 @@ void OKeySet::tryRefetch(const ORowSetRow& _rInsertRow,bool bRefetch)
OSL_ENSURE(m_xSet.is(),"No resultset form statement!");
bRefetch = m_xSet->next();
}
- catch(Exception)
+ catch(const Exception&)
{
bRefetch = false;
}
@@ -953,7 +898,7 @@ void OKeySet::tryRefetch(const ORowSetRow& _rInsertRow,bool bRefetch)
m_aKeyIter->second.second.second = new OPrivateRow(_rInsertRow->get());
}
}
-// -----------------------------------------------------------------------------
+
void OKeySet::copyRowValue(const ORowSetRow& _rInsertRow,ORowSetRow& _rKeyRow,sal_Int32 i_nBookmark)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::copyRowValue" );
@@ -993,20 +938,20 @@ void OKeySet::copyRowValue(const ORowSetRow& _rInsertRow,ORowSetRow& _rKeyRow,sa
aIter->setTypeKind(aPosIter->second.nType);
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OKeySet::deleteRow(const ORowSetRow& _rDeleteRow,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::deleteRow" );
Reference<XPropertySet> xSet(_xTable,UNO_QUERY);
fillTableName(xSet);
- ::rtl::OUStringBuffer aSql = ::rtl::OUString::createFromAscii("DELETE FROM ");
+ ::rtl::OUStringBuffer aSql = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DELETE FROM "));
aSql.append(m_aComposedTableName);
- aSql.append(::rtl::OUString::createFromAscii(" WHERE "));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" WHERE ")));
// list all cloumns that should be set
::rtl::OUString aQuote = getIdentifierQuoteString();
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
// use keys and indexes for excat postioning
Reference<XNameAccess> xKeyColumns = getKeyColumns();
@@ -1034,11 +979,11 @@ void SAL_CALL OKeySet::deleteRow(const ORowSetRow& _rDeleteRow,const connectivit
aSql.append(::dbtools::quoteName( aQuote,aIter->second.sRealName));
if((_rDeleteRow->get())[aIter->second.nPosition].isNull())
{
- OSL_ENSURE(0,"can a primary key be null");
- aSql.append(::rtl::OUString::createFromAscii(" IS NULL"));
+ OSL_FAIL("can a primary key be null");
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" IS NULL")));
}
else
- aSql.append(::rtl::OUString::createFromAscii(" = ?"));
+ aSql.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" = ?")));
aSql.append(aAnd);
}
else
@@ -1051,10 +996,10 @@ void SAL_CALL OKeySet::deleteRow(const ORowSetRow& _rDeleteRow,const connectivit
{
sIndexCondition.append(::dbtools::quoteName( aQuote,aIter->second.sRealName));
if((_rDeleteRow->get())[aIter->second.nPosition].isNull())
- sIndexCondition.append(::rtl::OUString::createFromAscii(" IS NULL"));
+ sIndexCondition.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" IS NULL")));
else
{
- sIndexCondition.append(::rtl::OUString::createFromAscii(" = ?"));
+ sIndexCondition.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" = ?")));
aIndexColumnPositions.push_back(aIter->second.nPosition);
}
sIndexCondition.append(aAnd);
@@ -1099,23 +1044,23 @@ void SAL_CALL OKeySet::deleteRow(const ORowSetRow& _rDeleteRow,const connectivit
m_bDeleted = sal_True;
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OKeySet::cancelRowUpdates( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::cancelRowUpdates" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OKeySet::moveToInsertRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::moveToInsertRow" );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OKeySet::moveToCurrentRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::moveToCurrentRow" );
}
-// -------------------------------------------------------------------------
+
Reference<XNameAccess> OKeySet::getKeyColumns() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getKeyColumns" );
@@ -1156,7 +1101,7 @@ Reference<XNameAccess> OKeySet::getKeyColumns() const
return xKeyColumns;
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::next( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::next" );
@@ -1182,19 +1127,19 @@ sal_Bool SAL_CALL OKeySet::next( ) throw(SQLException, RuntimeException)
refreshRow();
return !isAfterLast();
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::isBeforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::isBeforeFirst" );
return m_aKeyIter == m_aKeyMap.begin();
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::isAfterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::isAfterLast" );
return m_bRowCountFinal && m_aKeyIter == m_aKeyMap.end();
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::isFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::isFirst" );
@@ -1202,7 +1147,7 @@ sal_Bool SAL_CALL OKeySet::isFirst( ) throw(SQLException, RuntimeException)
++aTemp;
return m_aKeyIter == aTemp && m_aKeyIter != m_aKeyMap.end();
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::isLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::isLast" );
@@ -1213,7 +1158,7 @@ sal_Bool SAL_CALL OKeySet::isLast( ) throw(SQLException, RuntimeException)
--aTemp;
return m_aKeyIter == aTemp;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OKeySet::beforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::beforeFirst" );
@@ -1222,7 +1167,7 @@ void SAL_CALL OKeySet::beforeFirst( ) throw(SQLException, RuntimeException)
m_xRow = NULL;
::comphelper::disposeComponent(m_xSet);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OKeySet::afterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::afterLast" );
@@ -1232,7 +1177,7 @@ void SAL_CALL OKeySet::afterLast( ) throw(SQLException, RuntimeException)
m_xRow = NULL;
::comphelper::disposeComponent(m_xSet);
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::first( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::first" );
@@ -1245,7 +1190,7 @@ sal_Bool SAL_CALL OKeySet::first( ) throw(SQLException, RuntimeException)
refreshRow();
return m_aKeyIter != m_aKeyMap.end() && m_aKeyIter != m_aKeyMap.begin();
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::last( ) throw(SQLException, RuntimeException)
{
return last_checked(sal_True);
@@ -1263,7 +1208,7 @@ sal_Bool OKeySet::last_checked( sal_Bool i_bFetchRow)
refreshRow();
return m_aKeyIter != m_aKeyMap.end() && m_aKeyIter != m_aKeyMap.begin();
}
-// -----------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OKeySet::getRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getRow" );
@@ -1272,7 +1217,7 @@ sal_Int32 SAL_CALL OKeySet::getRow( ) throw(SQLException, RuntimeException)
return ::std::distance(m_aKeyMap.begin(),m_aKeyIter);
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::absolute( sal_Int32 row ) throw(SQLException, RuntimeException)
{
return absolute_checked(row,sal_True);
@@ -1320,7 +1265,7 @@ sal_Bool OKeySet::absolute_checked( sal_Int32 row,sal_Bool i_bFetchRow )
return m_aKeyIter != m_aKeyMap.end() && m_aKeyIter != m_aKeyMap.begin();
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::relative( sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::relative" );
@@ -1331,7 +1276,7 @@ sal_Bool SAL_CALL OKeySet::relative( sal_Int32 rows ) throw(SQLException, Runtim
}
return absolute(getRow()+rows);
}
-// -----------------------------------------------------------------------------
+
sal_Bool OKeySet::previous_checked( sal_Bool i_bFetchRow )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::previous" );
@@ -1344,7 +1289,6 @@ sal_Bool OKeySet::previous_checked( sal_Bool i_bFetchRow )
}
return m_aKeyIter != m_aKeyMap.begin();
}
-// -----------------------------------------------------------------------------
sal_Bool SAL_CALL OKeySet::previous( ) throw(SQLException, RuntimeException)
{
return previous_checked(sal_True);
@@ -1418,7 +1362,7 @@ void SAL_CALL OKeySet::refreshRow() throw(SQLException, RuntimeException)
OSL_ENSURE(m_xRow.is(),"No row form statement!");
}
}
-// -----------------------------------------------------------------------------
+
sal_Bool OKeySet::fetchRow()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::fetchRow" );
@@ -1452,7 +1396,7 @@ sal_Bool OKeySet::fetchRow()
m_bRowCountFinal = sal_True;
return bRet;
}
-// -------------------------------------------------------------------------
+
void OKeySet::fillAllRows()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::fillAllRows" );
@@ -1468,152 +1412,152 @@ sal_Bool SAL_CALL OKeySet::wasNull( ) throw(SQLException, RuntimeException)
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::wasNull" );
return m_xRow->wasNull();
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OKeySet::getString( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getString" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getString(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::getBoolean( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getBoolean" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getBoolean(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int8 SAL_CALL OKeySet::getByte( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getByte" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getByte(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int16 SAL_CALL OKeySet::getShort( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getShort" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getShort(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OKeySet::getInt( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getInt" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getInt(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int64 SAL_CALL OKeySet::getLong( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getLong" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getLong(columnIndex);
}
-// -------------------------------------------------------------------------
+
float SAL_CALL OKeySet::getFloat( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getFloat" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getFloat(columnIndex);
}
-// -------------------------------------------------------------------------
+
double SAL_CALL OKeySet::getDouble( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getDouble" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getDouble(columnIndex);
}
-// -------------------------------------------------------------------------
+
Sequence< sal_Int8 > SAL_CALL OKeySet::getBytes( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getBytes" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getBytes(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Date SAL_CALL OKeySet::getDate( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getDate" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getDate(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Time SAL_CALL OKeySet::getTime( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getTime" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getTime(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::DateTime SAL_CALL OKeySet::getTimestamp( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getTimestamp" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getTimestamp(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL OKeySet::getBinaryStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getBinaryStream" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getBinaryStream(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL OKeySet::getCharacterStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getCharacterStream" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getCharacterStream(columnIndex);
}
-// -------------------------------------------------------------------------
+
Any SAL_CALL OKeySet::getObject( sal_Int32 columnIndex, const Reference< ::com::sun::star::container::XNameAccess >& typeMap ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getObject" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getObject(columnIndex,typeMap);
}
-// -------------------------------------------------------------------------
+
Reference< XRef > SAL_CALL OKeySet::getRef( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getRef" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getRef(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< XBlob > SAL_CALL OKeySet::getBlob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getBlob" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getBlob(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< XClob > SAL_CALL OKeySet::getClob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getClob" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getClob(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< XArray > SAL_CALL OKeySet::getArray( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::getArray" );
OSL_ENSURE(m_xRow.is(),"m_xRow is null!");
return m_xRow->getArray(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::rowUpdated( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::rowUpdated" );
return m_aKeyIter != m_aKeyMap.begin() && m_aKeyIter != m_aKeyMap.end() && m_aKeyIter->second.second.first == 2;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::rowInserted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::rowInserted" );
return m_aKeyIter != m_aKeyMap.begin() && m_aKeyIter != m_aKeyMap.end() && m_aKeyIter->second.second.first == 1;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OKeySet::rowDeleted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OKeySet::rowDeleted" );
@@ -1621,7 +1565,7 @@ sal_Bool SAL_CALL OKeySet::rowDeleted( ) throw(SQLException, RuntimeException)
m_bDeleted = sal_False;
return bDeleted;
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OKeySet::getComposedTableName(const ::rtl::OUString& _sCatalog,
const ::rtl::OUString& _sSchema,
const ::rtl::OUString& _sTable)
@@ -1654,7 +1598,7 @@ sal_Bool SAL_CALL OKeySet::rowDeleted( ) throw(SQLException, RuntimeException)
return aComposedName;
}
-// -----------------------------------------------------------------------------
+
namespace dbaccess
{
@@ -1721,7 +1665,7 @@ void getColumnPositions(const Reference<XNameAccess>& _rxQueryColumns,
}
}
}
-// -----------------------------------------------------------------------------
+
void OKeySet::impl_convertValue_throw(const ORowSetRow& _rInsertRow,const SelectColumnDescription& i_aMetaData)
{
ORowSetValue& aValue((_rInsertRow->get())[i_aMetaData.nPosition]);
@@ -1742,5 +1686,4 @@ void OKeySet::impl_convertValue_throw(const ORowSetRow& _rInsertRow,const Select
break;
}
}
-// -----------------------------------------------------------------------------
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/KeySet.hxx b/dbaccess/source/core/api/KeySet.hxx
index 2f9d1b002cb1..22a56da716a4 100644
--- a/dbaccess/source/core/api/KeySet.hxx
+++ b/dbaccess/source/core/api/KeySet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,16 @@
#ifndef DBACCESS_CORE_API_KEYSET_HXX
#define DBACCESS_CORE_API_KEYSET_HXX
-#ifndef DBACCESS_CORE_API_CACHESET_HXX
#include "CacheSet.hxx"
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
#include <memory>
#include <map>
-#ifndef _COM_SUN_STAR_LANG_XUNOTUNNEL_HPP_
#include <com/sun/star/lang/XUnoTunnel.hpp>
-#endif
#include <com/sun/star/sdb/XSingleSelectQueryAnalyzer.hpp>
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
namespace dbaccess
{
@@ -59,8 +52,6 @@ namespace dbaccess
sal_Int32 nScale;
sal_Bool bNullable;
-
-
SelectColumnDescription()
:nPosition( 0 )
,nType( 0 )
@@ -210,17 +201,17 @@ namespace dbaccess
virtual void SAL_CALL refreshRow( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
// ::com::sun::star::sdbcx::XRowLocate
virtual ::com::sun::star::uno::Any SAL_CALL getBookmark() throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
- // -------------------------------------------------------------------------
+
virtual sal_Bool SAL_CALL moveToBookmark( const ::com::sun::star::uno::Any& bookmark ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
- // -------------------------------------------------------------------------
+
virtual sal_Bool SAL_CALL moveRelativeToBookmark( const ::com::sun::star::uno::Any& bookmark, sal_Int32 rows ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
- // -------------------------------------------------------------------------
+
virtual sal_Int32 SAL_CALL compareBookmarks( const ::com::sun::star::uno::Any& first, const ::com::sun::star::uno::Any& second ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
- // -------------------------------------------------------------------------
+
virtual sal_Bool SAL_CALL hasOrderedBookmarks( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
- // -------------------------------------------------------------------------
+
virtual sal_Int32 SAL_CALL hashBookmark( const ::com::sun::star::uno::Any& bookmark ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
- // -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XDeleteRows
virtual ::com::sun::star::uno::Sequence< sal_Int32 > SAL_CALL deleteRows( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& rows ,const connectivity::OSQLTable& _xTable) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
// ::com::sun::star::sdbc::XResultSetUpdate
@@ -239,3 +230,4 @@ namespace dbaccess
}
#endif // DBACCESS_CORE_API_KEYSET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/OptimisticSet.cxx b/dbaccess/source/core/api/OptimisticSet.cxx
index 2637a4f6bea6..7255a470fb2e 100644
--- a/dbaccess/source/core/api/OptimisticSet.cxx
+++ b/dbaccess/source/core/api/OptimisticSet.cxx
@@ -1,3 +1,5 @@
+
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +8,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: OptimisticSet.cxx,v $
- * $Revision: 1.73 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -98,7 +97,7 @@ namespace
}
DBG_NAME(OptimisticSet)
-// -------------------------------------------------------------------------
+
OptimisticSet::OptimisticSet(const ::comphelper::ComponentContext& _rContext,
const Reference< XConnection>& i_xConnection,
const Reference< XSingleSelectQueryAnalyzer >& _xComposer,
@@ -113,12 +112,12 @@ OptimisticSet::OptimisticSet(const ::comphelper::ComponentContext& _rContext,
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OptimisticSet::OptimisticSet" );
DBG_CTOR(OptimisticSet,NULL);
}
-// -----------------------------------------------------------------------------
+
OptimisticSet::~OptimisticSet()
{
DBG_DTOR(OptimisticSet,NULL);
}
-// -----------------------------------------------------------------------------
+
void OptimisticSet::construct(const Reference< XResultSet>& _xDriverSet,const ::rtl::OUString& i_sRowSetFilter)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OptimisticSet::construct" );
@@ -174,23 +173,23 @@ void OptimisticSet::construct(const Reference< XResultSet>& _xDriverSet,const ::
m_xStatement = m_xConnection->prepareStatement(xAnalyzer->getQueryWithSubstitution());
::comphelper::disposeComponent(xAnalyzer);
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XDeleteRows
Sequence< sal_Int32 > SAL_CALL OptimisticSet::deleteRows( const Sequence< Any >& /*rows*/ ,const connectivity::OSQLTable& /*_xTable*/) throw(SQLException, RuntimeException)
{
Sequence< sal_Int32 > aRet;
return aRet;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OptimisticSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrginalRow,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OptimisticSet::updateRow" );
if ( m_aJoinedKeyColumns.empty() )
throw SQLException();
// list all cloumns that should be set
- static ::rtl::OUString s_sPara = ::rtl::OUString::createFromAscii(" = ?");
+ static ::rtl::OUString s_sPara(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
::rtl::OUString aQuote = getIdentifierQuoteString();
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
::rtl::OUString sIsNull(RTL_CONSTASCII_USTRINGPARAM(" IS NULL"));
::rtl::OUString sParam(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
@@ -201,7 +200,6 @@ void SAL_CALL OptimisticSet::updateRow(const ORowSetRow& _rInsertRow ,const ORow
TSQLStatements aIndexConditions;
TSQLStatements aSql;
- // sal_Int32 i = 1;
// here we build the condition part for the update statement
SelectColumnsMetaData::const_iterator aIter = m_pColumnNames->begin();
SelectColumnsMetaData::const_iterator aEnd = m_pColumnNames->end();
@@ -258,10 +256,8 @@ void SAL_CALL OptimisticSet::updateRow(const ORowSetRow& _rInsertRow ,const ORow
sSql.append(s_sSET);
sSql.append(aSqlIter->second);
::rtl::OUStringBuffer& rCondition = aKeyConditions[aSqlIter->first];
- bool bAddWhere = true;
if ( rCondition.getLength() )
{
- bAddWhere = false;
sSql.appendAscii(" WHERE ");
sSql.append( rCondition );
}
@@ -269,7 +265,7 @@ void SAL_CALL OptimisticSet::updateRow(const ORowSetRow& _rInsertRow ,const ORow
}
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OptimisticSet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OptimisticSet::insertRow" );
@@ -278,7 +274,7 @@ void SAL_CALL OptimisticSet::insertRow( const ORowSetRow& _rInsertRow,const conn
TSQLStatements aKeyConditions;
::std::map< ::rtl::OUString,bool > aResultSetChanged;
::rtl::OUString aQuote = getIdentifierQuoteString();
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
::rtl::OUString sIsNull(RTL_CONSTASCII_USTRINGPARAM(" IS NULL"));
::rtl::OUString sParam(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
@@ -380,7 +376,7 @@ void SAL_CALL OptimisticSet::insertRow( const ORowSetRow& _rInsertRow,const conn
}
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OptimisticSet::deleteRow(const ORowSetRow& _rDeleteRow,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
::rtl::OUString sParam(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
@@ -394,7 +390,6 @@ void SAL_CALL OptimisticSet::deleteRow(const ORowSetRow& _rDeleteRow,const conne
TSQLStatements aIndexConditions;
TSQLStatements aSql;
- // sal_Int32 i = 1;
// here we build the condition part for the update statement
SelectColumnsMetaData::const_iterator aIter = m_pColumnNames->begin();
SelectColumnsMetaData::const_iterator aEnd = m_pColumnNames->end();
@@ -426,12 +421,12 @@ void SAL_CALL OptimisticSet::deleteRow(const ORowSetRow& _rDeleteRow,const conne
}
}
}
-// -------------------------------------------------------------------------
+
void OptimisticSet::executeDelete(const ORowSetRow& _rDeleteRow,const ::rtl::OUString& i_sSQL,const ::rtl::OUString& i_sTableName)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OptimisticSet::executeDelete" );
- // now create end execute the prepared statement
+ // now create and execute the prepared statement
Reference< XPreparedStatement > xPrep(m_xConnection->prepareStatement(i_sSQL));
Reference< XParameters > xParameter(xPrep,UNO_QUERY);
@@ -454,41 +449,17 @@ void OptimisticSet::executeDelete(const ORowSetRow& _rDeleteRow,const ::rtl::OUS
m_bDeleted = sal_True;
}
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OptimisticSet::getComposedTableName(const ::rtl::OUString& /*_sCatalog*/,
const ::rtl::OUString& /*_sSchema*/,
const ::rtl::OUString& /*_sTable*/)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OptimisticSet::getComposedTableName" );
::rtl::OUString aComposedName;
-/*
- Reference<XDatabaseMetaData> xMetaData = m_xConnection->getMetaData();
- if( xMetaData.is() && xMetaData->supportsTableCorrelationNames() )
- {
- aComposedName = ::dbtools::composeTableName( xMetaData, _sCatalog, _sSchema, _sTable, sal_False, ::dbtools::eInDataManipulation );
- // first we have to check if the composed tablename is in the select clause or if an alias is used
- Reference<XTablesSupplier> xTabSup(m_xComposer,UNO_QUERY);
- Reference<XNameAccess> xSelectTables = xTabSup->getTables();
- OSL_ENSURE(xSelectTables.is(),"No Select tables!");
- if(xSelectTables.is())
- {
- if(!xSelectTables->hasByName(aComposedName))
- { // the composed name isn't used in the select clause so we have to find out which name is used instead
- ::rtl::OUString sCatalog,sSchema,sTable;
- ::dbtools::qualifiedNameComponents(xMetaData,m_sUpdateTableName,sCatalog,sSchema,sTable,::dbtools::eInDataManipulation);
- aComposedName = ::dbtools::composeTableNameForSelect( m_xConnection, sCatalog, sSchema, sTable );
- }
- else
- aComposedName = ::dbtools::composeTableNameForSelect( m_xConnection, _sCatalog, _sSchema, _sTable );
- }
- }
- else
- aComposedName = ::dbtools::composeTableNameForSelect( m_xConnection, _sCatalog, _sSchema, _sTable );
-*/
return aComposedName;
}
-// -----------------------------------------------------------------------------
+
void OptimisticSet::fillJoinedColumns_throw(const ::std::vector< TNodePair >& i_aJoinColumns)
{
::std::vector< TNodePair >::const_iterator aIter = i_aJoinColumns.begin();
@@ -507,7 +478,7 @@ void OptimisticSet::fillJoinedColumns_throw(const ::std::vector< TNodePair >& i_
fillJoinedColumns_throw(sLeft.makeStringAndClear(),sRight.makeStringAndClear());
}
}
-// -----------------------------------------------------------------------------
+
void OptimisticSet::fillJoinedColumns_throw(const ::rtl::OUString& i_sLeftColumn,const ::rtl::OUString& i_sRightColumn)
{
sal_Int32 nLeft = 0,nRight = 0;
@@ -547,14 +518,14 @@ void OptimisticSet::fillJoinedColumns_throw(const ::rtl::OUString& i_sLeftColumn
else
m_aJoinedColumns[nRight] = nLeft;
}
-// -----------------------------------------------------------------------------
+
bool OptimisticSet::isResultSetChanged() const
{
bool bOld = m_bResultSetChanged;
m_bResultSetChanged = false;
return bOld;
}
-// -----------------------------------------------------------------------------
+
void OptimisticSet::reset(const Reference< XResultSet>& _xDriverSet)
{
OCacheSet::construct(_xDriverSet,::rtl::OUString());
@@ -563,7 +534,7 @@ void OptimisticSet::reset(const Reference< XResultSet>& _xDriverSet)
m_aKeyMap.insert(OKeySetMatrix::value_type(0,OKeySetValue(NULL,::std::pair<sal_Int32,Reference<XRow> >(0,NULL))));
m_aKeyIter = m_aKeyMap.begin();
}
-// -----------------------------------------------------------------------------
+
void OptimisticSet::mergeColumnValues(sal_Int32 i_nColumnIndex,ORowSetValueVector::Vector& io_aInsertRow,ORowSetValueVector::Vector& io_aRow,::std::vector<sal_Int32>& o_aChangedColumns)
{
o_aChangedColumns.push_back(i_nColumnIndex);
@@ -605,7 +576,7 @@ namespace
}
};
}
-// -----------------------------------------------------------------------------
+
bool OptimisticSet::updateColumnValues(const ORowSetValueVector::Vector& io_aCachedRow,ORowSetValueVector::Vector& io_aRow,const ::std::vector<sal_Int32>& i_aChangedColumns)
{
bool bRet = false;
@@ -642,7 +613,7 @@ bool OptimisticSet::updateColumnValues(const ORowSetValueVector::Vector& io_aCac
}
return bRet;
}
-// -----------------------------------------------------------------------------
+
bool OptimisticSet::columnValuesUpdated(ORowSetValueVector::Vector& o_aCachedRow,const ORowSetValueVector::Vector& i_aRow)
{
bool bRet = false;
@@ -681,14 +652,14 @@ bool OptimisticSet::columnValuesUpdated(ORowSetValueVector::Vector& o_aCachedRow
}
return bRet;
}
-// -----------------------------------------------------------------------------
+
void OptimisticSet::fillMissingValues(ORowSetValueVector::Vector& io_aRow) const
{
TSQLStatements aSql;
TSQLStatements aKeyConditions;
::std::map< ::rtl::OUString,bool > aResultSetChanged;
::rtl::OUString aQuote = getIdentifierQuoteString();
- static ::rtl::OUString aAnd = ::rtl::OUString::createFromAscii(" AND ");
+ static ::rtl::OUString aAnd(RTL_CONSTASCII_USTRINGPARAM(" AND "));
::rtl::OUString sIsNull(RTL_CONSTASCII_USTRINGPARAM(" IS NULL"));
::rtl::OUString sParam(RTL_CONSTASCII_USTRINGPARAM(" = ?"));
// here we build the condition part for the update statement
@@ -765,5 +736,4 @@ void OptimisticSet::fillMissingValues(ORowSetValueVector::Vector& io_aRow) const
}
}
}
-// -----------------------------------------------------------------------------
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/OptimisticSet.hxx b/dbaccess/source/core/api/OptimisticSet.hxx
index f3b75e08ed5b..4e44de65681a 100644
--- a/dbaccess/source/core/api/OptimisticSet.hxx
+++ b/dbaccess/source/core/api/OptimisticSet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: KeySet.hxx,v $
- * $Revision: 1.30 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -53,7 +51,6 @@ namespace dbaccess
::std::map<sal_Int32,sal_Int32> m_aJoinedColumns;
::std::map<sal_Int32,sal_Int32> m_aJoinedKeyColumns;
-
mutable bool m_bResultSetChanged;
/**
@@ -86,7 +83,6 @@ namespace dbaccess
// late ctor which can throw exceptions
virtual void construct(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSet>& _xDriverSet,const ::rtl::OUString& i_sRowSetFilter);
- // -------------------------------------------------------------------------
// ::com::sun::star::sdbcx::XDeleteRows
virtual ::com::sun::star::uno::Sequence< sal_Int32 > SAL_CALL deleteRows( const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& rows ,const connectivity::OSQLTable& _xTable) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
// ::com::sun::star::sdbc::XResultSetUpdate
@@ -109,3 +105,4 @@ namespace dbaccess
}
#endif // DBACCESS_CORE_API_OPTIMISTICSET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/PrivateRow.cxx b/dbaccess/source/core/api/PrivateRow.cxx
index 939e335b4cb3..05eed3b2b687 100644
--- a/dbaccess/source/core/api/PrivateRow.cxx
+++ b/dbaccess/source/core/api/PrivateRow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -140,3 +141,4 @@ using namespace ::com::sun::star;
return Reference< XArray >(m_aRow[m_nPos].makeAny(),UNO_QUERY);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/PrivateRow.hxx b/dbaccess/source/core/api/PrivateRow.hxx
index 82dd97232c92..e03e8dcdc363 100644
--- a/dbaccess/source/core/api/PrivateRow.hxx
+++ b/dbaccess/source/core/api/PrivateRow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: OptimisticSet.cxx,v $
- * $Revision: 1.73 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -67,3 +65,5 @@ namespace dbaccess
};
} // dbaccess
#endif // PRIVATE_ROW_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSet.cxx b/dbaccess/source/core/api/RowSet.cxx
index 38220bcade48..8e88f4ef8a8c 100644
--- a/dbaccess/source/core/api/RowSet.cxx
+++ b/dbaccess/source/core/api/RowSet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,6 +41,7 @@
#include "core_resource.hrc"
#include "core_resource.hxx"
#include "tablecontainer.hxx"
+#include "dbastrings.hrc"
/** === begin UNO includes === **/
#include <com/sun/star/beans/PropertyAttribute.hpp>
@@ -102,12 +104,10 @@ using namespace ::com::sun::star::util;
using namespace ::cppu;
using namespace ::osl;
-//--------------------------------------------------------------------------
extern "C" void SAL_CALL createRegistryInfo_ORowSet()
{
static ::dba::OAutoRegistration< ORowSet > aAutoRegistration;
}
-// -----------------------------------------------------------------------------
#define NOTIFY_LISTERNERS_CHECK(_rListeners,T,method) \
Sequence< Reference< XInterface > > aListenerSeq = _rListeners.getElements(); \
@@ -134,16 +134,14 @@ extern "C" void SAL_CALL createRegistryInfo_ORowSet()
_rGuard.reset();
-//..................................................................
namespace dbaccess
{
-//..................................................................
-//--------------------------------------------------------------------------
+
Reference< XInterface > ORowSet_CreateInstance(const Reference< XMultiServiceFactory >& _rxFactory)
{
return *(new ORowSet(_rxFactory));
}
-//--------------------------------------------------------------------------
+
ORowSet::ORowSet( const Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxORB )
:ORowSet_BASE1(m_aMutex)
,ORowSetBase( _rxORB, ORowSet_BASE1::rBHelper, &m_aMutex )
@@ -170,6 +168,7 @@ ORowSet::ORowSet( const Reference< ::com::sun::star::lang::XMultiServiceFactory
,m_bNew(sal_False)
,m_bCanUpdateInsertedRows(sal_True)
,m_bOwnConnection(sal_False)
+ ,m_bPropChangeNotifyEnabled(sal_True)
{
m_nResultSetType = ResultSetType::SCROLL_SENSITIVE;
m_nResultSetConcurrency = ResultSetConcurrency::UPDATABLE;
@@ -222,19 +221,21 @@ ORowSet::ORowSet( const Reference< ::com::sun::star::lang::XMultiServiceFactory
registerProperty(PROPERTY_UPDATE_CATALOGNAME, PROPERTY_ID_UPDATE_CATALOGNAME, PropertyAttribute::BOUND, &m_aUpdateCatalogName, ::getCppuType(reinterpret_cast< ::rtl::OUString*>(NULL)));
registerProperty(PROPERTY_UPDATE_SCHEMANAME, PROPERTY_ID_UPDATE_SCHEMANAME, PropertyAttribute::BOUND, &m_aUpdateSchemaName, ::getCppuType(reinterpret_cast< ::rtl::OUString*>(NULL)));
registerProperty(PROPERTY_UPDATE_TABLENAME, PROPERTY_ID_UPDATE_TABLENAME, PropertyAttribute::BOUND, &m_aUpdateTableName, ::getCppuType(reinterpret_cast< ::rtl::OUString*>(NULL)));
+
+ // ???
+ registerProperty(PROPERTY_CHANGE_NOTIFICATION_ENABLED, PROPERTY_ID_PROPCHANGE_NOTIFY, PropertyAttribute::BOUND, &m_bPropChangeNotifyEnabled, ::getBooleanCppuType());
}
ORowSet::~ORowSet()
{
if ( !m_rBHelper.bDisposed && !m_rBHelper.bInDispose )
{
- OSL_ENSURE(0, "Please check who doesn't dispose this component!");
+ OSL_FAIL("Please check who doesn't dispose this component!");
osl_incrementInterlockedCount( &m_refCount );
dispose();
}
}
-// -----------------------------------------------------------------------------
void ORowSet::getPropertyDefaultByHandle( sal_Int32 _nHandle, Any& _rDefault ) const
{
switch( _nHandle )
@@ -286,9 +287,8 @@ void ORowSet::getPropertyDefaultByHandle( sal_Int32 _nHandle, Any& _rDefault ) c
break;
}
}
-// -------------------------------------------------------------------------
-// typedef ::comphelper::OPropertyArrayUsageHelper<ORowSet> ORowSet_Prop;
+// typedef ::comphelper::OPropertyArrayUsageHelper<ORowSet> ORowSet_Prop;
void SAL_CALL ORowSet::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception)
{
switch(nHandle)
@@ -373,11 +373,14 @@ void SAL_CALL ORowSet::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const
case PROPERTY_ID_TYPEMAP:
::cppu::extractInterface(m_xTypeMap,m_aTypeMap);
break;
+ case PROPERTY_ID_PROPCHANGE_NOTIFY:
+ m_bPropChangeNotifyEnabled = ::cppu::any2bool(rValue);
+ break;
default:
break;
};
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) const
{
if(m_pCache)
@@ -413,12 +416,15 @@ void SAL_CALL ORowSet::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) const
case PROPERTY_ID_TYPEMAP:
rValue <<= m_xTypeMap;
break;
+ case PROPERTY_ID_PROPCHANGE_NOTIFY:
+ rValue <<= m_bPropChangeNotifyEnabled;
+ break;
default:
ORowSetBase::getFastPropertyValue(rValue,nHandle);
}
}
}
-// -------------------------------------------------------------------------
+
// com::sun::star::XTypeProvider
Sequence< Type > SAL_CALL ORowSet::getTypes() throw (RuntimeException)
{
@@ -428,7 +434,7 @@ Sequence< Type > SAL_CALL ORowSet::getTypes() throw (RuntimeException)
::comphelper::concatSequences(ORowSet_BASE1::getTypes(),ORowSetBase::getTypes()));
return aTypes.getTypes();
}
-// -------------------------------------------------------------------------
+
Sequence< sal_Int8 > SAL_CALL ORowSet::getImplementationId() throw (RuntimeException)
{
static OImplementationId * pId = 0;
@@ -443,24 +449,22 @@ Sequence< sal_Int8 > SAL_CALL ORowSet::getImplementationId() throw (RuntimeExcep
}
return pId->getImplementationId();
}
-// -------------------------------------------------------------------------
// com::sun::star::XInterface
Any SAL_CALL ORowSet::queryInterface( const Type & rType ) throw (RuntimeException)
{
return ORowSet_BASE1::queryInterface( rType);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::acquire() throw()
{
ORowSet_BASE1::acquire();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::release() throw()
{
ORowSet_BASE1::release();
}
-// -------------------------------------------------------------------------
// com::sun::star::XUnoTunnel
sal_Int64 SAL_CALL ORowSet::getSomething( const Sequence< sal_Int8 >& rId ) throw(RuntimeException)
@@ -470,7 +474,7 @@ sal_Int64 SAL_CALL ORowSet::getSomething( const Sequence< sal_Int8 >& rId ) thro
return 0;
}
-// -------------------------------------------------------------------------
+
// com::sun::star::XAggregation
Any SAL_CALL ORowSet::queryAggregation( const Type& rType ) throw(RuntimeException)
{
@@ -479,23 +483,23 @@ Any SAL_CALL ORowSet::queryAggregation( const Type& rType ) throw(RuntimeExcepti
aRet = ORowSet_BASE1::queryAggregation(rType);
return aRet;
}
-//------------------------------------------------------------------------------
+
rtl::OUString ORowSet::getImplementationName_static( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.comp.dba.ORowSet");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.dba.ORowSet"));
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::XServiceInfo
::rtl::OUString SAL_CALL ORowSet::getImplementationName( ) throw(RuntimeException)
{
return getImplementationName_static();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSet::supportsService( const ::rtl::OUString& _rServiceName ) throw(RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > ORowSet::getSupportedServiceNames_static( ) throw (RuntimeException)
{
Sequence< rtl::OUString > aSNS( 5 );
@@ -506,18 +510,18 @@ Sequence< ::rtl::OUString > ORowSet::getSupportedServiceNames_static( ) throw (
aSNS[4] = SERVICE_SDB_ROWSET;
return aSNS;
}
-// -------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > SAL_CALL ORowSet::getSupportedServiceNames( ) throw(RuntimeException)
{
return getSupportedServiceNames_static();
}
-//------------------------------------------------------------------------------
+
Reference< XInterface > ORowSet::Create(const Reference< XComponentContext >& _rxContext)
{
::comphelper::ComponentContext aContext( _rxContext );
return ORowSet_CreateInstance( aContext.getLegacyServiceFactory() );
}
-// -------------------------------------------------------------------------
+
// OComponentHelper
void SAL_CALL ORowSet::disposing()
{
@@ -549,14 +553,14 @@ void SAL_CALL ORowSet::disposing()
ORowSetBase::disposing();
}
-// -------------------------------------------------------------------------
+
void ORowSet::freeResources( bool _bComplete )
{
MutexGuard aGuard(m_aMutex);
// free all clones
connectivity::OWeakRefArray::iterator aEnd = m_aClones.end();
- for (connectivity::OWeakRefArray::iterator i = m_aClones.begin(); aEnd != i; i++)
+ for (connectivity::OWeakRefArray::iterator i = m_aClones.begin(); aEnd != i; ++i)
{
Reference< XComponent > xComp(i->get(), UNO_QUERY);
if (xComp.is())
@@ -598,7 +602,7 @@ void ORowSet::freeResources( bool _bComplete )
m_bIsInsertRow = sal_False;
m_bLastKnownRowCountFinal = sal_False;
m_nLastKnownRowCount = 0;
- if ( m_aOldRow.isValid() )
+ if ( m_aOldRow.is() )
m_aOldRow->clearRow();
impl_disposeParametersContainer_nothrow();
@@ -607,7 +611,6 @@ void ORowSet::freeResources( bool _bComplete )
}
}
-// -------------------------------------------------------------------------
void ORowSet::setActiveConnection( Reference< XConnection >& _rxNewConn, sal_Bool _bFireEvent )
{
if (_rxNewConn.get() == m_xActiveConnection.get())
@@ -653,7 +656,6 @@ void ORowSet::setActiveConnection( Reference< XConnection >& _rxNewConn, sal_Boo
}
}
-// -------------------------------------------------------------------------
// ::com::sun::star::XEventListener
void SAL_CALL ORowSet::disposing( const ::com::sun::star::lang::EventObject& Source ) throw(RuntimeException)
{
@@ -669,7 +671,6 @@ void SAL_CALL ORowSet::disposing( const ::com::sun::star::lang::EventObject& Sou
}
}
}
-// -------------------------------------------------------------------------
// XCloseable
void SAL_CALL ORowSet::close( ) throw(SQLException, RuntimeException)
@@ -681,7 +682,7 @@ void SAL_CALL ORowSet::close( ) throw(SQLException, RuntimeException)
// additionals things to set
freeResources( true );
}
-// -------------------------------------------------------------------------
+
// comphelper::OPropertyArrayUsageHelper
::cppu::IPropertyArrayHelper* ORowSet::createArrayHelper( ) const
{
@@ -689,14 +690,14 @@ void SAL_CALL ORowSet::close( ) throw(SQLException, RuntimeException)
describeProperties(aProps);
return new ::cppu::OPropertyArrayHelper(aProps);
}
-// -------------------------------------------------------------------------
+
// cppu::OPropertySetHelper
::cppu::IPropertyArrayHelper& SAL_CALL ORowSet::getInfoHelper()
{
typedef ::comphelper::OPropertyArrayUsageHelper<ORowSet> ORowSet_PROP;
return *ORowSet_PROP::getArrayHelper();
}
-// -----------------------------------------------------------------------------
+
void ORowSet::updateValue(sal_Int32 columnIndex,const ORowSetValue& x)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -711,7 +712,7 @@ void ORowSet::updateValue(sal_Int32 columnIndex,const ORowSetValue& x)
m_bModified = m_bModified || !aNotify.getChangedColumns().empty();
aNotify.firePropertyChange();
}
-// -------------------------------------------------------------------------
+
// XRowUpdate
void SAL_CALL ORowSet::updateNull( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
@@ -727,67 +728,67 @@ void SAL_CALL ORowSet::updateNull( sal_Int32 columnIndex ) throw(SQLException, R
m_bModified = m_bModified || !aNotify.getChangedColumns().empty();
aNotify.firePropertyChange();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateBoolean( sal_Int32 columnIndex, sal_Bool x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateByte( sal_Int32 columnIndex, sal_Int8 x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateShort( sal_Int32 columnIndex, sal_Int16 x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateInt( sal_Int32 columnIndex, sal_Int32 x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateLong( sal_Int32 columnIndex, sal_Int64 x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateFloat( sal_Int32 columnIndex, float x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateDouble( sal_Int32 columnIndex, double x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateString( sal_Int32 columnIndex, const ::rtl::OUString& x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateBytes( sal_Int32 columnIndex, const Sequence< sal_Int8 >& x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateDate( sal_Int32 columnIndex, const ::com::sun::star::util::Date& x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateTime( sal_Int32 columnIndex, const ::com::sun::star::util::Time& x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateTimestamp( sal_Int32 columnIndex, const ::com::sun::star::util::DateTime& x ) throw(SQLException, RuntimeException)
{
updateValue(columnIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateBinaryStream( sal_Int32 columnIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -795,24 +796,14 @@ void SAL_CALL ORowSet::updateBinaryStream( sal_Int32 columnIndex, const Referenc
checkUpdateConditions(columnIndex);
checkUpdateIterator();
- //if(((*m_aCurrentRow)->get())[columnIndex].getTypeKind() == DataType::BLOB)
- //{
- // ::connectivity::ORowSetValue aOldValue = ((*m_aCurrentRow)->get())[columnIndex];
- // m_pCache->updateBinaryStream(columnIndex,x,length);
- // ((*m_aCurrentRow)->get())[columnIndex] = makeAny(x);
- // ((*m_aCurrentRow)->get())[columnIndex].setTypeKind(DataType::BLOB);
- // firePropertyChange(columnIndex-1 ,aOldValue);
- // fireProperty(PROPERTY_ID_ISMODIFIED,sal_True,sal_False);
- //}
- //else
- {
+ {
Sequence<sal_Int8> aSeq;
if(x.is())
x->readBytes(aSeq,length);
updateValue(columnIndex,aSeq);
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateCharacterStream( sal_Int32 columnIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -825,7 +816,7 @@ void SAL_CALL ORowSet::updateCharacterStream( sal_Int32 columnIndex, const Refer
m_bModified = m_bModified || !aNotify.getChangedColumns().empty();
aNotify.firePropertyChange();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateObject( sal_Int32 columnIndex, const Any& x ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -870,7 +861,7 @@ void SAL_CALL ORowSet::updateObject( sal_Int32 columnIndex, const Any& x ) throw
aNotify.firePropertyChange();
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateNumericObject( sal_Int32 columnIndex, const Any& x, sal_Int32 scale ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -883,7 +874,6 @@ void SAL_CALL ORowSet::updateNumericObject( sal_Int32 columnIndex, const Any& x,
m_bModified = m_bModified || !aNotify.getChangedColumns().empty();
aNotify.firePropertyChange();
}
-// -------------------------------------------------------------------------
// XResultSetUpdate
void SAL_CALL ORowSet::insertRow( ) throw(SQLException, RuntimeException)
@@ -903,7 +893,7 @@ void SAL_CALL ORowSet::insertRow( ) throw(SQLException, RuntimeException)
ORowSetRow aOldValues;
if ( !m_aCurrentRow.isNull() )
- aOldValues = new ORowSetValueVector( m_aCurrentRow->getBody() );
+ aOldValues = new ORowSetValueVector( *(*m_aCurrentRow));
Sequence<Any> aChangedBookmarks;
RowsChangeEvent aEvt(*this,RowChangeAction::INSERT,1,aChangedBookmarks);
notifyAllListenersRowBeforeChange(aGuard,aEvt);
@@ -942,7 +932,7 @@ void SAL_CALL ORowSet::insertRow( ) throw(SQLException, RuntimeException)
// - RowCount/IsRowCountFinal
fireRowcount();
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL ORowSet::getRow( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
@@ -951,7 +941,7 @@ sal_Int32 SAL_CALL ORowSet::getRow( ) throw(SQLException, RuntimeException)
// check if we are inserting a row
return (m_pCache && isInsertRow()) ? 0 : ORowSetBase::getRow();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::updateRow( ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -965,7 +955,7 @@ void SAL_CALL ORowSet::updateRow( ) throw(SQLException, RuntimeException)
{
ORowSetRow aOldValues;
if ( !m_aCurrentRow.isNull() )
- aOldValues = new ORowSetValueVector( m_aCurrentRow->getBody() );
+ aOldValues = new ORowSetValueVector( *(*m_aCurrentRow) );
Sequence<Any> aChangedBookmarks;
RowsChangeEvent aEvt(*this,RowChangeAction::UPDATE,1,aChangedBookmarks);
@@ -978,8 +968,7 @@ void SAL_CALL ORowSet::updateRow( ) throw(SQLException, RuntimeException)
aEvt.Rows += aBookmarks.size();
m_aBookmark = m_pCache->getBookmark();
m_aCurrentRow = m_pCache->m_aMatrixIter;
- m_bIsInsertRow = sal_False;
- if ( m_pCache->m_aMatrixIter != m_pCache->getEnd() && (*m_pCache->m_aMatrixIter).isValid() )
+ if ( m_pCache->m_aMatrixIter != m_pCache->getEnd() && (*m_pCache->m_aMatrixIter).is() )
{
if ( m_pCache->isResultSetChanged() )
{
@@ -987,7 +976,7 @@ void SAL_CALL ORowSet::updateRow( ) throw(SQLException, RuntimeException)
}
else
{
- m_aOldRow->setRow(new ORowSetValueVector(m_aCurrentRow->getBody()));
+ m_aOldRow->setRow(new ORowSetValueVector(*(*m_aCurrentRow)));
// notification order
// - column values
@@ -1010,7 +999,7 @@ void SAL_CALL ORowSet::updateRow( ) throw(SQLException, RuntimeException)
}
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::deleteRow( ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -1037,8 +1026,8 @@ void SAL_CALL ORowSet::deleteRow( ) throw(SQLException, RuntimeException)
notifyRowSetAndClonesRowDelete( aBookmarkToDelete );
ORowSetRow aOldValues;
- if ( m_pCache->m_aMatrixIter != m_pCache->getEnd() && m_pCache->m_aMatrixIter->isValid() )
- aOldValues = new ORowSetValueVector( m_pCache->m_aMatrixIter->getBody() );
+ if ( m_pCache->m_aMatrixIter != m_pCache->getEnd() && m_pCache->m_aMatrixIter->is() )
+ aOldValues = new ORowSetValueVector( *(*(m_pCache->m_aMatrixIter)) );
Sequence<Any> aChangedBookmarks;
RowsChangeEvent aEvt(*this,RowChangeAction::DELETE,1,aChangedBookmarks);
@@ -1062,7 +1051,6 @@ void SAL_CALL ORowSet::deleteRow( ) throw(SQLException, RuntimeException)
fireRowcount();
}
-// -------------------------------------------------------------------------
void ORowSet::implCancelRowUpdates( sal_Bool _bNotifyModified ) SAL_THROW( ( SQLException, RuntimeException ) )
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -1083,7 +1071,7 @@ void ORowSet::implCancelRowUpdates( sal_Bool _bNotifyModified ) SAL_THROW( ( SQL
ORowSetRow aOldValues;
if ( !m_bModified && _bNotifyModified && !m_aCurrentRow.isNull() )
- aOldValues = new ORowSetValueVector( m_aCurrentRow->getBody() );
+ aOldValues = new ORowSetValueVector( *(*m_aCurrentRow) );
m_pCache->cancelRowUpdates();
@@ -1102,13 +1090,11 @@ void ORowSet::implCancelRowUpdates( sal_Bool _bNotifyModified ) SAL_THROW( ( SQL
}
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSet::cancelRowUpdates( ) throw(SQLException, RuntimeException)
{
implCancelRowUpdates( sal_True );
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSet::addRowSetListener( const Reference< XRowSetListener >& listener ) throw(RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -1117,7 +1103,7 @@ void SAL_CALL ORowSet::addRowSetListener( const Reference< XRowSetListener >& li
if(listener.is())
m_aRowsetListeners.addInterface(listener);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::removeRowSetListener( const Reference< XRowSetListener >& listener ) throw(RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -1126,7 +1112,7 @@ void SAL_CALL ORowSet::removeRowSetListener( const Reference< XRowSetListener >&
if(listener.is())
m_aRowsetListeners.removeInterface(listener);
}
-// -----------------------------------------------------------------------------
+
void ORowSet::notifyAllListeners(::osl::ResettableMutexGuard& _rGuard)
{
EventObject aEvt(*m_pMySelf);
@@ -1134,7 +1120,7 @@ void ORowSet::notifyAllListeners(::osl::ResettableMutexGuard& _rGuard)
m_aRowsetListeners.notifyEach( &XRowSetListener::rowSetChanged, aEvt );
_rGuard.reset();
}
-// -------------------------------------------------------------------------
+
void ORowSet::notifyAllListenersCursorMoved(::osl::ResettableMutexGuard& _rGuard)
{
EventObject aEvt(*m_pMySelf);
@@ -1142,7 +1128,7 @@ void ORowSet::notifyAllListenersCursorMoved(::osl::ResettableMutexGuard& _rGuard
m_aRowsetListeners.notifyEach( &XRowSetListener::cursorMoved, aEvt );
_rGuard.reset();
}
-// -------------------------------------------------------------------------
+
void ORowSet::notifyAllListenersRowChanged(::osl::ResettableMutexGuard& _rGuard, const RowsChangeEvent& aEvt)
{
_rGuard.clear();
@@ -1150,21 +1136,21 @@ void ORowSet::notifyAllListenersRowChanged(::osl::ResettableMutexGuard& _rGuard,
m_aRowsChangeListener.notifyEach( &XRowsChangeListener::rowsChanged, aEvt );
_rGuard.reset();
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSet::notifyAllListenersCursorBeforeMove(::osl::ResettableMutexGuard& _rGuard)
{
EventObject aEvt(*m_pMySelf);
NOTIFY_LISTERNERS_CHECK(m_aApproveListeners,XRowSetApproveListener,approveCursorMove);
return bCheck;
}
-// -------------------------------------------------------------------------
+
void ORowSet::notifyAllListenersRowBeforeChange(::osl::ResettableMutexGuard& _rGuard,const RowChangeEvent &aEvt)
{
NOTIFY_LISTERNERS_CHECK(m_aApproveListeners,XRowSetApproveListener,approveRowChange);
if ( !bCheck )
m_aErrors.raiseTypedException( sdb::ErrorCondition::ROW_SET_OPERATION_VETOED, *this, ::cppu::UnoType< RowSetVetoException >::get() );
}
-// -------------------------------------------------------------------------
+
void ORowSet::fireRowcount()
{
sal_Int32 nCurrentRowCount( impl_getRowCount() );
@@ -1188,7 +1174,7 @@ void ORowSet::fireRowcount()
m_bLastKnownRowCountFinal = bCurrentRowCountFinal;
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::moveToInsertRow( ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -1215,9 +1201,9 @@ void SAL_CALL ORowSet::moveToInsertRow( ) throw(SQLException, RuntimeException)
if ( !m_bBeforeFirst
&& !m_bAfterLast
&& m_pCache->m_aMatrixIter != m_pCache->getEnd()
- && m_pCache->m_aMatrixIter->isValid()
+ && m_pCache->m_aMatrixIter->is()
)
- aOldValues = new ORowSetValueVector( m_pCache->m_aMatrixIter->getBody() );
+ aOldValues = new ORowSetValueVector( *(*(m_pCache->m_aMatrixIter)) );
const sal_Bool bNewState = m_bNew;
const sal_Bool bModState = m_bModified;
@@ -1248,13 +1234,13 @@ void SAL_CALL ORowSet::moveToInsertRow( ) throw(SQLException, RuntimeException)
fireRowcount();
}
}
-// -------------------------------------------------------------------------
+
void ORowSet::impl_setDataColumnsWriteable_throw()
{
impl_restoreDataColumnsWriteable_throw();
TDataColumns::iterator aIter = m_aDataColumns.begin();
m_aReadOnlyDataColumns.resize(m_aDataColumns.size(),false);
- ::std::bit_vector::iterator aReadIter = m_aReadOnlyDataColumns.begin();
+ ::std::vector<bool, std::allocator<bool> >::iterator aReadIter = m_aReadOnlyDataColumns.begin();
for(;aIter != m_aDataColumns.end();++aIter,++aReadIter)
{
sal_Bool bReadOnly = sal_False;
@@ -1264,18 +1250,18 @@ void ORowSet::impl_setDataColumnsWriteable_throw()
(*aIter)->setPropertyValue(PROPERTY_ISREADONLY,makeAny(sal_False));
}
}
-// -------------------------------------------------------------------------
+
void ORowSet::impl_restoreDataColumnsWriteable_throw()
{
TDataColumns::iterator aIter = m_aDataColumns.begin();
- ::std::bit_vector::iterator aReadIter = m_aReadOnlyDataColumns.begin();
+ ::std::vector<bool, std::allocator<bool> >::iterator aReadIter = m_aReadOnlyDataColumns.begin();
for(;aReadIter != m_aReadOnlyDataColumns.end();++aIter,++aReadIter)
{
(*aIter)->setPropertyValue(PROPERTY_ISREADONLY,makeAny((sal_Bool)*aReadIter ));
}
m_aReadOnlyDataColumns.clear();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::moveToCurrentRow( ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -1310,7 +1296,7 @@ void SAL_CALL ORowSet::moveToCurrentRow( ) throw(SQLException, RuntimeException
aNotifier.fire();
}
}
-// -------------------------------------------------------------------------
+
// XRow
sal_Bool SAL_CALL ORowSet::wasNull( ) throw(SQLException, RuntimeException)
{
@@ -1319,7 +1305,7 @@ sal_Bool SAL_CALL ORowSet::wasNull( ) throw(SQLException, RuntimeException)
return ( m_pCache && isInsertRow() ) ? ((*m_pCache->m_aInsertRow)->get())[m_nLastColumnIndex].isNull() : ORowSetBase::wasNull();
}
-// -----------------------------------------------------------------------------
+
const ORowSetValue& ORowSet::getInsertValue(sal_Int32 columnIndex)
{
checkCache();
@@ -1329,79 +1315,79 @@ const ORowSetValue& ORowSet::getInsertValue(sal_Int32 columnIndex)
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL ORowSet::getString( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSet::getBoolean( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int8 SAL_CALL ORowSet::getByte( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int16 SAL_CALL ORowSet::getShort( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL ORowSet::getInt( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int64 SAL_CALL ORowSet::getLong( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
float SAL_CALL ORowSet::getFloat( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
double SAL_CALL ORowSet::getDouble( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
Sequence< sal_Int8 > SAL_CALL ORowSet::getBytes( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Date SAL_CALL ORowSet::getDate( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Time SAL_CALL ORowSet::getTime( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::DateTime SAL_CALL ORowSet::getTimestamp( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSet::getBinaryStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
@@ -1413,7 +1399,7 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSet::getBinaryStrea
return ORowSetBase::getBinaryStream(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSet::getCharacterStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
@@ -1425,18 +1411,18 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSet::getCharacterSt
return ORowSetBase::getCharacterStream(columnIndex);
}
-// -------------------------------------------------------------------------
+
Any SAL_CALL ORowSet::getObject( sal_Int32 columnIndex, const Reference< XNameAccess >& /*typeMap*/ ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
return getInsertValue(columnIndex).makeAny();
}
-// -------------------------------------------------------------------------
+
Reference< XRef > SAL_CALL ORowSet::getRef( sal_Int32 /*columnIndex*/ ) throw(SQLException, RuntimeException)
{
return Reference< XRef >();
}
-// -------------------------------------------------------------------------
+
Reference< XBlob > SAL_CALL ORowSet::getBlob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
if ( m_pCache && isInsertRow() )
@@ -1446,17 +1432,17 @@ Reference< XBlob > SAL_CALL ORowSet::getBlob( sal_Int32 columnIndex ) throw(SQLE
}
return ORowSetBase::getBlob(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< XClob > SAL_CALL ORowSet::getClob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
return Reference< XClob >(getInsertValue(columnIndex).makeAny(),UNO_QUERY);
}
-// -------------------------------------------------------------------------
+
Reference< XArray > SAL_CALL ORowSet::getArray( sal_Int32 /*columnIndex*/ ) throw(SQLException, RuntimeException)
{
return Reference< XArray >();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::executeWithCompletion( const Reference< XInteractionHandler >& _rxHandler ) throw(SQLException, RuntimeException)
{
if (!_rxHandler.is())
@@ -1504,7 +1490,7 @@ void SAL_CALL ORowSet::executeWithCompletion( const Reference< XInteractionHandl
}
catch(Exception&)
{
- DBG_ERROR("ORowSet::executeWithCompletion: caught an unexpected exception type while filling in the parameters!");
+ OSL_FAIL("ORowSet::executeWithCompletion: caught an unexpected exception type while filling in the parameters!");
}
// we're done with the parameters, now for the real execution
@@ -1513,7 +1499,6 @@ void SAL_CALL ORowSet::executeWithCompletion( const Reference< XInteractionHandl
execute_NoApprove_NoNewConn(aGuard);
}
-// -------------------------------------------------------------------------
Reference< XIndexAccess > SAL_CALL ORowSet::getParameters( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( *m_pMutex );
@@ -1540,7 +1525,6 @@ Reference< XIndexAccess > SAL_CALL ORowSet::getParameters( ) throw (RuntimeExce
return m_pParameters.get();
}
-// -------------------------------------------------------------------------
void ORowSet::approveExecution() throw (RowSetVetoException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aColumnsMutex );
@@ -1568,9 +1552,8 @@ void ORowSet::approveExecution() throw (RowSetVetoException, RuntimeException)
}
}
}
-// -------------------------------------------------------------------------
+
// XRowSet
-// -------------------------------------------------------------------------
void SAL_CALL ORowSet::execute( ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -1595,7 +1578,6 @@ void SAL_CALL ORowSet::execute( ) throw(SQLException, RuntimeException)
execute_NoApprove_NoNewConn(aGuard);
}
-//------------------------------------------------------------------------------
void ORowSet::setStatementResultSetType( const Reference< XPropertySet >& _rxStatement, sal_Int32 _nDesiredResultSetType, sal_Int32 _nDesiredResultSetConcurrency )
{
OSL_ENSURE( _rxStatement.is(), "ORowSet::setStatementResultSetType: invalid statement - this will crash!" );
@@ -1604,7 +1586,7 @@ void ORowSet::setStatementResultSetType( const Reference< XPropertySet >& _rxSta
sal_Int32 nResultSetConcurrency( _nDesiredResultSetConcurrency );
// there *might* be a data source setting which tells use to be more defensive with those settings
- // #i15113# / 2005-02-10 / frank.schoenheit@sun.com
+ // #i15113#
sal_Bool bRespectDriverRST = sal_False;
Any aSetting;
if ( getDataSourceSetting( ::dbaccess::getDataSource( m_xActiveConnection ), "RespectDriverResultSetType", aSetting ) )
@@ -1649,7 +1631,6 @@ void ORowSet::setStatementResultSetType( const Reference< XPropertySet >& _rxSta
_rxStatement->setPropertyValue( PROPERTY_RESULTSETCONCURRENCY, makeAny( nResultSetConcurrency ) );
}
-// -----------------------------------------------------------------------------
Reference< XResultSet > ORowSet::impl_prepareAndExecute_throw()
{
::rtl::OUString sCommandToExecute;
@@ -1711,7 +1692,6 @@ Reference< XResultSet > ORowSet::impl_prepareAndExecute_throw()
return xResultSet;
}
-// -----------------------------------------------------------------------------
void ORowSet::impl_initializeColumnSettings_nothrow( const Reference< XPropertySet >& _rxTemplateColumn, const Reference< XPropertySet >& _rxRowSetColumn )
{
OSL_ENSURE( _rxTemplateColumn.is() && _rxRowSetColumn.is(),
@@ -1727,7 +1707,7 @@ void ORowSet::impl_initializeColumnSettings_nothrow( const Reference< XPropertyS
PROPERTY_ALIGN, PROPERTY_RELATIVEPOSITION, PROPERTY_WIDTH, PROPERTY_HIDDEN, PROPERTY_CONTROLMODEL,
PROPERTY_HELPTEXT, PROPERTY_CONTROLDEFAULT
};
- for ( size_t i=0; i<sizeof( aPropertyNames ) / sizeof( aPropertyNames[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aPropertyNames ); ++i )
{
if ( xInfo->hasPropertyByName( aPropertyNames[i] ) )
{
@@ -1797,7 +1777,6 @@ void ORowSet::impl_initializeColumnSettings_nothrow( const Reference< XPropertyS
}
}
-// -----------------------------------------------------------------------------
void ORowSet::execute_NoApprove_NoNewConn(ResettableMutexGuard& _rClearForNotification)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "frank.schoenheit@sun.com", "ORowSet::execute_NoApprove_NoNewConn" );
@@ -1840,9 +1819,7 @@ void ORowSet::execute_NoApprove_NoNewConn(ResettableMutexGuard& _rClearForNotifi
}
// get the locale
- // ConfigManager* pConfigMgr = ConfigManager::GetConfigManager();
Locale aLocale = SvtSysLocale().GetLocaleData().getLocale();
- // pConfigMgr->GetDirectConfigProperty(ConfigManager::LOCALE) >>= aLocale;
// get the numberformatTypes
OSL_ENSURE(m_xActiveConnection.is(),"No ActiveConnection");
@@ -1851,10 +1828,9 @@ void ORowSet::execute_NoApprove_NoNewConn(ResettableMutexGuard& _rClearForNotifi
if ( xNumberFormat.is() )
m_xNumberFormatTypes.set(xNumberFormat->getNumberFormats(),UNO_QUERY);
- ::vos::ORef< ::connectivity::OSQLColumns> aColumns = new ::connectivity::OSQLColumns();
+ ::rtl::Reference< ::connectivity::OSQLColumns> aColumns = new ::connectivity::OSQLColumns();
::std::vector< ::rtl::OUString> aNames;
::rtl::OUString aDescription;
- sal_Int32 nFormatKey = 0;
const ::std::map<sal_Int32,sal_Int32>& rKeyColumns = m_pCache->getKeyColumns();
if(!m_xColumns.is())
@@ -1905,7 +1881,7 @@ void ORowSet::execute_NoApprove_NoNewConn(ResettableMutexGuard& _rClearForNotifi
try
{
- nFormatKey = 0;
+ sal_Int32 nFormatKey = 0;
if(m_xNumberFormatTypes.is())
nFormatKey = ::dbtools::getDefaultNumberFormat(pColumn,m_xNumberFormatTypes,aLocale);
@@ -1959,8 +1935,6 @@ void ORowSet::execute_NoApprove_NoNewConn(ResettableMutexGuard& _rClearForNotifi
if(!xColumn.is())
{
// no column found so we could look at the position i
- //bReFetchName = sal_True;
- //sColumnLabel = ::rtl::OUString();
Reference<XIndexAccess> xIndexAccess(m_xColumns,UNO_QUERY);
if(xIndexAccess.is() && i <= xIndexAccess->getCount())
{
@@ -2033,7 +2007,7 @@ void ORowSet::execute_NoApprove_NoNewConn(ResettableMutexGuard& _rClearForNotifi
// notify the rowset listeners
notifyAllListeners(_rClearForNotification);
}
-// -------------------------------------------------------------------------
+
// XRowSetApproveBroadcaster
void SAL_CALL ORowSet::addRowSetApproveListener( const Reference< XRowSetApproveListener >& listener ) throw(RuntimeException)
{
@@ -2043,7 +2017,7 @@ void SAL_CALL ORowSet::addRowSetApproveListener( const Reference< XRowSetApprove
m_aApproveListeners.addInterface(listener);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::removeRowSetApproveListener( const Reference< XRowSetApproveListener >& listener ) throw(RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -2061,7 +2035,7 @@ void SAL_CALL ORowSet::addRowsChangeListener( const Reference< XRowsChangeListen
m_aRowsChangeListener.addInterface(listener);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::removeRowsChangeListener( const Reference< XRowsChangeListener >& listener ) throw(RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -2070,7 +2044,6 @@ void SAL_CALL ORowSet::removeRowsChangeListener( const Reference< XRowsChangeLis
m_aRowsChangeListener.removeInterface(listener);
}
-// -------------------------------------------------------------------------
// XResultSetAccess
Reference< XResultSet > SAL_CALL ORowSet::createResultSet( ) throw(SQLException, RuntimeException)
@@ -2086,14 +2059,12 @@ Reference< XResultSet > SAL_CALL ORowSet::createResultSet( ) throw(SQLException
}
return Reference< XResultSet >();
}
-// -------------------------------------------------------------------------
// ::com::sun::star::util::XCancellable
void SAL_CALL ORowSet::cancel( ) throw(RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
}
-// -------------------------------------------------------------------------
// ::com::sun::star::sdbcx::XDeleteRows
Sequence< sal_Int32 > SAL_CALL ORowSet::deleteRows( const Sequence< Any >& rows ) throw(SQLException, RuntimeException)
@@ -2149,14 +2120,14 @@ Sequence< sal_Int32 > SAL_CALL ORowSet::deleteRows( const Sequence< Any >& rows
return aResults;
}
-// -----------------------------------------------------------------------------
+
void ORowSet::notifyRowSetAndClonesRowDelete( const Any& _rBookmark )
{
// notify ourself
onDeleteRow( _rBookmark );
// notify the clones
connectivity::OWeakRefArray::iterator aEnd = m_aClones.end();
- for (connectivity::OWeakRefArray::iterator i = m_aClones.begin(); aEnd != i; i++)
+ for (connectivity::OWeakRefArray::iterator i = m_aClones.begin(); aEnd != i; ++i)
{
Reference< XUnoTunnel > xTunnel(i->get(),UNO_QUERY);
if(xTunnel.is())
@@ -2167,14 +2138,14 @@ void ORowSet::notifyRowSetAndClonesRowDelete( const Any& _rBookmark )
}
}
}
-//------------------------------------------------------------------------------
+
void ORowSet::notifyRowSetAndClonesRowDeleted( const Any& _rBookmark, sal_Int32 _nPos )
{
// notify ourself
onDeletedRow( _rBookmark, _nPos );
// notify the clones
connectivity::OWeakRefArray::iterator aEnd = m_aClones.end();
- for (connectivity::OWeakRefArray::iterator i = m_aClones.begin(); aEnd != i; i++)
+ for (connectivity::OWeakRefArray::iterator i = m_aClones.begin(); aEnd != i; ++i)
{
Reference< XUnoTunnel > xTunnel(i->get(),UNO_QUERY);
if(xTunnel.is())
@@ -2185,7 +2156,7 @@ void ORowSet::notifyRowSetAndClonesRowDeleted( const Any& _rBookmark, sal_Int32
}
}
}
-//------------------------------------------------------------------------------
+
Reference< XConnection > ORowSet::calcConnection(const Reference< XInteractionHandler >& _rxHandler) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -2229,7 +2200,7 @@ Reference< XConnection > ORowSet::calcConnection(const Reference< XInteractionH
}
return m_xActiveConnection;
}
-//------------------------------------------------------------------------------
+
Reference< XNameAccess > ORowSet::impl_getTables_throw()
{
Reference< XNameAccess > xTables;
@@ -2262,14 +2233,13 @@ Reference< XNameAccess > ORowSet::impl_getTables_throw()
m_pTables = new OTableContainer(*this,m_aMutex,m_xActiveConnection,bCase,NULL,NULL,NULL,m_nInAppend);
xTables = m_pTables;
Sequence< ::rtl::OUString> aTableFilter(1);
- aTableFilter[0] = ::rtl::OUString::createFromAscii("%");
+ aTableFilter[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("%"));
m_pTables->construct(aTableFilter,Sequence< ::rtl::OUString>());
}
return xTables;
}
-//------------------------------------------------------------------------------
void ORowSet::impl_resetTables_nothrow()
{
if ( !m_pTables )
@@ -2287,7 +2257,6 @@ void ORowSet::impl_resetTables_nothrow()
DELETEZ( m_pTables );
}
-//------------------------------------------------------------------------------
sal_Bool ORowSet::impl_initComposer_throw( ::rtl::OUString& _out_rCommandToExecute )
{
sal_Bool bUseEscapeProcessing = impl_buildActiveCommand_throw( );
@@ -2318,9 +2287,8 @@ sal_Bool ORowSet::impl_initComposer_throw( ::rtl::OUString& _out_rCommandToExecu
{ // append a "0=1" filter
// don't simply overwrite an existent filter, this would lead to problems if this existent
// filter contains paramters (since a keyset may add parameters itself)
- // 2003-12-12 - #23418# - fs@openoffice.org
m_xComposer->setElementaryQuery( m_xComposer->getQuery( ) );
- m_xComposer->setFilter( ::rtl::OUString::createFromAscii( "0 = 1" ) );
+ m_xComposer->setFilter( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "0 = 1" ) ) );
}
m_xComposer->setOrder( m_aOrder );
@@ -2339,7 +2307,6 @@ sal_Bool ORowSet::impl_initComposer_throw( ::rtl::OUString& _out_rCommandToExecu
return bUseEscapeProcessing;
}
-//------------------------------------------------------------------------------
sal_Bool ORowSet::impl_buildActiveCommand_throw()
{
// create the sql command
@@ -2363,32 +2330,6 @@ sal_Bool ORowSet::impl_buildActiveCommand_throw()
Reference< XNameAccess > xTables( impl_getTables_throw() );
if ( xTables->hasByName(m_aCommand) )
{
-/*
- Reference< XPropertySet > xTable;
- try
- {
- xTables->getByName( m_aCommand ) >>= xTable;
- }
- catch(const WrappedTargetException& e)
- {
- SQLException e2;
- if ( e.TargetException >>= e2 )
- throw e2;
- }
- catch(Exception&)
- {
- DBG_UNHANDLED_EXCEPTION();
- }
-
- Reference<XColumnsSupplier> xSup(xTable,UNO_QUERY);
- if ( xSup.is() )
- m_xColumns = xSup->getColumns();
-
- sCommand = rtl::OUString::createFromAscii("SELECT * FROM ");
- ::rtl::OUString sCatalog, sSchema, sTable;
- ::dbtools::qualifiedNameComponents( m_xActiveConnection->getMetaData(), m_aCommand, sCatalog, sSchema, sTable, ::dbtools::eInDataManipulation );
- sCommand += ::dbtools::composeTableNameForSelect( m_xActiveConnection, sCatalog, sSchema, sTable );
-*/
}
else
{
@@ -2399,7 +2340,7 @@ sal_Bool ORowSet::impl_buildActiveCommand_throw()
}
else
{
- sCommand = rtl::OUString::createFromAscii("SELECT * FROM ");
+ sCommand = rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT * FROM "));
::rtl::OUString sCatalog, sSchema, sTable;
::dbtools::qualifiedNameComponents( m_xActiveConnection->getMetaData(), m_aCommand, sCatalog, sSchema, sTable, ::dbtools::eInDataManipulation );
sCommand += ::dbtools::composeTableNameForSelect( m_xActiveConnection, sCatalog, sSchema, sTable );
@@ -2434,11 +2375,6 @@ sal_Bool ORowSet::impl_buildActiveCommand_throw()
xQuery->getPropertyValue(PROPERTY_UPDATE_TABLENAME) >>= aTable;
if(aTable.getLength())
m_aUpdateTableName = composeTableName( m_xActiveConnection->getMetaData(), aCatalog, aSchema, aTable, sal_False, ::dbtools::eInDataManipulation );
-/*
- Reference<XColumnsSupplier> xSup(xQuery,UNO_QUERY);
- if(xSup.is())
- m_xColumns = xSup->getColumns();
-*/
}
}
else
@@ -2466,7 +2402,6 @@ sal_Bool ORowSet::impl_buildActiveCommand_throw()
return bDoEscapeProcessing;
}
-//------------------------------------------------------------------------------
void ORowSet::impl_initParametersContainer_nothrow()
{
OSL_PRECOND( !m_pParameters.is(), "ORowSet::impl_initParametersContainer_nothrow: already initialized the parameters!" );
@@ -2480,7 +2415,6 @@ void ORowSet::impl_initParametersContainer_nothrow()
}
}
-//------------------------------------------------------------------------------
void ORowSet::impl_disposeParametersContainer_nothrow()
{
if ( !m_pParameters.is() )
@@ -2498,7 +2432,6 @@ void ORowSet::impl_disposeParametersContainer_nothrow()
m_pParameters = NULL;
}
-// -----------------------------------------------------------------------------
ORowSetValue& ORowSet::getParameterStorage(sal_Int32 parameterIndex)
{
::connectivity::checkDisposed( ORowSet_BASE1::rBHelper.bDisposed );
@@ -2531,7 +2464,7 @@ ORowSetValue& ORowSet::getParameterStorage(sal_Int32 parameterIndex)
m_aPrematureParamValues.get().resize( parameterIndex );
return m_aPrematureParamValues.get()[ parameterIndex - 1 ];
}
-// -------------------------------------------------------------------------
+
// XParameters
void SAL_CALL ORowSet::setNull( sal_Int32 parameterIndex, sal_Int32 /*sqlType*/ ) throw(SQLException, RuntimeException)
{
@@ -2539,12 +2472,12 @@ void SAL_CALL ORowSet::setNull( sal_Int32 parameterIndex, sal_Int32 /*sqlType*/
getParameterStorage( parameterIndex ).setNull();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setObjectNull( sal_Int32 parameterIndex, sal_Int32 sqlType, const ::rtl::OUString& /*typeName*/ ) throw(SQLException, RuntimeException)
{
setNull( parameterIndex, sqlType );
}
-// -----------------------------------------------------------------------------
+
void ORowSet::setParameter(sal_Int32 parameterIndex, const ORowSetValue& x)
{
::osl::MutexGuard aGuard( m_aColumnsMutex );
@@ -2552,67 +2485,66 @@ void ORowSet::setParameter(sal_Int32 parameterIndex, const ORowSetValue& x)
getParameterStorage( parameterIndex ) = x;
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSet::setBoolean( sal_Int32 parameterIndex, sal_Bool x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setByte( sal_Int32 parameterIndex, sal_Int8 x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setShort( sal_Int32 parameterIndex, sal_Int16 x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setInt( sal_Int32 parameterIndex, sal_Int32 x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setLong( sal_Int32 parameterIndex, sal_Int64 x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setFloat( sal_Int32 parameterIndex, float x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setDouble( sal_Int32 parameterIndex, double x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setString( sal_Int32 parameterIndex, const ::rtl::OUString& x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setBytes( sal_Int32 parameterIndex, const Sequence< sal_Int8 >& x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setDate( sal_Int32 parameterIndex, const ::com::sun::star::util::Date& x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setTime( sal_Int32 parameterIndex, const ::com::sun::star::util::Time& x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setTimestamp( sal_Int32 parameterIndex, const ::com::sun::star::util::DateTime& x ) throw(SQLException, RuntimeException)
{
setParameter(parameterIndex,x);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setBinaryStream( sal_Int32 parameterIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aColumnsMutex );
@@ -2630,7 +2562,7 @@ void SAL_CALL ORowSet::setBinaryStream( sal_Int32 parameterIndex, const Referenc
throw SQLException();
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setCharacterStream( sal_Int32 parameterIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aColumnsMutex );
@@ -2652,7 +2584,7 @@ void SAL_CALL ORowSet::setCharacterStream( sal_Int32 parameterIndex, const Refer
throw SQLException();
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setObject( sal_Int32 parameterIndex, const Any& x ) throw(SQLException, RuntimeException)
{
if ( !::dbtools::implSetObject( this, parameterIndex, x ) )
@@ -2660,7 +2592,7 @@ void SAL_CALL ORowSet::setObject( sal_Int32 parameterIndex, const Any& x ) throw
throw SQLException();
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setObjectWithInfo( sal_Int32 parameterIndex, const Any& x, sal_Int32 targetSqlType, sal_Int32 /*scale*/ ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aColumnsMutex );
@@ -2668,27 +2600,27 @@ void SAL_CALL ORowSet::setObjectWithInfo( sal_Int32 parameterIndex, const Any& x
setObject( parameterIndex, x );
rParamValue.setTypeKind( targetSqlType );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setRef( sal_Int32 /*parameterIndex*/, const Reference< XRef >& /*x*/ ) throw(SQLException, RuntimeException)
{
::dbtools::throwFeatureNotImplementedException( "XParameters::setRef", *this );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setBlob( sal_Int32 /*parameterIndex*/, const Reference< XBlob >& /*x*/ ) throw(SQLException, RuntimeException)
{
::dbtools::throwFeatureNotImplementedException( "XParameters::setBlob", *this );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setClob( sal_Int32 /*parameterIndex*/, const Reference< XClob >& /*x*/ ) throw(SQLException, RuntimeException)
{
::dbtools::throwFeatureNotImplementedException( "XParameters::setClob", *this );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::setArray( sal_Int32 /*parameterIndex*/, const Reference< XArray >& /*x*/ ) throw(SQLException, RuntimeException)
{
::dbtools::throwFeatureNotImplementedException( "XParameters::setArray", *this );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSet::clearParameters( ) throw(SQLException, RuntimeException)
{
::connectivity::checkDisposed(ORowSet_BASE1::rBHelper.bDisposed);
@@ -2701,21 +2633,18 @@ void SAL_CALL ORowSet::clearParameters( ) throw(SQLException, RuntimeException)
m_aParametersSet.clear();
}
-// -------------------------------------------------------------------------
Any SAL_CALL ORowSet::getWarnings( ) throw (SQLException, RuntimeException)
{
return m_aWarnings.getWarnings();
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSet::clearWarnings( ) throw (SQLException, RuntimeException)
{
m_aWarnings.clearWarnings();
}
-// -----------------------------------------------------------------------------
+
void ORowSet::doCancelModification( )
{
- //OSL_ENSURE( isModification(), "ORowSet::doCancelModification: invalid call (no cache!)!" );
if ( isModification() )
{
// read-only flag restored
@@ -2726,25 +2655,26 @@ void ORowSet::doCancelModification( )
m_bIsInsertRow = sal_False;
}
-// -----------------------------------------------------------------------------
sal_Bool ORowSet::isModification( )
{
return isNew();
}
-// -----------------------------------------------------------------------------
sal_Bool ORowSet::isModified( )
{
return m_bModified;
}
-// -----------------------------------------------------------------------------
sal_Bool ORowSet::isNew( )
{
return m_bNew;
}
-// -----------------------------------------------------------------------------
+sal_Bool ORowSet::isPropertyChangeNotificationEnabled() const
+{
+ return m_bPropChangeNotifyEnabled;
+}
+
void ORowSet::checkUpdateIterator()
{
if(!m_bIsInsertRow)
@@ -2754,7 +2684,7 @@ void ORowSet::checkUpdateIterator()
m_bIsInsertRow = sal_True;
}
}
-// -----------------------------------------------------------------------------
+
void ORowSet::checkUpdateConditions(sal_Int32 columnIndex)
{
checkCache();
@@ -2770,7 +2700,7 @@ void ORowSet::checkUpdateConditions(sal_Int32 columnIndex)
if ( columnIndex <= 0 || sal_Int32((*m_aCurrentRow)->get().size()) <= columnIndex )
::dbtools::throwSQLException( DBACORE_RESSTRING( RID_STR_INVALID_INDEX ), SQL_INVALID_DESCRIPTOR_INDEX, *this );
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ORowSet::refreshRow( ) throw(SQLException, RuntimeException)
{
@@ -2788,7 +2718,7 @@ void SAL_CALL ORowSet::refreshRow( ) throw(SQLException, RuntimeException)
// - IsNew
aNotifier.fire( );
}
-// -----------------------------------------------------------------------------
+
void ORowSet::impl_rebuild_throw(::osl::ResettableMutexGuard& _rGuard)
{
Reference< XResultSet > xResultSet( m_xStatement->executeQuery() );
@@ -2800,7 +2730,7 @@ void ORowSet::impl_rebuild_throw(::osl::ResettableMutexGuard& _rGuard)
// ORowSetClone
// ***********************************************************
DBG_NAME(ORowSetClone);
-//--------------------------------------------------------------------------
+
ORowSetClone::ORowSetClone( const ::comphelper::ComponentContext& _rContext, ORowSet& rParent, ::osl::Mutex* _pMutex )
:OSubComponent(m_aMutex, rParent)
,ORowSetBase( _rContext, OComponentHelper::rBHelper, _pMutex )
@@ -2824,13 +2754,10 @@ ORowSetClone::ORowSetClone( const ::comphelper::ComponentContext& _rContext, ORo
m_aOldRow = m_pCache->registerOldRow();
- ::vos::ORef< ::connectivity::OSQLColumns> aColumns = new ::connectivity::OSQLColumns();
+ ::rtl::Reference< ::connectivity::OSQLColumns> aColumns = new ::connectivity::OSQLColumns();
::std::vector< ::rtl::OUString> aNames;
::rtl::OUString aDescription;
- // ConfigManager* pConfigMgr = ConfigManager::GetConfigManager();
- // Locale aLocale;
- // pConfigMgr->GetDirectConfigProperty(ConfigManager::LOCALE) >>= aLocale;
Locale aLocale = SvtSysLocale().GetLocaleData().getLocale();
if ( rParent.m_pColumns )
@@ -2873,7 +2800,7 @@ ORowSetClone::ORowSetClone( const ::comphelper::ComponentContext& _rContext, ORo
pColumn->setFastPropertyValue_NoBroadcast(PROPERTY_ID_HELPTEXT,xColumn->getPropertyValue(PROPERTY_HELPTEXT));
pColumn->setFastPropertyValue_NoBroadcast(PROPERTY_ID_CONTROLDEFAULT,xColumn->getPropertyValue(PROPERTY_CONTROLDEFAULT));
- } // for(sal_Int32 i=1;pIter != pEnd ;++pIter,++i)
+ }
}
Reference<XDatabaseMetaData> xMeta = rParent.m_xActiveConnection->getMetaData();
m_pColumns = new ORowSetDataColumns(xMeta.is() && xMeta->supportsMixedCaseQuotedIdentifiers(),
@@ -2882,7 +2809,6 @@ ORowSetClone::ORowSetClone( const ::comphelper::ComponentContext& _rContext, ORo
sal_Int32 nRT = PropertyAttribute::READONLY | PropertyAttribute::TRANSIENT;
// sdb.RowSet Properties
- // registerProperty(PROPERTY_CURSORNAME, PROPERTY_ID_CURSORNAME, PropertyAttribute::READONLY, &m_aDataSourceName, ::getCppuType(reinterpret_cast< ::rtl::OUString*>(NULL)));
registerMayBeVoidProperty(PROPERTY_ACTIVE_CONNECTION,PROPERTY_ID_ACTIVE_CONNECTION, PropertyAttribute::MAYBEVOID|PropertyAttribute::READONLY, &rParent.m_aActiveConnection, ::getCppuType(reinterpret_cast< Reference< XConnection >* >(NULL)));
registerProperty(PROPERTY_RESULTSETCONCURRENCY, PROPERTY_ID_RESULTSETCONCURRENCY, PropertyAttribute::READONLY, &m_nResultSetConcurrency,::getCppuType(reinterpret_cast< sal_Int32*>(NULL)));
registerProperty(PROPERTY_RESULTSETTYPE, PROPERTY_ID_RESULTSETTYPE, PropertyAttribute::READONLY, &m_nResultSetType, ::getCppuType(reinterpret_cast< sal_Int32*>(NULL)));
@@ -2891,19 +2817,18 @@ ORowSetClone::ORowSetClone( const ::comphelper::ComponentContext& _rContext, ORo
registerProperty(PROPERTY_ISBOOKMARKABLE, PROPERTY_ID_ISBOOKMARKABLE, nRT, &m_bIsBookmarable, ::getBooleanCppuType());
}
-//--------------------------------------------------------------------------
ORowSetClone::~ORowSetClone()
{
DBG_DTOR(ORowSetClone, NULL);
}
+
// com::sun::star::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > ORowSetClone::getTypes() throw (RuntimeException)
{
return ::comphelper::concatSequences(OSubComponent::getTypes(),ORowSetBase::getTypes());
}
+
// com::sun::star::XInterface
-//--------------------------------------------------------------------------
Any ORowSetClone::queryInterface( const Type & rType ) throw (RuntimeException)
{
Any aRet = ORowSetBase::queryInterface(rType);
@@ -2911,32 +2836,28 @@ Any ORowSetClone::queryInterface( const Type & rType ) throw (RuntimeException)
aRet = OSubComponent::queryInterface(rType);
return aRet;
}
-//------------------------------------------------------------------------------
+
void ORowSetClone::acquire() throw()
{
OSubComponent::acquire();
}
-//------------------------------------------------------------------------------
void ORowSetClone::release() throw()
{
OSubComponent::release();
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString ORowSetClone::getImplementationName( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.ORowSetClone");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ORowSetClone"));
}
-//------------------------------------------------------------------------------
sal_Bool ORowSetClone::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > ORowSetClone::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 2 );
@@ -2946,7 +2867,6 @@ Sequence< ::rtl::OUString > ORowSetClone::getSupportedServiceNames( ) throw (Ru
}
// OComponentHelper
-//------------------------------------------------------------------------------
void ORowSetClone::disposing()
{
MutexGuard aGuard( m_aMutex );
@@ -2958,7 +2878,6 @@ void ORowSetClone::disposing()
}
// XCloseable
-//------------------------------------------------------------------------------
void ORowSetClone::close(void) throw( SQLException, RuntimeException )
{
{
@@ -2968,7 +2887,6 @@ void ORowSetClone::close(void) throw( SQLException, RuntimeException )
}
dispose();
}
-// -------------------------------------------------------------------------
// comphelper::OPropertyArrayUsageHelper
::cppu::IPropertyArrayHelper* ORowSetClone::createArrayHelper( ) const
@@ -2977,7 +2895,6 @@ void ORowSetClone::close(void) throw( SQLException, RuntimeException )
describeProperties(aProps);
return new ::cppu::OPropertyArrayHelper(aProps);
}
-// -------------------------------------------------------------------------
// cppu::OPropertySetHelper
::cppu::IPropertyArrayHelper& SAL_CALL ORowSetClone::getInfoHelper()
@@ -2985,8 +2902,7 @@ void ORowSetClone::close(void) throw( SQLException, RuntimeException )
typedef ::comphelper::OPropertyArrayUsageHelper<ORowSetClone> ORowSetClone_PROP;
return *ORowSetClone_PROP::getArrayHelper();
}
-// -------------------------------------------------------------------------
-//--------------------------------------------------------------------------
+
Sequence< sal_Int8 > ORowSetClone::getUnoTunnelImplementationId()
{
static ::cppu::OImplementationId * pId = 0;
@@ -3001,7 +2917,7 @@ Sequence< sal_Int8 > ORowSetClone::getUnoTunnelImplementationId()
}
return pId->getImplementationId();
}
-// -----------------------------------------------------------------------------
+
// com::sun::star::XUnoTunnel
sal_Int64 SAL_CALL ORowSetClone::getSomething( const Sequence< sal_Int8 >& rId ) throw(RuntimeException)
{
@@ -3010,7 +2926,7 @@ sal_Int64 SAL_CALL ORowSetClone::getSomething( const Sequence< sal_Int8 >& rId )
return 0;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ORowSetClone::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception)
{
if ( nHandle == PROPERTY_ID_FETCHSIZE )
@@ -3022,46 +2938,40 @@ void SAL_CALL ORowSetClone::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,c
OPropertyStateContainer::setFastPropertyValue_NoBroadcast(nHandle,rValue);
}
-// -----------------------------------------------------------------------------
void ORowSetClone::doCancelModification( )
{
- //OSL_ENSURE( sal_False, "ORowSetClone::doCancelModification: invalid call!" );
}
-// -----------------------------------------------------------------------------
sal_Bool ORowSetClone::isModification( )
{
return sal_False;
}
-// -----------------------------------------------------------------------------
sal_Bool ORowSetClone::isModified( )
{
return sal_False;
}
-// -----------------------------------------------------------------------------
sal_Bool ORowSetClone::isNew( )
{
return sal_False;
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSetClone::execute( ) throw(SQLException, RuntimeException)
{
throwFunctionNotSupportedException( "RowSetClone::XRowSet::execute", *this );
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSetClone::addRowSetListener( const Reference< XRowSetListener >& ) throw(RuntimeException)
{
throwFunctionNotSupportedException( "RowSetClone::XRowSet", *this );
}
-// -------------------------------------------------------------------------
void SAL_CALL ORowSetClone::removeRowSetListener( const Reference< XRowSetListener >& ) throw(RuntimeException)
{
throwFunctionNotSupportedException( "RowSetClone::XRowSet", *this );
}
} // dbaccess
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSet.hxx b/dbaccess/source/core/api/RowSet.hxx
index 8a85237cb928..891d4a2f18ae 100644
--- a/dbaccess/source/core/api/RowSet.hxx
+++ b/dbaccess/source/core/api/RowSet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -99,8 +100,8 @@ namespace dbaccess
*/
ORowSetValueVector m_aPrematureParamValues;
ORowSetValueVector m_aParameterValueForCache;
- ::std::bit_vector m_aParametersSet;
- ::std::bit_vector m_aReadOnlyDataColumns;
+ ::std::vector<bool> m_aParametersSet;
+ ::std::vector<bool> m_aReadOnlyDataColumns;
::cppu::OInterfaceContainerHelper m_aRowsetListeners;
::cppu::OInterfaceContainerHelper m_aApproveListeners;
@@ -145,6 +146,7 @@ namespace dbaccess
sal_Bool m_bNew ;
sal_Bool m_bCanUpdateInsertedRows;
sal_Bool m_bOwnConnection;
+ sal_Bool m_bPropChangeNotifyEnabled;
private:
/** builds m_aActiveCommand from our settings
@@ -177,7 +179,7 @@ namespace dbaccess
m_xActiveConnection points to a valid SDB-level connection
@throws com::sun::star::sdb::SQLException
- if an database-related error occured
+ if an database-related error occurred
@throws com::sun::star::uno::RuntimeException
if any of the components involved throws a com::sun::star::uno::RuntimeException
@@ -248,6 +250,7 @@ namespace dbaccess
virtual sal_Bool isModification( );
virtual sal_Bool isModified( );
virtual sal_Bool isNew( );
+ virtual sal_Bool isPropertyChangeNotificationEnabled() const;
virtual ~ORowSet();
@@ -542,3 +545,4 @@ namespace dbaccess
}
#endif // DBACCESS_CORE_API_ROWSET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSetBase.cxx b/dbaccess/source/core/api/RowSetBase.cxx
index b8f489d65728..5b526137215e 100644
--- a/dbaccess/source/core/api/RowSetBase.cxx
+++ b/dbaccess/source/core/api/RowSetBase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -70,7 +71,6 @@ namespace dbaccess
// =========================================================================
// = OEmptyCollection
// =========================================================================
-// -------------------------------------------------------------------------
class OEmptyCollection : public sdbcx::OCollection
{
protected:
@@ -79,22 +79,21 @@ protected:
public:
OEmptyCollection(::cppu::OWeakObject& _rParent,::osl::Mutex& _rMutex) : OCollection(_rParent,sal_True,_rMutex,::std::vector< ::rtl::OUString>()){}
};
-// -----------------------------------------------------------------------------
+
void OEmptyCollection::impl_refresh() throw(RuntimeException)
{
}
-// -----------------------------------------------------------------------------
+
connectivity::sdbcx::ObjectType OEmptyCollection::createObject(const ::rtl::OUString& /*_rName*/)
{
return connectivity::sdbcx::ObjectType();
}
-// -----------------------------------------------------------------------------
// =========================================================================
// = ORowSetBase
// =========================================================================
DBG_NAME(ORowSetBase)
-// -------------------------------------------------------------------------
+
ORowSetBase::ORowSetBase( const ::comphelper::ComponentContext& _rContext, ::cppu::OBroadcastHelper& _rBHelper, ::osl::Mutex* _pMutex )
:OPropertyStateContainer(_rBHelper)
,m_pMutex(_pMutex)
@@ -124,7 +123,7 @@ ORowSetBase::ORowSetBase( const ::comphelper::ComponentContext& _rContext, ::cpp
registerPropertyNoMember( PROPERTY_ROWCOUNT, PROPERTY_ID_ROWCOUNT, nRBT, ::getCppuType( &nInitialRowCountValue ), &nInitialRowCountValue );
registerPropertyNoMember( PROPERTY_ISROWCOUNTFINAL, PROPERTY_ID_ISROWCOUNTFINAL, nRBT, ::getBooleanCppuType(), &bInitialRowCountFinalValue );
}
-// -----------------------------------------------------------------------------
+
ORowSetBase::~ORowSetBase()
{
if(m_pColumns)
@@ -141,15 +140,15 @@ ORowSetBase::~ORowSetBase()
DBG_DTOR(ORowSetBase,NULL);
}
+
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > ORowSetBase::getTypes() throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getTypes" );
return ::comphelper::concatSequences(ORowSetBase_BASE::getTypes(),OPropertyStateContainer::getTypes());
}
+
// com::sun::star::uno::XInterface
-//--------------------------------------------------------------------------
Any ORowSetBase::queryInterface( const Type & rType ) throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::queryInterface" );
@@ -158,7 +157,7 @@ Any ORowSetBase::queryInterface( const Type & rType ) throw (RuntimeException)
aRet = OPropertyStateContainer::queryInterface(rType);
return aRet;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSetBase::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getFastPropertyValue" );
@@ -179,7 +178,7 @@ void SAL_CALL ORowSetBase::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) c
else
OPropertyStateContainer::getFastPropertyValue(rValue,nHandle);
}
-// -------------------------------------------------------------------------
+
// OComponentHelper
void SAL_CALL ORowSetBase::disposing(void)
{
@@ -198,7 +197,7 @@ void SAL_CALL ORowSetBase::disposing(void)
}
m_pCache = NULL;
}
-// -------------------------------------------------------------------------
+
// comphelper::OPropertyArrayUsageHelper
::cppu::IPropertyArrayHelper* ORowSetBase::createArrayHelper( ) const
{
@@ -207,14 +206,14 @@ void SAL_CALL ORowSetBase::disposing(void)
describeProperties(aProps);
return new ::cppu::OPropertyArrayHelper(aProps);
}
-// -------------------------------------------------------------------------
+
// cppu::OPropertySetHelper
::cppu::IPropertyArrayHelper& SAL_CALL ORowSetBase::getInfoHelper()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getInfoHelper" );
return *const_cast<ORowSetBase*>(this)->getArrayHelper();
}
-// -------------------------------------------------------------------------
+
// XRow
sal_Bool SAL_CALL ORowSetBase::wasNull( ) throw(SQLException, RuntimeException)
{
@@ -223,27 +222,26 @@ sal_Bool SAL_CALL ORowSetBase::wasNull( ) throw(SQLException, RuntimeException)
checkCache();
return impl_wasNull();
}
-// -----------------------------------------------------------------------------
+
sal_Bool ORowSetBase::impl_wasNull()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::impl_wasNull" );
- return ((m_nLastColumnIndex != -1) && !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->isValid()) ? ((*m_aCurrentRow)->get())[m_nLastColumnIndex].isNull() : sal_True;
+ return ((m_nLastColumnIndex != -1) && !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->is()) ? ((*m_aCurrentRow)->get())[m_nLastColumnIndex].isNull() : sal_True;
}
-// -----------------------------------------------------------------------------
const ORowSetValue& ORowSetBase::getValue(sal_Int32 columnIndex)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getValue" );
checkCache();
return impl_getValue(columnIndex);
}
-// -----------------------------------------------------------------------------
+
const ORowSetValue& ORowSetBase::impl_getValue(sal_Int32 columnIndex)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::impl_getValue" );
if ( m_bBeforeFirst || m_bAfterLast )
{
- OSL_ENSURE(0,"ORowSetBase::getValue: Illegal call here (we're before first or after last)!");
+ OSL_FAIL("ORowSetBase::getValue: Illegal call here (we're before first or after last)!");
::dbtools::throwSQLException( DBACORE_RESSTRING( RID_STR_CURSOR_BEFORE_OR_AFTER ), SQL_INVALID_CURSOR_POSITION, *m_pMySelf );
}
@@ -252,7 +250,7 @@ const ORowSetValue& ORowSetBase::impl_getValue(sal_Int32 columnIndex)
return m_aEmptyValue;
}
- bool bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->isValid() );
+ bool bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->is() );
if ( !bValidCurrentRow )
{
// currentrow is null when the clone moves the window
@@ -261,7 +259,7 @@ const ORowSetValue& ORowSetBase::impl_getValue(sal_Int32 columnIndex)
m_bIsInsertRow = sal_False;
OSL_ENSURE(!m_aCurrentRow.isNull(),"ORowSetBase::getValue: we don't stand on a valid row! Row is null.");
- bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->isValid() );
+ bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->is() );
}
if ( bValidCurrentRow )
@@ -278,14 +276,14 @@ const ORowSetValue& ORowSetBase::impl_getValue(sal_Int32 columnIndex)
ORowSetMatrix::iterator k = aHelper.aIterator;
for (; k != m_pCache->getEnd(); ++k)
{
- ORowSetValueVector* pTemp = k->getBodyPtr();
+ ORowSetValueVector* pTemp = k->get();
OSL_ENSURE( pTemp != (void*)0xfeeefeee,"HALT!" );
}
#endif
OSL_ENSURE(!m_aCurrentRow.isNull() && m_aCurrentRow < m_pCache->getEnd() && aCacheIter != m_pCache->m_aCacheIterators.end(),"Invalid iterator set for currentrow!");
#if OSL_DEBUG_LEVEL > 0
ORowSetRow rRow = (*m_aCurrentRow);
- OSL_ENSURE(rRow.isValid() && static_cast<sal_uInt16>(columnIndex) < (rRow->get()).size(),"Invalid size of vector!");
+ OSL_ENSURE(rRow.is() && static_cast<sal_uInt16>(columnIndex) < (rRow->get()).size(),"Invalid size of vector!");
#endif
return ((*m_aCurrentRow)->get())[m_nLastColumnIndex = columnIndex];
}
@@ -293,91 +291,91 @@ const ORowSetValue& ORowSetBase::impl_getValue(sal_Int32 columnIndex)
// we should normally never reach this
return m_aEmptyValue;
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL ORowSetBase::getString( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getString" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::getBoolean( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getBoolean" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int8 SAL_CALL ORowSetBase::getByte( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getByte" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int16 SAL_CALL ORowSetBase::getShort( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getShort" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL ORowSetBase::getInt( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getInt" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
sal_Int64 SAL_CALL ORowSetBase::getLong( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getLong" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
float SAL_CALL ORowSetBase::getFloat( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getFloat" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
double SAL_CALL ORowSetBase::getDouble( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getDouble" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
Sequence< sal_Int8 > SAL_CALL ORowSetBase::getBytes( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getBytes" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Date SAL_CALL ORowSetBase::getDate( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getDate" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::Time SAL_CALL ORowSetBase::getTime( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getTime" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
::com::sun::star::util::DateTime SAL_CALL ORowSetBase::getTimestamp( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getTimestamp" );
::osl::MutexGuard aGuard( *m_pMutex );
return getValue(columnIndex);
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSetBase::getBinaryStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getBinaryStream" );
@@ -386,7 +384,7 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSetBase::getBinaryS
if ( m_bBeforeFirst || m_bAfterLast )
{
- OSL_ENSURE(0,"ORowSetBase::getBinaryStream: Illegal call here (we're before first or after last)!");
+ OSL_FAIL("ORowSetBase::getBinaryStream: Illegal call here (we're before first or after last)!");
::dbtools::throwSQLException( DBACORE_RESSTRING( RID_STR_CURSOR_BEFORE_OR_AFTER ), SQL_INVALID_CURSOR_POSITION, *m_pMySelf );
}
@@ -395,7 +393,7 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSetBase::getBinaryS
return NULL;
}
- bool bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->isValid() );
+ bool bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->is() );
if ( !bValidCurrentRow )
{
positionCache( MOVE_NONE_REFRESH_ONLY );
@@ -403,7 +401,7 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSetBase::getBinaryS
m_bIsInsertRow = sal_False;
OSL_ENSURE(!m_aCurrentRow.isNull(),"ORowSetBase::getBinaryStream: we don't stand on a valid row! Row is null.");
- bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->isValid() );
+ bValidCurrentRow = ( !m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd() && m_aCurrentRow->is() );
}
if ( bValidCurrentRow )
@@ -412,13 +410,13 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSetBase::getBinaryS
// we should normally never reach this
return Reference< ::com::sun::star::io::XInputStream >();
}
-// -------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > SAL_CALL ORowSetBase::getCharacterStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getCharacterStream" );
return getBinaryStream(columnIndex);
}
-// -------------------------------------------------------------------------
+
Any SAL_CALL ORowSetBase::getObject( sal_Int32 columnIndex, const Reference< XNameAccess >& /*typeMap*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getObject" );
@@ -427,38 +425,38 @@ Any SAL_CALL ORowSetBase::getObject( sal_Int32 columnIndex, const Reference< XNa
return getValue(columnIndex).makeAny();
}
-// -------------------------------------------------------------------------
+
Reference< XRef > SAL_CALL ORowSetBase::getRef( sal_Int32 /*columnIndex*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getRef" );
::dbtools::throwFeatureNotImplementedException( "XRow::getRef", *m_pMySelf );
return NULL;
}
-// -------------------------------------------------------------------------
+
Reference< XBlob > SAL_CALL ORowSetBase::getBlob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getBlob" );
return Reference< XBlob >(getValue(columnIndex).makeAny(),UNO_QUERY);
}
-// -------------------------------------------------------------------------
+
Reference< XClob > SAL_CALL ORowSetBase::getClob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getClob" );
return Reference< XClob >(getValue(columnIndex).makeAny(),UNO_QUERY);
}
-// -------------------------------------------------------------------------
+
Reference< XArray > SAL_CALL ORowSetBase::getArray( sal_Int32 /*columnIndex*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getArray" );
::dbtools::throwFeatureNotImplementedException( "XRow::getArray", *m_pMySelf );
return NULL;
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XRowLocate
Any SAL_CALL ORowSetBase::getBookmark( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getBookmark" );
- DBG_TRACE2("DBACCESS ORowSetBase::getBookmark() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::getBookmark() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::MutexGuard aGuard( *m_pMutex );
checkCache();
@@ -472,20 +470,20 @@ Any SAL_CALL ORowSetBase::getBookmark( ) throw(SQLException, RuntimeException)
OSL_ENSURE( m_aBookmark.hasValue(), "ORowSetBase::getBookmark: bookmark has no value!" );
return m_aBookmark;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::moveToBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::moveToBookmark" );
- DBG_TRACE2("DBACCESS ORowSetBase::moveToBookmark(Any) Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::moveToBookmark(Any) Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
OSL_ENSURE(bookmark.hasValue(),"ORowSetBase::moveToBookmark bookmark has no value!");
::osl::ResettableMutexGuard aGuard( *m_pMutex );
if(!bookmark.hasValue() || m_nResultSetType == ResultSetType::FORWARD_ONLY)
{
if(bookmark.hasValue())
- OSL_ENSURE(0,"MoveToBookmark is not possible when we are only forward");
+ OSL_FAIL("MoveToBookmark is not possible when we are only forward");
else
- OSL_ENSURE(0,"Bookmark is not valid");
+ OSL_FAIL("Bookmark is not valid");
throwFunctionSequenceException(*m_pMySelf);
}
@@ -521,14 +519,14 @@ sal_Bool SAL_CALL ORowSetBase::moveToBookmark( const Any& bookmark ) throw(SQLEx
// - IsNew
aNotifier.fire( );
}
- DBG_TRACE2("DBACCESS ORowSetBase::moveToBookmark(Any) = %i Clone = %i\n",bRet,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::moveToBookmark(Any) = %i Clone = %i\n",bRet,m_bClone);
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::moveRelativeToBookmark( const Any& bookmark, sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::moveRelativeToBookmark" );
- DBG_TRACE2("DBACCESS ORowSetBase::moveRelativeToBookmark(Any,%i) Clone = %i\n",rows,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::moveRelativeToBookmark(Any,%i) Clone = %i\n",rows,m_bClone);
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::ResettableMutexGuard aGuard( *m_pMutex );
@@ -565,10 +563,10 @@ sal_Bool SAL_CALL ORowSetBase::moveRelativeToBookmark( const Any& bookmark, sal_
// RowCount/IsRowCountFinal
fireRowcount();
}
- DBG_TRACE3("DBACCESS ORowSetBase::moveRelativeToBookmark(Any,%i) = %i Clone = %i\n",rows,bRet,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::moveRelativeToBookmark(Any,%i) = %i Clone = %i\n",rows,bRet,m_bClone);
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL ORowSetBase::compareBookmarks( const Any& _first, const Any& _second ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::compareBookmarks" );
@@ -576,7 +574,7 @@ sal_Int32 SAL_CALL ORowSetBase::compareBookmarks( const Any& _first, const Any&
checkCache();
return m_pCache->compareBookmarks(_first,_second);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::hasOrderedBookmarks( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::hasOrderedBookmarks" );
@@ -584,7 +582,7 @@ sal_Bool SAL_CALL ORowSetBase::hasOrderedBookmarks( ) throw(SQLException, Runti
checkCache();
return m_pCache->hasOrderedBookmarks();
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL ORowSetBase::hashBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::hashBookmark" );
@@ -592,8 +590,7 @@ sal_Int32 SAL_CALL ORowSetBase::hashBookmark( const Any& bookmark ) throw(SQLExc
checkCache();
return m_pCache->hashBookmark(bookmark);
}
-// -------------------------------------------------------------------------
-// -------------------------------------------------------------------------
+
// XResultSetMetaDataSupplier
Reference< XResultSetMetaData > SAL_CALL ORowSetBase::getMetaData( ) throw(SQLException, RuntimeException)
{
@@ -606,7 +603,6 @@ Reference< XResultSetMetaData > SAL_CALL ORowSetBase::getMetaData( ) throw(SQLE
return xMeta;
}
-// -------------------------------------------------------------------------
// XColumnLocate
sal_Int32 SAL_CALL ORowSetBase::findColumn( const ::rtl::OUString& columnName ) throw(SQLException, RuntimeException)
@@ -615,10 +611,9 @@ sal_Int32 SAL_CALL ORowSetBase::findColumn( const ::rtl::OUString& columnName )
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::MutexGuard aGuard( m_aColumnsMutex );
- // it is possible to save some time her when we remember the names - position relation in a map
+ // it is possible to save some time here when we remember the names - position relation in a map
return m_pColumns ? m_pColumns->findColumn(columnName) : sal_Int32(0);
}
-// -------------------------------------------------------------------------
// ::com::sun::star::sdbcx::XColumnsSupplier
Reference< XNameAccess > SAL_CALL ORowSetBase::getColumns( ) throw(RuntimeException)
@@ -636,12 +631,12 @@ Reference< XNameAccess > SAL_CALL ORowSetBase::getColumns( ) throw(RuntimeExcep
return m_pColumns;
}
-// -------------------------------------------------------------------------
+
// XResultSet
sal_Bool SAL_CALL ORowSetBase::next( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::next" );
- DBG_TRACE2("DBACCESS ORowSetBase::next() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::next() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::osl::ResettableMutexGuard aGuard( *m_pMutex );
checkCache();
@@ -661,7 +656,6 @@ sal_Bool SAL_CALL ORowSetBase::next( ) throw(SQLException, RuntimeException)
bRet = m_pCache->next();
doCancelModification( );
-
if ( bRet || bAfterLast != m_pCache->isAfterLast() )
{
// notification order
@@ -684,10 +678,10 @@ sal_Bool SAL_CALL ORowSetBase::next( ) throw(SQLException, RuntimeException)
// - RowCount/IsRowCountFinal
fireRowcount();
}
- DBG_TRACE3("DBACCESS ORowSetBase::next() = %i Clone = %i ID = %i\n",bRet,m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::next() = %i Clone = %i ID = %i\n",bRet,m_bClone,osl_getThreadIdentifier(NULL));
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::isBeforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::isBeforeFirst" );
@@ -695,32 +689,32 @@ sal_Bool SAL_CALL ORowSetBase::isBeforeFirst( ) throw(SQLException, RuntimeExce
::osl::MutexGuard aGuard( *m_pMutex );
checkCache();
- DBG_TRACE2("DBACCESS ORowSetBase::isBeforeFirst() = %i Clone = %i\n",m_bBeforeFirst,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::isBeforeFirst() = %i Clone = %i\n",m_bBeforeFirst,m_bClone);
return m_bBeforeFirst;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::isAfterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::isAfterLast" );
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::MutexGuard aGuard( *m_pMutex );
checkCache();
- DBG_TRACE2("DBACCESS ORowSetBase::isAfterLast() = %i Clone = %i\n",m_bAfterLast,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::isAfterLast() = %i Clone = %i\n",m_bAfterLast,m_bClone);
return m_bAfterLast;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetBase::isOnFirst()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::isOnFirst" );
return isFirst();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::isFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::isFirst" );
- DBG_TRACE2("DBACCESS ORowSetBase::isFirst() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::isFirst() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::MutexGuard aGuard( *m_pMutex );
@@ -735,20 +729,20 @@ sal_Bool SAL_CALL ORowSetBase::isFirst( ) throw(SQLException, RuntimeException)
positionCache( MOVE_NONE_REFRESH_ONLY );
sal_Bool bIsFirst = m_pCache->isFirst();
- DBG_TRACE2("DBACCESS ORowSetBase::isFirst() = %i Clone = %i\n",bIsFirst,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::isFirst() = %i Clone = %i\n",bIsFirst,m_bClone);
return bIsFirst;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetBase::isOnLast()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::isOnLast" );
return isLast();
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::isLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::isLast" );
- DBG_TRACE2("DBACCESS ORowSetBase::isLast() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::isLast() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::MutexGuard aGuard( *m_pMutex );
checkCache();
@@ -767,14 +761,14 @@ sal_Bool SAL_CALL ORowSetBase::isLast( ) throw(SQLException, RuntimeException)
positionCache( MOVE_NONE_REFRESH_ONLY );
sal_Bool bIsLast = m_pCache->isLast();
- DBG_TRACE2("DBACCESS ORowSetBase::isLast() = %i Clone = %i\n",bIsLast,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::isLast() = %i Clone = %i\n",bIsLast,m_bClone);
return bIsLast;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSetBase::beforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::beforeFirst" );
- DBG_TRACE2("DBACCESS ORowSetBase::beforeFirst() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::beforeFirst() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::ResettableMutexGuard aGuard( *m_pMutex );
@@ -810,13 +804,13 @@ void SAL_CALL ORowSetBase::beforeFirst( ) throw(SQLException, RuntimeException)
// to be done _after_ the notifications!
m_aOldRow->clearRow();
}
- DBG_TRACE2("DBACCESS ORowSetBase::beforeFirst() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::beforeFirst() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSetBase::afterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::afterLast" );
- DBG_TRACE2("DBACCESS ORowSetBase::afterLast() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::afterLast() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::ResettableMutexGuard aGuard( *m_pMutex );
@@ -850,14 +844,14 @@ void SAL_CALL ORowSetBase::afterLast( ) throw(SQLException, RuntimeException)
fireRowcount();
}
}
- DBG_TRACE2("DBACCESS ORowSetBase::afterLast() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::afterLast() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::move( ::std::mem_fun_t<sal_Bool,ORowSetBase>& _aCheckFunctor,
::std::mem_fun_t<sal_Bool,ORowSetCache>& _aMovementFunctor)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::move" );
- DBG_TRACE2("DBACCESS ORowSetBase::move() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::move() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::ResettableMutexGuard aGuard( *m_pMutex );
checkPositioningAllowed();
@@ -897,38 +891,38 @@ sal_Bool SAL_CALL ORowSetBase::move( ::std::mem_fun_t<sal_Bool,ORowSetBase>&
// - RowCount/IsRowCountFinal
fireRowcount();
}
- DBG_TRACE2("DBACCESS ORowSetBase::move() = %i Clone = %i\n",bRet,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::move() = %i Clone = %i\n",bRet,m_bClone);
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::first( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::first" );
- DBG_TRACE2("DBACCESS ORowSetBase::first() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::first() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::std::mem_fun_t<sal_Bool,ORowSetBase> ioF_tmp(&ORowSetBase::isOnFirst);
::std::mem_fun_t<sal_Bool,ORowSetCache> F_tmp(&ORowSetCache::first);
return move(ioF_tmp,F_tmp);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::last( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::last" );
- DBG_TRACE2("DBACCESS ORowSetBase::last() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::last() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::std::mem_fun_t<sal_Bool,ORowSetBase> ioL_tmp(&ORowSetBase::isOnLast);
::std::mem_fun_t<sal_Bool,ORowSetCache> L_tmp(&ORowSetCache::last);
return move(ioL_tmp,L_tmp);
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL ORowSetBase::getRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getRow" );
- DBG_TRACE2("DBACCESS ORowSetBase::getRow() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::getRow() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::osl::MutexGuard aGuard( *m_pMutex );
checkCache();
return impl_getRow();
}
-// -------------------------------------------------------------------------
+
sal_Int32 ORowSetBase::impl_getRow()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::impl_getRow" );
@@ -952,14 +946,14 @@ sal_Int32 ORowSetBase::impl_getRow()
}
nPos = m_pCache->getRow();
}
- DBG_TRACE3("DBACCESS ORowSetBase::impl_getRow() = %i Clone = %i ID = %i\n",nPos,m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::impl_getRow() = %i Clone = %i ID = %i\n",nPos,m_bClone,osl_getThreadIdentifier(NULL));
return nPos;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::absolute( sal_Int32 row ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::absolute" );
- DBG_TRACE2("DBACCESS ORowSetBase::absolute(%i) Clone = %i\n",row,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::absolute(%i) Clone = %i\n",row,m_bClone);
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::ResettableMutexGuard aGuard( *m_pMutex );
checkPositioningAllowed();
@@ -998,14 +992,14 @@ sal_Bool SAL_CALL ORowSetBase::absolute( sal_Int32 row ) throw(SQLException, Run
// - RowCount/IsRowCountFinal
fireRowcount();
}
- DBG_TRACE3("DBACCESS ORowSetBase::absolute(%i) = %i Clone = %i\n",row,bRet,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::absolute(%i) = %i Clone = %i\n",row,bRet,m_bClone);
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::relative( sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::relative" );
- DBG_TRACE2("DBACCESS ORowSetBase::relative(%i) Clone = %i\n",rows,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::relative(%i) Clone = %i\n",rows,m_bClone);
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::ResettableMutexGuard aGuard( *m_pMutex );
@@ -1054,14 +1048,14 @@ sal_Bool SAL_CALL ORowSetBase::relative( sal_Int32 rows ) throw(SQLException, Ru
// - RowCount/IsRowCountFinal
fireRowcount();
}
- DBG_TRACE3("DBACCESS ORowSetBase::relative(%i) = %i Clone = %i\n",rows,bRet,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::relative(%i) = %i Clone = %i\n",rows,bRet,m_bClone);
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::previous( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::previous" );
- DBG_TRACE2("DBACCESS ORowSetBase::previous() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::previous() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
::connectivity::checkDisposed(m_rBHelper.bDisposed);
::osl::ResettableMutexGuard aGuard( *m_pMutex );
@@ -1094,7 +1088,7 @@ sal_Bool SAL_CALL ORowSetBase::previous( ) throw(SQLException, RuntimeException
}
else
{
- DBG_ERROR( "ORowSetBase::previous: inconsistency!" );
+ OSL_FAIL( "ORowSetBase::previous: inconsistency!" );
// we should never reach this place, as we should not get into this whole branch if m_bBeforeFirst
// was |true| from the beginning
movementFailed();
@@ -1107,17 +1101,16 @@ sal_Bool SAL_CALL ORowSetBase::previous( ) throw(SQLException, RuntimeException
// - RowCount/IsRowCountFinal
fireRowcount();
}
- DBG_TRACE2("DBACCESS ORowSetBase::previous() = %i Clone = %i\n",bRet,m_bClone);
+ OSL_TRACE("DBACCESS ORowSetBase::previous() = %i Clone = %i\n",bRet,m_bClone);
return bRet;
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::setCurrentRow( sal_Bool _bMoved, sal_Bool _bDoNotify, const ORowSetRow& _rOldValues, ::osl::ResettableMutexGuard& _rGuard )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::setCurrentRow" );
- DBG_TRACE2("DBACCESS ORowSetBase::setCurrentRow() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::setCurrentRow() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
m_bBeforeFirst = m_pCache->isBeforeFirst();
m_bAfterLast = m_pCache->isAfterLast();
- //m_pCache->resetInsertRow(sal_True);
if(!(m_bBeforeFirst || m_bAfterLast))
{
@@ -1128,7 +1121,7 @@ void ORowSetBase::setCurrentRow( sal_Bool _bMoved, sal_Bool _bDoNotify, const OR
OSL_ENSURE(!m_aCurrentRow.isNull(),"CurrentRow is null!");
m_aCurrentRow.setBookmark(m_aBookmark);
OSL_ENSURE(!m_aCurrentRow.isNull() && m_aCurrentRow != m_pCache->getEnd(),"Position of matrix iterator isn't valid!");
- OSL_ENSURE(m_aCurrentRow->isValid(),"Currentrow isn't valid");
+ OSL_ENSURE(m_aCurrentRow->is(),"Currentrow isn't valid");
OSL_ENSURE(m_aBookmark.hasValue(),"Bookmark has no value!");
#if OSL_DEBUG_LEVEL > 0
@@ -1144,10 +1137,9 @@ void ORowSetBase::setCurrentRow( sal_Bool _bMoved, sal_Bool _bDoNotify, const OR
OSL_ENSURE(!m_aCurrentRow.isNull(),"CurrentRow is nul after positionCache!");
#if OSL_DEBUG_LEVEL > 0
ORowSetRow rRow = (*m_aCurrentRow);
- OSL_ENSURE(rRow.isValid() ,"Invalid size of vector!");
+ OSL_ENSURE(rRow.is() ,"Invalid size of vector!");
#endif
// the cache could repositioned so we need to adjust the cache
- // #104144# OJ
if ( _bMoved && m_aCurrentRow.isNull() )
{
positionCache( MOVE_NONE_REFRESH_ONLY );
@@ -1170,29 +1162,29 @@ void ORowSetBase::setCurrentRow( sal_Bool _bMoved, sal_Bool _bDoNotify, const OR
firePropertyChange(_rOldValues);
// TODO: can this be done before the notifications?
- if(!(m_bBeforeFirst || m_bAfterLast) && !m_aCurrentRow.isNull() && m_aCurrentRow->isValid() && m_aCurrentRow != m_pCache->getEnd())
- m_aOldRow->setRow(new ORowSetValueVector(m_aCurrentRow->getBody()));
+ if(!(m_bBeforeFirst || m_bAfterLast) && !m_aCurrentRow.isNull() && m_aCurrentRow->is() && m_aCurrentRow != m_pCache->getEnd())
+ m_aOldRow->setRow(new ORowSetValueVector( *(*m_aCurrentRow) ));
if ( _bMoved && _bDoNotify )
// - cursorMoved
notifyAllListenersCursorMoved( _rGuard );
- DBG_TRACE2("DBACCESS ORowSetBase::setCurrentRow() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::setCurrentRow() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::checkPositioningAllowed() throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::checkPositioningAllowed" );
if(!m_pCache || m_nResultSetType == ResultSetType::FORWARD_ONLY)
throwFunctionSequenceException(*m_pMySelf);
}
-//------------------------------------------------------------------------------
+
Reference< XInterface > ORowSetBase::getStatement(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getStatement" );
return NULL;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSetBase::refreshRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::refreshRow" );
@@ -1211,7 +1203,7 @@ void SAL_CALL ORowSetBase::refreshRow( ) throw(SQLException, RuntimeException)
firePropertyChange(aOldValues);
}
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::rowUpdated( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::rowUpdated" );
@@ -1223,7 +1215,7 @@ sal_Bool SAL_CALL ORowSetBase::rowUpdated( ) throw(SQLException, RuntimeExcepti
return m_pCache->rowUpdated();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::rowInserted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::rowInserted" );
@@ -1236,7 +1228,7 @@ sal_Bool SAL_CALL ORowSetBase::rowInserted( ) throw(SQLException, RuntimeExcept
return m_pCache->rowInserted();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL ORowSetBase::rowDeleted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::rowDeleted" );
@@ -1244,12 +1236,12 @@ sal_Bool SAL_CALL ORowSetBase::rowDeleted( ) throw(SQLException, RuntimeExcepti
checkCache();
return impl_rowDeleted();
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetBase::impl_rowDeleted( )
{
return !m_aBookmark.hasValue() && !m_bBeforeFirst && !m_bAfterLast;
}
-// -------------------------------------------------------------------------
+
// XWarningsSupplier
Any SAL_CALL ORowSetBase::getWarnings( ) throw(SQLException, RuntimeException)
{
@@ -1265,7 +1257,7 @@ Any SAL_CALL ORowSetBase::getWarnings( ) throw(SQLException, RuntimeException)
return Any();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL ORowSetBase::clearWarnings( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::clearWarnings" );
@@ -1278,11 +1270,14 @@ void SAL_CALL ORowSetBase::clearWarnings( ) throw(SQLException, RuntimeExceptio
xWarnings->clearWarnings();
}
}
-// -------------------------------------------------------------------------
+
void ORowSetBase::firePropertyChange(const ORowSetRow& _rOldRow)
{
+ if (!isPropertyChangeNotificationEnabled())
+ return;
+
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::firePropertyChange" );
- DBG_TRACE2("DBACCESS ORowSetBase::firePropertyChange() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::firePropertyChange() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
OSL_ENSURE(m_pColumns,"Columns can not be NULL here!");
#if OSL_DEBUG_LEVEL > 1
sal_Bool bNull;
@@ -1294,47 +1289,48 @@ void ORowSetBase::firePropertyChange(const ORowSetRow& _rOldRow)
try
{
TDataColumns::iterator aEnd = m_aDataColumns.end();
- for(TDataColumns::iterator aIter = m_aDataColumns.begin();aIter != aEnd;++aIter,++i) // #104278# OJ ++i inserted
- (*aIter)->fireValueChange(_rOldRow.isValid() ? (_rOldRow->get())[i+1] : ::connectivity::ORowSetValue());
+ for(TDataColumns::iterator aIter = m_aDataColumns.begin();aIter != aEnd;++aIter,++i)
+ (*aIter)->fireValueChange(_rOldRow.is() ? (_rOldRow->get())[i+1] : ::connectivity::ORowSetValue());
}
catch(Exception&)
{
- OSL_ENSURE(0,"firePropertyChange: Exception");
+ OSL_FAIL("firePropertyChange: Exception");
}
- DBG_TRACE2("DBACCESS ORowSetBase::firePropertyChange() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::firePropertyChange() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
}
-// -------------------------------------------------------------------------
+
void ORowSetBase::firePropertyChange(sal_Int32 _nPos,const ::connectivity::ORowSetValue& _rOldValue)
{
OSL_ENSURE(_nPos < (sal_Int32)m_aDataColumns.size(),"nPos is invalid!");
m_aDataColumns[_nPos]->fireValueChange(_rOldValue);
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::fireRowcount()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::fireRowcount" );
}
-// -----------------------------------------------------------------------------
sal_Bool ORowSetBase::notifyAllListenersCursorBeforeMove(::osl::ResettableMutexGuard& /*_rGuard*/)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::notifyAllListenersCursorBeforeMove" );
return sal_True;
}
-// -----------------------------------------------------------------------------
void ORowSetBase::notifyAllListenersCursorMoved(::osl::ResettableMutexGuard& /*_rGuard*/)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::notifyAllListenersCursorMoved" );
}
-// -----------------------------------------------------------------------------
void ORowSetBase::notifyAllListeners(::osl::ResettableMutexGuard& /*_rGuard*/)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::notifyAllListeners" );
}
-// -----------------------------------------------------------------------------
+sal_Bool ORowSetBase::isPropertyChangeNotificationEnabled() const
+{
+ return sal_True;
+}
+
void ORowSetBase::fireProperty( sal_Int32 _nProperty, sal_Bool _bNew, sal_Bool _bOld )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::fireProperty" );
@@ -1343,11 +1339,10 @@ void ORowSetBase::fireProperty( sal_Int32 _nProperty, sal_Bool _bNew, sal_Bool _
fire( &_nProperty, &aNew, &aOld, 1, sal_False );
}
-// -----------------------------------------------------------------------------
void ORowSetBase::positionCache( CursorMoveDirection _ePrepareForDirection )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::positionCache" );
- DBG_TRACE2("DBACCESS ORowSetBase::positionCache() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::positionCache() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
sal_Bool bSuccess = sal_False;
if ( m_aBookmark.hasValue() )
@@ -1396,10 +1391,11 @@ void ORowSetBase::positionCache( CursorMoveDirection _ePrepareForDirection )
}
}
OSL_ENSURE( bSuccess, "ORowSetBase::positionCache: failed!" );
+ (void)bSuccess;
- DBG_TRACE2("DBACCESS ORowSetBase::positionCache() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::positionCache() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::checkCache()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::checkCache" );
@@ -1407,11 +1403,11 @@ void ORowSetBase::checkCache()
if(!m_pCache)
throwFunctionSequenceException(*m_pMySelf);
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::movementFailed()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::movementFailed" );
- DBG_TRACE2("DBACCESS ORowSetBase::movementFailed() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::movementFailed() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
m_aOldRow->clearRow();
m_aCurrentRow = m_pCache->getEnd();
m_bBeforeFirst = m_pCache->isBeforeFirst();
@@ -1419,25 +1415,25 @@ void ORowSetBase::movementFailed()
m_aBookmark = Any();
m_aCurrentRow.setBookmark(m_aBookmark);
OSL_ENSURE(m_bBeforeFirst || m_bAfterLast,"BeforeFirst or AfterLast is wrong!");
- DBG_TRACE2("DBACCESS ORowSetBase::movementFailed() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
+ OSL_TRACE("DBACCESS ORowSetBase::movementFailed() Clone = %i ID = %i\n",m_bClone,osl_getThreadIdentifier(NULL));
}
-// -----------------------------------------------------------------------------
+
ORowSetRow ORowSetBase::getOldRow(sal_Bool _bWasNew)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getOldRow" );
- OSL_ENSURE(m_aOldRow.isValid(),"RowSetRowHElper isn't valid!");
+ OSL_ENSURE(m_aOldRow.is(),"RowSetRowHElper isn't valid!");
ORowSetRow aOldValues;
- if ( !_bWasNew && m_aOldRow->getRow().isValid() )
- aOldValues = new ORowSetValueVector( m_aOldRow->getRow().getBody()); // remember the old values
+ if ( !_bWasNew && m_aOldRow->getRow().is() )
+ aOldValues = new ORowSetValueVector( *(m_aOldRow->getRow())); // remember the old values
return aOldValues;
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::getPropertyDefaultByHandle( sal_Int32 /*_nHandle*/, Any& _rDefault ) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::getPropertyDefaultByHandle" );
_rDefault.clear();
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::onDeleteRow( const Any& _rBookmark )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::onDeleteRow" );
@@ -1453,7 +1449,7 @@ void ORowSetBase::onDeleteRow( const Any& _rBookmark )
m_nDeletedPosition = m_pCache->getRow();
}
}
-// -----------------------------------------------------------------------------
+
void ORowSetBase::onDeletedRow( const Any& _rBookmark, sal_Int32 _nPos )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::onDeletedRow" );
@@ -1476,7 +1472,7 @@ void ORowSetBase::onDeletedRow( const Any& _rBookmark, sal_Int32 _nPos )
m_aCurrentRow.setBookmark( m_aBookmark );
}
}
-// -----------------------------------------------------------------------------
+
sal_Int32 ORowSetBase::impl_getRowCount() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetBase::impl_getRowCount" );
@@ -1494,7 +1490,7 @@ struct ORowSetNotifierImpl
};
DBG_NAME(ORowSetNotifier)
-// -----------------------------------------------------------------------------
+
ORowSetNotifier::ORowSetNotifier( ORowSetBase* _pRowSet )
:m_pRowSet( _pRowSet )
,m_bWasNew( sal_False )
@@ -1515,7 +1511,7 @@ ORowSetNotifier::ORowSetNotifier( ORowSetBase* _pRowSet )
if ( m_pRowSet->isModification( ORowSetBase::GrantNotifierAccess() ) )
m_pRowSet->doCancelModification( ORowSetBase::GrantNotifierAccess() );
}
-// -----------------------------------------------------------------------------
+
ORowSetNotifier::ORowSetNotifier( ORowSetBase* _pRowSet,const ORowSetValueVector::Vector& i_aRow )
:m_pImpl(new ORowSetNotifierImpl)
,m_pRowSet( _pRowSet )
@@ -1530,14 +1526,13 @@ ORowSetNotifier::ORowSetNotifier( ORowSetBase* _pRowSet,const ORowSetValueVector
OSL_ENSURE( m_pRowSet, "ORowSetNotifier::ORowSetNotifier: invalid row set. This wil crash." );
m_pImpl->aRow = i_aRow; // yes, create a copy to store the old values
}
-// -----------------------------------------------------------------------------
+
ORowSetNotifier::~ORowSetNotifier( )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetNotifier::~ORowSetNotifier" );
DBG_DTOR(ORowSetNotifier,NULL);
}
-// -----------------------------------------------------------------------------
void ORowSetNotifier::fire()
{
// we're not interested in firing changes FALSE->TRUE, only TRUE->FALSE.
@@ -1557,19 +1552,19 @@ void ORowSetNotifier::fire()
m_bNotifyCalled = sal_True;
#endif
}
-// -----------------------------------------------------------------------------
+
::std::vector<sal_Int32>& ORowSetNotifier::getChangedColumns() const
{
OSL_ENSURE(m_pImpl.get(),"Illegal CTor call, use the other one!");
return m_pImpl->aChangedColumns;
}
-// -----------------------------------------------------------------------------
+
::std::vector<Any>& ORowSetNotifier::getChangedBookmarks() const
{
OSL_ENSURE(m_pImpl.get(),"Illegal CTor call, use the other one!");
return m_pImpl->aChangedBookmarks;
}
-// -----------------------------------------------------------------------------
+
void ORowSetNotifier::firePropertyChange()
{
OSL_ENSURE(m_pImpl.get(),"Illegal CTor call, use the other one!");
@@ -1585,3 +1580,5 @@ void ORowSetNotifier::firePropertyChange()
}
}
} // namespace dbaccess
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSetBase.hxx b/dbaccess/source/core/api/RowSetBase.hxx
index 83b4d2fb74ef..2a931d5af376 100644
--- a/dbaccess/source/core/api/RowSetBase.hxx
+++ b/dbaccess/source/core/api/RowSetBase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,69 +28,27 @@
#ifndef DBACCESS_CORE_API_ROWSETBASE_HXX
#define DBACCESS_CORE_API_ROWSETBASE_HXX
-#ifndef _CPPUHELPER_IMPLBASE10_HXX_
#include <cppuhelper/implbase10.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCOLUMNLOCATE_HPP_
#include <com/sun/star/sdbc/XColumnLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCLOSEABLE_HPP_
#include <com/sun/star/sdbc/XCloseable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XROWLOCATE_HPP_
#include <com/sun/star/sdbcx/XRowLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XWARNINGSSUPPLIER_HPP_
#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XUNOTUNNEL_HPP_
#include <com/sun/star/lang/XUnoTunnel.hpp>
-#endif
-#ifndef _CPPUHELPER_INTERFACECONTAINER_H_
#include <cppuhelper/interfacecontainer.h>
-#endif
-#ifndef CONNECTIVITY_SQLERROR_HXX
#include <connectivity/sqlerror.hxx>
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef COMPHELPER_PROPERTYSTATECONTAINER_HXX
#include <comphelper/propertystatecontainer.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWSET_HPP_
#include <com/sun/star/sdbc/XRowSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTYPES_HPP_
#include <com/sun/star/util/XNumberFormatTypes.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBACCESS_CORE_API_ROWSETROW_HXX
#include "RowSetRow.hxx"
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef DBACCESS_ROWSETCACHEITERATOR_HXX
#include "RowSetCacheIterator.hxx"
-#endif
#include "core_resource.hxx"
#include <comphelper/componentcontext.hxx>
@@ -191,6 +150,9 @@ namespace dbaccess
virtual sal_Bool isModified( ) = 0;
// return <TRUE/> if and only if the current row is the insert row
virtual sal_Bool isNew( ) = 0;
+ // return <TRUE/> if the property change notification should be fired
+ // upon property change.
+ virtual sal_Bool isPropertyChangeNotificationEnabled() const;
// notify the change of a boolean property
void fireProperty( sal_Int32 _nProperty, sal_Bool _bNew, sal_Bool _bOld );
@@ -462,3 +424,4 @@ namespace dbaccess
#endif // DBACCESS_CORE_API_ROWSETBASE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSetCache.cxx b/dbaccess/source/core/api/RowSetCache.cxx
index 0ab902c6a52f..447137062b50 100644
--- a/dbaccess/source/core/api/RowSetCache.cxx
+++ b/dbaccess/source/core/api/RowSetCache.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,7 +29,6 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-
#include "BookmarkSet.hxx"
#include "CRowSetColumn.hxx"
#include "CRowSetDataColumn.hxx"
@@ -42,7 +42,6 @@
#include "core_resource.hxx"
#include "dbastrings.hrc"
-/** === begin UNO includes === **/
#include <com/sun/star/sdbc/ColumnValue.hpp>
#include <com/sun/star/sdbc/ResultSetConcurrency.hpp>
#include <com/sun/star/sdbcx/CompareBookmark.hpp>
@@ -51,7 +50,6 @@
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-/** === end UNO includes === **/
#include <comphelper/extract.hxx>
#include <comphelper/property.hxx>
@@ -64,6 +62,7 @@
#include <connectivity/sqlparse.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <algorithm>
@@ -83,7 +82,7 @@ using namespace ::osl;
#define CHECK_MATRIX_POS(M) OSL_ENSURE(((M) >= static_cast<ORowSetMatrix::difference_type>(0)) && ((M) < static_cast<sal_Int32>(m_pMatrix->size())),"Position is invalid!")
DBG_NAME(ORowSetCache)
-// -------------------------------------------------------------------------
+
ORowSetCache::ORowSetCache(const Reference< XResultSet >& _xRs,
const Reference< XSingleSelectQueryAnalyzer >& _xAnalyzer,
const ::comphelper::ComponentContext& _rContext,
@@ -195,7 +194,6 @@ ORowSetCache::ORowSetCache(const Reference< XResultSet >& _xRs,
}
catch(const Exception&)
{
- // DBG_UNHANDLED_EXCEPTION();
}
m_pCacheSet = NULL;
m_xCacheSet.clear();
@@ -273,9 +271,6 @@ ORowSetCache::ORowSetCache(const Reference< XResultSet >& _xRs,
// need to check if we could handle this select clause
bAllKeysFound = bAllKeysFound && (nTablesCount == 1 || checkJoin(xConnection,_xAnalyzer,aUpdateTableName));
- // || !(comphelper::hasProperty(PROPERTY_CANUPDATEINSERTEDROWS,xProp) && any2bool(xProp->getPropertyValue(PROPERTY_CANUPDATEINSERTEDROWS)))
-
- // oj removed because keyset uses only the next// || (xProp->getPropertySetInfo()->hasPropertyByName(PROPERTY_RESULTSETTYPE) && comphelper::getINT32(xProp->getPropertyValue(PROPERTY_RESULTSETTYPE)) == ResultSetType::FORWARD_ONLY)
if(!bAllKeysFound )
{
if ( bBookmarkable )
@@ -366,7 +361,6 @@ ORowSetCache::ORowSetCache(const Reference< XResultSet >& _xRs,
m_nPrivileges = Privilege::SELECT;
}
-// -------------------------------------------------------------------------
ORowSetCache::~ORowSetCache()
{
m_pCacheSet = NULL;
@@ -389,7 +383,6 @@ ORowSetCache::~ORowSetCache()
DBG_DTOR(ORowSetCache,NULL);
}
-// -------------------------------------------------------------------------
void ORowSetCache::setFetchSize(sal_Int32 _nSize)
{
if(_nSize == m_nFetchSize)
@@ -433,7 +426,7 @@ void ORowSetCache::setFetchSize(sal_Int32 _nSize)
m_aMatrixIter = m_pMatrix->end();
m_aMatrixEnd = m_pMatrix->end();
- // now adjust their positions because a resize invalid all iterators
+ // now adjust their positions because a resize invalidates all iterators
::std::vector<sal_Int32>::const_iterator aIter = aPositions.begin();
::std::map<sal_Int32,sal_Bool>::const_iterator aPosChangeIter = aCacheIterToChange.begin();
for( aCacheIter = m_aCacheIterators.begin();
@@ -465,14 +458,13 @@ void ORowSetCache::setFetchSize(sal_Int32 _nSize)
m_nEndPos = _nSize;
}
}
-// -------------------------------------------------------------------------
// XResultSetMetaDataSupplier
Reference< XResultSetMetaData > ORowSetCache::getMetaData( )
{
return m_xMetaData;
}
-// -------------------------------------------------------------------------
+
Any lcl_getBookmark(ORowSetValue& i_aValue,OCacheSet* i_pCacheSet)
{
switch ( i_aValue.getTypeKind() )
@@ -487,22 +479,21 @@ Any lcl_getBookmark(ORowSetValue& i_aValue,OCacheSet* i_pCacheSet)
return i_aValue.getAny();
}
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XRowLocate
Any ORowSetCache::getBookmark( )
{
-
if(m_bAfterLast)
throwFunctionSequenceException(m_xSet.get());
- if ( m_aMatrixIter >= m_pMatrix->end() || m_aMatrixIter < m_pMatrix->begin() || !(*m_aMatrixIter).isValid())
+ if ( m_aMatrixIter >= m_pMatrix->end() || m_aMatrixIter < m_pMatrix->begin() || !(*m_aMatrixIter).is())
{
return Any(); // this is allowed here because the rowset knowns what it is doing
}
return lcl_getBookmark(((*m_aMatrixIter)->get())[0],m_pCacheSet);
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::moveToBookmark( const Any& bookmark )
{
if ( m_pCacheSet->moveToBookmark(bookmark) )
@@ -519,7 +510,7 @@ sal_Bool ORowSetCache::moveToBookmark( const Any& bookmark )
if ( !m_bAfterLast )
{
m_aMatrixIter = calcPosition();
- OSL_ENSURE(m_aMatrixIter->isValid(),"Iterator after moveToBookmark not valid");
+ OSL_ENSURE(m_aMatrixIter->is(),"Iterator after moveToBookmark not valid");
}
else
m_aMatrixIter = m_pMatrix->end();
@@ -530,9 +521,9 @@ sal_Bool ORowSetCache::moveToBookmark( const Any& bookmark )
else
return sal_False;
- return m_aMatrixIter != m_pMatrix->end() && (*m_aMatrixIter).isValid();
+ return m_aMatrixIter != m_pMatrix->end() && (*m_aMatrixIter).is();
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::moveRelativeToBookmark( const Any& bookmark, sal_Int32 rows )
{
sal_Bool bRet( moveToBookmark( bookmark ) );
@@ -540,30 +531,29 @@ sal_Bool ORowSetCache::moveRelativeToBookmark( const Any& bookmark, sal_Int32 ro
{
m_nPosition = m_pCacheSet->getRow() + rows;
absolute(m_nPosition);
- // for(sal_Int32 i=0;i<rows && m_aMatrixIter != m_pMatrix->end();++i,++m_aMatrixIter) ;
- bRet = m_aMatrixIter != m_pMatrix->end() && (*m_aMatrixIter).isValid();
+ bRet = m_aMatrixIter != m_pMatrix->end() && (*m_aMatrixIter).is();
}
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Int32 ORowSetCache::compareBookmarks( const Any& _first, const Any& _second )
{
return (!_first.hasValue() || !_second.hasValue()) ? CompareBookmark::NOT_COMPARABLE : m_pCacheSet->compareBookmarks(_first,_second);
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::hasOrderedBookmarks( )
{
return m_pCacheSet->hasOrderedBookmarks();
}
-// -------------------------------------------------------------------------
+
sal_Int32 ORowSetCache::hashBookmark( const Any& bookmark )
{
return m_pCacheSet->hashBookmark(bookmark);
}
+
// XRowUpdate
-// -----------------------------------------------------------------------------
void ORowSetCache::updateNull(sal_Int32 columnIndex,ORowSetValueVector::Vector& io_aRow
,::std::vector<sal_Int32>& o_ChangedColumns
)
@@ -582,7 +572,7 @@ void ORowSetCache::updateNull(sal_Int32 columnIndex,ORowSetValueVector::Vector&
impl_updateRowFromCache_throw(io_aRow,o_ChangedColumns);
}
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::updateValue(sal_Int32 columnIndex,const ORowSetValue& x
,ORowSetValueVector::Vector& io_aRow
,::std::vector<sal_Int32>& o_ChangedColumns
@@ -602,7 +592,7 @@ void ORowSetCache::updateValue(sal_Int32 columnIndex,const ORowSetValue& x
impl_updateRowFromCache_throw(io_aRow,o_ChangedColumns);
}
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::updateCharacterStream( sal_Int32 columnIndex, const Reference< ::com::sun::star::io::XInputStream >& x
, sal_Int32 length,ORowSetValueVector::Vector& io_aRow
,::std::vector<sal_Int32>& o_ChangedColumns
@@ -623,7 +613,7 @@ void ORowSetCache::updateCharacterStream( sal_Int32 columnIndex, const Reference
m_pCacheSet->mergeColumnValues(columnIndex,rInsert,io_aRow,o_ChangedColumns);
impl_updateRowFromCache_throw(io_aRow,o_ChangedColumns);
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::updateObject( sal_Int32 columnIndex, const Any& x
,ORowSetValueVector::Vector& io_aRow
,::std::vector<sal_Int32>& o_ChangedColumns
@@ -645,7 +635,7 @@ void ORowSetCache::updateObject( sal_Int32 columnIndex, const Any& x
impl_updateRowFromCache_throw(io_aRow,o_ChangedColumns);
}
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::updateNumericObject( sal_Int32 columnIndex, const Any& x, sal_Int32 /*scale*/
,ORowSetValueVector::Vector& io_aRow
,::std::vector<sal_Int32>& o_ChangedColumns
@@ -667,7 +657,7 @@ void ORowSetCache::updateNumericObject( sal_Int32 columnIndex, const Any& x, sal
impl_updateRowFromCache_throw(io_aRow,o_ChangedColumns);
}
}
-// -------------------------------------------------------------------------
+
// XResultSet
sal_Bool ORowSetCache::next( )
{
@@ -690,27 +680,27 @@ sal_Bool ORowSetCache::next( )
return !m_bAfterLast;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::isBeforeFirst( )
{
return m_bBeforeFirst;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::isAfterLast( )
{
return m_bAfterLast;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::isFirst( )
{
return m_nPosition == 1; // ask resultset for
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::isLast( )
{
return m_nPosition == m_nRowCount;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::beforeFirst( )
{
if(!m_bBeforeFirst)
@@ -724,7 +714,7 @@ sal_Bool ORowSetCache::beforeFirst( )
}
return sal_True;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::afterLast( )
{
if(!m_bAfterLast)
@@ -745,7 +735,7 @@ sal_Bool ORowSetCache::afterLast( )
}
return sal_True;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::fillMatrix(sal_Int32& _nNewStartPos,sal_Int32 _nNewEndPos)
{
OSL_ENSURE(_nNewStartPos != _nNewEndPos,"ORowSetCache::fillMatrix: StartPos and EndPos can not be equal!");
@@ -770,7 +760,7 @@ sal_Bool ORowSetCache::fillMatrix(sal_Int32& _nNewStartPos,sal_Int32 _nNewEndPos
{
if(bCheck)
{
- if(!aIter->isValid())
+ if(!aIter->is())
*aIter = new ORowSetValueVector(m_xMetaData->getColumnCount());
m_pCacheSet->fillValueRow(*aIter,i);
if(!m_bRowCountFinal)
@@ -799,7 +789,7 @@ sal_Bool ORowSetCache::fillMatrix(sal_Int32& _nNewStartPos,sal_Int32 _nNewEndPos
{
if(bCheck)
{
- if(!aIter->isValid())
+ if(!aIter->is())
*aIter = new ORowSetValueVector(m_xMetaData->getColumnCount());
m_pCacheSet->fillValueRow(*aIter,nPos++);
}
@@ -813,7 +803,6 @@ sal_Bool ORowSetCache::fillMatrix(sal_Int32& _nNewStartPos,sal_Int32 _nNewEndPos
if ( i < (_nNewEndPos-1) )
bCheck = m_pCacheSet->next();
}
- // m_nStartPos = _nNewStartPos;
// we have to read one row forward to ensure that we know when we are on last row
// but only when we don't know it already
/*
@@ -832,15 +821,13 @@ sal_Bool ORowSetCache::fillMatrix(sal_Int32& _nNewStartPos,sal_Int32 _nNewEndPos
*/
return bCheck;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::moveWindow()
{
-
sal_Bool bRet = sal_True;
sal_Int32 nDiff = (sal_Int32)(m_nFetchSize*0.5 -0.5);
sal_Int32 nNewStartPos = (m_nPosition - nDiff);
- // sal_Int32 nNewEndPos = (m_nPosition+m_nFetchSize*0.5);
sal_Int32 nNewEndPos = nNewStartPos + m_nFetchSize;
if ( m_nPosition <= m_nStartPos )
@@ -914,8 +901,8 @@ sal_Bool ORowSetCache::moveWindow()
}
}
else
- { // normaly this should never happen
- OSL_ENSURE(0,"What the hell is happen here!");
+ { // normally this should never happen
+ OSL_FAIL("What the hell is happen here!");
return sal_False;
}
}
@@ -936,7 +923,7 @@ sal_Bool ORowSetCache::moveWindow()
bCheck = m_pCacheSet->next();
if ( bCheck )
{
- if(!aIter->isValid())
+ if(!aIter->is())
*aIter = new ORowSetValueVector(m_xMetaData->getColumnCount());
m_pCacheSet->fillValueRow(*aIter,i+1);
}
@@ -955,7 +942,7 @@ sal_Bool ORowSetCache::moveWindow()
{ // position in window
OSL_ENSURE((m_nPosition - m_nStartPos -1) < (sal_Int32)m_pMatrix->size(),"Position is behind end()!");
m_aMatrixIter = calcPosition();
- if(!m_aMatrixIter->isValid())
+ if(!m_aMatrixIter->is())
{
sal_Bool bOk( m_pCacheSet->absolute( m_nPosition ) );
if ( bOk )
@@ -1017,7 +1004,6 @@ sal_Bool ORowSetCache::moveWindow()
{ // the end was reached before end() so we can set the start before nNewStartPos
m_nStartPos += (aIter - m_pMatrix->begin());
- // m_nStartPos = (aIter - m_pMatrix->begin());
::std::rotate(m_pMatrix->begin(),aIter,m_pMatrix->end());
// now correct the iterator in our iterator vector
rotateCacheIterator( (sal_Int16)( aIter - m_pMatrix->begin() ) );
@@ -1035,13 +1021,13 @@ sal_Bool ORowSetCache::moveWindow()
m_nStartPos = 0;
}
// here we need only to check if the begining row is valid. If not we have to fetch it.
- if(!m_pMatrix->begin()->isValid())
+ if(!m_pMatrix->begin()->is())
{
aIter = m_pMatrix->begin();
nPos = m_nStartPos;
bCheck = m_pCacheSet->absolute_checked(m_nStartPos,sal_False);
- for(; !aIter->isValid() && bCheck;++aIter)
+ for(; !aIter->is() && bCheck;++aIter)
{
OSL_ENSURE(aIter != m_pMatrix->end(),"Invalid iterator");
bCheck = m_pCacheSet->next();
@@ -1063,7 +1049,7 @@ sal_Bool ORowSetCache::moveWindow()
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::first( )
{
// first move to the first row
@@ -1088,7 +1074,7 @@ sal_Bool ORowSetCache::first( )
}
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::last( )
{
sal_Bool bRet = m_pCacheSet->last();
@@ -1104,10 +1090,6 @@ sal_Bool ORowSetCache::last( )
moveWindow();
// we have to repositioning because moveWindow can modify the cache
m_pCacheSet->last();
-// if(m_nPosition > m_nFetchSize)
-// m_aMatrixIter = m_pMatrix->end() -1;
-// else
-// m_aMatrixIter = m_pMatrix->begin() + m_nPosition - 1;
OSL_ENSURE(((m_nPosition - m_nStartPos) - 1) < (sal_Int32)m_pMatrix->size(),"Position is behind end()!");
m_aMatrixIter = calcPosition();
}
@@ -1121,18 +1103,18 @@ sal_Bool ORowSetCache::last( )
#if OSL_DEBUG_LEVEL > 1
if(bRet)
{
- OSL_ENSURE((*m_aMatrixIter).isValid(),"ORowSetCache::last: Row not valid!");
+ OSL_ENSURE((*m_aMatrixIter).is(),"ORowSetCache::last: Row not valid!");
}
#endif
return bRet;
}
-// -------------------------------------------------------------------------
+
sal_Int32 ORowSetCache::getRow( )
{
return (isBeforeFirst() || isAfterLast()) ? 0 : m_nPosition;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::absolute( sal_Int32 row )
{
if(!row )
@@ -1185,7 +1167,7 @@ sal_Bool ORowSetCache::absolute( sal_Int32 row )
return !(m_bAfterLast || m_bBeforeFirst);
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::relative( sal_Int32 rows )
{
sal_Bool bErg = sal_True;
@@ -1213,7 +1195,7 @@ sal_Bool ORowSetCache::relative( sal_Int32 rows )
}
return bErg;
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::previous( )
{
sal_Bool bRet = sal_False;
@@ -1238,13 +1220,13 @@ sal_Bool ORowSetCache::previous( )
else
{
m_aMatrixIter = calcPosition();
- bRet = (*m_aMatrixIter).isValid();
+ bRet = (*m_aMatrixIter).is();
}
}
}
return bRet;
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::refreshRow( )
{
if(isAfterLast())
@@ -1257,21 +1239,21 @@ void ORowSetCache::refreshRow( )
cancelRowModification();
}
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::rowUpdated( )
{
return m_pCacheSet->rowUpdated();
}
-// -------------------------------------------------------------------------
+
sal_Bool ORowSetCache::rowInserted( )
{
return m_pCacheSet->rowInserted();
}
-// -------------------------------------------------------------------------
+
// XResultSetUpdate
sal_Bool ORowSetCache::insertRow(::std::vector< Any >& o_aBookmarks)
{
- if ( !m_bNew || !m_aInsertRow->isValid() )
+ if ( !m_bNew || !m_aInsertRow->is() )
throw SQLException(DBACORE_RESSTRING(RID_STR_NO_MOVETOINSERTROW_CALLED),NULL,SQLSTATE_GENERAL,1000,Any() );
m_pCacheSet->insertRow(*m_aInsertRow,m_aUpdateTable);
@@ -1290,7 +1272,7 @@ sal_Bool ORowSetCache::insertRow(::std::vector< Any >& o_aBookmarks)
ORowSetMatrix::iterator aIter = m_pMatrix->begin();
for(;aIter != m_pMatrix->end();++aIter)
{
- if ( m_aMatrixIter != aIter && aIter->isValid() && m_pCacheSet->columnValuesUpdated((*aIter)->get(),rCurrentRow) )
+ if ( m_aMatrixIter != aIter && aIter->is() && m_pCacheSet->columnValuesUpdated((*aIter)->get(),rCurrentRow) )
{
o_aBookmarks.push_back(lcl_getBookmark((*aIter)->get()[0],m_pCacheSet));
}
@@ -1298,12 +1280,12 @@ sal_Bool ORowSetCache::insertRow(::std::vector< Any >& o_aBookmarks)
}
else
{
- OSL_ENSURE(0,"There must be a bookmark after the row was inserted!");
+ OSL_FAIL("There must be a bookmark after the row was inserted!");
}
}
return bRet;
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::resetInsertRow(sal_Bool _bClearInsertRow)
{
if ( _bClearInsertRow )
@@ -1311,7 +1293,7 @@ void ORowSetCache::resetInsertRow(sal_Bool _bClearInsertRow)
m_bNew = sal_False;
m_bModified = sal_False;
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::cancelRowModification()
{
// clear the insertrow references -> implies that the current row of the rowset changes as well
@@ -1321,10 +1303,10 @@ void ORowSetCache::cancelRowModification()
{
if ( aCacheIter->second.pRowSet->isInsertRow() && aCacheIter->second.aIterator == m_aInsertRow )
aCacheIter->second.aIterator = m_pMatrix->end();
- } // for(;aCacheIter != aCacheEnd;++aCacheIter)
+ }
resetInsertRow(sal_False);
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::updateRow( ORowSetMatrix::iterator& _rUpdateRow,::std::vector< Any >& o_aBookmarks )
{
if(isAfterLast() || isBeforeFirst())
@@ -1346,7 +1328,7 @@ void ORowSetCache::updateRow( ORowSetMatrix::iterator& _rUpdateRow,::std::vector
ORowSetMatrix::iterator aIter = m_pMatrix->begin();
for(;aIter != m_pMatrix->end();++aIter)
{
- if ( m_aMatrixIter != aIter && aIter->isValid() && m_pCacheSet->columnValuesUpdated((*aIter)->get(),rCurrentRow) )
+ if ( m_aMatrixIter != aIter && aIter->is() && m_pCacheSet->columnValuesUpdated((*aIter)->get(),rCurrentRow) )
{
o_aBookmarks.push_back(lcl_getBookmark((*aIter)->get()[0],m_pCacheSet));
}
@@ -1355,13 +1337,12 @@ void ORowSetCache::updateRow( ORowSetMatrix::iterator& _rUpdateRow,::std::vector
m_bModified = sal_False;
}
-// -------------------------------------------------------------------------
+
bool ORowSetCache::deleteRow( )
{
if(isAfterLast() || isBeforeFirst())
throw SQLException(DBACORE_RESSTRING(RID_STR_NO_DELETEROW),NULL,SQLSTATE_GENERAL,1000,Any() );
- // m_pCacheSet->absolute(m_nPosition);
m_pCacheSet->deleteRow(*m_aMatrixIter,m_aUpdateTable);
if ( !m_pCacheSet->rowDeleted() )
return false;
@@ -1372,7 +1353,7 @@ bool ORowSetCache::deleteRow( )
(*aPos) = NULL;
ORowSetMatrix::iterator aEnd = m_pMatrix->end();
- for(++aPos;aPos != aEnd && aPos->isValid();++aPos)
+ for(++aPos;aPos != aEnd && aPos->is();++aPos)
{
*(aPos-1) = *aPos;
(*aPos) = NULL;
@@ -1382,13 +1363,13 @@ bool ORowSetCache::deleteRow( )
--m_nPosition;
return true;
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::cancelRowUpdates( )
{
m_bNew = m_bModified = sal_False;
if(!m_nPosition)
{
- OSL_ENSURE(0,"cancelRowUpdates:Invalid positions pos == 0");
+ OSL_FAIL("cancelRowUpdates:Invalid positions pos == 0");
::dbtools::throwFunctionSequenceException(NULL);
}
@@ -1396,18 +1377,18 @@ void ORowSetCache::cancelRowUpdates( )
m_pCacheSet->fillValueRow(*m_aMatrixIter,m_nPosition);
else
{
- OSL_ENSURE(0,"cancelRowUpdates couldn't position right with absolute");
+ OSL_FAIL("cancelRowUpdates couldn't position right with absolute");
::dbtools::throwFunctionSequenceException(NULL);
}
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::moveToInsertRow( )
{
m_bNew = sal_True;
m_bUpdated = m_bAfterLast = sal_False;
m_aInsertRow = m_pInsertMatrix->begin();
- if(!m_aInsertRow->isValid())
+ if(!m_aInsertRow->is())
*m_aInsertRow = new ORowSetValueVector(m_xMetaData->getColumnCount());
// we don't unbound the bookmark column
@@ -1421,16 +1402,15 @@ void ORowSetCache::moveToInsertRow( )
aIter->setTypeKind(m_xMetaData->getColumnType(i));
}
}
-// -------------------------------------------------------------------------
+
ORowSetCacheIterator ORowSetCache::createIterator(ORowSetBase* _pRowSet)
{
-
ORowSetCacheIterator_Helper aHelper;
aHelper.aIterator = m_pMatrix->end();
aHelper.pRowSet = _pRowSet;
return ORowSetCacheIterator(m_aCacheIterators.insert(m_aCacheIterators.begin(),ORowSetCacheMap::value_type(m_aCacheIterators.size()+1,aHelper)),this,_pRowSet);
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::deleteIterator(const ORowSetBase* _pRowSet)
{
ORowSetCacheMap::iterator aCacheIter = m_aCacheIterators.begin();
@@ -1440,12 +1420,12 @@ void ORowSetCache::deleteIterator(const ORowSetBase* _pRowSet)
{
m_aCacheIterators.erase(aCacheIter);
aCacheIter = m_aCacheIterators.begin();
- } // if ( aCacheIter->second.pRowSet == _pRowSet )
+ }
else
++aCacheIter;
}
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::rotateCacheIterator(ORowSetMatrix::difference_type _nDist)
{
if(_nDist)
@@ -1474,11 +1454,11 @@ void ORowSetCache::rotateCacheIterator(ORowSetMatrix::difference_type _nDist)
}
}
}
-// -------------------------------------------------------------------------
+
void ORowSetCache::setUpdateIterator(const ORowSetMatrix::iterator& _rOriginalRow)
{
m_aInsertRow = m_pInsertMatrix->begin();
- if(!m_aInsertRow->isValid())
+ if(!m_aInsertRow->is())
*m_aInsertRow = new ORowSetValueVector(m_xMetaData->getColumnCount());
(*(*m_aInsertRow)) = (*(*_rOriginalRow));
@@ -1488,7 +1468,7 @@ void ORowSetCache::setUpdateIterator(const ORowSetMatrix::iterator& _rOriginalRo
for(;aIter != aEnd;++aIter)
aIter->setModified(sal_False);
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::checkPositionFlags()
{
if(m_bRowCountFinal)
@@ -1498,13 +1478,13 @@ void ORowSetCache::checkPositionFlags()
m_nPosition = 0;//m_nRowCount;
}
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::checkUpdateConditions(sal_Int32 columnIndex)
{
if(m_bAfterLast || columnIndex >= (sal_Int32)(*m_aInsertRow)->get().size())
throwFunctionSequenceException(m_xSet.get());
}
-//------------------------------------------------------------------------------
+
sal_Bool ORowSetCache::checkInnerJoin(const ::connectivity::OSQLParseNode *pNode,const Reference< XConnection>& _xConnection,const ::rtl::OUString& _sUpdateTableName)
{
sal_Bool bOk = sal_False;
@@ -1514,10 +1494,10 @@ sal_Bool ORowSetCache::checkInnerJoin(const ::connectivity::OSQLParseNode *pNode
{
bOk = checkInnerJoin(pNode->getChild(1),_xConnection,_sUpdateTableName);
}
- else if ((SQL_ISRULE(pNode,search_condition) || SQL_ISRULE(pNode,boolean_term)) && // AND/OR-Verknuepfung:
+ else if ((SQL_ISRULE(pNode,search_condition) || SQL_ISRULE(pNode,boolean_term)) && // AND/OR link
pNode->count() == 3)
{
- // nur AND Verknüpfung zulassen
+ // only allow an AND link
if ( SQL_ISTOKEN(pNode->getChild(1),AND) )
bOk = checkInnerJoin(pNode->getChild(0),_xConnection,_sUpdateTableName)
&& checkInnerJoin(pNode->getChild(2),_xConnection,_sUpdateTableName);
@@ -1525,7 +1505,7 @@ sal_Bool ORowSetCache::checkInnerJoin(const ::connectivity::OSQLParseNode *pNode
else if (SQL_ISRULE(pNode,comparison_predicate))
{
// only the comparison of columns is allowed
- DBG_ASSERT(pNode->count() == 3,"checkInnerJoin: Fehler im Parse Tree");
+ OSL_ENSURE(pNode->count() == 3,"checkInnerJoin: Fehler im Parse Tree");
if (!(SQL_ISRULE(pNode->getChild(0),column_ref) &&
SQL_ISRULE(pNode->getChild(2),column_ref) &&
pNode->getChild(1)->getNodeType() == SQL_NODE_EQUAL))
@@ -1543,7 +1523,7 @@ sal_Bool ORowSetCache::checkInnerJoin(const ::connectivity::OSQLParseNode *pNode
}
return bOk;
}
-// -----------------------------------------------------------------------------
+
sal_Bool ORowSetCache::checkJoin(const Reference< XConnection>& _xConnection,
const Reference< XSingleSelectQueryAnalyzer >& _xAnalyzer,
const ::rtl::OUString& _sUpdateTableName )
@@ -1603,11 +1583,11 @@ sal_Bool ORowSetCache::checkJoin(const Reference< XConnection>& _xConnection,
}
return bOk;
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::clearInsertRow()
{
// we don't unbound the bookmark column
- if ( m_aInsertRow != m_pInsertMatrix->end() && m_aInsertRow->isValid() )
+ if ( m_aInsertRow != m_pInsertMatrix->end() && m_aInsertRow->is() )
{
ORowSetValueVector::Vector::iterator aIter = (*m_aInsertRow)->get().begin()+1;
ORowSetValueVector::Vector::iterator aEnd = (*m_aInsertRow)->get().end();
@@ -1616,17 +1596,16 @@ void ORowSetCache::clearInsertRow()
aIter->setBound(sal_False);
aIter->setModified(sal_False);
aIter->setNull();
- } // for(;aIter != (*m_aInsertRow)->end();++aIter)
+ }
}
}
-// -----------------------------------------------------------------------------
+
ORowSetMatrix::iterator ORowSetCache::calcPosition() const
{
sal_Int32 nValue = (m_nPosition - m_nStartPos) - 1;
CHECK_MATRIX_POS(nValue);
return ( nValue < 0 || nValue >= static_cast<sal_Int32>(m_pMatrix->size()) ) ? m_pMatrix->end() : (m_pMatrix->begin() + nValue);
}
-// -----------------------------------------------------------------------------
TORowSetOldRowHelperRef ORowSetCache::registerOldRow()
{
@@ -1634,13 +1613,13 @@ TORowSetOldRowHelperRef ORowSetCache::registerOldRow()
m_aOldRows.push_back(pRef);
return pRef;
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::deregisterOldRow(const TORowSetOldRowHelperRef& _rRow)
{
TOldRowSetRows::iterator aOldRowEnd = m_aOldRows.end();
for (TOldRowSetRows::iterator aOldRowIter = m_aOldRows.begin(); aOldRowIter != aOldRowEnd; ++aOldRowIter)
{
- if ( aOldRowIter->getBodyPtr() == _rRow.getBodyPtr() )
+ if ( aOldRowIter->get() == _rRow.get() )
{
m_aOldRows.erase(aOldRowIter);
break;
@@ -1648,35 +1627,35 @@ void ORowSetCache::deregisterOldRow(const TORowSetOldRowHelperRef& _rRow)
}
}
-// -----------------------------------------------------------------------------
+
sal_Bool ORowSetCache::reFillMatrix(sal_Int32 _nNewStartPos,sal_Int32 _nNewEndPos)
{
TOldRowSetRows::iterator aOldRowEnd = m_aOldRows.end();
for (TOldRowSetRows::iterator aOldRowIter = m_aOldRows.begin(); aOldRowIter != aOldRowEnd; ++aOldRowIter)
{
- if ( aOldRowIter->isValid() && aOldRowIter->getBody().getRow().isValid() )
- aOldRowIter->getBody().setRow(new ORowSetValueVector(aOldRowIter->getBody().getRow().getBody()) );
+ if ( aOldRowIter->is() && (*aOldRowIter)->getRow().is() )
+ (*aOldRowIter)->setRow(new ORowSetValueVector( *((*aOldRowIter)->getRow()) ) );
}
sal_Int32 nNewSt = _nNewStartPos;
sal_Bool bRet = fillMatrix(nNewSt,_nNewEndPos);
m_nStartPos = nNewSt - 1;
- rotateCacheIterator(static_cast<sal_Int16>(m_nFetchSize+1)); // forces that every iterator will be set to null
+ rotateCacheIterator(static_cast<sal_Int16>(m_nFetchSize+1)); // forces every iterator to null
return bRet;
}
-// -----------------------------------------------------------------------------
+
sal_Bool ORowSetCache::fill(ORowSetMatrix::iterator& _aIter,const ORowSetMatrix::iterator& _aEnd,sal_Int32& _nPos,sal_Bool _bCheck)
{
sal_Int32 nColumnCount = m_xMetaData->getColumnCount();
for(; _bCheck && _aIter != _aEnd;)
{
- if ( !_aIter->isValid() )
+ if ( !_aIter->is() )
*_aIter = new ORowSetValueVector(nColumnCount);
else
{
TOldRowSetRows::iterator aOldRowEnd = m_aOldRows.end();
for (TOldRowSetRows::iterator aOldRowIter = m_aOldRows.begin(); aOldRowIter != aOldRowEnd; ++aOldRowIter)
{
- if ( aOldRowIter->getBody().getRow().isEqualBody(*_aIter) )
+ if ( (*aOldRowIter)->getRow() == *_aIter )
*_aIter = new ORowSetValueVector(nColumnCount);
}
}
@@ -1685,12 +1664,12 @@ sal_Bool ORowSetCache::fill(ORowSetMatrix::iterator& _aIter,const ORowSetMatrix:
}
return _bCheck;
}
-// -----------------------------------------------------------------------------
+
bool ORowSetCache::isResultSetChanged() const
{
return m_pCacheSet->isResultSetChanged();
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::reset(const Reference< XResultSet>& _xDriverSet)
{
m_xMetaData.set(Reference< XResultSetMetaDataSupplier >(_xDriverSet,UNO_QUERY)->getMetaData());
@@ -1700,7 +1679,7 @@ void ORowSetCache::reset(const Reference< XResultSet>& _xDriverSet)
m_nRowCount = 0;
reFillMatrix(m_nStartPos+1,m_nEndPos+1);
}
-// -----------------------------------------------------------------------------
+
void ORowSetCache::impl_updateRowFromCache_throw(ORowSetValueVector::Vector& io_aRow
,::std::vector<sal_Int32>& o_ChangedColumns)
{
@@ -1709,7 +1688,7 @@ void ORowSetCache::impl_updateRowFromCache_throw(ORowSetValueVector::Vector& io_
ORowSetMatrix::iterator aIter = m_pMatrix->begin();
for(;aIter != m_pMatrix->end();++aIter)
{
- if ( aIter->isValid() && m_pCacheSet->updateColumnValues((*aIter)->get(),io_aRow,o_ChangedColumns))
+ if ( aIter->is() && m_pCacheSet->updateColumnValues((*aIter)->get(),io_aRow,o_ChangedColumns))
{
break;
}
@@ -1721,4 +1700,4 @@ void ORowSetCache::impl_updateRowFromCache_throw(ORowSetValueVector::Vector& io_
}
}
}
-// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSetCache.hxx b/dbaccess/source/core/api/RowSetCache.hxx
index bf9dc1500d56..ba1aaa937996 100644
--- a/dbaccess/source/core/api/RowSetCache.hxx
+++ b/dbaccess/source/core/api/RowSetCache.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,78 +28,30 @@
#ifndef DBACCESS_CORE_API_ROWSETCACHE_HXX
#define DBACCESS_CORE_API_ROWSETCACHE_HXX
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPREPAREDSTATEMENT_HPP_
#include <com/sun/star/sdbc/XPreparedStatement.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYANALYZER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryAnalyzer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYANALYZER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryAnalyzer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XWARNINGSSUPPLIER_HPP_
#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XRESULTSETACCESS_HPP_
#include <com/sun/star/sdb/XResultSetAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCOLUMNLOCATE_HPP_
#include <com/sun/star/sdbc/XColumnLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XROWLOCATE_HPP_
#include <com/sun/star/sdbcx/XRowLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWUPDATE_HPP_
#include <com/sun/star/sdbc/XRowUpdate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETUPDATE_HPP_
#include <com/sun/star/sdbc/XResultSetUpdate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XROWSETAPPROVEBROADCASTER_HPP_
#include <com/sun/star/sdb/XRowSetApproveBroadcaster.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_RESULTSETTYPE_HPP_
#include <com/sun/star/sdbc/ResultSetType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDELETEROWS_HPP_
#include <com/sun/star/sdbcx/XDeleteRows.hpp>
-#endif
-#ifndef _CPPUHELPER_COMPBASE11_HXX_
#include <cppuhelper/compbase11.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTYCONTAINER_HXX_
#include <comphelper/propertycontainer.hxx>
-#endif
-#ifndef COMPHELPER_COMPONENTCONTEXT_HXX
#include <comphelper/componentcontext.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef DBACCESS_CORE_API_ROWSETROW_HXX
#include "RowSetRow.hxx"
-#endif
-#ifndef DBACCESS_ROWSETCACHEITERATOR_HXX
#include "RowSetCacheIterator.hxx"
-#endif
namespace connectivity
{
@@ -137,7 +90,6 @@ namespace dbaccess
ORowSetMatrix* m_pInsertMatrix; // represent the rows which should be inserted normally this is only one
ORowSetMatrix::iterator m_aInsertRow; // represent a insert row
- // ORowSetRow m_aInsertRow; // present the row that should be inserted
sal_Int32 m_nLastColumnIndex; // the last column ask for, used for wasNull()
connectivity::OSQLTable m_aUpdateTable; // used for updates/deletes and inserts
@@ -272,3 +224,4 @@ namespace dbaccess
}
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSetCacheIterator.cxx b/dbaccess/source/core/api/RowSetCacheIterator.cxx
index 29d3f38278f4..9f634d4bef0e 100644
--- a/dbaccess/source/core/api/RowSetCacheIterator.cxx
+++ b/dbaccess/source/core/api/RowSetCacheIterator.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_ROWSETCACHEITERATOR_HXX
#include "RowSetCacheIterator.hxx"
-#endif
-#ifndef DBACCESS_CORE_API_ROWSETCACHE_HXX
#include "RowSetCache.hxx"
-#endif
-#ifndef DBACCESS_CORE_API_ROWSETBASE_HXX
#include "RowSetBase.hxx"
-#endif
#include <rtl/logfile.hxx>
using namespace dbaccess;
@@ -46,12 +41,12 @@ ORowSetCacheIterator::ORowSetCacheIterator(const ORowSetCacheIterator& _rRH)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetCacheIterator::ORowSetCacheIterator" );
}
-// -----------------------------------------------------------------------------
+
ORowSetCacheIterator::operator ORowSetMatrix::iterator()
{
return m_aIter->second.aIterator;
}
-// -----------------------------------------------------------------------------
+
ORowSetCacheIterator& ORowSetCacheIterator::operator =(const ORowSetCacheIterator& _rRH)
{
if(this == &_rRH)
@@ -63,18 +58,18 @@ ORowSetCacheIterator& ORowSetCacheIterator::operator =(const ORowSetCacheIterato
return *this;
}
-// -----------------------------------------------------------------------------
+
ORowSetCacheIterator& ORowSetCacheIterator::operator =(const ORowSetMatrix::iterator& _rIter)
{
m_aIter->second.aIterator = _rIter;
return *this;
}
-// -----------------------------------------------------------------------------
+
ORowSetRow& ORowSetCacheIterator::operator *()
{
return *m_aIter->second.aIterator;
}
-// -----------------------------------------------------------------------------
+
const ORowSetRow& ORowSetCacheIterator::operator *() const
{
if ( !m_pRowSet->isInsertRow() && m_aIter->second.aIterator == m_pCache->m_pMatrix->end() )
@@ -85,12 +80,12 @@ const ORowSetRow& ORowSetCacheIterator::operator *() const
}
return *m_aIter->second.aIterator;
}
-// -----------------------------------------------------------------------------
+
ORowSetMatrix::iterator& ORowSetCacheIterator::operator ->()
{
return m_aIter->second.aIterator;
}
-// -----------------------------------------------------------------------------
+
const ORowSetMatrix::iterator& ORowSetCacheIterator::operator ->() const
{
if ( !m_pRowSet->isInsertRow() && m_aIter->second.aIterator == m_pCache->m_pMatrix->end() )
@@ -101,33 +96,33 @@ const ORowSetMatrix::iterator& ORowSetCacheIterator::operator ->() const
}
return m_aIter->second.aIterator;
}
-// -----------------------------------------------------------------------------
+
bool ORowSetCacheIterator::operator <=(const ORowSetMatrix::iterator& _rRH) const
{
return m_aIter->second.aIterator <= _rRH;
}
-// -----------------------------------------------------------------------------
+
bool ORowSetCacheIterator::operator <(const ORowSetMatrix::iterator& _rRH) const
{
return m_aIter->second.aIterator < _rRH;
}
-// -----------------------------------------------------------------------------
+
bool ORowSetCacheIterator::operator !=(const ORowSetMatrix::iterator& _rRH) const
{
return m_aIter->second.aIterator != _rRH;
}
-// -----------------------------------------------------------------------------
+
bool ORowSetCacheIterator::operator ==(const ORowSetMatrix::iterator& _rRH) const
{
return m_aIter->second.aIterator == _rRH;
}
-// -----------------------------------------------------------------------------
+
void ORowSetCacheIterator::setBookmark(const ::com::sun::star::uno::Any& _rBookmark)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetCacheIterator::setBookmark" );
m_aIter->second.aBookmark = _rBookmark;
}
-// -----------------------------------------------------------------------------
+
sal_Bool ORowSetCacheIterator::isNull() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetCacheIterator::isNull" );
@@ -144,9 +139,11 @@ sal_Bool ORowSetCacheIterator::isNull() const
}
return bRet;
}
-// -----------------------------------------------------------------------------
+
::osl::Mutex* ORowSetCacheIterator::getMutex() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ORowSetCacheIterator::getMutex" );
return m_pRowSet ? m_pRowSet->getMutex() : NULL;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSetCacheIterator.hxx b/dbaccess/source/core/api/RowSetCacheIterator.hxx
index 6c4c1a8576ce..e6be14baaeb8 100644
--- a/dbaccess/source/core/api/RowSetCacheIterator.hxx
+++ b/dbaccess/source/core/api/RowSetCacheIterator.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBACCESS_ROWSETCACHEITERATOR_HXX
#define DBACCESS_ROWSETCACHEITERATOR_HXX
-#ifndef DBACCESS_CORE_API_ROWSETROW_HXX
#include "RowSetRow.hxx"
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
namespace dbaccess
{
@@ -89,4 +86,4 @@ namespace dbaccess
}
#endif // DBACCESS_ROWSETCACHEITERATOR_HXX
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/RowSetRow.hxx b/dbaccess/source/core/api/RowSetRow.hxx
index 1178c2990b83..9dfb0eb6a80f 100644
--- a/dbaccess/source/core/api/RowSetRow.hxx
+++ b/dbaccess/source/core/api/RowSetRow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,23 +28,15 @@
#ifndef DBACCESS_CORE_API_ROWSETROW_HXX
#define DBACCESS_CORE_API_ROWSETROW_HXX
-#ifndef _VOS_REF_HXX_
-#include <vos/ref.hxx>
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
+#include <rtl/ref.hxx>
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _CONNECTIVITY_FILE_VALUE_HXX_
#include "connectivity/FValue.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
namespace dbaccess
{
typedef connectivity::ORowVector< connectivity::ORowSetValue > ORowSetValueVector;
- typedef ::vos::ORef< ORowSetValueVector > ORowSetRow;
+ typedef ::rtl::Reference< ORowSetValueVector > ORowSetRow;
typedef ::std::vector< ORowSetRow > ORowSetMatrix;
class ORowSetOldRowHelper
@@ -59,10 +52,6 @@ namespace dbaccess
: m_refCount(0)
, m_aRow(_rRow)
{}
-// ORowSetOldRowHelper(const ORowSetOldRowHelper& _rRh)
-// : m_refCount(0)
-// , m_aRow(_rRh.m_aRow)
-// {}
void acquire()
{
@@ -78,7 +67,7 @@ namespace dbaccess
inline void setRow(const ORowSetRow& _rRow) { m_aRow = _rRow; }
};
- typedef ::vos::ORef< ORowSetOldRowHelper > TORowSetOldRowHelperRef;
+ typedef ::rtl::Reference< ORowSetOldRowHelper > TORowSetOldRowHelperRef;
class ORowSetValueCompare
{
@@ -106,3 +95,4 @@ namespace dbaccess
}
#endif // DBACCESS_CORE_API_ROWSETROW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
index f3b40ffe968e..2942f5ccbe78 100644
--- a/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
+++ b/dbaccess/source/core/api/SingleSelectQueryComposer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,6 +64,7 @@
#include <unotools/syslocale.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <unotools/configmgr.hxx>
#include <unotools/sharedunocomponent.hxx>
@@ -104,10 +106,8 @@ namespace BooleanComparisonMode = ::com::sun::star::sdb::BooleanComparisonMode;
#define R_BRACKET ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(")"))
#define COMMA ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(","))
-// -------------------------------------------------------------------------
namespace
{
- // .....................................................................
/** parses the given statement, using the given parser, returns a parse node representing
the statement
@@ -241,7 +241,7 @@ namespace
}
DBG_NAME(OSingleSelectQueryComposer)
-// -------------------------------------------------------------------------
+
OSingleSelectQueryComposer::OSingleSelectQueryComposer(const Reference< XNameAccess>& _rxTables,
const Reference< XConnection>& _xConnection,
const ::comphelper::ComponentContext& _rContext )
@@ -292,7 +292,7 @@ OSingleSelectQueryComposer::OSingleSelectQueryComposer(const Reference< XNameAcc
{
}
}
-// -------------------------------------------------------------------------
+
OSingleSelectQueryComposer::~OSingleSelectQueryComposer()
{
DBG_DTOR(OSingleSelectQueryComposer,NULL);
@@ -306,7 +306,7 @@ OSingleSelectQueryComposer::~OSingleSelectQueryComposer()
for(;aTabIter != aTabEnd;++aTabIter)
delete *aTabIter;
}
-// -------------------------------------------------------------------------
+
// OComponentHelper
void SAL_CALL OSingleSelectQueryComposer::disposing(void)
{
@@ -328,7 +328,6 @@ IMPLEMENT_SERVICE_INFO1(OSingleSelectQueryComposer,"org.openoffice.comp.dba.OSin
IMPLEMENT_TYPEPROVIDER3(OSingleSelectQueryComposer,OSubComponent,OSingleSelectQueryComposer_BASE,OPropertyContainer)
IMPLEMENT_PROPERTYCONTAINER_DEFAULTS(OSingleSelectQueryComposer)
-// -------------------------------------------------------------------------
// com::sun::star::lang::XUnoTunnel
sal_Int64 SAL_CALL OSingleSelectQueryComposer::getSomething( const Sequence< sal_Int8 >& rId ) throw(RuntimeException)
{
@@ -339,7 +338,6 @@ sal_Int64 SAL_CALL OSingleSelectQueryComposer::getSomething( const Sequence< sal
return sal_Int64(0);
}
-// -------------------------------------------------------------------------
// XSingleSelectQueryAnalyzer
::rtl::OUString SAL_CALL OSingleSelectQueryComposer::getQuery( ) throw(RuntimeException)
{
@@ -351,7 +349,6 @@ sal_Int64 SAL_CALL OSingleSelectQueryComposer::getSomething( const Sequence< sal
return getStatementPart(F_tmp,m_aSqlIterator);
}
-// -------------------------------------------------------------------------
void SAL_CALL OSingleSelectQueryComposer::setQuery( const ::rtl::OUString& command ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "frank.schoenheit@sun.com", "OSingleSelectQueryComposer::setQuery" );
@@ -372,7 +369,7 @@ void SAL_CALL OSingleSelectQueryComposer::setQuery( const ::rtl::OUString& comma
for ( SQLPart eLoopParts = Where; eLoopParts != SQLPartCount; incSQLPart( eLoopParts ) )
m_aElementaryParts[ eLoopParts ] = ::rtl::OUString();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OSingleSelectQueryComposer::setCommand( const ::rtl::OUString& Command,sal_Int32 _nCommandType ) throw(SQLException, RuntimeException)
{
::rtl::OUStringBuffer sSQL;
@@ -441,16 +438,8 @@ void SAL_CALL OSingleSelectQueryComposer::setCommand( const ::rtl::OUString& Com
::rtl::OUString sCommand = sSQL.makeStringAndClear();
setElementaryQuery(sCommand);
m_sOrignal = sCommand;
-/*
- // reset the additive iterator to the same statement
- parseAndCheck_throwError( m_aSqlParser, m_sOrignal, m_aAdditiveIterator, *this );
-
- // we have no "elementary" parts anymore (means filter/groupby/having/order clauses)
- for ( SQLPart eLoopParts = Where; eLoopParts != SQLPartCount; incSQLPart( eLoopParts ) )
- m_aElementaryParts[ eLoopParts ] = ::rtl::OUString();
-*/
}
-// -----------------------------------------------------------------------------
+
void OSingleSelectQueryComposer::setQuery_Impl( const ::rtl::OUString& command )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "frank.schoenheit@sun.com", "OSingleSelectQueryComposer::setQuery_Impl" );
@@ -460,41 +449,38 @@ void OSingleSelectQueryComposer::setQuery_Impl( const ::rtl::OUString& command )
// strip it from all clauses, to have the pure SELECT statement
m_aPureSelectSQL = getPureSelectStatement( m_aSqlIterator.getParseTree(), m_xConnection );
- // update columns and tables
- // why? Shouldn't this be done on request only?
- // otherwise nothing is working anymore :-)
-// getColumns();
+ // update tables
getTables();
}
-// -----------------------------------------------------------------------------
+
Sequence< Sequence< PropertyValue > > SAL_CALL OSingleSelectQueryComposer::getStructuredHavingClause( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getStructuredHavingClause" );
TGetParseNode F_tmp(&OSQLParseTreeIterator::getSimpleHavingTree);
return getStructuredCondition(F_tmp);
}
-// -------------------------------------------------------------------------
+
Sequence< Sequence< PropertyValue > > SAL_CALL OSingleSelectQueryComposer::getStructuredFilter( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getStructuredFilter" );
TGetParseNode F_tmp(&OSQLParseTreeIterator::getSimpleWhereTree);
return getStructuredCondition(F_tmp);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OSingleSelectQueryComposer::appendHavingClauseByColumn( const Reference< XPropertySet >& column, sal_Bool andCriteria,sal_Int32 filterOperator ) throw (SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::appendHavingClauseByColumn" );
::std::mem_fun1_t<bool,OSingleSelectQueryComposer,::rtl::OUString> F_tmp(&OSingleSelectQueryComposer::implSetHavingClause);
setConditionByColumn(column,andCriteria,F_tmp,filterOperator);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OSingleSelectQueryComposer::appendFilterByColumn( const Reference< XPropertySet >& column, sal_Bool andCriteria,sal_Int32 filterOperator ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::appendFilterByColumn" );
::std::mem_fun1_t<bool,OSingleSelectQueryComposer,::rtl::OUString> F_tmp(&OSingleSelectQueryComposer::implSetFilter);
setConditionByColumn(column,andCriteria,F_tmp,filterOperator);
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OSingleSelectQueryComposer::impl_getColumnName_throw(const Reference< XPropertySet >& column)
{
::connectivity::checkDisposed(OSubComponent::rBHelper.bDisposed);
@@ -564,7 +550,7 @@ void SAL_CALL OSingleSelectQueryComposer::appendFilterByColumn( const Reference<
aNewName = getTableAlias(column) + ::dbtools::quoteName(aQuote,aName);
return aNewName;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OSingleSelectQueryComposer::appendOrderByColumn( const Reference< XPropertySet >& column, sal_Bool ascending ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::appendOrderByColumn" );
@@ -580,7 +566,6 @@ void SAL_CALL OSingleSelectQueryComposer::appendOrderByColumn( const Reference<
setOrder(sOrder);
}
-// -------------------------------------------------------------------------
void SAL_CALL OSingleSelectQueryComposer::appendGroupByColumn( const Reference< XPropertySet >& column) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::appendGroupByColumn" );
@@ -591,11 +576,11 @@ void SAL_CALL OSingleSelectQueryComposer::appendGroupByColumn( const Reference<
aComposer.append( sColumnName );
setGroup( aComposer.getComposedAndClear() );
}
-// -------------------------------------------------------------------------
+
::rtl::OUString OSingleSelectQueryComposer::composeStatementFromParts( const ::std::vector< ::rtl::OUString >& _rParts )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::composeStatementFromParts" );
- DBG_ASSERT( _rParts.size() == (size_t)SQLPartCount, "OSingleSelectQueryComposer::composeStatementFromParts: invalid parts array!" );
+ OSL_ENSURE( _rParts.size() == (size_t)SQLPartCount, "OSingleSelectQueryComposer::composeStatementFromParts: invalid parts array!" );
::rtl::OUStringBuffer aSql( m_aPureSelectSQL );
for ( SQLPart eLoopParts = Where; eLoopParts != SQLPartCount; incSQLPart( eLoopParts ) )
@@ -608,14 +593,12 @@ void SAL_CALL OSingleSelectQueryComposer::appendGroupByColumn( const Reference<
return aSql.makeStringAndClear();
}
-// -------------------------------------------------------------------------
::rtl::OUString SAL_CALL OSingleSelectQueryComposer::getElementaryQuery() throw (::com::sun::star::uno::RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getElementaryQuery" );
return composeStatementFromParts( m_aElementaryParts );
}
-// -------------------------------------------------------------------------
void SAL_CALL OSingleSelectQueryComposer::setElementaryQuery( const ::rtl::OUString& _rElementary ) throw (::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "frank.schoenheit@sun.com", "OSingleSelectQueryComposer::setElementaryQuery" );
@@ -644,13 +627,12 @@ void SAL_CALL OSingleSelectQueryComposer::setElementaryQuery( const ::rtl::OUStr
catch( const Exception& e )
{
(void)e;
- DBG_ERROR( "OSingleSelectQueryComposer::setElementaryQuery: there should be no error anymore for the additive statement!" );
+ OSL_FAIL( "OSingleSelectQueryComposer::setElementaryQuery: there should be no error anymore for the additive statement!" );
// every part of the additive statement should have passed other tests already, and should not
// be able to cause any errors ... me thinks
}
}
-// -------------------------------------------------------------------------
namespace
{
::rtl::OUString getComposedClause( const ::rtl::OUString _rElementaryClause, const ::rtl::OUString _rAdditionalClause,
@@ -666,7 +648,6 @@ namespace
}
}
-// -------------------------------------------------------------------------
void OSingleSelectQueryComposer::setSingleAdditiveClause( SQLPart _ePart, const ::rtl::OUString& _rClause )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setSingleAdditiveClause" );
@@ -724,39 +705,36 @@ void OSingleSelectQueryComposer::setSingleAdditiveClause( SQLPart _ePart, const
catch( const Exception& e )
{
(void)e;
- DBG_ERROR( "OSingleSelectQueryComposer::setSingleAdditiveClause: there should be no error anymore for the additive statement!" );
+ OSL_FAIL( "OSingleSelectQueryComposer::setSingleAdditiveClause: there should be no error anymore for the additive statement!" );
// every part of the additive statement should have passed other tests already, and should not
// be able to cause any errors ... me thinks
}
}
-// -------------------------------------------------------------------------
void SAL_CALL OSingleSelectQueryComposer::setFilter( const ::rtl::OUString& filter ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setFilter" );
setSingleAdditiveClause( Where, filter );
}
-// -------------------------------------------------------------------------
void SAL_CALL OSingleSelectQueryComposer::setOrder( const ::rtl::OUString& order ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setOrder" );
setSingleAdditiveClause( Order, order );
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OSingleSelectQueryComposer::setGroup( const ::rtl::OUString& group ) throw (SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setGroup" );
setSingleAdditiveClause( Group, group );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OSingleSelectQueryComposer::setHavingClause( const ::rtl::OUString& filter ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setHavingClause" );
setSingleAdditiveClause( Having, filter );
}
-// -------------------------------------------------------------------------
// XTablesSupplier
Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getTables( ) throw(RuntimeException)
{
@@ -777,7 +755,7 @@ Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getTables( ) thro
return m_pTables;
}
-// -------------------------------------------------------------------------
+
// XColumnsSupplier
Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getColumns( ) throw(RuntimeException)
{
@@ -788,7 +766,7 @@ Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getColumns( ) thr
return m_aCurrentColumns[SelectColumns];
::std::vector< ::rtl::OUString> aNames;
- ::vos::ORef< OSQLColumns> aSelectColumns;
+ ::rtl::Reference< OSQLColumns> aSelectColumns;
sal_Bool bCase = sal_True;
Reference< XNameAccess> xQueryColumns;
if ( m_nCommandType == CommandType::QUERY )
@@ -813,7 +791,7 @@ Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getColumns( ) thr
aSQL.append( STR_WHERE );
// preserve the original WHERE clause
- // #i102234# / 2009-06-02 / frank.schoenheit@sun.com
+ // #i102234#
::rtl::OUString sOriginalWhereClause = getSQLPart( Where, m_aSqlIterator, sal_False );
if ( sOriginalWhereClause.getLength() )
{
@@ -834,7 +812,7 @@ Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getColumns( ) thr
// normalize the statement so that it doesn't contain any application-level features anymore
::rtl::OUString sError;
const ::std::auto_ptr< OSQLParseNode > pStatementTree( m_aSqlParser.parseTree( sError, sSQL, false ) );
- DBG_ASSERT( pStatementTree.get(), "OSingleSelectQueryComposer::getColumns: could not parse the column retrieval statement!" );
+ OSL_ENSURE( pStatementTree.get(), "OSingleSelectQueryComposer::getColumns: could not parse the column retrieval statement!" );
if ( pStatementTree.get() )
if ( !pStatementTree->parseNodeToExecutableStatement( sSQL, m_xConnection, m_aSqlParser, NULL ) )
break;
@@ -959,7 +937,6 @@ Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getColumns( ) thr
if ( !sColumnName.getLength() )
xProp->getPropertyValue(PROPERTY_NAME) >>= sColumnName;
-
aFindName = ::std::find_if(aNames.begin(),aNames.end(),::std::bind2nd(aCaseCompareFunctor,sColumnName));
sal_Int32 j = 0;
while ( aFindName != aNames.end() )
@@ -994,7 +971,7 @@ Reference< XNameAccess > SAL_CALL OSingleSelectQueryComposer::getColumns( ) thr
return m_aCurrentColumns[SelectColumns];
}
-// -------------------------------------------------------------------------
+
sal_Bool OSingleSelectQueryComposer::setORCriteria(OSQLParseNode* pCondition, OSQLParseTreeIterator& _rIterator,
::std::vector< ::std::vector < PropertyValue > >& rFilters, const Reference< ::com::sun::star::util::XNumberFormatter > & xFormatter) const
{
@@ -1015,7 +992,6 @@ sal_Bool OSingleSelectQueryComposer::setORCriteria(OSQLParseNode* pCondition, OS
{
// Ist das erste Element wieder eine OR-Verknuepfung?
// Dann rekursiv absteigen ...
- //if (!i && SQL_ISRULE(pCondition->getChild(i),search_condition))
if (SQL_ISRULE(pCondition->getChild(i),search_condition))
bResult = setORCriteria(pCondition->getChild(i), _rIterator, rFilters, xFormatter);
else
@@ -1033,7 +1009,6 @@ sal_Bool OSingleSelectQueryComposer::setORCriteria(OSQLParseNode* pCondition, OS
}
}
-//--------------------------------------------------------------------------------------------------
sal_Bool OSingleSelectQueryComposer::setANDCriteria( OSQLParseNode * pCondition,
OSQLParseTreeIterator& _rIterator, ::std::vector < PropertyValue >& rFilter, const Reference< XNumberFormatter > & xFormatter) const
{
@@ -1042,7 +1017,7 @@ sal_Bool OSingleSelectQueryComposer::setANDCriteria( OSQLParseNode * pCondition,
if (SQL_ISRULE(pCondition,boolean_primary))
{
// this should not occur
- DBG_ERROR("boolean_primary in And-Criteria");
+ OSL_FAIL("boolean_primary in And-Criteria");
return sal_False;
}
// Das erste Element ist (wieder) eine AND-Verknuepfung
@@ -1068,9 +1043,7 @@ sal_Bool OSingleSelectQueryComposer::setANDCriteria( OSQLParseNode * pCondition,
::rtl::OUString aColumnName;
- // pCondition->parseNodeToStr(aValue,m_xMetaData, xFormatter, m_aLocale,static_cast<sal_Char>(m_sDecimalSep.toChar()));
pCondition->parseNodeToStr( aValue, m_xConnection, NULL );
- // pCondition->getChild(0)->parseNodeToStr(aColumnName,m_xMetaData, xFormatter, m_aLocale,static_cast<sal_Char>(m_sDecimalSep.toChar()));
pCondition->getChild(0)->parseNodeToStr( aColumnName, m_xConnection, NULL );
// don't display the column name
@@ -1096,15 +1069,15 @@ sal_Bool OSingleSelectQueryComposer::setANDCriteria( OSQLParseNode * pCondition,
}
else if (SQL_ISRULE(pCondition,in_predicate))
{
- OSL_ENSURE( false, "OSingleSelectQueryComposer::setANDCriteria: in_predicate not implemented!" );
+ OSL_FAIL( "OSingleSelectQueryComposer::setANDCriteria: in_predicate not implemented!" );
}
else if (SQL_ISRULE(pCondition,all_or_any_predicate))
{
- OSL_ENSURE( false, "OSingleSelectQueryComposer::setANDCriteria: all_or_any_predicate not implemented!" );
+ OSL_FAIL( "OSingleSelectQueryComposer::setANDCriteria: all_or_any_predicate not implemented!" );
}
else if (SQL_ISRULE(pCondition,between_predicate))
{
- OSL_ENSURE( false, "OSingleSelectQueryComposer::setANDCriteria: between_predicate not implemented!" );
+ OSL_FAIL( "OSingleSelectQueryComposer::setANDCriteria: between_predicate not implemented!" );
}
rFilter.push_back(aItem);
@@ -1124,7 +1097,7 @@ sal_Bool OSingleSelectQueryComposer::setANDCriteria( OSQLParseNode * pCondition,
return sal_True;
}
-// -----------------------------------------------------------------------------
+
sal_Int32 OSingleSelectQueryComposer::getPredicateType(OSQLParseNode * _pPredicate) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getPredicateType" );
@@ -1150,16 +1123,16 @@ sal_Int32 OSingleSelectQueryComposer::getPredicateType(OSQLParseNode * _pPredica
nPredicate = SQLFilterOperator::GREATER_EQUAL;
break;
default:
- OSL_ENSURE(0,"Wrong NodeType!");
+ OSL_FAIL("Wrong NodeType!");
}
return nPredicate;
}
-//------------------------------------------------------------------------------
+
sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCondition, OSQLParseTreeIterator& _rIterator,
::std::vector < PropertyValue >& rFilter, const Reference< ::com::sun::star::util::XNumberFormatter > & xFormatter) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setComparsionPredicate" );
- DBG_ASSERT(SQL_ISRULE(pCondition, comparison_predicate),"setComparsionPredicate: pCondition ist kein ComparsionPredicate");
+ OSL_ENSURE(SQL_ISRULE(pCondition, comparison_predicate),"setComparsionPredicate: pCondition ist kein ComparsionPredicate");
if (SQL_ISRULE(pCondition->getChild(0), column_ref) ||
SQL_ISRULE(pCondition->getChild(pCondition->count()-1), column_ref))
{
@@ -1277,8 +1250,8 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
}
return sal_True;
}
+
// functions for analysing SQL
-//--------------------------------------------------------------------------------------------------
::rtl::OUString OSingleSelectQueryComposer::getColumnName( ::connectivity::OSQLParseNode* pColumnRef, OSQLParseTreeIterator& _rIterator ) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getColumnName" );
@@ -1286,7 +1259,7 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
_rIterator.getColumnRange(pColumnRef,aColumnName,aTableRange);
return aColumnName;
}
-//------------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OSingleSelectQueryComposer::getFilter( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getFilter" );
@@ -1294,7 +1267,7 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
::osl::MutexGuard aGuard( m_aMutex );
return getSQLPart(Where,m_aAdditiveIterator,sal_False);
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OSingleSelectQueryComposer::getOrder( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getOrder" );
@@ -1302,7 +1275,7 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
::osl::MutexGuard aGuard( m_aMutex );
return getSQLPart(Order,m_aAdditiveIterator,sal_False);
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OSingleSelectQueryComposer::getGroup( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getGroup" );
@@ -1310,7 +1283,7 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
::osl::MutexGuard aGuard( m_aMutex );
return getSQLPart(Group,m_aAdditiveIterator,sal_False);
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OSingleSelectQueryComposer::getHavingClause() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getHavingClause" );
@@ -1318,7 +1291,7 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
::osl::MutexGuard aGuard( m_aMutex );
return getSQLPart(Having,m_aAdditiveIterator,sal_False);
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OSingleSelectQueryComposer::getTableAlias(const Reference< XPropertySet >& column) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getTableAlias" );
@@ -1336,7 +1309,7 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
const ::rtl::OUString* pEnd = pBegin + aNames.getLength();
if(!aTable.getLength())
- { // we don't found a table name, now we must search every table for this column
+ { // we haven't found a table name, now we must search every table for this column
for(;pBegin != pEnd;++pBegin)
{
Reference<XColumnsSupplier> xColumnsSupp;
@@ -1344,10 +1317,6 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
if(xColumnsSupp.is() && xColumnsSupp->getColumns()->hasByName(aColumnName))
{
-// Reference<XPropertySet> xTableProp(xColumnsSupp,UNO_QUERY);
-// xTableProp->getPropertyValue(PROPERTY_CATALOGNAME) >>= aCatalog;
-// xTableProp->getPropertyValue(PROPERTY_SCHEMANAME) >>= aSchema;
-// xTableProp->getPropertyValue(PROPERTY_NAME) >>= aTable;
aTable = *pBegin;
break;
}
@@ -1393,14 +1362,14 @@ sal_Bool OSingleSelectQueryComposer::setComparsionPredicate(OSQLParseNode * pCon
}
return sReturn;
}
-// -----------------------------------------------------------------------------
+
Reference< XIndexAccess > SAL_CALL OSingleSelectQueryComposer::getParameters( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getParameters" );
// now set the Parameters
if ( !m_aCurrentColumns[ParameterColumns] )
{
- ::vos::ORef< OSQLColumns> aCols = m_aSqlIterator.getParameters();
+ ::rtl::Reference< OSQLColumns> aCols = m_aSqlIterator.getParameters();
::std::vector< ::rtl::OUString> aNames;
OSQLColumns::Vector::const_iterator aEnd = aCols->get().end();
for(OSQLColumns::Vector::const_iterator aIter = aCols->get().begin(); aIter != aEnd;++aIter)
@@ -1410,7 +1379,7 @@ Reference< XIndexAccess > SAL_CALL OSingleSelectQueryComposer::getParameters( )
return m_aCurrentColumns[ParameterColumns];
}
-// -----------------------------------------------------------------------------
+
void OSingleSelectQueryComposer::clearColumns( const EColumnType _eType )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::clearColumns" );
@@ -1422,7 +1391,7 @@ void OSingleSelectQueryComposer::clearColumns( const EColumnType _eType )
m_aCurrentColumns[ _eType ] = NULL;
}
}
-// -----------------------------------------------------------------------------
+
void OSingleSelectQueryComposer::clearCurrentCollections()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::clearCurrentCollections" );
@@ -1445,9 +1414,9 @@ void OSingleSelectQueryComposer::clearCurrentCollections()
m_pTables = NULL;
}
}
-// -----------------------------------------------------------------------------
+
Reference< XIndexAccess > OSingleSelectQueryComposer::setCurrentColumns( EColumnType _eType,
- const ::vos::ORef< OSQLColumns >& _rCols )
+ const ::rtl::Reference< OSQLColumns >& _rCols )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setCurrentColumns" );
::connectivity::checkDisposed(OSubComponent::rBHelper.bDisposed);
@@ -1465,19 +1434,19 @@ Reference< XIndexAccess > OSingleSelectQueryComposer::setCurrentColumns( EColumn
return m_aCurrentColumns[_eType];
}
-// -----------------------------------------------------------------------------
+
Reference< XIndexAccess > SAL_CALL OSingleSelectQueryComposer::getGroupColumns( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getGroupColumns" );
return setCurrentColumns( GroupByColumns, m_aAdditiveIterator.getGroupColumns() );
}
-// -------------------------------------------------------------------------
+
Reference< XIndexAccess > SAL_CALL OSingleSelectQueryComposer::getOrderColumns( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getOrderColumns" );
return setCurrentColumns( OrderColumns, m_aAdditiveIterator.getOrderColumns() );
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OSingleSelectQueryComposer::getQueryWithSubstitution( ) throw (SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getQueryWithSubstitution" );
@@ -1496,7 +1465,7 @@ Reference< XIndexAccess > SAL_CALL OSingleSelectQueryComposer::getOrderColumns(
return sSqlStatement;
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OSingleSelectQueryComposer::getStatementPart( TGetParseNode& _aGetFunctor, OSQLParseTreeIterator& _rIterator )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getStatementPart" );
@@ -1508,7 +1477,7 @@ Reference< XIndexAccess > SAL_CALL OSingleSelectQueryComposer::getOrderColumns(
return sResult;
}
-// -----------------------------------------------------------------------------
+
namespace
{
::rtl::OUString lcl_getCondition(const Sequence< Sequence< PropertyValue > >& filter,const OPredicateInputController& i_aPredicateInputController,const Reference< XNameAccess >& i_xSelectColumns)
@@ -1551,21 +1520,21 @@ namespace
return sRet.makeStringAndClear();
}
}
-// -----------------------------------------------------------------------------
+
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);
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);
setHavingClause(lcl_getCondition(filter,aPredicateInput,getColumns()));
}
-// -----------------------------------------------------------------------------
+
void OSingleSelectQueryComposer::setConditionByColumn( const Reference< XPropertySet >& column, sal_Bool andCriteria ,::std::mem_fun1_t<bool,OSingleSelectQueryComposer,::rtl::OUString>& _aSetFunctor,sal_Int32 filterOperator)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::setConditionByColumn" );
@@ -1631,7 +1600,6 @@ void OSingleSelectQueryComposer::setConditionByColumn( const Reference< XPropert
aSQL.append( ::dbtools::quoteName( aQuote, aName ) );
}
-
if ( aValue.hasValue() )
{
if( !m_xTypeConverter.is() )
@@ -1736,7 +1704,7 @@ void OSingleSelectQueryComposer::setConditionByColumn( const Reference< XPropert
// add the filter and the sort order
_aSetFunctor(this,sFilter);
}
-// -----------------------------------------------------------------------------
+
Sequence< Sequence< PropertyValue > > OSingleSelectQueryComposer::getStructuredCondition( TGetParseNode& _aGetFunctor )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getStructuredCondition" );
@@ -1825,7 +1793,7 @@ Sequence< Sequence< PropertyValue > > OSingleSelectQueryComposer::getStructuredC
}
return aFilterSeq;
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OSingleSelectQueryComposer::getKeyword( SQLPart _ePart ) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getKeyword" );
@@ -1833,7 +1801,7 @@ Sequence< Sequence< PropertyValue > > OSingleSelectQueryComposer::getStructuredC
switch(_ePart)
{
default:
- OSL_ENSURE( 0, "OSingleSelectQueryComposer::getKeyWord: Invalid enum value!" );
+ OSL_FAIL( "OSingleSelectQueryComposer::getKeyWord: Invalid enum value!" );
// no break, fallback to WHERE
case Where:
sKeyword = STR_WHERE;
@@ -1851,7 +1819,6 @@ Sequence< Sequence< PropertyValue > > OSingleSelectQueryComposer::getStructuredC
return sKeyword;
}
-// -----------------------------------------------------------------------------
::rtl::OUString OSingleSelectQueryComposer::getSQLPart( SQLPart _ePart, OSQLParseTreeIterator& _rIterator, sal_Bool _bWithKeyword )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OSingleSelectQueryComposer::getSQLPart" );
@@ -1872,7 +1839,7 @@ Sequence< Sequence< PropertyValue > > OSingleSelectQueryComposer::getStructuredC
F_tmp = TGetParseNode(&OSQLParseTreeIterator::getSimpleOrderTree);
break;
default:
- OSL_ENSURE(0,"Invalid enum value!");
+ OSL_FAIL("Invalid enum value!");
}
::rtl::OUString sRet = getStatementPart( F_tmp, _rIterator );
@@ -1880,4 +1847,4 @@ Sequence< Sequence< PropertyValue > > OSingleSelectQueryComposer::getStructuredC
sRet = sKeyword + sRet;
return sRet;
}
-// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/StaticSet.cxx b/dbaccess/source/core/api/StaticSet.cxx
index 216ccf08eb5d..f76303f41299 100644
--- a/dbaccess/source/core/api/StaticSet.cxx
+++ b/dbaccess/source/core/api/StaticSet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_CORE_API_STATICSET_HXX
#include "StaticSet.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_COMPAREBOOKMARK_HPP_
#include <com/sun/star/sdbcx/CompareBookmark.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPREPAREDSTATEMENT_HPP_
#include <com/sun/star/sdbc/XPreparedStatement.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
#include <rtl/logfile.hxx>
using namespace dbaccess;
@@ -62,41 +45,38 @@ using namespace connectivity;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::sdbc;
-// using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::sdbcx;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::lang;
-// using namespace ::cppu;
using namespace ::osl;
-// -------------------------------------------------------------------------
void OStaticSet::fillValueRow(ORowSetRow& _rRow,sal_Int32 /*_nPosition*/)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::fillValueRow" );
_rRow = *m_aSetIter;
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XRowLocate
Any SAL_CALL OStaticSet::getBookmark() throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::getBookmark" );
return makeAny(getRow());
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::moveToBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::moveToBookmark" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return absolute(::comphelper::getINT32(bookmark));
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::moveRelativeToBookmark( const Any& bookmark, sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::moveRelativeToBookmark" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
return absolute(::comphelper::getINT32(bookmark)+rows);
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OStaticSet::compareBookmarks( const Any& _first, const Any& _second ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::compareBookmarks" );
@@ -105,19 +85,19 @@ sal_Int32 SAL_CALL OStaticSet::compareBookmarks( const Any& _first, const Any& _
_second >>= nSecond;
return (nFirst < nSecond) ? CompareBookmark::LESS : ((nFirst > nSecond) ? CompareBookmark::GREATER : CompareBookmark::EQUAL);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::hasOrderedBookmarks( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::hasOrderedBookmarks" );
return sal_True;
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OStaticSet::hashBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::hashBookmark" );
return ::comphelper::getINT32(bookmark);
}
-// -------------------------------------------------------------------------
+
sal_Bool OStaticSet::fetchRow()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::fetchRow" );
@@ -135,7 +115,7 @@ sal_Bool OStaticSet::fetchRow()
m_bEnd = sal_True;
return bRet;
}
-// -------------------------------------------------------------------------
+
void OStaticSet::fillAllRows()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::fillAllRows" );
@@ -153,7 +133,7 @@ void OStaticSet::fillAllRows()
m_bEnd = sal_True;
}
}
-// -------------------------------------------------------------------------
+
// XResultSet
sal_Bool SAL_CALL OStaticSet::next( ) throw(SQLException, RuntimeException)
{
@@ -172,38 +152,38 @@ sal_Bool SAL_CALL OStaticSet::next( ) throw(SQLException, RuntimeException)
++m_aSetIter;
return !isAfterLast();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::isBeforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::isBeforeFirst" );
return m_aSetIter == m_aSet.begin();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::isAfterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::isAfterLast" );
return m_aSetIter == m_aSet.end() && m_bEnd;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::isFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::isFirst" );
return m_aSetIter == m_aSet.begin()+1;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::isLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::isLast" );
return m_aSetIter == m_aSet.end()-1 && m_bEnd;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::beforeFirst( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::beforeFirst" );
m_bInserted = m_bUpdated = m_bDeleted = sal_False;
m_aSetIter = m_aSet.begin();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::afterLast( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::afterLast" );
@@ -211,7 +191,7 @@ void SAL_CALL OStaticSet::afterLast( ) throw(SQLException, RuntimeException)
fillAllRows();
m_aSetIter = m_aSet.end();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::first( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::first" );
@@ -222,7 +202,7 @@ sal_Bool SAL_CALL OStaticSet::first( ) throw(SQLException, RuntimeException)
return m_aSetIter != m_aSet.end();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::last( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::last" );
@@ -232,7 +212,7 @@ sal_Bool SAL_CALL OStaticSet::last( ) throw(SQLException, RuntimeException)
return !isBeforeFirst() && !isAfterLast();
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OStaticSet::getRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::getRow" );
@@ -243,7 +223,7 @@ sal_Int32 SAL_CALL OStaticSet::getRow( ) throw(SQLException, RuntimeException)
OSL_ENSURE(nPos > 0,"RowPos is < 0");
return nPos;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::absolute( sal_Int32 row ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::absolute" );
@@ -284,7 +264,7 @@ sal_Bool SAL_CALL OStaticSet::absolute( sal_Int32 row ) throw(SQLException, Runt
return m_aSetIter != m_aSet.end() && m_aSetIter != m_aSet.begin();
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::relative( sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::relative" );
@@ -294,7 +274,7 @@ sal_Bool SAL_CALL OStaticSet::relative( sal_Int32 rows ) throw(SQLException, Run
sal_Int32 nCurPos = getRow();
return absolute(nCurPos+rows);
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::previous( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::previous" );
@@ -305,30 +285,30 @@ sal_Bool SAL_CALL OStaticSet::previous( ) throw(SQLException, RuntimeException)
return m_aSetIter != m_aSet.begin();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::refreshRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::refreshRow" );
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::rowUpdated( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::rowUpdated" );
return m_bUpdated;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::rowInserted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::rowInserted" );
return m_bInserted;
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL OStaticSet::rowDeleted( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::rowDeleted" );
return m_bDeleted;
}
-// -------------------------------------------------------------------------
+
Sequence< sal_Int32 > SAL_CALL OStaticSet::deleteRows( const Sequence< Any >& rows,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::deleteRows" );
@@ -342,7 +322,7 @@ Sequence< sal_Int32 > SAL_CALL OStaticSet::deleteRows( const Sequence< Any >& ro
}
return aRet;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLTable& _xTable ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::insertRow" );
@@ -355,13 +335,13 @@ void SAL_CALL OStaticSet::insertRow( const ORowSetRow& _rInsertRow,const connect
m_bEnd = sal_False;
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrginalRow,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::updateRow" );
OCacheSet::updateRow( _rInsertRow,_rOrginalRow,_xTable);
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::deleteRow(const ORowSetRow& _rDeleteRow ,const connectivity::OSQLTable& _xTable ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::deleteRow" );
@@ -374,20 +354,19 @@ void SAL_CALL OStaticSet::deleteRow(const ORowSetRow& _rDeleteRow ,const connect
m_aSet.erase(aPos);
}
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::cancelRowUpdates( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::cancelRowUpdates" );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::moveToInsertRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::moveToInsertRow" );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OStaticSet::moveToCurrentRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStaticSet::moveToCurrentRow" );
}
-// -------------------------------------------------------------------------
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/StaticSet.hxx b/dbaccess/source/core/api/StaticSet.hxx
index 19d0d3023402..82b152161a31 100644
--- a/dbaccess/source/core/api/StaticSet.hxx
+++ b/dbaccess/source/core/api/StaticSet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBACCESS_CORE_API_STATICSET_HXX
#define DBACCESS_CORE_API_STATICSET_HXX
-#ifndef DBACCESS_CORE_API_CACHESET_HXX
#include "CacheSet.hxx"
-#endif
namespace dbaccess
{
@@ -91,3 +90,4 @@ namespace dbaccess
}
#endif //DBACCESS_CORE_API_STATICSET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/TableDeco.cxx b/dbaccess/source/core/api/TableDeco.cxx
index a296833ab6ef..d2b724f68a04 100644
--- a/dbaccess/source/core/api/TableDeco.cxx
+++ b/dbaccess/source/core/api/TableDeco.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,73 +29,30 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_CORE_TABLEDECORATOR_HXX_
#include "TableDeco.hxx"
-#endif
-#ifndef _DBACORE_DEFINITIONCOLUMN_HXX_
#include <definitioncolumn.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HXX_
#include "core_resource.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HRC_
#include "core_resource.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
+#include <osl/diagnose.h>
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_ENUMHELPER_HXX_
#include <comphelper/enumhelper.hxx>
-#endif
-#ifndef _COMPHELPER_CONTAINER_HXX_
#include <comphelper/container.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XREFRESHLISTENER_HPP_
#include <com/sun/star/util/XRefreshListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_PRIVILEGE_HPP_
#include <com/sun/star/sdbcx/Privilege.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBA_CONTAINERMEDIATOR_HXX
#include "ContainerMediator.hxx"
-#endif
#include <rtl/logfile.hxx>
using namespace dbaccess;
@@ -114,7 +72,7 @@ using namespace ::cppu;
//= ODBTableDecorator
//==========================================================================
DBG_NAME(ODBTableDecorator)
-// -----------------------------------------------------------------------------
+
ODBTableDecorator::ODBTableDecorator( const Reference< XConnection >& _rxConnection, const Reference< XColumnsSupplier >& _rxNewTable,
const Reference< XNumberFormatsSupplier >& _rxNumberFormats, const Reference< XNameAccess >& _xColumnDefinitions ) throw(SQLException)
:OTableDescriptor_BASE(m_aMutex)
@@ -131,7 +89,7 @@ ODBTableDecorator::ODBTableDecorator( const Reference< XConnection >& _rxConnect
DBG_CTOR(ODBTableDecorator, NULL);
ODataSettings::registerPropertiesFor(this);
}
-// -------------------------------------------------------------------------
+
ODBTableDecorator::~ODBTableDecorator()
{
DBG_DTOR(ODBTableDecorator, NULL);
@@ -139,7 +97,6 @@ ODBTableDecorator::~ODBTableDecorator()
delete m_pColumns;
}
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > ODBTableDecorator::getImplementationId() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getImplementationId" );
@@ -157,7 +114,6 @@ Sequence< sal_Int8 > ODBTableDecorator::getImplementationId() throw (RuntimeExce
}
// OComponentHelper
-//------------------------------------------------------------------------------
void SAL_CALL ODBTableDecorator::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::disposing" );
@@ -174,7 +130,7 @@ void SAL_CALL ODBTableDecorator::disposing()
m_pColumns->disposing();
m_xColumnMediator = NULL;
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL ODBTableDecorator::convertFastPropertyValue(
Any & rConvertedValue,
Any & rOldValue,
@@ -182,7 +138,6 @@ sal_Bool SAL_CALL ODBTableDecorator::convertFastPropertyValue(
const Any& rValue )
throw (::com::sun::star::lang::IllegalArgumentException)
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::convertFastPropertyValue" );
sal_Bool bRet = sal_True;
switch(nHandle)
{
@@ -225,14 +180,14 @@ sal_Bool SAL_CALL ODBTableDecorator::convertFastPropertyValue(
}
return bRet;
}
-// -----------------------------------------------------------------------------
+
void ODBTableDecorator::setFastPropertyValue_NoBroadcast(sal_Int32 _nHandle, const Any& _rValue) throw (Exception)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::setFastPropertyValue_NoBroadcast" );
switch(_nHandle)
{
case PROPERTY_ID_PRIVILEGES:
- OSL_ENSURE(0,"Property is readonly!");
+ OSL_FAIL("Property is readonly!");
case PROPERTY_ID_FILTER:
case PROPERTY_ID_ORDER:
case PROPERTY_ID_APPLYFILTER:
@@ -293,10 +248,10 @@ void ODBTableDecorator::setFastPropertyValue_NoBroadcast(sal_Int32 _nHandle, con
break;
}
}
-//------------------------------------------------------------------------------
+
void ODBTableDecorator::getFastPropertyValue(Any& _rValue, sal_Int32 _nHandle) const
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getFastPropertyValue" );
+
switch(_nHandle)
{
case PROPERTY_ID_PRIVILEGES:
@@ -371,10 +326,10 @@ void ODBTableDecorator::getFastPropertyValue(Any& _rValue, sal_Int32 _nHandle) c
}
break;
default:
- OSL_ENSURE(0,"Invalid Handle for table");
+ OSL_FAIL("Invalid Handle for table");
}
}
-// -------------------------------------------------------------------------
+
void ODBTableDecorator::construct()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::construct" );
@@ -389,10 +344,9 @@ void ODBTableDecorator::construct()
registerProperty(PROPERTY_PRIVILEGES, PROPERTY_ID_PRIVILEGES, PropertyAttribute::BOUND | PropertyAttribute::READONLY,
&m_nPrivileges, ::getCppuType(static_cast<sal_Int32*>(NULL)));
}
-// -----------------------------------------------------------------------------
+
::cppu::IPropertyArrayHelper* ODBTableDecorator::createArrayHelper(sal_Int32 /*_nId*/) const
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::createArrayHelper" );
Reference<XPropertySet> xProp(m_xTable,UNO_QUERY);
Reference<XPropertySetInfo> xInfo = xProp->getPropertySetInfo();
@@ -419,10 +373,9 @@ void ODBTableDecorator::construct()
return new ::cppu::OPropertyArrayHelper(aTableProps);
}
-// -----------------------------------------------------------------------------
+
::cppu::IPropertyArrayHelper & SAL_CALL ODBTableDecorator::getInfoHelper()
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getInfoHelper" );
Reference<XPropertySet> xProp(m_xTable,UNO_QUERY);
Reference<XPropertySetInfo> xInfo = xProp->getPropertySetInfo();
@@ -438,13 +391,12 @@ void ODBTableDecorator::construct()
// property set infos: Depending on the table for which we act as decorator, different property
// sets might exist.
}
-// -------------------------------------------------------------------------
+
// XServiceInfo
IMPLEMENT_SERVICE_INFO1(ODBTableDecorator, "com.sun.star.sdb.dbaccess.ODBTableDecorator", SERVICE_SDBCX_TABLE)
-// -------------------------------------------------------------------------
+
Any SAL_CALL ODBTableDecorator::queryInterface( const Type & rType ) throw(RuntimeException)
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::queryInterface" );
Any aRet;
if(m_xTable.is())
{
@@ -459,18 +411,15 @@ Any SAL_CALL ODBTableDecorator::queryInterface( const Type & rType ) throw(Runti
return aRet;
}
-// -------------------------------------------------------------------------
+
Sequence< Type > SAL_CALL ODBTableDecorator::getTypes( ) throw(RuntimeException)
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getTypes" );
Reference<XTypeProvider> xTypes(m_xTable,UNO_QUERY);
OSL_ENSURE(xTypes.is(),"Table must be a TypePropvider!");
return xTypes->getTypes();
}
-// -----------------------------------------------------------------------------
// XRename,
-//------------------------------------------------------------------------------
void SAL_CALL ODBTableDecorator::rename( const ::rtl::OUString& _rNewName ) throw(SQLException, ElementExistException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::rename" );
@@ -479,9 +428,6 @@ void SAL_CALL ODBTableDecorator::rename( const ::rtl::OUString& _rNewName ) thro
Reference<XRename> xRename(m_xTable,UNO_QUERY);
if(xRename.is())
{
-// ::rtl::OUString sOldName;
-// Reference<XPropertySet> xProp(m_xTable,UNO_QUERY);
-// xProp->getPropertyValue(PROPERTY_NAME) >>= sOldName;
xRename->rename(_rNewName);
}
else // not supported
@@ -489,7 +435,6 @@ void SAL_CALL ODBTableDecorator::rename( const ::rtl::OUString& _rNewName ) thro
}
// XAlterTable,
-//------------------------------------------------------------------------------
void SAL_CALL ODBTableDecorator::alterColumnByName( const ::rtl::OUString& _rName, const Reference< XPropertySet >& _rxDescriptor ) throw(SQLException, NoSuchElementException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::alterColumnByName" );
@@ -506,7 +451,6 @@ void SAL_CALL ODBTableDecorator::alterColumnByName( const ::rtl::OUString& _rNam
m_pColumns->refresh();
}
-//------------------------------------------------------------------------------
void SAL_CALL ODBTableDecorator::alterColumnByIndex( sal_Int32 _nIndex, const Reference< XPropertySet >& _rxDescriptor ) throw(SQLException, IndexOutOfBoundsException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::alterColumnByIndex" );
@@ -522,7 +466,7 @@ void SAL_CALL ODBTableDecorator::alterColumnByIndex( sal_Int32 _nIndex, const Re
else // not supported
throw SQLException(DBACORE_RESSTRING(RID_STR_COLUMN_ALTER_BY_INDEX),*this,SQLSTATE_GENERAL,1000,Any() );
}
-// -----------------------------------------------------------------------------
+
Reference< XNameAccess> ODBTableDecorator::getIndexes() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getIndexes" );
@@ -530,7 +474,7 @@ Reference< XNameAccess> ODBTableDecorator::getIndexes() throw (RuntimeException)
::connectivity::checkDisposed(OTableDescriptor_BASE::rBHelper.bDisposed);
return Reference< XIndexesSupplier>(m_xTable,UNO_QUERY)->getIndexes();
}
-// -------------------------------------------------------------------------
+
Reference< XIndexAccess> ODBTableDecorator::getKeys() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getKeys" );
@@ -538,7 +482,7 @@ Reference< XIndexAccess> ODBTableDecorator::getKeys() throw (RuntimeException)
::connectivity::checkDisposed(OTableDescriptor_BASE::rBHelper.bDisposed);
return Reference< XKeysSupplier>(m_xTable,UNO_QUERY)->getKeys();
}
-// -------------------------------------------------------------------------
+
Reference< XNameAccess> ODBTableDecorator::getColumns() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getColumns" );
@@ -550,7 +494,7 @@ Reference< XNameAccess> ODBTableDecorator::getColumns() throw (RuntimeException)
return m_pColumns;
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL ODBTableDecorator::getName() throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getName" );
@@ -560,7 +504,7 @@ Reference< XNameAccess> ODBTableDecorator::getColumns() throw (RuntimeException)
OSL_ENSURE(xName.is(),"Table should support the XNamed interface");
return xName->getName();
}
-// -----------------------------------------------------------------------------
+
sal_Int64 SAL_CALL ODBTableDecorator::getSomething( const Sequence< sal_Int8 >& rId ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getSomething" );
@@ -573,7 +517,7 @@ sal_Int64 SAL_CALL ODBTableDecorator::getSomething( const Sequence< sal_Int8 >&
nRet = xTunnel->getSomething(rId);
return nRet;
}
-// -----------------------------------------------------------------------------
+
Sequence< sal_Int8 > ODBTableDecorator::getUnoTunnelImplementationId()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getUnoTunnelImplementationId" );
@@ -589,11 +533,11 @@ Sequence< sal_Int8 > ODBTableDecorator::getUnoTunnelImplementationId()
}
return pId->getImplementationId();
}
-// -----------------------------------------------------------------------------
+
void ODBTableDecorator::fillPrivileges() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::fillPrivileges" );
- // somebody is asking for the privileges an we do not know them, yet
+ // somebody is asking for the privileges and we do not know them, yet
m_nPrivileges = 0;
try
{
@@ -617,10 +561,10 @@ void ODBTableDecorator::fillPrivileges() const
catch(const SQLException& e)
{
(void)e;
- DBG_ERROR("ODBTableDecorator::ODBTableDecorator : could not collect the privileges !");
+ OSL_FAIL("ODBTableDecorator::ODBTableDecorator : could not collect the privileges !");
}
}
-// -----------------------------------------------------------------------------
+
Reference< XPropertySet > SAL_CALL ODBTableDecorator::createDataDescriptor( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::createDataDescriptor" );
@@ -628,7 +572,7 @@ Reference< XPropertySet > SAL_CALL ODBTableDecorator::createDataDescriptor( ) t
::connectivity::checkDisposed(OTableDescriptor_BASE::rBHelper.bDisposed);
Reference< XDataDescriptorFactory > xFactory( m_xTable, UNO_QUERY );
- DBG_ASSERT( xFactory.is(), "ODBTableDecorator::createDataDescriptor: invalid table!" );
+ OSL_ENSURE( xFactory.is(), "ODBTableDecorator::createDataDescriptor: invalid table!" );
Reference< XColumnsSupplier > xColsSupp;
if ( xFactory.is() )
xColsSupp = xColsSupp.query( xFactory->createDataDescriptor() );
@@ -640,13 +584,13 @@ Reference< XPropertySet > SAL_CALL ODBTableDecorator::createDataDescriptor( ) t
NULL
);
}
-// -----------------------------------------------------------------------------
+
Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL ODBTableDecorator::getPropertySetInfo( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::getPropertySetInfo" );
return ::cppu::OPropertySetHelper::createPropertySetInfo(getInfoHelper());
}
-// -----------------------------------------------------------------------------
+
void ODBTableDecorator::refreshColumns()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::refreshColumns" );
@@ -684,7 +628,7 @@ void ODBTableDecorator::refreshColumns()
else
m_pColumns->reFill(aVector);
}
-// -----------------------------------------------------------------------------
+
OColumn* ODBTableDecorator::createColumn(const ::rtl::OUString& _rName) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::createColumn" );
@@ -708,13 +652,13 @@ OColumn* ODBTableDecorator::createColumn(const ::rtl::OUString& _rName) const
}
return pReturn;
}
-// -----------------------------------------------------------------------------
+
void ODBTableDecorator::columnAppended( const Reference< XPropertySet >& /*_rxSourceDescriptor*/ )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::columnAppended" );
// not interested in
}
-// -----------------------------------------------------------------------------
+
void ODBTableDecorator::columnDropped(const ::rtl::OUString& _sName)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::columnDropped" );
@@ -723,7 +667,6 @@ void ODBTableDecorator::columnDropped(const ::rtl::OUString& _sName)
xDrop->dropByName(_sName);
}
-// -----------------------------------------------------------------------------
Reference< XPropertySet > ODBTableDecorator::createColumnDescriptor()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::createColumnDescriptor" );
@@ -735,24 +678,20 @@ Reference< XPropertySet > ODBTableDecorator::createColumnDescriptor()
xRet = new OTableColumnDescriptorWrapper( xNames->createDataDescriptor(), false, true );
return xRet;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODBTableDecorator::acquire() throw()
{
OTableDescriptor_BASE::acquire();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODBTableDecorator::release() throw()
{
OTableDescriptor_BASE::release();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODBTableDecorator::setName( const ::rtl::OUString& /*aName*/ ) throw (::com::sun::star::uno::RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTableDecorator::setName" );
throwFunctionNotSupportedException( "XNamed::setName", *this );
}
-
-// -----------------------------------------------------------------------------
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/View.cxx b/dbaccess/source/core/api/View.cxx
index fa528d203466..56148298960d 100644
--- a/dbaccess/source/core/api/View.cxx
+++ b/dbaccess/source/core/api/View.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: View.cxx,v $
- * $Revision: 1.3 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -47,10 +45,8 @@
#include <tools/diagnose_ex.h>
#include <unotools/sharedunocomponent.hxx>
-//........................................................................
namespace dbaccess
{
-//........................................................................
/** === begin UNO using === **/
using namespace ::com::sun::star::uno;
@@ -78,7 +74,6 @@ namespace dbaccess
//====================================================================
//= View
//====================================================================
- //--------------------------------------------------------------------
View::View( const Reference< XConnection >& _rxConnection, sal_Bool _bCaseSensitive,
const ::rtl::OUString& _rCatalogName,const ::rtl::OUString& _rSchemaName, const ::rtl::OUString& _rName )
:View_Base( _bCaseSensitive, _rName, _rxConnection->getMetaData(), 0, ::rtl::OUString(), _rSchemaName, _rCatalogName )
@@ -96,15 +91,13 @@ namespace dbaccess
}
}
- //--------------------------------------------------------------------
View::~View()
{
}
- //--------------------------------------------------------------------
IMPLEMENT_FORWARD_REFCOUNT( View, View_Base )
IMPLEMENT_GET_IMPLEMENTATION_ID( View )
- // -------------------------------------------------------------------------
+
Any SAL_CALL View::queryInterface( const Type & _rType ) throw(RuntimeException)
{
if(_rType == getCppuType( (Reference<XAlterView>*)0) && !m_xViewAccess.is() )
@@ -114,7 +107,7 @@ namespace dbaccess
aReturn = View_IBASE::queryInterface( _rType );
return aReturn;
}
- // -------------------------------------------------------------------------
+
Sequence< Type > SAL_CALL View::getTypes( ) throw(RuntimeException)
{
Type aAlterType = getCppuType( (Reference<XAlterView>*)0);
@@ -135,14 +128,12 @@ namespace dbaccess
return Sequence< Type >(pTypes, aOwnTypes.size());
}
- //--------------------------------------------------------------------
void SAL_CALL View::alterCommand( const ::rtl::OUString& _rNewCommand ) throw (SQLException, RuntimeException)
{
OSL_ENSURE(m_xViewAccess.is(),"Illegal call to AlterView!");
m_xViewAccess->alterCommand(this,_rNewCommand);
}
- //--------------------------------------------------------------------
void SAL_CALL View::getFastPropertyValue( Any& _rValue, sal_Int32 _nHandle ) const
{
if ( _nHandle == m_nCommandHandle && m_xViewAccess.is() )
@@ -155,7 +146,6 @@ namespace dbaccess
View_Base::getFastPropertyValue( _rValue, _nHandle );
}
- // -----------------------------------------------------------------------------
-//........................................................................
+
} // namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/WrappedResultSet.cxx b/dbaccess/source/core/api/WrappedResultSet.cxx
index 22e8f61383ac..794015333d6d 100644
--- a/dbaccess/source/core/api/WrappedResultSet.cxx
+++ b/dbaccess/source/core/api/WrappedResultSet.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: BookmarkSet.cxx,v $
- * $Revision: 1.21 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -45,11 +43,9 @@ using namespace ::dbtools;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::sdbc;
-// using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::sdbcx;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::lang;
-// using namespace ::cppu;
using namespace ::osl;
void WrappedResultSet::construct(const Reference< XResultSet>& _xDriverSet,const ::rtl::OUString& i_sRowSetFilter)
@@ -60,7 +56,7 @@ void WrappedResultSet::construct(const Reference< XResultSet>& _xDriverSet,const
m_xRowLocate.set(_xDriverSet,UNO_QUERY_THROW);
m_xUpdRow.set(_xDriverSet,UNO_QUERY_THROW);
}
-// -----------------------------------------------------------------------------
+
Any SAL_CALL WrappedResultSet::getBookmark() throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::getBookmark" );
@@ -70,37 +66,37 @@ Any SAL_CALL WrappedResultSet::getBookmark() throw(SQLException, RuntimeExceptio
}
return makeAny(m_xDriverSet->getRow());
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL WrappedResultSet::moveToBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::moveToBookmark" );
return m_xRowLocate->moveToBookmark( bookmark );
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL WrappedResultSet::moveRelativeToBookmark( const Any& bookmark, sal_Int32 rows ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::moveRelativeToBookmark" );
return m_xRowLocate->moveRelativeToBookmark( bookmark,rows );
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL WrappedResultSet::compareBookmarks( const Any& _first, const Any& _second ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::compareBookmarks" );
return m_xRowLocate->compareBookmarks( _first,_second );
}
-// -------------------------------------------------------------------------
+
sal_Bool SAL_CALL WrappedResultSet::hasOrderedBookmarks( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::hasOrderedBookmarks" );
return m_xRowLocate->hasOrderedBookmarks();
}
-// -------------------------------------------------------------------------
+
sal_Int32 SAL_CALL WrappedResultSet::hashBookmark( const Any& bookmark ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::hashBookmark" );
return m_xRowLocate->hashBookmark(bookmark);
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::sdbcx::XDeleteRows
Sequence< sal_Int32 > SAL_CALL WrappedResultSet::deleteRows( const Sequence< Any >& rows ,const connectivity::OSQLTable& /*_xTable*/) throw(SQLException, RuntimeException)
{
@@ -112,7 +108,7 @@ Sequence< sal_Int32 > SAL_CALL WrappedResultSet::deleteRows( const Sequence< Any
}
return Sequence< sal_Int32 >();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL WrappedResultSet::insertRow( const ORowSetRow& _rInsertRow,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::insertRow" );
@@ -128,7 +124,7 @@ void SAL_CALL WrappedResultSet::insertRow( const ORowSetRow& _rInsertRow,const c
m_xUpd->insertRow();
(*_rInsertRow->get().begin()) = getBookmark();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL WrappedResultSet::updateRow(const ORowSetRow& _rInsertRow ,const ORowSetRow& _rOrginalRow,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::updateRow" );
@@ -142,37 +138,37 @@ void SAL_CALL WrappedResultSet::updateRow(const ORowSetRow& _rInsertRow ,const O
}
m_xUpd->updateRow();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL WrappedResultSet::deleteRow(const ORowSetRow& /*_rDeleteRow*/ ,const connectivity::OSQLTable& /*_xTable*/ ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::deleteRow" );
m_xUpd->deleteRow();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL WrappedResultSet::cancelRowUpdates( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::cancelRowUpdates" );
m_xUpd->cancelRowUpdates();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL WrappedResultSet::moveToInsertRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::moveToInsertRow" );
m_xUpd->moveToInsertRow();
}
-// -------------------------------------------------------------------------
+
void SAL_CALL WrappedResultSet::moveToCurrentRow( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::moveToCurrentRow" );
m_xUpd->moveToCurrentRow();
}
-// -------------------------------------------------------------------------
+
void WrappedResultSet::fillValueRow(ORowSetRow& _rRow,sal_Int32 _nPosition)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::fillValueRow" );
OCacheSet::fillValueRow(_rRow,_nPosition);
}
-// -------------------------------------------------------------------------
+
void WrappedResultSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xParameter,const ORowSetValue& _rValue)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "WrappedResultSet::updateColumn" );
@@ -191,8 +187,6 @@ void WrappedResultSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xPar
break;
case DataType::CHAR:
case DataType::VARCHAR:
- //case DataType::DECIMAL:
- //case DataType::NUMERIC:
_xParameter->updateString(nPos,_rValue);
break;
case DataType::BIGINT:
@@ -252,4 +246,4 @@ void WrappedResultSet::updateColumn(sal_Int32 nPos,Reference< XRowUpdate > _xPar
}
}
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/WrappedResultSet.hxx b/dbaccess/source/core/api/WrappedResultSet.hxx
index 34860e0da390..8765a183afb7 100644
--- a/dbaccess/source/core/api/WrappedResultSet.hxx
+++ b/dbaccess/source/core/api/WrappedResultSet.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: BookmarkSet.hxx,v $
- * $Revision: 1.11 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -31,9 +29,7 @@
#ifndef DBACCESS_CORE_API_WRAPPEDRESULTSET_HXX
#define DBACCESS_CORE_API_WRAPPEDRESULTSET_HXX
-#ifndef DBACCESS_CORE_API_CACHESET_HXX
#include "CacheSet.hxx"
-#endif
#include <com/sun/star/sdbc/XRowUpdate.hpp>
#include <com/sun/star/sdbc/XResultSetUpdate.hpp>
@@ -77,3 +73,4 @@ namespace dbaccess
}
#endif // DBACCESS_CORE_API_WRAPPEDRESULTSET_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/callablestatement.cxx b/dbaccess/source/core/api/callablestatement.cxx
index 22057ff7a9f6..4f052bdf42b6 100644
--- a/dbaccess/source/core/api/callablestatement.cxx
+++ b/dbaccess/source/core/api/callablestatement.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREAPI_CALLABLESTATEMENT_HXX_
#include <callablestatement.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX //autogen
#include <tools/debug.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
#include <rtl/logfile.hxx>
using namespace dbaccess;
@@ -57,7 +46,6 @@ using namespace ::cppu;
using namespace ::osl;
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > OCallableStatement::getTypes() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getTypes" );
@@ -68,7 +56,6 @@ Sequence< Type > OCallableStatement::getTypes() throw (RuntimeException)
return aTypes.getTypes();
}
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > OCallableStatement::getImplementationId() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getImplementationId" );
@@ -86,7 +73,6 @@ Sequence< sal_Int8 > OCallableStatement::getImplementationId() throw (RuntimeExc
}
// com::sun::star::uno::XInterface
-//--------------------------------------------------------------------------
Any OCallableStatement::queryInterface( const Type & rType ) throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::queryInterface" );
@@ -99,27 +85,23 @@ Any OCallableStatement::queryInterface( const Type & rType ) throw (RuntimeExcep
return aIface;
}
-//--------------------------------------------------------------------------
void OCallableStatement::acquire() throw ()
{
OPreparedStatement::acquire();
}
-//--------------------------------------------------------------------------
void OCallableStatement::release() throw ()
{
OPreparedStatement::release();
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OCallableStatement::getImplementationName( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getImplementationName" );
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OCallableStatement");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OCallableStatement"));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OCallableStatement::getSupportedServiceNames( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getSupportedServiceNames" );
@@ -130,7 +112,6 @@ Sequence< ::rtl::OUString > OCallableStatement::getSupportedServiceNames( ) thr
}
// XOutParameters
-//------------------------------------------------------------------------------
void SAL_CALL OCallableStatement::registerOutParameter( sal_Int32 parameterIndex, sal_Int32 sqlType, const ::rtl::OUString& typeName ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::registerOutParameter" );
@@ -138,11 +119,9 @@ void SAL_CALL OCallableStatement::registerOutParameter( sal_Int32 parameterIndex
::connectivity::checkDisposed(OComponentHelper::rBHelper.bDisposed);
-
Reference< XOutParameters >(m_xAggregateAsSet, UNO_QUERY)->registerOutParameter( parameterIndex, sqlType, typeName );
}
-//------------------------------------------------------------------------------
void SAL_CALL OCallableStatement::registerNumericOutParameter( sal_Int32 parameterIndex, sal_Int32 sqlType, sal_Int32 scale ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::registerNumericOutParameter" );
@@ -153,7 +132,6 @@ void SAL_CALL OCallableStatement::registerNumericOutParameter( sal_Int32 paramet
}
// XRow
-//------------------------------------------------------------------------------
sal_Bool SAL_CALL OCallableStatement::wasNull( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::wasNull" );
@@ -163,7 +141,6 @@ sal_Bool SAL_CALL OCallableStatement::wasNull( ) throw(SQLException, RuntimeExc
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->wasNull();
}
-//------------------------------------------------------------------------------
::rtl::OUString SAL_CALL OCallableStatement::getString( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getString" );
@@ -173,7 +150,6 @@ sal_Bool SAL_CALL OCallableStatement::wasNull( ) throw(SQLException, RuntimeExc
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getString( columnIndex );
}
-//------------------------------------------------------------------------------
sal_Bool SAL_CALL OCallableStatement::getBoolean( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getBoolean" );
@@ -183,7 +159,6 @@ sal_Bool SAL_CALL OCallableStatement::getBoolean( sal_Int32 columnIndex ) throw(
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getBoolean( columnIndex );
}
-//------------------------------------------------------------------------------
sal_Int8 SAL_CALL OCallableStatement::getByte( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getByte" );
@@ -193,7 +168,6 @@ sal_Int8 SAL_CALL OCallableStatement::getByte( sal_Int32 columnIndex ) throw(SQL
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getByte( columnIndex );
}
-//------------------------------------------------------------------------------
sal_Int16 SAL_CALL OCallableStatement::getShort( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getShort" );
@@ -202,7 +176,6 @@ sal_Int16 SAL_CALL OCallableStatement::getShort( sal_Int32 columnIndex ) throw(S
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getShort( columnIndex );
}
-//------------------------------------------------------------------------------
sal_Int32 SAL_CALL OCallableStatement::getInt( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getInt" );
@@ -211,7 +184,6 @@ sal_Int32 SAL_CALL OCallableStatement::getInt( sal_Int32 columnIndex ) throw(SQL
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getInt( columnIndex );
}
-//------------------------------------------------------------------------------
sal_Int64 SAL_CALL OCallableStatement::getLong( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getLong" );
@@ -220,7 +192,6 @@ sal_Int64 SAL_CALL OCallableStatement::getLong( sal_Int32 columnIndex ) throw(SQ
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getLong( columnIndex );
}
-//------------------------------------------------------------------------------
float SAL_CALL OCallableStatement::getFloat( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getFloat" );
@@ -229,7 +200,6 @@ float SAL_CALL OCallableStatement::getFloat( sal_Int32 columnIndex ) throw(SQLEx
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getFloat( columnIndex );
}
-//------------------------------------------------------------------------------
double SAL_CALL OCallableStatement::getDouble( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getDouble" );
@@ -238,7 +208,6 @@ double SAL_CALL OCallableStatement::getDouble( sal_Int32 columnIndex ) throw(SQL
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getDouble( columnIndex );
}
-//------------------------------------------------------------------------------
Sequence< sal_Int8 > SAL_CALL OCallableStatement::getBytes( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getBytes" );
@@ -247,7 +216,6 @@ Sequence< sal_Int8 > SAL_CALL OCallableStatement::getBytes( sal_Int32 columnInde
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getBytes( columnIndex );
}
-//------------------------------------------------------------------------------
::com::sun::star::util::Date SAL_CALL OCallableStatement::getDate( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getDate" );
@@ -256,7 +224,6 @@ Sequence< sal_Int8 > SAL_CALL OCallableStatement::getBytes( sal_Int32 columnInde
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getDate( columnIndex );
}
-//------------------------------------------------------------------------------
::com::sun::star::util::Time SAL_CALL OCallableStatement::getTime( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getTime" );
@@ -265,7 +232,6 @@ Sequence< sal_Int8 > SAL_CALL OCallableStatement::getBytes( sal_Int32 columnInde
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getTime( columnIndex );
}
-//------------------------------------------------------------------------------
::com::sun::star::util::DateTime SAL_CALL OCallableStatement::getTimestamp( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getTimestamp" );
@@ -275,7 +241,6 @@ Sequence< sal_Int8 > SAL_CALL OCallableStatement::getBytes( sal_Int32 columnInde
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getTimestamp( columnIndex );
}
-//------------------------------------------------------------------------------
Reference< ::com::sun::star::io::XInputStream > SAL_CALL OCallableStatement::getBinaryStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getBinaryStream" );
@@ -285,7 +250,6 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL OCallableStatement::get
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getBinaryStream( columnIndex );
}
-//------------------------------------------------------------------------------
Reference< ::com::sun::star::io::XInputStream > SAL_CALL OCallableStatement::getCharacterStream( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getCharacterStream" );
@@ -295,7 +259,6 @@ Reference< ::com::sun::star::io::XInputStream > SAL_CALL OCallableStatement::get
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getCharacterStream( columnIndex );
}
-//------------------------------------------------------------------------------
Any SAL_CALL OCallableStatement::getObject( sal_Int32 columnIndex, const Reference< ::com::sun::star::container::XNameAccess >& typeMap ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getObject" );
@@ -305,7 +268,6 @@ Any SAL_CALL OCallableStatement::getObject( sal_Int32 columnIndex, const Referen
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getObject( columnIndex, typeMap );
}
-//------------------------------------------------------------------------------
Reference< XRef > SAL_CALL OCallableStatement::getRef( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getRef" );
@@ -314,7 +276,6 @@ Reference< XRef > SAL_CALL OCallableStatement::getRef( sal_Int32 columnIndex ) t
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getRef( columnIndex );
}
-//------------------------------------------------------------------------------
Reference< XBlob > SAL_CALL OCallableStatement::getBlob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getBlob" );
@@ -323,7 +284,6 @@ Reference< XBlob > SAL_CALL OCallableStatement::getBlob( sal_Int32 columnIndex )
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getBlob( columnIndex );
}
-//------------------------------------------------------------------------------
Reference< XClob > SAL_CALL OCallableStatement::getClob( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getClob" );
@@ -332,7 +292,6 @@ Reference< XClob > SAL_CALL OCallableStatement::getClob( sal_Int32 columnIndex )
return Reference< XRow >(m_xAggregateAsSet, UNO_QUERY)->getClob( columnIndex );
}
-//------------------------------------------------------------------------------
Reference< XArray > SAL_CALL OCallableStatement::getArray( sal_Int32 columnIndex ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OCallableStatement::getArray" );
@@ -342,3 +301,4 @@ Reference< XArray > SAL_CALL OCallableStatement::getArray( sal_Int32 columnIndex
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/column.cxx b/dbaccess/source/core/api/column.cxx
index 292bf5694793..bcb19b18b847 100644
--- a/dbaccess/source/core/api/column.cxx
+++ b/dbaccess/source/core/api/column.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,7 +78,6 @@ DBG_NAME(OColumn)
//============================================================
//= OColumn
//============================================================
-//--------------------------------------------------------------------------
OColumn::OColumn( const bool _bNameIsReadOnly )
:OColumnBase( m_aMutex )
,::comphelper::OPropertyContainer( OColumnBase::rBHelper )
@@ -88,14 +88,12 @@ OColumn::OColumn( const bool _bNameIsReadOnly )
&m_sName, ::getCppuType( &m_sName ) );
}
-//--------------------------------------------------------------------------
OColumn::~OColumn()
{
DBG_DTOR(OColumn, NULL);
}
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > OColumn::getTypes() throw (RuntimeException)
{
return ::comphelper::concatSequences(
@@ -108,19 +106,16 @@ Sequence< Type > OColumn::getTypes() throw (RuntimeException)
IMPLEMENT_FORWARD_XINTERFACE2( OColumn, OColumnBase, ::comphelper::OPropertyContainer )
// ::com::sun::star::lang::XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OColumn::getImplementationName( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OColumn");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OColumn"));
}
-//------------------------------------------------------------------------------
sal_Bool OColumn::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OColumn::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 1 );
@@ -129,49 +124,42 @@ Sequence< ::rtl::OUString > OColumn::getSupportedServiceNames( ) throw (Runtime
}
// OComponentHelper
-//------------------------------------------------------------------------------
void OColumn::disposing()
{
OPropertyContainer::disposing();
}
// com::sun::star::beans::XPropertySet
-//------------------------------------------------------------------------------
Reference< XPropertySetInfo > OColumn::getPropertySetInfo() throw (RuntimeException)
{
return createPropertySetInfo( getInfoHelper() ) ;
}
-// -----------------------------------------------------------------------------
::rtl::OUString SAL_CALL OColumn::getName( ) throw(::com::sun::star::uno::RuntimeException)
{
return m_sName;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OColumn::setName( const ::rtl::OUString& _rName ) throw(::com::sun::star::uno::RuntimeException)
{
m_sName = _rName;
}
-// -----------------------------------------------------------------------------
void OColumn::fireValueChange(const ::connectivity::ORowSetValue& /*_rOldValue*/)
{
- DBG_ERROR( "OColumn::fireValueChange: not implemented!" );
+ OSL_FAIL( "OColumn::fireValueChange: not implemented!" );
}
-//------------------------------------------------------------------------------
void OColumn::registerProperty( const ::rtl::OUString& _rName, sal_Int32 _nHandle, sal_Int32 _nAttributes, void* _pPointerToMember, const Type& _rMemberType )
{
::comphelper::OPropertyContainer::registerProperty( _rName, _nHandle, _nAttributes, _pPointerToMember, _rMemberType );
}
-//------------------------------------------------------------------------------
void OColumn::registerMayBeVoidProperty( const ::rtl::OUString& _rName, sal_Int32 _nHandle, sal_Int32 _nAttributes, Any* _pPointerToMember, const Type& _rExpectedType )
{
::comphelper::OPropertyContainer::registerMayBeVoidProperty( _rName, _nHandle, _nAttributes, _pPointerToMember, _rExpectedType );
}
-//------------------------------------------------------------------------------
void OColumn::registerPropertyNoMember( const ::rtl::OUString& _rName, sal_Int32 _nHandle, sal_Int32 _nAttributes, const Type& _rType, const void* _pInitialValue )
{
::comphelper::OPropertyContainer::registerPropertyNoMember( _rName, _nHandle, _nAttributes, _rType, _pInitialValue );
@@ -182,7 +170,6 @@ void OColumn::registerPropertyNoMember( const ::rtl::OUString& _rName, sal_Int32
//============================================================
DBG_NAME(OColumns);
-//--------------------------------------------------------------------------
OColumns::OColumns(::cppu::OWeakObject& _rParent,
::osl::Mutex& _rMutex,
sal_Bool _bCaseSensitive,const ::std::vector< ::rtl::OUString> &_rVector,
@@ -203,7 +190,6 @@ OColumns::OColumns(::cppu::OWeakObject& _rParent,
DBG_CTOR(OColumns, NULL);
}
-// -------------------------------------------------------------------------
OColumns::OColumns(::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex,
const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _rxDrvColumns,
sal_Bool _bCaseSensitive,const ::std::vector< ::rtl::OUString> &_rVector,
@@ -223,26 +209,23 @@ OColumns::OColumns(::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex,
{
DBG_CTOR(OColumns, NULL);
}
-//--------------------------------------------------------------------------
+
OColumns::~OColumns()
{
DBG_DTOR(OColumns, NULL);
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OColumns::getImplementationName( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OColumns");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OColumns"));
}
-//------------------------------------------------------------------------------
sal_Bool OColumns::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OColumns::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 1 );
@@ -271,7 +254,6 @@ void OColumns::clearColumns()
disposing();
}
-// -----------------------------------------------------------------------------
void SAL_CALL OColumns::disposing(void)
{
MutexGuard aGuard(m_rMutex);
@@ -281,14 +263,12 @@ void SAL_CALL OColumns::disposing(void)
OColumns_BASE::disposing();
}
-// -------------------------------------------------------------------------
void OColumns::impl_refresh() throw(::com::sun::star::uno::RuntimeException)
{
if (m_pRefreshColumns)
m_pRefreshColumns->refreshColumns();
}
-// -------------------------------------------------------------------------
connectivity::sdbcx::ObjectType OColumns::createObject(const ::rtl::OUString& _rName)
{
OSL_ENSURE(m_pColFactoryImpl, "OColumns::createObject: no column factory!");
@@ -308,7 +288,7 @@ connectivity::sdbcx::ObjectType OColumns::createObject(const ::rtl::OUString& _r
return xRet;
}
-// -------------------------------------------------------------------------
+
Reference< XPropertySet > OColumns::createDescriptor()
{
if ( m_pColFactoryImpl )
@@ -322,7 +302,7 @@ Reference< XPropertySet > OColumns::createDescriptor()
else
return Reference< XPropertySet >();
}
-// -------------------------------------------------------------------------
+
Any SAL_CALL OColumns::queryInterface( const Type & rType ) throw(RuntimeException)
{
Any aRet;
@@ -348,7 +328,7 @@ Any SAL_CALL OColumns::queryInterface( const Type & rType ) throw(RuntimeExcepti
aRet = TXChild::queryInterface( rType);
return aRet;
}
-// -------------------------------------------------------------------------
+
Sequence< Type > SAL_CALL OColumns::getTypes( ) throw(RuntimeException)
{
sal_Bool bAppendFound = sal_False,bDropFound = sal_False;
@@ -399,7 +379,7 @@ Sequence< Type > SAL_CALL OColumns::getTypes( ) throw(RuntimeException)
}
return aRet;
}
-// -------------------------------------------------------------------------
+
// XAppend
sdbcx::ObjectType OColumns::appendObject( const ::rtl::OUString& _rForName, const Reference< XPropertySet >& descriptor )
{
@@ -437,7 +417,7 @@ sdbcx::ObjectType OColumns::appendObject( const ::rtl::OUString& _rForName, cons
return xReturn;
}
-// -------------------------------------------------------------------------
+
// XDrop
void OColumns::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName)
{
@@ -465,17 +445,16 @@ void OColumns::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName)
::dbaccess::notifyDataSourceModified(m_xParent,sal_True);
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL OColumns::getParent( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_rMutex);
return m_xParent;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OColumns::setParent( const Reference< XInterface >& _xParent ) throw (NoSupportException, RuntimeException)
{
::osl::MutexGuard aGuard(m_rMutex);
m_xParent = _xParent;
}
-// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/columnsettings.cxx b/dbaccess/source/core/api/columnsettings.cxx
index a88879ca5eb8..985a252cdb57 100644
--- a/dbaccess/source/core/api/columnsettings.cxx
+++ b/dbaccess/source/core/api/columnsettings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -38,6 +39,7 @@
#include <comphelper/property.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <sal/macros.h>
//........................................................................
namespace dbaccess
@@ -66,20 +68,18 @@ namespace dbaccess
//= OColumnSettings
//==============================================================================
DBG_NAME( OColumnSettings )
- //------------------------------------------------------------------------------
+
OColumnSettings::OColumnSettings()
:m_bHidden(sal_False)
{
DBG_CTOR( OColumnSettings, NULL );
}
- //------------------------------------------------------------------------------
OColumnSettings::~OColumnSettings()
{
DBG_DTOR( OColumnSettings, NULL );
}
- //------------------------------------------------------------------------------
void OColumnSettings::registerProperties( IPropertyContainer& _rPropertyContainer )
{
const sal_Int32 nBoundAttr = PropertyAttribute::BOUND;
@@ -98,7 +98,6 @@ namespace dbaccess
_rPropertyContainer.registerProperty( PROPERTY_HIDDEN, PROPERTY_ID_HIDDEN, nBoundAttr, &m_bHidden, ::getCppuType( &m_bHidden ) );
}
- //------------------------------------------------------------------------------
bool OColumnSettings::isColumnSettingProperty( const sal_Int32 _nPropertyHandle )
{
return ( _nPropertyHandle == PROPERTY_ID_ALIGN )
@@ -111,7 +110,6 @@ namespace dbaccess
|| ( _nPropertyHandle == PROPERTY_ID_HIDDEN );
}
- //------------------------------------------------------------------------------
bool OColumnSettings::isDefaulted( const sal_Int32 _nPropertyHandle, const Any& _rPropertyValue )
{
switch ( _nPropertyHandle )
@@ -134,11 +132,10 @@ namespace dbaccess
return !bHidden;
}
}
- OSL_ENSURE( false, "OColumnSettings::isDefaulted: illegal property handle!" );
+ OSL_FAIL( "OColumnSettings::isDefaulted: illegal property handle!" );
return sal_False;
}
- //------------------------------------------------------------------------------
bool OColumnSettings::hasDefaultSettings( const Reference< XPropertySet >& _rxColumn )
{
ENSURE_OR_THROW( _rxColumn.is(), "illegal column" );
@@ -163,7 +160,7 @@ namespace dbaccess
{ PROPERTY_HIDDEN, PROPERTY_ID_HIDDEN }
};
- for ( size_t i=0; i < sizeof( aProps ) / sizeof( aProps[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aProps ); ++i )
{
if ( xPSI->hasPropertyByName( aProps[i].sName ) )
if ( !isDefaulted( aProps[i].nHandle, _rxColumn->getPropertyValue( aProps[i].sName ) ) )
@@ -180,3 +177,5 @@ namespace dbaccess
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/datacolumn.cxx b/dbaccess/source/core/api/datacolumn.cxx
index cb1be701cb99..bca1cadfc01d 100644
--- a/dbaccess/source/core/api/datacolumn.cxx
+++ b/dbaccess/source/core/api/datacolumn.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBACORE_DATACOLUMN_HXX_
#include "datacolumn.hxx"
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNVALUE_HPP_
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
using namespace dbaccess;
using namespace ::com::sun::star::sdbc;
@@ -67,7 +50,7 @@ using namespace ::comphelper;
using namespace ::cppu;
DBG_NAME(ODataColumn)
-//--------------------------------------------------------------------------
+
ODataColumn::ODataColumn(
const Reference < XResultSetMetaData >& _xMetaData,
const Reference < XRow >& _xRow,
@@ -80,14 +63,13 @@ ODataColumn::ODataColumn(
{
DBG_CTOR(ODataColumn,NULL);
}
-// -----------------------------------------------------------------------------
+
ODataColumn::~ODataColumn()
{
DBG_DTOR(ODataColumn,NULL);
}
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > ODataColumn::getTypes() throw (RuntimeException)
{
OTypeCollection aTypes(::getCppuType( (const Reference< XColumn > *)0 ),
@@ -96,7 +78,6 @@ Sequence< Type > ODataColumn::getTypes() throw (RuntimeException)
return aTypes.getTypes();
}
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > ODataColumn::getImplementationId() throw (RuntimeException)
{
static OImplementationId * pId = 0;
@@ -112,7 +93,6 @@ Sequence< sal_Int8 > ODataColumn::getImplementationId() throw (RuntimeException)
return pId->getImplementationId();
}
-//------------------------------------------------------------------------------
Any SAL_CALL ODataColumn::queryInterface( const Type & _rType ) throw (RuntimeException)
{
Any aReturn = OResultColumn::queryInterface(_rType);
@@ -125,13 +105,11 @@ Any SAL_CALL ODataColumn::queryInterface( const Type & _rType ) throw (RuntimeEx
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString ODataColumn::getImplementationName( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.ODataColumn");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ODataColumn"));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > ODataColumn::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 3 );
@@ -142,7 +120,6 @@ Sequence< ::rtl::OUString > ODataColumn::getSupportedServiceNames( ) throw (Run
}
// OComponentHelper
-//------------------------------------------------------------------------------
void ODataColumn::disposing()
{
OResultColumn::disposing();
@@ -152,7 +129,6 @@ void ODataColumn::disposing()
}
// ::com::sun::star::sdb::XColumn
-//------------------------------------------------------------------------------
sal_Bool ODataColumn::wasNull(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -161,7 +137,6 @@ sal_Bool ODataColumn::wasNull(void) throw( SQLException, RuntimeException )
return m_xRow->wasNull();
}
-//------------------------------------------------------------------------------
rtl::OUString ODataColumn::getString(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -170,7 +145,6 @@ rtl::OUString ODataColumn::getString(void) throw( SQLException, RuntimeException
return m_xRow->getString(m_nPos);
}
-//------------------------------------------------------------------------------
sal_Bool ODataColumn::getBoolean(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -179,7 +153,6 @@ sal_Bool ODataColumn::getBoolean(void) throw( SQLException, RuntimeException )
return m_xRow->getBoolean(m_nPos);
}
-//------------------------------------------------------------------------------
sal_Int8 ODataColumn::getByte(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -188,7 +161,6 @@ sal_Int8 ODataColumn::getByte(void) throw( SQLException, RuntimeException )
return m_xRow->getByte(m_nPos);
}
-//------------------------------------------------------------------------------
sal_Int16 ODataColumn::getShort(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -197,7 +169,6 @@ sal_Int16 ODataColumn::getShort(void) throw( SQLException, RuntimeException )
return m_xRow->getShort(m_nPos);
}
-//------------------------------------------------------------------------------
sal_Int32 ODataColumn::getInt(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -206,7 +177,6 @@ sal_Int32 ODataColumn::getInt(void) throw( SQLException, RuntimeException )
return m_xRow->getInt(m_nPos);
}
-//------------------------------------------------------------------------------
sal_Int64 ODataColumn::getLong(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -215,7 +185,6 @@ sal_Int64 ODataColumn::getLong(void) throw( SQLException, RuntimeException )
return m_xRow->getLong(m_nPos);
}
-//------------------------------------------------------------------------------
float ODataColumn::getFloat(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -223,7 +192,7 @@ float ODataColumn::getFloat(void) throw( SQLException, RuntimeException )
return m_xRow->getFloat(m_nPos);
}
-//------------------------------------------------------------------------------
+
double ODataColumn::getDouble(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -232,7 +201,6 @@ double ODataColumn::getDouble(void) throw( SQLException, RuntimeException )
return m_xRow->getDouble(m_nPos);
}
-//------------------------------------------------------------------------------
Sequence< sal_Int8 > ODataColumn::getBytes(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -240,7 +208,7 @@ Sequence< sal_Int8 > ODataColumn::getBytes(void) throw( SQLException, RuntimeExc
return m_xRow->getBytes(m_nPos);
}
-//------------------------------------------------------------------------------
+
com::sun::star::util::Date ODataColumn::getDate(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -249,7 +217,6 @@ com::sun::star::util::Date ODataColumn::getDate(void) throw( SQLException, Runti
return m_xRow->getDate(m_nPos);
}
-//------------------------------------------------------------------------------
com::sun::star::util::Time ODataColumn::getTime(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -257,7 +224,7 @@ com::sun::star::util::Time ODataColumn::getTime(void) throw( SQLException, Runti
return m_xRow->getTime(m_nPos);
}
-//------------------------------------------------------------------------------
+
com::sun::star::util::DateTime ODataColumn::getTimestamp(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -266,7 +233,6 @@ com::sun::star::util::DateTime ODataColumn::getTimestamp(void) throw( SQLExcepti
return m_xRow->getTimestamp(m_nPos);
}
-//------------------------------------------------------------------------------
Reference< ::com::sun::star::io::XInputStream > ODataColumn::getBinaryStream(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -275,7 +241,6 @@ Reference< ::com::sun::star::io::XInputStream > ODataColumn::getBinaryStream(vo
return m_xRow->getBinaryStream(m_nPos);
}
-//------------------------------------------------------------------------------
Reference< ::com::sun::star::io::XInputStream > ODataColumn::getCharacterStream(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -284,7 +249,6 @@ Reference< ::com::sun::star::io::XInputStream > ODataColumn::getCharacterStream
return m_xRow->getCharacterStream(m_nPos);
}
-//------------------------------------------------------------------------------
Any ODataColumn::getObject(const Reference< ::com::sun::star::container::XNameAccess > & typeMap) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -293,7 +257,6 @@ Any ODataColumn::getObject(const Reference< ::com::sun::star::container::XNameAc
return m_xRow->getObject(m_nPos, typeMap);
}
-//------------------------------------------------------------------------------
Reference< XRef > ODataColumn::getRef(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -302,7 +265,6 @@ Reference< XRef > ODataColumn::getRef(void) throw( SQLException, RuntimeExcepti
return m_xRow->getRef(m_nPos);
}
-//------------------------------------------------------------------------------
Reference< XBlob > ODataColumn::getBlob(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -311,7 +273,6 @@ Reference< XBlob > ODataColumn::getBlob(void) throw( SQLException, RuntimeExcep
return m_xRow->getBlob(m_nPos);
}
-//------------------------------------------------------------------------------
Reference< XClob > ODataColumn::getClob(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -320,7 +281,6 @@ Reference< XClob > ODataColumn::getClob(void) throw( SQLException, RuntimeExcep
return m_xRow->getClob(m_nPos);
}
-//------------------------------------------------------------------------------
Reference< XArray > ODataColumn::getArray(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -330,7 +290,6 @@ Reference< XArray > ODataColumn::getArray(void) throw( SQLException, RuntimeExc
}
// ::com::sun::star::sdb::XColumnUpdate
-//------------------------------------------------------------------------------
void ODataColumn::updateNull(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -339,7 +298,6 @@ void ODataColumn::updateNull(void) throw( SQLException, RuntimeException )
m_xRowUpdate->updateNull(m_nPos);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateBoolean(sal_Bool x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -348,7 +306,6 @@ void ODataColumn::updateBoolean(sal_Bool x) throw( SQLException, RuntimeExceptio
m_xRowUpdate->updateBoolean(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateByte(sal_Int8 x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -357,7 +314,6 @@ void ODataColumn::updateByte(sal_Int8 x) throw( SQLException, RuntimeException )
m_xRowUpdate->updateByte(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateShort(sal_Int16 x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -366,7 +322,6 @@ void ODataColumn::updateShort(sal_Int16 x) throw( SQLException, RuntimeException
m_xRowUpdate->updateShort(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateInt(sal_Int32 x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -375,7 +330,6 @@ void ODataColumn::updateInt(sal_Int32 x) throw( SQLException, RuntimeException )
m_xRowUpdate->updateInt(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateLong(sal_Int64 x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -384,7 +338,6 @@ void ODataColumn::updateLong(sal_Int64 x) throw( SQLException, RuntimeException
m_xRowUpdate->updateLong(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateFloat(float x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -393,7 +346,6 @@ void ODataColumn::updateFloat(float x) throw( SQLException, RuntimeException )
m_xRowUpdate->updateFloat(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateDouble(double x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -402,7 +354,6 @@ void ODataColumn::updateDouble(double x) throw( SQLException, RuntimeException )
m_xRowUpdate->updateDouble(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateString(const rtl::OUString& x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -411,7 +362,6 @@ void ODataColumn::updateString(const rtl::OUString& x) throw( SQLException, Runt
m_xRowUpdate->updateString(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateBytes(const Sequence< sal_Int8 >& x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -420,7 +370,6 @@ void ODataColumn::updateBytes(const Sequence< sal_Int8 >& x) throw( SQLException
m_xRowUpdate->updateBytes(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateDate(const com::sun::star::util::Date& x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -429,7 +378,6 @@ void ODataColumn::updateDate(const com::sun::star::util::Date& x) throw( SQLExce
m_xRowUpdate->updateDate(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateTime(const ::com::sun::star::util::Time& x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -438,7 +386,6 @@ void ODataColumn::updateTime(const ::com::sun::star::util::Time& x) throw( SQLEx
m_xRowUpdate->updateTime(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateTimestamp(const ::com::sun::star::util::DateTime& x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -447,7 +394,6 @@ void ODataColumn::updateTimestamp(const ::com::sun::star::util::DateTime& x) thr
m_xRowUpdate->updateTimestamp(m_nPos, x);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateCharacterStream(const Reference< ::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -456,7 +402,6 @@ void ODataColumn::updateCharacterStream(const Reference< ::com::sun::star::io::X
m_xRowUpdate->updateCharacterStream(m_nPos, x, length);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateBinaryStream(const Reference< ::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -465,7 +410,6 @@ void ODataColumn::updateBinaryStream(const Reference< ::com::sun::star::io::XInp
m_xRowUpdate->updateBinaryStream(m_nPos, x, length);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateNumericObject(const Any& x, sal_Int32 scale) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -474,7 +418,6 @@ void ODataColumn::updateNumericObject(const Any& x, sal_Int32 scale) throw( SQLE
m_xRowUpdate->updateNumericObject(m_nPos, x, scale);
}
-//------------------------------------------------------------------------------
void ODataColumn::updateObject(const Any& x) throw( SQLException, RuntimeException )
{
MutexGuard aGuard( m_aMutex );
@@ -482,4 +425,4 @@ void ODataColumn::updateObject(const Any& x) throw( SQLException, RuntimeExcepti
m_xRowUpdate->updateObject(m_nPos, x);
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/datacolumn.hxx b/dbaccess/source/core/api/datacolumn.hxx
index 3c18fd4d830d..fce607807650 100644
--- a/dbaccess/source/core/api/datacolumn.hxx
+++ b/dbaccess/source/core/api/datacolumn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
#ifndef _DBACORE_DATACOLUMN_HXX_
#define _DBACORE_DATACOLUMN_HXX_
-#ifndef _COM_SUN_STAR_SDBC_XROWUPDATE_HPP_
#include <com/sun/star/sdbc/XRowUpdate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATA_HDL_
#include <com/sun/star/sdbc/XResultSetMetaData.hdl>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XCOLUMN_HPP_
#include <com/sun/star/sdb/XColumn.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XCOLUMNUPDATE_HPP_
#include <com/sun/star/sdb/XColumnUpdate.hpp>
-#endif
-#ifndef _DBA_COREAPI_RESULTCOLUMN_HXX_
#include <resultcolumn.hxx>
-#endif
namespace dbaccess
{
//************************************************************
@@ -127,3 +116,4 @@ namespace dbaccess
}
#endif // _DBACORE_RESULTCOLUMN_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/datasettings.cxx b/dbaccess/source/core/api/datasettings.cxx
index 2f5a01fd7004..134cd23a6956 100644
--- a/dbaccess/source/core/api/datasettings.cxx
+++ b/dbaccess/source/core/api/datasettings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,43 +29,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_CORE_DATASETTINGS_HXX_
#include "datasettings.hxx"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTWEIGHT_HPP_
#include <com/sun/star/awt/FontWeight.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTEMPHASISMARK_HPP_
#include <com/sun/star/awt/FontEmphasisMark.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTRELIEF_HPP_
#include <com/sun/star/awt/FontRelief.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTWIDTH_HPP_
#include <com/sun/star/awt/FontWidth.hpp>
-#endif
using namespace ::com::sun::star::uno;
@@ -74,13 +51,11 @@ using namespace ::com::sun::star::beans;
using namespace ::comphelper;
using namespace ::cppu;
-//........................................................................
namespace dbaccess
{
//==========================================================================
//= ODataSettings
//==========================================================================
-//--------------------------------------------------------------------------
void ODataSettings::registerPropertiesFor(ODataSettings_Base* _pItem)
{
if ( m_bQuery )
@@ -136,7 +111,6 @@ void ODataSettings::registerPropertiesFor(ODataSettings_Base* _pItem)
registerProperty(PROPERTY_FONTTYPE, PROPERTY_ID_FONTTYPE, PropertyAttribute::BOUND,&_pItem->m_aFont.Type, ::getCppuType(&_pItem->m_aFont.Type));
}
-//--------------------------------------------------------------------------
ODataSettings::ODataSettings(OBroadcastHelper& _rBHelper,sal_Bool _bQuery)
:OPropertyStateContainer(_rBHelper)
,ODataSettings_Base()
@@ -144,7 +118,6 @@ ODataSettings::ODataSettings(OBroadcastHelper& _rBHelper,sal_Bool _bQuery)
{
}
-//--------------------------------------------------------------------------
ODataSettings_Base::ODataSettings_Base()
:m_bApplyFilter(sal_False)
,m_aFont(::comphelper::getDefaultFont())
@@ -153,7 +126,6 @@ ODataSettings_Base::ODataSettings_Base()
{
}
-//--------------------------------------------------------------------------
ODataSettings_Base::ODataSettings_Base(const ODataSettings_Base& _rSource)
:m_sFilter( _rSource.m_sFilter )
,m_sHavingClause( _rSource.m_sHavingClause )
@@ -169,12 +141,10 @@ ODataSettings_Base::ODataSettings_Base(const ODataSettings_Base& _rSource)
{
}
-// -----------------------------------------------------------------------------
ODataSettings_Base::~ODataSettings_Base()
{
}
-// -----------------------------------------------------------------------------
void ODataSettings::getPropertyDefaultByHandle( sal_Int32 _nHandle, Any& _rDefault ) const
{
static ::com::sun::star::awt::FontDescriptor aFD = ::comphelper::getDefaultFont();
@@ -248,7 +218,6 @@ void ODataSettings::getPropertyDefaultByHandle( sal_Int32 _nHandle, Any& _rDefau
break;
}
}
-//........................................................................
-} // namespace dbaccess
-//........................................................................
+} // namespace dbaccess
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/definitioncolumn.cxx b/dbaccess/source/core/api/definitioncolumn.cxx
index 4620abd661f3..2709369adab9 100644
--- a/dbaccess/source/core/api/definitioncolumn.cxx
+++ b/dbaccess/source/core/api/definitioncolumn.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44,6 +45,7 @@
#include <cppuhelper/typeprovider.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <sal/macros.h>
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::sdbcx;
@@ -66,7 +68,6 @@ using namespace dbaccess;
//============================================================
IMPLEMENT_FORWARD_XINTERFACE2(OTableColumnDescriptor,OColumn,TXChild)
-//------------------------------------------------------------------------------
void OTableColumnDescriptor::impl_registerProperties()
{
sal_Int32 nDefaultAttr = m_bActAsDescriptor ? 0 : PropertyAttribute::READONLY;
@@ -89,17 +90,14 @@ void OTableColumnDescriptor::impl_registerProperties()
OColumnSettings::registerProperties( *this );
}
-//--------------------------------------------------------------------------
IMPLEMENT_GET_IMPLEMENTATION_ID( OTableColumnDescriptor )
// ::com::sun::star::lang::XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OTableColumnDescriptor::getImplementationName( ) throw (RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OTableColumnDescriptor");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OTableColumnDescriptor"));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OTableColumnDescriptor::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 2 );
@@ -109,7 +107,6 @@ Sequence< ::rtl::OUString > OTableColumnDescriptor::getSupportedServiceNames( )
}
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OTableColumnDescriptor::createArrayHelper( ) const
{
Sequence< Property > aProps;
@@ -118,26 +115,23 @@ Sequence< ::rtl::OUString > OTableColumnDescriptor::getSupportedServiceNames( )
}
// cppu::OPropertySetHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OTableColumnDescriptor::getInfoHelper()
{
return *static_cast< ::comphelper::OPropertyArrayUsageHelper< OTableColumnDescriptor >* >(this)->getArrayHelper();
}
-//------------------------------------------------------------------------------
void OTableColumnDescriptor::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any& rValue ) throw (Exception)
{
OColumn::setFastPropertyValue_NoBroadcast( nHandle, rValue );
::dbaccess::notifyDataSourceModified( m_xParent, sal_True );
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL OTableColumnDescriptor::getParent( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
return m_xParent;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OTableColumnDescriptor::setParent( const Reference< XInterface >& _xParent ) throw (NoSupportException, RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
@@ -148,7 +142,6 @@ void SAL_CALL OTableColumnDescriptor::setParent( const Reference< XInterface >&
//============================================================
DBG_NAME(OTableColumn);
-// -------------------------------------------------------------------------
OTableColumn::OTableColumn( const ::rtl::OUString& _rName )
:OTableColumnDescriptor( false /* do not act as descriptor */ )
{
@@ -156,28 +149,23 @@ OTableColumn::OTableColumn( const ::rtl::OUString& _rName )
m_sName = _rName;
}
-// -----------------------------------------------------------------------------
OTableColumn::~OTableColumn()
{
DBG_DTOR(OTableColumn,NULL);
}
-//--------------------------------------------------------------------------
IMPLEMENT_GET_IMPLEMENTATION_ID( OTableColumn )
-//------------------------------------------------------------------------------
rtl::OUString OTableColumn::getImplementationName( ) throw (RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OTableColumn");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OTableColumn"));
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& SAL_CALL OTableColumn::getInfoHelper()
{
return *OTableColumn_PBase::getArrayHelper();
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OTableColumn::createArrayHelper( ) const
{
return OTableColumnDescriptor::createArrayHelper();
@@ -188,7 +176,6 @@ rtl::OUString OTableColumn::getImplementationName( ) throw (RuntimeException)
// =========================================================================
DBG_NAME( OQueryColumn );
-// -------------------------------------------------------------------------
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)
@@ -230,7 +217,7 @@ OQueryColumn::OQueryColumn( const Reference< XPropertySet >& _rxParserColumn, co
{ PROPERTY_TABLENAME, PROPERTY_ID_TABLENAME },
{ PROPERTY_REALNAME, PROPERTY_ID_REALNAME }
};
- for ( size_t i=0; i < sizeof( aProps ) / sizeof( aProps[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aProps ); ++i )
{
if ( xPSI->hasPropertyByName( aProps[i].sName ) )
setFastPropertyValue_NoBroadcast( aProps[i].nHandle, _rxParserColumn->getPropertyValue( aProps[i].sName ) );
@@ -244,13 +231,11 @@ OQueryColumn::OQueryColumn( const Reference< XPropertySet >& _rxParserColumn, co
osl_decrementInterlockedCount( &m_refCount );
}
-//--------------------------------------------------------------------------
OQueryColumn::~OQueryColumn()
{
DBG_DTOR( OQueryColumn, NULL );
}
-//--------------------------------------------------------------------------
Reference< XPropertySet > OQueryColumn::impl_determineOriginalTableColumn( const Reference< XConnection >& _rxConnection )
{
OSL_PRECOND( _rxConnection.is(), "OQueryColumn::impl_determineOriginalTableColumn: illegal connection!" );
@@ -295,28 +280,23 @@ Reference< XPropertySet > OQueryColumn::impl_determineOriginalTableColumn( const
return xOriginalTableColumn;
}
-//--------------------------------------------------------------------------
IMPLEMENT_GET_IMPLEMENTATION_ID( OQueryColumn )
-//--------------------------------------------------------------------------
::rtl::OUString SAL_CALL OQueryColumn::getImplementationName( ) throw(RuntimeException)
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "org.openoffice.comp.dbaccess.OQueryColumn" ) );
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& SAL_CALL OQueryColumn::getInfoHelper()
{
return *OQueryColumn_PBase::getArrayHelper();
}
-//--------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OQueryColumn::createArrayHelper() const
{
return OTableColumnDescriptor::createArrayHelper();
}
-//--------------------------------------------------------------------------
void SAL_CALL OQueryColumn::getFastPropertyValue( Any& _rValue, sal_Int32 _nHandle ) const
{
OTableColumnDescriptor::getFastPropertyValue( _rValue, _nHandle );
@@ -353,7 +333,7 @@ void SAL_CALL OQueryColumn::getFastPropertyValue( Any& _rValue, sal_Int32 _nHand
//= OColumnWrapper
//==========================================================================
DBG_NAME(OColumnWrapper);
-//--------------------------------------------------------------------------
+
OColumnWrapper::OColumnWrapper( const Reference< XPropertySet > & rCol, const bool _bNameIsReadOnly )
:OColumn( _bNameIsReadOnly )
,m_xAggregate(rCol)
@@ -374,13 +354,12 @@ OColumnWrapper::OColumnWrapper( const Reference< XPropertySet > & rCol, const bo
m_xAggregate->getPropertyValue(PROPERTY_NAME) >>= m_sName;
}
}
-// -----------------------------------------------------------------------------
+
OColumnWrapper::~OColumnWrapper()
{
DBG_DTOR(OColumnWrapper,NULL);
}
-//------------------------------------------------------------------------------
::rtl::OUString OColumnWrapper::impl_getPropertyNameFromHandle( const sal_Int32 _nHandle ) const
{
::rtl::OUString sPropName;
@@ -390,7 +369,6 @@ OColumnWrapper::~OColumnWrapper()
return sPropName;
}
-//------------------------------------------------------------------------------
void OColumnWrapper::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
{
// derived classes are free to either use the OPropertyContainer(Helper) mechanisms for properties,
@@ -406,7 +384,6 @@ void OColumnWrapper::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) cons
}
}
-//------------------------------------------------------------------------------
sal_Bool OColumnWrapper::convertFastPropertyValue( Any & rConvertedValue, Any & rOldValue, sal_Int32 nHandle,
const Any& rValue ) throw (IllegalArgumentException)
{
@@ -427,7 +404,6 @@ sal_Bool OColumnWrapper::convertFastPropertyValue( Any & rConvertedValue, Any &
return bModified;
}
-//------------------------------------------------------------------------------
void OColumnWrapper::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any& rValue ) throw (Exception)
{
if ( OColumn::isRegisteredProperty( nHandle ) )
@@ -440,7 +416,6 @@ void OColumnWrapper::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const
}
}
-// -----------------------------------------------------------------------------
sal_Int64 SAL_CALL OColumnWrapper::getSomething( const Sequence< sal_Int8 >& aIdentifier ) throw(RuntimeException)
{
Reference< XUnoTunnel > xTunnel( m_xAggregate, UNO_QUERY);
@@ -452,7 +427,6 @@ sal_Int64 SAL_CALL OColumnWrapper::getSomething( const Sequence< sal_Int8 >& aId
//============================================================
//= OTableColumnDescriptorWrapper
//============================================================
-//--------------------------------------------------------------------------
OTableColumnDescriptorWrapper::OTableColumnDescriptorWrapper( const Reference< XPropertySet >& _rCol, const bool _bPureWrap, const bool _bIsDescriptor )
:OColumnWrapper( _rCol, !_bIsDescriptor )
,m_bPureWrap( _bPureWrap )
@@ -463,17 +437,14 @@ OTableColumnDescriptorWrapper::OTableColumnDescriptorWrapper( const Reference< X
}
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
IMPLEMENT_GET_IMPLEMENTATION_ID( OTableColumnDescriptorWrapper )
// ::com::sun::star::lang::XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OTableColumnDescriptorWrapper::getImplementationName( ) throw (RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OTableColumnDescriptorWrapper");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OTableColumnDescriptorWrapper"));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 2 );
@@ -483,7 +454,6 @@ Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNa
}
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OTableColumnDescriptorWrapper::createArrayHelper( sal_Int32 nId ) const
{
const sal_Int32 nHaveAlways = 7;
@@ -499,10 +469,7 @@ Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNa
if ( nId & HAS_AUTOINCREMENT_CREATION )
++nHaveOptionally;
- const sal_Int32 nPropertyCount( nHaveAlways + nHaveOptionally );
- Sequence< Property > aTableDescProperties( nPropertyCount );
- Property* pDesc = aTableDescProperties.getArray();
- sal_Int32 nPos = 0;
+ BEGIN_PROPERTY_SEQUENCE( nHaveAlways + nHaveOptionally )
DECL_PROP0_BOOL( ISAUTOINCREMENT );
DECL_PROP0_BOOL( ISCURRENCY );
@@ -529,12 +496,12 @@ Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNa
DECL_PROP0_BOOL( ISROWVERSION );
}
- OSL_ENSURE( nPos == nPropertyCount, "OTableColumnDescriptorWrapper::createArrayHelper: something went wrong!" );
+ END_PROPERTY_SEQUENCE()
if ( !m_bIsDescriptor )
{
- for ( Property* prop = aTableDescProperties.getArray();
- prop != aTableDescProperties.getArray() + aTableDescProperties.getLength();
+ for ( Property* prop = aDescriptor.getArray();
+ prop != aDescriptor.getArray() + aDescriptor.getLength();
++prop
)
{
@@ -546,18 +513,16 @@ Sequence< ::rtl::OUString > OTableColumnDescriptorWrapper::getSupportedServiceNa
Sequence< Property > aBaseProperties;
describeProperties( aBaseProperties );
- Sequence< Property > aAllProperties( ::comphelper::concatSequences( aTableDescProperties, aBaseProperties ) );
+ Sequence< Property > aAllProperties( ::comphelper::concatSequences( aDescriptor, aBaseProperties ) );
return new ::cppu::OPropertyArrayHelper( aAllProperties, sal_False );
}
// cppu::OPropertySetHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OTableColumnDescriptorWrapper::getInfoHelper()
{
return *static_cast< OIdPropertyArrayUsageHelper< OTableColumnDescriptorWrapper >* >(this)->getArrayHelper(m_nColTypeID);
}
-//------------------------------------------------------------------------------
void OTableColumnDescriptorWrapper::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
{
if ( m_bPureWrap )
@@ -570,7 +535,6 @@ void OTableColumnDescriptorWrapper::getFastPropertyValue( Any& rValue, sal_Int32
}
}
-//------------------------------------------------------------------------------
sal_Bool OTableColumnDescriptorWrapper::convertFastPropertyValue( Any & rConvertedValue, Any & rOldValue, sal_Int32 nHandle, const Any& rValue ) throw (IllegalArgumentException)
{
sal_Bool bModified(sal_False);
@@ -595,7 +559,6 @@ sal_Bool OTableColumnDescriptorWrapper::convertFastPropertyValue( Any & rConvert
return bModified;
}
-//------------------------------------------------------------------------------
void OTableColumnDescriptorWrapper::setFastPropertyValue_NoBroadcast(
sal_Int32 nHandle,
const Any& rValue
@@ -615,7 +578,6 @@ void OTableColumnDescriptorWrapper::setFastPropertyValue_NoBroadcast(
//============================================================
//= OTableColumnWrapper
//============================================================
-//--------------------------------------------------------------------------
OTableColumnWrapper::OTableColumnWrapper( const Reference< XPropertySet >& rCol, const Reference< XPropertySet >& _xColDefintion,
const bool _bPureWrap )
:OTableColumnDescriptorWrapper( rCol, _bPureWrap, false )
@@ -635,21 +597,17 @@ OTableColumnWrapper::OTableColumnWrapper( const Reference< XPropertySet >& rCol,
osl_decrementInterlockedCount( &m_refCount );
}
-//--------------------------------------------------------------------------
OTableColumnWrapper::~OTableColumnWrapper()
{
}
-//--------------------------------------------------------------------------
IMPLEMENT_GET_IMPLEMENTATION_ID( OTableColumnWrapper )
-//------------------------------------------------------------------------------
rtl::OUString OTableColumnWrapper::getImplementationName( ) throw (RuntimeException)
{
- return rtl::OUString::createFromAscii( "com.sun.star.sdb.OTableColumnWrapper" );
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OTableColumnWrapper" ));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OTableColumnWrapper::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 2 );
@@ -658,16 +616,14 @@ Sequence< ::rtl::OUString > OTableColumnWrapper::getSupportedServiceNames( ) th
return aSNS;
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OTableColumnWrapper::getInfoHelper()
{
return *static_cast< OIdPropertyArrayUsageHelper< OTableColumnWrapper >* >(this)->getArrayHelper(m_nColTypeID);
}
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OTableColumnWrapper::createArrayHelper( sal_Int32 nId ) const
{
return OTableColumnDescriptorWrapper::createArrayHelper( nId );
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/makefile.mk b/dbaccess/source/core/api/makefile.mk
deleted file mode 100644
index 9a4dc9d8ec52..000000000000
--- a/dbaccess/source/core/api/makefile.mk
+++ /dev/null
@@ -1,82 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=api
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/dba.pmk
-
-# --- Files -------------------------------------
-SLOFILES= \
- $(SLO)$/querydescriptor.obj \
- $(SLO)$/FilteredContainer.obj \
- $(SLO)$/TableDeco.obj \
- $(SLO)$/RowSetCacheIterator.obj \
- $(SLO)$/RowSet.obj \
- $(SLO)$/column.obj \
- $(SLO)$/RowSetBase.obj \
- $(SLO)$/CRowSetDataColumn.obj \
- $(SLO)$/CRowSetColumn.obj \
- $(SLO)$/querycomposer.obj \
- $(SLO)$/CIndexes.obj \
- $(SLO)$/BookmarkSet.obj \
- $(SLO)$/KeySet.obj \
- $(SLO)$/StaticSet.obj \
- $(SLO)$/CacheSet.obj \
- $(SLO)$/RowSetCache.obj \
- $(SLO)$/definitioncolumn.obj \
- $(SLO)$/resultcolumn.obj \
- $(SLO)$/datacolumn.obj \
- $(SLO)$/resultset.obj \
- $(SLO)$/statement.obj \
- $(SLO)$/preparedstatement.obj \
- $(SLO)$/callablestatement.obj \
- $(SLO)$/query.obj \
- $(SLO)$/querycontainer.obj \
- $(SLO)$/table.obj \
- $(SLO)$/viewcontainer.obj \
- $(SLO)$/tablecontainer.obj \
- $(SLO)$/SingleSelectQueryComposer.obj \
- $(SLO)$/HelperCollections.obj \
- $(SLO)$/datasettings.obj \
- $(SLO)$/View.obj \
- $(SLO)$/WrappedResultSet.obj \
- $(SLO)$/OptimisticSet.obj \
- $(SLO)$/PrivateRow.obj \
- $(SLO)$/columnsettings.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/core/api/preparedstatement.cxx b/dbaccess/source/core/api/preparedstatement.cxx
index 98c7c1c74b65..bca0ffa9b371 100644
--- a/dbaccess/source/core/api/preparedstatement.cxx
+++ b/dbaccess/source/core/api/preparedstatement.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -54,7 +55,6 @@ using namespace dbaccess;
DBG_NAME(OPreparedStatement)
-//--------------------------------------------------------------------------
OPreparedStatement::OPreparedStatement(const Reference< XConnection > & _xConn,
const Reference< XInterface > & _xStatement)
:OStatementBase(_xConn, _xStatement)
@@ -66,7 +66,6 @@ OPreparedStatement::OPreparedStatement(const Reference< XConnection > & _xConn,
m_pColumns = new OColumns(*this, m_aMutex, xMeta.is() && xMeta->supportsMixedCaseQuotedIdentifiers(),::std::vector< ::rtl::OUString>(), NULL,NULL);
}
-//--------------------------------------------------------------------------
OPreparedStatement::~OPreparedStatement()
{
m_pColumns->acquire();
@@ -77,7 +76,6 @@ OPreparedStatement::~OPreparedStatement()
}
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > OPreparedStatement::getTypes() throw (RuntimeException)
{
OTypeCollection aTypes(::getCppuType( (const Reference< XServiceInfo > *)0 ),
@@ -90,7 +88,6 @@ Sequence< Type > OPreparedStatement::getTypes() throw (RuntimeException)
return aTypes.getTypes();
}
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > OPreparedStatement::getImplementationId() throw (RuntimeException)
{
static OImplementationId * pId = 0;
@@ -107,7 +104,6 @@ Sequence< sal_Int8 > OPreparedStatement::getImplementationId() throw (RuntimeExc
}
// com::sun::star::uno::XInterface
-//--------------------------------------------------------------------------
Any OPreparedStatement::queryInterface( const Type & rType ) throw (RuntimeException)
{
Any aIface = OStatementBase::queryInterface( rType );
@@ -124,32 +120,27 @@ Any OPreparedStatement::queryInterface( const Type & rType ) throw (RuntimeExcep
return aIface;
}
-//--------------------------------------------------------------------------
void OPreparedStatement::acquire() throw ()
{
OStatementBase::acquire();
}
-//--------------------------------------------------------------------------
void OPreparedStatement::release() throw ()
{
OStatementBase::release();
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OPreparedStatement::getImplementationName( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OPreparedStatement");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.OPreparedStatement"));
}
-//------------------------------------------------------------------------------
sal_Bool OPreparedStatement::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OPreparedStatement::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 2 );
@@ -159,7 +150,6 @@ Sequence< ::rtl::OUString > OPreparedStatement::getSupportedServiceNames( ) thr
}
// OComponentHelper
-//------------------------------------------------------------------------------
void OPreparedStatement::disposing()
{
{
@@ -171,7 +161,6 @@ void OPreparedStatement::disposing()
}
// ::com::sun::star::sdbcx::XColumnsSupplier
-//------------------------------------------------------------------------------
Reference< ::com::sun::star::container::XNameAccess > OPreparedStatement::getColumns(void) throw( RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -206,7 +195,6 @@ Reference< ::com::sun::star::container::XNameAccess > OPreparedStatement::getCol
}
// XResultSetMetaDataSupplier
-//------------------------------------------------------------------------------
Reference< XResultSetMetaData > OPreparedStatement::getMetaData(void) throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -215,7 +203,6 @@ Reference< XResultSetMetaData > OPreparedStatement::getMetaData(void) throw( SQL
}
// XPreparedStatement
-//------------------------------------------------------------------------------
Reference< XResultSet > OPreparedStatement::executeQuery() throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -235,7 +222,6 @@ Reference< XResultSet > OPreparedStatement::executeQuery() throw( SQLException,
return xResultSet;
}
-//------------------------------------------------------------------------------
sal_Int32 OPreparedStatement::executeUpdate() throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -246,7 +232,6 @@ sal_Int32 OPreparedStatement::executeUpdate() throw( SQLException, RuntimeExcept
return Reference< XPreparedStatement >( m_xAggregateAsSet, UNO_QUERY_THROW )->executeUpdate();
}
-//------------------------------------------------------------------------------
sal_Bool OPreparedStatement::execute() throw( SQLException, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -257,14 +242,12 @@ sal_Bool OPreparedStatement::execute() throw( SQLException, RuntimeException )
return Reference< XPreparedStatement >( m_xAggregateAsSet, UNO_QUERY_THROW )->execute();
}
-//------------------------------------------------------------------------------
Reference< XConnection > OPreparedStatement::getConnection(void) throw( SQLException, RuntimeException )
{
return Reference< XConnection > (m_xParent, UNO_QUERY);
}
// XParameters
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setNull( sal_Int32 parameterIndex, sal_Int32 sqlType ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -273,7 +256,6 @@ void SAL_CALL OPreparedStatement::setNull( sal_Int32 parameterIndex, sal_Int32 s
m_xAggregateAsParameters->setNull(parameterIndex, sqlType);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setObjectNull( sal_Int32 parameterIndex, sal_Int32 sqlType, const ::rtl::OUString& typeName ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -282,7 +264,6 @@ void SAL_CALL OPreparedStatement::setObjectNull( sal_Int32 parameterIndex, sal_I
m_xAggregateAsParameters->setObjectNull(parameterIndex, sqlType, typeName);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setBoolean( sal_Int32 parameterIndex, sal_Bool x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -291,7 +272,6 @@ void SAL_CALL OPreparedStatement::setBoolean( sal_Int32 parameterIndex, sal_Bool
m_xAggregateAsParameters->setBoolean(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setByte( sal_Int32 parameterIndex, sal_Int8 x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -300,7 +280,6 @@ void SAL_CALL OPreparedStatement::setByte( sal_Int32 parameterIndex, sal_Int8 x
m_xAggregateAsParameters->setByte(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setShort( sal_Int32 parameterIndex, sal_Int16 x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -309,7 +288,6 @@ void SAL_CALL OPreparedStatement::setShort( sal_Int32 parameterIndex, sal_Int16
m_xAggregateAsParameters->setShort(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setInt( sal_Int32 parameterIndex, sal_Int32 x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -318,7 +296,6 @@ void SAL_CALL OPreparedStatement::setInt( sal_Int32 parameterIndex, sal_Int32 x
m_xAggregateAsParameters->setInt(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setLong( sal_Int32 parameterIndex, sal_Int64 x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -327,7 +304,6 @@ void SAL_CALL OPreparedStatement::setLong( sal_Int32 parameterIndex, sal_Int64 x
m_xAggregateAsParameters->setLong(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setFloat( sal_Int32 parameterIndex, float x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -336,7 +312,6 @@ void SAL_CALL OPreparedStatement::setFloat( sal_Int32 parameterIndex, float x )
m_xAggregateAsParameters->setFloat(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setDouble( sal_Int32 parameterIndex, double x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -345,7 +320,6 @@ void SAL_CALL OPreparedStatement::setDouble( sal_Int32 parameterIndex, double x
m_xAggregateAsParameters->setDouble(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setString( sal_Int32 parameterIndex, const ::rtl::OUString& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -354,7 +328,6 @@ void SAL_CALL OPreparedStatement::setString( sal_Int32 parameterIndex, const ::r
m_xAggregateAsParameters->setString(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setBytes( sal_Int32 parameterIndex, const Sequence< sal_Int8 >& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -363,7 +336,6 @@ void SAL_CALL OPreparedStatement::setBytes( sal_Int32 parameterIndex, const Sequ
m_xAggregateAsParameters->setBytes(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setDate( sal_Int32 parameterIndex, const ::com::sun::star::util::Date& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -372,7 +344,6 @@ void SAL_CALL OPreparedStatement::setDate( sal_Int32 parameterIndex, const ::com
m_xAggregateAsParameters->setDate(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setTime( sal_Int32 parameterIndex, const ::com::sun::star::util::Time& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -381,7 +352,6 @@ void SAL_CALL OPreparedStatement::setTime( sal_Int32 parameterIndex, const ::com
m_xAggregateAsParameters->setTime(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setTimestamp( sal_Int32 parameterIndex, const ::com::sun::star::util::DateTime& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -390,7 +360,6 @@ void SAL_CALL OPreparedStatement::setTimestamp( sal_Int32 parameterIndex, const
m_xAggregateAsParameters->setTimestamp(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setBinaryStream( sal_Int32 parameterIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -399,7 +368,6 @@ void SAL_CALL OPreparedStatement::setBinaryStream( sal_Int32 parameterIndex, con
m_xAggregateAsParameters->setBinaryStream(parameterIndex, x, length);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setCharacterStream( sal_Int32 parameterIndex, const Reference< ::com::sun::star::io::XInputStream >& x, sal_Int32 length ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -408,7 +376,6 @@ void SAL_CALL OPreparedStatement::setCharacterStream( sal_Int32 parameterIndex,
m_xAggregateAsParameters->setCharacterStream(parameterIndex, x, length);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setObject( sal_Int32 parameterIndex, const Any& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -417,7 +384,6 @@ void SAL_CALL OPreparedStatement::setObject( sal_Int32 parameterIndex, const Any
m_xAggregateAsParameters->setObject(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setObjectWithInfo( sal_Int32 parameterIndex, const Any& x, sal_Int32 targetSqlType, sal_Int32 scale ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -426,7 +392,6 @@ void SAL_CALL OPreparedStatement::setObjectWithInfo( sal_Int32 parameterIndex, c
m_xAggregateAsParameters->setObjectWithInfo(parameterIndex, x, targetSqlType, scale);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setRef( sal_Int32 parameterIndex, const Reference< XRef >& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -435,7 +400,6 @@ void SAL_CALL OPreparedStatement::setRef( sal_Int32 parameterIndex, const Refere
m_xAggregateAsParameters->setRef(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setBlob( sal_Int32 parameterIndex, const Reference< XBlob >& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -444,7 +408,6 @@ void SAL_CALL OPreparedStatement::setBlob( sal_Int32 parameterIndex, const Refer
m_xAggregateAsParameters->setBlob(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setClob( sal_Int32 parameterIndex, const Reference< XClob >& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -453,7 +416,6 @@ void SAL_CALL OPreparedStatement::setClob( sal_Int32 parameterIndex, const Refer
m_xAggregateAsParameters->setClob(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::setArray( sal_Int32 parameterIndex, const Reference< XArray >& x ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -462,7 +424,6 @@ void SAL_CALL OPreparedStatement::setArray( sal_Int32 parameterIndex, const Refe
m_xAggregateAsParameters->setArray(parameterIndex, x);
}
-//------------------------------------------------------------------------------
void SAL_CALL OPreparedStatement::clearParameters( ) throw(SQLException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -470,4 +431,4 @@ void SAL_CALL OPreparedStatement::clearParameters( ) throw(SQLException, Runtim
m_xAggregateAsParameters->clearParameters();
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/query.cxx b/dbaccess/source/core/api/query.cxx
index 2d1c12ad3f25..ac2201841fbe 100644
--- a/dbaccess/source/core/api/query.cxx
+++ b/dbaccess/source/core/api/query.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,83 +29,38 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREAPI_QUERY_HXX_
#include "query.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef DBTOOLS_WARNINGSCONTAINER_HXX
#include <connectivity/warningscontainer.hxx>
-#endif
-#ifndef DBA_HELPERCOLLECTIONS_HXX
#include "HelperCollections.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HXX_
#include "core_resource.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HRC_
#include "core_resource.hrc"
-#endif
-#ifndef _CPPUHELPER_QUERYINTERFACE_HXX_
#include <cppuhelper/queryinterface.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _COMPHELPER_PROPERTY_AGGREGATION_HXX_
+#include <osl/diagnose.h>
#include <comphelper/propagg.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef UNOTOOLS_INC_SHAREDUNOCOMPONENT_HXX
#include <unotools/sharedunocomponent.hxx>
-#endif
-#ifndef _DBACORE_DEFINITIONCOLUMN_HXX_
#include "definitioncolumn.hxx"
-#endif
#include <functional>
-#ifndef DBACORE_SDBCORETOOLS_HXX
#include "sdbcoretools.hxx"
-#endif
-#ifndef DBACCESS_CORE_API_QUERYCOMPOSER_HXX
#include "querycomposer.hxx"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef DBA_CONTAINERMEDIATOR_HXX
#include "ContainerMediator.hxx"
-#endif
using namespace dbaccess;
using namespace ::com::sun::star::uno;
@@ -120,16 +76,14 @@ using namespace ::osl;
using namespace ::cppu;
using namespace ::utl;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OQuery
//==========================================================================
DBG_NAME(OQuery)
-//--------------------------------------------------------------------------
+
OQuery::OQuery( const Reference< XPropertySet >& _rxCommandDefinition
,const Reference< XConnection >& _rxConn
,const Reference< XMultiServiceFactory >& _xORB)
@@ -148,7 +102,7 @@ OQuery::OQuery( const Reference< XPropertySet >& _rxCommandDefinition
ODataSettings::registerPropertiesFor(this);
osl_incrementInterlockedCount(&m_refCount);
- DBG_ASSERT(m_xCommandDefinition.is(), "OQuery::OQuery : invalid CommandDefinition object !");
+ OSL_ENSURE(m_xCommandDefinition.is(), "OQuery::OQuery : invalid CommandDefinition object !");
if ( m_xCommandDefinition.is() )
{
try
@@ -157,27 +111,26 @@ OQuery::OQuery( const Reference< XPropertySet >& _rxCommandDefinition
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "OQueryDescriptor_Base::OQueryDescriptor_Base: caught an exception!");
+ OSL_FAIL("OQueryDescriptor_Base::OQueryDescriptor_Base: caught an exception!");
}
m_xCommandDefinition->addPropertyChangeListener(::rtl::OUString(), this);
// m_xCommandDefinition->addPropertyChangeListener(PROPERTY_NAME, this);
m_xCommandPropInfo = m_xCommandDefinition->getPropertySetInfo();
}
- DBG_ASSERT(m_xConnection.is(), "OQuery::OQuery : invalid connection !");
+ OSL_ENSURE(m_xConnection.is(), "OQuery::OQuery : invalid connection !");
osl_decrementInterlockedCount(&m_refCount);
}
-//--------------------------------------------------------------------------
OQuery::~OQuery()
{
DBG_DTOR(OQuery, NULL);
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_IMPLEMENTATION_ID(OQuery);
IMPLEMENT_GETTYPES3(OQuery,OQueryDescriptor_Base,ODataSettings,OContentHelper);
IMPLEMENT_FORWARD_XINTERFACE3( OQuery,OContentHelper,OQueryDescriptor_Base,ODataSettings)
-//--------------------------------------------------------------------------
+
void OQuery::rebuildColumns()
{
OSL_PRECOND( getColumnCount() == 0, "OQuery::rebuildColumns: column container should be empty!" );
@@ -225,7 +178,7 @@ void OQuery::rebuildColumns()
}
Reference< XDatabaseMetaData > xDBMeta( m_xConnection->getMetaData(), UNO_QUERY_THROW );
- ::vos::ORef< OSQLColumns > aParseColumns(
+ ::rtl::Reference< OSQLColumns > aParseColumns(
::connectivity::parse::OParseColumn::createColumnsForResultSet( xResultSetMeta, xDBMeta,xColumnDefinitions ) );
xColumns = OPrivateColumns::createWithIntrinsicNames(
aParseColumns, xDBMeta->supportsMixedCaseQuotedIdentifiers(), *this, m_aMutex );
@@ -277,18 +230,16 @@ void OQuery::rebuildColumns()
}
// XServiceInfo
-//--------------------------------------------------------------------------
IMPLEMENT_SERVICE_INFO3(OQuery, "com.sun.star.sdb.dbaccess.OQuery", SERVICE_SDB_DATASETTINGS, SERVICE_SDB_QUERY, SERVICE_SDB_QUERYDEFINITION)
// ::com::sun::star::beans::XPropertyChangeListener
-//--------------------------------------------------------------------------
void SAL_CALL OQuery::propertyChange( const PropertyChangeEvent& _rSource ) throw(RuntimeException)
{
sal_Int32 nOwnHandle = -1;
{
MutexGuard aGuard(m_aMutex);
- DBG_ASSERT(_rSource.Source.get() == Reference< XInterface >(m_xCommandDefinition, UNO_QUERY).get(),
+ OSL_ENSURE(_rSource.Source.get() == Reference< XInterface >(m_xCommandDefinition, UNO_QUERY).get(),
"OQuery::propertyChange : where did this call come from ?");
if (m_eDoingCurrently == SETTING_PROPERTIES)
@@ -307,20 +258,19 @@ void SAL_CALL OQuery::propertyChange( const PropertyChangeEvent& _rSource ) thro
}
else
{
- DBG_ERROR("OQuery::propertyChange : my CommandDefinition has more properties than I do !");
+ OSL_FAIL("OQuery::propertyChange : my CommandDefinition has more properties than I do !");
}
}
fire(&nOwnHandle, &_rSource.NewValue, &_rSource.OldValue, 1, sal_False);
}
-//--------------------------------------------------------------------------
void SAL_CALL OQuery::disposing( const EventObject& _rSource ) throw (RuntimeException)
{
MutexGuard aGuard(m_aMutex);
(void)_rSource;
- DBG_ASSERT(_rSource.Source.get() == Reference< XInterface >(m_xCommandDefinition, UNO_QUERY).get(),
+ OSL_ENSURE(_rSource.Source.get() == Reference< XInterface >(m_xCommandDefinition, UNO_QUERY).get(),
"OQuery::disposing : where did this call come from ?");
m_xCommandDefinition->removePropertyChangeListener(::rtl::OUString(), this);
@@ -328,14 +278,12 @@ void SAL_CALL OQuery::disposing( const EventObject& _rSource ) throw (RuntimeExc
}
// XDataDescriptorFactory
-//--------------------------------------------------------------------------
Reference< XPropertySet > SAL_CALL OQuery::createDataDescriptor( ) throw(RuntimeException)
{
return new OQueryDescriptor(*this);
}
// pseudo-XComponent
-//--------------------------------------------------------------------------
void SAL_CALL OQuery::disposing()
{
MutexGuard aGuard(m_aMutex);
@@ -349,7 +297,6 @@ void SAL_CALL OQuery::disposing()
m_pWarnings = NULL;
}
-//--------------------------------------------------------------------------
void OQuery::setFastPropertyValue_NoBroadcast( sal_Int32 _nHandle, const Any& _rValue ) throw (Exception)
{
ODataSettings::setFastPropertyValue_NoBroadcast(_nHandle, _rValue);
@@ -361,29 +308,25 @@ void OQuery::setFastPropertyValue_NoBroadcast( sal_Int32 _nHandle, const Any& _r
{ // the base class holds the property values itself, but we have to forward this to our CommandDefinition
m_eDoingCurrently = SETTING_PROPERTIES;
- OAutoActionReset aActionResetter(this);
+ OAutoActionReset aAutoReset(this);
m_xCommandDefinition->setPropertyValue(sAggPropName, _rValue);
if ( PROPERTY_ID_COMMAND == _nHandle )
// the columns are out of date if we are based on a new statement ....
- // 90573 - 16.08.2001 - frank.schoenheit@sun.com
setColumnsOutOfDate();
}
}
-//--------------------------------------------------------------------------
Reference< XPropertySetInfo > SAL_CALL OQuery::getPropertySetInfo( ) throw(RuntimeException)
{
return createPropertySetInfo( getInfoHelper() ) ;
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OQuery::getInfoHelper()
{
return *getArrayHelper();
}
-//--------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OQuery::createArrayHelper( ) const
{
Sequence< Property > aProps;
@@ -391,12 +334,12 @@ Reference< XPropertySetInfo > SAL_CALL OQuery::getPropertySetInfo( ) throw(Runt
describeProperties(aProps);
return new ::cppu::OPropertyArrayHelper(aProps);
}
-// -----------------------------------------------------------------------------
+
OColumn* OQuery::createColumn(const ::rtl::OUString& /*_rName*/) const
{
return NULL;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OQuery::rename( const ::rtl::OUString& newName ) throw (SQLException, ElementExistException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -405,7 +348,7 @@ void SAL_CALL OQuery::rename( const ::rtl::OUString& newName ) throw (SQLExcepti
if(xRename.is())
xRename->rename(newName);
}
-// -----------------------------------------------------------------------------
+
void OQuery::registerProperties()
{
// the properties which OCommandBase supplies (it has no own registration, as it's not derived from
@@ -432,14 +375,10 @@ void OQuery::registerProperties()
&m_aLayoutInformation, ::getCppuType(&m_aLayoutInformation));
}
-// -----------------------------------------------------------------------------
::rtl::OUString OQuery::determineContentType() const
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "application/vnd.org.openoffice.DatabaseQuery" ) );
}
-// -----------------------------------------------------------------------------
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/query.hxx b/dbaccess/source/core/api/query.hxx
index 81e3a38c7862..c3fff9cc3cdd 100644
--- a/dbaccess/source/core/api/query.hxx
+++ b/dbaccess/source/core/api/query.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,27 +29,13 @@
#ifndef _DBA_COREAPI_QUERY_HXX_
#define _DBA_COREAPI_QUERY_HXX_
-#ifndef _DBA_COREAPI_QUERYDESCRIPTOR_HXX_
#include "querydescriptor.hxx"
-#endif
-#ifndef _CPPUHELPER_IMPLBASE3_HXX_
#include <cppuhelper/implbase3.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYCHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertyChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XRENAME_HPP_
#include <com/sun/star/sdbcx/XRename.hpp>
-#endif
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
#include <map>
@@ -184,3 +171,4 @@ private:
#endif // _DBA_COREAPI_QUERY_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/querycomposer.cxx b/dbaccess/source/core/api/querycomposer.cxx
index ea0a3617e9ba..9bf2e34006fb 100644
--- a/dbaccess/source/core/api/querycomposer.cxx
+++ b/dbaccess/source/core/api/querycomposer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,76 +29,30 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNSEARCH_HPP_
#include <com/sun/star/sdbc/ColumnSearch.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATA_HPP_
#include <com/sun/star/sdbc/XResultSetMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_SERVICENOTREGISTEREDEXCEPTION_HPP_
#include <com/sun/star/lang/ServiceNotRegisteredException.hpp>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UNO_XAGGREGATION_HPP_
#include <com/sun/star/uno/XAggregation.hpp>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_PROCESSFACTORY_HXX_
#include <comphelper/processfactory.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _UTL_CONFIGMGR_HXX_
#include <unotools/configmgr.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COM_SUN_STAR_I18N_XLOCALEDATA_HPP_
#include <com/sun/star/i18n/XLocaleData.hpp>
-#endif
-#ifndef INCLUDED_SVTOOLS_SYSLOCALE_HXX
#include <unotools/syslocale.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
#include <com/sun/star/sdb/SQLFilterOperator.hpp>
-#ifndef DBACCESS_CORE_API_QUERYCOMPOSER_HXX
#include "querycomposer.hxx"
-#endif
-#ifndef DBA_HELPERCOLLECTIONS_HXX
#include "HelperCollections.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_CORE_INC_COMPOSERTOOLS_HXX
#include "composertools.hxx"
-#endif
#include <algorithm>
#include <rtl/logfile.hxx>
@@ -120,7 +75,7 @@ using namespace ::utl;
DBG_NAME(OQueryComposer)
-// -------------------------------------------------------------------------
+
OQueryComposer::OQueryComposer(const Reference< XConnection>& _xConnection)
: OSubComponent(m_aMutex,_xConnection)
{
@@ -132,26 +87,26 @@ OQueryComposer::OQueryComposer(const Reference< XConnection>& _xConnection)
m_xComposer.set( xFac->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ), UNO_QUERY_THROW );
m_xComposerHelper.set( xFac->createInstance( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER ), UNO_QUERY_THROW );
}
-// -------------------------------------------------------------------------
+
OQueryComposer::~OQueryComposer()
{
DBG_DTOR(OQueryComposer,NULL);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::disposing" );
::comphelper::disposeComponent(m_xComposerHelper);
::comphelper::disposeComponent(m_xComposer);
}
-// -------------------------------------------------------------------------
+
// ::com::sun::star::lang::XTypeProvider
Sequence< Type > SAL_CALL OQueryComposer::getTypes() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getTypes" );
return ::comphelper::concatSequences(OSubComponent::getTypes(),OQueryComposer_BASE::getTypes());
}
-// -------------------------------------------------------------------------
+
Sequence< sal_Int8 > SAL_CALL OQueryComposer::getImplementationId() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getImplementationId" );
@@ -167,7 +122,7 @@ Sequence< sal_Int8 > SAL_CALL OQueryComposer::getImplementationId() throw (Runti
}
return pId->getImplementationId();
}
-// -------------------------------------------------------------------------
+
// com::sun::star::lang::XUnoTunnel
sal_Int64 SAL_CALL OQueryComposer::getSomething( const Sequence< sal_Int8 >& rId ) throw(RuntimeException)
{
@@ -177,7 +132,7 @@ sal_Int64 SAL_CALL OQueryComposer::getSomething( const Sequence< sal_Int8 >& rId
return 0;
}
-// -------------------------------------------------------------------------
+
Any SAL_CALL OQueryComposer::queryInterface( const Type & rType ) throw(RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::queryInterface" );
@@ -186,21 +141,20 @@ Any SAL_CALL OQueryComposer::queryInterface( const Type & rType ) throw(RuntimeE
aRet = OQueryComposer_BASE::queryInterface(rType);
return aRet;
}
-// -------------------------------------------------------------------------
+
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OQueryComposer::getImplementationName( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getImplementationName" );
return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.dbaccess.OQueryComposer"));
}
-//------------------------------------------------------------------------------
+
sal_Bool OQueryComposer::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::supportsService" );
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > OQueryComposer::getSupportedServiceNames( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getSupportedServiceNames" );
@@ -208,7 +162,7 @@ Sequence< ::rtl::OUString > OQueryComposer::getSupportedServiceNames( ) throw (
aSNS[0] = SERVICE_SDB_SQLQUERYCOMPOSER;
return aSNS;
}
-// -------------------------------------------------------------------------
+
// XSQLQueryComposer
::rtl::OUString SAL_CALL OQueryComposer::getQuery( ) throw(RuntimeException)
{
@@ -222,7 +176,7 @@ Sequence< ::rtl::OUString > OQueryComposer::getSupportedServiceNames( ) throw (
xProp->getPropertyValue(PROPERTY_ORIGINAL) >>= sQuery;
return sQuery;
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::setQuery( const ::rtl::OUString& command ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::setQuery" );
@@ -234,7 +188,7 @@ void SAL_CALL OQueryComposer::setQuery( const ::rtl::OUString& command ) throw(S
m_sOrgFilter = m_xComposer->getFilter();
m_sOrgOrder = m_xComposer->getOrder();
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OQueryComposer::getComposedQuery( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getComposedQuery" );
@@ -244,7 +198,7 @@ void SAL_CALL OQueryComposer::setQuery( const ::rtl::OUString& command ) throw(S
return m_xComposer->getQuery();
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OQueryComposer::getFilter( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getFilter" );
@@ -254,7 +208,7 @@ void SAL_CALL OQueryComposer::setQuery( const ::rtl::OUString& command ) throw(S
aFilterCreator = ::std::for_each(m_aFilters.begin(),m_aFilters.end(),aFilterCreator);
return aFilterCreator.getComposedAndClear();
}
-// -------------------------------------------------------------------------
+
Sequence< Sequence< PropertyValue > > SAL_CALL OQueryComposer::getStructuredFilter( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getStructuredFilter" );
@@ -263,7 +217,7 @@ Sequence< Sequence< PropertyValue > > SAL_CALL OQueryComposer::getStructuredFilt
MutexGuard aGuard(m_aMutex);
return m_xComposer->getStructuredFilter();
}
-// -------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OQueryComposer::getOrder( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getOrder" );
@@ -274,7 +228,7 @@ Sequence< Sequence< PropertyValue > > SAL_CALL OQueryComposer::getStructuredFilt
aOrderCreator = ::std::for_each(m_aOrders.begin(),m_aOrders.end(),aOrderCreator);
return aOrderCreator.getComposedAndClear();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::appendFilterByColumn( const Reference< XPropertySet >& column ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::appendFilterByColumn" );
@@ -307,7 +261,7 @@ void SAL_CALL OQueryComposer::appendFilterByColumn( const Reference< XPropertySe
setFilter( aFilterCreator.getComposedAndClear() );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::appendOrderByColumn( const Reference< XPropertySet >& column, sal_Bool ascending ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::appendOrderByColumn" );
@@ -324,7 +278,7 @@ void SAL_CALL OQueryComposer::appendOrderByColumn( const Reference< XPropertySet
setOrder(aOrderCreator.getComposedAndClear());
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::setFilter( const ::rtl::OUString& filter ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::setFilter" );
@@ -341,7 +295,7 @@ void SAL_CALL OQueryComposer::setFilter( const ::rtl::OUString& filter ) throw(S
m_xComposer->setFilter( aFilterCreator.getComposedAndClear() );
}
-// -------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::setOrder( const ::rtl::OUString& order ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::setOrder" );
@@ -359,7 +313,7 @@ void SAL_CALL OQueryComposer::setOrder( const ::rtl::OUString& order ) throw(SQL
m_xComposer->setOrder(aOrderCreator.getComposedAndClear());
}
-// -------------------------------------------------------------------------
+
// XTablesSupplier
Reference< XNameAccess > SAL_CALL OQueryComposer::getTables( ) throw(RuntimeException)
{
@@ -369,7 +323,7 @@ Reference< XNameAccess > SAL_CALL OQueryComposer::getTables( ) throw(RuntimeExc
::osl::MutexGuard aGuard( m_aMutex );
return Reference<XTablesSupplier>(m_xComposer,UNO_QUERY)->getTables();
}
-// -------------------------------------------------------------------------
+
// XColumnsSupplier
Reference< XNameAccess > SAL_CALL OQueryComposer::getColumns( ) throw(RuntimeException)
{
@@ -379,7 +333,7 @@ Reference< XNameAccess > SAL_CALL OQueryComposer::getColumns( ) throw(RuntimeEx
::osl::MutexGuard aGuard( m_aMutex );
return Reference<XColumnsSupplier>(m_xComposer,UNO_QUERY)->getColumns();
}
-// -------------------------------------------------------------------------
+
Reference< XIndexAccess > SAL_CALL OQueryComposer::getParameters( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OQueryComposer::getParameters" );
@@ -388,19 +342,14 @@ Reference< XIndexAccess > SAL_CALL OQueryComposer::getParameters( ) throw(Runti
::osl::MutexGuard aGuard( m_aMutex );
return Reference<XParametersSupplier>(m_xComposer,UNO_QUERY)->getParameters();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::acquire() throw()
{
OSubComponent::acquire();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OQueryComposer::release() throw()
{
OSubComponent::release();
}
-// -----------------------------------------------------------------------------
-
-
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/querycontainer.cxx b/dbaccess/source/core/api/querycontainer.cxx
index 043912259aff..6aac55d0bbf1 100644
--- a/dbaccess/source/core/api/querycontainer.cxx
+++ b/dbaccess/source/core/api/querycontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,65 +29,30 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_CORE_QUERYCONTAINER_HXX_
#include "querycontainer.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBA_COREAPI_QUERY_HXX_
#include "query.hxx"
-#endif
-#ifndef DBACCESS_OBJECTNAMEAPPROVAL_HXX
#include "objectnameapproval.hxx"
-#endif
-#ifndef DBA_CONTAINERLISTENER_HXX
#include "ContainerListener.hxx"
-#endif
-#ifndef DBACCESS_VETO_HXX
#include "veto.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERAPPROVEBROADCASTER_HPP_
#include <com/sun/star/container/XContainerApproveBroadcaster.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COMPHELPER_ENUMHELPER_HXX_
+#include <osl/diagnose.h>
#include <comphelper/enumhelper.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
using namespace dbtools;
using namespace ::com::sun::star::uno;
@@ -102,16 +68,14 @@ using namespace ::osl;
using namespace ::comphelper;
using namespace ::cppu;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OQueryContainer
//==========================================================================
DBG_NAME(OQueryContainer)
-//------------------------------------------------------------------------------
+
OQueryContainer::OQueryContainer(
const Reference< XNameContainer >& _rxCommandDefinitions
, const Reference< XConnection >& _rxConn
@@ -151,20 +115,17 @@ OQueryContainer::OQueryContainer(
setElementApproval( PContainerApprove( new ObjectNameApproval( _rxConn, ObjectNameApproval::TypeQuery ) ) );
}
-//------------------------------------------------------------------------------
OQueryContainer::~OQueryContainer()
{
DBG_DTOR(OQueryContainer, NULL);
// dispose();
// maybe we're already disposed, but this should be uncritical
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_FORWARD_XINTERFACE2( OQueryContainer,ODefinitionContainer,OQueryContainer_Base)
-//------------------------------------------------------------------------------
IMPLEMENT_FORWARD_XTYPEPROVIDER2( OQueryContainer,ODefinitionContainer,OQueryContainer_Base)
-//------------------------------------------------------------------------------
void OQueryContainer::disposing()
{
ODefinitionContainer::disposing();
@@ -190,18 +151,15 @@ void OQueryContainer::disposing()
}
// XServiceInfo
-//------------------------------------------------------------------------------
IMPLEMENT_SERVICE_INFO2(OQueryContainer, "com.sun.star.sdb.dbaccess.OQueryContainer", SERVICE_SDBCX_CONTAINER, SERVICE_SDB_QUERIES)
// XDataDescriptorFactory
-//--------------------------------------------------------------------------
Reference< XPropertySet > SAL_CALL OQueryContainer::createDataDescriptor( ) throw(RuntimeException)
{
return new OQueryDescriptor();
}
// XAppend
-//------------------------------------------------------------------------------
void SAL_CALL OQueryContainer::appendByDescriptor( const Reference< XPropertySet >& _rxDesc ) throw(SQLException, ElementExistException, RuntimeException)
{
ResettableMutexGuard aGuard(m_aMutex);
@@ -242,7 +200,6 @@ void SAL_CALL OQueryContainer::appendByDescriptor( const Reference< XPropertySet
}
// XDrop
-//------------------------------------------------------------------------------
void SAL_CALL OQueryContainer::dropByName( const ::rtl::OUString& _rName ) throw(SQLException, NoSuchElementException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -257,7 +214,6 @@ void SAL_CALL OQueryContainer::dropByName( const ::rtl::OUString& _rName ) throw
m_xCommandDefinitions->removeByName(_rName);
}
-//------------------------------------------------------------------------------
void SAL_CALL OQueryContainer::dropByIndex( sal_Int32 _nIndex ) throw(SQLException, IndexOutOfBoundsException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -274,7 +230,7 @@ void SAL_CALL OQueryContainer::dropByIndex( sal_Int32 _nIndex ) throw(SQLExcepti
dropByName(sName);
}
-//------------------------------------------------------------------------------
+
void SAL_CALL OQueryContainer::elementInserted( const ::com::sun::star::container::ContainerEvent& _rEvent ) throw(::com::sun::star::uno::RuntimeException)
{
Reference< XContent > xNewElement;
@@ -286,8 +242,8 @@ void SAL_CALL OQueryContainer::elementInserted( const ::com::sun::star::containe
// nothing to do, we're inserting via an "appendByDescriptor"
return;
- DBG_ASSERT(sElementName.getLength(), "OQueryContainer::elementInserted : invalid name !");
- DBG_ASSERT(m_aDocumentMap.find(sElementName) == m_aDocumentMap.end(), "OQueryContainer::elementInserted : oops .... we're inconsistent with our master container !");
+ OSL_ENSURE(sElementName.getLength(), "OQueryContainer::elementInserted : invalid name !");
+ OSL_ENSURE(m_aDocumentMap.find(sElementName) == m_aDocumentMap.end(), "OQueryContainer::elementInserted : oops .... we're inconsistent with our master container !");
if (!sElementName.getLength() || hasByName(sElementName))
return;
@@ -297,21 +253,19 @@ void SAL_CALL OQueryContainer::elementInserted( const ::com::sun::star::containe
insertByName(sElementName,makeAny(xNewElement));
}
-//------------------------------------------------------------------------------
void SAL_CALL OQueryContainer::elementRemoved( const ::com::sun::star::container::ContainerEvent& _rEvent ) throw(::com::sun::star::uno::RuntimeException)
{
::rtl::OUString sAccessor;
_rEvent.Accessor >>= sAccessor;
{
- DBG_ASSERT(sAccessor.getLength(), "OQueryContainer::elementRemoved : invalid name !");
- DBG_ASSERT(m_aDocumentMap.find(sAccessor) != m_aDocumentMap.end(), "OQueryContainer::elementRemoved : oops .... we're inconsistent with our master container !");
+ OSL_ENSURE(sAccessor.getLength(), "OQueryContainer::elementRemoved : invalid name !");
+ OSL_ENSURE(m_aDocumentMap.find(sAccessor) != m_aDocumentMap.end(), "OQueryContainer::elementRemoved : oops .... we're inconsistent with our master container !");
if ( !sAccessor.getLength() || !hasByName(sAccessor) )
return;
}
removeByName(sAccessor);
}
-//------------------------------------------------------------------------------
void SAL_CALL OQueryContainer::elementReplaced( const ::com::sun::star::container::ContainerEvent& _rEvent ) throw(::com::sun::star::uno::RuntimeException)
{
Reference< XPropertySet > xReplacedElement;
@@ -321,8 +275,8 @@ void SAL_CALL OQueryContainer::elementReplaced( const ::com::sun::star::containe
{
MutexGuard aGuard(m_aMutex);
- DBG_ASSERT(sAccessor.getLength(), "OQueryContainer::elementReplaced : invalid name !");
- DBG_ASSERT(m_aDocumentMap.find(sAccessor) != m_aDocumentMap.end(), "OQueryContainer::elementReplaced : oops .... we're inconsistent with our master container !");
+ OSL_ENSURE(sAccessor.getLength(), "OQueryContainer::elementReplaced : invalid name !");
+ OSL_ENSURE(m_aDocumentMap.find(sAccessor) != m_aDocumentMap.end(), "OQueryContainer::elementReplaced : oops .... we're inconsistent with our master container !");
if (!sAccessor.getLength() || !hasByName(sAccessor))
return;
@@ -332,7 +286,6 @@ void SAL_CALL OQueryContainer::elementReplaced( const ::com::sun::star::containe
replaceByName(sAccessor,makeAny(xNewElement));
}
-//------------------------------------------------------------------------------
Reference< XVeto > SAL_CALL OQueryContainer::approveInsertElement( const ContainerEvent& Event ) throw (WrappedTargetException, RuntimeException)
{
::rtl::OUString sName;
@@ -351,24 +304,21 @@ Reference< XVeto > SAL_CALL OQueryContainer::approveInsertElement( const Contain
return xReturn;
}
-//------------------------------------------------------------------------------
Reference< XVeto > SAL_CALL OQueryContainer::approveReplaceElement( const ContainerEvent& /*Event*/ ) throw (WrappedTargetException, RuntimeException)
{
return NULL;
}
-//------------------------------------------------------------------------------
Reference< XVeto > SAL_CALL OQueryContainer::approveRemoveElement( const ContainerEvent& /*Event*/ ) throw (WrappedTargetException, RuntimeException)
{
return NULL;
}
-//------------------------------------------------------------------------------
void SAL_CALL OQueryContainer::disposing( const ::com::sun::star::lang::EventObject& _rSource ) throw(::com::sun::star::uno::RuntimeException)
{
if (_rSource.Source.get() == Reference< XInterface >(m_xCommandDefinitions, UNO_QUERY).get())
- { // our "master container" (with the command definitions) is beeing disposed
- DBG_ERROR("OQueryContainer::disposing : nobody should dispose the CommandDefinition container before disposing my connection !");
+ { // our "master container" (with the command definitions) is being disposed
+ OSL_FAIL("OQueryContainer::disposing : nobody should dispose the CommandDefinition container before disposing my connection !");
dispose();
}
else
@@ -389,20 +339,17 @@ void SAL_CALL OQueryContainer::disposing( const ::com::sun::star::lang::EventObj
}
}
-// -----------------------------------------------------------------------------
::rtl::OUString OQueryContainer::determineContentType() const
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "application/vnd.org.openoffice.DatabaseQueryContainer" ) );
}
-// -----------------------------------------------------------------------------
Reference< XContent > OQueryContainer::implCreateWrapper(const ::rtl::OUString& _rName)
{
Reference< XContent > xObject(m_xCommandDefinitions->getByName(_rName),UNO_QUERY);
return implCreateWrapper(xObject);
}
-//--------------------------------------------------------------------------
Reference< XContent > OQueryContainer::implCreateWrapper(const Reference< XContent >& _rxCommandDesc)
{
Reference<XNameContainer> xContainer(_rxCommandDesc,UNO_QUERY);
@@ -424,12 +371,12 @@ Reference< XContent > OQueryContainer::implCreateWrapper(const Reference< XConte
return xReturn;
}
-//--------------------------------------------------------------------------
+
Reference< XContent > OQueryContainer::createObject( const ::rtl::OUString& _rName)
{
return implCreateWrapper(_rName);
}
-// -----------------------------------------------------------------------------
+
sal_Bool OQueryContainer::checkExistence(const ::rtl::OUString& _rName)
{
sal_Bool bRet = sal_False;
@@ -449,19 +396,19 @@ sal_Bool OQueryContainer::checkExistence(const ::rtl::OUString& _rName)
}
return bRet;
}
-//--------------------------------------------------------------------------
+
sal_Bool SAL_CALL OQueryContainer::hasElements( ) throw (RuntimeException)
{
MutexGuard aGuard(m_aMutex);
return m_xCommandDefinitions->hasElements();
}
-// -----------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OQueryContainer::getCount( ) throw(RuntimeException)
{
MutexGuard aGuard(m_aMutex);
return Reference<XIndexAccess>(m_xCommandDefinitions,UNO_QUERY)->getCount();
}
-// -----------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > SAL_CALL OQueryContainer::getElementNames( ) throw(RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -469,7 +416,5 @@ Sequence< ::rtl::OUString > SAL_CALL OQueryContainer::getElementNames( ) throw(
return m_xCommandDefinitions->getElementNames();
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/querydescriptor.cxx b/dbaccess/source/core/api/querydescriptor.cxx
index 0fb61dbd1f64..8a03f3fd9ced 100644
--- a/dbaccess/source/core/api/querydescriptor.cxx
+++ b/dbaccess/source/core/api/querydescriptor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREAPI_QUERYDESCRIPTOR_HXX_
#include "querydescriptor.hxx"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _DBACORE_DEFINITIONCOLUMN_HXX_
#include "definitioncolumn.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::awt;
@@ -66,16 +49,14 @@ using namespace ::comphelper;
using namespace ::osl;
using namespace ::cppu;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OQueryDescriptor
//==========================================================================
DBG_NAME(OQueryDescriptor)
-//--------------------------------------------------------------------------
+
OQueryDescriptor::OQueryDescriptor()
:OQueryDescriptor_Base(m_aMutex,*this)
,ODataSettings(m_aBHelper,sal_True)
@@ -85,7 +66,6 @@ OQueryDescriptor::OQueryDescriptor()
ODataSettings::registerPropertiesFor(this);
}
-//--------------------------------------------------------------------------
OQueryDescriptor::OQueryDescriptor(const OQueryDescriptor_Base& _rSource)
:OQueryDescriptor_Base(_rSource,*this)
,ODataSettings(m_aBHelper,sal_True)
@@ -94,15 +74,15 @@ OQueryDescriptor::OQueryDescriptor(const OQueryDescriptor_Base& _rSource)
registerProperties();
ODataSettings::registerPropertiesFor(this);
}
-// -----------------------------------------------------------------------------
+
OQueryDescriptor::~OQueryDescriptor()
{
DBG_DTOR(OQueryDescriptor,NULL);
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_TYPEPROVIDER2(OQueryDescriptor,OQueryDescriptor_Base,ODataSettings);
IMPLEMENT_FORWARD_XINTERFACE3( OQueryDescriptor,OWeakObject,OQueryDescriptor_Base,ODataSettings)
-//--------------------------------------------------------------------------
+
void OQueryDescriptor::registerProperties()
{
// the properties which OCommandBase supplies (it has no own registration, as it's not derived from
@@ -128,19 +108,17 @@ void OQueryDescriptor::registerProperties()
registerProperty(PROPERTY_LAYOUTINFORMATION, PROPERTY_ID_LAYOUTINFORMATION, PropertyAttribute::BOUND,
&m_aLayoutInformation, ::getCppuType(&m_aLayoutInformation));
}
-// -----------------------------------------------------------------------------
-//--------------------------------------------------------------------------
+
Reference< XPropertySetInfo > SAL_CALL OQueryDescriptor::getPropertySetInfo( ) throw(RuntimeException)
{
return createPropertySetInfo( getInfoHelper() ) ;
}
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OQueryDescriptor::getInfoHelper()
{
return *getArrayHelper();
}
-//--------------------------------------------------------------------------
+
::cppu::IPropertyArrayHelper* OQueryDescriptor::createArrayHelper( ) const
{
Sequence< Property > aProps;
@@ -148,9 +126,8 @@ Reference< XPropertySetInfo > SAL_CALL OQueryDescriptor::getPropertySetInfo( )
return new ::cppu::OPropertyArrayHelper(aProps);
}
-// -----------------------------------------------------------------------------
DBG_NAME(OQueryDescriptor_Base);
-//--------------------------------------------------------------------------
+
OQueryDescriptor_Base::OQueryDescriptor_Base(::osl::Mutex& _rMutex,::cppu::OWeakObject& _rMySelf)
:m_bColumnsOutOfDate(sal_True)
,m_rMutex(_rMutex)
@@ -158,7 +135,7 @@ OQueryDescriptor_Base::OQueryDescriptor_Base(::osl::Mutex& _rMutex,::cppu::OWea
DBG_CTOR(OQueryDescriptor_Base,NULL);
m_pColumns = new OColumns(_rMySelf, m_rMutex, sal_True,::std::vector< ::rtl::OUString>(), this,this);
}
-//--------------------------------------------------------------------------
+
OQueryDescriptor_Base::OQueryDescriptor_Base(const OQueryDescriptor_Base& _rSource,::cppu::OWeakObject& _rMySelf)
:m_bColumnsOutOfDate(sal_True)
,m_rMutex(_rSource.m_rMutex)
@@ -174,7 +151,6 @@ OQueryDescriptor_Base::OQueryDescriptor_Base(const OQueryDescriptor_Base& _rSour
m_aLayoutInformation = _rSource.m_aLayoutInformation;
}
-//--------------------------------------------------------------------------
OQueryDescriptor_Base::~OQueryDescriptor_Base()
{
m_pColumns->acquire();
@@ -183,7 +159,7 @@ OQueryDescriptor_Base::~OQueryDescriptor_Base()
DBG_DTOR(OQueryDescriptor_Base,NULL);
}
-// -----------------------------------------------------------------------------
+
sal_Int64 SAL_CALL OQueryDescriptor_Base::getSomething( const Sequence< sal_Int8 >& _rIdentifier ) throw(RuntimeException)
{
if (_rIdentifier.getLength() != 16)
@@ -194,9 +170,9 @@ sal_Int64 SAL_CALL OQueryDescriptor_Base::getSomething( const Sequence< sal_Int8
return 0;
}
-//--------------------------------------------------------------------------
+
IMPLEMENT_IMPLEMENTATION_ID(OQueryDescriptor_Base)
-//--------------------------------------------------------------------------
+
void OQueryDescriptor_Base::setColumnsOutOfDate( sal_Bool _bOutOfDate )
{
m_bColumnsOutOfDate = _bOutOfDate;
@@ -204,13 +180,11 @@ void OQueryDescriptor_Base::setColumnsOutOfDate( sal_Bool _bOutOfDate )
m_pColumns->setInitialized();
}
-//--------------------------------------------------------------------------
void OQueryDescriptor_Base::implAppendColumn( const ::rtl::OUString& _rName, OColumn* _pColumn )
{
m_pColumns->append( _rName, _pColumn );
}
-//--------------------------------------------------------------------------
void OQueryDescriptor_Base::clearColumns( )
{
m_pColumns->clearColumns();
@@ -218,7 +192,6 @@ void OQueryDescriptor_Base::clearColumns( )
setColumnsOutOfDate();
}
-//--------------------------------------------------------------------------
Reference< XNameAccess > SAL_CALL OQueryDescriptor_Base::getColumns( ) throw (RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -249,19 +222,16 @@ Reference< XNameAccess > SAL_CALL OQueryDescriptor_Base::getColumns( ) throw (Ru
return m_pColumns;
}
-//--------------------------------------------------------------------------
::rtl::OUString SAL_CALL OQueryDescriptor_Base::getImplementationName( ) throw(RuntimeException)
{
- return ::rtl::OUString::createFromAscii("com.sun.star.sdb.OQueryDescriptor");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.OQueryDescriptor"));
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OQueryDescriptor_Base::supportsService( const ::rtl::OUString& _rServiceName ) throw(RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL OQueryDescriptor_Base::getSupportedServiceNames( ) throw(RuntimeException)
{
Sequence< ::rtl::OUString > aSupported(2);
@@ -269,37 +239,32 @@ Sequence< ::rtl::OUString > SAL_CALL OQueryDescriptor_Base::getSupportedServiceN
aSupported.getArray()[1] = SERVICE_SDB_QUERYDESCRIPTOR;
return aSupported;
}
-//--------------------------------------------------------------------------
+
void OQueryDescriptor_Base::disposeColumns()
{
m_pColumns->disposing();
}
-// -----------------------------------------------------------------------------
void OQueryDescriptor_Base::columnAppended( const Reference< XPropertySet >& /*_rxSourceDescriptor*/ )
{
// not interested in
}
-// -----------------------------------------------------------------------------
void OQueryDescriptor_Base::columnDropped(const ::rtl::OUString& /*_sName*/)
{
// not interested in
}
-// -----------------------------------------------------------------------------
Reference< XPropertySet > OQueryDescriptor_Base::createColumnDescriptor()
{
- OSL_ENSURE( false, "OQueryDescriptor_Base::createColumnDescriptor: called why?" );
+ OSL_FAIL( "OQueryDescriptor_Base::createColumnDescriptor: called why?" );
return NULL;
}
-// -----------------------------------------------------------------------------
void OQueryDescriptor_Base::rebuildColumns( )
{
}
-// -----------------------------------------------------------------------------
// IRefreshableColumns
void OQueryDescriptor_Base::refreshColumns()
{
@@ -309,15 +274,12 @@ void OQueryDescriptor_Base::refreshColumns()
rebuildColumns();
}
-//------------------------------------------------------------------------------
OColumn* OQueryDescriptor_Base::createColumn( const ::rtl::OUString& /*_rName*/ ) const
{
// creating a column/descriptor for a query/descriptor does not make sense at all
return NULL;
}
-// -----------------------------------------------------------------------------
-//........................................................................
-} // namespace dbaccess
-//........................................................................
+}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/querydescriptor.hxx b/dbaccess/source/core/api/querydescriptor.hxx
index 2f27b4b9c628..391df07351bb 100644
--- a/dbaccess/source/core/api/querydescriptor.hxx
+++ b/dbaccess/source/core/api/querydescriptor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,44 +29,20 @@
#ifndef _DBA_COREAPI_QUERYDESCRIPTOR_HXX_
#define _DBA_COREAPI_QUERYDESCRIPTOR_HXX_
-#ifndef _CPPUHELPER_IMPLBASE3_HXX_
#include <cppuhelper/implbase3.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XUNOTUNNEL_HPP_
#include <com/sun/star/lang/XUnoTunnel.hpp>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DBA_COREAPI_COLUMN_HXX_
#include "column.hxx"
-#endif
-#ifndef _DBA_CORE_DATASETTINGS_HXX_
#include "datasettings.hxx"
-#endif
-#ifndef _DBA_CORE_COMMANDBASE_HXX_
#include "commandbase.hxx"
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
//........................................................................
namespace dbaccess
@@ -181,3 +158,4 @@ public:
#endif // _DBA_COREAPI_QUERYDESCRIPTOR_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/resultcolumn.cxx b/dbaccess/source/core/api/resultcolumn.cxx
index 02195693bba1..7949cef634ce 100644
--- a/dbaccess/source/core/api/resultcolumn.cxx
+++ b/dbaccess/source/core/api/resultcolumn.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,45 +28,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBACORE_RESULTCOLUMN_HXX_
#include "resultcolumn.hxx"
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNVALUE_HPP_
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
-#ifndef _OSL_THREAD_H_
#include <osl/thread.h>
-#endif
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::beans;
@@ -78,7 +53,7 @@ using namespace ::cppu;
using namespace dbaccess;
DBG_NAME(OResultColumn)
-//--------------------------------------------------------------------------
+
OResultColumn::OResultColumn( const Reference < XResultSetMetaData >& _xMetaData, sal_Int32 _nPos,
const Reference< XDatabaseMetaData >& _rxDBMeta )
:OColumn( true )
@@ -88,7 +63,7 @@ OResultColumn::OResultColumn( const Reference < XResultSetMetaData >& _xMetaData
{
DBG_CTOR(OResultColumn,NULL);
}
-// -----------------------------------------------------------------------------
+
void OResultColumn::impl_determineIsRowVersion_nothrow()
{
if ( m_aIsRowVersion.hasValue() )
@@ -133,13 +108,13 @@ void OResultColumn::impl_determineIsRowVersion_nothrow()
DBG_UNHANDLED_EXCEPTION();
}
}
-// -----------------------------------------------------------------------------
+
OResultColumn::~OResultColumn()
{
DBG_DTOR(OResultColumn,NULL);
}
+
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > OResultColumn::getImplementationId() throw (RuntimeException)
{
static OImplementationId * pId = 0;
@@ -156,13 +131,11 @@ Sequence< sal_Int8 > OResultColumn::getImplementationId() throw (RuntimeExceptio
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OResultColumn::getImplementationName( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OResultColumn");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.OResultColumn"));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OResultColumn::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 2 );
@@ -172,7 +145,6 @@ Sequence< ::rtl::OUString > OResultColumn::getSupportedServiceNames( ) throw (R
}
// OComponentHelper
-//------------------------------------------------------------------------------
void OResultColumn::disposing()
{
OColumn::disposing();
@@ -182,7 +154,6 @@ void OResultColumn::disposing()
}
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OResultColumn::createArrayHelper( ) const
{
BEGIN_PROPERTY_HELPER(21)
@@ -211,13 +182,11 @@ void OResultColumn::disposing()
}
// cppu::OPropertySetHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OResultColumn::getInfoHelper()
{
return *static_cast< ::comphelper::OPropertyArrayUsageHelper< OResultColumn >* >(this)->getArrayHelper();
}
-//------------------------------------------------------------------------------
namespace
{
template< typename TYPE >
@@ -229,7 +198,6 @@ namespace
}
}
-//------------------------------------------------------------------------------
void OResultColumn::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
{
try
@@ -304,7 +272,7 @@ void OResultColumn::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
rValue <<= m_xMetaData->getColumnTypeName(m_nPos);
break;
default:
- OSL_ENSURE( false, "OResultColumn::getFastPropertyValue: unknown property handle!" );
+ OSL_FAIL( "OResultColumn::getFastPropertyValue: unknown property handle!" );
break;
}
}
@@ -354,4 +322,4 @@ void OResultColumn::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
}
}
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/resultcolumn.hxx b/dbaccess/source/core/api/resultcolumn.hxx
index 7e1842241cf6..a28854fcdf29 100644
--- a/dbaccess/source/core/api/resultcolumn.hxx
+++ b/dbaccess/source/core/api/resultcolumn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef _DBACORE_RESULTCOLUMN_HXX_
#define _DBACORE_RESULTCOLUMN_HXX_
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATA_HDL_
#include <com/sun/star/sdbc/XResultSetMetaData.hdl>
-#endif
-#ifndef _DBA_COREAPI_COLUMN_HXX_
#include <column.hxx>
-#endif
#include <boost/optional.hpp>
namespace dbaccess
{
@@ -99,3 +96,4 @@ namespace dbaccess
}
#endif // _DBACORE_RESULTCOLUMN_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/resultset.cxx b/dbaccess/source/core/api/resultset.cxx
index 0f1be7553ad6..a6d3e23d4e67 100644
--- a/dbaccess/source/core/api/resultset.cxx
+++ b/dbaccess/source/core/api/resultset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,63 +28,28 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREAPI_RESULTSET_HXX_
#include <resultset.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_RESULTSETTYPE_HPP_
#include <com/sun/star/sdbc/ResultSetType.hpp>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX //autogen
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBA_COREAPI_DATACOLUMN_HXX_
#include <datacolumn.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
-#ifndef _OSL_THREAD_H_
#include <osl/thread.h>
-#endif
#include <rtl/logfile.hxx>
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::sdbcx;
-//using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
@@ -95,7 +61,6 @@ using namespace dbtools;
DBG_NAME(OResultSet)
-//--------------------------------------------------------------------------
OResultSet::OResultSet(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSet >& _xResultSet,
const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& _xStatement,
sal_Bool _bCaseSensitive)
@@ -139,7 +104,6 @@ OResultSet::OResultSet(const ::com::sun::star::uno::Reference< ::com::sun::star:
}
}
-//--------------------------------------------------------------------------
OResultSet::~OResultSet()
{
m_pColumns->acquire();
@@ -150,7 +114,6 @@ OResultSet::~OResultSet()
}
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > OResultSet::getTypes() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getTypes" );
@@ -160,7 +123,6 @@ Sequence< Type > OResultSet::getTypes() throw (RuntimeException)
return aTypes.getTypes();
}
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > OResultSet::getImplementationId() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getImplementationId" );
@@ -178,7 +140,6 @@ Sequence< sal_Int8 > OResultSet::getImplementationId() throw (RuntimeException)
}
// com::sun::star::uno::XInterface
-//--------------------------------------------------------------------------
Any OResultSet::queryInterface( const Type & rType ) throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::queryInterface" );
@@ -191,13 +152,11 @@ Any OResultSet::queryInterface( const Type & rType ) throw (RuntimeException)
return aIface;
}
-//--------------------------------------------------------------------------
void OResultSet::acquire() throw ()
{
OResultSetBase::acquire();
}
-//--------------------------------------------------------------------------
void OResultSet::release() throw ()
{
OResultSetBase::release();
@@ -205,7 +164,6 @@ void OResultSet::release() throw ()
// OResultSetBase
-//------------------------------------------------------------------------------
void OResultSet::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::disposing" );
@@ -227,7 +185,6 @@ void OResultSet::disposing()
}
// XCloseable
-//------------------------------------------------------------------------------
void OResultSet::close(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::close" );
@@ -239,21 +196,18 @@ void OResultSet::close(void) throw( SQLException, RuntimeException )
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OResultSet::getImplementationName( ) throw(RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getImplementationName" );
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OResultSet");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.OResultSet"));
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::supportsService" );
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OResultSet::getSupportedServiceNames( ) throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getSupportedServiceNames" );
@@ -264,7 +218,6 @@ Sequence< ::rtl::OUString > OResultSet::getSupportedServiceNames( ) throw (Runt
}
// com::sun::star::beans::XPropertySet
-//------------------------------------------------------------------------------
Reference< XPropertySetInfo > OResultSet::getPropertySetInfo() throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getPropertySetInfo" );
@@ -272,7 +225,6 @@ Reference< XPropertySetInfo > OResultSet::getPropertySetInfo() throw (RuntimeExc
}
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OResultSet::createArrayHelper( ) const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::createArrayHelper" );
@@ -287,14 +239,12 @@ Reference< XPropertySetInfo > OResultSet::getPropertySetInfo() throw (RuntimeExc
}
// cppu::OPropertySetHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OResultSet::getInfoHelper()
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getInfoHelper" );
return *getArrayHelper();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::convertFastPropertyValue(Any & rConvertedValue, Any & rOldValue, sal_Int32 nHandle, const Any& rValue ) throw( IllegalArgumentException )
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::convertFastPropertyValue" );
@@ -304,7 +254,6 @@ sal_Bool OResultSet::convertFastPropertyValue(Any & rConvertedValue, Any & rOldV
return sal_True;
}
-//------------------------------------------------------------------------------
void OResultSet::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any& rValue ) throw (Exception)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::setFastPropertyValue_NoBroadcast" );
@@ -319,11 +268,10 @@ void OResultSet::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any&
xSet->setPropertyValue(PROPERTY_FETCHSIZE, rValue);
break;
default:
- DBG_ERROR("unknown Property");
+ OSL_FAIL("unknown Property");
}
}
-//------------------------------------------------------------------------------
void OResultSet::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getFastPropertyValue" );
@@ -350,7 +298,6 @@ void OResultSet::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
}
// XWarningsSupplier
-//------------------------------------------------------------------------------
Any OResultSet::getWarnings(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getWarnings" );
@@ -359,7 +306,6 @@ Any OResultSet::getWarnings(void) throw( SQLException, RuntimeException )
return m_aWarnings.getWarnings();
}
-//------------------------------------------------------------------------------
void OResultSet::clearWarnings(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::clearWarnings" );
@@ -369,7 +315,6 @@ void OResultSet::clearWarnings(void) throw( SQLException, RuntimeException )
}
// ::com::sun::star::sdbc::XResultSetMetaDataSupplier
-//------------------------------------------------------------------------------
Reference< XResultSetMetaData > OResultSet::getMetaData(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getMetaData" );
@@ -380,7 +325,6 @@ Reference< XResultSetMetaData > OResultSet::getMetaData(void) throw( SQLExceptio
}
// ::com::sun::star::sdbc::XColumnLocate
-//------------------------------------------------------------------------------
sal_Int32 OResultSet::findColumn(const rtl::OUString& columnName) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::findColumn" );
@@ -390,7 +334,6 @@ sal_Int32 OResultSet::findColumn(const rtl::OUString& columnName) throw( SQLExce
return Reference< XColumnLocate >(m_xDelegatorResultSet, UNO_QUERY)->findColumn(columnName);
}
-//------------------------------------------------------------------------------
namespace
{
static Reference< XDatabaseMetaData > lcl_getDBMetaDataFromStatement_nothrow( const Reference< XInterface >& _rxStatement )
@@ -415,8 +358,8 @@ namespace
return xDBMetaData;
}
}
+
// ::com::sun::star::sdbcx::XColumnsSupplier
-//------------------------------------------------------------------------------
Reference< ::com::sun::star::container::XNameAccess > OResultSet::getColumns(void) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getColumns" );
@@ -488,7 +431,6 @@ Reference< ::com::sun::star::container::XNameAccess > OResultSet::getColumns(voi
}
// ::com::sun::star::sdbc::XRow
-//------------------------------------------------------------------------------
sal_Bool OResultSet::wasNull(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::wasNull" );
@@ -497,7 +439,7 @@ sal_Bool OResultSet::wasNull(void) throw( SQLException, RuntimeException )
return m_xDelegatorRow->wasNull();
}
-//------------------------------------------------------------------------------
+
rtl::OUString OResultSet::getString(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getString" );
@@ -506,7 +448,7 @@ rtl::OUString OResultSet::getString(sal_Int32 columnIndex) throw( SQLException,
return m_xDelegatorRow->getString(columnIndex);
}
-//------------------------------------------------------------------------------
+
sal_Bool OResultSet::getBoolean(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBoolean" );
@@ -515,7 +457,7 @@ sal_Bool OResultSet::getBoolean(sal_Int32 columnIndex) throw( SQLException, Runt
return m_xDelegatorRow->getBoolean(columnIndex);
}
-//------------------------------------------------------------------------------
+
sal_Int8 OResultSet::getByte(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getByte" );
@@ -524,7 +466,7 @@ sal_Int8 OResultSet::getByte(sal_Int32 columnIndex) throw( SQLException, Runtime
return m_xDelegatorRow->getByte(columnIndex);
}
-//------------------------------------------------------------------------------
+
sal_Int16 OResultSet::getShort(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getShort" );
@@ -533,7 +475,7 @@ sal_Int16 OResultSet::getShort(sal_Int32 columnIndex) throw( SQLException, Runti
return m_xDelegatorRow->getShort(columnIndex);
}
-//------------------------------------------------------------------------------
+
sal_Int32 OResultSet::getInt(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getInt" );
@@ -542,7 +484,7 @@ sal_Int32 OResultSet::getInt(sal_Int32 columnIndex) throw( SQLException, Runtime
return m_xDelegatorRow->getInt(columnIndex);
}
-//------------------------------------------------------------------------------
+
sal_Int64 OResultSet::getLong(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getLong" );
@@ -551,7 +493,7 @@ sal_Int64 OResultSet::getLong(sal_Int32 columnIndex) throw( SQLException, Runtim
return m_xDelegatorRow->getLong(columnIndex);
}
-//------------------------------------------------------------------------------
+
float OResultSet::getFloat(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getFloat" );
@@ -560,7 +502,7 @@ float OResultSet::getFloat(sal_Int32 columnIndex) throw( SQLException, RuntimeEx
return m_xDelegatorRow->getFloat(columnIndex);
}
-//------------------------------------------------------------------------------
+
double OResultSet::getDouble(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getDouble" );
@@ -569,7 +511,7 @@ double OResultSet::getDouble(sal_Int32 columnIndex) throw( SQLException, Runtime
return m_xDelegatorRow->getDouble(columnIndex);
}
-//------------------------------------------------------------------------------
+
Sequence< sal_Int8 > OResultSet::getBytes(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBytes" );
@@ -578,7 +520,7 @@ Sequence< sal_Int8 > OResultSet::getBytes(sal_Int32 columnIndex) throw( SQLExcep
return m_xDelegatorRow->getBytes(columnIndex);
}
-//------------------------------------------------------------------------------
+
::com::sun::star::util::Date OResultSet::getDate(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getDate" );
@@ -587,7 +529,7 @@ Sequence< sal_Int8 > OResultSet::getBytes(sal_Int32 columnIndex) throw( SQLExcep
return m_xDelegatorRow->getDate(columnIndex);
}
-//------------------------------------------------------------------------------
+
::com::sun::star::util::Time OResultSet::getTime(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getTime" );
@@ -596,7 +538,7 @@ Sequence< sal_Int8 > OResultSet::getBytes(sal_Int32 columnIndex) throw( SQLExcep
return m_xDelegatorRow->getTime(columnIndex);
}
-//------------------------------------------------------------------------------
+
::com::sun::star::util::DateTime OResultSet::getTimestamp(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getTimestamp" );
@@ -605,7 +547,7 @@ Sequence< sal_Int8 > OResultSet::getBytes(sal_Int32 columnIndex) throw( SQLExcep
return m_xDelegatorRow->getTimestamp(columnIndex);
}
-//------------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > OResultSet::getBinaryStream(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBinaryStream" );
@@ -614,7 +556,7 @@ Reference< ::com::sun::star::io::XInputStream > OResultSet::getBinaryStream(sal
return m_xDelegatorRow->getBinaryStream(columnIndex);
}
-//------------------------------------------------------------------------------
+
Reference< ::com::sun::star::io::XInputStream > OResultSet::getCharacterStream(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getCharacterStream" );
@@ -623,7 +565,7 @@ Reference< ::com::sun::star::io::XInputStream > OResultSet::getCharacterStream(
return m_xDelegatorRow->getCharacterStream(columnIndex);
}
-//------------------------------------------------------------------------------
+
Any OResultSet::getObject(sal_Int32 columnIndex, const Reference< ::com::sun::star::container::XNameAccess > & typeMap) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getObject" );
@@ -632,7 +574,7 @@ Any OResultSet::getObject(sal_Int32 columnIndex, const Reference< ::com::sun::st
return m_xDelegatorRow->getObject(columnIndex, typeMap);
}
-//------------------------------------------------------------------------------
+
Reference< XRef > OResultSet::getRef(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getRef" );
@@ -641,7 +583,7 @@ Reference< XRef > OResultSet::getRef(sal_Int32 columnIndex) throw( SQLException
return m_xDelegatorRow->getRef(columnIndex);
}
-//------------------------------------------------------------------------------
+
Reference< XBlob > OResultSet::getBlob(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBlob" );
@@ -650,7 +592,7 @@ Reference< XBlob > OResultSet::getBlob(sal_Int32 columnIndex) throw( SQLExcepti
return m_xDelegatorRow->getBlob(columnIndex);
}
-//------------------------------------------------------------------------------
+
Reference< XClob > OResultSet::getClob(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getClob" );
@@ -659,7 +601,7 @@ Reference< XClob > OResultSet::getClob(sal_Int32 columnIndex) throw( SQLExcepti
return m_xDelegatorRow->getClob(columnIndex);
}
-//------------------------------------------------------------------------------
+
Reference< XArray > OResultSet::getArray(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getArray" );
@@ -670,7 +612,6 @@ Reference< XArray > OResultSet::getArray(sal_Int32 columnIndex) throw( SQLExcep
}
// ::com::sun::star::sdbc::XRowUpdate
-//------------------------------------------------------------------------------
void OResultSet::updateNull(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateNull" );
@@ -682,7 +623,6 @@ void OResultSet::updateNull(sal_Int32 columnIndex) throw( SQLException, RuntimeE
m_xDelegatorRowUpdate->updateNull(columnIndex);
}
-//------------------------------------------------------------------------------
void OResultSet::updateBoolean(sal_Int32 columnIndex, sal_Bool x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateBoolean" );
@@ -693,7 +633,7 @@ void OResultSet::updateBoolean(sal_Int32 columnIndex, sal_Bool x) throw( SQLExce
m_xDelegatorRowUpdate->updateBoolean(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateByte(sal_Int32 columnIndex, sal_Int8 x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateByte" );
@@ -704,7 +644,7 @@ void OResultSet::updateByte(sal_Int32 columnIndex, sal_Int8 x) throw( SQLExcepti
m_xDelegatorRowUpdate->updateByte(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateShort(sal_Int32 columnIndex, sal_Int16 x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateShort" );
@@ -715,7 +655,7 @@ void OResultSet::updateShort(sal_Int32 columnIndex, sal_Int16 x) throw( SQLExcep
m_xDelegatorRowUpdate->updateShort(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateInt(sal_Int32 columnIndex, sal_Int32 x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateInt" );
@@ -726,7 +666,7 @@ void OResultSet::updateInt(sal_Int32 columnIndex, sal_Int32 x) throw( SQLExcepti
m_xDelegatorRowUpdate->updateInt(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateLong(sal_Int32 columnIndex, sal_Int64 x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateLong" );
@@ -737,7 +677,7 @@ void OResultSet::updateLong(sal_Int32 columnIndex, sal_Int64 x) throw( SQLExcept
m_xDelegatorRowUpdate->updateLong(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateFloat(sal_Int32 columnIndex, float x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateFloat" );
@@ -748,7 +688,7 @@ void OResultSet::updateFloat(sal_Int32 columnIndex, float x) throw( SQLException
m_xDelegatorRowUpdate->updateFloat(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateDouble(sal_Int32 columnIndex, double x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateDouble" );
@@ -759,7 +699,7 @@ void OResultSet::updateDouble(sal_Int32 columnIndex, double x) throw( SQLExcepti
m_xDelegatorRowUpdate->updateDouble(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateString(sal_Int32 columnIndex, const rtl::OUString& x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateString" );
@@ -770,7 +710,7 @@ void OResultSet::updateString(sal_Int32 columnIndex, const rtl::OUString& x) thr
m_xDelegatorRowUpdate->updateString(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateBytes(sal_Int32 columnIndex, const Sequence< sal_Int8 >& x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateBytes" );
@@ -781,7 +721,7 @@ void OResultSet::updateBytes(sal_Int32 columnIndex, const Sequence< sal_Int8 >&
m_xDelegatorRowUpdate->updateBytes(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateDate(sal_Int32 columnIndex, const ::com::sun::star::util::Date& x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateDate" );
@@ -792,7 +732,7 @@ void OResultSet::updateDate(sal_Int32 columnIndex, const ::com::sun::star::util:
m_xDelegatorRowUpdate->updateDate(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateTime(sal_Int32 columnIndex, const ::com::sun::star::util::Time& x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateTime" );
@@ -803,7 +743,7 @@ void OResultSet::updateTime(sal_Int32 columnIndex, const ::com::sun::star::util:
m_xDelegatorRowUpdate->updateTime(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateTimestamp(sal_Int32 columnIndex, const ::com::sun::star::util::DateTime& x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateTimestamp" );
@@ -814,7 +754,7 @@ void OResultSet::updateTimestamp(sal_Int32 columnIndex, const ::com::sun::star::
m_xDelegatorRowUpdate->updateTimestamp(columnIndex, x);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateBinaryStream(sal_Int32 columnIndex, const Reference< ::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateBinaryStream" );
@@ -825,7 +765,7 @@ void OResultSet::updateBinaryStream(sal_Int32 columnIndex, const Reference< ::co
m_xDelegatorRowUpdate->updateBinaryStream(columnIndex, x, length);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateCharacterStream(sal_Int32 columnIndex, const Reference< ::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateCharacterStream" );
@@ -836,7 +776,7 @@ void OResultSet::updateCharacterStream(sal_Int32 columnIndex, const Reference< :
m_xDelegatorRowUpdate->updateCharacterStream(columnIndex, x, length);
}
-//------------------------------------------------------------------------------
+
void OResultSet::updateNumericObject(sal_Int32 columnIndex, const Any& x, sal_Int32 scale) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateNumericObject" );
@@ -848,7 +788,6 @@ void OResultSet::updateNumericObject(sal_Int32 columnIndex, const Any& x, sal_In
m_xDelegatorRowUpdate->updateNumericObject(columnIndex, x, scale);
}
-//------------------------------------------------------------------------------
void OResultSet::updateObject(sal_Int32 columnIndex, const Any& x) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateObject" );
@@ -861,7 +800,6 @@ void OResultSet::updateObject(sal_Int32 columnIndex, const Any& x) throw( SQLExc
}
// ::com::sun::star::sdbc::XResultSet
-//------------------------------------------------------------------------------
sal_Bool OResultSet::next(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::next" );
@@ -871,7 +809,6 @@ sal_Bool OResultSet::next(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->next();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::isBeforeFirst(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isBeforeFirst" );
@@ -881,7 +818,6 @@ sal_Bool OResultSet::isBeforeFirst(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->isBeforeFirst();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::isAfterLast(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isAfterLast" );
@@ -891,7 +827,6 @@ sal_Bool OResultSet::isAfterLast(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->isAfterLast();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::isFirst(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isFirst" );
@@ -901,7 +836,6 @@ sal_Bool OResultSet::isFirst(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->isFirst();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::isLast(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isLast" );
@@ -911,7 +845,6 @@ sal_Bool OResultSet::isLast(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->isLast();
}
-//------------------------------------------------------------------------------
void OResultSet::beforeFirst(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::beforeFirst" );
@@ -921,7 +854,6 @@ void OResultSet::beforeFirst(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSet->beforeFirst();
}
-//------------------------------------------------------------------------------
void OResultSet::afterLast(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::afterLast" );
@@ -931,7 +863,6 @@ void OResultSet::afterLast(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSet->afterLast();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::first(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::first" );
@@ -941,7 +872,6 @@ sal_Bool OResultSet::first(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->first();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::last(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::last" );
@@ -951,7 +881,6 @@ sal_Bool OResultSet::last(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->last();
}
-//------------------------------------------------------------------------------
sal_Int32 OResultSet::getRow(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getRow" );
@@ -961,7 +890,6 @@ sal_Int32 OResultSet::getRow(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->getRow();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::absolute(sal_Int32 row) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::absolute" );
@@ -971,7 +899,6 @@ sal_Bool OResultSet::absolute(sal_Int32 row) throw( SQLException, RuntimeExcepti
return m_xDelegatorResultSet->absolute(row);
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::relative(sal_Int32 rows) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::relative" );
@@ -981,7 +908,6 @@ sal_Bool OResultSet::relative(sal_Int32 rows) throw( SQLException, RuntimeExcept
return m_xDelegatorResultSet->relative(rows);
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::previous(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::previous" );
@@ -991,7 +917,6 @@ sal_Bool OResultSet::previous(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->previous();
}
-//------------------------------------------------------------------------------
void OResultSet::refreshRow(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::refreshRow" );
@@ -1001,7 +926,6 @@ void OResultSet::refreshRow(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSet->refreshRow();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::rowUpdated(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::rowUpdated" );
@@ -1011,7 +935,6 @@ sal_Bool OResultSet::rowUpdated(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->rowUpdated();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::rowInserted(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::rowInserted" );
@@ -1021,7 +944,6 @@ sal_Bool OResultSet::rowInserted(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->rowInserted();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::rowDeleted(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::rowDeleted" );
@@ -1031,7 +953,6 @@ sal_Bool OResultSet::rowDeleted(void) throw( SQLException, RuntimeException )
return m_xDelegatorResultSet->rowDeleted();
}
-//------------------------------------------------------------------------------
Reference< XInterface > OResultSet::getStatement(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getStatement" );
@@ -1042,7 +963,6 @@ Reference< XInterface > OResultSet::getStatement(void) throw( SQLException, Runt
}
// ::com::sun::star::sdbcx::XRowLocate
-//------------------------------------------------------------------------------
Any OResultSet::getBookmark(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBookmark" );
@@ -1054,7 +974,6 @@ Any OResultSet::getBookmark(void) throw( SQLException, RuntimeException )
return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->getBookmark();
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::moveToBookmark(const Any& bookmark) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveToBookmark" );
@@ -1066,7 +985,6 @@ sal_Bool OResultSet::moveToBookmark(const Any& bookmark) throw( SQLException, Ru
return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->moveToBookmark(bookmark);
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::moveRelativeToBookmark(const Any& bookmark, sal_Int32 rows) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveRelativeToBookmark" );
@@ -1078,7 +996,6 @@ sal_Bool OResultSet::moveRelativeToBookmark(const Any& bookmark, sal_Int32 rows)
return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->moveRelativeToBookmark(bookmark, rows);
}
-//------------------------------------------------------------------------------
sal_Int32 OResultSet::compareBookmarks(const Any& _first, const Any& _second) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::compareBookmarks" );
@@ -1090,7 +1007,6 @@ sal_Int32 OResultSet::compareBookmarks(const Any& _first, const Any& _second) th
return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->compareBookmarks(_first, _second);
}
-//------------------------------------------------------------------------------
sal_Bool OResultSet::hasOrderedBookmarks(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::hasOrderedBookmarks" );
@@ -1102,7 +1018,6 @@ sal_Bool OResultSet::hasOrderedBookmarks(void) throw( SQLException, RuntimeExcep
return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->hasOrderedBookmarks();
}
-//------------------------------------------------------------------------------
sal_Int32 OResultSet::hashBookmark(const Any& bookmark) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::hashBookmark" );
@@ -1115,7 +1030,6 @@ sal_Int32 OResultSet::hashBookmark(const Any& bookmark) throw( SQLException, Run
}
// ::com::sun::star::sdbc::XResultSetUpdate
-//------------------------------------------------------------------------------
void OResultSet::insertRow(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::insertRow" );
@@ -1127,7 +1041,6 @@ void OResultSet::insertRow(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSetUpdate->insertRow();
}
-//------------------------------------------------------------------------------
void OResultSet::updateRow(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateRow" );
@@ -1139,7 +1052,6 @@ void OResultSet::updateRow(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSetUpdate->updateRow();
}
-//------------------------------------------------------------------------------
void OResultSet::deleteRow(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::deleteRow" );
@@ -1151,7 +1063,6 @@ void OResultSet::deleteRow(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSetUpdate->deleteRow();
}
-//------------------------------------------------------------------------------
void OResultSet::cancelRowUpdates(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::cancelRowUpdates" );
@@ -1163,7 +1074,6 @@ void OResultSet::cancelRowUpdates(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSetUpdate->cancelRowUpdates();
}
-//------------------------------------------------------------------------------
void OResultSet::moveToInsertRow(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveToInsertRow" );
@@ -1175,7 +1085,6 @@ void OResultSet::moveToInsertRow(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSetUpdate->moveToInsertRow();
}
-//------------------------------------------------------------------------------
void OResultSet::moveToCurrentRow(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveToCurrentRow" );
@@ -1187,7 +1096,6 @@ void OResultSet::moveToCurrentRow(void) throw( SQLException, RuntimeException )
m_xDelegatorResultSetUpdate->moveToCurrentRow();
}
-// -----------------------------------------------------------------------------
void OResultSet::checkReadOnly() const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::checkReadOnly" );
@@ -1197,12 +1105,10 @@ void OResultSet::checkReadOnly() const
throwSQLException( "The result set is read-only.", SQL_GENERAL_ERROR, *const_cast< OResultSet* >( this ) );
}
-// -----------------------------------------------------------------------------
void OResultSet::checkBookmarkable() const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::checkBookmarkable" );
if ( !m_bIsBookmarkable )
throwSQLException( "The result set does not have bookmark support.", SQL_GENERAL_ERROR, *const_cast< OResultSet* >( this ) );
}
-// -----------------------------------------------------------------------------
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/resultset.hxx b/dbaccess/source/core/api/resultset.hxx
index cc765919c313..dfc750bf51be 100644
--- a/dbaccess/source/core/api/resultset.hxx
+++ b/dbaccess/source/core/api/resultset.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,68 +28,28 @@
#ifndef _DBA_COREAPI_RESULTSET_HXX_
#define _DBA_COREAPI_RESULTSET_HXX_
-#ifndef _DBA_COREAPI_COLUMN_HXX_
#include "column.hxx"
-#endif
-#ifndef DBTOOLS_WARNINGSCONTAINER_HXX
#include <connectivity/warningscontainer.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XSTATEMENT_HPP_
#include <com/sun/star/sdbc/XStatement.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCLOSEABLE_HPP_
#include <com/sun/star/sdbc/XCloseable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XWARNINGSSUPPLIER_HPP_
#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSET_HPP_
#include <com/sun/star/sdbc/XResultSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCOLUMNLOCATE_HPP_
#include <com/sun/star/sdbc/XColumnLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XROWLOCATE_HPP_
#include <com/sun/star/sdbcx/XRowLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWUPDATE_HPP_
#include <com/sun/star/sdbc/XRowUpdate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETUPDATE_HPP_
#include <com/sun/star/sdbc/XResultSetUpdate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_RESULTSETCONCURRENCY_HPP_
#include <com/sun/star/sdbc/ResultSetConcurrency.hpp>
-#endif
-#ifndef _CPPUHELPER_PROPSHLP_HXX
#include <cppuhelper/propshlp.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _CPPUHELPER_COMPBASE11_HXX_
#include <cppuhelper/compbase11.hxx>
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
namespace dbaccess
{
@@ -276,3 +237,4 @@ namespace dbaccess
}
#endif // _DBA_COREAPI_RESULTSET_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/statement.cxx b/dbaccess/source/core/api/statement.cxx
index 05ef557f2582..251facd240a9 100644
--- a/dbaccess/source/core/api/statement.cxx
+++ b/dbaccess/source/core/api/statement.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,42 +28,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREAPI_STATEMENT_HXX_
#include <statement.hxx>
-#endif
-#ifndef _DBA_COREAPI_RESULTSET_HXX_
#include <resultset.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX //autogen
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
#include <rtl/logfile.hxx>
using namespace ::com::sun::star::sdb;
@@ -77,7 +54,6 @@ using namespace dbtools;
DBG_NAME(OStatementBase)
-//--------------------------------------------------------------------------
OStatementBase::OStatementBase(const Reference< XConnection > & _xConn,
const Reference< XInterface > & _xStatement)
:OSubComponent(m_aMutex, _xConn)
@@ -93,14 +69,12 @@ OStatementBase::OStatementBase(const Reference< XConnection > & _xConn,
m_xAggregateAsCancellable = Reference< ::com::sun::star::util::XCancellable > (m_xAggregateAsSet, UNO_QUERY);
}
-//--------------------------------------------------------------------------
OStatementBase::~OStatementBase()
{
DBG_DTOR(OStatementBase, NULL);
}
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > OStatementBase::getTypes() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getTypes" );
@@ -121,7 +95,6 @@ Sequence< Type > OStatementBase::getTypes() throw (RuntimeException)
}
// com::sun::star::uno::XInterface
-//--------------------------------------------------------------------------
Any OStatementBase::queryInterface( const Type & rType ) throw (RuntimeException)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::queryInterface" );
@@ -140,7 +113,7 @@ Any OStatementBase::queryInterface( const Type & rType ) throw (RuntimeException
Reference< XGeneratedResultSet > xGRes(m_xAggregateAsSet, UNO_QUERY);
if ( ::getCppuType( (const Reference< XGeneratedResultSet > *)0 ) == rType && xGRes.is() )
aIface = ::cppu::queryInterface(rType,static_cast< XGeneratedResultSet * >( this ));
- } // if ( !aIface.hasValue() )
+ }
if ( !aIface.hasValue() )
{
Reference< XPreparedBatchExecution > xGRes(m_xAggregateAsSet, UNO_QUERY);
@@ -151,19 +124,16 @@ Any OStatementBase::queryInterface( const Type & rType ) throw (RuntimeException
return aIface;
}
-//--------------------------------------------------------------------------
void OStatementBase::acquire() throw ()
{
OSubComponent::acquire();
}
-//--------------------------------------------------------------------------
void OStatementBase::release() throw ()
{
OSubComponent::release();
}
-//------------------------------------------------------------------------------
void OStatementBase::disposeResultSet()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::disposeResultSet" );
@@ -175,7 +145,6 @@ void OStatementBase::disposeResultSet()
}
// OComponentHelper
-//------------------------------------------------------------------------------
void OStatementBase::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::disposing" );
@@ -209,7 +178,6 @@ void OStatementBase::disposing()
}
// XCloseable
-//------------------------------------------------------------------------------
void OStatementBase::close(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::close" );
@@ -221,7 +189,6 @@ void OStatementBase::close(void) throw( SQLException, RuntimeException )
}
// OPropertySetHelper
-//------------------------------------------------------------------------------
Reference< XPropertySetInfo > OStatementBase::getPropertySetInfo() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getPropertySetInfo" );
@@ -229,7 +196,6 @@ Reference< XPropertySetInfo > OStatementBase::getPropertySetInfo() throw (Runtim
}
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* OStatementBase::createArrayHelper( ) const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::createArrayHelper" );
@@ -248,14 +214,12 @@ Reference< XPropertySetInfo > OStatementBase::getPropertySetInfo() throw (Runtim
}
// cppu::OPropertySetHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OStatementBase::getInfoHelper()
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getInfoHelper" );
return *getArrayHelper();
}
-//------------------------------------------------------------------------------
sal_Bool OStatementBase::convertFastPropertyValue( Any & rConvertedValue, Any & rOldValue, sal_Int32 nHandle, const Any& rValue ) throw( IllegalArgumentException )
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::convertFastPropertyValue" );
@@ -291,7 +255,6 @@ sal_Bool OStatementBase::convertFastPropertyValue( Any & rConvertedValue, Any &
return bModified;
}
-//------------------------------------------------------------------------------
void OStatementBase::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any& rValue ) throw (Exception)
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::setFastPropertyValue_NoBroadcast" );
@@ -322,7 +285,6 @@ void OStatementBase::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const
}
}
-//------------------------------------------------------------------------------
void OStatementBase::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getFastPropertyValue" );
@@ -350,7 +312,6 @@ void OStatementBase::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) cons
}
// XWarningsSupplier
-//------------------------------------------------------------------------------
Any OStatementBase::getWarnings(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getWarnings" );
@@ -360,7 +321,6 @@ Any OStatementBase::getWarnings(void) throw( SQLException, RuntimeException )
return Reference< XWarningsSupplier >(m_xAggregateAsSet, UNO_QUERY)->getWarnings();
}
-//------------------------------------------------------------------------------
void OStatementBase::clearWarnings(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::clearWarnings" );
@@ -371,7 +331,6 @@ void OStatementBase::clearWarnings(void) throw( SQLException, RuntimeException )
}
// ::com::sun::star::util::XCancellable
-//------------------------------------------------------------------------------
void OStatementBase::cancel(void) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::cancel" );
@@ -383,7 +342,6 @@ void OStatementBase::cancel(void) throw( RuntimeException )
}
// XMultipleResults
-//------------------------------------------------------------------------------
Reference< XResultSet > SAL_CALL OStatementBase::getResultSet( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getResultSet" );
@@ -398,7 +356,6 @@ Reference< XResultSet > SAL_CALL OStatementBase::getResultSet( ) throw(SQLExcep
return Reference< XMultipleResults >(m_xAggregateAsSet, UNO_QUERY)->getResultSet();
}
-//------------------------------------------------------------------------------
sal_Int32 SAL_CALL OStatementBase::getUpdateCount( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getUpdateCount" );
@@ -413,7 +370,6 @@ sal_Int32 SAL_CALL OStatementBase::getUpdateCount( ) throw(SQLException, Runtim
return Reference< XMultipleResults >(m_xAggregateAsSet, UNO_QUERY)->getUpdateCount();
}
-//------------------------------------------------------------------------------
sal_Bool SAL_CALL OStatementBase::getMoreResults( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getMoreResults" );
@@ -433,7 +389,6 @@ sal_Bool SAL_CALL OStatementBase::getMoreResults( ) throw(SQLException, Runtime
}
// XPreparedBatchExecution
-//------------------------------------------------------------------------------
void SAL_CALL OStatementBase::addBatch( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::addBatch" );
@@ -448,7 +403,6 @@ void SAL_CALL OStatementBase::addBatch( ) throw(SQLException, RuntimeException)
Reference< XPreparedBatchExecution >(m_xAggregateAsSet, UNO_QUERY)->addBatch();
}
-//------------------------------------------------------------------------------
void SAL_CALL OStatementBase::clearBatch( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::clearBatch" );
@@ -463,7 +417,6 @@ void SAL_CALL OStatementBase::clearBatch( ) throw(SQLException, RuntimeExceptio
Reference< XPreparedBatchExecution >(m_xAggregateAsSet, UNO_QUERY)->clearBatch();
}
-//------------------------------------------------------------------------------
Sequence< sal_Int32 > SAL_CALL OStatementBase::executeBatch( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::executeBatch" );
@@ -480,7 +433,7 @@ Sequence< sal_Int32 > SAL_CALL OStatementBase::executeBatch( ) throw(SQLExcepti
return Reference< XPreparedBatchExecution >(m_xAggregateAsSet, UNO_QUERY)->executeBatch();
}
-// -----------------------------------------------------------------------------
+
Reference< XResultSet > SAL_CALL OStatementBase::getGeneratedValues( ) throw (SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatementBase::getGeneratedValues" );
@@ -496,7 +449,6 @@ Reference< XResultSet > SAL_CALL OStatementBase::getGeneratedValues( ) throw (S
//************************************************************
// OStatement
//************************************************************
-//------------------------------------------------------------------------------
OStatement::OStatement( const Reference< XConnection >& _xConn, const Reference< XInterface > & _xStatement )
:OStatementBase( _xConn, _xStatement )
,m_bAttemptedComposerCreation( false )
@@ -505,26 +457,22 @@ OStatement::OStatement( const Reference< XConnection >& _xConn, const Reference<
m_xAggregateStatement.set( _xStatement, UNO_QUERY_THROW );
}
-//------------------------------------------------------------------------------
IMPLEMENT_FORWARD_XINTERFACE2( OStatement, OStatementBase, OStatement_IFACE );
IMPLEMENT_FORWARD_XTYPEPROVIDER2( OStatement, OStatementBase, OStatement_IFACE );
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OStatement::getImplementationName( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::getImplementationName" );
- return rtl::OUString::createFromAscii("com.sun.star.sdb.OStatement");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.OStatement"));
}
-//------------------------------------------------------------------------------
sal_Bool OStatement::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::supportsService" );
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OStatement::getSupportedServiceNames( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::getSupportedServiceNames" );
@@ -534,7 +482,6 @@ Sequence< ::rtl::OUString > OStatement::getSupportedServiceNames( ) throw (Runt
}
// XStatement
-//------------------------------------------------------------------------------
Reference< XResultSet > OStatement::executeQuery( const rtl::OUString& _rSQL ) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::executeQuery" );
@@ -562,7 +509,6 @@ Reference< XResultSet > OStatement::executeQuery( const rtl::OUString& _rSQL ) t
return xResultSet;
}
-//------------------------------------------------------------------------------
sal_Int32 OStatement::executeUpdate( const rtl::OUString& _rSQL ) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::executeUpdate" );
@@ -575,7 +521,6 @@ sal_Int32 OStatement::executeUpdate( const rtl::OUString& _rSQL ) throw( SQLExce
return m_xAggregateStatement->executeUpdate( sSQL );
}
-//------------------------------------------------------------------------------
sal_Bool OStatement::execute( const rtl::OUString& _rSQL ) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::execute" );
@@ -587,7 +532,7 @@ sal_Bool OStatement::execute( const rtl::OUString& _rSQL ) throw( SQLException,
::rtl::OUString sSQL( impl_doEscapeProcessing_nothrow( _rSQL ) );
return m_xAggregateStatement->execute( sSQL );
}
-//------------------------------------------------------------------------------
+
void OStatement::addBatch( const rtl::OUString& _rSQL ) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::execute" );
@@ -602,7 +547,7 @@ void OStatement::addBatch( const rtl::OUString& _rSQL ) throw( SQLException, Run
::rtl::OUString sSQL( impl_doEscapeProcessing_nothrow( _rSQL ) );
Reference< XBatchExecution >(m_xAggregateAsSet, UNO_QUERY)->addBatch( sSQL );
}
-//------------------------------------------------------------------------------
+
void OStatement::clearBatch( ) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::execute" );
@@ -615,7 +560,7 @@ void OStatement::clearBatch( ) throw( SQLException, RuntimeException )
Reference< XBatchExecution >(m_xAggregateAsSet, UNO_QUERY)->clearBatch();
}
-//------------------------------------------------------------------------------
+
Sequence< sal_Int32 > OStatement::executeBatch( ) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::execute" );
@@ -628,14 +573,13 @@ Sequence< sal_Int32 > OStatement::executeBatch( ) throw( SQLException, RuntimeEx
return Reference< XBatchExecution >(m_xAggregateAsSet, UNO_QUERY)->executeBatch( );
}
-//------------------------------------------------------------------------------
+
Reference< XConnection > OStatement::getConnection(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::getConnection" );
return Reference< XConnection >( m_xParent, UNO_QUERY );
}
-// -----------------------------------------------------------------------------
void SAL_CALL OStatement::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::disposing" );
@@ -644,7 +588,6 @@ void SAL_CALL OStatement::disposing()
m_xAggregateStatement.clear();
}
-// -----------------------------------------------------------------------------
::rtl::OUString OStatement::impl_doEscapeProcessing_nothrow( const ::rtl::OUString& _rSQL ) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::impl_doEscapeProcessing_nothrow" );
@@ -674,7 +617,6 @@ void SAL_CALL OStatement::disposing()
return _rSQL;
}
-// -----------------------------------------------------------------------------
bool OStatement::impl_ensureComposer_nothrow() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OStatement::impl_ensureComposer_nothrow" );
@@ -694,3 +636,5 @@ bool OStatement::impl_ensureComposer_nothrow() const
return m_xComposer.is();
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/table.cxx b/dbaccess/source/core/api/table.cxx
index e33098f74f4c..5cbe805d1740 100644
--- a/dbaccess/source/core/api/table.cxx
+++ b/dbaccess/source/core/api/table.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,12 +37,12 @@
#include "CIndexes.hxx"
#include <tools/debug.hxx>
+#include <osl/diagnose.h>
#include <cppuhelper/typeprovider.hxx>
#include <comphelper/enumhelper.hxx>
#include <comphelper/container.hxx>
#include <comphelper/sequence.hxx>
#include <comphelper/types.hxx>
-//#include <comphelper/extract.hxx>
#include <com/sun/star/util/XRefreshListener.hpp>
#include <com/sun/star/sdbc/XConnection.hpp>
#include <com/sun/star/sdbc/XRow.hpp>
@@ -76,7 +77,7 @@ typedef ::std::map <sal_Int32, OTableColumn*, std::less <sal_Int32> > OColMap;
//= ODBTable
//==========================================================================
DBG_NAME(ODBTable)
-//--------------------------------------------------------------------------
+
ODBTable::ODBTable(connectivity::sdbcx::OCollection* _pTables
,const Reference< XConnection >& _rxConn
,const ::rtl::OUString& _rCatalog
@@ -91,14 +92,14 @@ ODBTable::ODBTable(connectivity::sdbcx::OCollection* _pTables
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::ODBTable" );
DBG_CTOR(ODBTable, NULL);
- DBG_ASSERT(getMetaData().is(), "ODBTable::ODBTable : invalid conn !");
- DBG_ASSERT(_rName.getLength(), "ODBTable::ODBTable : name !");
+ OSL_ENSURE(getMetaData().is(), "ODBTable::ODBTable : invalid conn !");
+ OSL_ENSURE(_rName.getLength(), "ODBTable::ODBTable : name !");
// TODO : think about collecting the privileges here, as we can't ensure that in getFastPropertyValue, where
// we do this at the moment, the statement needed can be supplied by the connection (for example the SQL-Server
// ODBC driver does not allow more than one statement per connection, and in getFastPropertyValue it's more
// likely that it's already used up than it's here.)
}
-// -----------------------------------------------------------------------------
+
ODBTable::ODBTable(connectivity::sdbcx::OCollection* _pTables
,const Reference< XConnection >& _rxConn)
throw(SQLException)
@@ -108,15 +109,14 @@ ODBTable::ODBTable(connectivity::sdbcx::OCollection* _pTables
DBG_CTOR(ODBTable, NULL);
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::ODBTable" );
}
-// -------------------------------------------------------------------------
+
ODBTable::~ODBTable()
{
DBG_DTOR(ODBTable, NULL);
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_FORWARD_REFCOUNT(ODBTable,OTable_Base)
-//--------------------------------------------------------------------------
OColumn* ODBTable::createColumn(const ::rtl::OUString& _rName) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::createColumn" );
@@ -140,13 +140,13 @@ OColumn* ODBTable::createColumn(const ::rtl::OUString& _rName) const
return pReturn;
}
-// -----------------------------------------------------------------------------
+
void ODBTable::columnAppended( const Reference< XPropertySet >& /*_rxSourceDescriptor*/ )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::columnAppended" );
// not interested in
}
-// -----------------------------------------------------------------------------
+
void ODBTable::columnDropped(const ::rtl::OUString& _sName)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::columnDropped" );
@@ -156,7 +156,7 @@ void ODBTable::columnDropped(const ::rtl::OUString& _sName)
xDrop->dropByName(_sName);
}
}
-//--------------------------------------------------------------------------
+
Sequence< sal_Int8 > ODBTable::getImplementationId() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::getImplementationId" );
@@ -174,7 +174,6 @@ Sequence< sal_Int8 > ODBTable::getImplementationId() throw (RuntimeException)
}
// OComponentHelper
-//------------------------------------------------------------------------------
void SAL_CALL ODBTable::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::disposing" );
@@ -185,7 +184,6 @@ void SAL_CALL ODBTable::disposing()
m_pColumnMediator = NULL;
}
-//------------------------------------------------------------------------------
void ODBTable::getFastPropertyValue(Any& _rValue, sal_Int32 _nHandle) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::getFastPropertyValue" );
@@ -196,7 +194,7 @@ void ODBTable::getFastPropertyValue(Any& _rValue, sal_Int32 _nHandle) const
OTable_Base::getFastPropertyValue(_rValue, _nHandle);
}
-// -------------------------------------------------------------------------
+
void ODBTable::construct()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::construct" );
@@ -257,7 +255,7 @@ void ODBTable::construct()
refreshColumns();
}
-// -----------------------------------------------------------------------------
+
::cppu::IPropertyArrayHelper* ODBTable::createArrayHelper( sal_Int32 _nId) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::createArrayHelper" );
@@ -282,15 +280,15 @@ void ODBTable::construct()
return new ::cppu::OPropertyArrayHelper(aProps);
}
-// -----------------------------------------------------------------------------
+
::cppu::IPropertyArrayHelper & SAL_CALL ODBTable::getInfoHelper()
{
return *ODBTable_PROP::getArrayHelper(isNew() ? 1 : 0);
}
-// -------------------------------------------------------------------------
+
// XServiceInfo
IMPLEMENT_SERVICE_INFO1(ODBTable, "com.sun.star.sdb.dbaccess.ODBTable", SERVICE_SDBCX_TABLE)
-// -------------------------------------------------------------------------
+
Any SAL_CALL ODBTable::queryInterface( const Type & rType ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::getInfoHelper" );
@@ -300,7 +298,7 @@ Any SAL_CALL ODBTable::queryInterface( const Type & rType ) throw(RuntimeExcepti
return Any();
return OTable_Base::queryInterface( rType);
}
-// -------------------------------------------------------------------------
+
Sequence< Type > SAL_CALL ODBTable::getTypes( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::getTypes" );
@@ -322,8 +320,8 @@ Sequence< Type > SAL_CALL ODBTable::getTypes( ) throw(RuntimeException)
Type* pTypes = aOwnTypes.empty() ? 0 : &aOwnTypes[0];
return Sequence< Type >(pTypes, aOwnTypes.size());
}
+
// XRename,
-//------------------------------------------------------------------------------
void SAL_CALL ODBTable::rename( const ::rtl::OUString& _rNewName ) throw(SQLException, ElementExistException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::rename" );
@@ -338,7 +336,6 @@ void SAL_CALL ODBTable::rename( const ::rtl::OUString& _rNewName ) throw(SQLExce
}
// XAlterTable,
-//------------------------------------------------------------------------------
void SAL_CALL ODBTable::alterColumnByName( const ::rtl::OUString& _rName, const Reference< XPropertySet >& _rxDescriptor ) throw(SQLException, NoSuchElementException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::alterColumnByName" );
@@ -354,7 +351,7 @@ void SAL_CALL ODBTable::alterColumnByName( const ::rtl::OUString& _rName, const
getAlterService()->alterColumnByName(xTable,_rName,_rxDescriptor);
m_pColumns->refresh();
}
-// -----------------------------------------------------------------------------
+
sal_Int64 SAL_CALL ODBTable::getSomething( const Sequence< sal_Int8 >& rId ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::getSomething" );
@@ -366,7 +363,7 @@ sal_Int64 SAL_CALL ODBTable::getSomething( const Sequence< sal_Int8 >& rId ) thr
return nRet;
}
-// -----------------------------------------------------------------------------
+
Sequence< sal_Int8 > ODBTable::getUnoTunnelImplementationId()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::getUnoTunnelImplementationId" );
@@ -382,13 +379,13 @@ Sequence< sal_Int8 > ODBTable::getUnoTunnelImplementationId()
}
return pId->getImplementationId();
}
-// -----------------------------------------------------------------------------
+
Reference< XPropertySet > ODBTable::createColumnDescriptor()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::createColumnDescriptor" );
return new OTableColumnDescriptor( true );
}
-// -----------------------------------------------------------------------------
+
sdbcx::OCollection* ODBTable::createColumns(const TStringVector& _rNames)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::createColumns" );
@@ -402,16 +399,16 @@ sdbcx::OCollection* ODBTable::createColumns(const TStringVector& _rNames)
pCol->setMediator( m_pColumnMediator.get() );
return pCol;
}
-// -----------------------------------------------------------------------------
+
sdbcx::OCollection* ODBTable::createKeys(const TStringVector& _rNames)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::createKeys" );
return new connectivity::OKeysHelper(this,m_aMutex,_rNames);
}
-// -----------------------------------------------------------------------------
+
sdbcx::OCollection* ODBTable::createIndexes(const TStringVector& _rNames)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "ODBTable::createIndexes" );
return new OIndexes(this,m_aMutex,_rNames,NULL);
}
-// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/tablecontainer.cxx b/dbaccess/source/core/api/tablecontainer.cxx
index 76d6ac063441..9c497708c93c 100644
--- a/dbaccess/source/core/api/tablecontainer.cxx
+++ b/dbaccess/source/core/api/tablecontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,12 +61,8 @@
#include "objectnameapproval.hxx"
#include <tools/string.hxx>
#include <rtl/logfile.hxx>
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
using namespace dbaccess;
using namespace dbtools;
@@ -99,9 +96,9 @@ namespace
if ( aState != PropertyState_DEFAULT_VALUE )
break;
}
- catch(Exception)
+ catch(const Exception&)
{
- OSL_ENSURE( 0, "lcl_isPropertySetDefaulted: Exception caught!" );
+ OSL_FAIL( "lcl_isPropertySetDefaulted: Exception caught!" );
}
}
return ( pIter == pEnd );
@@ -113,7 +110,7 @@ namespace
//= OTableContainer
//==========================================================================
DBG_NAME(OTableContainer)
-//------------------------------------------------------------------------------
+
OTableContainer::OTableContainer(::cppu::OWeakObject& _rParent,
::osl::Mutex& _rMutex,
const Reference< XConnection >& _xCon,
@@ -130,15 +127,12 @@ OTableContainer::OTableContainer(::cppu::OWeakObject& _rParent,
DBG_CTOR(OTableContainer, NULL);
}
-//------------------------------------------------------------------------------
OTableContainer::~OTableContainer()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::OTableContainer" );
- // dispose();
DBG_DTOR(OTableContainer, NULL);
}
-// -----------------------------------------------------------------------------
void OTableContainer::removeMasterContainerListener()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::removeMasterContainerListener" );
@@ -153,19 +147,15 @@ void OTableContainer::removeMasterContainerListener()
}
}
-// -----------------------------------------------------------------------------
::rtl::OUString OTableContainer::getTableTypeRestriction() const
{
// no restriction at all (other than the ones provided externally)
return ::rtl::OUString();
}
-// -----------------------------------------------------------------------------
// XServiceInfo
-//------------------------------------------------------------------------------
IMPLEMENT_SERVICE_INFO2(OTableContainer, "com.sun.star.sdb.dbaccess.OTableContainer", SERVICE_SDBCX_CONTAINER, SERVICE_SDBCX_TABLES)
-// -----------------------------------------------------------------------------
namespace
{
void lcl_createDefintionObject(const ::rtl::OUString& _rName
@@ -195,9 +185,9 @@ void lcl_createDefintionObject(const ::rtl::OUString& _rName
_xColumnDefinitions = xColumnsSupplier->getColumns();
}
}
-// -------------------------------------------------------------------------
+
}
-// -------------------------------------------------------------------------
+
connectivity::sdbcx::ObjectType OTableContainer::createObject(const ::rtl::OUString& _rName)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::createObject" );
@@ -269,14 +259,14 @@ connectivity::sdbcx::ObjectType OTableContainer::createObject(const ::rtl::OUStr
return xRet;
}
-// -----------------------------------------------------------------------------
+
Reference< XPropertySet > OTableContainer::createDescriptor()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::createDescriptor" );
Reference< XPropertySet > xRet;
- // frist we have to look if the master tables does support this
- // and if then create a table object as well with the master tables
+ // first we have to look if the master tables support this
+ // and if so then create a table object as well with the master tables
Reference<XColumnsSupplier > xMasterColumnsSup;
Reference<XDataDescriptorFactory> xDataFactory(m_xMasterContainer,UNO_QUERY);
if ( xDataFactory.is() && m_xMetaData.is() )
@@ -294,7 +284,7 @@ Reference< XPropertySet > OTableContainer::createDescriptor()
}
return xRet;
}
-// -----------------------------------------------------------------------------
+
// XAppend
ObjectType OTableContainer::appendObject( const ::rtl::OUString& _rForName, const Reference< XPropertySet >& descriptor )
{
@@ -335,7 +325,7 @@ ObjectType OTableContainer::appendObject( const ::rtl::OUString& _rForName, cons
}
}
}
- catch(Exception&)
+ catch(const Exception&)
{
throw;
}
@@ -376,13 +366,13 @@ ObjectType OTableContainer::appendObject( const ::rtl::OUString& _rForName, cons
, ::rtl::OUString(PROPERTY_ROW_HEIGHT), ::rtl::OUString(PROPERTY_TEXTCOLOR)
, ::rtl::OUString(PROPERTY_TEXTLINECOLOR), ::rtl::OUString(PROPERTY_TEXTEMPHASIS)
, ::rtl::OUString(PROPERTY_TEXTRELIEF) };
- Sequence< ::rtl::OUString> aNames(s_pTableProps,sizeof(s_pTableProps)/sizeof(s_pTableProps[0]));
+ Sequence< ::rtl::OUString> aNames(s_pTableProps,SAL_N_ELEMENTS(s_pTableProps));
if ( bModified || !lcl_isPropertySetDefaulted(aNames,xTableDefinition) )
::dbaccess::notifyDataSourceModified(m_xTableDefinitions,sal_True);
return createObject( _rForName );
}
-// -------------------------------------------------------------------------
+
// XDrop
void OTableContainer::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName)
{
@@ -417,9 +407,8 @@ void OTableContainer::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElement
if(!sComposedName.getLength())
::dbtools::throwFunctionSequenceException(static_cast<XTypeProvider*>(static_cast<OFilteredContainer*>(this)));
- ::rtl::OUString aSql = ::rtl::OUString::createFromAscii("DROP ");
+ ::rtl::OUString aSql(RTL_CONSTASCII_USTRINGPARAM("DROP "));
- // #104282# OJ
if ( bIsView ) // here we have a view
aSql += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VIEW "));
else
@@ -441,14 +430,14 @@ void OTableContainer::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElement
m_xTableDefinitions->removeByName(_sElementName);
}
}
- catch(Exception&)
+ catch(const Exception&)
{
m_bInDrop = sal_False;
throw;
}
m_bInDrop = sal_False;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OTableContainer::elementInserted( const ContainerEvent& Event ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::elementInserted" );
@@ -467,12 +456,12 @@ void SAL_CALL OTableContainer::elementInserted( const ContainerEvent& Event ) th
}
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OTableContainer::elementRemoved( const ContainerEvent& /*Event*/ ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::elementRemoved" );
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OTableContainer::elementReplaced( const ContainerEvent& Event ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::elementReplaced" );
@@ -485,22 +474,21 @@ void SAL_CALL OTableContainer::elementReplaced( const ContainerEvent& Event ) th
renameObject(sOldComposedName,sNewComposedName);
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OTableContainer::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::disposing" );
OFilteredContainer::disposing();
- // say our listeners goobye
+ // say goodbye to our listeners
m_xTableDefinitions = NULL;
m_pTableMediator = NULL;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OTableContainer::disposing( const ::com::sun::star::lang::EventObject& /*Source*/ ) throw (::com::sun::star::uno::RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "api", "Ocke.Janssen@sun.com", "OTableContainer::disposing" );
}
-// -----------------------------------------------------------------------------
void OTableContainer::addMasterContainerListener()
{
try
@@ -513,4 +501,4 @@ void OTableContainer::addMasterContainerListener()
DBG_UNHANDLED_EXCEPTION();
}
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/api/viewcontainer.cxx b/dbaccess/source/core/api/viewcontainer.cxx
index 0fc2542bfa4a..7cae5e38e1ce 100644
--- a/dbaccess/source/core/api/viewcontainer.cxx
+++ b/dbaccess/source/core/api/viewcontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,7 +73,7 @@ using namespace ::connectivity::sdbcx;
//= OViewContainer
//==========================================================================
DBG_NAME(OViewContainer)
-//------------------------------------------------------------------------------
+
OViewContainer::OViewContainer(::cppu::OWeakObject& _rParent
,::osl::Mutex& _rMutex
,const Reference< XConnection >& _xCon
@@ -86,17 +87,14 @@ OViewContainer::OViewContainer(::cppu::OWeakObject& _rParent
DBG_CTOR(OViewContainer, NULL);
}
-//------------------------------------------------------------------------------
OViewContainer::~OViewContainer()
{
- // dispose();
DBG_DTOR(OViewContainer, NULL);
}
-//------------------------------------------------------------------------------
+
// XServiceInfo
-//------------------------------------------------------------------------------
IMPLEMENT_SERVICE_INFO2(OViewContainer, "com.sun.star.sdb.dbaccess.OViewContainer", SERVICE_SDBCX_CONTAINER, SERVICE_SDBCX_TABLES)
-// -----------------------------------------------------------------------------
+
ObjectType OViewContainer::createObject(const ::rtl::OUString& _rName)
{
ObjectType xProp;
@@ -122,12 +120,12 @@ ObjectType OViewContainer::createObject(const ::rtl::OUString& _rName)
return xProp;
}
-// -----------------------------------------------------------------------------
+
Reference< XPropertySet > OViewContainer::createDescriptor()
{
Reference< XPropertySet > xRet;
- // frist we have to look if the master tables does support this
- // and if then create a table object as well with the master tables
+ // first we have to look if the master tables support this
+ // and if so then create a table object as well with the master tables
Reference<XColumnsSupplier > xMasterColumnsSup;
Reference<XDataDescriptorFactory> xDataFactory(m_xMasterContainer,UNO_QUERY);
if(xDataFactory.is())
@@ -137,7 +135,7 @@ Reference< XPropertySet > OViewContainer::createDescriptor()
return xRet;
}
-// -----------------------------------------------------------------------------
+
// XAppend
ObjectType OViewContainer::appendObject( const ::rtl::OUString& _rForName, const Reference< XPropertySet >& descriptor )
{
@@ -181,7 +179,7 @@ ObjectType OViewContainer::appendObject( const ::rtl::OUString& _rForName, const
return createObject( _rForName );
}
-// -------------------------------------------------------------------------
+
// XDrop
void OViewContainer::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementName)
{
@@ -207,7 +205,7 @@ void OViewContainer::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementN
if(!sComposedName.getLength())
::dbtools::throwFunctionSequenceException(static_cast<XTypeProvider*>(static_cast<OFilteredContainer*>(this)));
- ::rtl::OUString aSql = ::rtl::OUString::createFromAscii("DROP VIEW ");
+ ::rtl::OUString aSql(RTL_CONSTASCII_USTRINGPARAM("DROP VIEW "));
aSql += sComposedName;
Reference<XConnection> xCon = m_xConnection;
OSL_ENSURE(xCon.is(),"Connection is null!");
@@ -221,7 +219,7 @@ void OViewContainer::dropObject(sal_Int32 _nPos,const ::rtl::OUString _sElementN
}
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OViewContainer::elementInserted( const ContainerEvent& Event ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_rMutex);
@@ -238,7 +236,7 @@ void SAL_CALL OViewContainer::elementInserted( const ContainerEvent& Event ) thr
insertElement(sName,createObject(sName));
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OViewContainer::elementRemoved( const ContainerEvent& Event ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_rMutex);
@@ -258,17 +256,19 @@ void SAL_CALL OViewContainer::elementRemoved( const ContainerEvent& Event ) thro
m_bInElementRemoved = false;
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OViewContainer::disposing( const ::com::sun::star::lang::EventObject& /*Source*/ ) throw (RuntimeException)
{
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OViewContainer::elementReplaced( const ContainerEvent& /*Event*/ ) throw (RuntimeException)
{
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OViewContainer::getTableTypeRestriction() const
{
// no restriction at all (other than the ones provided externally)
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "VIEW" ) );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/ComponentDefinition.cxx b/dbaccess/source/core/dataaccess/ComponentDefinition.cxx
index 10361a3aa280..2a5d15388a65 100644
--- a/dbaccess/source/core/dataaccess/ComponentDefinition.cxx
+++ b/dbaccess/source/core/dataaccess/ComponentDefinition.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,35 +29,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBA_COREDATAACESS_COMPONENTDEFINITION_HXX
#include "ComponentDefinition.hxx"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
#include "module_dba.hxx"
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
+#include <osl/diagnose.h>
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _DBACORE_DEFINITIONCOLUMN_HXX_
#include "definitioncolumn.hxx"
-#endif
#include <cppuhelper/implbase1.hxx>
#include <comphelper/componentcontext.hxx>
@@ -75,10 +59,9 @@ extern "C" void SAL_CALL createRegistryInfo_OComponentDefinition()
static ::dba::OAutoRegistration< ::dbaccess::OComponentDefinition > aAutoRegistration;
}
-//........................................................................
namespace dbaccess
{
-//........................................................................
+
/// helper class for column property change events which holds the OComponentDefinition weak
typedef ::cppu::WeakImplHelper1 < XPropertyChangeListener > TColumnPropertyListener_BASE;
class OColumnPropertyListener : public TColumnPropertyListener_BASE
@@ -108,7 +91,7 @@ OComponentDefinition_Impl::OComponentDefinition_Impl()
{
DBG_CTOR(OComponentDefinition_Impl,NULL);
}
-// -----------------------------------------------------------------------------
+
OComponentDefinition_Impl::~OComponentDefinition_Impl()
{
DBG_DTOR(OComponentDefinition_Impl,NULL);
@@ -116,9 +99,9 @@ OComponentDefinition_Impl::~OComponentDefinition_Impl()
//==========================================================================
//= OComponentDefinition
//==========================================================================
-//--------------------------------------------------------------------------
+
DBG_NAME(OComponentDefinition)
-//--------------------------------------------------------------------------
+
void OComponentDefinition::registerProperties()
{
m_xColumnPropertyListener = ::comphelper::ImplementationReference<OColumnPropertyListener,XPropertyChangeListener>(new OColumnPropertyListener(this));
@@ -138,7 +121,6 @@ void OComponentDefinition::registerProperties()
}
}
-//--------------------------------------------------------------------------
OComponentDefinition::OComponentDefinition(const Reference< XMultiServiceFactory >& _xORB
,const Reference< XInterface >& _xParentContainer
,const TContentPtr& _pImpl
@@ -150,13 +132,13 @@ OComponentDefinition::OComponentDefinition(const Reference< XMultiServiceFactory
DBG_CTOR(OComponentDefinition, NULL);
registerProperties();
}
-//--------------------------------------------------------------------------
+
OComponentDefinition::~OComponentDefinition()
{
DBG_DTOR(OComponentDefinition, NULL);
}
-//--------------------------------------------------------------------------
+
OComponentDefinition::OComponentDefinition( const Reference< XInterface >& _rxContainer
,const ::rtl::OUString& _rElementName
,const Reference< XMultiServiceFactory >& _xORB
@@ -170,26 +152,23 @@ OComponentDefinition::OComponentDefinition( const Reference< XInterface >& _rxCo
registerProperties();
m_pImpl->m_aProps.aTitle = _rElementName;
- DBG_ASSERT(m_pImpl->m_aProps.aTitle.getLength() != 0, "OComponentDefinition::OComponentDefinition : invalid name !");
+ OSL_ENSURE(m_pImpl->m_aProps.aTitle.getLength() != 0, "OComponentDefinition::OComponentDefinition : invalid name !");
}
-//--------------------------------------------------------------------------
IMPLEMENT_IMPLEMENTATION_ID(OComponentDefinition);
IMPLEMENT_GETTYPES3(OComponentDefinition,ODataSettings,OContentHelper,OComponentDefinition_BASE);
IMPLEMENT_FORWARD_XINTERFACE3( OComponentDefinition,OContentHelper,ODataSettings,OComponentDefinition_BASE)
-//--------------------------------------------------------------------------
+
::rtl::OUString OComponentDefinition::getImplementationName_static( ) throw(RuntimeException)
{
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dba.OComponentDefinition"));
}
-//--------------------------------------------------------------------------
::rtl::OUString SAL_CALL OComponentDefinition::getImplementationName( ) throw(RuntimeException)
{
return getImplementationName_static();
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > OComponentDefinition::getSupportedServiceNames_static( ) throw(RuntimeException)
{
Sequence< ::rtl::OUString > aServices(2);
@@ -199,18 +178,17 @@ Sequence< ::rtl::OUString > OComponentDefinition::getSupportedServiceNames_stati
return aServices;
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL OComponentDefinition::getSupportedServiceNames( ) throw(RuntimeException)
{
return getSupportedServiceNames_static();
}
-//------------------------------------------------------------------------------
+
Reference< XInterface > OComponentDefinition::Create( const Reference< XComponentContext >& _rxContext )
{
::comphelper::ComponentContext aContext( _rxContext );
return *(new OComponentDefinition( aContext.getLegacyServiceFactory(), NULL, TContentPtr( new OComponentDefinition_Impl ) ) );
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OComponentDefinition::disposing()
{
OContentHelper::disposing();
@@ -219,26 +197,25 @@ void SAL_CALL OComponentDefinition::disposing()
m_xColumnPropertyListener->clear();
m_xColumnPropertyListener.dispose();
}
-// -----------------------------------------------------------------------------
+
IPropertyArrayHelper& OComponentDefinition::getInfoHelper()
{
return *getArrayHelper();
}
-//--------------------------------------------------------------------------
+
IPropertyArrayHelper* OComponentDefinition::createArrayHelper( ) const
{
Sequence< Property > aProps;
describeProperties(aProps);
return new OPropertyArrayHelper(aProps);
}
-//--------------------------------------------------------------------------
+
Reference< XPropertySetInfo > SAL_CALL OComponentDefinition::getPropertySetInfo( ) throw(RuntimeException)
{
Reference<XPropertySetInfo> xInfo( createPropertySetInfo( getInfoHelper() ) );
return xInfo;
}
-// -----------------------------------------------------------------------------
::rtl::OUString OComponentDefinition::determineContentType() const
{
return m_bTable
@@ -246,7 +223,6 @@ Reference< XPropertySetInfo > SAL_CALL OComponentDefinition::getPropertySetInfo(
: ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "application/vnd.org.openoffice.DatabaseCommandDefinition" ) );
}
-// -----------------------------------------------------------------------------
Reference< XNameAccess> OComponentDefinition::getColumns() throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
@@ -269,7 +245,7 @@ Reference< XNameAccess> OComponentDefinition::getColumns() throw (RuntimeExcepti
}
return m_pColumns.get();
}
-// -----------------------------------------------------------------------------
+
OColumn* OComponentDefinition::createColumn(const ::rtl::OUString& _rName) const
{
const OComponentDefinition_Impl& rDefinition( getDefinition() );
@@ -279,28 +255,28 @@ OColumn* OComponentDefinition::createColumn(const ::rtl::OUString& _rName) const
aFind->second->addPropertyChangeListener(::rtl::OUString(),m_xColumnPropertyListener.getRef());
return new OTableColumnWrapper( aFind->second, aFind->second, true );
}
- OSL_ENSURE( false, "OComponentDefinition::createColumn: is this a valid case?" );
+ OSL_FAIL( "OComponentDefinition::createColumn: is this a valid case?" );
// This here is the last place creating a OTableColumn, and somehow /me thinks it is not needed ...
return new OTableColumn( _rName );
}
-// -----------------------------------------------------------------------------
+
Reference< XPropertySet > OComponentDefinition::createColumnDescriptor()
{
return new OTableColumnDescriptor( true );
}
-// -----------------------------------------------------------------------------
+
void OComponentDefinition::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception)
{
ODataSettings::setFastPropertyValue_NoBroadcast(nHandle,rValue);
notifyDataSourceModified();
}
-// -----------------------------------------------------------------------------
+
void OComponentDefinition::columnDropped(const ::rtl::OUString& _sName)
{
getDefinition().erase( _sName );
notifyDataSourceModified();
}
-// -----------------------------------------------------------------------------
+
void OComponentDefinition::columnAppended( const Reference< XPropertySet >& _rxSourceDescriptor )
{
::rtl::OUString sName;
@@ -322,7 +298,5 @@ void OComponentDefinition::columnAppended( const Reference< XPropertySet >& _rxS
notifyDataSourceModified();
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/ComponentDefinition.hxx b/dbaccess/source/core/dataaccess/ComponentDefinition.hxx
index 834e7a9979fa..0eba07a61dd4 100644
--- a/dbaccess/source/core/dataaccess/ComponentDefinition.hxx
+++ b/dbaccess/source/core/dataaccess/ComponentDefinition.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,45 +29,19 @@
#ifndef DBA_COREDATAACESS_COMPONENTDEFINITION_HXX
#define DBA_COREDATAACESS_COMPONENTDEFINITION_HXX
-#ifndef _DBA_CORE_COMMANDBASE_HXX_
#include "commandbase.hxx"
-#endif
-#ifndef _COMPHELPER_PROPERTYCONTAINER_HXX_
#include <comphelper/propertycontainer.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XRENAME_HPP_
#include <com/sun/star/sdbcx/XRename.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _DBA_CORE_DATASETTINGS_HXX_
#include "datasettings.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYCHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertyChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_XCOMPONENTCONTEXT_HPP_
#include <com/sun/star/uno/XComponentContext.hpp>
-#endif
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DBA_COREAPI_COLUMN_HXX_
#include <column.hxx>
-#endif
#include <comphelper/implementationreference.hxx>
#include <memory>
@@ -205,3 +180,5 @@ private:
//........................................................................
#endif // DBA_COREDATAACESS_COMPONENTDEFINITION_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/ContentHelper.cxx b/dbaccess/source/core/dataaccess/ContentHelper.cxx
index 3ed2649caabe..dd3082aa157f 100644
--- a/dbaccess/source/core/dataaccess/ContentHelper.cxx
+++ b/dbaccess/source/core/dataaccess/ContentHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,54 +28,22 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
-#ifndef _UCBHELPER_CANCELCOMMANDEXECUTION_HXX_
#include <ucbhelper/cancelcommandexecution.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UCB_UNSUPPORTEDCOMMANDEXCEPTION_HPP_
#include <com/sun/star/ucb/UnsupportedCommandException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_ILLEGALARGUMENTEXCEPTION_HPP_
#include <com/sun/star/lang/IllegalArgumentException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_ILLEGALACCESSEXCEPTION_HPP_
#include <com/sun/star/lang/IllegalAccessException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XOUTPUTSTREAM_HPP_
#include <com/sun/star/io/XOutputStream.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XACTIVEDATASINK_HPP_
#include <com/sun/star/io/XActiveDataSink.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _UCBHELPER_PROPERTYVALUESET_HXX
#include <ucbhelper/propertyvalueset.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENTIDENTIFIER_HXX
#include <ucbhelper/contentidentifier.hxx>
-#endif
-#ifndef DBA_UCPRESULTSET_HXX
#include "myucp_resultset.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef DBACORE_SDBCORETOOLS_HXX
#include "sdbcoretools.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaccess
@@ -91,18 +60,16 @@ using namespace ::com::sun::star::container;
using namespace ::comphelper;
using namespace ::cppu;
-// -----------------------------------------------------------------------------
DBG_NAME(OContentHelper_Impl)
OContentHelper_Impl::OContentHelper_Impl()
{
DBG_CTOR(OContentHelper_Impl,NULL);
}
-// -----------------------------------------------------------------------------
+
OContentHelper_Impl::~OContentHelper_Impl()
{
DBG_DTOR(OContentHelper_Impl,NULL);
}
-// -----------------------------------------------------------------------------
OContentHelper::OContentHelper(const Reference< XMultiServiceFactory >& _xORB
,const Reference< XInterface >& _xParentContainer
@@ -117,21 +84,21 @@ OContentHelper::OContentHelper(const Reference< XMultiServiceFactory >& _xORB
,m_nCommandId(0)
{
}
-//--------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::disposing()
{
::osl::MutexGuard aGuard(m_aMutex);
- // say our listeners goobye
+ // say goodbye to our listeners
EventObject aEvt(*this);
m_aContentListeners.disposeAndClear(aEvt);
m_xParentContainer = NULL;
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_SERVICE_INFO1(OContentHelper,"com.sun.star.comp.sdb.Content","com.sun.star.ucb.Content");
IMPLEMENT_IMPLEMENTATION_ID(OContentHelper)
-// -----------------------------------------------------------------------------
+
// XContent
Reference< XContentIdentifier > SAL_CALL OContentHelper::getIdentifier( ) throw (RuntimeException)
{
@@ -141,7 +108,7 @@ Reference< XContentIdentifier > SAL_CALL OContentHelper::getIdentifier( ) throw
aIdentifier.append( impl_getHierarchicalName( true ) );
return new ::ucbhelper::ContentIdentifier( m_aContext.getLegacyServiceFactory(), aIdentifier.makeStringAndClear() );
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString OContentHelper::impl_getHierarchicalName( bool _includingRootContainer ) const
{
::rtl::OUStringBuffer aHierarchicalName( m_pImpl->m_aProps.aTitle );
@@ -168,7 +135,6 @@ Reference< XContentIdentifier > SAL_CALL OContentHelper::getIdentifier( ) throw
return sHierarchicalName;
}
-// -----------------------------------------------------------------------------
::rtl::OUString SAL_CALL OContentHelper::getContentType() throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
@@ -180,21 +146,20 @@ Reference< XContentIdentifier > SAL_CALL OContentHelper::getIdentifier( ) throw
return *m_pImpl->m_aProps.aContentType;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::addContentEventListener( const Reference< XContentEventListener >& _rxListener ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
if ( _rxListener.is() )
m_aContentListeners.addInterface(_rxListener);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::removeContentEventListener( const Reference< XContentEventListener >& _rxListener ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
if (_rxListener.is())
m_aContentListeners.removeInterface(_rxListener);
}
-// -----------------------------------------------------------------------------
// XCommandProcessor
sal_Int32 SAL_CALL OContentHelper::createCommandIdentifier( ) throw (RuntimeException)
@@ -203,7 +168,7 @@ sal_Int32 SAL_CALL OContentHelper::createCommandIdentifier( ) throw (RuntimeExc
// Just increase counter on every call to generate an identifier.
return ++m_nCommandId;
}
-// -----------------------------------------------------------------------------
+
Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*CommandId*/, const Reference< XCommandEnvironment >& Environment ) throw (Exception, CommandAbortedException, RuntimeException)
{
Any aRet;
@@ -216,7 +181,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
Sequence< Property > Properties;
if ( !( aCommand.Argument >>= Properties ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -236,7 +201,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
Sequence< PropertyValue > aProperties;
if ( !( aCommand.Argument >>= aProperties ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -248,7 +213,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
if ( !aProperties.getLength() )
{
- OSL_ENSURE( sal_False, "No properties!" );
+ OSL_FAIL( "No properties!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -277,7 +242,7 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
// Unsupported command
//////////////////////////////////////////////////////////////////
- OSL_ENSURE( sal_False, "Content::execute - unsupported command!" );
+ OSL_FAIL( "Content::execute - unsupported command!" );
ucbhelper::cancelCommandExecution(
makeAny( UnsupportedCommandException(
@@ -289,11 +254,10 @@ Any SAL_CALL OContentHelper::execute( const Command& aCommand, sal_Int32 /*Comma
return aRet;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::abort( sal_Int32 /*CommandId*/ ) throw (RuntimeException)
{
}
-// -----------------------------------------------------------------------------
// XPropertiesChangeNotifier
void SAL_CALL OContentHelper::addPropertiesChangeListener( const Sequence< ::rtl::OUString >& PropertyNames, const Reference< XPropertiesChangeListener >& Listener ) throw (RuntimeException)
@@ -317,7 +281,7 @@ void SAL_CALL OContentHelper::addPropertiesChangeListener( const Sequence< ::rtl
}
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::removePropertiesChangeListener( const Sequence< ::rtl::OUString >& PropertyNames, const Reference< XPropertiesChangeListener >& Listener ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
@@ -339,19 +303,18 @@ void SAL_CALL OContentHelper::removePropertiesChangeListener( const Sequence< ::
}
}
}
-// -----------------------------------------------------------------------------
// XPropertyContainer
void SAL_CALL OContentHelper::addProperty( const ::rtl::OUString& /*Name*/, sal_Int16 /*Attributes*/, const Any& /*DefaultValue*/ ) throw (PropertyExistException, IllegalTypeException, IllegalArgumentException, RuntimeException)
{
- DBG_ERROR( "OContentHelper::addProperty: not implemented!" );
+ OSL_FAIL( "OContentHelper::addProperty: not implemented!" );
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::removeProperty( const ::rtl::OUString& /*Name*/ ) throw (UnknownPropertyException, NotRemoveableException, RuntimeException)
{
- DBG_ERROR( "OContentHelper::removeProperty: not implemented!" );
+ OSL_FAIL( "OContentHelper::removeProperty: not implemented!" );
}
-// -----------------------------------------------------------------------------
+
// XInitialization
void SAL_CALL OContentHelper::initialize( const Sequence< Any >& _aArguments ) throw(Exception, RuntimeException)
{
@@ -361,7 +324,7 @@ void SAL_CALL OContentHelper::initialize( const Sequence< Any >& _aArguments ) t
for(;pBegin != pEnd;++pBegin)
{
*pBegin >>= aValue;
- if ( aValue.Name.equalsAscii("Parent") )
+ if ( aValue.Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Parent")) )
{
m_xParentContainer.set(aValue.Value,UNO_QUERY);
}
@@ -375,7 +338,7 @@ void SAL_CALL OContentHelper::initialize( const Sequence< Any >& _aArguments ) t
}
}
}
-// -----------------------------------------------------------------------------
+
Sequence< Any > OContentHelper::setPropertyValues(const Sequence< PropertyValue >& rValues,const Reference< XCommandEnvironment >& /*xEnv*/ )
{
osl::ClearableGuard< osl::Mutex > aGuard( m_aMutex );
@@ -400,24 +363,27 @@ Sequence< Any > OContentHelper::setPropertyValues(const Sequence< PropertyValue
{
// Read-only property!
aRet[ n ] <<= IllegalAccessException(
- rtl::OUString::createFromAscii(
- "Property is read-only!" ),
+ ::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("Property is read-only!")
+ ),
static_cast< cppu::OWeakObject * >( this ) );
}
else if ( rValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "IsDocument" ) ) )
{
// Read-only property!
aRet[ n ] <<= IllegalAccessException(
- rtl::OUString::createFromAscii(
- "Property is read-only!" ),
+ ::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("Property is read-only!")
+ ),
static_cast< cppu::OWeakObject * >( this ) );
}
else if ( rValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "IsFolder" ) ) )
{
// Read-only property!
aRet[ n ] <<= IllegalAccessException(
- rtl::OUString::createFromAscii(
- "Property is read-only!" ),
+ ::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("Property is read-only!")
+ ),
static_cast< cppu::OWeakObject * >( this ) );
}
else if ( rValue.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Title" ) ) )
@@ -441,7 +407,7 @@ Sequence< Any > OContentHelper::setPropertyValues(const Sequence< PropertyValue
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OContentHelper::setPropertyValues('Title'): caught an exception while renaming!" );
+ OSL_FAIL( "OContentHelper::setPropertyValues('Title'): caught an exception while renaming!" );
}
}
else
@@ -452,33 +418,25 @@ Sequence< Any > OContentHelper::setPropertyValues(const Sequence< PropertyValue
else
{
aRet[ n ] <<= IllegalTypeException(
- rtl::OUString::createFromAscii(
- "Property value has wrong type!" ),
+ ::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("Property value has wrong type!")
+ ),
static_cast< cppu::OWeakObject * >( this ) );
}
}
- // @@@ Process other properties supported directly.
-#if 0
- else if ( rValue.Name.equalsAsciiL(
- RTL_CONSTASCII_STRINGPARAM( "xxxxxx" ) ) )
- {
- }
-#endif
else
{
aRet[ n ] <<= Exception(
- rtl::OUString::createFromAscii(
- "No property set for storing the value!" ),
+ ::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("No property set for storing the value!")
+ ),
static_cast< cppu::OWeakObject * >( this ) );
}
}
if ( nChanged > 0 )
{
- // @@@ Save changes.
-// storeData();
-
notifyDataSourceModified();
aGuard.clear();
aChanges.realloc( nChanged );
@@ -487,7 +445,7 @@ Sequence< Any > OContentHelper::setPropertyValues(const Sequence< PropertyValue
return aRet;
}
-// -----------------------------------------------------------------------------
+
//=========================================================================
// static
Reference< XRow > OContentHelper::getPropertyValues( const Sequence< Property >& rProperties)
@@ -524,41 +482,33 @@ Reference< XRow > OContentHelper::getPropertyValues( const Sequence< Property >&
}
else
xRow->appendVoid(rProp);
-
- // @@@ Process other properties supported directly.
-#if 0
- else if ( rProp.Name.equalsAsciiL(
- RTL_CONSTASCII_STRINGPARAM( "xxxxxx" ) ) )
- {
- }
-#endif
}
}
else
{
// Append all Core Properties.
xRow->appendString (
- Property( rtl::OUString::createFromAscii( "ContentType" ),
+ Property( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ContentType")),
-1,
getCppuType( static_cast< const rtl::OUString * >( 0 ) ),
PropertyAttribute::BOUND
| PropertyAttribute::READONLY ),
getContentType() );
xRow->appendString (
- Property( rtl::OUString::createFromAscii( "Title" ),
+ Property( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Title" )),
-1,
getCppuType( static_cast< const rtl::OUString * >( 0 ) ),
PropertyAttribute::BOUND ),
m_pImpl->m_aProps.aTitle );
xRow->appendBoolean(
- Property( rtl::OUString::createFromAscii( "IsDocument" ),
+ Property( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsDocument")),
-1,
getCppuBooleanType(),
PropertyAttribute::BOUND
| PropertyAttribute::READONLY ),
m_pImpl->m_aProps.bIsDocument );
xRow->appendBoolean(
- Property( rtl::OUString::createFromAscii( "IsFolder" ),
+ Property( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsFolder")),
-1,
getCppuBooleanType(),
PropertyAttribute::BOUND
@@ -570,8 +520,7 @@ Reference< XRow > OContentHelper::getPropertyValues( const Sequence< Property >&
return Reference< XRow >( xRow.get() );
}
-// -----------------------------------------------------------------------------
-// -----------------------------------------------------------------------------
+
void OContentHelper::notifyPropertiesChange( const Sequence< PropertyChangeEvent >& evt ) const
{
@@ -596,7 +545,6 @@ void OContentHelper::notifyPropertiesChange( const Sequence< PropertyChangeEvent
typedef ::std::map< XPropertiesChangeListener*, PropertyEventSequence* > PropertiesEventListenerMap;
PropertiesEventListenerMap aListeners;
-
const PropertyChangeEvent* propertyChangeEvent = evt.getConstArray();
for ( sal_Int32 n = 0; n < nCount; ++n, ++propertyChangeEvent )
@@ -649,9 +597,8 @@ void OContentHelper::notifyPropertiesChange( const Sequence< PropertyChangeEvent
}
}
}
-// -----------------------------------------------------------------------------
+
// com::sun::star::lang::XUnoTunnel
-//------------------------------------------------------------------
sal_Int64 OContentHelper::getSomething( const Sequence< sal_Int8 > & rId ) throw (RuntimeException)
{
if (rId.getLength() == 16 && 0 == rtl_compareMemory(getUnoTunnelImplementationId().getConstArray(), rId.getConstArray(), 16 ) )
@@ -660,7 +607,6 @@ sal_Int64 OContentHelper::getSomething( const Sequence< sal_Int8 > & rId ) throw
return 0;
}
-// -----------------------------------------------------------------------------
OContentHelper* OContentHelper::getImplementation( const Reference< XInterface >& _rxComponent )
{
OContentHelper* pContent( NULL );
@@ -672,20 +618,18 @@ OContentHelper* OContentHelper::getImplementation( const Reference< XInterface >
return pContent;
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL OContentHelper::getParent( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
return m_xParentContainer;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::setParent( const Reference< XInterface >& _xParent ) throw (NoSupportException, RuntimeException)
{
::osl::MutexGuard aGuard(m_aMutex);
m_xParentContainer = _xParent;
}
-// -----------------------------------------------------------------------------
void OContentHelper::impl_rename_throw(const ::rtl::OUString& _sNewName,bool _bNotify )
{
osl::ClearableGuard< osl::Mutex > aGuard(m_aMutex);
@@ -714,49 +658,18 @@ void OContentHelper::impl_rename_throw(const ::rtl::OUString& _sNewName,bool _bN
throw ElementExistException(_sNewName,*this);
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OContentHelper::rename( const ::rtl::OUString& newName ) throw (SQLException, ElementExistException, RuntimeException)
{
impl_rename_throw(newName);
- //Reference<XNameContainer> xNameCont(m_xParentContainer,UNO_QUERY);
- //if ( xNameCont.is() )
- //{
- // if ( xNameCont->hasByName(newName) )
- // throw ElementExistException(newName,*this);
-
- // try
- // {
- // if ( xNameCont->hasByName(m_pImpl->m_aProps.aTitle) )
- // xNameCont->removeByName(m_pImpl->m_aProps.aTitle);
-
- // m_pImpl->m_aProps.aTitle = newName;
- // xNameCont->insertByName(m_pImpl->m_aProps.aTitle,makeAny(Reference<XContent>(*this,UNO_QUERY)));
- // notifyDataSourceModified();
- // }
- // catch(IllegalArgumentException)
- // {
- // throw SQLException();
- // }
- // catch(NoSuchElementException)
- // {
- // throw SQLException();
- // }
- // catch(WrappedTargetException)
- // {
- // throw SQLException();
- // }
- //}
- //else
- // m_pImpl->m_aProps.aTitle = newName;
}
-// -----------------------------------------------------------------------------
+
void OContentHelper::notifyDataSourceModified()
{
::dbaccess::notifyDataSourceModified(m_xParentContainer,sal_True);
}
-//........................................................................
-} // namespace dbaccess
-//........................................................................
+} // namespace dbaccess
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/ModelImpl.cxx b/dbaccess/source/core/dataaccess/ModelImpl.cxx
index ee50bea00dd0..fc754bb084d0 100644
--- a/dbaccess/source/core/dataaccess/ModelImpl.cxx
+++ b/dbaccess/source/core/dataaccess/ModelImpl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,6 +64,7 @@
#include <sfx2/signaturestate.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <tools/errcode.hxx>
#include <tools/urlobj.hxx>
#include <unotools/sharedunocomponent.hxx>
@@ -89,38 +91,31 @@ using namespace ::com::sun::star::reflection;
using namespace ::com::sun::star::script;
using namespace ::cppu;
using namespace ::osl;
-using namespace ::vos;
using namespace ::dbtools;
using namespace ::comphelper;
namespace css = ::com::sun::star;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//============================================================
//= VosMutexFacade
//============================================================
-//------------------------------------------------------------------------
VosMutexFacade::VosMutexFacade( ::osl::Mutex& _rMutex )
:m_rMutex( _rMutex )
{
}
-//------------------------------------------------------------------------
void SAL_CALL VosMutexFacade::acquire()
{
m_rMutex.acquire();
}
-//------------------------------------------------------------------------
sal_Bool SAL_CALL VosMutexFacade::tryToAcquire()
{
return m_rMutex.tryToAcquire();
}
-//------------------------------------------------------------------------
void SAL_CALL VosMutexFacade::release()
{
m_rMutex.release();
@@ -200,7 +195,6 @@ private:
};
-//--------------------------------------------------------------------------
void DocumentStorageAccess::dispose()
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -227,7 +221,6 @@ void DocumentStorageAccess::dispose()
m_pModelImplementation = NULL;
}
-//--------------------------------------------------------------------------
Reference< XStorage > DocumentStorageAccess::impl_openSubStorage_nothrow( const ::rtl::OUString& _rStorageName, sal_Int32 _nDesiredMode )
{
OSL_ENSURE( _rStorageName.getLength(),"ODatabaseModelImpl::impl_openSubStorage_nothrow: Invalid storage name!" );
@@ -261,7 +254,6 @@ Reference< XStorage > DocumentStorageAccess::impl_openSubStorage_nothrow( const
return xStorage;
}
-//--------------------------------------------------------------------------
void DocumentStorageAccess::disposeStorages()
{
m_bDisposingSubStorages = true;
@@ -286,7 +278,6 @@ void DocumentStorageAccess::disposeStorages()
m_bDisposingSubStorages = false;
}
-//--------------------------------------------------------------------------
void DocumentStorageAccess::commitStorages() SAL_THROW(( IOException, RuntimeException ))
{
try
@@ -306,7 +297,6 @@ void DocumentStorageAccess::commitStorages() SAL_THROW(( IOException, RuntimeExc
}
}
-//--------------------------------------------------------------------------
bool DocumentStorageAccess::commitEmbeddedStorage( bool _bPreventRootCommits )
{
if ( _bPreventRootCommits )
@@ -331,7 +321,6 @@ bool DocumentStorageAccess::commitEmbeddedStorage( bool _bPreventRootCommits )
}
-//--------------------------------------------------------------------------
Reference< XStorage > SAL_CALL DocumentStorageAccess::getDocumentSubStorage( const ::rtl::OUString& aStorageName, ::sal_Int32 _nDesiredMode ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -345,7 +334,6 @@ Reference< XStorage > SAL_CALL DocumentStorageAccess::getDocumentSubStorage( con
return pos->second;
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL DocumentStorageAccess::getDocumentSubStoragesNames( ) throw (IOException, RuntimeException)
{
Reference< XStorage > xRootStor( m_pModelImplementation->getRootStorage() );
@@ -366,13 +354,11 @@ Sequence< ::rtl::OUString > SAL_CALL DocumentStorageAccess::getDocumentSubStorag
: Sequence< ::rtl::OUString >( &aNames[0], aNames.size() );
}
-//--------------------------------------------------------------------------
void SAL_CALL DocumentStorageAccess::preCommit( const css::lang::EventObject& /*aEvent*/ ) throw (Exception, RuntimeException)
{
// not interested in
}
-//--------------------------------------------------------------------------
void SAL_CALL DocumentStorageAccess::commited( const css::lang::EventObject& aEvent ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -396,19 +382,16 @@ void SAL_CALL DocumentStorageAccess::commited( const css::lang::EventObject& aEv
}
}
-//--------------------------------------------------------------------------
void SAL_CALL DocumentStorageAccess::preRevert( const css::lang::EventObject& /*aEvent*/ ) throw (Exception, RuntimeException)
{
// not interested in
}
-//--------------------------------------------------------------------------
void SAL_CALL DocumentStorageAccess::reverted( const css::lang::EventObject& /*aEvent*/ ) throw (RuntimeException)
{
// not interested in
}
-//--------------------------------------------------------------------------
void SAL_CALL DocumentStorageAccess::disposing( const css::lang::EventObject& Source ) throw ( RuntimeException )
{
OSL_ENSURE( Reference< XStorage >( Source.Source, UNO_QUERY ).is(), "DocumentStorageAccess::disposing: No storage? What's this?" );
@@ -431,7 +414,7 @@ void SAL_CALL DocumentStorageAccess::disposing( const css::lang::EventObject& So
//= ODatabaseModelImpl
//============================================================
DBG_NAME(ODatabaseModelImpl)
-//--------------------------------------------------------------------------
+
ODatabaseModelImpl::ODatabaseModelImpl( const Reference< XMultiServiceFactory >& _rxFactory, ODatabaseContext& _rDBContext )
:m_xModel()
,m_xDataSource()
@@ -458,13 +441,12 @@ ODatabaseModelImpl::ODatabaseModelImpl( const Reference< XMultiServiceFactory >&
{
// some kind of default
DBG_CTOR(ODatabaseModelImpl,NULL);
- m_sConnectURL = ::rtl::OUString::createFromAscii("jdbc:");
+ m_sConnectURL = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("jdbc:"));
m_aTableFilter.realloc(1);
- m_aTableFilter[0] = ::rtl::OUString::createFromAscii("%");
+ m_aTableFilter[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("%"));
impl_construct_nothrow();
}
-//--------------------------------------------------------------------------
ODatabaseModelImpl::ODatabaseModelImpl(
const ::rtl::OUString& _rRegistrationName,
const Reference< XMultiServiceFactory >& _rxFactory,
@@ -498,13 +480,11 @@ ODatabaseModelImpl::ODatabaseModelImpl(
impl_construct_nothrow();
}
-//--------------------------------------------------------------------------
ODatabaseModelImpl::~ODatabaseModelImpl()
{
DBG_DTOR(ODatabaseModelImpl,NULL);
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::impl_construct_nothrow()
{
// create the property bag to hold the settings (also known as "Info" property)
@@ -565,10 +545,8 @@ void ODatabaseModelImpl::impl_construct_nothrow()
m_pDBContext->appendAtTerminateListener(*this);
}
-// -----------------------------------------------------------------------------
namespace
{
- // .........................................................................
::rtl::OUString lcl_getContainerStorageName_throw( ODatabaseModelImpl::ObjectType _eType )
{
const sal_Char* pAsciiName( NULL );
@@ -584,7 +562,6 @@ namespace
return ::rtl::OUString::createFromAscii( pAsciiName );
}
- // .........................................................................
bool lcl_hasObjectWithMacros_throw( const ODefinitionContainer_Impl& _rObjectDefinitions, const Reference< XStorage >& _rxContainerStorage )
{
bool bSomeDocHasMacros = false;
@@ -613,7 +590,6 @@ namespace
return bSomeDocHasMacros;
}
- // .........................................................................
bool lcl_hasObjectsWithMacros_nothrow( ODatabaseModelImpl& _rModel, const ODatabaseModelImpl::ObjectType _eType )
{
bool bSomeDocHasMacros = false;
@@ -647,7 +623,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
bool ODatabaseModelImpl::objectHasMacros( const Reference< XStorage >& _rxContainerStorage, const ::rtl::OUString& _rPersistentName )
{
OSL_PRECOND( _rxContainerStorage.is(), "ODatabaseModelImpl::objectHasMacros: this will crash!" );
@@ -670,7 +645,6 @@ bool ODatabaseModelImpl::objectHasMacros( const Reference< XStorage >& _rxContai
return bHasMacros;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::reset()
{
m_bReadOnly = sal_False;
@@ -684,7 +658,7 @@ void ODatabaseModelImpl::reset()
m_pStorageAccess = NULL;
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseModelImpl::disposing( const ::com::sun::star::lang::EventObject& Source ) throw(RuntimeException)
{
Reference<XConnection> xCon(Source.Source,UNO_QUERY);
@@ -707,10 +681,10 @@ void SAL_CALL ODatabaseModelImpl::disposing( const ::com::sun::star::lang::Event
}
else
{
- OSL_ENSURE( false, "ODatabaseModelImpl::disposing: where does this come from?" );
+ OSL_FAIL( "ODatabaseModelImpl::disposing: where does this come from?" );
}
}
-//------------------------------------------------------------------------------
+
void ODatabaseModelImpl::clearConnections()
{
OWeakConnectionArray aConnections;
@@ -737,7 +711,7 @@ void ODatabaseModelImpl::clearConnections()
m_pSharedConnectionManager = NULL;
m_xSharedConnectionManager = NULL;
}
-//------------------------------------------------------------------------------
+
void ODatabaseModelImpl::dispose()
{
// dispose the data source and the model
@@ -792,7 +766,7 @@ void ODatabaseModelImpl::dispose()
m_pStorageAccess = NULL;
}
}
-// -----------------------------------------------------------------------------
+
const Reference< XNumberFormatsSupplier > & ODatabaseModelImpl::getNumberFormatsSupplier()
{
if (!m_xNumberFormatsSupplier.is())
@@ -804,19 +778,17 @@ const Reference< XNumberFormatsSupplier > & ODatabaseModelImpl::getNumberFormats
m_xNumberFormatsSupplier.set(
m_aContext.createComponentWithArguments( "com.sun.star.util.NumberFormatsSupplier", aArguments ), UNO_QUERY_THROW );
- DBG_ASSERT(m_xNumberFormatsSupplier.is(), "ODatabaseModelImpl::getNumberFormatsSupplier : could not instantiate the formats supplier !");
+ OSL_ENSURE(m_xNumberFormatsSupplier.is(), "ODatabaseModelImpl::getNumberFormatsSupplier : could not instantiate the formats supplier !");
}
return m_xNumberFormatsSupplier;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::setDocFileLocation( const ::rtl::OUString& i_rLoadedFrom )
{
ENSURE_OR_THROW( i_rLoadedFrom.getLength(), "invalid URL" );
m_sDocFileLocation = i_rLoadedFrom;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::setResource( const ::rtl::OUString& i_rDocumentURL, const Sequence< PropertyValue >& _rArgs )
{
ENSURE_OR_THROW( i_rDocumentURL.getLength(), "invalid URL" );
@@ -841,7 +813,6 @@ void ODatabaseModelImpl::setResource( const ::rtl::OUString& i_rDocumentURL, con
impl_switchToLogicalURL( i_rDocumentURL );
}
-// -----------------------------------------------------------------------------
::comphelper::NamedValueCollection ODatabaseModelImpl::stripLoadArguments( const ::comphelper::NamedValueCollection& _rArguments )
{
OSL_ENSURE( !_rArguments.has( "Model" ), "ODatabaseModelImpl::stripLoadArguments: this is suspicious (1)!" );
@@ -853,18 +824,16 @@ void ODatabaseModelImpl::setResource( const ::rtl::OUString& i_rDocumentURL, con
return aMutableArgs;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::disposeStorages() SAL_THROW(())
{
getDocumentStorageAccess()->disposeStorages();
}
-// -----------------------------------------------------------------------------
Reference< XSingleServiceFactory > ODatabaseModelImpl::createStorageFactory() const
{
return Reference< XSingleServiceFactory >( m_aContext.createComponent( "com.sun.star.embed.StorageFactory" ), UNO_QUERY_THROW );
}
-// -----------------------------------------------------------------------------
+
void ODatabaseModelImpl::commitRootStorage()
{
Reference< XStorage > xStorage( getOrCreateRootStorage() );
@@ -875,7 +844,7 @@ void ODatabaseModelImpl::commitRootStorage()
OSL_ENSURE( bSuccess || !xStorage.is(),
"ODatabaseModelImpl::commitRootStorage: could commit the storage!" );
}
-// -----------------------------------------------------------------------------
+
Reference< XStorage > ODatabaseModelImpl::getOrCreateRootStorage()
{
if ( !m_xDocumentStorage.is() )
@@ -924,7 +893,7 @@ Reference< XStorage > ODatabaseModelImpl::getOrCreateRootStorage()
}
return m_xDocumentStorage.getTyped();
}
-// -----------------------------------------------------------------------------
+
DocumentStorageAccess* ODatabaseModelImpl::getDocumentStorageAccess()
{
if ( !m_pStorageAccess )
@@ -935,7 +904,6 @@ DocumentStorageAccess* ODatabaseModelImpl::getDocumentStorageAccess()
return m_pStorageAccess;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::modelIsDisposing( const bool _wasInitialized, ResetModelAccess )
{
m_xModel = Reference< XModel >();
@@ -949,19 +917,16 @@ void ODatabaseModelImpl::modelIsDisposing( const bool _wasInitialized, ResetMode
m_bDocumentInitialized = _wasInitialized;
}
-// -----------------------------------------------------------------------------
Reference< XDocumentSubStorageSupplier > ODatabaseModelImpl::getDocumentSubStorageSupplier()
{
return getDocumentStorageAccess();
}
-// -----------------------------------------------------------------------------
bool ODatabaseModelImpl::commitEmbeddedStorage( bool _bPreventRootCommits )
{
return getDocumentStorageAccess()->commitEmbeddedStorage( _bPreventRootCommits );
}
-// -----------------------------------------------------------------------------
bool ODatabaseModelImpl::commitStorageIfWriteable_ignoreErrors( const Reference< XStorage >& _rxStorage ) SAL_THROW(())
{
bool bSuccess = false;
@@ -975,7 +940,7 @@ bool ODatabaseModelImpl::commitStorageIfWriteable_ignoreErrors( const Reference<
}
return bSuccess;
}
-// -----------------------------------------------------------------------------
+
void ODatabaseModelImpl::setModified( sal_Bool _bModified )
{
if ( isModifyLocked() )
@@ -995,7 +960,6 @@ void ODatabaseModelImpl::setModified( sal_Bool _bModified )
}
}
-// -----------------------------------------------------------------------------
Reference<XDataSource> ODatabaseModelImpl::getOrCreateDataSource()
{
Reference<XDataSource> xDs = m_xDataSource;
@@ -1006,12 +970,12 @@ Reference<XDataSource> ODatabaseModelImpl::getOrCreateDataSource()
}
return xDs;
}
-// -----------------------------------------------------------------------------
+
Reference< XModel> ODatabaseModelImpl::getModel_noCreate() const
{
return m_xModel;
}
-// -----------------------------------------------------------------------------
+
Reference< XModel > ODatabaseModelImpl::createNewModel_deliverOwnership( bool _bInitialize )
{
Reference< XModel > xModel( m_xModel );
@@ -1041,7 +1005,7 @@ Reference< XModel > ODatabaseModelImpl::createNewModel_deliverOwnership( bool _b
// However, in case that the document is implicitly created by asking the data source for the document,
// then nobody would call the doc's attachResource. So, we do it here, to ensure it's in a proper
// state, fires all events, and so on.
- // #i105505# / 2009-10-02 / frank.schoenheit@sun.com
+ // #i105505#
xModel->attachResource( xModel->getURL(), m_aMediaDescriptor.getPropertyValues() );
}
@@ -1061,12 +1025,12 @@ Reference< XModel > ODatabaseModelImpl::createNewModel_deliverOwnership( bool _b
}
return xModel;
}
-// -----------------------------------------------------------------------------
+
oslInterlockedCount SAL_CALL ODatabaseModelImpl::acquire()
{
return osl_incrementInterlockedCount(&m_refCount);
}
-// -----------------------------------------------------------------------------
+
oslInterlockedCount SAL_CALL ODatabaseModelImpl::release()
{
if ( osl_decrementInterlockedCount(&m_refCount) == 0 )
@@ -1081,19 +1045,17 @@ oslInterlockedCount SAL_CALL ODatabaseModelImpl::release()
}
return m_refCount;
}
-// -----------------------------------------------------------------------------
+
void ODatabaseModelImpl::commitStorages() SAL_THROW(( IOException, RuntimeException ))
{
getDocumentStorageAccess()->commitStorages();
}
-// -----------------------------------------------------------------------------
Reference< XStorage > ODatabaseModelImpl::getStorage( const ObjectType _eType, const sal_Int32 _nDesiredMode )
{
return getDocumentStorageAccess()->getDocumentSubStorage( getObjectContainerStorageName( _eType ), _nDesiredMode );
}
-// -----------------------------------------------------------------------------
const AsciiPropertyValue* ODatabaseModelImpl::getDefaultDataSourceSettings()
{
static const AsciiPropertyValue aKnownSettings[] =
@@ -1173,7 +1135,6 @@ const AsciiPropertyValue* ODatabaseModelImpl::getDefaultDataSourceSettings()
return aKnownSettings;
}
-// -----------------------------------------------------------------------------
TContentPtr& ODatabaseModelImpl::getObjectContainer( ObjectType _eType )
{
OSL_PRECOND( _eType >= E_FORM && _eType <= E_TABLE, "ODatabaseModelImpl::getObjectContainer: illegal index!" );
@@ -1188,20 +1149,17 @@ TContentPtr& ODatabaseModelImpl::getObjectContainer( ObjectType _eType )
return rContentPtr;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::revokeDataSource() const
{
if ( m_pDBContext && m_sDocumentURL.getLength() )
m_pDBContext->revokeDatabaseDocument( *this );
}
-// -----------------------------------------------------------------------------
bool ODatabaseModelImpl::adjustMacroMode_AutoReject()
{
return m_aMacroMode.adjustMacroMode( NULL );
}
-// -----------------------------------------------------------------------------
bool ODatabaseModelImpl::checkMacrosOnLoading()
{
Reference< XInteractionHandler > xInteraction;
@@ -1209,13 +1167,11 @@ bool ODatabaseModelImpl::checkMacrosOnLoading()
return m_aMacroMode.checkMacrosOnLoading( xInteraction );
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::resetMacroExecutionMode()
{
m_aMacroMode = ::sfx2::DocumentMacroMode( *this );
}
-// -----------------------------------------------------------------------------
Reference< XStorageBasedLibraryContainer > ODatabaseModelImpl::getLibraryContainer( bool _bScript )
{
Reference< XStorageBasedLibraryContainer >& rxContainer( _bScript ? m_xBasicLibraries : m_xDialogLibraries );
@@ -1251,7 +1207,6 @@ Reference< XStorageBasedLibraryContainer > ODatabaseModelImpl::getLibraryContain
return rxContainer;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::storeLibraryContainersTo( const Reference< XStorage >& _rxToRootStorage )
{
if ( m_xBasicLibraries.is() )
@@ -1261,7 +1216,6 @@ void ODatabaseModelImpl::storeLibraryContainersTo( const Reference< XStorage >&
m_xDialogLibraries->storeLibrariesToStorage( _rxToRootStorage );
}
-// -----------------------------------------------------------------------------
Reference< XStorage > ODatabaseModelImpl::switchToStorage( const Reference< XStorage >& _rxNewRootStorage )
{
if ( !_rxNewRootStorage.is() )
@@ -1270,12 +1224,11 @@ Reference< XStorage > ODatabaseModelImpl::switchToStorage( const Reference< XSto
return impl_switchToStorage_throw( _rxNewRootStorage );
}
-// -----------------------------------------------------------------------------
namespace
{
void lcl_modifyListening( ::sfx2::IModifiableDocument& _rDocument,
const Reference< XStorage >& _rxStorage, ::rtl::Reference< ::sfx2::DocumentStorageModifyListener >& _inout_rListener,
- ::vos::IMutex& _rMutex, bool _bListen )
+ ::osl::SolarMutex& _rMutex, bool _bListen )
{
Reference< XModifiable > xModify( _rxStorage, UNO_QUERY );
OSL_ENSURE( xModify.is() || !_rxStorage.is(), "lcl_modifyListening: storage can't notify us!" );
@@ -1299,7 +1252,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
namespace
{
static void lcl_rebaseScriptStorage_throw( const Reference< XStorageBasedLibraryContainer >& _rxContainer,
@@ -1315,7 +1267,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
Reference< XStorage > ODatabaseModelImpl::impl_switchToStorage_throw( const Reference< XStorage >& _rxNewRootStorage )
{
// stop listening for modifications at the old storage
@@ -1337,7 +1288,6 @@ Reference< XStorage > ODatabaseModelImpl::impl_switchToStorage_throw( const Refe
return m_xDocumentStorage.getTyped();
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::impl_switchToLogicalURL( const ::rtl::OUString& i_rDocumentURL )
{
if ( i_rDocumentURL == m_sDocumentURL )
@@ -1374,13 +1324,11 @@ void ODatabaseModelImpl::impl_switchToLogicalURL( const ::rtl::OUString& i_rDocu
}
}
-// -----------------------------------------------------------------------------
::rtl::OUString ODatabaseModelImpl::getObjectContainerStorageName( const ObjectType _eType )
{
return lcl_getContainerStorageName_throw( _eType );
}
-// -----------------------------------------------------------------------------
sal_Int16 ODatabaseModelImpl::getCurrentMacroExecMode() const
{
sal_Int16 nCurrentMode = MacroExecMode::NEVER_EXECUTE;
@@ -1395,14 +1343,12 @@ sal_Int16 ODatabaseModelImpl::getCurrentMacroExecMode() const
return nCurrentMode;
}
-// -----------------------------------------------------------------------------
sal_Bool ODatabaseModelImpl::setCurrentMacroExecMode( sal_uInt16 nMacroMode )
{
m_aMediaDescriptor.put( "MacroExecutionMode", nMacroMode );
return sal_True;
}
-// -----------------------------------------------------------------------------
::rtl::OUString ODatabaseModelImpl::getDocumentLocation() const
{
return getURL();
@@ -1414,7 +1360,6 @@ sal_Bool ODatabaseModelImpl::setCurrentMacroExecMode( sal_uInt16 nMacroMode )
// this folder is considered to be secure. So, the document URL needs to be used to decide about the security.
}
-// -----------------------------------------------------------------------------
Reference< XStorage > ODatabaseModelImpl::getZipStorageToSign()
{
// we do not support signing the scripting storages, so we're allowed to
@@ -1422,7 +1367,6 @@ Reference< XStorage > ODatabaseModelImpl::getZipStorageToSign()
return Reference< XStorage >();
}
-// -----------------------------------------------------------------------------
ODatabaseModelImpl::EmbeddedMacros ODatabaseModelImpl::determineEmbeddedMacros()
{
if ( !m_aEmbeddedMacros )
@@ -1445,58 +1389,48 @@ ODatabaseModelImpl::EmbeddedMacros ODatabaseModelImpl::determineEmbeddedMacros()
return *m_aEmbeddedMacros;
}
-// -----------------------------------------------------------------------------
sal_Bool ODatabaseModelImpl::documentStorageHasMacros() const
{
const_cast< ODatabaseModelImpl* >( this )->determineEmbeddedMacros();
return ( *m_aEmbeddedMacros != eNoMacros );
}
-// -----------------------------------------------------------------------------
Reference< XEmbeddedScripts > ODatabaseModelImpl::getEmbeddedDocumentScripts() const
{
return Reference< XEmbeddedScripts >( getModel_noCreate(), UNO_QUERY );
}
-// -----------------------------------------------------------------------------
sal_Int16 ODatabaseModelImpl::getScriptingSignatureState()
{
// no support for signatures at the moment
return SIGNATURESTATE_NOSIGNATURES;
}
-// -----------------------------------------------------------------------------
sal_Bool ODatabaseModelImpl::hasTrustedScriptingSignature( sal_Bool /*bAllowUIToAddAuthor*/ )
{
// no support for signatures at the moment
return sal_False;
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::showBrokenSignatureWarning( const Reference< XInteractionHandler >& /*_rxInteraction*/ ) const
{
- OSL_ENSURE( false, "ODatabaseModelImpl::showBrokenSignatureWarning: signatures can't be broken - we do not support them!" );
+ OSL_FAIL( "ODatabaseModelImpl::showBrokenSignatureWarning: signatures can't be broken - we do not support them!" );
}
-// -----------------------------------------------------------------------------
void ODatabaseModelImpl::storageIsModified()
{
setModified( sal_True );
}
-// -----------------------------------------------------------------------------
ModelDependentComponent::ModelDependentComponent( const ::rtl::Reference< ODatabaseModelImpl >& _model )
:m_pImpl( _model )
,m_aMutex( _model->getSharedMutex() )
{
}
-// -----------------------------------------------------------------------------
ModelDependentComponent::~ModelDependentComponent()
{
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/ModelImpl.hxx b/dbaccess/source/core/dataaccess/ModelImpl.hxx
index f83b2230c2b4..804e2f976acf 100644
--- a/dbaccess/source/core/dataaccess/ModelImpl.hxx
+++ b/dbaccess/source/core/dataaccess/ModelImpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,7 +81,8 @@
#include <sfx2/docstoragemodifylistener.hxx>
#include <tools/string.hxx>
#include <unotools/sharedunocomponent.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
+#include <rtl/ref.hxx>
#include <memory>
@@ -139,7 +141,7 @@ class OSharedConnectionManager;
//============================================================
/** a class which provides an IMutex interface to an OSL-based mutex
*/
-class VosMutexFacade : public ::vos::IMutex
+class VosMutexFacade : public ::osl::SolarMutex
{
public:
/** beware of life time: the mutex you pass here must live as least as long
@@ -562,7 +564,7 @@ public:
{
return getMutex();
}
- inline ::rtl::Reference< ODatabaseModelImpl > getImpl( GuardAccess )
+ inline ::rtl::Reference< ODatabaseModelImpl > getImpl( GuardAccess ) const
{
return m_pImpl;
}
@@ -571,7 +573,7 @@ public:
inline void checkDisposed() const
{
if ( !m_pImpl.is() )
- throw ::com::sun::star::lang::DisposedException( ::rtl::OUString::createFromAscii( "Component is already disposed." ), getThis() );
+ throw ::com::sun::star::lang::DisposedException( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Component is already disposed.")), getThis() );
}
inline void lockModify()
@@ -639,3 +641,4 @@ public:
#endif // _DBA_COREDATAACCESS_DATALINK_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/SharedConnection.cxx b/dbaccess/source/core/dataaccess/SharedConnection.cxx
index 58625fe15170..ee65cd2a024c 100644
--- a/dbaccess/source/core/dataaccess/SharedConnection.cxx
+++ b/dbaccess/source/core/dataaccess/SharedConnection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBA_CORE_SHARED_CONNECTION_HXX
#include "SharedConnection.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaccess
@@ -41,7 +38,6 @@ namespace dbaccess
using namespace ::com::sun::star::lang;
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::container;
-// using namespace ::com::sun::star::reflection;
using namespace connectivity;
DBG_NAME(OSharedConnection)
@@ -51,81 +47,74 @@ OSharedConnection::OSharedConnection(Reference< XAggregation >& _rxProxyConnecti
DBG_CTOR(OSharedConnection,NULL);
setDelegation(_rxProxyConnection,m_refCount);
}
-// -----------------------------------------------------------------------------
+
OSharedConnection::~OSharedConnection()
{
DBG_DTOR(OSharedConnection,NULL);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OSharedConnection::disposing(void)
{
OSharedConnection_BASE::disposing();
OConnectionWrapper::disposing();
}
-// -----------------------------------------------------------------------------
+
Reference< XStatement > SAL_CALL OSharedConnection::createStatement( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->createStatement();
}
-// --------------------------------------------------------------------------------
+
Reference< XPreparedStatement > SAL_CALL OSharedConnection::prepareStatement( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->prepareStatement(sql);
}
-// --------------------------------------------------------------------------------
+
Reference< XPreparedStatement > SAL_CALL OSharedConnection::prepareCall( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->prepareCall(sql);
}
-// --------------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OSharedConnection::nativeSQL( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->nativeSQL(sql);
}
-// --------------------------------------------------------------------------------
+
sal_Bool SAL_CALL OSharedConnection::getAutoCommit( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->getAutoCommit();
}
-// --------------------------------------------------------------------------------
+
void SAL_CALL OSharedConnection::commit( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
m_xConnection->commit();
}
-// --------------------------------------------------------------------------------
+
void SAL_CALL OSharedConnection::rollback( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
m_xConnection->rollback();
}
-// --------------------------------------------------------------------------------
+
sal_Bool SAL_CALL OSharedConnection::isClosed( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -134,7 +123,7 @@ sal_Bool SAL_CALL OSharedConnection::isClosed( ) throw(SQLException, RuntimeExc
return m_xConnection->isClosed();
}
-// --------------------------------------------------------------------------------
+
Reference< XDatabaseMetaData > SAL_CALL OSharedConnection::getMetaData( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -143,46 +132,38 @@ Reference< XDatabaseMetaData > SAL_CALL OSharedConnection::getMetaData( ) throw
return m_xConnection->getMetaData();
}
-// --------------------------------------------------------------------------------
+
sal_Bool SAL_CALL OSharedConnection::isReadOnly( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->isReadOnly();
}
-// --------------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL OSharedConnection::getCatalog( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->getCatalog();
}
-// --------------------------------------------------------------------------------
+
sal_Int32 SAL_CALL OSharedConnection::getTransactionIsolation( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->getTransactionIsolation();
}
-// --------------------------------------------------------------------------------
+
Reference< ::com::sun::star::container::XNameAccess > SAL_CALL OSharedConnection::getTypeMap( ) throw(SQLException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
checkDisposed(rBHelper.bDisposed);
-
return m_xConnection->getTypeMap();
}
-// -----------------------------------------------------------------------------
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/SharedConnection.hxx b/dbaccess/source/core/dataaccess/SharedConnection.hxx
index 018e7ead0e1f..5706d20ef5ae 100644
--- a/dbaccess/source/core/dataaccess/SharedConnection.hxx
+++ b/dbaccess/source/core/dataaccess/SharedConnection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,48 +28,20 @@
#ifndef DBA_CORE_SHARED_CONNECTION_HXX
#define DBA_CORE_SHARED_CONNECTION_HXX
-#ifndef _CONNECTIVITY_CONNECTIONWRAPPER_HXX_
#include "connectivity/ConnectionWrapper.hxx"
-#endif
-#ifndef _CPPUHELPER_COMPONENT_HXX_
#include <cppuhelper/component.hxx>
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _CPPUHELPER_COMPBASE1_HXX_
#include <cppuhelper/compbase1.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XWARNINGSSUPPLIER_HPP_
#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLWARNING_HPP_
#include <com/sun/star/sdbc/SQLWarning.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSQLQUERYCOMPOSERFACTORY_HPP_
#include <com/sun/star/sdb/XSQLQueryComposerFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XCOMMANDPREPARATION_HPP_
#include <com/sun/star/sdb/XCommandPreparation.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XQUERIESSUPPLIER_HPP_
#include <com/sun/star/sdb/XQueriesSupplier.hpp>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
namespace dbaccess
@@ -112,14 +85,13 @@ namespace dbaccess
aReturn = OSharedConnection_BASE2::queryInterface(_rType);
return aReturn;
}
- // --------------------------------------------------------------------------------
+
// XCloseable
virtual void SAL_CALL close( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException)
{
{
::osl::MutexGuard aGuard( m_aMutex );
::connectivity::checkDisposed(rBHelper.bDisposed);
-
}
dispose();
}
@@ -161,9 +133,12 @@ namespace dbaccess
virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess > SAL_CALL getTypeMap( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException);
};
-//........................................................................
+#ifdef IMPLEMENT_GET_IMPLEMENTATION_ID
+ IMPLEMENT_GET_IMPLEMENTATION_ID( OSharedConnection );
+#endif
+
} // namespace dbaccess
-//........................................................................
-#endif // DBA_CORE_SHARED_CONNECTION_HXX
+#endif // DBA_CORE_SHARED_CONNECTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/bookmarkcontainer.cxx b/dbaccess/source/core/dataaccess/bookmarkcontainer.cxx
index 08321a0e0053..6e330a1f6cf8 100644
--- a/dbaccess/source/core/dataaccess/bookmarkcontainer.cxx
+++ b/dbaccess/source/core/dataaccess/bookmarkcontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,40 +29,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_CORE_BOOKMARKCONTAINER_HXX_
#include "bookmarkcontainer.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HXX_
#include "core_resource.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HRC_
#include "core_resource.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
+#include <osl/diagnose.h>
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_ENUMHELPER_HXX_
#include <comphelper/enumhelper.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XCOMPONENT_HPP_
#include <com/sun/star/lang/XComponent.hpp>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
@@ -71,16 +51,14 @@ using namespace ::osl;
using namespace ::comphelper;
using namespace ::cppu;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OBookmarkContainer
//==========================================================================
DBG_NAME(OBookmarkContainer)
-//--------------------------------------------------------------------------
+
OBookmarkContainer::OBookmarkContainer(OWeakObject& _rParent, Mutex& _rMutex)
:m_rParent(_rParent)
,m_aContainerListeners(_rMutex)
@@ -89,12 +67,11 @@ OBookmarkContainer::OBookmarkContainer(OWeakObject& _rParent, Mutex& _rMutex)
DBG_CTOR(OBookmarkContainer, NULL);
}
-//--------------------------------------------------------------------------
void OBookmarkContainer::dispose()
{
MutexGuard aGuard(m_rMutex);
- // say our listeners goobye
+ // say goodbye to our listeners
EventObject aEvt(*this);
m_aContainerListeners.disposeAndClear(aEvt);
@@ -103,32 +80,27 @@ void OBookmarkContainer::dispose()
m_aBookmarks.clear();
}
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::acquire( ) throw()
{
m_rParent.acquire();
}
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::release( ) throw()
{
m_rParent.release();
}
-//--------------------------------------------------------------------------
OBookmarkContainer::~OBookmarkContainer()
{
DBG_DTOR(OBookmarkContainer, NULL);
}
// XServiceInfo
-//--------------------------------------------------------------------------
::rtl::OUString SAL_CALL OBookmarkContainer::getImplementationName( ) throw(RuntimeException)
{
- return ::rtl::OUString::createFromAscii("com.sun.star.comp.dba.OBookmarkContainer");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dba.OBookmarkContainer"));
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OBookmarkContainer::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -136,16 +108,14 @@ sal_Bool SAL_CALL OBookmarkContainer::supportsService( const ::rtl::OUString& _r
return findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL OBookmarkContainer::getSupportedServiceNames( ) throw(RuntimeException)
{
Sequence< ::rtl::OUString > aReturn(1);
- aReturn.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.DefinitionContainer");
+ aReturn.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.DefinitionContainer"));
return aReturn;
}
// XNameContainer
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::insertByName( const ::rtl::OUString& _rName, const Any& aElement ) throw(IllegalArgumentException, ElementExistException, WrappedTargetException, RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -175,7 +145,6 @@ void SAL_CALL OBookmarkContainer::insertByName( const ::rtl::OUString& _rName, c
}
}
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::removeByName( const ::rtl::OUString& _rName ) throw(NoSuchElementException, WrappedTargetException, RuntimeException)
{
::rtl::OUString sOldBookmark;
@@ -208,7 +177,6 @@ void SAL_CALL OBookmarkContainer::removeByName( const ::rtl::OUString& _rName )
}
// XNameReplace
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::replaceByName( const ::rtl::OUString& _rName, const Any& aElement ) throw(IllegalArgumentException, NoSuchElementException, WrappedTargetException, RuntimeException)
{
ClearableMutexGuard aGuard(m_rMutex);
@@ -244,7 +212,6 @@ void SAL_CALL OBookmarkContainer::replaceByName( const ::rtl::OUString& _rName,
}
}
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::addContainerListener( const Reference< XContainerListener >& _rxListener ) throw(RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -252,7 +219,6 @@ void SAL_CALL OBookmarkContainer::addContainerListener( const Reference< XContai
m_aContainerListeners.addInterface(_rxListener);
}
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::removeContainerListener( const Reference< XContainerListener >& _rxListener ) throw(RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -261,7 +227,6 @@ void SAL_CALL OBookmarkContainer::removeContainerListener( const Reference< XCon
}
// XElementAccess
-//--------------------------------------------------------------------------
Type SAL_CALL OBookmarkContainer::getElementType( ) throw (RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -269,7 +234,6 @@ Type SAL_CALL OBookmarkContainer::getElementType( ) throw (RuntimeException)
return ::getCppuType( static_cast< ::rtl::OUString* >(NULL) );
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OBookmarkContainer::hasElements( ) throw (RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -278,7 +242,6 @@ sal_Bool SAL_CALL OBookmarkContainer::hasElements( ) throw (RuntimeException)
}
// XEnumerationAccess
-//--------------------------------------------------------------------------
Reference< XEnumeration > SAL_CALL OBookmarkContainer::createEnumeration( ) throw(RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -286,7 +249,6 @@ Reference< XEnumeration > SAL_CALL OBookmarkContainer::createEnumeration( ) thr
return new ::comphelper::OEnumerationByIndex(static_cast<XIndexAccess*>(this));
}
-//--------------------------------------------------------------------------
// XIndexAccess
sal_Int32 SAL_CALL OBookmarkContainer::getCount( ) throw(RuntimeException)
{
@@ -295,7 +257,6 @@ sal_Int32 SAL_CALL OBookmarkContainer::getCount( ) throw(RuntimeException)
return m_aBookmarks.size();
}
-//--------------------------------------------------------------------------
Any SAL_CALL OBookmarkContainer::getByIndex( sal_Int32 _nIndex ) throw(IndexOutOfBoundsException, WrappedTargetException, RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -307,7 +268,6 @@ Any SAL_CALL OBookmarkContainer::getByIndex( sal_Int32 _nIndex ) throw(IndexOutO
return makeAny(m_aBookmarksIndexed[_nIndex]->second);
}
-//--------------------------------------------------------------------------
Any SAL_CALL OBookmarkContainer::getByName( const ::rtl::OUString& _rName ) throw(NoSuchElementException, WrappedTargetException, RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -319,7 +279,6 @@ Any SAL_CALL OBookmarkContainer::getByName( const ::rtl::OUString& _rName ) thro
return makeAny(m_aBookmarks[_rName]);
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL OBookmarkContainer::getElementNames( ) throw(RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -339,7 +298,6 @@ Sequence< ::rtl::OUString > SAL_CALL OBookmarkContainer::getElementNames( ) thr
return aNames;
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OBookmarkContainer::hasByName( const ::rtl::OUString& _rName ) throw(RuntimeException)
{
MutexGuard aGuard(m_rMutex);
@@ -348,7 +306,6 @@ sal_Bool SAL_CALL OBookmarkContainer::hasByName( const ::rtl::OUString& _rName )
return checkExistence(_rName);
}
-//--------------------------------------------------------------------------
void OBookmarkContainer::implRemove(const ::rtl::OUString& _rName)
{
MutexGuard aGuard(m_rMutex);
@@ -373,7 +330,7 @@ void OBookmarkContainer::implRemove(const ::rtl::OUString& _rName)
if (m_aBookmarks.end() == aMapPos)
{
- DBG_ERROR("OBookmarkContainer::implRemove: inconsistence!");
+ OSL_FAIL("OBookmarkContainer::implRemove: inconsistence!");
return;
}
@@ -381,7 +338,6 @@ void OBookmarkContainer::implRemove(const ::rtl::OUString& _rName)
m_aBookmarks.erase(aMapPos);
}
-//--------------------------------------------------------------------------
void OBookmarkContainer::implAppend(const ::rtl::OUString& _rName, const ::rtl::OUString& _rDocumentLocation)
{
MutexGuard aGuard(m_rMutex);
@@ -390,32 +346,27 @@ void OBookmarkContainer::implAppend(const ::rtl::OUString& _rName, const ::rtl::
m_aBookmarksIndexed.push_back(m_aBookmarks.insert( MapString2String::value_type(_rName,_rDocumentLocation)).first);
}
-//--------------------------------------------------------------------------
void OBookmarkContainer::implReplace(const ::rtl::OUString& _rName, const ::rtl::OUString& _rNewLink)
{
MutexGuard aGuard(m_rMutex);
- DBG_ASSERT(checkExistence(_rName), "OBookmarkContainer::implReplace : invalid name !");
+ OSL_ENSURE(checkExistence(_rName), "OBookmarkContainer::implReplace : invalid name !");
m_aBookmarks[_rName] = _rNewLink;
}
-//--------------------------------------------------------------------------
void OBookmarkContainer::checkValid(sal_Bool /*_bIntendWriteAccess*/) const throw (RuntimeException, DisposedException)
{
}
-//--------------------------------------------------------------------------
Reference< XInterface > SAL_CALL OBookmarkContainer::getParent( ) throw (RuntimeException)
{
return m_rParent;
}
-//--------------------------------------------------------------------------
void SAL_CALL OBookmarkContainer::setParent( const Reference< XInterface >& /*Parent*/ ) throw (NoSupportException, RuntimeException)
{
throw NoSupportException();
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/bookmarkcontainer.hxx b/dbaccess/source/core/dataaccess/bookmarkcontainer.hxx
index 0a43371c51e5..b41c70ae75e3 100644
--- a/dbaccess/source/core/dataaccess/bookmarkcontainer.hxx
+++ b/dbaccess/source/core/dataaccess/bookmarkcontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,50 +29,22 @@
#ifndef _DBA_CORE_BOOKMARKCONTAINER_HXX_
#define _DBA_CORE_BOOKMARKCONTAINER_HXX_
-#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_
#include <cppuhelper/interfacecontainer.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE6_HXX_
#include <cppuhelper/implbase6.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XENUMERATIONACCESS_HPP_
#include <com/sun/star/container/XEnumerationAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OBookmarkContainer - base class of collections of database definition
@@ -194,15 +167,13 @@ protected:
};
-//--------------------------------------------------------------------------
inline sal_Bool OBookmarkContainer::checkExistence(const ::rtl::OUString& _rName)
{
return m_aBookmarks.find(_rName) != m_aBookmarks.end();
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_CORE_BOOKMARKCONTAINER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/commandcontainer.cxx b/dbaccess/source/core/dataaccess/commandcontainer.cxx
index 34d7283b1837..695b952ca2f4 100644
--- a/dbaccess/source/core/dataaccess/commandcontainer.cxx
+++ b/dbaccess/source/core/dataaccess/commandcontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,19 +29,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREDATAACCESS_COMMANDCONTAINER_HXX_
#include "commandcontainer.hxx"
-#endif
-#ifndef _DBA_COREDATAACESS_COMMANDDEFINITION_HXX_
#include "commanddefinition.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
@@ -51,16 +44,14 @@ using namespace ::osl;
using namespace ::comphelper;
using namespace ::cppu;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OCommandContainer
//==========================================================================
DBG_NAME(OCommandContainer)
-//--------------------------------------------------------------------------
+
OCommandContainer::OCommandContainer( const Reference< ::com::sun::star::lang::XMultiServiceFactory >& _xORB
,const Reference< XInterface >& _xParentContainer
,const TContentPtr& _pImpl
@@ -71,15 +62,15 @@ OCommandContainer::OCommandContainer( const Reference< ::com::sun::star::lang::X
{
DBG_CTOR(OCommandContainer, NULL);
}
-//--------------------------------------------------------------------------
+
OCommandContainer::~OCommandContainer()
{
DBG_DTOR(OCommandContainer, NULL);
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_FORWARD_XINTERFACE2( OCommandContainer,ODefinitionContainer,OCommandContainer_BASE)
IMPLEMENT_TYPEPROVIDER2(OCommandContainer,ODefinitionContainer,OCommandContainer_BASE);
-//--------------------------------------------------------------------------
+
Reference< XContent > OCommandContainer::createObject( const ::rtl::OUString& _rName)
{
const ODefinitionContainer_Impl& rDefinitions( getDefinitions() );
@@ -91,25 +82,20 @@ Reference< XContent > OCommandContainer::createObject( const ::rtl::OUString& _r
return new OCommandDefinition( *this, _rName, m_aContext.getLegacyServiceFactory(), pElementContent );
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL OCommandContainer::createInstanceWithArguments(const Sequence< Any >& /*aArguments*/ ) throw (Exception, RuntimeException)
{
return createInstance( );
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL OCommandContainer::createInstance( ) throw (Exception, RuntimeException)
{
return m_aContext.createComponent( (::rtl::OUString)( m_bTables ? SERVICE_SDB_TABLEDEFINITION : SERVICE_SDB_COMMAND_DEFINITION ) );
}
-// -----------------------------------------------------------------------------
::rtl::OUString OCommandContainer::determineContentType() const
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "application/vnd.org.openoffice.DatabaseCommandDefinitionContainer" ) );
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/commandcontainer.hxx b/dbaccess/source/core/dataaccess/commandcontainer.hxx
index 4528224ce24d..e1ff6b34357c 100644
--- a/dbaccess/source/core/dataaccess/commandcontainer.hxx
+++ b/dbaccess/source/core/dataaccess/commandcontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,22 +29,14 @@
#ifndef _DBA_COREDATAACCESS_COMMANDCONTAINER_HXX_
#define _DBA_COREDATAACCESS_COMMANDCONTAINER_HXX_
-#ifndef _DBA_CORE_DEFINITIONCONTAINER_HXX_
#include "definitioncontainer.hxx"
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OCommandContainer
//==========================================================================
@@ -84,10 +77,9 @@ protected:
virtual ::rtl::OUString determineContentType() const;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
-#endif // _DBA_COREDATAACCESS_COMMANDCONTAINER_HXX_
+#endif // _DBA_COREDATAACCESS_COMMANDCONTAINER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/commanddefinition.cxx b/dbaccess/source/core/dataaccess/commanddefinition.cxx
index b3b41ff903b8..e96da41181ea 100644
--- a/dbaccess/source/core/dataaccess/commanddefinition.cxx
+++ b/dbaccess/source/core/dataaccess/commanddefinition.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -49,10 +50,8 @@ using namespace ::osl;
using namespace ::comphelper;
using namespace ::cppu;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OCommandDefinition
@@ -62,9 +61,8 @@ extern "C" void SAL_CALL createRegistryInfo_OCommandDefinition()
static ::dba::OAutoRegistration< OCommandDefinition > aAutoRegistration;
}
-//--------------------------------------------------------------------------
DBG_NAME(OCommandDefinition)
-//--------------------------------------------------------------------------
+
void OCommandDefinition::registerProperties()
{
OCommandDefinition_Impl& rCommandDefinition( getCommandDefinition() );
@@ -86,7 +84,6 @@ void OCommandDefinition::registerProperties()
&rCommandDefinition.m_aLayoutInformation, ::getCppuType(&rCommandDefinition.m_aLayoutInformation));
}
-//--------------------------------------------------------------------------
OCommandDefinition::OCommandDefinition(const Reference< XMultiServiceFactory >& _xORB
,const Reference< XInterface >& _rxContainer
,const TContentPtr& _pImpl)
@@ -95,13 +92,12 @@ OCommandDefinition::OCommandDefinition(const Reference< XMultiServiceFactory >&
DBG_CTOR(OCommandDefinition, NULL);
registerProperties();
}
-//--------------------------------------------------------------------------
+
OCommandDefinition::~OCommandDefinition()
{
DBG_DTOR(OCommandDefinition, NULL);
}
-//--------------------------------------------------------------------------
OCommandDefinition::OCommandDefinition( const Reference< XInterface >& _rxContainer
,const ::rtl::OUString& _rElementName
,const Reference< XMultiServiceFactory >& _xORB
@@ -112,24 +108,21 @@ OCommandDefinition::OCommandDefinition( const Reference< XInterface >& _rxContai
registerProperties();
}
-//--------------------------------------------------------------------------
IMPLEMENT_IMPLEMENTATION_ID(OCommandDefinition);
IMPLEMENT_GETTYPES2(OCommandDefinition,OCommandDefinition_Base,OComponentDefinition);
IMPLEMENT_FORWARD_XINTERFACE2( OCommandDefinition,OComponentDefinition,OCommandDefinition_Base)
IMPLEMENT_PROPERTYCONTAINER_DEFAULTS2(OCommandDefinition,OCommandDefinition_PROP)
-//--------------------------------------------------------------------------
+
::rtl::OUString OCommandDefinition::getImplementationName_static( ) throw(RuntimeException)
{
- return ::rtl::OUString::createFromAscii("com.sun.star.comp.dba.OCommandDefinition");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dba.OCommandDefinition"));
}
-//--------------------------------------------------------------------------
::rtl::OUString SAL_CALL OCommandDefinition::getImplementationName( ) throw(RuntimeException)
{
return getImplementationName_static();
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > OCommandDefinition::getSupportedServiceNames_static( ) throw(RuntimeException)
{
Sequence< ::rtl::OUString > aServices(3);
@@ -139,20 +132,17 @@ Sequence< ::rtl::OUString > OCommandDefinition::getSupportedServiceNames_static(
return aServices;
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL OCommandDefinition::getSupportedServiceNames( ) throw(RuntimeException)
{
return getSupportedServiceNames_static();
}
-//------------------------------------------------------------------------------
Reference< XInterface > OCommandDefinition::Create(const Reference< XComponentContext >& _rxContext)
{
::comphelper::ComponentContext aContext( _rxContext );
return *(new OCommandDefinition( aContext.getLegacyServiceFactory(), NULL, TContentPtr( new OCommandDefinition_Impl ) ) );
}
-// -----------------------------------------------------------------------------
void SAL_CALL OCommandDefinition::rename( const ::rtl::OUString& newName ) throw (SQLException, ElementExistException, RuntimeException)
{
try
@@ -172,8 +162,6 @@ void SAL_CALL OCommandDefinition::rename( const ::rtl::OUString& newName ) throw
throw ElementExistException(newName,*this);
}
}
-// -----------------------------------------------------------------------------
-//........................................................................
-} // namespace dbaccess
-//........................................................................
+} // namespace dbaccess
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/commanddefinition.hxx b/dbaccess/source/core/dataaccess/commanddefinition.hxx
index 6d245324c831..30f22948cb62 100644
--- a/dbaccess/source/core/dataaccess/commanddefinition.hxx
+++ b/dbaccess/source/core/dataaccess/commanddefinition.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,39 +29,17 @@
#ifndef _DBA_COREDATAACESS_COMMANDDEFINITION_HXX_
#define _DBA_COREDATAACESS_COMMANDDEFINITION_HXX_
-#ifndef _DBA_CORE_COMMANDBASE_HXX_
#include "commandbase.hxx"
-#endif
-#ifndef _COMPHELPER_PROPERTYCONTAINER_HXX_
#include <comphelper/propertycontainer.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XRENAME_HPP_
#include <com/sun/star/sdbcx/XRename.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _DBA_CORE_DATASETTINGS_HXX_
#include "datasettings.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
-#ifndef DBA_COREDATAACESS_COMPONENTDEFINITION_HXX
#include "ComponentDefinition.hxx"
-#endif
//........................................................................
@@ -83,7 +62,6 @@ class OCommandDefinition;
typedef ::comphelper::OPropertyArrayUsageHelper< OCommandDefinition >
OCommandDefinition_PROP;
-
class OCommandDefinition :public OComponentDefinition
,public OCommandDefinition_Base
,public OCommandDefinition_PROP
@@ -142,3 +120,4 @@ private:
#endif // _DBA_COREDATAACESS_COMMANDDEFINITION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/connection.cxx b/dbaccess/source/core/dataaccess/connection.cxx
index 9c00ebdd0385..4b226e73787e 100644
--- a/dbaccess/source/core/dataaccess/connection.cxx
+++ b/dbaccess/source/core/dataaccess/connection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -53,6 +54,7 @@
#include <connectivity/dbexception.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <comphelper/extract.hxx>
#include <comphelper/uno3.hxx>
#include <comphelper/sequence.hxx>
@@ -80,30 +82,23 @@ using ::com::sun::star::sdb::tools::XTableName;
using ::com::sun::star::sdb::tools::XObjectNames;
using ::com::sun::star::sdb::tools::XDataSourceMetaData;
-//........................................................................
namespace dbaccess
{
-//........................................................................
-#ifdef IMPLEMENT_GET_IMPLEMENTATION_ID
- IMPLEMENT_GET_IMPLEMENTATION_ID( OSharedConnection );
-#endif
//==========================================================================
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString OConnection::getImplementationName( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getImplementationName" );
- return rtl::OUString::createFromAscii("com.sun.star.comp.dbaccess.Connection");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dbaccess.Connection"));
}
-//------------------------------------------------------------------------------
+
sal_Bool OConnection::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::supportsService" );
return findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OConnection::getSupportedServiceNames( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getSupportedServiceNames" );
@@ -120,7 +115,6 @@ Sequence< ::rtl::OUString > OConnection::getSupportedServiceNames( ) throw (Run
}
// XCloseable
-//------------------------------------------------------------------------------
void OConnection::close(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::close" );
@@ -128,7 +122,6 @@ void OConnection::close(void) throw( SQLException, RuntimeException )
dispose();
}
-//------------------------------------------------------------------------------
sal_Bool OConnection::isClosed(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::isClosed" );
@@ -137,7 +130,6 @@ sal_Bool OConnection::isClosed(void) throw( SQLException, RuntimeException )
}
// XConnection
-//------------------------------------------------------------------------------
Reference< XStatement > OConnection::createStatement(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::createStatement" );
@@ -153,7 +145,6 @@ Reference< XStatement > OConnection::createStatement(void) throw( SQLException,
}
return xStatement;
}
-//------------------------------------------------------------------------------
Reference< XPreparedStatement > OConnection::prepareStatement(const rtl::OUString& sql) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::prepareStatement" );
@@ -171,7 +162,6 @@ Reference< XPreparedStatement > OConnection::prepareStatement(const rtl::OUStri
return xStatement;
}
-//------------------------------------------------------------------------------
Reference< XPreparedStatement > OConnection::prepareCall(const rtl::OUString& sql) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::prepareCall" );
@@ -188,7 +178,6 @@ Reference< XPreparedStatement > OConnection::prepareCall(const rtl::OUString& s
return xStatement;
}
-//------------------------------------------------------------------------------
rtl::OUString OConnection::nativeSQL(const rtl::OUString& sql) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::nativeSQL" );
@@ -197,7 +186,6 @@ rtl::OUString OConnection::nativeSQL(const rtl::OUString& sql) throw( SQLExcepti
return m_xMasterConnection->nativeSQL(sql);
}
-//------------------------------------------------------------------------------
void OConnection::setAutoCommit(sal_Bool autoCommit) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::setAutoCommit" );
@@ -206,7 +194,6 @@ void OConnection::setAutoCommit(sal_Bool autoCommit) throw( SQLException, Runtim
m_xMasterConnection->setAutoCommit(autoCommit);
}
-//------------------------------------------------------------------------------
sal_Bool OConnection::getAutoCommit(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getAutoCommit" );
@@ -215,7 +202,6 @@ sal_Bool OConnection::getAutoCommit(void) throw( SQLException, RuntimeException
return m_xMasterConnection->getAutoCommit();
}
-//------------------------------------------------------------------------------
void OConnection::commit(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::commit" );
@@ -224,7 +210,6 @@ void OConnection::commit(void) throw( SQLException, RuntimeException )
m_xMasterConnection->commit();
}
-//------------------------------------------------------------------------------
void OConnection::rollback(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::rollback" );
@@ -233,7 +218,6 @@ void OConnection::rollback(void) throw( SQLException, RuntimeException )
m_xMasterConnection->rollback();
}
-//------------------------------------------------------------------------------
Reference< XDatabaseMetaData > OConnection::getMetaData(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getMetaData" );
@@ -242,7 +226,6 @@ Reference< XDatabaseMetaData > OConnection::getMetaData(void) throw( SQLExcepti
return m_xMasterConnection->getMetaData();
}
-//------------------------------------------------------------------------------
void OConnection::setReadOnly(sal_Bool readOnly) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::setReadOnly" );
@@ -251,7 +234,6 @@ void OConnection::setReadOnly(sal_Bool readOnly) throw( SQLException, RuntimeExc
m_xMasterConnection->setReadOnly(readOnly);
}
-//------------------------------------------------------------------------------
sal_Bool OConnection::isReadOnly(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::isReadOnly" );
@@ -260,7 +242,6 @@ sal_Bool OConnection::isReadOnly(void) throw( SQLException, RuntimeException )
return m_xMasterConnection->isReadOnly();
}
-//------------------------------------------------------------------------------
void OConnection::setCatalog(const rtl::OUString& catalog) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::setCatalog" );
@@ -269,7 +250,6 @@ void OConnection::setCatalog(const rtl::OUString& catalog) throw( SQLException,
m_xMasterConnection->setCatalog(catalog);
}
-//------------------------------------------------------------------------------
rtl::OUString OConnection::getCatalog(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getCatalog" );
@@ -278,7 +258,6 @@ rtl::OUString OConnection::getCatalog(void) throw( SQLException, RuntimeExceptio
return m_xMasterConnection->getCatalog();
}
-//------------------------------------------------------------------------------
void OConnection::setTransactionIsolation(sal_Int32 level) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::setTransactionIsolation" );
@@ -287,7 +266,6 @@ void OConnection::setTransactionIsolation(sal_Int32 level) throw( SQLException,
m_xMasterConnection->setTransactionIsolation(level);
}
-//------------------------------------------------------------------------------
sal_Int32 OConnection::getTransactionIsolation(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getTransactionIsolation" );
@@ -296,7 +274,6 @@ sal_Int32 OConnection::getTransactionIsolation(void) throw( SQLException, Runtim
return m_xMasterConnection->getTransactionIsolation();
}
-//------------------------------------------------------------------------------
Reference< XNameAccess > OConnection::getTypeMap(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getTypeMap" );
@@ -305,7 +282,6 @@ Reference< XNameAccess > OConnection::getTypeMap(void) throw( SQLException, Run
return m_xMasterConnection->getTypeMap();
}
-//------------------------------------------------------------------------------
void OConnection::setTypeMap(const Reference< XNameAccess > & typeMap) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::setTypeMap" );
@@ -317,7 +293,7 @@ void OConnection::setTypeMap(const Reference< XNameAccess > & typeMap) throw( SQ
//= OConnection
//==========================================================================
DBG_NAME(OConnection)
-//--------------------------------------------------------------------------
+
OConnection::OConnection(ODatabaseSource& _rDB
, Reference< XConnection >& _rxMaster
, const Reference< XMultiServiceFactory >& _rxORB)
@@ -347,7 +323,7 @@ OConnection::OConnection(ODatabaseSource& _rDB
_rxORB->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.reflection.ProxyFactory"))),UNO_QUERY);
Reference<XAggregation> xAgg = xProxyFactory->createProxy(_rxMaster.get());
setDelegation(xAgg,m_refCount);
- DBG_ASSERT(m_xConnection.is(), "OConnection::OConnection : invalid master connection !");
+ OSL_ENSURE(m_xConnection.is(), "OConnection::OConnection : invalid master connection !");
}
catch(const Exception&)
{
@@ -367,7 +343,7 @@ OConnection::OConnection(ODatabaseSource& _rDB
xMeta = getMetaData();
bCase = xMeta.is() && xMeta->supportsMixedCaseQuotedIdentifiers();
}
- catch(SQLException&)
+ catch(const SQLException&)
{
}
Reference< XNameContainer > xTableDefinitions(_rDB.getTables(),UNO_QUERY);
@@ -418,7 +394,6 @@ OConnection::OConnection(ODatabaseSource& _rDB
osl_decrementInterlockedCount( &m_refCount );
}
-//--------------------------------------------------------------------------
OConnection::~OConnection()
{
delete m_pTables;
@@ -426,9 +401,7 @@ OConnection::~OConnection()
DBG_DTOR(OConnection,NULL);
}
-
// XWarningsSupplier
-//--------------------------------------------------------------------------
Any SAL_CALL OConnection::getWarnings() throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getWarnings" );
@@ -437,7 +410,6 @@ Any SAL_CALL OConnection::getWarnings() throw(SQLException, RuntimeException)
return m_aWarnings.getWarnings();
}
-//--------------------------------------------------------------------------
void SAL_CALL OConnection::clearWarnings( ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::clearWarnings" );
@@ -446,7 +418,6 @@ void SAL_CALL OConnection::clearWarnings( ) throw(SQLException, RuntimeExceptio
m_aWarnings.clearWarnings();
}
-//--------------------------------------------------------------------------
namespace
{
struct CompareTypeByName : public ::std::binary_function< Type, Type, bool >
@@ -464,8 +435,8 @@ namespace
::std::insert_iterator< TypeBag >( _out_rTypes, _out_rTypes.begin() ) );
}
}
+
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > OConnection::getTypes() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getTypes" );
@@ -487,7 +458,6 @@ Sequence< Type > OConnection::getTypes() throw (RuntimeException)
return aSupportedTypes;
}
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > OConnection::getImplementationId() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getImplementationId" );
@@ -495,7 +465,6 @@ Sequence< sal_Int8 > OConnection::getImplementationId() throw (RuntimeException)
}
// com::sun::star::uno::XInterface
-//--------------------------------------------------------------------------
Any OConnection::queryInterface( const Type & rType ) throw (RuntimeException)
{
if ( !m_bSupportsViews && rType.equals( XViewsSupplier::static_type() ) )
@@ -514,24 +483,19 @@ Any OConnection::queryInterface( const Type & rType ) throw (RuntimeException)
return aReturn;
}
-//--------------------------------------------------------------------------
void OConnection::acquire() throw ()
{
// include this one when you want to see who calls it (call graph)
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::acquire" );
OSubComponent::acquire();
}
-//--------------------------------------------------------------------------
void OConnection::release() throw ()
{
// include this one when you want to see who calls it (call graph)
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::release" );
OSubComponent::release();
}
// OSubComponent
-//------------------------------------------------------------------------------
void OConnection::disposing()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::disposing" );
@@ -570,14 +534,13 @@ void OConnection::disposing()
if (m_xMasterConnection.is())
m_xMasterConnection->close();
}
- catch(Exception)
+ catch(const Exception&)
{
}
m_xMasterConnection = NULL;
}
// XChild
-//------------------------------------------------------------------------------
Reference< XInterface > OConnection::getParent(void) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getParent" );
@@ -586,7 +549,6 @@ Reference< XInterface > OConnection::getParent(void) throw( RuntimeException )
return m_xParent;
}
-//------------------------------------------------------------------------------
void OConnection::setParent(const Reference< XInterface > & /*Parent*/) throw( NoSupportException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::setParent" );
@@ -594,7 +556,6 @@ void OConnection::setParent(const Reference< XInterface > & /*Parent*/) throw( N
}
// XSQLQueryComposerFactory
-//------------------------------------------------------------------------------
Reference< XSQLQueryComposer > OConnection::createQueryComposer(void) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::createQueryComposer" );
@@ -606,7 +567,7 @@ Reference< XSQLQueryComposer > OConnection::createQueryComposer(void) throw( Ru
m_aComposers.push_back(WeakReferenceHelper(xComposer));
return xComposer;
}
-// -----------------------------------------------------------------------------
+
void OConnection::impl_fillTableFilter()
{
Reference<XPropertySet> xProp(getParent(),UNO_QUERY);
@@ -617,7 +578,6 @@ void OConnection::impl_fillTableFilter()
}
}
-// -----------------------------------------------------------------------------
void OConnection::refresh(const Reference< XNameAccess >& _rToBeRefreshed)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::refresh" );
@@ -654,10 +614,8 @@ void OConnection::refresh(const Reference< XNameAccess >& _rToBeRefreshed)
}
}
}
-// -----------------------------------------------------------------------------
// XTablesSupplier
-//------------------------------------------------------------------------------
Reference< XNameAccess > OConnection::getTables() throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getTables" );
@@ -668,7 +626,7 @@ Reference< XNameAccess > OConnection::getTables() throw( RuntimeException )
return m_pTables;
}
-// -----------------------------------------------------------------------------
+
Reference< XNameAccess > SAL_CALL OConnection::getViews( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getViews" );
@@ -680,7 +638,6 @@ Reference< XNameAccess > SAL_CALL OConnection::getViews( ) throw(RuntimeExcepti
return m_pViews;
}
// XQueriesSupplier
-//------------------------------------------------------------------------------
Reference< XNameAccess > OConnection::getQueries(void) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getQueries" );
@@ -691,7 +648,6 @@ Reference< XNameAccess > OConnection::getQueries(void) throw( RuntimeException
}
// ::com::sun::star::sdb::XCommandPreparation
-//------------------------------------------------------------------------------
Reference< XPreparedStatement > SAL_CALL OConnection::prepareCommand( const ::rtl::OUString& command, sal_Int32 commandType ) throw(::com::sun::star::sdbc::SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::prepareCommand" );
@@ -723,13 +679,13 @@ Reference< XPreparedStatement > SAL_CALL OConnection::prepareCommand( const ::r
// TODO EscapeProcessing
return prepareStatement(aStatement);
}
-// -----------------------------------------------------------------------------
+
Reference< XInterface > SAL_CALL OConnection::createInstance( const ::rtl::OUString& _sServiceSpecifier ) throw (Exception, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::createInstance" );
Reference< XServiceInfo > xRet;
if ( ( SERVICE_NAME_SINGLESELECTQUERYCOMPOSER == _sServiceSpecifier )
- || ( _sServiceSpecifier.equalsAscii( "com.sun.star.sdb.SingleSelectQueryAnalyzer" ) )
+ || ( _sServiceSpecifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sdb.SingleSelectQueryAnalyzer" ) ) )
)
{
xRet = new OSingleSelectQueryComposer( getTables(),this, m_aContext );
@@ -752,13 +708,13 @@ Reference< XInterface > SAL_CALL OConnection::createInstance( const ::rtl::OUStr
}
return Reference< XInterface >(xRet,UNO_QUERY);
}
-// -----------------------------------------------------------------------------
+
Reference< XInterface > SAL_CALL OConnection::createInstanceWithArguments( const ::rtl::OUString& _sServiceSpecifier, const Sequence< Any >& /*Arguments*/ ) throw (Exception, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::createInstanceWithArguments" );
return createInstance(_sServiceSpecifier);
}
-// -----------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > SAL_CALL OConnection::getAvailableServiceNames( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getAvailableServiceNames" );
@@ -766,7 +722,7 @@ Sequence< ::rtl::OUString > SAL_CALL OConnection::getAvailableServiceNames( ) t
aRet[0] = SERVICE_NAME_SINGLESELECTQUERYCOMPOSER;
return aRet;
}
-// -----------------------------------------------------------------------------
+
Reference< XTablesSupplier > OConnection::getMasterTables()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getMasterTables" );
@@ -779,13 +735,13 @@ Reference< XTablesSupplier > OConnection::getMasterTables()
if ( xMeta.is() )
m_xMasterTables = ::dbtools::getDataDefinitionByURLAndConnection( xMeta->getURL(), m_xMasterConnection, m_aContext.getLegacyServiceFactory() );
}
- catch(SQLException&)
+ catch(const SQLException&)
{
}
}
return m_xMasterTables;
}
-// -----------------------------------------------------------------------------
+
// XUsersSupplier
Reference< XNameAccess > SAL_CALL OConnection::getUsers( ) throw(RuntimeException)
{
@@ -796,7 +752,7 @@ Reference< XNameAccess > SAL_CALL OConnection::getUsers( ) throw(RuntimeExcepti
Reference<XUsersSupplier> xUsr(getMasterTables(),UNO_QUERY);
return xUsr.is() ? xUsr->getUsers() : Reference< XNameAccess >();
}
-// -----------------------------------------------------------------------------
+
// XGroupsSupplier
Reference< XNameAccess > SAL_CALL OConnection::getGroups( ) throw(RuntimeException)
{
@@ -807,7 +763,6 @@ Reference< XNameAccess > SAL_CALL OConnection::getGroups( ) throw(RuntimeExcept
return xGrp.is() ? xGrp->getGroups() : Reference< XNameAccess >();
}
-// -----------------------------------------------------------------------------
void OConnection::impl_loadConnectionTools_throw()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::impl_loadConnectionTools_throw" );
@@ -818,7 +773,6 @@ void OConnection::impl_loadConnectionTools_throw()
throw RuntimeException( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "service not registered: com.sun.star.sdb.tools.ConnectionTools" ) ), *this );
}
-// -----------------------------------------------------------------------------
Reference< XTableName > SAL_CALL OConnection::createTableName( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::createTableName" );
@@ -829,7 +783,6 @@ Reference< XTableName > SAL_CALL OConnection::createTableName( ) throw (Runtime
return m_xConnectionTools->createTableName();
}
-// -----------------------------------------------------------------------------
Reference< XObjectNames > SAL_CALL OConnection::getObjectNames( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getObjectNames" );
@@ -840,7 +793,6 @@ Reference< XObjectNames > SAL_CALL OConnection::getObjectNames( ) throw (Runtim
return m_xConnectionTools->getObjectNames();
}
-// -----------------------------------------------------------------------------
Reference< XDataSourceMetaData > SAL_CALL OConnection::getDataSourceMetaData( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getDataSourceMetaData" );
@@ -850,7 +802,7 @@ Reference< XDataSourceMetaData > SAL_CALL OConnection::getDataSourceMetaData( )
return m_xConnectionTools->getDataSourceMetaData();
}
-// -----------------------------------------------------------------------------
+
Reference< ::com::sun::star::container::XNameAccess > SAL_CALL OConnection::getFieldsByCommandDescriptor( ::sal_Int32 commandType, const ::rtl::OUString& command, ::com::sun::star::uno::Reference< ::com::sun::star::lang::XComponent >& keepFieldsAlive ) throw (::com::sun::star::sdbc::SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getFieldsByCommandDescriptor" );
@@ -860,7 +812,7 @@ Reference< ::com::sun::star::container::XNameAccess > SAL_CALL OConnection::getF
return m_xConnectionTools->getFieldsByCommandDescriptor(commandType,command,keepFieldsAlive);
}
-//--------------------------------------------------------------------
+
Reference< XSingleSelectQueryComposer > SAL_CALL OConnection::getComposer( ::sal_Int32 commandType, const ::rtl::OUString& command ) throw (::com::sun::star::uno::RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getComposer" );
@@ -871,7 +823,6 @@ Reference< XSingleSelectQueryComposer > SAL_CALL OConnection::getComposer( ::sal
return m_xConnectionTools->getComposer(commandType,command);
}
-// -----------------------------------------------------------------------------
void OConnection::impl_checkTableQueryNames_nothrow()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::impl_checkTableQueryNames_nothrow" );
@@ -907,7 +858,6 @@ void OConnection::impl_checkTableQueryNames_nothrow()
}
}
-// -----------------------------------------------------------------------------
Reference< XGraphic > SAL_CALL OConnection::getTableIcon( const ::rtl::OUString& _TableName, ::sal_Int32 _ColorMode ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getTableIcon" );
@@ -925,7 +875,6 @@ Reference< XGraphic > SAL_CALL OConnection::getTableIcon( const ::rtl::OUString&
return xReturn;
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL OConnection::getTableEditor( const Reference< XDatabaseDocumentUI >& _DocumentUI, const ::rtl::OUString& _TableName ) throw (IllegalArgumentException, WrappedTargetException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "OConnection::getTableEditor" );
@@ -943,8 +892,5 @@ Reference< XInterface > SAL_CALL OConnection::getTableEditor( const Reference< X
return xReturn;
}
-
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/connection.hxx b/dbaccess/source/core/dataaccess/connection.hxx
index eb80cc2fc7db..20488aa13e1c 100644
--- a/dbaccess/source/core/dataaccess/connection.hxx
+++ b/dbaccess/source/core/dataaccess/connection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -250,3 +251,4 @@ private:
#endif // _DBA_CORE_CONNECTION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/dataaccessdescriptor.cxx b/dbaccess/source/core/dataaccess/dataaccessdescriptor.cxx
index ad5078825a16..0a5432f79db7 100644
--- a/dbaccess/source/core/dataaccess/dataaccessdescriptor.cxx
+++ b/dbaccess/source/core/dataaccess/dataaccessdescriptor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -144,7 +145,6 @@ namespace dbaccess
#define REGISTER_PROPERTY( propname, member ) \
registerProperty( PROPERTY_##propname, PROPERTY_ID_##propname, PropertyAttribute::BOUND, &member, ::getCppuType( &member ) )
- //--------------------------------------------------------------------
DataAccessDescriptor::DataAccessDescriptor( const ::comphelper::ComponentContext& _rContext )
:DataAccessDescriptor_MutexBase()
,DataAccessDescriptor_TypeBase()
@@ -187,24 +187,19 @@ namespace dbaccess
REGISTER_PROPERTY( COLUMN, m_xColumn );
}
- //--------------------------------------------------------------------
DataAccessDescriptor::~DataAccessDescriptor()
{
}
- //--------------------------------------------------------------------
IMPLEMENT_FORWARD_XINTERFACE2( DataAccessDescriptor, DataAccessDescriptor_TypeBase, DataAccessDescriptor_PropertyBase );
- //--------------------------------------------------------------------
IMPLEMENT_FORWARD_XTYPEPROVIDER2( DataAccessDescriptor, DataAccessDescriptor_TypeBase, DataAccessDescriptor_PropertyBase );
- //--------------------------------------------------------------------
::rtl::OUString SAL_CALL DataAccessDescriptor::getImplementationName() throw (RuntimeException)
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.dba.DataAccessDescriptor" ) );
}
- //--------------------------------------------------------------------
::sal_Bool SAL_CALL DataAccessDescriptor::supportsService( const ::rtl::OUString& rServiceName ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aServices( getSupportedServiceNames() );
@@ -213,7 +208,6 @@ namespace dbaccess
return ::std::find( pStart, pEnd, rServiceName ) != pEnd;
}
- //--------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL DataAccessDescriptor::getSupportedServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aServices(1);
@@ -221,20 +215,17 @@ namespace dbaccess
return aServices;
}
- //-------------------------------------------------------------------------
Reference< XPropertySetInfo > SAL_CALL DataAccessDescriptor::getPropertySetInfo() throw(RuntimeException)
{
Reference< XPropertySetInfo > xInfo( createPropertySetInfo( getInfoHelper() ) );
return xInfo;
}
- //-------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& DataAccessDescriptor::getInfoHelper()
{
return *getArrayHelper();
}
- //------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* DataAccessDescriptor::createArrayHelper( ) const
{
Sequence< Property > aProps;
@@ -273,24 +264,20 @@ namespace dbaccess
::comphelper::ComponentContext m_aContext;
};
- //--------------------------------------------------------------------
DataAccessDescriptorFactory::DataAccessDescriptorFactory( const Reference< XComponentContext >& _rxContext )
:m_aContext( _rxContext )
{
}
- //--------------------------------------------------------------------
DataAccessDescriptorFactory::~DataAccessDescriptorFactory()
{
}
- //--------------------------------------------------------------------
::rtl::OUString DataAccessDescriptorFactory::getSingletonName_static()
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.DataAccessDescriptorFactory" ) );
}
- //--------------------------------------------------------------------
Sequence< ::rtl::OUString > DataAccessDescriptorFactory::getSupportedServiceNames_static() throw( RuntimeException )
{
Sequence< ::rtl::OUString > aServices(1);
@@ -298,25 +285,21 @@ namespace dbaccess
return aServices;
}
- //--------------------------------------------------------------------
::rtl::OUString DataAccessDescriptorFactory::getImplementationName_static() throw( RuntimeException )
{
return ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.comp.dba.DataAccessDescriptorFactory" ) );
}
- //--------------------------------------------------------------------
Reference< XInterface > DataAccessDescriptorFactory::Create( const Reference< XComponentContext >& _rxContext )
{
return *( new DataAccessDescriptorFactory( _rxContext ) );
}
- //--------------------------------------------------------------------
::rtl::OUString SAL_CALL DataAccessDescriptorFactory::getImplementationName() throw (RuntimeException)
{
return getImplementationName_static();
}
- //--------------------------------------------------------------------
::sal_Bool SAL_CALL DataAccessDescriptorFactory::supportsService( const ::rtl::OUString& rServiceName ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aServices( getSupportedServiceNames_static() );
@@ -325,24 +308,21 @@ namespace dbaccess
return ::std::find( pStart, pEnd, rServiceName ) != pEnd;
}
- //--------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL DataAccessDescriptorFactory::getSupportedServiceNames( ) throw (RuntimeException)
{
return getSupportedServiceNames_static();
}
- //--------------------------------------------------------------------
Reference< XPropertySet > SAL_CALL DataAccessDescriptorFactory::createDataAccessDescriptor( ) throw (RuntimeException)
{
return new DataAccessDescriptor( m_aContext );
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-//--------------------------------------------------------------------------
extern "C" void SAL_CALL createRegistryInfo_DataAccessDescriptorFactory()
{
static ::dba::OSingletonRegistration< ::dbaccess::DataAccessDescriptorFactory > aAutoRegistration;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/databasecontext.cxx b/dbaccess/source/core/dataaccess/databasecontext.cxx
index 315cbcca3b7e..5069c338c43b 100644
--- a/dbaccess/source/core/dataaccess/databasecontext.cxx
+++ b/dbaccess/source/core/dataaccess/databasecontext.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -100,19 +101,10 @@ using ::com::sun::star::ucb::InteractiveIOException;
using ::com::sun::star::ucb::IOErrorCode_NOT_EXISTING;
using ::com::sun::star::ucb::IOErrorCode_NOT_EXISTING_PATH;
-//==========================================================================
-extern "C" void SAL_CALL createRegistryInfo_ODatabaseContext()
-{
- static ::dba::OLegacySingletonRegistration< ::dbaccess::ODatabaseContext > aODatabaseContext_AutoRegistration;
-}
-
-//........................................................................
namespace dbaccess
{
-//........................................................................
- // .............................................................................
typedef ::cppu::WeakImplHelper1 < XTerminateListener
> DatabaseDocumentLoader_Base;
class DatabaseDocumentLoader : public DatabaseDocumentLoader_Base
@@ -138,7 +130,6 @@ namespace dbaccess
virtual void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw (::com::sun::star::uno::RuntimeException);
};
- // .............................................................................
DatabaseDocumentLoader::DatabaseDocumentLoader( const comphelper::ComponentContext& _aContext )
{
acquire();
@@ -164,7 +155,7 @@ namespace dbaccess
{
Reference<util::XCloseable> xCloseable(xModel,UNO_QUERY_THROW);
xCloseable->close(sal_False);
- } // if ( !xModel->getControllers()->hasMoreElements() )
+ }
}
catch(const CloseVetoException&)
{
@@ -172,25 +163,24 @@ namespace dbaccess
}
}
};
- // .............................................................................
+
void SAL_CALL DatabaseDocumentLoader::queryTermination( const lang::EventObject& /*Event*/ ) throw (TerminationVetoException, RuntimeException)
{
::std::list< const ODatabaseModelImpl* > aCopy(m_aDatabaseDocuments);
::std::for_each(aCopy.begin(),aCopy.end(),TerminateFunctor());
}
- // .............................................................................
void SAL_CALL DatabaseDocumentLoader::notifyTermination( const lang::EventObject& /*Event*/ ) throw (RuntimeException)
{
}
- // .............................................................................
+
void SAL_CALL DatabaseDocumentLoader::disposing( const lang::EventObject& /*Source*/ ) throw (RuntimeException)
{
}
//= ODatabaseContext
//==========================================================================
-//--------------------------------------------------------------------------
+
ODatabaseContext::ODatabaseContext( const Reference< XComponentContext >& _rxContext )
:DatabaseAccessContext_Base(m_aMutex)
,m_aContext( _rxContext )
@@ -209,7 +199,6 @@ ODatabaseContext::ODatabaseContext( const Reference< XComponentContext >& _rxCon
osl_decrementInterlockedCount( &m_refCount );
}
-//--------------------------------------------------------------------------
ODatabaseContext::~ODatabaseContext()
{
::basic::BasicManagerRepository::revokeCreationListener( *this );
@@ -222,20 +211,17 @@ ODatabaseContext::~ODatabaseContext()
}
// Helper
-//------------------------------------------------------------------------------
rtl::OUString ODatabaseContext::getImplementationName_static() throw( RuntimeException )
{
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dba.ODatabaseContext"));
}
-//------------------------------------------------------------------------------
Reference< XInterface > ODatabaseContext::Create(const Reference< XComponentContext >& _rxContext)
{
return *( new ODatabaseContext( _rxContext ) );
}
-//------------------------------------------------------------------------------
Sequence< rtl::OUString > ODatabaseContext::getSupportedServiceNames_static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString > aSNS( 1 );
@@ -244,25 +230,21 @@ Sequence< rtl::OUString > ODatabaseContext::getSupportedServiceNames_static(void
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString ODatabaseContext::getImplementationName( ) throw(RuntimeException)
{
return getImplementationName_static();
}
-//------------------------------------------------------------------------------
sal_Bool ODatabaseContext::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > ODatabaseContext::getSupportedServiceNames( ) throw (RuntimeException)
{
return getSupportedServiceNames_static();
}
-//--------------------------------------------------------------------------
Reference< XInterface > ODatabaseContext::impl_createNewDataSource()
{
::rtl::Reference<ODatabaseModelImpl> pImpl( new ODatabaseModelImpl( m_aContext.getLegacyServiceFactory(), *this ) );
@@ -271,7 +253,6 @@ Reference< XInterface > ODatabaseContext::impl_createNewDataSource()
return xDataSource.get();
}
-//--------------------------------------------------------------------------
Reference< XInterface > SAL_CALL ODatabaseContext::createInstance( ) throw (Exception, RuntimeException)
{
// for convenience of the API user, we ensure the document is fully initialized (effectively: XLoadable::initNew
@@ -279,7 +260,6 @@ Reference< XInterface > SAL_CALL ODatabaseContext::createInstance( ) throw (Exc
return impl_createNewDataSource();
}
-//--------------------------------------------------------------------------
Reference< XInterface > SAL_CALL ODatabaseContext::createInstanceWithArguments( const Sequence< Any >& _rArguments ) throw (Exception, RuntimeException)
{
::comphelper::NamedValueCollection aArgs( _rArguments );
@@ -294,8 +274,8 @@ Reference< XInterface > SAL_CALL ODatabaseContext::createInstanceWithArguments(
return xDataSource;
}
+
// DatabaseAccessContext_Base
-//------------------------------------------------------------------------------
void ODatabaseContext::disposing()
{
// notify our listener
@@ -315,7 +295,6 @@ void ODatabaseContext::disposing()
}
// XNamingService
-//------------------------------------------------------------------------------
Reference< XInterface > ODatabaseContext::getRegisteredObject(const rtl::OUString& _rName) throw( Exception, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -334,7 +313,7 @@ Reference< XInterface > ODatabaseContext::getRegisteredObject(const rtl::OUStri
return loadObjectFromURL( _rName, sURL );
}
-// -----------------------------------------------------------------------------
+
Reference< XInterface > ODatabaseContext::loadObjectFromURL(const ::rtl::OUString& _rName,const ::rtl::OUString& _sURL)
{
INetURLObject aURL( _sURL );
@@ -399,17 +378,17 @@ Reference< XInterface > ODatabaseContext::loadObjectFromURL(const ::rtl::OUStrin
return pModelImpl->getOrCreateDataSource().get();
}
-// -----------------------------------------------------------------------------
+
void ODatabaseContext::appendAtTerminateListener(const ODatabaseModelImpl& _rDataSourceModel)
{
m_pDatabaseDocumentLoader->append(_rDataSourceModel);
}
-// -----------------------------------------------------------------------------
+
void ODatabaseContext::removeFromTerminateListener(const ODatabaseModelImpl& _rDataSourceModel)
{
m_pDatabaseDocumentLoader->remove(_rDataSourceModel);
}
-// -----------------------------------------------------------------------------
+
void ODatabaseContext::setTransientProperties(const ::rtl::OUString& _sURL, ODatabaseModelImpl& _rDataSourceModel )
{
if ( m_aDatasourceProperties.end() == m_aDatasourceProperties.find(_sURL) )
@@ -423,7 +402,7 @@ void ODatabaseContext::setTransientProperties(const ::rtl::OUString& _sURL, ODat
const PropertyValue* pPropsEnd = rSessionPersistentProps.getConstArray() + rSessionPersistentProps.getLength();
for ( ; pProp != pPropsEnd; ++pProp )
{
- if ( pProp->Name.equalsAscii( "AuthFailedPassword" ) )
+ if ( pProp->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "AuthFailedPassword" ) ) )
{
OSL_VERIFY( pProp->Value >>= sAuthFailedPassword );
}
@@ -441,7 +420,6 @@ void ODatabaseContext::setTransientProperties(const ::rtl::OUString& _sURL, ODat
}
}
-//------------------------------------------------------------------------------
void ODatabaseContext::registerObject(const rtl::OUString& _rName, const Reference< XInterface > & _rxObject) throw( Exception, RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -468,7 +446,6 @@ void ODatabaseContext::registerObject(const rtl::OUString& _rName, const Referen
m_aContainerListeners.notifyEach( &XContainerListener::elementInserted, aEvent );
}
-//------------------------------------------------------------------------------
void ODatabaseContext::storeTransientProperties( ODatabaseModelImpl& _rModelImpl)
{
Reference< XPropertySet > xSource( _rModelImpl.getOrCreateDataSource(), UNO_QUERY );
@@ -505,7 +482,7 @@ void ODatabaseContext::storeTransientProperties( ODatabaseModelImpl& _rModelImpl
}
// additionally, remember the "failed password", which is not available as property
- // #i86178# / 2008-02-19 / frank.schoenheit@sun.com
+ // #i86178#
aRememberProps.put( "AuthFailedPassword", _rModelImpl.m_sFailedPassword );
::rtl::OUString sDocumentURL( _rModelImpl.getURL() );
@@ -515,7 +492,7 @@ void ODatabaseContext::storeTransientProperties( ODatabaseModelImpl& _rModelImpl
}
else if ( m_aDatabaseObjects.find( _rModelImpl.m_sName ) != m_aDatabaseObjects.end() )
{
- OSL_ENSURE( false, "ODatabaseContext::storeTransientProperties: a database document register by name? This shouldn't happen anymore!" );
+ OSL_FAIL( "ODatabaseContext::storeTransientProperties: a database document register by name? This shouldn't happen anymore!" );
// all the code should have been changed so that registration is by URL only
m_aDatasourceProperties[ _rModelImpl.m_sName ] = aRememberProps.getPropertyValues();
}
@@ -526,19 +503,16 @@ void ODatabaseContext::storeTransientProperties( ODatabaseModelImpl& _rModelImpl
}
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseContext::addContainerListener( const Reference< XContainerListener >& _rxListener ) throw(RuntimeException)
{
m_aContainerListeners.addInterface(_rxListener);
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseContext::removeContainerListener( const Reference< XContainerListener >& _rxListener ) throw(RuntimeException)
{
m_aContainerListeners.removeInterface(_rxListener);
}
-//------------------------------------------------------------------------------
void ODatabaseContext::revokeObject(const rtl::OUString& _rName) throw( Exception, RuntimeException )
{
ClearableMutexGuard aGuard(m_aMutex);
@@ -565,68 +539,57 @@ void ODatabaseContext::revokeObject(const rtl::OUString& _rName) throw( Exceptio
m_aContainerListeners.notifyEach( &XContainerListener::elementRemoved, aEvent );
}
-//------------------------------------------------------------------------------
::sal_Bool SAL_CALL ODatabaseContext::hasRegisteredDatabase( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, RuntimeException)
{
return m_xDatabaseRegistrations->hasRegisteredDatabase( _Name );
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL ODatabaseContext::getRegistrationNames() throw (RuntimeException)
{
return m_xDatabaseRegistrations->getRegistrationNames();
}
-//------------------------------------------------------------------------------
::rtl::OUString SAL_CALL ODatabaseContext::getDatabaseLocation( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, NoSuchElementException, RuntimeException)
{
return m_xDatabaseRegistrations->getDatabaseLocation( _Name );
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseContext::registerDatabaseLocation( const ::rtl::OUString& _Name, const ::rtl::OUString& _Location ) throw (IllegalArgumentException, ElementExistException, RuntimeException)
{
m_xDatabaseRegistrations->registerDatabaseLocation( _Name, _Location );
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseContext::revokeDatabaseLocation( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, NoSuchElementException, IllegalAccessException, RuntimeException)
{
m_xDatabaseRegistrations->revokeDatabaseLocation( _Name );
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseContext::changeDatabaseLocation( const ::rtl::OUString& _Name, const ::rtl::OUString& _NewLocation ) throw (IllegalArgumentException, NoSuchElementException, IllegalAccessException, RuntimeException)
{
m_xDatabaseRegistrations->changeDatabaseLocation( _Name, _NewLocation );
}
-//------------------------------------------------------------------------------
::sal_Bool SAL_CALL ODatabaseContext::isDatabaseRegistrationReadOnly( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, NoSuchElementException, RuntimeException)
{
return m_xDatabaseRegistrations->isDatabaseRegistrationReadOnly( _Name );
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseContext::addDatabaseRegistrationsListener( const Reference< XDatabaseRegistrationsListener >& _Listener ) throw (RuntimeException)
{
m_xDatabaseRegistrations->addDatabaseRegistrationsListener( _Listener );
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseContext::removeDatabaseRegistrationsListener( const Reference< XDatabaseRegistrationsListener >& _Listener ) throw (RuntimeException)
{
m_xDatabaseRegistrations->removeDatabaseRegistrationsListener( _Listener );
}
// ::com::sun::star::container::XElementAccess
-//------------------------------------------------------------------------------
Type ODatabaseContext::getElementType( ) throw(RuntimeException)
{
return::getCppuType(static_cast<Reference<XDataSource>*>(NULL));
}
-//------------------------------------------------------------------------------
sal_Bool ODatabaseContext::hasElements(void) throw( RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -636,7 +599,6 @@ sal_Bool ODatabaseContext::hasElements(void) throw( RuntimeException )
}
// ::com::sun::star::container::XEnumerationAccess
-//------------------------------------------------------------------------------
Reference< ::com::sun::star::container::XEnumeration > ODatabaseContext::createEnumeration(void) throw( RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -644,7 +606,6 @@ Reference< ::com::sun::star::container::XEnumeration > ODatabaseContext::create
}
// ::com::sun::star::container::XNameAccess
-//------------------------------------------------------------------------------
Any ODatabaseContext::getByName(const rtl::OUString& _rName) throw( NoSuchElementException,
WrappedTargetException, RuntimeException )
{
@@ -695,7 +656,6 @@ Any ODatabaseContext::getByName(const rtl::OUString& _rName) throw( NoSuchElemen
}
}
-//------------------------------------------------------------------------------
Sequence< rtl::OUString > ODatabaseContext::getElementNames(void) throw( RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -704,7 +664,6 @@ Sequence< rtl::OUString > ODatabaseContext::getElementNames(void) throw( Runtime
return getRegistrationNames();
}
-//------------------------------------------------------------------------------
sal_Bool ODatabaseContext::hasByName(const rtl::OUString& _rName) throw( RuntimeException )
{
MutexGuard aGuard(m_aMutex);
@@ -713,7 +672,6 @@ sal_Bool ODatabaseContext::hasByName(const rtl::OUString& _rName) throw( Runtime
return hasRegisteredDatabase( _rName );
}
-// -----------------------------------------------------------------------------
Reference< XInterface > ODatabaseContext::getObject( const ::rtl::OUString& _rURL )
{
ObjectCacheIterator aFind = m_aDatabaseObjects.find( _rURL );
@@ -722,7 +680,7 @@ Reference< XInterface > ODatabaseContext::getObject( const ::rtl::OUString& _rUR
xExistent = aFind->second->getOrCreateDataSource();
return xExistent;
}
-// -----------------------------------------------------------------------------
+
void ODatabaseContext::registerDatabaseDocument( ODatabaseModelImpl& _rModelImpl )
{
::rtl::OUString sURL( _rModelImpl.getURL() );
@@ -735,9 +693,9 @@ void ODatabaseContext::registerDatabaseDocument( ODatabaseModelImpl& _rModelImpl
setTransientProperties( sURL, _rModelImpl );
}
else
- OSL_ENSURE( false, "ODatabaseContext::registerDatabaseDocument: already have an object registered for this URL!" );
+ OSL_FAIL( "ODatabaseContext::registerDatabaseDocument: already have an object registered for this URL!" );
}
-// -----------------------------------------------------------------------------
+
void ODatabaseContext::revokeDatabaseDocument( const ODatabaseModelImpl& _rModelImpl )
{
::rtl::OUString sURL( _rModelImpl.getURL() );
@@ -746,7 +704,7 @@ void ODatabaseContext::revokeDatabaseDocument( const ODatabaseModelImpl& _rModel
#endif
m_aDatabaseObjects.erase( sURL );
}
-// -----------------------------------------------------------------------------
+
void ODatabaseContext::databaseDocumentURLChange( const ::rtl::OUString& _rOldURL, const ::rtl::OUString& _rNewURL )
{
#if OSL_DEBUG_LEVEL > 1
@@ -762,7 +720,7 @@ void ODatabaseContext::databaseDocumentURLChange( const ::rtl::OUString& _rOldUR
m_aDatabaseObjects[ _rNewURL ] = oldPos->second;
m_aDatabaseObjects.erase( oldPos );
}
-// -----------------------------------------------------------------------------
+
sal_Int64 SAL_CALL ODatabaseContext::getSomething( const Sequence< sal_Int8 >& rId ) throw(RuntimeException)
{
if (rId.getLength() == 16 && 0 == rtl_compareMemory(getUnoTunnelImplementationId().getConstArray(), rId.getConstArray(), 16 ) )
@@ -770,7 +728,7 @@ sal_Int64 SAL_CALL ODatabaseContext::getSomething( const Sequence< sal_Int8 >& r
return 0;
}
-// -----------------------------------------------------------------------------
+
Sequence< sal_Int8 > ODatabaseContext::getUnoTunnelImplementationId()
{
static ::cppu::OImplementationId * pId = 0;
@@ -786,7 +744,6 @@ Sequence< sal_Int8 > ODatabaseContext::getUnoTunnelImplementationId()
return pId->getImplementationId();
}
-// -----------------------------------------------------------------------------
void ODatabaseContext::onBasicManagerCreated( const Reference< XModel >& _rxForDocument, BasicManager& _rBasicManager )
{
// if it's a database document ...
@@ -804,6 +761,5 @@ void ODatabaseContext::onBasicManagerCreated( const Reference< XModel >& _rxForD
_rBasicManager.SetGlobalUNOConstant( "ThisDatabaseDocument", makeAny( xDatabaseDocument ) );
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/databasecontext.hxx b/dbaccess/source/core/dataaccess/databasecontext.hxx
index dc55ff62b694..e7dbf9417e7e 100644
--- a/dbaccess/source/core/dataaccess/databasecontext.hxx
+++ b/dbaccess/source/core/dataaccess/databasecontext.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -91,7 +92,6 @@ private:
/** loads the given object from the given URL
@throws WrappedTargetException
if an error occurs accessing the URL via the UCB
-
*/
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > loadObjectFromURL(const ::rtl::OUString& _rName,const ::rtl::OUString& _sURL);
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > getObject( const ::rtl::OUString& _rURL );
@@ -211,3 +211,4 @@ private:
#endif // _DBA_COREDATAACCESS_DATABASECONTEXT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/databasedocument.cxx b/dbaccess/source/core/dataaccess/databasedocument.cxx
index 125c54121628..d8132a543e28 100644
--- a/dbaccess/source/core/dataaccess/databasedocument.cxx
+++ b/dbaccess/source/core/dataaccess/databasedocument.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -84,6 +85,7 @@
#include <unotools/saveopt.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <tools/errcode.hxx>
#include <tools/urlobj.hxx>
@@ -95,8 +97,6 @@
#define MAP_LEN(x) x, sizeof(x) - 1
-#define MAP_LEN(x) x, sizeof(x) - 1
-
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::frame;
@@ -121,15 +121,13 @@ using ::com::sun::star::awt::XWindow;
using ::com::sun::star::ucb::XContent;
using ::com::sun::star::sdb::application::XDatabaseDocumentUI;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//============================================================
//= ViewMonitor
//============================================================
-//--------------------------------------------------------------------------
+
bool ViewMonitor::onControllerConnected( const Reference< XController >& _rxController )
{
bool bFirstControllerEver = ( m_bEverHadController == false );
@@ -141,7 +139,6 @@ bool ViewMonitor::onControllerConnected( const Reference< XController >& _rxCont
return bFirstControllerEver;
}
-//--------------------------------------------------------------------------
bool ViewMonitor::onSetCurrentController( const Reference< XController >& _rxController )
{
// we interpret this as "loading the document (including UI) is finished",
@@ -160,13 +157,12 @@ bool ViewMonitor::onSetCurrentController( const Reference< XController >& _rxCon
//= ODatabaseDocument
//============================================================
DBG_NAME(ODatabaseDocument)
-//--------------------------------------------------------------------------
+
extern "C" void SAL_CALL createRegistryInfo_ODatabaseDocument()
{
static ::dba::OAutoRegistration< ODatabaseDocument > aAutoRegistration;
}
-//--------------------------------------------------------------------------
ODatabaseDocument::ODatabaseDocument(const ::rtl::Reference<ODatabaseModelImpl>& _pImpl )
:ModelDependentComponent( _pImpl )
,ODatabaseDocument_OfficeDocument( getMutex() )
@@ -210,13 +206,12 @@ ODatabaseDocument::ODatabaseDocument(const ::rtl::Reference<ODatabaseModelImpl>&
{
// if the previous incarnation of the DatabaseDocument already had an URL, then creating this incarnation
// here is effectively loading the document.
- // #i105505# / 2009-10-01 / frank.schoenheit@sun.com
+ // #i105505#
m_aViewMonitor.onLoadedDocument();
}
}
}
-//--------------------------------------------------------------------------
ODatabaseDocument::~ODatabaseDocument()
{
OSL_TRACE( "DD: dtor: %p: %p", this, m_pImpl.get() );
@@ -229,7 +224,7 @@ ODatabaseDocument::~ODatabaseDocument()
delete m_pEventContainer, m_pEventContainer = NULL;
}
-// -----------------------------------------------------------------------------
+
Any SAL_CALL ODatabaseDocument::queryInterface( const Type& _rType ) throw (RuntimeException)
{
// strip XEmbeddedScripts and XScriptInvocationContext if we have any form/report
@@ -247,18 +242,17 @@ Any SAL_CALL ODatabaseDocument::queryInterface( const Type& _rType ) throw (Runt
aReturn = ODatabaseDocument_Title::queryInterface(_rType);
return aReturn;
}
-//------------------------------------------------------------------------------
+
void SAL_CALL ODatabaseDocument::acquire( ) throw ()
{
ODatabaseDocument_OfficeDocument::acquire();
}
-//------------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::release( ) throw ()
{
ODatabaseDocument_OfficeDocument::release();
}
-//------------------------------------------------------------------------------
+
Sequence< Type > SAL_CALL ODatabaseDocument::getTypes( ) throw (RuntimeException)
{
Sequence< Type > aTypes = ::comphelper::concatSequences(
@@ -299,7 +293,7 @@ Sequence< Type > SAL_CALL ODatabaseDocument::getTypes( ) throw (RuntimeExceptio
return aTypes;
}
-//------------------------------------------------------------------------------
+
Sequence< sal_Int8 > SAL_CALL ODatabaseDocument::getImplementationId( ) throw (RuntimeException)
{
static ::cppu::OImplementationId * pId = 0;
@@ -315,19 +309,15 @@ Sequence< sal_Int8 > SAL_CALL ODatabaseDocument::getImplementationId( ) throw (
return pId->getImplementationId();
}
-// -----------------------------------------------------------------------------
// local functions
-// -----------------------------------------------------------------------------
namespace
{
- // -----------------------------------------------------------------------------
Reference< XStatusIndicator > lcl_extractStatusIndicator( const ::comphelper::NamedValueCollection& _rArguments )
{
Reference< XStatusIndicator > xStatusIndicator;
return _rArguments.getOrDefault( "StatusIndicator", xStatusIndicator );
}
- // -----------------------------------------------------------------------------
static void lcl_triggerStatusIndicator_throw( const ::comphelper::NamedValueCollection& _rArguments, DocumentGuard& _rGuard, const bool _bStart )
{
Reference< XStatusIndicator > xStatusIndicator( lcl_extractStatusIndicator( _rArguments ) );
@@ -350,7 +340,6 @@ namespace
// note that |reset| can throw a DisposedException
}
- // -----------------------------------------------------------------------------
static void lcl_extractStatusIndicator( const ::comphelper::NamedValueCollection& _rArguments, Sequence< Any >& _rCallArgs )
{
Reference< XStatusIndicator > xStatusIndicator( lcl_extractStatusIndicator( _rArguments ) );
@@ -362,7 +351,6 @@ namespace
_rCallArgs[ nLength ] <<= xStatusIndicator;
}
- // -----------------------------------------------------------------------------
static void lcl_extractAndStartStatusIndicator( const ::comphelper::NamedValueCollection& _rArguments, Reference< XStatusIndicator >& _rxStatusIndicator,
Sequence< Any >& _rCallArgs )
{
@@ -384,7 +372,6 @@ namespace
}
}
- // -----------------------------------------------------------------------------
static Sequence< PropertyValue > lcl_appendFileNameToDescriptor( const ::comphelper::NamedValueCollection& _rDescriptor, const ::rtl::OUString _rURL )
{
::comphelper::NamedValueCollection aMutableDescriptor( _rDescriptor );
@@ -397,7 +384,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_setInitialized()
{
m_eInitState = Initialized;
@@ -406,7 +392,6 @@ void ODatabaseDocument::impl_setInitialized()
m_aEventNotifier.onDocumentInitialized();
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_reset_nothrow()
{
try
@@ -431,7 +416,6 @@ void ODatabaseDocument::impl_reset_nothrow()
m_pImpl->m_bDocumentReadOnly = sal_False;
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_import_nolck_throw( const ::comphelper::ComponentContext _rContext, const Reference< XInterface >& _rxTargetComponent,
const ::comphelper::NamedValueCollection& _rResource )
{
@@ -469,7 +453,6 @@ void ODatabaseDocument::impl_import_nolck_throw( const ::comphelper::ComponentCo
xStatusIndicator->end();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::initNew( ) throw (DoubleInitializationException, IOException, Exception, RuntimeException)
{
// SYNCHRONIZED ->
@@ -504,7 +487,6 @@ void SAL_CALL ODatabaseDocument::initNew( ) throw (DoubleInitializationExceptio
impl_notifyStorageChange_nolck_nothrow( xTempStor );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::load( const Sequence< PropertyValue >& _Arguments ) throw (DoubleInitializationException, IOException, Exception, RuntimeException)
{
// SYNCHRONIZED ->
@@ -550,10 +532,8 @@ void SAL_CALL ODatabaseDocument::load( const Sequence< PropertyValue >& _Argumen
// <- SYNCHRONIZED
}
-// -----------------------------------------------------------------------------
namespace
{
- // .........................................................................
bool lcl_hasAnyModifiedSubComponent_throw( const Reference< XController >& i_rController )
{
Reference< XDatabaseDocumentUI > xDatabaseUI( i_rController, UNO_QUERY_THROW );
@@ -574,14 +554,13 @@ namespace
// TODO: clarify: anything else to care for? Both the sub componbents with and without model
// should support the XModifiable interface, so I think nothing more is needed here.
- OSL_ENSURE( false, "lcl_hasAnyModifiedSubComponent_throw: anything left to do here?" );
+ OSL_FAIL( "lcl_hasAnyModifiedSubComponent_throw: anything left to do here?" );
}
return isAnyModified;
}
}
-// -----------------------------------------------------------------------------
::sal_Bool SAL_CALL ODatabaseDocument::wasModifiedSinceLastSave() throw ( RuntimeException )
{
DocumentGuard aGuard( *this );
@@ -620,7 +599,6 @@ namespace
return sal_False;
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::storeToRecoveryFile( const ::rtl::OUString& i_TargetLocation, const Sequence< PropertyValue >& i_MediaDescriptor ) throw ( RuntimeException, IOException, WrappedTargetException )
{
DocumentGuard aGuard( *this );
@@ -657,7 +635,6 @@ void SAL_CALL ODatabaseDocument::storeToRecoveryFile( const ::rtl::OUString& i_T
}
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::recoverFromFile( const ::rtl::OUString& i_SourceLocation, const ::rtl::OUString& i_SalvagedFile, const Sequence< PropertyValue >& i_MediaDescriptor ) throw ( RuntimeException, IOException, WrappedTargetException )
{
DocumentGuard aGuard( *this, DocumentGuard::InitMethod );
@@ -706,7 +683,6 @@ void SAL_CALL ODatabaseDocument::recoverFromFile( const ::rtl::OUString& i_Sourc
}
}
-// -----------------------------------------------------------------------------
// XModel
sal_Bool SAL_CALL ODatabaseDocument::attachResource( const ::rtl::OUString& _rURL, const Sequence< PropertyValue >& _rArguments ) throw (RuntimeException)
{
@@ -714,7 +690,6 @@ sal_Bool SAL_CALL ODatabaseDocument::attachResource( const ::rtl::OUString& _rUR
return impl_attachResource( _rURL, _rArguments, aGuard );
}
-// -----------------------------------------------------------------------------
sal_Bool ODatabaseDocument::impl_attachResource( const ::rtl::OUString& i_rLogicalDocumentURL,
const Sequence< PropertyValue >& i_rMediaDescriptor, DocumentGuard& _rDocGuard )
{
@@ -756,21 +731,18 @@ sal_Bool ODatabaseDocument::impl_attachResource( const ::rtl::OUString& i_rLogic
return sal_True;
}
-// -----------------------------------------------------------------------------
::rtl::OUString SAL_CALL ODatabaseDocument::getURL( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodWithoutInit );
return m_pImpl->getURL();
}
-// -----------------------------------------------------------------------------
Sequence< PropertyValue > SAL_CALL ODatabaseDocument::getArgs( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodWithoutInit );
return m_pImpl->getMediaDescriptor().getPropertyValues();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::connectController( const Reference< XController >& _xController ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -797,7 +769,6 @@ void SAL_CALL ODatabaseDocument::connectController( const Reference< XController
m_pImpl->checkMacrosOnLoading();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::disconnectController( const Reference< XController >& _xController ) throw (RuntimeException)
{
bool bNotifyViewClosed = false;
@@ -830,7 +801,7 @@ void SAL_CALL ODatabaseDocument::disconnectController( const Reference< XControl
if ( bLastControllerGone && !bIsClosing )
{
// if this was the last view, close the document as a whole
- // #i51157# / 2006-03-16 / frank.schoenheit@sun.com
+ // #i51157#
try
{
close( sal_True );
@@ -842,7 +813,6 @@ void SAL_CALL ODatabaseDocument::disconnectController( const Reference< XControl
}
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::lockControllers( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -850,7 +820,6 @@ void SAL_CALL ODatabaseDocument::lockControllers( ) throw (RuntimeException)
++m_pImpl->m_nControllerLockCount;
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::unlockControllers( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -858,7 +827,6 @@ void SAL_CALL ODatabaseDocument::unlockControllers( ) throw (RuntimeException)
--m_pImpl->m_nControllerLockCount;
}
-// -----------------------------------------------------------------------------
sal_Bool SAL_CALL ODatabaseDocument::hasControllersLocked( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -866,7 +834,6 @@ sal_Bool SAL_CALL ODatabaseDocument::hasControllersLocked( ) throw (RuntimeExce
return m_pImpl->m_nControllerLockCount != 0;
}
-// -----------------------------------------------------------------------------
Reference< XController > SAL_CALL ODatabaseDocument::getCurrentController() throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -874,7 +841,6 @@ Reference< XController > SAL_CALL ODatabaseDocument::getCurrentController() thro
return m_xCurrentController.is() ? m_xCurrentController : ( m_aControllers.empty() ? Reference< XController >() : *m_aControllers.begin() );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::setCurrentController( const Reference< XController >& _xController ) throw (NoSuchElementException, RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -904,7 +870,6 @@ void SAL_CALL ODatabaseDocument::setCurrentController( const Reference< XControl
}
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL ODatabaseDocument::getCurrentSelection( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -916,14 +881,13 @@ Reference< XInterface > SAL_CALL ODatabaseDocument::getCurrentSelection( ) thro
return xRet;
}
-// -----------------------------------------------------------------------------
// XStorable
sal_Bool SAL_CALL ODatabaseDocument::hasLocation( ) throw (RuntimeException)
{
return getLocation().getLength() > 0;
}
-// -----------------------------------------------------------------------------
+
::rtl::OUString SAL_CALL ODatabaseDocument::getLocation( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodWithoutInit );
@@ -931,13 +895,13 @@ sal_Bool SAL_CALL ODatabaseDocument::hasLocation( ) throw (RuntimeException)
// both XStorable::getLocation and XModel::getURL have to return the URL of the document, *not*
// the location of the file which the docunment was possibly recovered from (which would be getDocFileLocation)
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL ODatabaseDocument::isReadonly( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodWithoutInit );
return m_pImpl->m_bDocumentReadOnly;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseDocument::store( ) throw (IOException, RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -975,7 +939,6 @@ void SAL_CALL ODatabaseDocument::store( ) throw (IOException, RuntimeException)
}
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_throwIOExceptionCausedBySave_throw( const Any& i_rError, const ::rtl::OUString& i_rTargetURL ) const
{
::rtl::OUString sErrorMessage = extractExceptionMessage( m_pImpl->m_aContext, i_rError );
@@ -987,7 +950,6 @@ void ODatabaseDocument::impl_throwIOExceptionCausedBySave_throw( const Any& i_rE
throw IOException( sErrorMessage, *const_cast< ODatabaseDocument* >( this ) );
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_storeAs_throw( const ::rtl::OUString& _rURL, const ::comphelper::NamedValueCollection& _rArguments,
const StoreType _eType, DocumentGuard& _rGuard ) throw ( IOException, RuntimeException )
{
@@ -1090,11 +1052,10 @@ void ODatabaseDocument::impl_storeAs_throw( const ::rtl::OUString& _rURL, const
impl_notifyStorageChange_nolck_nothrow( xNewRootStorage );
}
-// -----------------------------------------------------------------------------
Reference< XStorage > ODatabaseDocument::impl_createStorageFor_throw( const ::rtl::OUString& _rURL ) const
{
Reference < ::com::sun::star::ucb::XSimpleFileAccess > xTempAccess;
- m_pImpl->m_aContext.createComponent( ::rtl::OUString::createFromAscii( "com.sun.star.ucb.SimpleFileAccess" ) ,xTempAccess);
+ m_pImpl->m_aContext.createComponent( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SimpleFileAccess")) ,xTempAccess);
Reference< io::XStream > xStream = xTempAccess->openFileReadWrite( _rURL );
Reference< io::XTruncate > xTruncate(xStream,UNO_QUERY);
if ( xTruncate.is() )
@@ -1109,7 +1070,6 @@ Reference< XStorage > ODatabaseDocument::impl_createStorageFor_throw( const ::rt
return Reference< XStorage >( xStorageFactory->createInstanceWithArguments( aParam ), UNO_QUERY_THROW );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::storeAsURL( const ::rtl::OUString& _rURL, const Sequence< PropertyValue >& _rArguments ) throw (IOException, RuntimeException)
{
// SYNCHRONIZED ->
@@ -1158,7 +1118,6 @@ void SAL_CALL ODatabaseDocument::storeAsURL( const ::rtl::OUString& _rURL, const
m_aEventNotifier.notifyDocumentEvent( "OnCreate" );
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_storeToStorage_throw( const Reference< XStorage >& _rxTargetStorage, const Sequence< PropertyValue >& _rMediaDescriptor,
DocumentGuard& _rDocGuard ) const
{
@@ -1199,7 +1158,6 @@ void ODatabaseDocument::impl_storeToStorage_throw( const Reference< XStorage >&
}
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::storeToURL( const ::rtl::OUString& _rURL, const Sequence< PropertyValue >& _rArguments ) throw (IOException, RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -1241,7 +1199,6 @@ void SAL_CALL ODatabaseDocument::storeToURL( const ::rtl::OUString& _rURL, const
m_aEventNotifier.notifyDocumentEventAsync( "OnSaveToDone", NULL, makeAny( _rURL ) );
}
-// -----------------------------------------------------------------------------
// XModifyBroadcaster
void SAL_CALL ODatabaseDocument::addModifyListener( const Reference< XModifyListener >& _xListener ) throw (RuntimeException)
{
@@ -1249,14 +1206,12 @@ void SAL_CALL ODatabaseDocument::addModifyListener( const Reference< XModifyList
m_aModifyListeners.addInterface(_xListener);
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::removeModifyListener( const Reference< XModifyListener >& _xListener ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
m_aModifyListeners.removeInterface(_xListener);
}
-// -----------------------------------------------------------------------------
// XModifiable
sal_Bool SAL_CALL ODatabaseDocument::isModified( ) throw (RuntimeException)
{
@@ -1265,7 +1220,6 @@ sal_Bool SAL_CALL ODatabaseDocument::isModified( ) throw (RuntimeException)
return m_pImpl->m_bModified;
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::setModified( sal_Bool _bModified ) throw (PropertyVetoException, RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodWithoutInit );
@@ -1276,7 +1230,6 @@ void SAL_CALL ODatabaseDocument::setModified( sal_Bool _bModified ) throw (Prope
// a proper "modified" flag
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_setModified_nothrow( sal_Bool _bModified, DocumentGuard& _rGuard )
{
// SYNCHRONIZED ->
@@ -1297,32 +1250,27 @@ void ODatabaseDocument::impl_setModified_nothrow( sal_Bool _bModified, DocumentG
}
}
-// -----------------------------------------------------------------------------
// ::com::sun::star::document::XEventBroadcaster
void SAL_CALL ODatabaseDocument::addEventListener(const uno::Reference< document::XEventListener >& _Listener ) throw (uno::RuntimeException)
{
m_aEventNotifier.addLegacyEventListener( _Listener );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::removeEventListener( const uno::Reference< document::XEventListener >& _Listener ) throw (uno::RuntimeException)
{
m_aEventNotifier.removeLegacyEventListener( _Listener );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::addDocumentEventListener( const Reference< XDocumentEventListener >& _Listener ) throw (RuntimeException)
{
m_aEventNotifier.addDocumentEventListener( _Listener );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::removeDocumentEventListener( const Reference< XDocumentEventListener >& _Listener ) throw (RuntimeException)
{
m_aEventNotifier.removeDocumentEventListener( _Listener );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::notifyDocumentEvent( const ::rtl::OUString& _EventName, const Reference< XController2 >& _ViewController, const Any& _Supplement ) throw (IllegalArgumentException, NoSupportException, RuntimeException)
{
if ( !_EventName.getLength() )
@@ -1342,33 +1290,29 @@ void SAL_CALL ODatabaseDocument::notifyDocumentEvent( const ::rtl::OUString& _Ev
m_aEventNotifier.notifyDocumentEvent( _EventName, _ViewController, _Supplement );
}
-// -----------------------------------------------------------------------------
Sequence< PropertyValue > SAL_CALL ODatabaseDocument::getPrinter( ) throw (RuntimeException)
{
- DBG_ERROR( "ODatabaseDocument::getPrinter: not supported!" );
+ OSL_FAIL( "ODatabaseDocument::getPrinter: not supported!" );
return Sequence< PropertyValue >();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::setPrinter( const Sequence< PropertyValue >& /*aPrinter*/ ) throw (IllegalArgumentException, RuntimeException)
{
- DBG_ERROR( "ODatabaseDocument::setPrinter: not supported!" );
+ OSL_FAIL( "ODatabaseDocument::setPrinter: not supported!" );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::print( const Sequence< PropertyValue >& /*xOptions*/ ) throw (IllegalArgumentException, RuntimeException)
{
- DBG_ERROR( "ODatabaseDocument::print: not supported!" );
+ OSL_FAIL( "ODatabaseDocument::print: not supported!" );
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_reparent_nothrow( const WeakReference< XNameAccess >& _rxContainer )
{
Reference< XChild > xChild( _rxContainer.get(), UNO_QUERY );
if ( xChild.is() )
xChild->setParent( *this );
}
-// -----------------------------------------------------------------------------
+
void ODatabaseDocument::clearObjectContainer( WeakReference< XNameAccess >& _rxContainer)
{
Reference< XNameAccess > xContainer = _rxContainer;
@@ -1379,7 +1323,7 @@ void ODatabaseDocument::clearObjectContainer( WeakReference< XNameAccess >& _rxC
xChild->setParent( NULL );
_rxContainer = Reference< XNameAccess >();
}
-// -----------------------------------------------------------------------------
+
Reference< XNameAccess > ODatabaseDocument::impl_getDocumentContainer_throw( ODatabaseModelImpl::ObjectType _eType )
{
if ( ( _eType != ODatabaseModelImpl::E_FORM ) && ( _eType != ODatabaseModelImpl::E_REPORT ) )
@@ -1415,7 +1359,6 @@ Reference< XNameAccess > ODatabaseDocument::impl_getDocumentContainer_throw( ODa
return xContainer;
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_closeControllerFrames_nolck_throw( sal_Bool _bDeliverOwnership )
{
Controllers aCopy = m_aControllers;
@@ -1440,7 +1383,6 @@ void ODatabaseDocument::impl_closeControllerFrames_nolck_throw( sal_Bool _bDeliv
}
}
-// -----------------------------------------------------------------------------
struct DisposeControllerFrame : public ::std::unary_function< Reference< XController >, void >
{
void operator()( const Reference< XController >& _rxController ) const
@@ -1460,7 +1402,6 @@ struct DisposeControllerFrame : public ::std::unary_function< Reference< XContro
};
};
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_disposeControllerFrames_nothrow()
{
Controllers aCopy;
@@ -1468,7 +1409,6 @@ void ODatabaseDocument::impl_disposeControllerFrames_nothrow()
::std::for_each( aCopy.begin(), aCopy.end(), DisposeControllerFrame() );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::close( sal_Bool _bDeliverOwnership ) throw (CloseVetoException, RuntimeException)
{
// nearly everything below can/must be done without our mutex locked, the below is just for
@@ -1508,32 +1448,31 @@ void SAL_CALL ODatabaseDocument::close( sal_Bool _bDeliverOwnership ) throw (Clo
m_bClosing = false;
// <- SYNCHRONIZED
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseDocument::addCloseListener( const Reference< ::com::sun::star::util::XCloseListener >& Listener ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
m_aCloseListener.addInterface(Listener);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseDocument::removeCloseListener( const Reference< ::com::sun::star::util::XCloseListener >& Listener ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
m_aCloseListener.removeInterface(Listener);
}
-// -----------------------------------------------------------------------------
+
Reference< XNameAccess > SAL_CALL ODatabaseDocument::getFormDocuments( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodUsedDuringInit );
return impl_getDocumentContainer_throw( ODatabaseModelImpl::E_FORM );
}
-// -----------------------------------------------------------------------------
+
Reference< XNameAccess > SAL_CALL ODatabaseDocument::getReportDocuments( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodUsedDuringInit );
return impl_getDocumentContainer_throw( ODatabaseModelImpl::E_REPORT );
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::WriteThroughComponent( const Reference< XComponent >& xComponent, const sal_Char* pStreamName,
const sal_Char* pServiceName, const Sequence< Any >& _rArguments, const Sequence< PropertyValue >& rMediaDesc,
const Reference<XStorage>& _xStorageToSaveTo ) const
@@ -1602,7 +1541,6 @@ void ODatabaseDocument::WriteThroughComponent( const Reference< XOutputStream >&
xFilter->filter( rMediaDesc );
}
-// -----------------------------------------------------------------------------
void ODatabaseDocument::impl_writeStorage_throw( const Reference< XStorage >& _rxTargetStorage, const ::comphelper::NamedValueCollection& _rMediaDescriptor ) const
{
// extract status indicator
@@ -1637,7 +1575,7 @@ void ODatabaseDocument::impl_writeStorage_throw( const Reference< XStorage >& _r
{
xInfoSet->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "Version" )), uno::makeAny( aVersion ) );
}
- catch( uno::Exception& )
+ catch( const uno::Exception& )
{
}
}
@@ -1665,7 +1603,6 @@ void ODatabaseDocument::impl_writeStorage_throw( const Reference< XStorage >& _r
m_pImpl->storeLibraryContainersTo( _rxTargetStorage );
}
-// -----------------------------------------------------------------------------
Reference< XUIConfigurationManager > SAL_CALL ODatabaseDocument::getUIConfigurationManager( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -1703,7 +1640,7 @@ Reference< XUIConfigurationManager > SAL_CALL ODatabaseDocument::getUIConfigurat
return m_xUIConfigurationManager;
}
-// -----------------------------------------------------------------------------
+
Reference< XStorage > SAL_CALL ODatabaseDocument::getDocumentSubStorage( const ::rtl::OUString& aStorageName, sal_Int32 nMode ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -1711,14 +1648,13 @@ Reference< XStorage > SAL_CALL ODatabaseDocument::getDocumentSubStorage( const :
Reference< XDocumentSubStorageSupplier > xStorageAccess( m_pImpl->getDocumentSubStorageSupplier() );
return xStorageAccess->getDocumentSubStorage( aStorageName, nMode );
}
-// -----------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > SAL_CALL ODatabaseDocument::getDocumentSubStoragesNames( ) throw (::com::sun::star::io::IOException, RuntimeException)
{
Reference< XDocumentSubStorageSupplier > xStorageAccess( m_pImpl->getDocumentSubStorageSupplier() );
return xStorageAccess->getDocumentSubStoragesNames();
}
-//------------------------------------------------------------------------------
void ODatabaseDocument::impl_notifyStorageChange_nolck_nothrow( const Reference< XStorage >& _rxNewRootStorage )
{
Reference< XInterface > xMe( *const_cast< ODatabaseDocument* >( this ) );
@@ -1727,14 +1663,13 @@ void ODatabaseDocument::impl_notifyStorageChange_nolck_nothrow( const Reference<
boost::bind( &XStorageChangeListener::notifyStorageChange, _1, boost::cref( xMe ), boost::cref( _rxNewRootStorage ) ) );
}
-//------------------------------------------------------------------------------
void ODatabaseDocument::disposing()
{
OSL_TRACE( "DD: disp: %p: %p", this, m_pImpl.get() );
if ( !m_pImpl.is() )
{
// this means that we're already disposed
- DBG_ASSERT( ODatabaseDocument_OfficeDocument::rBHelper.bDisposed, "ODatabaseDocument::disposing: no impl anymore, but not yet disposed!" );
+ OSL_ENSURE( ODatabaseDocument_OfficeDocument::rBHelper.bDisposed, "ODatabaseDocument::disposing: no impl anymore, but not yet disposed!" );
return;
}
@@ -1760,7 +1695,7 @@ void ODatabaseDocument::disposing()
// SYNCHRONIZED ->
::osl::ClearableMutexGuard aGuard( m_aMutex );
- DBG_ASSERT( m_aControllers.empty(), "ODatabaseDocument::disposing: there still are controllers!" );
+ OSL_ENSURE( m_aControllers.empty(), "ODatabaseDocument::disposing: there still are controllers!" );
// normally, nobody should explicitly dispose, but only XCloseable::close the document. And upon
// closing, our controllers are closed, too
@@ -1775,7 +1710,7 @@ void ODatabaseDocument::disposing()
// the security warning, again.
m_pImpl->resetMacroExecutionMode();
- // similar argueing for our ViewMonitor
+ // similar arguing for our ViewMonitor
m_aViewMonitor.reset();
// tell our Impl to forget us
@@ -1783,7 +1718,7 @@ void ODatabaseDocument::disposing()
// now, at the latest, the controller array should be empty. Controllers are
// expected to listen for our disposal, and disconnect then
- DBG_ASSERT( m_aControllers.empty(), "ODatabaseDocument::disposing: there still are controllers!" );
+ OSL_ENSURE( m_aControllers.empty(), "ODatabaseDocument::disposing: there still are controllers!" );
impl_disposeControllerFrames_nothrow();
aKeepAlive.push_back( m_xModuleManager );
@@ -1799,42 +1734,39 @@ void ODatabaseDocument::disposing()
aKeepAlive.clear();
}
-// -----------------------------------------------------------------------------
+
// XComponent
void SAL_CALL ODatabaseDocument::dispose( ) throw (RuntimeException)
{
::cppu::WeakComponentImplHelperBase::dispose();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseDocument::addEventListener( const Reference< lang::XEventListener >& _xListener ) throw (RuntimeException)
{
::cppu::WeakComponentImplHelperBase::addEventListener( _xListener );
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseDocument::removeEventListener( const Reference< lang::XEventListener >& _xListener ) throw (RuntimeException)
{
::cppu::WeakComponentImplHelperBase::removeEventListener( _xListener );
}
+
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString ODatabaseDocument::getImplementationName( ) throw(RuntimeException)
{
return getImplementationName_static();
}
-//------------------------------------------------------------------------------
rtl::OUString ODatabaseDocument::getImplementationName_static( ) throw(RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.comp.dba.ODatabaseDocument");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dba.ODatabaseDocument"));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > ODatabaseDocument::getSupportedServiceNames( ) throw (RuntimeException)
{
return getSupportedServiceNames_static();
}
-//------------------------------------------------------------------------------
Reference< XInterface > ODatabaseDocument::Create( const Reference< XComponentContext >& _rxContext )
{
::comphelper::ComponentContext aContext( _rxContext );
@@ -1846,7 +1778,6 @@ Reference< XInterface > ODatabaseDocument::Create( const Reference< XComponentCo
return xModel.get();
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > ODatabaseDocument::getSupportedServiceNames_static( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSNS( 2 );
@@ -1855,19 +1786,17 @@ Sequence< ::rtl::OUString > ODatabaseDocument::getSupportedServiceNames_static(
return aSNS;
}
-//------------------------------------------------------------------------------
sal_Bool ODatabaseDocument::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
-// -----------------------------------------------------------------------------
+
Reference< XDataSource > SAL_CALL ODatabaseDocument::getDataSource() throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodWithoutInit );
return m_pImpl->getOrCreateDataSource();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::loadFromStorage( const Reference< XStorage >& /*xStorage*/, const Sequence< PropertyValue >& /*aMediaDescriptor*/ ) throw (IllegalArgumentException, DoubleInitializationException, IOException, Exception, RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -1878,14 +1807,12 @@ void SAL_CALL ODatabaseDocument::loadFromStorage( const Reference< XStorage >& /
);
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::storeToStorage( const Reference< XStorage >& _rxStorage, const Sequence< PropertyValue >& _rMediaDescriptor ) throw (IllegalArgumentException, IOException, Exception, RuntimeException)
{
DocumentGuard aGuard( *this );
impl_storeToStorage_throw( _rxStorage, _rMediaDescriptor, aGuard );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::switchToStorage( const Reference< XStorage >& _rxNewRootStorage ) throw (IllegalArgumentException, IOException, Exception, RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -1896,56 +1823,48 @@ void SAL_CALL ODatabaseDocument::switchToStorage( const Reference< XStorage >& _
impl_notifyStorageChange_nolck_nothrow( xNewRootStorage );
}
-// -----------------------------------------------------------------------------
Reference< XStorage > SAL_CALL ODatabaseDocument::getDocumentStorage( ) throw (IOException, Exception, RuntimeException)
{
DocumentGuard aGuard( *this );
return m_pImpl->getOrCreateRootStorage();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::addStorageChangeListener( const Reference< XStorageChangeListener >& _Listener ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
m_aStorageListeners.addInterface( _Listener );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::removeStorageChangeListener( const Reference< XStorageChangeListener >& _Listener ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
m_aStorageListeners.addInterface( _Listener );
}
-// -----------------------------------------------------------------------------
Reference< XStorageBasedLibraryContainer > SAL_CALL ODatabaseDocument::getBasicLibraries() throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodUsedDuringInit );
return m_pImpl->getLibraryContainer( true );
}
-// -----------------------------------------------------------------------------
Reference< XStorageBasedLibraryContainer > SAL_CALL ODatabaseDocument::getDialogLibraries() throw (RuntimeException)
{
DocumentGuard aGuard( *this );
return m_pImpl->getLibraryContainer( false );
}
-// -----------------------------------------------------------------------------
::sal_Bool SAL_CALL ODatabaseDocument::getAllowMacroExecution() throw (RuntimeException)
{
DocumentGuard aGuard( *this );
return m_pImpl->adjustMacroMode_AutoReject();
}
-// -----------------------------------------------------------------------------
Reference< XEmbeddedScripts > SAL_CALL ODatabaseDocument::getScriptContainer() throw (RuntimeException)
{
DocumentGuard aGuard( *this );
return this;
}
-// -----------------------------------------------------------------------------
Reference< provider::XScriptProvider > SAL_CALL ODatabaseDocument::getScriptProvider( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this );
@@ -1967,26 +1886,23 @@ Reference< provider::XScriptProvider > SAL_CALL ODatabaseDocument::getScriptProv
return xScriptProvider;
}
-// -----------------------------------------------------------------------------
Reference< XNameReplace > SAL_CALL ODatabaseDocument::getEvents( ) throw (RuntimeException)
{
DocumentGuard aGuard( *this, DocumentGuard::MethodUsedDuringInit );
return m_pEventContainer;
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseDocument::disposing( const ::com::sun::star::lang::EventObject& Source ) throw(RuntimeException)
{
if ( m_pImpl.is() )
m_pImpl->disposing(Source);
}
-//------------------------------------------------------------------
Reference< XInterface > ODatabaseDocument::getThis() const
{
return *const_cast< ODatabaseDocument* >( this );
}
-// -----------------------------------------------------------------------------
+
struct CreateAny : public ::std::unary_function< Reference<XController>, Any>
{
Any operator() (const Reference<XController>& lhs) const
@@ -2003,14 +1919,14 @@ Reference< XEnumeration > SAL_CALL ODatabaseDocument::getControllers( ) throw (
::std::transform( m_aControllers.begin(), m_aControllers.end(), aController.getArray(), CreateAny() );
return new ::comphelper::OAnyEnumeration(aController);
}
-// -----------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > SAL_CALL ODatabaseDocument::getAvailableViewControllerNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aNames(1);
aNames[0] = SERVICE_SDB_APPLICATIONCONTROLLER;
return aNames;
}
-// -----------------------------------------------------------------------------
+
Reference< XController2 > SAL_CALL ODatabaseDocument::createDefaultViewController( const Reference< XFrame >& _Frame ) throw (IllegalArgumentException, Exception, RuntimeException)
{
return createViewController(
@@ -2020,10 +1936,9 @@ Reference< XController2 > SAL_CALL ODatabaseDocument::createDefaultViewControlle
);
}
-// -----------------------------------------------------------------------------
Reference< XController2 > SAL_CALL ODatabaseDocument::createViewController( const ::rtl::OUString& _ViewName, const Sequence< PropertyValue >& _Arguments, const Reference< XFrame >& _Frame ) throw (IllegalArgumentException, Exception, RuntimeException)
{
- if ( !_ViewName.equalsAscii( "Default" ) && !_ViewName.equalsAscii( "Preview" ) )
+ if ( !_ViewName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Default" ) ) && !_ViewName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Preview" ) ) )
throw IllegalArgumentException( ::rtl::OUString(), *this, 1 );
if ( !_Frame.is() )
throw IllegalArgumentException( ::rtl::OUString(), *this, 3 );
@@ -2037,7 +1952,7 @@ Reference< XController2 > SAL_CALL ODatabaseDocument::createViewController( cons
::comphelper::NamedValueCollection aInitArgs( _Arguments );
aInitArgs.put( "Frame", _Frame );
- if ( _ViewName.equalsAscii( "Preview" ) )
+ if ( _ViewName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Preview" ) ) )
aInitArgs.put( "Preview", sal_Bool( sal_True ) );
Reference< XInitialization > xInitController( xController, UNO_QUERY_THROW );
xInitController->initialize( aInitArgs.getWrappedPropertyValues() );
@@ -2045,8 +1960,6 @@ Reference< XController2 > SAL_CALL ODatabaseDocument::createViewController( cons
return xController;
}
-// -----------------------------------------------------------------------------
-//=============================================================================
Reference< XTitle > ODatabaseDocument::impl_getTitleHelper_throw()
{
if ( ! m_xTitleHelper.is ())
@@ -2065,7 +1978,6 @@ Reference< XTitle > ODatabaseDocument::impl_getTitleHelper_throw()
return m_xTitleHelper;
}
-//=============================================================================
uno::Reference< frame::XUntitledNumbers > ODatabaseDocument::impl_getUntitledHelper_throw(const uno::Reference< uno::XInterface >& _xComponent)
{
if ( !m_xModuleManager.is() )
@@ -2076,9 +1988,8 @@ uno::Reference< frame::XUntitledNumbers > ODatabaseDocument::impl_getUntitledHel
{
sModuleId = m_xModuleManager->identify( _xComponent );
}
- catch(uno::Exception)
+ catch(const uno::Exception&)
{
- // ni
}
uno::Reference< frame::XUntitledNumbers > xNumberedControllers;
@@ -2090,7 +2001,7 @@ uno::Reference< frame::XUntitledNumbers > ODatabaseDocument::impl_getUntitledHel
xNumberedControllers.set(static_cast< ::cppu::OWeakObject* >(pHelper), uno::UNO_QUERY_THROW);
pHelper->setOwner (xThis);
- //pHelper->setUntitledPrefix (::rtl::OUString::createFromAscii(" : "));
+ //pHelper->setUntitledPrefix (::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" : ")));
m_aNumberedControllers.insert(TNumberedController::value_type(sModuleId,xNumberedControllers));
}
@@ -2100,7 +2011,6 @@ uno::Reference< frame::XUntitledNumbers > ODatabaseDocument::impl_getUntitledHel
return xNumberedControllers;
}
-//=============================================================================
// css.frame.XTitle
::rtl::OUString SAL_CALL ODatabaseDocument::getTitle()
throw (uno::RuntimeException)
@@ -2110,7 +2020,6 @@ uno::Reference< frame::XUntitledNumbers > ODatabaseDocument::impl_getUntitledHel
return impl_getTitleHelper_throw()->getTitle();
}
-//=============================================================================
// css.frame.XTitle
void SAL_CALL ODatabaseDocument::setTitle( const ::rtl::OUString& sTitle )
throw (uno::RuntimeException)
@@ -2122,7 +2031,6 @@ void SAL_CALL ODatabaseDocument::setTitle( const ::rtl::OUString& sTitle )
// <- SYNCHRONIZED
}
-//=============================================================================
// css.frame.XTitleChangeBroadcaster
void SAL_CALL ODatabaseDocument::addTitleChangeListener( const uno::Reference< frame::XTitleChangeListener >& xListener )
throw (uno::RuntimeException)
@@ -2134,7 +2042,6 @@ void SAL_CALL ODatabaseDocument::addTitleChangeListener( const uno::Reference< f
xBroadcaster->addTitleChangeListener( xListener );
}
-//=============================================================================
// css.frame.XTitleChangeBroadcaster
void SAL_CALL ODatabaseDocument::removeTitleChangeListener( const uno::Reference< frame::XTitleChangeListener >& xListener )
throw (uno::RuntimeException)
@@ -2146,7 +2053,6 @@ void SAL_CALL ODatabaseDocument::removeTitleChangeListener( const uno::Reference
xBroadcaster->removeTitleChangeListener( xListener );
}
-//=============================================================================
// css.frame.XUntitledNumbers
::sal_Int32 SAL_CALL ODatabaseDocument::leaseNumber( const uno::Reference< uno::XInterface >& xComponent )
throw (lang::IllegalArgumentException,
@@ -2156,7 +2062,6 @@ void SAL_CALL ODatabaseDocument::removeTitleChangeListener( const uno::Reference
return impl_getUntitledHelper_throw(xComponent)->leaseNumber (xComponent);
}
-//=============================================================================
// css.frame.XUntitledNumbers
void SAL_CALL ODatabaseDocument::releaseNumber( ::sal_Int32 nNumber )
throw (lang::IllegalArgumentException,
@@ -2166,7 +2071,6 @@ void SAL_CALL ODatabaseDocument::releaseNumber( ::sal_Int32 nNumber )
impl_getUntitledHelper_throw()->releaseNumber (nNumber);
}
-//=============================================================================
// css.frame.XUntitledNumbers
void SAL_CALL ODatabaseDocument::releaseNumberForComponent( const uno::Reference< uno::XInterface >& xComponent )
throw (lang::IllegalArgumentException,
@@ -2176,16 +2080,11 @@ void SAL_CALL ODatabaseDocument::releaseNumberForComponent( const uno::Reference
impl_getUntitledHelper_throw(xComponent)->releaseNumberForComponent (xComponent);
}
-//=============================================================================
// css.frame.XUntitledNumbers
::rtl::OUString SAL_CALL ODatabaseDocument::getUntitledPrefix() throw (uno::RuntimeException)
{
return ::rtl::OUString();/*RTL_CONSTASCII_USTRINGPARAM(" : "));*/
}
-//------------------------------------------------------------------
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/databasedocument.hxx b/dbaccess/source/core/dataaccess/databasedocument.hxx
index d2aa57130d18..a00019e28dae 100644
--- a/dbaccess/source/core/dataaccess/databasedocument.hxx
+++ b/dbaccess/source/core/dataaccess/databasedocument.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -145,7 +146,7 @@ private:
//============================================================
//= ODatabaseDocument
//============================================================
-typedef ::comphelper::WeakComponentImplHelper17 < ::com::sun::star::frame::XModel2
+typedef ::comphelper::PartialWeakComponentImplHelper17 < ::com::sun::star::frame::XModel2
, ::com::sun::star::util::XModifiable
, ::com::sun::star::frame::XStorable
, ::com::sun::star::document::XEventBroadcaster
@@ -291,7 +292,7 @@ private:
// Do NOT create those documents directly, always use ODatabaseModelImpl::getModel. Reason is that
// ODatabaseDocument requires clear ownership, and in turn lifetime synchronisation with the ModelImpl.
// If you create a ODatabaseDocument directly, you might easily create a leak.
- // #i50905# / 2005-06-20 / frank.schonheit@sun.com
+ // #i50905#
protected:
virtual void SAL_CALL disposing();
@@ -620,7 +621,6 @@ private:
denotes additional document parameters
@param _rDocGuard
is the guard which currently protects the document instance
-
*/
sal_Bool impl_attachResource(
const ::rtl::OUString& i_rLogicalDocumentURL,
@@ -703,7 +703,7 @@ private:
const ODatabaseDocument& m_document;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_COREDATAACCESS_DATABASEDOCUMENT_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/databaseregistrations.cxx b/dbaccess/source/core/dataaccess/databaseregistrations.cxx
index 6a8e7db21236..e2a521b71d23 100644
--- a/dbaccess/source/core/dataaccess/databaseregistrations.cxx
+++ b/dbaccess/source/core/dataaccess/databaseregistrations.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -40,11 +41,8 @@
#include <tools/urlobj.hxx>
#include <unotools/confignode.hxx>
-//........................................................................
namespace dbaccess
{
-//........................................................................
-
/** === begin UNO using === **/
using ::com::sun::star::uno::Reference;
using ::com::sun::star::uno::XInterface;
@@ -67,24 +65,21 @@ namespace dbaccess
using ::com::sun::star::uno::XAggregation;
/** === end UNO using === **/
- //--------------------------------------------------------------------
static const ::rtl::OUString& getConfigurationRootPath()
{
- static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii("org.openoffice.Office.DataAccess/RegisteredNames");
+ static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.DataAccess/RegisteredNames"));
return s_sNodeName;
}
- //--------------------------------------------------------------------
const ::rtl::OUString& getLocationNodeName()
{
- static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii( "Location" );
+ static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("Location"));
return s_sNodeName;
}
- //--------------------------------------------------------------------
const ::rtl::OUString& getNameNodeName()
{
- static ::rtl::OUString s_sNodeName = ::rtl::OUString::createFromAscii( "Name" );
+ static ::rtl::OUString s_sNodeName(RTL_CONSTASCII_USTRINGPARAM("Name"));
return s_sNodeName;
}
@@ -150,7 +145,6 @@ namespace dbaccess
//====================================================================
//= DatabaseRegistrations - implementation
//====================================================================
- //--------------------------------------------------------------------
DatabaseRegistrations::DatabaseRegistrations( const ::comphelper::ComponentContext& _rxContext )
:m_aContext( _rxContext )
,m_aConfigurationRoot()
@@ -160,12 +154,10 @@ namespace dbaccess
m_aContext.getLegacyServiceFactory(), getConfigurationRootPath(), -1, ::utl::OConfigurationTreeRoot::CM_UPDATABLE );
}
- //--------------------------------------------------------------------
DatabaseRegistrations::~DatabaseRegistrations()
{
}
- //--------------------------------------------------------------------
::utl::OConfigurationNode DatabaseRegistrations::impl_getNodeForName_nothrow( const ::rtl::OUString& _rName )
{
Sequence< ::rtl::OUString > aNames( m_aConfigurationRoot.getNodeNames() );
@@ -184,7 +176,6 @@ namespace dbaccess
return ::utl::OConfigurationNode();
}
- //--------------------------------------------------------------------
::utl::OConfigurationNode DatabaseRegistrations::impl_getNodeForName_throw( const ::rtl::OUString& _rName, const bool _bMustExist )
{
::utl::OConfigurationNode aNodeForName( impl_getNodeForName_nothrow( _rName ) );
@@ -224,7 +215,6 @@ namespace dbaccess
return aNewNode;
}
- //--------------------------------------------------------------------
::utl::OConfigurationNode DatabaseRegistrations::impl_checkValidName_throw( const ::rtl::OUString& _rName, const bool _bMustExist )
{
if ( !m_aConfigurationRoot.isValid() )
@@ -236,7 +226,6 @@ namespace dbaccess
return impl_getNodeForName_throw( _rName, _bMustExist );
}
- //--------------------------------------------------------------------
void DatabaseRegistrations::impl_checkValidLocation_throw( const ::rtl::OUString& _rLocation )
{
if ( !_rLocation.getLength() )
@@ -247,7 +236,6 @@ namespace dbaccess
throw IllegalArgumentException( ::rtl::OUString(), *this, 2 );
}
- //--------------------------------------------------------------------
::sal_Bool SAL_CALL DatabaseRegistrations::hasRegisteredDatabase( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -255,7 +243,6 @@ namespace dbaccess
return aNodeForName.isValid();
}
- //------------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL DatabaseRegistrations::getRegistrationNames() throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -273,13 +260,11 @@ namespace dbaccess
{
::utl::OConfigurationNode aRegistrationNode = m_aConfigurationRoot.openNode( *pName );
OSL_VERIFY( aRegistrationNode.getNodeValue( getNameNodeName() ) >>= *pDisplayName );
-
}
return aDisplayNames;
}
- //--------------------------------------------------------------------
::rtl::OUString SAL_CALL DatabaseRegistrations::getDatabaseLocation( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, NoSuchElementException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -293,7 +278,6 @@ namespace dbaccess
return sLocation;
}
- //--------------------------------------------------------------------
void SAL_CALL DatabaseRegistrations::registerDatabaseLocation( const ::rtl::OUString& _Name, const ::rtl::OUString& _Location ) throw (IllegalArgumentException, ElementExistException, RuntimeException)
{
::osl::ClearableMutexGuard aGuard( m_aMutex );
@@ -312,7 +296,6 @@ namespace dbaccess
m_aRegistrationListeners.notifyEach( &XDatabaseRegistrationsListener::registeredDatabaseLocation, aEvent );
}
- //--------------------------------------------------------------------
void SAL_CALL DatabaseRegistrations::revokeDatabaseLocation( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, NoSuchElementException, IllegalAccessException, RuntimeException)
{
::osl::ClearableMutexGuard aGuard( m_aMutex );
@@ -338,7 +321,6 @@ namespace dbaccess
m_aRegistrationListeners.notifyEach( &XDatabaseRegistrationsListener::revokedDatabaseLocation, aEvent );
}
- //--------------------------------------------------------------------
void SAL_CALL DatabaseRegistrations::changeDatabaseLocation( const ::rtl::OUString& _Name, const ::rtl::OUString& _NewLocation ) throw (IllegalArgumentException, NoSuchElementException, IllegalAccessException, RuntimeException)
{
::osl::ClearableMutexGuard aGuard( m_aMutex );
@@ -364,7 +346,6 @@ namespace dbaccess
m_aRegistrationListeners.notifyEach( &XDatabaseRegistrationsListener::changedDatabaseLocation, aEvent );
}
- //--------------------------------------------------------------------
::sal_Bool SAL_CALL DatabaseRegistrations::isDatabaseRegistrationReadOnly( const ::rtl::OUString& _Name ) throw (IllegalArgumentException, NoSuchElementException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -372,14 +353,12 @@ namespace dbaccess
return aDataSourceRegistration.isReadonly();
}
- //--------------------------------------------------------------------
void SAL_CALL DatabaseRegistrations::addDatabaseRegistrationsListener( const Reference< XDatabaseRegistrationsListener >& _Listener ) throw (RuntimeException)
{
if ( _Listener.is() )
m_aRegistrationListeners.addInterface( _Listener );
}
- //--------------------------------------------------------------------
void SAL_CALL DatabaseRegistrations::removeDatabaseRegistrationsListener( const Reference< XDatabaseRegistrationsListener >& _Listener ) throw (RuntimeException)
{
if ( _Listener.is() )
@@ -394,6 +373,5 @@ namespace dbaccess
return new DatabaseRegistrations( _rxContext );
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/databaseregistrations.hxx b/dbaccess/source/core/dataaccess/databaseregistrations.hxx
index 3d771625aa4a..f3213dba6823 100644
--- a/dbaccess/source/core/dataaccess/databaseregistrations.hxx
+++ b/dbaccess/source/core/dataaccess/databaseregistrations.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -36,16 +37,14 @@ namespace comphelper
class ComponentContext;
}
-//........................................................................
namespace dbaccess
{
-//........................................................................
::com::sun::star::uno::Reference< ::com::sun::star::uno::XAggregation >
createDataSourceRegistrations( const ::comphelper::ComponentContext& _rxContext );
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // OOO_DATASOURCEREGISTRATIONS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/datasource.cxx b/dbaccess/source/core/dataaccess/datasource.cxx
index 4cd88751ea15..9302899e775f 100644
--- a/dbaccess/source/core/dataaccess/datasource.cxx
+++ b/dbaccess/source/core/dataaccess/datasource.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,6 +74,7 @@
#include <cppuhelper/typeprovider.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <tools/urlobj.hxx>
#include <typelib/typedescription.hxx>
#include <unotools/confignode.hxx>
@@ -97,15 +99,12 @@ using namespace ::com::sun::star::frame;
using namespace ::com::sun::star::reflection;
using namespace ::cppu;
using namespace ::osl;
-using namespace ::vos;
using namespace ::dbtools;
using namespace ::comphelper;
namespace css = ::com::sun::star;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//============================================================
//= FlushNotificationAdapter
@@ -154,7 +153,7 @@ FlushNotificationAdapter::FlushNotificationAdapter( const Reference< XFlushable
,m_aListener( _rxListener )
{
DBG_CTOR( FlushNotificationAdapter, NULL );
- DBG_ASSERT( _rxBroadcaster.is(), "FlushNotificationAdapter::FlushNotificationAdapter: invalid flushable!" );
+ OSL_ENSURE( _rxBroadcaster.is(), "FlushNotificationAdapter::FlushNotificationAdapter: invalid flushable!" );
osl_incrementInterlockedCount( &m_refCount );
{
@@ -162,7 +161,7 @@ FlushNotificationAdapter::FlushNotificationAdapter( const Reference< XFlushable
_rxBroadcaster->addFlushListener( this );
}
osl_decrementInterlockedCount( &m_refCount );
- DBG_ASSERT( m_refCount == 1, "FlushNotificationAdapter::FlushNotificationAdapter: broadcaster isn't holding by hard ref!?" );
+ OSL_ENSURE( m_refCount == 1, "FlushNotificationAdapter::FlushNotificationAdapter: broadcaster isn't holding by hard ref!?" );
}
//------------------------------------------------------------
@@ -171,7 +170,6 @@ FlushNotificationAdapter::~FlushNotificationAdapter()
DBG_DTOR( FlushNotificationAdapter, NULL );
}
-//--------------------------------------------------------------------
void SAL_CALL FlushNotificationAdapter::impl_dispose( bool _bRevokeListener )
{
Reference< XFlushListener > xKeepAlive( this );
@@ -187,7 +185,6 @@ void SAL_CALL FlushNotificationAdapter::impl_dispose( bool _bRevokeListener )
m_aBroadcaster = Reference< XFlushable >();
}
-//--------------------------------------------------------------------
void SAL_CALL FlushNotificationAdapter::flushed( const EventObject& rEvent ) throw (RuntimeException)
{
Reference< XFlushListener > xListener( m_aListener );
@@ -197,7 +194,6 @@ void SAL_CALL FlushNotificationAdapter::flushed( const EventObject& rEvent ) thr
impl_dispose( true );
}
-//--------------------------------------------------------------------
void SAL_CALL FlushNotificationAdapter::disposing( const EventObject& Source ) throw (RuntimeException)
{
Reference< XFlushListener > xListener( m_aListener );
@@ -207,52 +203,44 @@ void SAL_CALL FlushNotificationAdapter::disposing( const EventObject& Source ) t
impl_dispose( true );
}
-//--------------------------------------------------------------------------
OAuthenticationContinuation::OAuthenticationContinuation()
- :m_bRemberPassword(sal_True), // TODO: a meaningfull default
+ :m_bRemberPassword(sal_True), // TODO: a meaningful default
m_bCanSetUserName(sal_True)
{
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OAuthenticationContinuation::canSetRealm( ) throw(RuntimeException)
{
return sal_False;
}
-//--------------------------------------------------------------------------
void SAL_CALL OAuthenticationContinuation::setRealm( const ::rtl::OUString& /*Realm*/ ) throw(RuntimeException)
{
- DBG_ERROR("OAuthenticationContinuation::setRealm: not supported!");
+ OSL_FAIL("OAuthenticationContinuation::setRealm: not supported!");
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OAuthenticationContinuation::canSetUserName( ) throw(RuntimeException)
{
- // we alwas allow this, even if the database document is read-only. In this case,
+ // we always allow this, even if the database document is read-only. In this case,
// it's simply that the user cannot store the new user name.
return m_bCanSetUserName;
}
-//--------------------------------------------------------------------------
void SAL_CALL OAuthenticationContinuation::setUserName( const ::rtl::OUString& _rUser ) throw(RuntimeException)
{
m_sUser = _rUser;
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OAuthenticationContinuation::canSetPassword( ) throw(RuntimeException)
{
return sal_True;
}
-//--------------------------------------------------------------------------
void SAL_CALL OAuthenticationContinuation::setPassword( const ::rtl::OUString& _rPassword ) throw(RuntimeException)
{
m_sPassword = _rPassword;
}
-//--------------------------------------------------------------------------
Sequence< RememberAuthentication > SAL_CALL OAuthenticationContinuation::getRememberPasswordModes( RememberAuthentication& _reDefault ) throw(RuntimeException)
{
Sequence< RememberAuthentication > aReturn(1);
@@ -260,25 +248,21 @@ Sequence< RememberAuthentication > SAL_CALL OAuthenticationContinuation::getReme
return aReturn;
}
-//--------------------------------------------------------------------------
void SAL_CALL OAuthenticationContinuation::setRememberPassword( RememberAuthentication _eRemember ) throw(RuntimeException)
{
m_bRemberPassword = (RememberAuthentication_NO != _eRemember);
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL OAuthenticationContinuation::canSetAccount( ) throw(RuntimeException)
{
return sal_False;
}
-//--------------------------------------------------------------------------
void SAL_CALL OAuthenticationContinuation::setAccount( const ::rtl::OUString& ) throw(RuntimeException)
{
- DBG_ERROR("OAuthenticationContinuation::setAccount: not supported!");
+ OSL_FAIL("OAuthenticationContinuation::setAccount: not supported!");
}
-//--------------------------------------------------------------------------
Sequence< RememberAuthentication > SAL_CALL OAuthenticationContinuation::getRememberAccountModes( RememberAuthentication& _reDefault ) throw(RuntimeException)
{
Sequence < RememberAuthentication > aReturn(1);
@@ -287,10 +271,9 @@ Sequence< RememberAuthentication > SAL_CALL OAuthenticationContinuation::getReme
return aReturn;
}
-//--------------------------------------------------------------------------
void SAL_CALL OAuthenticationContinuation::setRememberAccount( RememberAuthentication /*Remember*/ ) throw(RuntimeException)
{
- DBG_ERROR("OAuthenticationContinuation::setRememberAccount: not supported!");
+ OSL_FAIL("OAuthenticationContinuation::setRememberAccount: not supported!");
}
/** The class OSharedConnectionManager implements a structure to share connections.
@@ -334,7 +317,7 @@ class OSharedConnectionManager : public OConnectionHelper_BASE
typedef ::std::map< Reference< XConnection >,TConnectionMap::iterator> TSharedConnectionMap;// holds the shared connections
::osl::Mutex m_aMutex;
- TConnectionMap m_aConnections; // remeber the master connection in conjunction with the digest
+ TConnectionMap m_aConnections; // remember the master connection in conjunction with the digest
TSharedConnectionMap m_aSharedConnection; // the shared connections with conjunction with an iterator into the connections map
Reference< XProxyFactory > m_xProxyFactory;
@@ -396,14 +379,13 @@ Reference<XConnection> OSharedConnectionManager::getConnection( const rtl::OUStr
aInfoCopy[nPos].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TableFilter"));
aInfoCopy[nPos++].Value <<= _pDataSource->m_pImpl->m_aTableFilter;
aInfoCopy[nPos].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TableTypeFilter"));
- aInfoCopy[nPos++].Value <<= _pDataSource->m_pImpl->m_aTableTypeFilter; // #22377# OJ
+ aInfoCopy[nPos++].Value <<= _pDataSource->m_pImpl->m_aTableTypeFilter;
::rtl::OUString sUser = user;
::rtl::OUString sPassword = password;
if ((0 == sUser.getLength()) && (0 == sPassword.getLength()) && (0 != _pDataSource->m_pImpl->m_sUser.getLength()))
{ // ease the usage of this method. data source which are intended to have a user automatically
// fill in the user/password combination if the caller of this method does not specify otherwise
- // 86951 - 05/08/2001 - frank.schoenheit@germany.sun.com
sUser = _pDataSource->m_pImpl->m_sUser;
if (0 != _pDataSource->m_pImpl->m_aPassword.getLength())
sPassword = _pDataSource->m_pImpl->m_aPassword;
@@ -439,10 +421,8 @@ void OSharedConnectionManager::addEventListener(const Reference<XConnection>& _r
osl_incrementInterlockedCount(&_rIter->second.nALiveCount);
}
-//----------------------------------------------------------------------
namespace
{
- //------------------------------------------------------------------
Sequence< PropertyValue > lcl_filterDriverProperties( const Reference< XDriver >& _xDriver, const ::rtl::OUString& _sUrl,
const Sequence< PropertyValue >& _rDataSourceSettings, const AsciiPropertyValue* _pKnownSettings )
{
@@ -489,10 +469,8 @@ namespace
return Sequence< PropertyValue >();
}
- //------------------------------------------------------------------
typedef ::std::map< ::rtl::OUString, sal_Int32 > PropertyAttributeCache;
- //------------------------------------------------------------------
struct IsDefaultAndNotRemoveable : public ::std::unary_function< PropertyValue, bool >
{
private:
@@ -521,13 +499,12 @@ namespace
//= ODatabaseContext
//============================================================
DBG_NAME(ODatabaseSource)
-//--------------------------------------------------------------------------
+
extern "C" void SAL_CALL createRegistryInfo_ODatabaseSource()
{
static ::dba::OAutoRegistration< ODatabaseSource > aAutoRegistration;
}
-//--------------------------------------------------------------------------
ODatabaseSource::ODatabaseSource(const ::rtl::Reference<ODatabaseModelImpl>& _pImpl)
:ModelDependentComponent( _pImpl )
,ODatabaseSource_Base( getMutex() )
@@ -540,7 +517,6 @@ ODatabaseSource::ODatabaseSource(const ::rtl::Reference<ODatabaseModelImpl>& _pI
OSL_TRACE( "DS: ctor: %p: %p", this, m_pImpl.get() );
}
-//--------------------------------------------------------------------------
ODatabaseSource::~ODatabaseSource()
{
OSL_TRACE( "DS: dtor: %p: %p", this, m_pImpl.get() );
@@ -552,7 +528,6 @@ ODatabaseSource::~ODatabaseSource()
}
}
-//--------------------------------------------------------------------------
void ODatabaseSource::setName( const Reference< XDocumentDataSource >& _rxDocument, const ::rtl::OUString& _rNewName, DBContextAccess )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::setName" );
@@ -564,7 +539,6 @@ void ODatabaseSource::setName( const Reference< XDocumentDataSource >& _rxDocume
}
// com::sun::star::lang::XTypeProvider
-//--------------------------------------------------------------------------
Sequence< Type > ODatabaseSource::getTypes() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getTypes" );
@@ -578,7 +552,6 @@ Sequence< Type > ODatabaseSource::getTypes() throw (RuntimeException)
);
}
-//--------------------------------------------------------------------------
Sequence< sal_Int8 > ODatabaseSource::getImplementationId() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getImplementationId" );
@@ -596,55 +569,48 @@ Sequence< sal_Int8 > ODatabaseSource::getImplementationId() throw (RuntimeExcept
}
// com::sun::star::uno::XInterface
-//--------------------------------------------------------------------------
Any ODatabaseSource::queryInterface( const Type & rType ) throw (RuntimeException)
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::queryInterface" );
Any aIface = ODatabaseSource_Base::queryInterface( rType );
if ( !aIface.hasValue() )
aIface = ::cppu::OPropertySetHelper::queryInterface( rType );
return aIface;
}
-//--------------------------------------------------------------------------
void ODatabaseSource::acquire() throw ()
{
ODatabaseSource_Base::acquire();
}
-//--------------------------------------------------------------------------
void ODatabaseSource::release() throw ()
{
ODatabaseSource_Base::release();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseSource::disposing( const ::com::sun::star::lang::EventObject& Source ) throw(RuntimeException)
{
if ( m_pImpl.is() )
m_pImpl->disposing(Source);
}
// XServiceInfo
-//------------------------------------------------------------------------------
rtl::OUString ODatabaseSource::getImplementationName( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getImplementationName" );
return getImplementationName_static();
}
-//------------------------------------------------------------------------------
rtl::OUString ODatabaseSource::getImplementationName_static( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getImplementationName_static" );
- return rtl::OUString::createFromAscii("com.sun.star.comp.dba.ODatabaseSource");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dba.ODatabaseSource"));
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > ODatabaseSource::getSupportedServiceNames( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getSupportedServiceNames" );
return getSupportedServiceNames_static();
}
-//------------------------------------------------------------------------------
+
Reference< XInterface > ODatabaseSource::Create( const Reference< XComponentContext >& _rxContext )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::Create" );
@@ -653,7 +619,6 @@ Reference< XInterface > ODatabaseSource::Create( const Reference< XComponentCont
return xDBContext->createInstance();
}
-//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > ODatabaseSource::getSupportedServiceNames_static( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getSupportedServiceNames_static" );
@@ -663,14 +628,13 @@ Sequence< ::rtl::OUString > ODatabaseSource::getSupportedServiceNames_static( )
return aSNS;
}
-//------------------------------------------------------------------------------
sal_Bool ODatabaseSource::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::supportsService" );
return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
}
+
// OComponentHelper
-//------------------------------------------------------------------------------
void ODatabaseSource::disposing()
{
OSL_TRACE( "DS: disp: %p, %p", this, m_pImpl.get() );
@@ -684,7 +648,7 @@ void ODatabaseSource::disposing()
ODatabaseDocument::clearObjectContainer(m_pImpl->m_xTableDefinitions);
m_pImpl.clear();
}
-//------------------------------------------------------------------------------
+
Reference< XConnection > ODatabaseSource::buildLowLevelConnection(const ::rtl::OUString& _rUid, const ::rtl::OUString& _rPwd)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::buildLowLevelConnection" );
@@ -700,7 +664,6 @@ Reference< XConnection > ODatabaseSource::buildLowLevelConnection(const ::rtl::O
if ((0 == sUser.getLength()) && (0 == sPwd.getLength()) && (0 != m_pImpl->m_sUser.getLength()))
{ // ease the usage of this method. data source which are intended to have a user automatically
// fill in the user/password combination if the caller of this method does not specify otherwise
- // 86951 - 05/08/2001 - frank.schoenheit@germany.sun.com
sUser = m_pImpl->m_sUser;
if (0 != m_pImpl->m_aPassword.getLength())
sPwd = m_pImpl->m_aPassword;
@@ -717,13 +680,13 @@ Reference< XConnection > ODatabaseSource::buildLowLevelConnection(const ::rtl::O
sal_Int32 nArgPos = 0;
if (sUser.getLength())
{
- aUserPwd[ nArgPos ].Name = ::rtl::OUString::createFromAscii("user");
+ aUserPwd[ nArgPos ].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("user"));
aUserPwd[ nArgPos ].Value <<= sUser;
++nArgPos;
}
if (sPwd.getLength())
{
- aUserPwd[ nArgPos ].Name = ::rtl::OUString::createFromAscii("password");
+ aUserPwd[ nArgPos ].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("password"));
aUserPwd[ nArgPos ].Value <<= sPwd;
}
Reference< XDriver > xDriver;
@@ -735,7 +698,7 @@ Reference< XConnection > ODatabaseSource::buildLowLevelConnection(const ::rtl::O
}
catch( const Exception& )
{
- DBG_ERROR( "ODatabaseSource::buildLowLevelConnection: got a strange exception while analyzing the error!" );
+ OSL_FAIL( "ODatabaseSource::buildLowLevelConnection: got a strange exception while analyzing the error!" );
}
if ( !xDriver.is() || !xDriver->acceptsURL( m_pImpl->m_sConnectURL ) )
{
@@ -796,7 +759,6 @@ Reference< XConnection > ODatabaseSource::buildLowLevelConnection(const ::rtl::O
}
// OPropertySetHelper
-//------------------------------------------------------------------------------
Reference< XPropertySetInfo > ODatabaseSource::getPropertySetInfo() throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getPropertySetInfo" );
@@ -804,7 +766,6 @@ Reference< XPropertySetInfo > ODatabaseSource::getPropertySetInfo() throw (Runt
}
// comphelper::OPropertyArrayUsageHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper* ODatabaseSource::createArrayHelper( ) const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::createArrayHelper" );
@@ -826,16 +787,13 @@ Reference< XPropertySetInfo > ODatabaseSource::getPropertySetInfo() throw (Runt
}
// cppu::OPropertySetHelper
-//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& ODatabaseSource::getInfoHelper()
{
return *getArrayHelper();
}
-//------------------------------------------------------------------------------
sal_Bool ODatabaseSource::convertFastPropertyValue(Any & rConvertedValue, Any & rOldValue, sal_Int32 nHandle, const Any& rValue ) throw( IllegalArgumentException )
{
- //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::convertFastPropertyValue" );
sal_Bool bModified(sal_False);
if ( m_pImpl.is() )
{
@@ -901,13 +859,12 @@ sal_Bool ODatabaseSource::convertFastPropertyValue(Any & rConvertedValue, Any &
}
break;
default:
- DBG_ERROR( "ODatabaseSource::convertFastPropertyValue: unknown or readonly Property!" );
+ OSL_FAIL( "ODatabaseSource::convertFastPropertyValue: unknown or readonly Property!" );
}
}
return bModified;
}
-//------------------------------------------------------------------------------
namespace
{
struct SelectPropertyName : public ::std::unary_function< PropertyValue, ::rtl::OUString >
@@ -919,9 +876,9 @@ namespace
}
};
- /** sets a new set of property values at a given property bag instance
+ /** sets a new set of property values for a given property bag instance
- The methods takes a property bag, and a sequence of property values to set at this bag.
+ The method takes a property bag, and a sequence of property values to set for this bag.
Upon return, every property which is not part of the given sequence is
<ul><li>removed from the bag, if it's a removeable property</li>
<li><em>or</em>reset to its default value, if it's not a removeable property</li>
@@ -930,7 +887,7 @@ namespace
@param _rxPropertyBag
the property bag to operate on
@param _rAllNewPropertyValues
- the new property values to set at the bag
+ the new property values to set for the bag
*/
void lcl_setPropertyValues_resetOrRemoveOther( const Reference< XPropertyAccess >& _rxPropertyBag, const Sequence< PropertyValue >& _rAllNewPropertyValues )
{
@@ -963,7 +920,7 @@ namespace
continue;
// this property is not to be set, but currently exists in the bag.
- // -> Remove, respectively default, it
+ // -> Remove it, or reset it to the default.
if ( ( pExistentProperty->Attributes & PropertyAttribute::REMOVEABLE ) != 0 )
xPropertyContainer->removeProperty( pExistentProperty->Name );
else
@@ -980,7 +937,6 @@ namespace
}
}
-//------------------------------------------------------------------------------
void ODatabaseSource::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any& rValue ) throw (Exception)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::setFastPropertyValue_NoBroadcast" );
@@ -996,7 +952,7 @@ void ODatabaseSource::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const
break;
case PROPERTY_ID_USER:
rValue >>= m_pImpl->m_sUser;
- // if the user name changed, reset the password
+ // if the user name has changed, reset the password
m_pImpl->m_aPassword = ::rtl::OUString();
break;
case PROPERTY_ID_PASSWORD:
@@ -1026,7 +982,6 @@ void ODatabaseSource::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const
}
}
-//------------------------------------------------------------------------------
void ODatabaseSource::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
{
//RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getFastPropertyValue" );
@@ -1076,7 +1031,7 @@ void ODatabaseSource::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) con
Sequence< PropertyValue > aValues( m_pImpl->m_xSettings->getPropertyValues() );
// transform them so that only property values which fulfill certain
- // criterions survive
+ // criteria survive
Sequence< PropertyValue > aNonDefaultOrUserDefined( aValues.getLength() );
const PropertyValue* pCopyEnd = ::std::remove_copy_if(
aValues.getConstArray(),
@@ -1109,13 +1064,12 @@ void ODatabaseSource::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) con
rValue <<= m_pImpl->m_aLayoutInformation;
break;
default:
- DBG_ERROR("unknown Property");
+ OSL_FAIL("unknown Property");
}
}
}
// XDataSource
-//------------------------------------------------------------------------------
void ODatabaseSource::setLoginTimeout(sal_Int32 seconds) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::setLoginTimeout" );
@@ -1123,7 +1077,6 @@ void ODatabaseSource::setLoginTimeout(sal_Int32 seconds) throw( SQLException, Ru
m_pImpl->m_nLoginTimeout = seconds;
}
-//------------------------------------------------------------------------------
sal_Int32 ODatabaseSource::getLoginTimeout(void) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getLoginTimeout" );
@@ -1131,33 +1084,31 @@ sal_Int32 ODatabaseSource::getLoginTimeout(void) throw( SQLException, RuntimeExc
return m_pImpl->m_nLoginTimeout;
}
-
// XCompletedConnection
-//------------------------------------------------------------------------------
Reference< XConnection > SAL_CALL ODatabaseSource::connectWithCompletion( const Reference< XInteractionHandler >& _rxHandler ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::connectWithCompletion" );
return connectWithCompletion(_rxHandler,sal_False);
}
-// -----------------------------------------------------------------------------
+
Reference< XConnection > ODatabaseSource::getConnection(const rtl::OUString& user, const rtl::OUString& password) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getConnection" );
return getConnection(user,password,sal_False);
}
-// -----------------------------------------------------------------------------
+
Reference< XConnection > SAL_CALL ODatabaseSource::getIsolatedConnection( const ::rtl::OUString& user, const ::rtl::OUString& password ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getIsolatedConnection" );
return getConnection(user,password,sal_True);
}
-// -----------------------------------------------------------------------------
+
Reference< XConnection > SAL_CALL ODatabaseSource::getIsolatedConnectionWithCompletion( const Reference< XInteractionHandler >& _rxHandler ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getIsolatedConnectionWithCompletion" );
return connectWithCompletion(_rxHandler,sal_True);
}
-// -----------------------------------------------------------------------------
+
Reference< XConnection > SAL_CALL ODatabaseSource::connectWithCompletion( const Reference< XInteractionHandler >& _rxHandler,sal_Bool _bIsolated ) throw(SQLException, RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::connectWithCompletion" );
@@ -1165,7 +1116,7 @@ Reference< XConnection > SAL_CALL ODatabaseSource::connectWithCompletion( const
if (!_rxHandler.is())
{
- DBG_ERROR("ODatabaseSource::connectWithCompletion: invalid interaction handler!");
+ OSL_FAIL("ODatabaseSource::connectWithCompletion: invalid interaction handler!");
return getConnection(m_pImpl->m_sUser, m_pImpl->m_aPassword,_bIsolated);
}
@@ -1245,13 +1196,12 @@ Reference< XConnection > SAL_CALL ODatabaseSource::connectWithCompletion( const
}
}
-// -----------------------------------------------------------------------------
Reference< XConnection > ODatabaseSource::buildIsolatedConnection(const rtl::OUString& user, const rtl::OUString& password)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::buildIsolatedConnection" );
Reference< XConnection > xConn;
Reference< XConnection > xSdbcConn = buildLowLevelConnection(user, password);
- DBG_ASSERT( xSdbcConn.is(), "ODatabaseSource::buildIsolatedConnection: invalid return value of buildLowLevelConnection!" );
+ OSL_ENSURE( xSdbcConn.is(), "ODatabaseSource::buildIsolatedConnection: invalid return value of buildLowLevelConnection!" );
// buildLowLevelConnection is expected to always succeed
if ( xSdbcConn.is() )
{
@@ -1260,7 +1210,7 @@ Reference< XConnection > ODatabaseSource::buildIsolatedConnection(const rtl::OUS
}
return xConn;
}
-//------------------------------------------------------------------------------
+
Reference< XConnection > ODatabaseSource::getConnection(const rtl::OUString& user, const rtl::OUString& password,sal_Bool _bIsolated) throw( SQLException, RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getConnection" );
@@ -1293,7 +1243,6 @@ Reference< XConnection > ODatabaseSource::getConnection(const rtl::OUString& use
return xConn;
}
-//------------------------------------------------------------------------------
Reference< XNameAccess > SAL_CALL ODatabaseSource::getBookmarks( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getBookmarks" );
@@ -1301,7 +1250,6 @@ Reference< XNameAccess > SAL_CALL ODatabaseSource::getBookmarks( ) throw (Runti
return static_cast< XNameContainer* >(&m_aBookmarks);
}
-//------------------------------------------------------------------------------
Reference< XNameAccess > SAL_CALL ODatabaseSource::getQueryDefinitions( ) throw(RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getQueryDefinitions" );
@@ -1332,9 +1280,8 @@ Reference< XNameAccess > SAL_CALL ODatabaseSource::getQueryDefinitions( ) throw(
}
return xContainer;
}
-//------------------------------------------------------------------------------
+
// XTablesSupplier
-//------------------------------------------------------------------------------
Reference< XNameAccess > ODatabaseSource::getTables() throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getTables" );
@@ -1349,7 +1296,7 @@ Reference< XNameAccess > ODatabaseSource::getTables() throw( RuntimeException )
}
return xContainer;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseSource::flush( ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::flush" );
@@ -1379,7 +1326,6 @@ void SAL_CALL ODatabaseSource::flush( ) throw (RuntimeException)
}
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseSource::flushed( const EventObject& /*rEvent*/ ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::flushed" );
@@ -1405,7 +1351,7 @@ void SAL_CALL ODatabaseSource::flushed( const EventObject& /*rEvent*/ ) throw (R
// XFlushListener at the embedded connection (which needs to provide the XFlushable functionality).
// Then, when the connection is flushed, we commit both the database storage and our main storage.
//
- // #i55274# / 2005-09-30 / frank.schoenheit@sun.com
+ // #i55274#
OSL_ENSURE( m_pImpl->isEmbeddedDatabase(), "ODatabaseSource::flushed: no embedded database?!" );
sal_Bool bWasModified = m_pImpl->m_bModified;
@@ -1413,19 +1359,18 @@ void SAL_CALL ODatabaseSource::flushed( const EventObject& /*rEvent*/ ) throw (R
m_pImpl->setModified( bWasModified );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODatabaseSource::addFlushListener( const Reference< ::com::sun::star::util::XFlushListener >& _xListener ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::addFlushListener" );
m_aFlushListeners.addInterface(_xListener);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseSource::removeFlushListener( const Reference< ::com::sun::star::util::XFlushListener >& _xListener ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::removeFlushListener" );
m_aFlushListeners.removeInterface(_xListener);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseSource::elementInserted( const ContainerEvent& /*Event*/ ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::elementInserted" );
@@ -1433,7 +1378,7 @@ void SAL_CALL ODatabaseSource::elementInserted( const ContainerEvent& /*Event*/
if ( m_pImpl.is() )
m_pImpl->setModified(sal_True);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseSource::elementRemoved( const ContainerEvent& /*Event*/ ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::elementRemoved" );
@@ -1441,7 +1386,7 @@ void SAL_CALL ODatabaseSource::elementRemoved( const ContainerEvent& /*Event*/ )
if ( m_pImpl.is() )
m_pImpl->setModified(sal_True);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODatabaseSource::elementReplaced( const ContainerEvent& /*Event*/ ) throw (RuntimeException)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::elementReplaced" );
@@ -1449,7 +1394,7 @@ void SAL_CALL ODatabaseSource::elementReplaced( const ContainerEvent& /*Event*/
if ( m_pImpl.is() )
m_pImpl->setModified(sal_True);
}
-// -----------------------------------------------------------------------------
+
// XDocumentDataSource
Reference< XOfficeDatabaseDocument > SAL_CALL ODatabaseSource::getDatabaseDocument() throw (RuntimeException)
{
@@ -1462,15 +1407,12 @@ Reference< XOfficeDatabaseDocument > SAL_CALL ODatabaseSource::getDatabaseDocume
return Reference< XOfficeDatabaseDocument >( xModel, UNO_QUERY_THROW );
}
-// -----------------------------------------------------------------------------
+
Reference< XInterface > ODatabaseSource::getThis() const
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dataaccess", "Ocke.Janssen@sun.com", "ODatabaseSource::getThis" );
return *const_cast< ODatabaseSource* >( this );
}
-// -----------------------------------------------------------------------------
-//........................................................................
-} // namespace dbaccess
-//........................................................................
-
+} // namespace dbaccess
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/datasource.hxx b/dbaccess/source/core/dataaccess/datasource.hxx
index b84b3d74c727..88cb631aac36 100644
--- a/dbaccess/source/core/dataaccess/datasource.hxx
+++ b/dbaccess/source/core/dataaccess/datasource.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,107 +29,41 @@
#ifndef _DBA_COREDATAACCESS_DATASOURCE_HXX_
#define _DBA_COREDATAACCESS_DATASOURCE_HXX_
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATSSUPPLIER_HPP_
#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERLISTENER_HPP_
#include <com/sun/star/container/XContainerListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XBOOKMARKSSUPPLIER_HPP_
#include <com/sun/star/sdb/XBookmarksSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XQUERYDEFINITIONSSUPPLIER_HPP_
#include <com/sun/star/sdb/XQueryDefinitionsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XISOLATEDCONNECTION_HPP_
#include <com/sun/star/sdbc/XIsolatedConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XEVENTLISTENER_HPP_
#include <com/sun/star/document/XEventListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XFLUSHABLE_HPP_
#include <com/sun/star/util/XFlushable.hpp>
-#endif
-#ifndef _CPPUHELPER_PROPSHLP_HXX
#include <cppuhelper/propshlp.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _CPPUHELPER_WEAKREF_HXX_
#include <cppuhelper/weakref.hxx>
-#endif
-#ifndef _CPPUHELPER_COMPBASE11_HXX_
#include <cppuhelper/compbase11.hxx>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XTRANSACTIONLISTENER_HPP_
#include <com/sun/star/embed/XTransactionListener.hpp>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DBA_CORE_BOOKMARKCONTAINER_HXX_
#include "bookmarkcontainer.hxx"
-#endif
-#ifndef _VOS_REF_HXX_
-#include <vos/ref.hxx>
-#endif
-#ifndef _STRING_HXX
+#include <rtl/ref.hxx>
#include <tools/string.hxx>
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XCOMPLETEDCONNECTION_HPP_
#include <com/sun/star/sdb/XCompletedConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XSTORAGE_HPP_
#include <com/sun/star/embed/XStorage.hpp>
-#endif
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XSTORAGEBASEDDOCUMENT_HPP_
#include <com/sun/star/document/XStorageBasedDocument.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_ELEMENTMODES_HPP_
#include <com/sun/star/embed/ElementModes.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XREFRESHABLE_HPP_
#include <com/sun/star/util/XRefreshable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XDOCUMENTDATASOURCE_HPP_
#include <com/sun/star/sdb/XDocumentDataSource.hpp>
-#endif
-#ifndef _DBA_COREDATAACCESS_MODELIMPL_HXX_
#include "ModelImpl.hxx"
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
class OSharedConnectionManager;
class OChildCommitListen_Impl;
@@ -296,10 +231,9 @@ protected:
using ::cppu::OPropertySetHelper::getFastPropertyValue;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_COREDATAACCESS_DATALINK_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/definitioncontainer.cxx b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
index 33ce2782a1dd..f7645349e79d 100644
--- a/dbaccess/source/core/dataaccess/definitioncontainer.cxx
+++ b/dbaccess/source/core/dataaccess/definitioncontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,55 +29,25 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_CORE_DEFINITIONCONTAINER_HXX_
#include "definitioncontainer.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HXX_
#include "core_resource.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HRC_
#include "core_resource.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
+#include <osl/diagnose.h>
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_ENUMHELPER_HXX_
#include <comphelper/enumhelper.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XCOMPONENT_HPP_
#include <com/sun/star/lang/XComponent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_COMMANDINFO_HPP_
#include <com/sun/star/ucb/CommandInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_ERRORCONDITION_HPP_
#include <com/sun/star/sdb/ErrorCondition.hpp>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENTIDENTIFIER_HXX
#include <ucbhelper/contentidentifier.hxx>
-#endif
+#include <o3tl/compat_functional.hxx>
using namespace ::com::sun::star::uno;
@@ -91,15 +62,12 @@ using namespace ::comphelper;
using namespace ::cppu;
using namespace ::com::sun::star::ucb;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= ODefinitionContainer_Impl
//==========================================================================
-//--------------------------------------------------------------------------
void ODefinitionContainer_Impl::erase( TContentPtr _pDefinition )
{
NamedDefinitions::iterator aPos = find( _pDefinition );
@@ -107,28 +75,26 @@ void ODefinitionContainer_Impl::erase( TContentPtr _pDefinition )
m_aDefinitions.erase( aPos );
}
-//--------------------------------------------------------------------------
ODefinitionContainer_Impl::const_iterator ODefinitionContainer_Impl::find( TContentPtr _pDefinition ) const
{
return ::std::find_if(
m_aDefinitions.begin(),
m_aDefinitions.end(),
- ::std::compose1(
+ ::o3tl::compose1(
::std::bind2nd( ::std::equal_to< TContentPtr >(), _pDefinition ),
- ::std::select2nd< NamedDefinitions::value_type >()
+ ::o3tl::select2nd< NamedDefinitions::value_type >()
)
);
}
-//--------------------------------------------------------------------------
ODefinitionContainer_Impl::iterator ODefinitionContainer_Impl::find( TContentPtr _pDefinition )
{
return ::std::find_if(
m_aDefinitions.begin(),
m_aDefinitions.end(),
- ::std::compose1(
+ ::o3tl::compose1(
::std::bind2nd( ::std::equal_to< TContentPtr >(), _pDefinition ),
- ::std::select2nd< NamedDefinitions::value_type >()
+ ::o3tl::select2nd< NamedDefinitions::value_type >()
)
);
}
@@ -137,7 +103,7 @@ ODefinitionContainer_Impl::iterator ODefinitionContainer_Impl::find( TContentPtr
//= ODefinitionContainer
//==========================================================================
DBG_NAME(ODefinitionContainer)
-//--------------------------------------------------------------------------
+
ODefinitionContainer::ODefinitionContainer( const Reference< XMultiServiceFactory >& _xORB
, const Reference< XInterface >& _xParentContainer
, const TContentPtr& _pImpl
@@ -165,14 +131,13 @@ ODefinitionContainer::ODefinitionContainer( const Reference< XMultiServiceFact
DBG_CTOR(ODefinitionContainer, NULL);
}
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::disposing()
{
OContentHelper::disposing();
MutexGuard aGuard(m_aMutex);
- // say our listeners goobye
+ // say goodbye to our listeners
EventObject aEvt(*this);
m_aApproveListeners.disposeAndClear(aEvt);
m_aContainerListeners.disposeAndClear(aEvt);
@@ -197,7 +162,6 @@ void SAL_CALL ODefinitionContainer::disposing()
m_aDocumentMap.clear();
}
-//--------------------------------------------------------------------------
ODefinitionContainer::~ODefinitionContainer()
{
DBG_DTOR(ODefinitionContainer, NULL);
@@ -206,12 +170,11 @@ ODefinitionContainer::~ODefinitionContainer()
IMPLEMENT_FORWARD_XINTERFACE2( ODefinitionContainer,OContentHelper,ODefinitionContainer_Base)
IMPLEMENT_TYPEPROVIDER2(ODefinitionContainer,OContentHelper,ODefinitionContainer_Base);
// XServiceInfo
-//--------------------------------------------------------------------------
::rtl::OUString SAL_CALL ODefinitionContainer::getImplementationName( ) throw(RuntimeException)
{
return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ODefinitionContainer"));
}
-//--------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > SAL_CALL ODefinitionContainer::getSupportedServiceNames( ) throw(RuntimeException)
{
Sequence< ::rtl::OUString > aReturn(2);
@@ -221,7 +184,6 @@ Sequence< ::rtl::OUString > SAL_CALL ODefinitionContainer::getSupportedServiceNa
}
// XNameContainer
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::insertByName( const ::rtl::OUString& _rName, const Any& aElement ) throw(IllegalArgumentException, ElementExistException, WrappedTargetException, RuntimeException)
{
ResettableMutexGuard aGuard(m_aMutex);
@@ -235,7 +197,6 @@ void SAL_CALL ODefinitionContainer::insertByName( const ::rtl::OUString& _rName,
notifyByName( aGuard, _rName, xNewElement, NULL, E_INSERTED, ContainerListemers );
}
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::removeByName( const ::rtl::OUString& _rName ) throw(NoSuchElementException, WrappedTargetException, RuntimeException)
{
ResettableMutexGuard aGuard(m_aMutex);
@@ -260,7 +221,6 @@ void SAL_CALL ODefinitionContainer::removeByName( const ::rtl::OUString& _rName
}
// XNameReplace
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::replaceByName( const ::rtl::OUString& _rName, const Any& aElement ) throw(IllegalArgumentException, NoSuchElementException, WrappedTargetException, RuntimeException)
{
ResettableMutexGuard aGuard(m_aMutex);
@@ -280,7 +240,6 @@ void SAL_CALL ODefinitionContainer::replaceByName( const ::rtl::OUString& _rName
disposeComponent(xOldElement);
}
-// -----------------------------------------------------------------------------
namespace
{
typedef Reference< XVeto > ( SAL_CALL XContainerApproveListener::*ContainerApprovalMethod )( const ContainerEvent& );
@@ -319,7 +278,6 @@ namespace
};
}
-// -----------------------------------------------------------------------------
void ODefinitionContainer::notifyByName( ResettableMutexGuard& _rGuard, const ::rtl::OUString& _rName,
const Reference< XContent >& _xNewElement, const Reference< XContent >& _xOldElement,
ContainerOperation _eOperation, ListenerType _eType )
@@ -362,43 +320,36 @@ void ODefinitionContainer::notifyByName( ResettableMutexGuard& _rGuard, const ::
_rGuard.reset();
}
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::addContainerListener( const Reference< XContainerListener >& _rxListener ) throw(RuntimeException)
{
if (_rxListener.is())
m_aContainerListeners.addInterface(_rxListener);
}
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::removeContainerListener( const Reference< XContainerListener >& _rxListener ) throw(RuntimeException)
{
if (_rxListener.is())
m_aContainerListeners.removeInterface(_rxListener);
}
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::addContainerApproveListener( const Reference< XContainerApproveListener >& _Listener ) throw (RuntimeException)
{
if ( _Listener.is() )
m_aApproveListeners.addInterface( _Listener );
}
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::removeContainerApproveListener( const Reference< XContainerApproveListener >& _Listener ) throw (RuntimeException)
{
if ( _Listener.is() )
m_aApproveListeners.removeInterface( _Listener );
}
-
// XElementAccess
-//--------------------------------------------------------------------------
Type SAL_CALL ODefinitionContainer::getElementType( ) throw (RuntimeException)
{
return ::getCppuType( static_cast< Reference< XContent >* >(NULL) );
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL ODefinitionContainer::hasElements( ) throw (RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -406,14 +357,12 @@ sal_Bool SAL_CALL ODefinitionContainer::hasElements( ) throw (RuntimeException)
}
// XEnumerationAccess
-//--------------------------------------------------------------------------
Reference< XEnumeration > SAL_CALL ODefinitionContainer::createEnumeration( ) throw(RuntimeException)
{
MutexGuard aGuard(m_aMutex);
return new ::comphelper::OEnumerationByIndex(static_cast<XIndexAccess*>(this));
}
-//--------------------------------------------------------------------------
// XIndexAccess
sal_Int32 SAL_CALL ODefinitionContainer::getCount( ) throw(RuntimeException)
{
@@ -421,7 +370,6 @@ sal_Int32 SAL_CALL ODefinitionContainer::getCount( ) throw(RuntimeException)
return m_aDocuments.size();
}
-//--------------------------------------------------------------------------
Any SAL_CALL ODefinitionContainer::getByIndex( sal_Int32 _nIndex ) throw(IndexOutOfBoundsException, WrappedTargetException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -442,7 +390,6 @@ Any SAL_CALL ODefinitionContainer::getByIndex( sal_Int32 _nIndex ) throw(IndexOu
return makeAny(xProp);
}
-//--------------------------------------------------------------------------
Any SAL_CALL ODefinitionContainer::getByName( const ::rtl::OUString& _rName ) throw(NoSuchElementException, WrappedTargetException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -450,7 +397,6 @@ Any SAL_CALL ODefinitionContainer::getByName( const ::rtl::OUString& _rName ) th
return makeAny( implGetByName( _rName, sal_True ) );
}
-//--------------------------------------------------------------------------
Reference< XContent > ODefinitionContainer::implGetByName(const ::rtl::OUString& _rName, sal_Bool _bReadIfNeccessary) throw (NoSuchElementException)
{
Documents::iterator aMapPos = m_aDocumentMap.find(_rName);
@@ -472,7 +418,6 @@ Reference< XContent > ODefinitionContainer::implGetByName(const ::rtl::OUString&
return xProp;
}
-//--------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL ODefinitionContainer::getElementNames( ) throw(RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -491,7 +436,6 @@ Sequence< ::rtl::OUString > SAL_CALL ODefinitionContainer::getElementNames( ) t
return aNames;
}
-//--------------------------------------------------------------------------
sal_Bool SAL_CALL ODefinitionContainer::hasByName( const ::rtl::OUString& _rName ) throw(RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -499,7 +443,6 @@ sal_Bool SAL_CALL ODefinitionContainer::hasByName( const ::rtl::OUString& _rName
return checkExistence(_rName);
}
-//--------------------------------------------------------------------------
void SAL_CALL ODefinitionContainer::disposing( const EventObject& _rSource ) throw(RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -518,7 +461,6 @@ void SAL_CALL ODefinitionContainer::disposing( const EventObject& _rSource ) thr
}
}
-//--------------------------------------------------------------------------
void ODefinitionContainer::implRemove(const ::rtl::OUString& _rName)
{
// from the object maps
@@ -534,7 +476,6 @@ void ODefinitionContainer::implRemove(const ::rtl::OUString& _rName)
}
}
-//--------------------------------------------------------------------------
namespace
{
bool lcl_ensureName( const Reference< XContent >& _rxContent, const ::rtl::OUString& _rName )
@@ -542,7 +483,6 @@ namespace
if ( !_rxContent.is() )
return true;
- // ..........................................................
// obtain the current name. If it's the same as the new one,
// don't do anything
try
@@ -558,10 +498,9 @@ namespace
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "lcl_ensureName: caught an exception while obtaining the current name!" );
+ OSL_FAIL( "lcl_ensureName: caught an exception while obtaining the current name!" );
}
- // ..........................................................
// set the new name
Reference< XRename > xRename( _rxContent, UNO_QUERY );
OSL_ENSURE( xRename.is(), "lcl_ensureName: invalid content (not renameable)!" );
@@ -574,12 +513,12 @@ namespace
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "lcl_ensureName: caught an exception!" );
+ OSL_FAIL( "lcl_ensureName: caught an exception!" );
}
return false;
}
}
-//--------------------------------------------------------------------------
+
void ODefinitionContainer::implAppend(const ::rtl::OUString& _rName, const Reference< XContent >& _rxNewObject)
{
MutexGuard aGuard(m_aMutex);
@@ -593,11 +532,11 @@ void ODefinitionContainer::implAppend(const ::rtl::OUString& _rName, const Refer
ODefinitionContainer_Impl::const_iterator aFind = rDefinitions.find( _rName );
if ( aFind == rDefinitions.end() )
{
- // ensure that the new object thas the proper name.
+ // ensure that the new object has the proper name.
// Somebody could create an object with name "foo", and insert it as "bar"
// into a container. In this case, we need to ensure that the object name
// is also "bar"
- // #i44786# / 2005-03-11 / frank.schoenheit@sun.com
+ // #i44786#
lcl_ensureName( _rxNewObject, _rName );
::rtl::Reference< OContentHelper > pContent = OContentHelper::getImplementation( _rxNewObject );
@@ -619,14 +558,13 @@ void ODefinitionContainer::implAppend(const ::rtl::OUString& _rName, const Refer
}
catch(Exception&)
{
- DBG_ERROR("ODefinitionContainer::implAppend: caught something !");
+ OSL_FAIL("ODefinitionContainer::implAppend: caught something !");
}
}
-//--------------------------------------------------------------------------
void ODefinitionContainer::implReplace(const ::rtl::OUString& _rName, const Reference< XContent >& _rxNewObject)
{
- DBG_ASSERT(checkExistence(_rName), "ODefinitionContainer::implReplace : invalid name !");
+ OSL_ENSURE(checkExistence(_rName), "ODefinitionContainer::implReplace : invalid name !");
Documents::iterator aFind = m_aDocumentMap.find(_rName);
removeObjectListener(aFind->second);
@@ -634,7 +572,6 @@ void ODefinitionContainer::implReplace(const ::rtl::OUString& _rName, const Refe
addObjectListener(aFind->second);
}
-// -----------------------------------------------------------------------------
void ODefinitionContainer::approveNewObject(const ::rtl::OUString& _sName,const Reference< XContent >& _rxObject) const
{
// check the arguments
@@ -675,7 +612,6 @@ void ODefinitionContainer::approveNewObject(const ::rtl::OUString& _sName,const
*this );
}
-// -----------------------------------------------------------------------------
// XPropertyChangeListener
void SAL_CALL ODefinitionContainer::propertyChange( const PropertyChangeEvent& evt ) throw (RuntimeException)
{
@@ -701,7 +637,7 @@ void SAL_CALL ODefinitionContainer::propertyChange( const PropertyChangeEvent& e
m_bInPropertyChange = sal_False;
}
}
-// -----------------------------------------------------------------------------
+
// XVetoableChangeListener
void SAL_CALL ODefinitionContainer::vetoableChange( const PropertyChangeEvent& aEvent ) throw (PropertyVetoException, RuntimeException)
{
@@ -715,7 +651,7 @@ void SAL_CALL ODefinitionContainer::vetoableChange( const PropertyChangeEvent& a
throw PropertyVetoException();
}
}
-// -----------------------------------------------------------------------------
+
void ODefinitionContainer::addObjectListener(const Reference< XContent >& _xNewObject)
{
OSL_ENSURE(_xNewObject.is(),"ODefinitionContainer::addObjectListener: Object is null!");
@@ -726,7 +662,7 @@ void ODefinitionContainer::addObjectListener(const Reference< XContent >& _xNewO
xProp->addVetoableChangeListener(PROPERTY_NAME, this);
}
}
-// -----------------------------------------------------------------------------
+
void ODefinitionContainer::removeObjectListener(const Reference< XContent >& _xNewObject)
{
Reference<XPropertySet> xProp(_xNewObject,UNO_QUERY);
@@ -736,13 +672,12 @@ void ODefinitionContainer::removeObjectListener(const Reference< XContent >& _xN
xProp->removeVetoableChangeListener(PROPERTY_NAME, this);
}
}
-// -----------------------------------------------------------------------------
+
sal_Bool ODefinitionContainer::checkExistence(const ::rtl::OUString& _rName)
{
return m_aDocumentMap.find(_rName) != m_aDocumentMap.end();
}
-//........................................................................
}
// namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documentcontainer.cxx b/dbaccess/source/core/dataaccess/documentcontainer.cxx
index d9427eff0463..bdec740dc305 100644
--- a/dbaccess/source/core/dataaccess/documentcontainer.cxx
+++ b/dbaccess/source/core/dataaccess/documentcontainer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,64 +29,30 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREDATAACCESS_DOCUMENTCONTAINER_HXX_
#include "documentcontainer.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _DBA_COREDATAACCESS_DOCUMENTDEFINITION_HXX_
#include "documentdefinition.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UCB_OPENCOMMANDARGUMENT2_HPP_
#include <com/sun/star/ucb/OpenCommandArgument2.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_OPENMODE_HPP_
#include <com/sun/star/ucb/OpenMode.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef DBA_UCPRESULTSET_HXX
#include "myucp_resultset.hxx"
-#endif
-#ifndef _UCBHELPER_CANCELCOMMANDEXECUTION_HXX_
#include <ucbhelper/cancelcommandexecution.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UCB_UNSUPPORTEDOPENMODEEXCEPTION_HPP_
#include <com/sun/star/ucb/UnsupportedOpenModeException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_INSERTCOMMANDARGUMENT_HPP_
#include <com/sun/star/ucb/InsertCommandArgument.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_ERRORCONDITION_HPP_
#include <com/sun/star/sdb/ErrorCondition.hpp>
-#endif
-#ifndef _DBA_COREDATAACCESS_DATASOURCE_HXX_
#include "datasource.hxx"
-#endif
#include <comphelper/classids.hxx>
-#ifndef _COMPHELPER_MIMECONFIGHELPER_HXX_
#include <comphelper/mimeconfighelper.hxx>
-#endif
-#ifndef INCLUDED_COMPHELPER_STRING_HXX
#include <comphelper/string.hxx>
-#endif
-#ifndef CONNECTIVITY_SQLERROR_HXX
#include <connectivity/sqlerror.hxx>
-#endif
#include "core_resource.hxx"
#include "core_resource.hrc"
#include <comphelper/namedvaluecollection.hxx>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <comphelper/namedvaluecollection.hxx>
using namespace ::com::sun::star::uno;
@@ -101,10 +68,8 @@ using namespace ::osl;
using namespace ::comphelper;
using namespace ::cppu;
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= LocalNameApproval
@@ -125,7 +90,6 @@ public:
void SAL_CALL approveElement( const ::rtl::OUString& _rName, const Reference< XInterface >& _rxElement );
};
-//--------------------------------------------------------------------------
void SAL_CALL LocalNameApproval::approveElement( const ::rtl::OUString& _rName, const Reference< XInterface >& /*_rxElement*/ )
{
if ( _rName.indexOf( '/' ) != -1 )
@@ -140,7 +104,7 @@ void SAL_CALL LocalNameApproval::approveElement( const ::rtl::OUString& _rName,
//= ODocumentContainer
//==========================================================================
DBG_NAME(ODocumentContainer)
-//--------------------------------------------------------------------------
+
ODocumentContainer::ODocumentContainer(const Reference< XMultiServiceFactory >& _xORB
,const Reference< XInterface >& _xParentContainer
,const TContentPtr& _pImpl
@@ -157,7 +121,6 @@ ODocumentContainer::ODocumentContainer(const Reference< XMultiServiceFactory >&
setElementApproval( PContainerApprove( new LocalNameApproval ( _xORB ) ) );
}
-//--------------------------------------------------------------------------
ODocumentContainer::~ODocumentContainer()
{
DBG_DTOR(ODocumentContainer, NULL);
@@ -168,7 +131,7 @@ ODocumentContainer::~ODocumentContainer()
dispose();
}
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_FORWARD_XINTERFACE3( ODocumentContainer,ODefinitionContainer,ODocumentContainer_Base,OPropertyStateContainer)
IMPLEMENT_TYPEPROVIDER3(ODocumentContainer,ODefinitionContainer,OPropertyStateContainer,ODocumentContainer_Base);
IMPLEMENT_SERVICE_INFO_IMPLNAME(ODocumentContainer, "com.sun.star.comp.dba.ODocumentContainer");
@@ -182,13 +145,11 @@ Sequence< ::rtl::OUString > SAL_CALL ODocumentContainer::getSupportedServiceName
return aSupported;
}
-// -----------------------------------------------------------------------------
::rtl::OUString ODocumentContainer::determineContentType() const
{
return ::rtl::OUString();
}
-//--------------------------------------------------------------------------
Reference< XContent > ODocumentContainer::createObject( const ::rtl::OUString& _rName)
{
const ODefinitionContainer_Impl& rDefinitions( getDefinitions() );
@@ -198,7 +159,7 @@ Reference< XContent > ODocumentContainer::createObject( const ::rtl::OUString& _
return new ODocumentContainer( m_aContext.getLegacyServiceFactory(), *this, aFind->second, m_bFormsContainer );
return new ODocumentDefinition( *this, m_aContext.getLegacyServiceFactory(), aFind->second, m_bFormsContainer );
}
-// -----------------------------------------------------------------------------
+
Reference< XInterface > SAL_CALL ODocumentContainer::createInstance( const ::rtl::OUString& aServiceSpecifier ) throw (Exception, RuntimeException)
{
return createInstanceWithArguments( aServiceSpecifier, Sequence< Any >() );
@@ -217,7 +178,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
Reference< XInterface > SAL_CALL ODocumentContainer::createInstanceWithArguments( const ::rtl::OUString& ServiceSpecifier, const Sequence< Any >& _aArguments ) throw (Exception, RuntimeException)
{
Reference< XInterface > xRet;
@@ -226,7 +186,7 @@ Reference< XInterface > SAL_CALL ODocumentContainer::createInstanceWithArguments
{
MutexGuard aGuard(m_aMutex);
- // extrat known arguments
+ // extract known arguments
::rtl::OUString sName, sPersistentName, sURL, sMediaType, sDocServiceName;
Reference< XCommandProcessor > xCopyFrom;
Reference< XConnection > xConnection;
@@ -271,7 +231,7 @@ Reference< XInterface > SAL_CALL ODocumentContainer::createInstanceWithArguments
if ( bNew )
{
const static ::rtl::OUString sBaseName(RTL_CONSTASCII_USTRINGPARAM("Obj"));
- // -----------------------------------------------------------------------------
+
sPersistentName = sBaseName;
sPersistentName += ::rtl::OUString::valueOf(sal_Int32(rDefinitions.size() + 1));
Reference<XNameAccess> xElements(getContainerStorage(),UNO_QUERY);
@@ -353,8 +313,6 @@ Reference< XInterface > SAL_CALL ODocumentContainer::createInstanceWithArguments
xCommandProcessor->execute(aCommand,-1,Reference< XCommandEnvironment >());
}
}
-
- // xRet = xContent;
}
else if ( ServiceSpecifier == SERVICE_NAME_FORM_COLLECTION || SERVICE_NAME_REPORT_COLLECTION == ServiceSpecifier )
{
@@ -442,7 +400,7 @@ Reference< XInterface > SAL_CALL ODocumentContainer::createInstanceWithArguments
xRet = xContent;
return xRet;
}
-// -----------------------------------------------------------------------------
+
Sequence< ::rtl::OUString > SAL_CALL ODocumentContainer::getAvailableServiceNames( ) throw (RuntimeException)
{
Sequence< ::rtl::OUString > aSe(3);
@@ -451,7 +409,7 @@ Sequence< ::rtl::OUString > SAL_CALL ODocumentContainer::getAvailableServiceName
aSe[2] = SERVICE_NAME_REPORT_COLLECTION;
return aSe;
}
-// -----------------------------------------------------------------------------
+
Any SAL_CALL ODocumentContainer::execute( const Command& aCommand, sal_Int32 CommandId, const Reference< XCommandEnvironment >& Environment ) throw (Exception, CommandAbortedException, RuntimeException)
{
Any aRet;
@@ -463,7 +421,7 @@ Any SAL_CALL ODocumentContainer::execute( const Command& aCommand, sal_Int32 Com
OpenCommandArgument2 aOpenCommand;
if ( !( aCommand.Argument >>= aOpenCommand ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -509,7 +467,7 @@ Any SAL_CALL ODocumentContainer::execute( const Command& aCommand, sal_Int32 Com
InsertCommandArgument arg;
if ( !( aCommand.Argument >>= arg ) )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -536,7 +494,7 @@ Any SAL_CALL ODocumentContainer::execute( const Command& aCommand, sal_Int32 Com
aRet = OContentHelper::execute(aCommand,CommandId,Environment);
return aRet;
}
-// -----------------------------------------------------------------------------
+
namespace
{
sal_Bool lcl_queryContent(const ::rtl::OUString& _sName,Reference< XNameContainer >& _xNameContainer,Any& _rRet,::rtl::OUString& _sSimpleName)
@@ -569,13 +527,13 @@ namespace
return bRet;
}
}
-// -----------------------------------------------------------------------------
+
Reference< XComponent > SAL_CALL ODocumentContainer::loadComponentFromURL( const ::rtl::OUString& _sURL
, const ::rtl::OUString& /*TargetFrameName*/
, sal_Int32 /*SearchFlags*/
, const Sequence< PropertyValue >& Arguments ) throw (IOException, IllegalArgumentException, RuntimeException)
{
- vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ ::SolarMutexGuard aSolarGuard;
MutexGuard aGuard(m_aMutex);
Reference< XComponent > xComp;
@@ -608,18 +566,17 @@ Reference< XComponent > SAL_CALL ODocumentContainer::loadComponentFromURL( const
xComp.set(xContent->execute(aCommand,xContent->createCommandIdentifier(),Reference< XCommandEnvironment >()),UNO_QUERY);
}
}
- catch(NoSuchElementException)
+ catch(const NoSuchElementException&)
{
throw IllegalArgumentException();
}
- catch(WrappedTargetException e)
+ catch(const WrappedTargetException&)
{
- // throw IllegalArgumentException();
throw;
}
return xComp;
}
-// -----------------------------------------------------------------------------
+
Any SAL_CALL ODocumentContainer::getByHierarchicalName( const ::rtl::OUString& _sName ) throw (NoSuchElementException, RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -630,7 +587,7 @@ Any SAL_CALL ODocumentContainer::getByHierarchicalName( const ::rtl::OUString& _
return aContent;
throw NoSuchElementException(_sName,*this);
}
-// -----------------------------------------------------------------------------
+
sal_Bool SAL_CALL ODocumentContainer::hasByHierarchicalName( const ::rtl::OUString& _sName ) throw (RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -639,7 +596,7 @@ sal_Bool SAL_CALL ODocumentContainer::hasByHierarchicalName( const ::rtl::OUStri
::rtl::OUString sName;
return lcl_queryContent(_sName,xNameContainer,aContent,sName);
}
-// -----------------------------------------------------------------------------
+
// XHierarchicalNameContainer
void SAL_CALL ODocumentContainer::insertByHierarchicalName( const ::rtl::OUString& _sName, const Any& _aElement ) throw (IllegalArgumentException, ElementExistException, WrappedTargetException, RuntimeException)
{
@@ -664,7 +621,7 @@ void SAL_CALL ODocumentContainer::insertByHierarchicalName( const ::rtl::OUStrin
xNameContainer->insertByName(sName,_aElement);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentContainer::removeByHierarchicalName( const ::rtl::OUString& _sName ) throw (NoSuchElementException, WrappedTargetException, RuntimeException)
{
if ( !_sName.getLength() )
@@ -679,7 +636,7 @@ void SAL_CALL ODocumentContainer::removeByHierarchicalName( const ::rtl::OUStrin
xNameContainer->removeByName(sName);
}
-// -----------------------------------------------------------------------------
+
// XHierarchicalNameReplace
void SAL_CALL ODocumentContainer::replaceByHierarchicalName( const ::rtl::OUString& _sName, const Any& _aElement ) throw (IllegalArgumentException, NoSuchElementException, WrappedTargetException, RuntimeException)
{
@@ -697,14 +654,12 @@ void SAL_CALL ODocumentContainer::replaceByHierarchicalName( const ::rtl::OUStri
xNameContainer->replaceByName(sName,_aElement);
}
-// -----------------------------------------------------------------------------
::rtl::OUString SAL_CALL ODocumentContainer::getHierarchicalName() throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
return impl_getHierarchicalName( false );
}
-// -----------------------------------------------------------------------------
::rtl::OUString SAL_CALL ODocumentContainer::composeHierarchicalName( const ::rtl::OUString& i_rRelativeName ) throw (IllegalArgumentException, NoSupportException, RuntimeException)
{
::rtl::OUStringBuffer aBuffer;
@@ -714,7 +669,6 @@ void SAL_CALL ODocumentContainer::replaceByHierarchicalName( const ::rtl::OUStri
return aBuffer.makeStringAndClear();
}
-// -----------------------------------------------------------------------------
::rtl::Reference<OContentHelper> ODocumentContainer::getContent(const ::rtl::OUString& _sName) const
{
::rtl::Reference<OContentHelper> pContent = NULL;
@@ -724,17 +678,17 @@ void SAL_CALL ODocumentContainer::replaceByHierarchicalName( const ::rtl::OUStri
if ( xUnoTunnel.is() )
pContent = reinterpret_cast<OContentHelper*>(xUnoTunnel->getSomething(OContentHelper::getUnoTunnelImplementationId()));
}
- catch(Exception)
+ catch(const Exception&)
{
}
return pContent;
}
-// -----------------------------------------------------------------------------
+
void ODocumentContainer::getPropertyDefaultByHandle( sal_Int32 /*_nHandle*/, Any& _rDefault ) const
{
_rDefault.clear();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentContainer::commit( ) throw (::com::sun::star::io::IOException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -750,7 +704,7 @@ void SAL_CALL ODocumentContainer::commit( ) throw (::com::sun::star::io::IOExce
if ( xTrans.is() )
xTrans->commit();
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentContainer::revert( ) throw (::com::sun::star::io::IOException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException)
{
MutexGuard aGuard(m_aMutex);
@@ -766,7 +720,7 @@ void SAL_CALL ODocumentContainer::revert( ) throw (::com::sun::star::io::IOExce
if ( xTrans.is() )
xTrans->revert();
}
-// -----------------------------------------------------------------------------
+
Reference< XStorage> ODocumentContainer::getContainerStorage() const
{
return m_pImpl->m_pDataSource
@@ -774,7 +728,6 @@ Reference< XStorage> ODocumentContainer::getContainerStorage() const
: Reference< XStorage>();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODocumentContainer::removeByName( const ::rtl::OUString& _rName ) throw(NoSuchElementException, WrappedTargetException, RuntimeException)
{
ResettableMutexGuard aGuard(m_aMutex);
@@ -798,12 +751,9 @@ void SAL_CALL ODocumentContainer::removeByName( const ::rtl::OUString& _rName )
// do the removal
implRemove(_rName);
- // disposeComponent(xContent); // no dispose here, the object may be inserted again under a different name
-
notifyByName( aGuard, _rName, NULL, NULL, E_REMOVED, ContainerListemers );
}
-// -----------------------------------------------------------------------------
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentContainer::rename( const ::rtl::OUString& newName ) throw (SQLException, ElementExistException, RuntimeException)
{
try
@@ -827,7 +777,5 @@ void SAL_CALL ODocumentContainer::rename( const ::rtl::OUString& newName ) throw
}
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documentcontainer.hxx b/dbaccess/source/core/dataaccess/documentcontainer.hxx
index c1a9c424d7d3..dafeef03fabf 100644
--- a/dbaccess/source/core/dataaccess/documentcontainer.hxx
+++ b/dbaccess/source/core/dataaccess/documentcontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,41 +29,19 @@
#ifndef _DBA_COREDATAACCESS_DOCUMENTCONTAINER_HXX_
#define _DBA_COREDATAACCESS_DOCUMENTCONTAINER_HXX_
-#ifndef _DBA_CORE_DEFINITIONCONTAINER_HXX_
#include "definitioncontainer.hxx"
-#endif
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_
#include <com/sun/star/frame/XComponentLoader.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMECONTAINER_HPP_
#include <com/sun/star/container/XHierarchicalNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAME_HPP_
#include <com/sun/star/container/XHierarchicalName.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XTRANSACTEDOBJECT_HPP_
#include <com/sun/star/embed/XTransactedObject.hpp>
-#endif
-#ifndef COMPHELPER_PROPERTYSTATECONTAINER_HXX
#include <comphelper/propertystatecontainer.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
typedef ::cppu::ImplHelper5 < ::com::sun::star::frame::XComponentLoader
, ::com::sun::star::lang::XMultiServiceFactory
, ::com::sun::star::container::XHierarchicalNameContainer
@@ -160,9 +139,8 @@ protected:
virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_COREDATAACCESS_DOCUMENTCONTAINER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documentdefinition.cxx b/dbaccess/source/core/dataaccess/documentdefinition.cxx
index 7678cfbba62e..4604f1d4cd44 100644
--- a/dbaccess/source/core/dataaccess/documentdefinition.cxx
+++ b/dbaccess/source/core/dataaccess/documentdefinition.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,224 +29,84 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_COREDATAACCESS_DOCUMENTDEFINITION_HXX_
#include "documentdefinition.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef DBACORE_SDBCORETOOLS_HXX
#include "sdbcoretools.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
+#include <osl/diagnose.h>
#include <comphelper/property.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_MEDIADESCRIPTOR_HXX_
#include <comphelper/mediadescriptor.hxx>
-#endif
-#ifndef COMPHELPER_NAMEDVALUECOLLECTION_HXX
#include <comphelper/namedvaluecollection.hxx>
-#endif
-#ifndef _COMPHELPER_CLASSIDS_HXX
#include <comphelper/classids.hxx>
-#endif
#include <com/sun/star/frame/XUntitledNumbers.hpp>
-#ifndef _COM_SUN_STAR_AWT_XTOPWINDOW_HPP_
#include <com/sun/star/awt/XTopWindow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_SIZE_HPP_
#include <com/sun/star/awt/Size.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XMODEL_HPP_
#include <com/sun/star/frame/XModel.hpp>
-#endif
#include <com/sun/star/frame/XTitle.hpp>
-#ifndef _COM_SUN_STAR_FRAME_XCONTROLLER_HPP_
#include <com/sun/star/frame/XController.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XJOBEXECUTOR_HPP_
#include <com/sun/star/task/XJobExecutor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCHPROVIDERINTERCEPTION_HPP_
#include <com/sun/star/frame/XDispatchProviderInterception.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XFRAMESSUPPLIER_HPP_
#include <com/sun/star/frame/XFramesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_INSERTCOMMANDARGUMENT_HPP_
#include <com/sun/star/ucb/InsertCommandArgument.hpp>
-#endif
#include <com/sun/star/report/XReportDefinition.hpp>
#include <com/sun/star/report/XReportEngine.hpp>
-#ifndef _COM_SUN_STAR_UCB_OPENMODE_HPP_
#include <com/sun/star/ucb/OpenMode.hpp>
-#endif
-#ifndef _COM_SUN_STAR_XEMBEDOBJECTFACTORY_HPP_
#include <com/sun/star/embed/XEmbedObjectFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_XEMBEDOBJECTCREATOR_HPP_
#include <com/sun/star/embed/XEmbedObjectCreator.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_ASPECTS_HPP_
#include <com/sun/star/embed/Aspects.hpp>
-#endif
-#ifndef _UCBHELPER_CANCELCOMMANDEXECUTION_HXX_
#include <ucbhelper/cancelcommandexecution.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UCB_UNSUPPORTEDDATASINKEXCEPTION_HPP_
#include <com/sun/star/ucb/UnsupportedDataSinkException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_UNSUPPORTEDOPENMODEEXCEPTION_HPP_
#include <com/sun/star/ucb/UnsupportedOpenModeException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ELEMENTMODES_HPP_
#include <com/sun/star/embed/ElementModes.hpp>
-#endif
-#ifndef _COM_SUN_STAR_XEMBEDPERSIST_HPP_
#include <com/sun/star/embed/XEmbedPersist.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBEDSTATES_HPP_
#include <com/sun/star/embed/EmbedStates.hpp>
-#endif
-#ifndef _COM_SUN_STAR_XCOMPONENTSUPPLIER_HPP_
#include <com/sun/star/embed/XComponentSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ENTRYINITMODES_HPP_
#include <com/sun/star/embed/EntryInitModes.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_MISSINGPROPERTIESEXCEPTION_HPP_
#include <com/sun/star/ucb/MissingPropertiesException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_MISSINGINPUTSTREAMEXCEPTION_HPP_
#include <com/sun/star/ucb/MissingInputStreamException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_OPENCOMMANDARGUMENT2_HPP_
#include <com/sun/star/ucb/OpenCommandArgument2.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XCLOSEBROADCASTER_HPP_
#include <com/sun/star/util/XCloseBroadcaster.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XMODULE_HPP_
#include <com/sun/star/frame/XModule.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DATATRANSFER_DATAFLAVOR_HPP_
#include <com/sun/star/datatransfer/DataFlavor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DATATRANSFER_XTRANSFERABLE_HPP_
#include <com/sun/star/datatransfer/XTransferable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_XTRANSACTEDOBJECT_HPP_
#include <com/sun/star/embed/XTransactedObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XCOMMONEMBEDPERSIST_HPP_
#include <com/sun/star/embed/XCommonEmbedPersist.hpp>
-#endif
-#ifndef DBA_INTERCEPT_HXX
#include "intercept.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDB_ERRORCONDITION_HPP_
#include <com/sun/star/sdb/ErrorCondition.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XINTERACTIONDOCUMENTSAVE_HPP_
#include <com/sun/star/sdb/XInteractionDocumentSave.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_DOCUMENTSAVEREQUEST_HPP_
#include <com/sun/star/sdb/DocumentSaveRequest.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XDOCUMENTPROPERTIESSUPPLIER_HPP_
#include <com/sun/star/document/XDocumentPropertiesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_MACROEXECMODE_HPP_
#include <com/sun/star/document/MacroExecMode.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DRAWING_XDRAWPAGESUPPLIER_HPP_
#include <com/sun/star/drawing/XDrawPageSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXCONTAINER_HPP_
#include <com/sun/star/container/XIndexContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XFORMSSUPPLIER_HPP_
#include <com/sun/star/form/XFormsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XFORM_HPP_
#include <com/sun/star/form/XForm.hpp>
-#endif
-#ifndef _COMPHELPER_INTERACTION_HXX_
#include <comphelper/interaction.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
-#ifndef _COM_SUN_STAR_VIEW_XVIEWSETTINGSSUPPLIER_HPP_
+#include <osl/mutex.hxx>
+#include <sal/macros.h>
#include <com/sun/star/view/XViewSettingsSupplier.hpp>
-#endif
-#ifndef _DBA_CORE_RESOURCE_HXX_
#include "core_resource.hxx"
-#endif
-#ifndef _DBA_CORE_RESOURCE_HRC_
#include "core_resource.hrc"
-#endif
-#ifndef _DBA_COREDATAACCESS_DATASOURCE_HXX_
#include "datasource.hxx"
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XSTATECHANGEBROADCASTER_HPP_
#include <com/sun/star/embed/XStateChangeBroadcaster.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONAPPROVE_HPP_
#include <com/sun/star/task/XInteractionApprove.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONDISAPPROVE_HPP_
#include <com/sun/star/task/XInteractionDisapprove.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XLAYOUTMANAGER_HPP_
#include <com/sun/star/frame/XLayoutManager.hpp>
-#endif
-#ifndef _CPPUHELPER_COMPBASE1_HXX_
#include <cppuhelper/compbase1.hxx>
-#endif
#include <cppuhelper/exc_hlp.hxx>
-#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
-#endif
-#ifndef _COMPHELPER_SEQUENCEASHASHMAP_HXX_
#include <comphelper/sequenceashashmap.hxx>
-#endif
-#ifndef _COMPHELPER_MIMECONFIGHELPER_HXX_
#include <comphelper/mimeconfighelper.hxx>
-#endif
-#ifndef _COMPHELPER_STORAGEHELPER_HXX
#include <comphelper/storagehelper.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTENTENUMERATIONACCESS_HPP_
#include <com/sun/star/container/XContentEnumerationAccess.hpp>
-#endif
#include <com/sun/star/io/WrongFormatException.hpp>
#include <com/sun/star/sdb/application/XDatabaseDocumentUI.hpp>
#include <com/sun/star/sdb/application/DatabaseObject.hpp>
@@ -281,10 +142,9 @@ namespace DatabaseObject = sdb::application::DatabaseObject;
#define DEFAULT_WIDTH 10000
#define DEFAULT_HEIGHT 7500
-//.............................................................................
+
namespace dbaccess
{
-//.............................................................................
typedef ::boost::optional< bool > optional_bool;
@@ -346,7 +206,7 @@ namespace dbaccess
virtual void SAL_CALL stateChanged( const lang::EventObject& aEvent, ::sal_Int32 nOldState, ::sal_Int32 nNewState ) throw (uno::RuntimeException);
virtual void SAL_CALL disposing( const lang::EventObject& Source ) throw (uno::RuntimeException);
};
- //------------------------------------------------------------------
+
void SAL_CALL OEmbedObjectHolder::disposing()
{
if ( m_xBroadCaster.is() )
@@ -354,17 +214,16 @@ namespace dbaccess
m_xBroadCaster = NULL;
m_pDefinition = NULL;
}
- //------------------------------------------------------------------
+
void SAL_CALL OEmbedObjectHolder::changingState( const lang::EventObject& /*aEvent*/, ::sal_Int32 nOldState, ::sal_Int32 nNewState ) throw (embed::WrongStateException, uno::RuntimeException)
{
if ( !m_bInChangingState && nNewState == EmbedStates::RUNNING && nOldState == EmbedStates::ACTIVE && m_pDefinition )
{
m_bInChangingState = true;
- //m_pDefinition->save(sal_False);
m_bInChangingState = false;
}
}
- //------------------------------------------------------------------
+
void SAL_CALL OEmbedObjectHolder::stateChanged( const lang::EventObject& aEvent, ::sal_Int32 nOldState, ::sal_Int32 nNewState ) throw (uno::RuntimeException)
{
if ( !m_bInStateChange && nNewState == EmbedStates::RUNNING && nOldState == EmbedStates::ACTIVE && m_pDefinition )
@@ -379,7 +238,7 @@ namespace dbaccess
m_bInStateChange = false;
}
}
- //------------------------------------------------------------------
+
void SAL_CALL OEmbedObjectHolder::disposing( const lang::EventObject& /*Source*/ ) throw (uno::RuntimeException)
{
m_xBroadCaster = NULL;
@@ -480,20 +339,19 @@ namespace dbaccess
inline LifetimeCoupler( const Reference< XInterface >& _rxClient, const Reference< XComponent >& _rxActor )
:m_xClient( _rxClient )
{
- DBG_ASSERT( _rxActor.is(), "LifetimeCoupler::LifetimeCoupler: this will crash!" );
+ OSL_ENSURE( _rxActor.is(), "LifetimeCoupler::LifetimeCoupler: this will crash!" );
osl_incrementInterlockedCount( &m_refCount );
{
_rxActor->addEventListener( this );
}
osl_decrementInterlockedCount( &m_refCount );
- DBG_ASSERT( m_refCount, "LifetimeCoupler::LifetimeCoupler: the actor is not holding us by hard ref - this won't work!" );
+ OSL_ENSURE( m_refCount, "LifetimeCoupler::LifetimeCoupler: the actor is not holding us by hard ref - this won't work!" );
}
virtual void SAL_CALL disposing( const css::lang::EventObject& Source ) throw (RuntimeException);
protected:
};
- //------------------------------------------------------------------
void SAL_CALL LifetimeCoupler::disposing( const css::lang::EventObject& /*Source*/ ) throw (RuntimeException)
{
m_xClient.clear();
@@ -517,14 +375,12 @@ namespace dbaccess
virtual void SAL_CALL setName( const ::rtl::OUString& _sName,const Reference<XContent>& _xParent) throw(RuntimeException);
};
- //------------------------------------------------------------------
void SAL_CALL ODocumentSaveContinuation::setName( const ::rtl::OUString& _sName,const Reference<XContent>& _xParent) throw(RuntimeException)
{
m_sName = _sName;
m_xParentContainer = _xParent;
}
-// -----------------------------------------------------------------------------
::rtl::OUString ODocumentDefinition::GetDocumentServiceFromMediaType( const Reference< XStorage >& _rxContainerStorage,
const ::rtl::OUString& _rEntityName, const ::comphelper::ComponentContext& _rContext,
Sequence< sal_Int8 >& _rClassId )
@@ -534,7 +390,6 @@ namespace dbaccess
_rContext, _rClassId );
}
-// -----------------------------------------------------------------------------
::rtl::OUString ODocumentDefinition::GetDocumentServiceFromMediaType( const ::rtl::OUString& _rMediaType,
const ::comphelper::ComponentContext& _rContext, Sequence< sal_Int8 >& _rClassId )
{
@@ -576,19 +431,18 @@ namespace dbaccess
OSL_ENSURE( aAlternativeClassID == _rClassId, "ODocumentDefinition::GetDocumentServiceFromMediaType: failed, this approach is *not* equivalent (2)!" );
#endif
}
- catch ( Exception& )
+ catch ( const Exception& )
{
DBG_UNHANDLED_EXCEPTION();
}
return sResult;
}
-// -----------------------------------------------------------------------------
+
//==========================================================================
//= ODocumentDefinition
//==========================================================================
DBG_NAME(ODocumentDefinition)
-//--------------------------------------------------------------------------
ODocumentDefinition::ODocumentDefinition( const Reference< XInterface >& _rxContainer, const Reference< XMultiServiceFactory >& _xORB,
const TContentPtr& _pImpl, sal_Bool _bForm )
:OContentHelper(_xORB,_rxContainer,_pImpl)
@@ -604,7 +458,6 @@ ODocumentDefinition::ODocumentDefinition( const Reference< XInterface >& _rxCont
registerProperties();
}
-//--------------------------------------------------------------------------
void ODocumentDefinition::initialLoad( const Sequence< sal_Int8 >& i_rClassID, const Sequence< PropertyValue >& i_rCreationArgs,
const Reference< XConnection >& i_rConnection )
{
@@ -615,7 +468,6 @@ void ODocumentDefinition::initialLoad( const Sequence< sal_Int8 >& i_rClassID, c
loadEmbeddedObject( i_rConnection, i_rClassID, i_rCreationArgs, false, false );
}
-//--------------------------------------------------------------------------
ODocumentDefinition::~ODocumentDefinition()
{
DBG_DTOR(ODocumentDefinition, NULL);
@@ -632,7 +484,7 @@ ODocumentDefinition::~ODocumentDefinition()
m_pInterceptor = NULL;
}
}
-// -----------------------------------------------------------------------------
+
void ODocumentDefinition::closeObject()
{
::osl::MutexGuard aGuard(m_aMutex);
@@ -644,7 +496,7 @@ void ODocumentDefinition::closeObject()
if ( xCloseable.is() )
xCloseable->close(sal_True);
}
- catch(Exception)
+ catch(const Exception&)
{
}
m_xEmbeddedObject = NULL;
@@ -656,7 +508,7 @@ void ODocumentDefinition::closeObject()
}
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentDefinition::disposing()
{
OContentHelper::disposing();
@@ -670,11 +522,11 @@ void SAL_CALL ODocumentDefinition::disposing()
xCloseable->removeCloseListener(this);
}
}
-// -----------------------------------------------------------------------------
+
IMPLEMENT_TYPEPROVIDER3(ODocumentDefinition,OContentHelper,OPropertyStateContainer,ODocumentDefinition_Base);
IMPLEMENT_FORWARD_XINTERFACE3( ODocumentDefinition,OContentHelper,OPropertyStateContainer,ODocumentDefinition_Base)
IMPLEMENT_SERVICE_INFO1(ODocumentDefinition,"com.sun.star.comp.dba.ODocumentDefinition",SERVICE_SDB_DOCUMENTDEFINITION)
-//--------------------------------------------------------------------------
+
void ODocumentDefinition::registerProperties()
{
#define REGISTER_PROPERTY( name, location ) \
@@ -689,7 +541,6 @@ void ODocumentDefinition::registerProperties()
REGISTER_PROPERTY ( IS_FORM, m_bForm );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODocumentDefinition::getFastPropertyValue( Any& o_rValue, sal_Int32 i_nHandle ) const
{
if ( i_nHandle == PROPERTY_ID_PERSISTENT_PATH )
@@ -710,21 +561,17 @@ void SAL_CALL ODocumentDefinition::getFastPropertyValue( Any& o_rValue, sal_Int3
OPropertyStateContainer::getFastPropertyValue( o_rValue, i_nHandle );
}
-// -----------------------------------------------------------------------------
Reference< XPropertySetInfo > SAL_CALL ODocumentDefinition::getPropertySetInfo( ) throw(RuntimeException)
{
Reference<XPropertySetInfo> xInfo( createPropertySetInfo( getInfoHelper() ) );
return xInfo;
}
-//--------------------------------------------------------------------------
IPropertyArrayHelper& ODocumentDefinition::getInfoHelper()
{
return *getArrayHelper();
}
-
-//--------------------------------------------------------------------------
IPropertyArrayHelper* ODocumentDefinition::createArrayHelper( ) const
{
// properties maintained by our base class (see registerProperties)
@@ -741,7 +588,6 @@ IPropertyArrayHelper* ODocumentDefinition::createArrayHelper( ) const
return new OPropertyArrayHelper( ::comphelper::concatSequences( aProps, aManualProps ) );
}
-// -----------------------------------------------------------------------------
class OExecuteImpl
{
sal_Bool& m_rbSet;
@@ -750,7 +596,6 @@ public:
~OExecuteImpl(){ m_rbSet = sal_False; }
};
-// -----------------------------------------------------------------------------
namespace
{
bool lcl_extractOpenMode( const Any& _rValue, sal_Int32& _out_rMode )
@@ -770,7 +615,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::impl_removeFrameFromDesktop_throw( const ::comphelper::ComponentContext& _rContxt, const Reference< XFrame >& _rxFrame )
{
Reference< XFramesSupplier > xDesktop( _rContxt.createComponent( (::rtl::OUString)SERVICE_FRAME_DESKTOP ), UNO_QUERY_THROW );
@@ -778,7 +622,6 @@ void ODocumentDefinition::impl_removeFrameFromDesktop_throw( const ::comphelper:
xFrames->remove( _rxFrame );
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::impl_onActivateEmbeddedObject_nothrow( const bool i_bReactivated )
{
try
@@ -815,7 +658,6 @@ void ODocumentDefinition::impl_onActivateEmbeddedObject_nothrow( const bool i_bR
}
}
-// -----------------------------------------------------------------------------
namespace
{
// =========================================================================
@@ -839,9 +681,9 @@ namespace
{
m_aOriginalSize = m_xVisObject->getVisualAreaSize( Aspects::MSOLE_CONTENT );
}
- catch ( Exception& )
+ catch ( const Exception& )
{
- DBG_ERROR( "PreserveVisualAreaSize::PreserveVisualAreaSize: caught an exception!" );
+ OSL_FAIL( "PreserveVisualAreaSize::PreserveVisualAreaSize: caught an exception!" );
}
}
}
@@ -854,9 +696,9 @@ namespace
{
m_xVisObject->setVisualAreaSize( Aspects::MSOLE_CONTENT, m_aOriginalSize );
}
- catch ( Exception& )
+ catch ( const Exception& )
{
- DBG_ERROR( "PreserveVisualAreaSize::~PreserveVisualAreaSize: caught an exception!" );
+ OSL_FAIL( "PreserveVisualAreaSize::~PreserveVisualAreaSize: caught an exception!" );
}
}
}
@@ -875,7 +717,7 @@ namespace
public:
inline LayoutManagerLock( const Reference< XController >& _rxController )
{
- DBG_ASSERT( _rxController.is(), "LayoutManagerLock::LayoutManagerLock: this will crash!" );
+ OSL_ENSURE( _rxController.is(), "LayoutManagerLock::LayoutManagerLock: this will crash!" );
Reference< XFrame > xFrame( _rxController->getFrame() );
try
{
@@ -886,9 +728,9 @@ namespace
m_xLayoutManager->lock();
}
- catch( Exception& )
+ catch( const Exception& )
{
- DBG_ERROR( "LayoutManagerLock::LayoutManagerLock: caught an exception!" );
+ OSL_FAIL( "LayoutManagerLock::LayoutManagerLock: caught an exception!" );
}
}
@@ -900,15 +742,14 @@ namespace
if ( m_xLayoutManager.is() )
m_xLayoutManager->unlock();
}
- catch( Exception& )
+ catch( const Exception& )
{
- DBG_ERROR( "LayoutManagerLock::~LayoutManagerLock: caught an exception!" );
+ OSL_FAIL( "LayoutManagerLock::~LayoutManagerLock: caught an exception!" );
}
}
};
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::impl_initFormEditView( const Reference< XController >& _rxController )
{
try
@@ -943,7 +784,6 @@ void ODocumentDefinition::impl_initFormEditView( const Reference< XController >&
}
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::impl_showOrHideComponent_throw( const bool i_bShow )
{
const sal_Int32 nCurrentState = m_xEmbeddedObject.is() ? m_xEmbeddedObject->getCurrentState() : EmbedStates::LOADED;
@@ -976,7 +816,6 @@ void ODocumentDefinition::impl_showOrHideComponent_throw( const bool i_bShow )
}
}
-// -----------------------------------------------------------------------------
Any ODocumentDefinition::onCommandOpenSomething( const Any& _rOpenArgument, const bool _bActivate,
const Reference< XCommandEnvironment >& _rxEnvironment )
{
@@ -1014,7 +853,7 @@ Any ODocumentDefinition::onCommandOpenSomething( const Any& _rOpenArgument, cons
if ( lcl_extractOpenMode( pIter->Value, nOpenMode ) )
continue;
- if ( pIter->Name.equalsAscii( "MacroExecutionMode" ) )
+ if ( pIter->Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "MacroExecutionMode" ) ) )
{
sal_Int16 nMacroExecMode( !aDocumentMacroMode ? MacroExecMode::USE_CONFIG : *aDocumentMacroMode );
OSL_VERIFY( pIter->Value >>= nMacroExecMode );
@@ -1035,7 +874,7 @@ Any ODocumentDefinition::onCommandOpenSomething( const Any& _rOpenArgument, cons
// However, it is possible to programmatically load forms/reports, without actually
// loading the database document into a frame. In this case, the user will be asked
// here and now.
- // #i87741# / 2008-05-05 / frank.schoenheit@sun.com
+ // #i87741#
// allow the command arguments to downgrade the macro execution mode, but not to upgrade
// it
@@ -1096,7 +935,7 @@ Any ODocumentDefinition::onCommandOpenSomething( const Any& _rOpenArgument, cons
sal_Int16( nOpenMode ) ) ),
_rxEnvironment );
// Unreachable
- DBG_ERROR( "unreachable" );
+ OSL_FAIL( "unreachable" );
}
OSL_ENSURE( m_pImpl->m_aProps.sPersistentName.getLength(),
@@ -1160,14 +999,13 @@ Any ODocumentDefinition::onCommandOpenSomething( const Any& _rOpenArgument, cons
return makeAny( xModel );
}
-// -----------------------------------------------------------------------------
Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 CommandId, const Reference< XCommandEnvironment >& Environment ) throw (Exception, CommandAbortedException, RuntimeException)
{
Any aRet;
- sal_Bool bOpen = aCommand.Name.equalsAscii( "open" );
- sal_Bool bOpenInDesign = aCommand.Name.equalsAscii( "openDesign" );
- sal_Bool bOpenForMail = aCommand.Name.equalsAscii( "openForMail" );
+ sal_Bool bOpen = aCommand.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "open" ) );
+ sal_Bool bOpenInDesign = aCommand.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "openDesign" ) );
+ sal_Bool bOpenForMail = aCommand.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "openForMail" ) );
if ( bOpen || bOpenInDesign || bOpenForMail )
{
// opening the document involves a lot of VCL code, which is not thread-safe, but needs the SolarMutex locked.
@@ -1178,7 +1016,7 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
// However, we do /not/ have control over the EmbeddedObject implementation, and from a first look, it seems as
// making it release the own mutex before calling SolarMutex-code is ... difficult, at least.
// So, to be on the same side, we lock the SolarMutex here. Yes, it sucks.
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aSolarGuard;
::osl::ClearableMutexGuard aGuard(m_aMutex);
if ( m_bInExecute )
return aRet;
@@ -1186,12 +1024,11 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
bool bActivateObject = true;
if ( bOpenForMail )
{
- OSL_ENSURE( false, "ODocumentDefinition::execute: 'openForMail' should not be used anymore - use the 'Hidden' parameter instead!" );
+ OSL_FAIL( "ODocumentDefinition::execute: 'openForMail' should not be used anymore - use the 'Hidden' parameter instead!" );
bActivateObject = false;
}
// if the object is already opened, do nothing
- // #i89509# / 2008-05-22 / frank.schoenheit@sun.com
if ( m_xEmbeddedObject.is() )
{
sal_Int32 nCurrentState = m_xEmbeddedObject->getCurrentState();
@@ -1225,7 +1062,7 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
aCommand.Argument >>= aIni;
if ( aIni.getLength() != 2 )
{
- OSL_ENSURE( sal_False, "Wrong argument type!" );
+ OSL_FAIL( "Wrong argument type!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -1238,7 +1075,7 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
::rtl::OUString sPersistentName;
aIni[1] >>= sPersistentName;
Reference< XStorage> xStorage = getContainerStorage();
- // -----------------------------------------------------------------------------
+
xStorage->copyElementTo(m_pImpl->m_aProps.sPersistentName,xDest,sPersistentName);
}
else if ( aCommand.Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "preview" ) ) )
@@ -1251,7 +1088,7 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
aCommand.Argument >>= aIni;
if ( !aIni.getLength() )
{
- OSL_ENSURE( sal_False, "Wrong argument count!" );
+ OSL_FAIL( "Wrong argument count!" );
ucbhelper::cancelCommandExecution(
makeAny( IllegalArgumentException(
rtl::OUString(),
@@ -1310,7 +1147,7 @@ Any SAL_CALL ODocumentDefinition::execute( const Command& aCommand, sal_Int32 Co
return aRet;
}
-// -----------------------------------------------------------------------------
+
namespace
{
void lcl_resetChildFormsToEmptyDataSource( const Reference< XIndexAccess>& _rxFormsContainer )
@@ -1362,7 +1199,7 @@ namespace
}
}
-// -----------------------------------------------------------------------------
+
void ODocumentDefinition::onCommandInsert( const ::rtl::OUString& _sURL, const Reference< XCommandEnvironment >& Environment )
throw( Exception )
{
@@ -1371,7 +1208,7 @@ void ODocumentDefinition::onCommandInsert( const ::rtl::OUString& _sURL, const R
// Check, if all required properties were set.
if ( !_sURL.getLength() || m_xEmbeddedObject.is() )
{
- OSL_ENSURE( sal_False, "Content::onCommandInsert - property value missing!" );
+ OSL_FAIL( "Content::onCommandInsert - property value missing!" );
Sequence< rtl::OUString > aProps( 1 );
aProps[ 0 ] = PROPERTY_URL;
@@ -1384,7 +1221,6 @@ void ODocumentDefinition::onCommandInsert( const ::rtl::OUString& _sURL, const R
// Unreachable
}
-
if ( !m_xEmbeddedObject.is() )
{
Reference< XStorage> xStorage = getContainerStorage();
@@ -1402,7 +1238,7 @@ void ODocumentDefinition::onCommandInsert( const ::rtl::OUString& _sURL, const R
,aEmpty),UNO_QUERY);
lcl_resetFormsToEmptyDataSource( m_xEmbeddedObject );
- // #i57669# / 2005-12-01 / frank.schoenheit@sun.com
+ // #i57669#
Reference<XEmbedPersist> xPersist(m_xEmbeddedObject,UNO_QUERY);
if ( xPersist.is() )
@@ -1415,7 +1251,7 @@ void ODocumentDefinition::onCommandInsert( const ::rtl::OUString& _sURL, const R
if ( xCloseable.is() )
xCloseable->close(sal_True);
}
- catch(Exception)
+ catch(const Exception&)
{
}
m_xEmbeddedObject = NULL;
@@ -1423,13 +1259,9 @@ void ODocumentDefinition::onCommandInsert( const ::rtl::OUString& _sURL, const R
}
}
-// @@@
-// storeData();
-
aGuard.clear();
-// inserted();
}
-// -----------------------------------------------------------------------------
+
sal_Bool ODocumentDefinition::save(sal_Bool _bApprove)
{
// default handling: instantiate an interaction handler and let it handle the parameter request
@@ -1439,7 +1271,7 @@ sal_Bool ODocumentDefinition::save(sal_Bool _bApprove)
{
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ ::SolarMutexGuard aSolarGuard;
// the request
Reference<XNameAccess> xName(m_xParentContainer,UNO_QUERY);
@@ -1511,13 +1343,13 @@ sal_Bool ODocumentDefinition::save(sal_Bool _bApprove)
notifyDataSourceModified();
}
}
- catch(Exception&)
+ catch(const Exception&)
{
- OSL_ENSURE(0,"ODocumentDefinition::save: caught an Exception (tried to let the InteractionHandler handle it)!");
+ OSL_FAIL("ODocumentDefinition::save: caught an Exception (tried to let the InteractionHandler handle it)!");
}
return sal_True;
}
-// -----------------------------------------------------------------------------
+
sal_Bool ODocumentDefinition::saveAs()
{
// default handling: instantiate an interaction handler and let it handle the parameter request
@@ -1535,7 +1367,7 @@ sal_Bool ODocumentDefinition::saveAs()
try
{
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ ::SolarMutexGuard aSolarGuard;
// the request
Reference<XNameAccess> xName(m_xParentContainer,UNO_QUERY);
@@ -1575,7 +1407,7 @@ sal_Bool ODocumentDefinition::saveAs()
{
Reference< XStorage> xStorage = getContainerStorage();
const static ::rtl::OUString sBaseName(RTL_CONSTASCII_USTRINGPARAM("Obj"));
- // -----------------------------------------------------------------------------
+
Reference<XNameAccess> xElements(xStorage,UNO_QUERY_THROW);
::rtl::OUString sPersistentName = ::dbtools::createUniqueName(xElements,sBaseName);
xStorage->copyElementTo(m_pImpl->m_aProps.sPersistentName,xStorage,sPersistentName);
@@ -1604,7 +1436,7 @@ sal_Bool ODocumentDefinition::saveAs()
Reference< XNameContainer > xNameContainer( m_xParentContainer, UNO_QUERY_THROW );
xNameContainer->insertByName( sOldName, makeAny( xComponent ) );
}
- catch(Exception&)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -1619,11 +1451,10 @@ sal_Bool ODocumentDefinition::saveAs()
}
}
-
}
- catch(Exception&)
+ catch(const Exception&)
{
- OSL_ENSURE(0,"ODocumentDefinition::save: caught an Exception (tried to let the InteractionHandler handle it)!");
+ OSL_FAIL("ODocumentDefinition::save: caught an Exception (tried to let the InteractionHandler handle it)!");
}
return sal_True;
}
@@ -1655,7 +1486,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
namespace
{
Reference< XFrame > lcl_getDatabaseDocumentFrame( ODatabaseModelImpl& _rImpl )
@@ -1674,26 +1504,23 @@ namespace
}
}
-// -----------------------------------------------------------------------------
sal_Bool ODocumentDefinition::objectSupportsEmbeddedScripts() const
{
bool bAllowDocumentMacros = !m_pImpl->m_pDataSource
|| ( m_pImpl->m_pDataSource->determineEmbeddedMacros() == ODatabaseModelImpl::eSubDocumentMacros );
- // if *any* of the objects of the database document already has macros, we continue to allow it
- // to have them, until the user did a migration.
- // If there are no macros, yet, we don't allow to create them
+ // if *any* of the objects of the database document already has macros, we
+ // continue to allow it to have them, until the user does a migration.
+ // If there are no macros, we don't allow them to be created.
return bAllowDocumentMacros;
}
-// -----------------------------------------------------------------------------
::rtl::OUString ODocumentDefinition::determineContentType() const
{
return lcl_determineContentType_nothrow( getContainerStorage(), m_pImpl->m_aProps.sPersistentName );
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::separateOpenCommandArguments( const Sequence< PropertyValue >& i_rOpenCommandArguments,
::comphelper::NamedValueCollection& o_rDocumentLoadArgs, ::comphelper::NamedValueCollection& o_rEmbeddedObjectDescriptor )
{
@@ -1703,7 +1530,7 @@ void ODocumentDefinition::separateOpenCommandArguments( const Sequence< Property
{
"RecoveryStorage"
};
- for ( size_t i=0; i < sizeof( pObjectDescriptorArgs ) / sizeof( pObjectDescriptorArgs[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( pObjectDescriptorArgs ); ++i )
{
if ( aOpenCommandArguments.has( pObjectDescriptorArgs[i] ) )
{
@@ -1715,7 +1542,6 @@ void ODocumentDefinition::separateOpenCommandArguments( const Sequence< Property
o_rDocumentLoadArgs.merge( aOpenCommandArguments, false );
}
-// -----------------------------------------------------------------------------
Sequence< PropertyValue > ODocumentDefinition::fillLoadArgs( const Reference< XConnection>& _xConnection, const bool _bSuppressMacros, const bool _bReadOnly,
const Sequence< PropertyValue >& i_rOpenCommandArguments, Sequence< PropertyValue >& _out_rEmbeddedObjectDescriptor )
{
@@ -1799,7 +1625,7 @@ Sequence< PropertyValue > ODocumentDefinition::fillLoadArgs( const Reference< XC
return aMediaDesc.getPropertyValues();
}
-// -----------------------------------------------------------------------------
+
void ODocumentDefinition::loadEmbeddedObject( const Reference< XConnection >& i_rConnection, const Sequence< sal_Int8 >& _aClassID,
const Sequence< PropertyValue >& i_rOpenCommandArguments, const bool _bSuppressMacros, const bool _bReadOnly )
{
@@ -1825,7 +1651,7 @@ void ODocumentDefinition::loadEmbeddedObject( const Reference< XConnection >& i_
sDocumentService = GetDocumentServiceFromMediaType( getContentType(), m_aContext, aClassID );
// check if we are not a form and
// the com.sun.star.report.pentaho.SOReportJobFactory is not present.
- if ( !m_bForm && !sDocumentService.equalsAscii("com.sun.star.text.TextDocument"))
+ if ( !m_bForm && !sDocumentService.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextDocument")))
{
// we seem to be a "new style" report, check if report extension is present.
Reference< XContentEnumerationAccess > xEnumAccess( m_aContext.getLegacyServiceFactory(), UNO_QUERY );
@@ -1931,8 +1757,7 @@ void ODocumentDefinition::loadEmbeddedObject( const Reference< XConnection >& i_
lcl_putLoadArgs( aExistentMediaDesc, optional_bool(), optional_bool() );
// don't put _bSuppressMacros and _bReadOnly here - if the document was already
// loaded, we should not tamper with its settings.
- // #i88977# / 2008-05-05 / frank.schoenheit@sun.com
- // #i86872# / 2008-03-13 / frank.schoenheit@sun.com
+ // #i88977# #i86872#
xModel->attachResource( xModel->getURL(), aExistentMediaDesc.getPropertyValues() );
}
@@ -1944,7 +1769,7 @@ void ODocumentDefinition::loadEmbeddedObject( const Reference< XConnection >& i_
}
// set the OfficeDatabaseDocument instance as parent of the embedded document
- // #i40358# / 2005-01-19 / frank.schoenheit@sun.com
+ // #i40358#
Reference< XChild > xDepdendDocAsChild( getComponent(), UNO_QUERY );
if ( xDepdendDocAsChild.is() )
{
@@ -1965,7 +1790,6 @@ void ODocumentDefinition::loadEmbeddedObject( const Reference< XConnection >& i_
m_xLastKnownConnection = i_rConnection;
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::onCommandPreview(Any& _rImage)
{
loadEmbeddedObjectForPreview();
@@ -1984,17 +1808,17 @@ void ODocumentDefinition::onCommandPreview(Any& _rImage)
_rImage = xTransfer->getTransferData( aFlavor );
}
}
- catch( Exception )
+ catch( const Exception& )
{
}
}
}
-// -----------------------------------------------------------------------------
+
void ODocumentDefinition::getPropertyDefaultByHandle( sal_Int32 /*_nHandle*/, Any& _rDefault ) const
{
_rDefault.clear();
}
-// -----------------------------------------------------------------------------
+
void ODocumentDefinition::onCommandGetDocumentProperties( Any& _rProps )
{
loadEmbeddedObjectForPreview();
@@ -2013,7 +1837,7 @@ void ODocumentDefinition::onCommandGetDocumentProperties( Any& _rProps )
}
}
}
-// -----------------------------------------------------------------------------
+
Reference< util::XCloseable > ODocumentDefinition::impl_getComponent_throw( const bool i_ForceCreate )
{
OSL_ENSURE(m_xEmbeddedObject.is(),"Illegal call for embeddedObject");
@@ -2041,14 +1865,12 @@ Reference< util::XCloseable > ODocumentDefinition::impl_getComponent_throw( cons
return xComp;
}
-// -----------------------------------------------------------------------------
Reference< util::XCloseable > ODocumentDefinition::getComponent() throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
return impl_getComponent_throw( true );
}
-// -----------------------------------------------------------------------------
namespace
{
Reference< XDatabaseDocumentUI > lcl_getDatabaseDocumentUI( ODatabaseModelImpl& _rModelImpl )
@@ -2062,7 +1884,6 @@ namespace
}
}
-// -----------------------------------------------------------------------------
Reference< XComponent > ODocumentDefinition::impl_openUI_nolck_throw( bool _bForEditing )
{
::osl::ClearableMutexGuard aGuard( m_aMutex );
@@ -2090,7 +1911,7 @@ Reference< XComponent > ODocumentDefinition::impl_openUI_nolck_throw( bool _bFor
nObjectType, sName, _bForEditing
);
}
- catch( RuntimeException& ) { throw; }
+ catch( const RuntimeException& ) { throw; }
catch( const Exception& )
{
throw WrappedTargetException(
@@ -2099,7 +1920,6 @@ Reference< XComponent > ODocumentDefinition::impl_openUI_nolck_throw( bool _bFor
return xComponent;
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::impl_store_throw()
{
Reference<XEmbedPersist> xPersist( m_xEmbeddedObject, UNO_QUERY );
@@ -2110,7 +1930,6 @@ void ODocumentDefinition::impl_store_throw()
}
}
-// -----------------------------------------------------------------------------
bool ODocumentDefinition::impl_close_throw()
{
bool bSuccess = prepareClose();
@@ -2122,19 +1941,16 @@ bool ODocumentDefinition::impl_close_throw()
return bSuccess;
}
-// -----------------------------------------------------------------------------
Reference< XComponent > SAL_CALL ODocumentDefinition::open( ) throw (WrappedTargetException, RuntimeException)
{
return impl_openUI_nolck_throw( false );
}
-// -----------------------------------------------------------------------------
Reference< XComponent > SAL_CALL ODocumentDefinition::openDesign( ) throw (WrappedTargetException, RuntimeException)
{
return impl_openUI_nolck_throw( true );
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODocumentDefinition::store( ) throw (WrappedTargetException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -2142,7 +1958,7 @@ void SAL_CALL ODocumentDefinition::store( ) throw (WrappedTargetException, Runt
{
impl_store_throw();
}
- catch( RuntimeException& ) { throw; }
+ catch( const RuntimeException& ) { throw; }
catch( const Exception& )
{
throw WrappedTargetException(
@@ -2150,7 +1966,6 @@ void SAL_CALL ODocumentDefinition::store( ) throw (WrappedTargetException, Runt
}
}
-// -----------------------------------------------------------------------------
::sal_Bool SAL_CALL ODocumentDefinition::close( ) throw (WrappedTargetException, RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
@@ -2160,7 +1975,7 @@ void SAL_CALL ODocumentDefinition::store( ) throw (WrappedTargetException, Runt
{
bSuccess = impl_close_throw();
}
- catch( RuntimeException& ) { throw; }
+ catch( const RuntimeException& ) { throw; }
catch( const Exception& )
{
throw WrappedTargetException(
@@ -2169,14 +1984,12 @@ void SAL_CALL ODocumentDefinition::store( ) throw (WrappedTargetException, Runt
return bSuccess;
}
-// -----------------------------------------------------------------------------
::rtl::OUString SAL_CALL ODocumentDefinition::getHierarchicalName() throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_aMutex );
return impl_getHierarchicalName( false );
}
-// -----------------------------------------------------------------------------
::rtl::OUString SAL_CALL ODocumentDefinition::composeHierarchicalName( const ::rtl::OUString& i_rRelativeName ) throw (IllegalArgumentException, NoSupportException, RuntimeException)
{
::rtl::OUStringBuffer aBuffer;
@@ -2186,7 +1999,6 @@ void SAL_CALL ODocumentDefinition::store( ) throw (WrappedTargetException, Runt
return aBuffer.makeStringAndClear();
}
-// -----------------------------------------------------------------------------
void SAL_CALL ODocumentDefinition::rename( const ::rtl::OUString& _rNewName ) throw (SQLException, ElementExistException, RuntimeException)
{
try
@@ -2211,14 +2023,14 @@ void SAL_CALL ODocumentDefinition::rename( const ::rtl::OUString& _rNewName ) th
throw ElementExistException(_rNewName,*this);
}
}
-// -----------------------------------------------------------------------------
+
Reference< XStorage> ODocumentDefinition::getContainerStorage() const
{
return m_pImpl->m_pDataSource
? m_pImpl->m_pDataSource->getStorage( m_bForm ? ODatabaseModelImpl::E_FORM : ODatabaseModelImpl::E_REPORT )
: Reference< XStorage>();
}
-// -----------------------------------------------------------------------------
+
sal_Bool ODocumentDefinition::isModified()
{
osl::ClearableGuard< osl::Mutex > aGuard(m_aMutex);
@@ -2230,7 +2042,7 @@ sal_Bool ODocumentDefinition::isModified()
}
return bRet;
}
-// -----------------------------------------------------------------------------
+
bool ODocumentDefinition::prepareClose()
{
if ( !m_xEmbeddedObject.is() )
@@ -2241,7 +2053,7 @@ bool ODocumentDefinition::prepareClose()
// suspend the controller. Embedded objects are not allowed to raise
// own UI at their own discretion, instead, this has always to be triggered
// by the embedding component. Thus, we do the suspend call here.
- // #i49370# / 2005-06-09 / frank.schoenheit@sun.com
+ // #i49370#
Reference< util::XCloseable > xComponent( impl_getComponent_throw( false ) );
if ( !xComponent.is() )
@@ -2288,7 +2100,7 @@ bool ODocumentDefinition::prepareClose()
return true;
}
-// -----------------------------------------------------------------------------
+
void ODocumentDefinition::fillReportData( const ::comphelper::ComponentContext& _rContext,
const Reference< util::XCloseable >& _rxComponent,
const Reference< XConnection >& _rxActiveConnection )
@@ -2313,7 +2125,7 @@ void ODocumentDefinition::fillReportData( const ::comphelper::ComponentContext&
DBG_UNHANDLED_EXCEPTION();
}
}
-// -----------------------------------------------------------------------------
+
void ODocumentDefinition::updateDocumentTitle()
{
::rtl::OUString sName = m_pImpl->m_aProps.aTitle;
@@ -2338,7 +2150,7 @@ void ODocumentDefinition::updateDocumentTitle()
if ( xTitle.is() )
xTitle->setTitle(sName);
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentDefinition::queryClosing( const lang::EventObject& Source, ::sal_Bool GetsOwnership ) throw (util::CloseVetoException, uno::RuntimeException)
{
(void) Source;
@@ -2353,16 +2165,15 @@ void SAL_CALL ODocumentDefinition::queryClosing( const lang::EventObject& Source
throw util::CloseVetoException();
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentDefinition::notifyClosing( const lang::EventObject& /*Source*/ ) throw (uno::RuntimeException)
{
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL ODocumentDefinition::disposing( const lang::EventObject& /*Source*/ ) throw (uno::RuntimeException)
{
}
-// -----------------------------------------------------------------------------
void ODocumentDefinition::firePropertyChange( sal_Int32 i_nHandle, const Any& i_rNewValue, const Any& i_rOldValue,
sal_Bool i_bVetoable, const NotifierAccess )
{
@@ -2372,7 +2183,6 @@ void ODocumentDefinition::firePropertyChange( sal_Int32 i_nHandle, const Any& i_
// =============================================================================
// NameChangeNotifier
// =============================================================================
-// -----------------------------------------------------------------------------
NameChangeNotifier::NameChangeNotifier( ODocumentDefinition& i_rDocumentDefinition, const ::rtl::OUString& i_rNewName,
::osl::ResettableMutexGuard& i_rClearForNotify )
:m_rDocumentDefinition( i_rDocumentDefinition )
@@ -2383,13 +2193,11 @@ NameChangeNotifier::NameChangeNotifier( ODocumentDefinition& i_rDocumentDefiniti
impl_fireEvent_throw( sal_True );
}
-// -----------------------------------------------------------------------------
NameChangeNotifier::~NameChangeNotifier()
{
impl_fireEvent_throw( sal_False );
}
-// -----------------------------------------------------------------------------
void NameChangeNotifier::impl_fireEvent_throw( const sal_Bool i_bVetoable )
{
m_rClearForNotify.clear();
@@ -2398,7 +2206,5 @@ void NameChangeNotifier::impl_fireEvent_throw( const sal_Bool i_bVetoable )
m_rClearForNotify.reset();
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documentdefinition.hxx b/dbaccess/source/core/dataaccess/documentdefinition.hxx
index 76427ea78baf..d45b25181db1 100644
--- a/dbaccess/source/core/dataaccess/documentdefinition.hxx
+++ b/dbaccess/source/core/dataaccess/documentdefinition.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,39 +29,17 @@
#ifndef _DBA_COREDATAACCESS_DOCUMENTDEFINITION_HXX_
#define _DBA_COREDATAACCESS_DOCUMENTDEFINITION_HXX_
-#ifndef _CPPUHELPER_PROPSHLP_HXX
#include <cppuhelper/propshlp.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE4_HXX_
#include <cppuhelper/implbase4.hxx>
-#endif
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
-#ifndef COMPHELPER_PROPERTYSTATECONTAINER_HXX
#include <comphelper/propertystatecontainer.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_
#include <com/sun/star/frame/XComponentLoader.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCONTROLLER_HPP_
#include <com/sun/star/frame/XController.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XSTATECHANGELISTENER_HPP_
#include <com/sun/star/embed/XStateChangeListener.hpp>
-#endif
#include <com/sun/star/sdb/XSubDocument.hpp>
#include <com/sun/star/util/XCloseListener.hpp>
#include <com/sun/star/container/XHierarchicalName.hpp>
@@ -366,9 +345,7 @@ private:
*/
sal_Bool objectSupportsEmbeddedScripts() const;
- //-------------------------------------------------------------------------
//- commands
- //-------------------------------------------------------------------------
void onCommandGetDocumentProperties( ::com::sun::star::uno::Any& _rProps );
void onCommandInsert( const ::rtl::OUString& _sURL, const ::com::sun::star::uno::Reference< ::com::sun::star::ucb::XCommandEnvironment >& Environment ) throw( ::com::sun::star::uno::Exception );
@@ -397,14 +374,13 @@ private:
ODocumentDefinition& m_rDocumentDefinition;
const ::com::sun::star::uno::Any m_aOldValue;
const ::com::sun::star::uno::Any m_aNewValue;
- mutable ::osl::ResettableMutexGuard& m_rClearForNotify;
+ ::osl::ResettableMutexGuard& m_rClearForNotify;
void impl_fireEvent_throw( const sal_Bool i_bVetoable );
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_COREDATAACCESS_DOCUMENTDEFINITION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documenteventexecutor.cxx b/dbaccess/source/core/dataaccess/documenteventexecutor.cxx
index c25d052a396c..ab44de2c27bf 100644
--- a/dbaccess/source/core/dataaccess/documenteventexecutor.cxx
+++ b/dbaccess/source/core/dataaccess/documenteventexecutor.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -41,12 +42,10 @@
#include <cppuhelper/weakref.hxx>
#include <tools/diagnose_ex.h>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
-//........................................................................
namespace dbaccess
{
-//........................................................................
/** === begin UNO using === **/
using ::com::sun::star::uno::Reference;
@@ -89,7 +88,6 @@ namespace dbaccess
}
};
- //--------------------------------------------------------------------
namespace
{
static void lcl_dispatchScriptURL_throw( DocumentEventExecutor_Data& _rDocExecData,
@@ -103,7 +101,7 @@ namespace dbaccess
xDispProv.set( xController->getFrame(), UNO_QUERY );
if ( !xDispProv.is() )
{
- OSL_ENSURE( false, "lcl_dispatchScriptURL_throw: no controller/frame? How should I dispatch?" );
+ OSL_FAIL( "lcl_dispatchScriptURL_throw: no controller/frame? How should I dispatch?" );
return;
}
@@ -115,12 +113,12 @@ namespace dbaccess
// unfortunately, executing a script can trigger all kind of complex stuff, and unfortunately, not
// every component involved into this properly cares for thread safety. To be on the safe side,
// we lock the solar mutex here.
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
Reference< XDispatch > xDispatch( xDispProv->queryDispatch( aScriptURL, ::rtl::OUString(), 0 ) );
if ( !xDispatch.is() )
{
- OSL_ENSURE( false, "lcl_dispatchScriptURL_throw: no dispatcher for the script URL!" );
+ OSL_FAIL( "lcl_dispatchScriptURL_throw: no dispatcher for the script URL!" );
return;
}
@@ -134,7 +132,6 @@ namespace dbaccess
//====================================================================
//= DocumentEventExecutor
//====================================================================
- //--------------------------------------------------------------------
DocumentEventExecutor::DocumentEventExecutor( const ::comphelper::ComponentContext& _rContext,
const Reference< XEventsSupplier >& _rxDocument )
:m_pData( new DocumentEventExecutor_Data( _rxDocument ) )
@@ -157,18 +154,16 @@ namespace dbaccess
}
}
- //--------------------------------------------------------------------
DocumentEventExecutor::~DocumentEventExecutor()
{
}
- //--------------------------------------------------------------------
void SAL_CALL DocumentEventExecutor::documentEventOccured( const DocumentEvent& _Event ) throw (RuntimeException)
{
Reference< XEventsSupplier > xEventsSupplier( m_pData->xDocument.get(), UNO_QUERY );
if ( !xEventsSupplier.is() )
{
- OSL_ENSURE( false, "DocumentEventExecutor::documentEventOccured: no document anymore, but still being notified?" );
+ OSL_FAIL( "DocumentEventExecutor::documentEventOccurred: no document anymore, but still being notified?" );
return;
}
@@ -181,13 +176,12 @@ namespace dbaccess
{
// this is worth an assertion: We are listener at the very same document which we just asked
// for its events. So when EventName is fired, why isn't it supported by xDocEvents?
- OSL_ENSURE( false, "DocumentEventExecutor::documentEventOccured: an unsupported event is notified!" );
+ OSL_FAIL( "DocumentEventExecutor::documentEventOccurred: an unsupported event is notified!" );
return;
}
const ::comphelper::NamedValueCollection aScriptDescriptor( xDocEvents->getByName( _Event.EventName ) );
-
::rtl::OUString sEventType;
bool bScriptAssigned = aScriptDescriptor.get_ensureType( "EventType", sEventType );
@@ -205,7 +199,7 @@ namespace dbaccess
bool bNonEmptyScript = sScript.getLength() != 0;
OSL_ENSURE( bDispatchScriptURL && bNonEmptyScript,
- "DocumentEventExecutor::documentEventOccured: invalid/unsupported script descriptor" );
+ "DocumentEventExecutor::documentEventOccurred: invalid/unsupported script descriptor" );
if ( bDispatchScriptURL && bNonEmptyScript )
{
@@ -219,13 +213,10 @@ namespace dbaccess
}
}
- //--------------------------------------------------------------------
void SAL_CALL DocumentEventExecutor::disposing( const lang::EventObject& /*_Source*/ ) throw (RuntimeException)
{
// not interested in
}
-
-//........................................................................
} // namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documenteventexecutor.hxx b/dbaccess/source/core/dataaccess/documenteventexecutor.hxx
index 5705c5304bd7..c83a3e2886fd 100644
--- a/dbaccess/source/core/dataaccess/documenteventexecutor.hxx
+++ b/dbaccess/source/core/dataaccess/documenteventexecutor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -41,10 +42,8 @@ namespace comphelper
class ComponentContext;
}
-//........................................................................
namespace dbaccess
{
-//........................................................................
struct DocumentEventExecutor_Data;
//====================================================================
@@ -71,8 +70,8 @@ namespace dbaccess
::std::auto_ptr< DocumentEventExecutor_Data > m_pData;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_DOCUMENTEVENTEXECUTOR_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documenteventnotifier.cxx b/dbaccess/source/core/dataaccess/documenteventnotifier.cxx
index cfbf96433971..ee33fd145dff 100644
--- a/dbaccess/source/core/dataaccess/documenteventnotifier.cxx
+++ b/dbaccess/source/core/dataaccess/documenteventnotifier.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -38,10 +39,8 @@
#include <cppuhelper/weak.hxx>
#include <tools/diagnose_ex.h>
-//........................................................................
namespace dbaccess
{
-//........................................................................
/** === begin UNO using === **/
using ::com::sun::star::uno::Reference;
@@ -148,20 +147,17 @@ namespace dbaccess
void impl_notifyEventAsync_nothrow( const DocumentEvent& _rEvent );
};
- //--------------------------------------------------------------------
void SAL_CALL DocumentEventNotifier_Impl::acquire()
{
osl_incrementInterlockedCount( &m_refCount );
}
- //--------------------------------------------------------------------
void SAL_CALL DocumentEventNotifier_Impl::release()
{
if ( 0 == osl_decrementInterlockedCount( &m_refCount ) )
delete this;
}
- //--------------------------------------------------------------------
void DocumentEventNotifier_Impl::disposing()
{
// SYNCHRONIZED ->
@@ -187,7 +183,6 @@ namespace dbaccess
// <-- SYNCHRONIZED
}
- //--------------------------------------------------------------------
void DocumentEventNotifier_Impl::onDocumentInitialized()
{
if ( m_bInitialized )
@@ -199,7 +194,6 @@ namespace dbaccess
m_pEventBroadcaster->create();
}
- //--------------------------------------------------------------------
void DocumentEventNotifier_Impl::impl_notifyEvent_nothrow( const DocumentEvent& _rEvent )
{
OSL_PRECOND( m_bInitialized,
@@ -223,7 +217,6 @@ namespace dbaccess
}
}
- //--------------------------------------------------------------------
void DocumentEventNotifier_Impl::impl_notifyEventAsync_nothrow( const DocumentEvent& _rEvent )
{
if ( !m_pEventBroadcaster.is() )
@@ -237,7 +230,6 @@ namespace dbaccess
m_pEventBroadcaster->addEvent( new DocumentEventHolder( _rEvent ), this );
}
- // -----------------------------------------------------------------------------
void DocumentEventNotifier_Impl::processEvent( const ::comphelper::AnyEvent& _rEvent )
{
// beware, this is called from the notification thread
@@ -253,67 +245,56 @@ namespace dbaccess
//====================================================================
//= DocumentEventNotifier
//====================================================================
- //--------------------------------------------------------------------
DocumentEventNotifier::DocumentEventNotifier( ::cppu::OWeakObject& _rBroadcasterDocument, ::osl::Mutex& _rMutex )
:m_pImpl( new DocumentEventNotifier_Impl( _rBroadcasterDocument, _rMutex ) )
{
}
- //--------------------------------------------------------------------
DocumentEventNotifier::~DocumentEventNotifier()
{
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::disposing()
{
m_pImpl->disposing();
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::onDocumentInitialized()
{
m_pImpl->onDocumentInitialized();
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::addLegacyEventListener( const Reference< document::XEventListener >& _Listener )
{
m_pImpl->addLegacyEventListener( _Listener );
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::removeLegacyEventListener( const Reference< document::XEventListener >& _Listener )
{
m_pImpl->removeLegacyEventListener( _Listener );
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::addDocumentEventListener( const Reference< XDocumentEventListener >& _Listener )
{
m_pImpl->addDocumentEventListener( _Listener );
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::removeDocumentEventListener( const Reference< XDocumentEventListener >& _Listener )
{
m_pImpl->removeDocumentEventListener( _Listener );
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::notifyDocumentEvent( const ::rtl::OUString& _EventName,
const Reference< XController2 >& _ViewController, const Any& _Supplement )
{
m_pImpl->notifyDocumentEvent( _EventName, _ViewController, _Supplement );
}
- //--------------------------------------------------------------------
void DocumentEventNotifier::notifyDocumentEventAsync( const ::rtl::OUString& _EventName,
const Reference< XController2 >& _ViewController, const Any& _Supplement )
{
m_pImpl->notifyDocumentEventAsync( _EventName, _ViewController, _Supplement );
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documenteventnotifier.hxx b/dbaccess/source/core/dataaccess/documenteventnotifier.hxx
index 870f5decf984..c92064aabbc7 100644
--- a/dbaccess/source/core/dataaccess/documenteventnotifier.hxx
+++ b/dbaccess/source/core/dataaccess/documenteventnotifier.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,10 +41,8 @@ namespace cppu
class OWeakObject;
}
-//........................................................................
namespace dbaccess
{
-//........................................................................
class DocumentEventNotifier_Impl;
//====================================================================
@@ -137,8 +136,8 @@ namespace dbaccess
::rtl::Reference< DocumentEventNotifier_Impl > m_pImpl;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_DOCUMENTEVENTNOTIFIER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documentevents.cxx b/dbaccess/source/core/dataaccess/documentevents.cxx
index 8d191c1d3503..e24c2bf59113 100644
--- a/dbaccess/source/core/dataaccess/documentevents.cxx
+++ b/dbaccess/source/core/dataaccess/documentevents.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -37,11 +38,10 @@
#include <algorithm>
#include <functional>
+#include <o3tl/compat_functional.hxx>
-//........................................................................
namespace dbaccess
{
-//........................................................................
/** === begin UNO using === **/
using ::com::sun::star::uno::Reference;
@@ -87,7 +87,6 @@ namespace dbaccess
bool bNeedsSyncNotify;
};
- //--------------------------------------------------------------------
namespace
{
static const DocumentEventData* lcl_getDocumentEventData()
@@ -126,7 +125,6 @@ namespace dbaccess
//====================================================================
//= DocumentEvents
//====================================================================
- //--------------------------------------------------------------------
DocumentEvents::DocumentEvents( ::cppu::OWeakObject& _rParent, ::osl::Mutex& _rMutex, DocumentEventsData& _rEventsData )
:m_pData( new DocumentEvents_Data( _rParent, _rMutex, _rEventsData ) )
{
@@ -141,24 +139,20 @@ namespace dbaccess
}
}
- //--------------------------------------------------------------------
DocumentEvents::~DocumentEvents()
{
}
- //--------------------------------------------------------------------
void SAL_CALL DocumentEvents::acquire() throw()
{
m_pData->rParent.acquire();
}
- //--------------------------------------------------------------------
void SAL_CALL DocumentEvents::release() throw()
{
m_pData->rParent.release();
}
- //--------------------------------------------------------------------
bool DocumentEvents::needsSynchronousNotification( const ::rtl::OUString& _rEventName )
{
const DocumentEventData* pEventData = lcl_getDocumentEventData();
@@ -173,7 +167,6 @@ namespace dbaccess
return false;
}
- //--------------------------------------------------------------------
void SAL_CALL DocumentEvents::replaceByName( const ::rtl::OUString& _Name, const Any& _Element ) throw (IllegalArgumentException, NoSuchElementException, WrappedTargetException, RuntimeException)
{
::osl::MutexGuard aGuard( m_pData->rMutex );
@@ -207,7 +200,6 @@ namespace dbaccess
elementPos->second = aEventDescriptor;
}
- //--------------------------------------------------------------------
Any SAL_CALL DocumentEvents::getByName( const ::rtl::OUString& _Name ) throw (NoSuchElementException, WrappedTargetException, RuntimeException)
{
::osl::MutexGuard aGuard( m_pData->rMutex );
@@ -223,7 +215,6 @@ namespace dbaccess
return aReturn;
}
- //--------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL DocumentEvents::getElementNames( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_pData->rMutex );
@@ -233,12 +224,11 @@ namespace dbaccess
m_pData->rEventsData.begin(),
m_pData->rEventsData.end(),
aNames.getArray(),
- ::std::select1st< DocumentEventsData::value_type >()
+ ::o3tl::select1st< DocumentEventsData::value_type >()
);
return aNames;
}
- //--------------------------------------------------------------------
::sal_Bool SAL_CALL DocumentEvents::hasByName( const ::rtl::OUString& _Name ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_pData->rMutex );
@@ -246,20 +236,16 @@ namespace dbaccess
return m_pData->rEventsData.find( _Name ) != m_pData->rEventsData.end();
}
- //--------------------------------------------------------------------
Type SAL_CALL DocumentEvents::getElementType( ) throw (RuntimeException)
{
return ::cppu::UnoType< Sequence< PropertyValue > >::get();
}
- //--------------------------------------------------------------------
::sal_Bool SAL_CALL DocumentEvents::hasElements( ) throw (RuntimeException)
{
::osl::MutexGuard aGuard( m_pData->rMutex );
return !m_pData->rEventsData.empty();
}
-
-//........................................................................
} // namespace dbaccess
-//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/documentevents.hxx b/dbaccess/source/core/dataaccess/documentevents.hxx
index 6d761027e0ca..16cb0c86875e 100644
--- a/dbaccess/source/core/dataaccess/documentevents.hxx
+++ b/dbaccess/source/core/dataaccess/documentevents.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -38,10 +39,8 @@
#include <map>
#include <boost/noncopyable.hpp>
-//........................................................................
namespace dbaccess
{
-//........................................................................
typedef ::std::map< ::rtl::OUString, ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > >
DocumentEventsData;
@@ -83,8 +82,8 @@ namespace dbaccess
::std::auto_ptr< DocumentEvents_Data > m_pData;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_DOCUMENTEVENTS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/intercept.cxx b/dbaccess/source/core/dataaccess/intercept.cxx
index 8a24bbcdf4a3..31317422288a 100644
--- a/dbaccess/source/core/dataaccess/intercept.cxx
+++ b/dbaccess/source/core/dataaccess/intercept.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -159,7 +160,7 @@ void SAL_CALL OInterceptor::dispatch( const URL& _URL,const Sequence<PropertyVal
while( nInd < aNewArgs.getLength() )
{
- if ( aNewArgs[nInd].Name.equalsAscii( "SaveTo" ) )
+ if ( aNewArgs[nInd].Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "SaveTo" ) ) )
{
aNewArgs[nInd].Value <<= sal_True;
break;
@@ -170,12 +171,12 @@ void SAL_CALL OInterceptor::dispatch( const URL& _URL,const Sequence<PropertyVal
if ( nInd == aNewArgs.getLength() )
{
aNewArgs.realloc( nInd + 1 );
- aNewArgs[nInd].Name = ::rtl::OUString::createFromAscii( "SaveTo" );
+ aNewArgs[nInd].Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SaveTo"));
aNewArgs[nInd].Value <<= sal_True;
}
Reference< XDispatch > xDispatch = m_xSlaveDispatchProvider->queryDispatch(
- _URL, ::rtl::OUString::createFromAscii( "_self" ), 0 );
+ _URL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")), 0 );
if ( xDispatch.is() )
xDispatch->dispatch( _URL, aNewArgs );
}
@@ -203,7 +204,7 @@ IMPL_LINK( OInterceptor, OnDispatch, void*, _pDispatcher )
if ( m_pContentHolder && m_pContentHolder->prepareClose() && m_xSlaveDispatchProvider.is() )
{
Reference< XDispatch > xDispatch = m_xSlaveDispatchProvider->queryDispatch(
- pHelper->aURL, ::rtl::OUString::createFromAscii( "_self" ), 0 );
+ pHelper->aURL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_self")), 0 );
if ( xDispatch.is() )
{
Reference< ::com::sun::star::document::XEventBroadcaster> xEvtB(m_pContentHolder->getComponent(),UNO_QUERY);
@@ -416,7 +417,7 @@ void SAL_CALL OInterceptor::setMasterDispatchProvider(
osl::MutexGuard aGuard(m_aMutex);
m_xMasterDispatchProvider = NewSupplier;
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OInterceptor::notifyEvent( const ::com::sun::star::document::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException)
{
osl::ResettableMutexGuard _rGuard(m_aMutex);
@@ -436,12 +437,10 @@ void SAL_CALL OInterceptor::notifyEvent( const ::com::sun::star::document::Event
}
}
}
-// -----------------------------------------------------------------------------
+
void SAL_CALL OInterceptor::disposing( const ::com::sun::star::lang::EventObject& /*Source*/ ) throw (::com::sun::star::uno::RuntimeException)
{
}
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/intercept.hxx b/dbaccess/source/core/dataaccess/intercept.hxx
index 9c69ee0d59d7..d1d4ffc27dd3 100644
--- a/dbaccess/source/core/dataaccess/intercept.hxx
+++ b/dbaccess/source/core/dataaccess/intercept.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,30 +29,14 @@
#ifndef DBA_INTERCEPT_HXX
#define DBA_INTERCEPT_HXX
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE4_HXX_
#include <cppuhelper/implbase4.hxx>
-#endif
-#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_
#include <cppuhelper/interfacecontainer.hxx>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCHPROVIDERINTERCEPTOR_HPP_
#include <com/sun/star/frame/XDispatchProviderInterceptor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XINTERCEPTORINFO_HPP_
#include <com/sun/star/frame/XInterceptorInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XEVENTLISTENER_HPP_
#include <com/sun/star/document/XEventListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCH_HPP_
#include <com/sun/star/frame/XDispatch.hpp>
-#endif
-#ifndef _DBA_COREDATAACCESS_DOCUMENTDEFINITION_HXX_
#include "documentdefinition.hxx"
-#endif
#include <vcl/svapp.hxx>
namespace dbaccess
@@ -126,7 +111,6 @@ public:
::com::sun::star::uno::RuntimeException
);
-
//XDispatchProviderInterceptor
virtual ::com::sun::star::uno::Reference<
::com::sun::star::frame::XDispatchProvider > SAL_CALL
@@ -162,7 +146,6 @@ public:
virtual void SAL_CALL notifyEvent( const ::com::sun::star::document::EventObject& Event ) throw (::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL disposing( const ::com::sun::star::lang::EventObject& Source ) throw (::com::sun::star::uno::RuntimeException);
-
private:
osl::Mutex m_aMutex;
@@ -179,12 +162,8 @@ private:
sal_Bool m_bAllowEditDoc;
};
-
-//........................................................................
} // namespace dbaccess
-//........................................................................
-
#endif //DBA_INTERCEPT_HXX
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/makefile.mk b/dbaccess/source/core/dataaccess/makefile.mk
deleted file mode 100644
index 831eae349858..000000000000
--- a/dbaccess/source/core/dataaccess/makefile.mk
+++ /dev/null
@@ -1,69 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=dataaccess
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/dba.pmk
-
-# --- Files -------------------------------------
-
-SLOFILES= \
- $(SLO)$/SharedConnection.obj \
- $(SLO)$/ContentHelper.obj \
- $(SLO)$/bookmarkcontainer.obj \
- $(SLO)$/definitioncontainer.obj \
- $(SLO)$/commanddefinition.obj \
- $(SLO)$/documentcontainer.obj \
- $(SLO)$/commandcontainer.obj \
- $(SLO)$/documentdefinition.obj \
- $(SLO)$/ComponentDefinition.obj \
- $(SLO)$/databasecontext.obj \
- $(SLO)$/connection.obj \
- $(SLO)$/datasource.obj \
- $(SLO)$/databaseregistrations.obj \
- $(SLO)$/intercept.obj \
- $(SLO)$/myucp_datasupplier.obj \
- $(SLO)$/myucp_resultset.obj \
- $(SLO)$/databasedocument.obj \
- $(SLO)$/dataaccessdescriptor.obj\
- $(SLO)$/ModelImpl.obj \
- $(SLO)$/documentevents.obj \
- $(SLO)$/documenteventexecutor.obj \
- $(SLO)$/documenteventnotifier.obj \
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx b/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx
index 725c7c01e17a..afb2040874b6 100644
--- a/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx
+++ b/dbaccess/source/core/dataaccess/myucp_datasupplier.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,25 +37,13 @@
#include <vector>
-#ifndef _UCBHELPER_CONTENTIDENTIFIER_HXX
#include <ucbhelper/contentidentifier.hxx>
-#endif
-#ifndef _UCBHELPER_PROVIDERHELPER_HXX
#include <ucbhelper/providerhelper.hxx>
-#endif
-#ifndef DBA_DATASUPPLIER_HXX
#include "myucp_datasupplier.hxx"
-#endif
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMEACCESS_HPP_
#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::ucb;
@@ -130,19 +119,17 @@ DataSupplier_Impl::~DataSupplier_Impl()
while ( it != end )
{
delete (*it);
- it++;
+ ++it;
}
}
}
//=========================================================================
-//=========================================================================
//
// DataSupplier Implementation.
//
//=========================================================================
-//=========================================================================
DBG_NAME(DataSupplier)
DataSupplier::DataSupplier( const Reference< XMultiServiceFactory >& rxSMgr,
@@ -154,16 +141,12 @@ DataSupplier::DataSupplier( const Reference< XMultiServiceFactory >& rxSMgr,
}
-//=========================================================================
-// virtual
DataSupplier::~DataSupplier()
{
DBG_DTOR(DataSupplier,NULL);
}
-//=========================================================================
-// virtual
rtl::OUString DataSupplier::queryContentIdentifierString( sal_uInt32 nIndex )
{
osl::Guard< osl::Mutex > aGuard( m_pImpl->m_aMutex );
@@ -194,8 +177,6 @@ rtl::OUString DataSupplier::queryContentIdentifierString( sal_uInt32 nIndex )
return rtl::OUString();
}
-//=========================================================================
-// virtual
Reference< XContentIdentifier >
DataSupplier::queryContentIdentifier( sal_uInt32 nIndex )
{
@@ -221,8 +202,6 @@ DataSupplier::queryContentIdentifier( sal_uInt32 nIndex )
return Reference< XContentIdentifier >();
}
-//=========================================================================
-// virtual
Reference< XContent >
DataSupplier::queryContent( sal_uInt32 _nIndex )
{
@@ -261,8 +240,6 @@ DataSupplier::queryContent( sal_uInt32 _nIndex )
return Reference< XContent >();
}
-//=========================================================================
-// virtual
sal_Bool DataSupplier::getResult( sal_uInt32 nIndex )
{
osl::ClearableGuard< osl::Mutex > aGuard( m_pImpl->m_aMutex );
@@ -324,8 +301,6 @@ sal_Bool DataSupplier::getResult( sal_uInt32 nIndex )
return bFound;
}
-//=========================================================================
-// virtual
sal_uInt32 DataSupplier::totalCount()
{
osl::ClearableGuard< osl::Mutex > aGuard( m_pImpl->m_aMutex );
@@ -361,22 +336,16 @@ sal_uInt32 DataSupplier::totalCount()
return m_pImpl->m_aResults.size();
}
-//=========================================================================
-// virtual
sal_uInt32 DataSupplier::currentCount()
{
return m_pImpl->m_aResults.size();
}
-//=========================================================================
-// virtual
sal_Bool DataSupplier::isCountFinal()
{
return m_pImpl->m_bCountFinal;
}
-//=========================================================================
-// virtual
Reference< XRow >
DataSupplier::queryPropertyValues( sal_uInt32 nIndex )
{
@@ -405,8 +374,6 @@ DataSupplier::queryPropertyValues( sal_uInt32 nIndex )
return Reference< XRow >();
}
-//=========================================================================
-// virtual
void DataSupplier::releasePropertyValues( sal_uInt32 nIndex )
{
osl::Guard< osl::Mutex > aGuard( m_pImpl->m_aMutex );
@@ -415,16 +382,12 @@ void DataSupplier::releasePropertyValues( sal_uInt32 nIndex )
m_pImpl->m_aResults[ nIndex ]->xRow = Reference< XRow >();
}
-//=========================================================================
-// virtual
void DataSupplier::close()
{
}
-//=========================================================================
-// virtual
void DataSupplier::validate()
throw( ResultSetException )
{
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/myucp_datasupplier.hxx b/dbaccess/source/core/dataaccess/myucp_datasupplier.hxx
index 7b1e5bd814df..77dcbf2e9659 100644
--- a/dbaccess/source/core/dataaccess/myucp_datasupplier.hxx
+++ b/dbaccess/source/core/dataaccess/myucp_datasupplier.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
#ifndef DBA_DATASUPPLIER_HXX
#define DBA_DATASUPPLIER_HXX
-#ifndef _RTL_REF_HXX_
#include <rtl/ref.hxx>
-#endif
-#ifndef _UCBHELPER_RESULTSET_HXX
#include <ucbhelper/resultset.hxx>
-#endif
-#ifndef _DBA_COREDATAACCESS_DOCUMENTCONTAINER_HXX_
#include "documentcontainer.hxx"
-#endif
#include <memory>
namespace dbaccess {
@@ -81,3 +76,5 @@ public:
}
#endif // DBA_DATASUPPLIER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/myucp_resultset.cxx b/dbaccess/source/core/dataaccess/myucp_resultset.cxx
index 0543c7f35326..f2d5840f7c15 100644
--- a/dbaccess/source/core/dataaccess/myucp_resultset.cxx
+++ b/dbaccess/source/core/dataaccess/myucp_resultset.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -37,12 +38,8 @@
*************************************************************************/
-#ifndef DBA_DATASUPPLIER_HXX
#include "myucp_datasupplier.hxx"
-#endif
-#ifndef DBA_UCPRESULTSET_HXX
#include "myucp_resultset.hxx"
-#endif
using namespace ::com::sun::star::uno;
@@ -56,12 +53,10 @@ using namespace ::com::sun::star::container;
using namespace dbaccess;
//=========================================================================
-//=========================================================================
//
// DynamicResultSet Implementation.
//
//=========================================================================
-//=========================================================================
DynamicResultSet::DynamicResultSet(
const Reference< XMultiServiceFactory >& rxSMgr,
@@ -79,7 +74,6 @@ DynamicResultSet::DynamicResultSet(
// Non-interface methods.
//
//=========================================================================
-
void DynamicResultSet::initStatic()
{
m_xResultSet1
@@ -91,7 +85,6 @@ void DynamicResultSet::initStatic()
m_xEnv );
}
-//=========================================================================
void DynamicResultSet::initDynamic()
{
m_xResultSet1
@@ -103,4 +96,4 @@ void DynamicResultSet::initDynamic()
m_xEnv );
m_xResultSet2 = m_xResultSet1;
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/dataaccess/myucp_resultset.hxx b/dbaccess/source/core/dataaccess/myucp_resultset.hxx
index a81658587003..b74be38df9d6 100644
--- a/dbaccess/source/core/dataaccess/myucp_resultset.hxx
+++ b/dbaccess/source/core/dataaccess/myucp_resultset.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
#ifndef DBA_UCPRESULTSET_HXX
#define DBA_UCPRESULTSET_HXX
-#ifndef _RTL_REF_HXX_
#include <rtl/ref.hxx>
-#endif
-#ifndef _UCBHELPER_RESULTSETHELPER_HXX
#include <ucbhelper/resultsethelper.hxx>
-#endif
-#ifndef _DBA_COREDATAACCESS_DOCUMENTCONTAINER_HXX_
#include "documentcontainer.hxx"
-#endif
// @@@ Adjust namespace name.
@@ -65,3 +60,5 @@ public:
}
#endif // DBA_UCPRESULTSET_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/ContainerListener.hxx b/dbaccess/source/core/inc/ContainerListener.hxx
index 2a6b976504e5..878f13dae47b 100644
--- a/dbaccess/source/core/inc/ContainerListener.hxx
+++ b/dbaccess/source/core/inc/ContainerListener.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,14 @@
#ifndef DBA_CONTAINERLISTENER_HXX
#define DBA_CONTAINERLISTENER_HXX
-#ifndef _CPPUHELPER_IMPLBASE2_HXX_
#include <cppuhelper/implbase2.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERLISTENER_HPP_
#include <com/sun/star/container/XContainerListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERAPPROVELISTENER_HPP_
#include <com/sun/star/container/XContainerApproveListener.hpp>
-#endif
-#ifndef _CPPUHELPER_WEAK_HXX_
#include <cppuhelper/weak.hxx>
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OContainerListener
@@ -90,8 +81,9 @@ namespace dbaccess
protected:
virtual ~OContainerListener();
};
-//........................................................................
+
} // namespace dbaccess
-//........................................................................
+
#endif // DBA_CONTAINERLISTENER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/ContainerMediator.hxx b/dbaccess/source/core/inc/ContainerMediator.hxx
index f35a0bfca58b..15b754e3607e 100644
--- a/dbaccess/source/core/inc/ContainerMediator.hxx
+++ b/dbaccess/source/core/inc/ContainerMediator.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,41 +28,21 @@
#ifndef DBA_CONTAINERMEDIATOR_HXX
#define DBA_CONTAINERMEDIATOR_HXX
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERLISTENER_HPP_
#include <com/sun/star/container/XContainerListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _RTL_REF_HXX_
#include <rtl/ref.hxx>
-#endif
#include <map>
-//........................................................................
namespace dbaccess
{
-//........................................................................
class OPropertyForward;
@@ -116,8 +97,9 @@ namespace dbaccess
const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& _rxDestination
);
};
-//........................................................................
+
} // namespace dbaccess
-//........................................................................
#endif // DBA_CONTAINERMEDIATOR_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/ContentHelper.hxx b/dbaccess/source/core/inc/ContentHelper.hxx
index 10c5df0cd5f3..2d659f066b90 100644
--- a/dbaccess/source/core/inc/ContentHelper.hxx
+++ b/dbaccess/source/core/inc/ContentHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,72 +28,28 @@
#ifndef DBA_CONTENTHELPER_HXX
#define DBA_CONTENTHELPER_HXX
-#ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_
#include <com/sun/star/ucb/XContent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCOMMANDPROCESSOR_HPP_
#include <com/sun/star/ucb/XCommandProcessor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTIESCHANGENOTIFIER_HPP_
#include <com/sun/star/beans/XPropertiesChangeNotifier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYCONTAINER_HPP_
#include <com/sun/star/beans/XPropertyContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XINITIALIZATION_HPP_
#include <com/sun/star/lang/XInitialization.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XSTORAGE_HPP_
#include <com/sun/star/embed/XStorage.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_XEMBEDDEDOBJECT_HPP_
#include <com/sun/star/embed/XEmbeddedObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XUNOTUNNEL_HPP_
#include <com/sun/star/lang/XUnoTunnel.hpp>
-#endif
-#ifndef _CPPUHELPER_COMPBASE9_HXX_
#include <cppuhelper/compbase9.hxx>
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef COMPHELPER_COMPONENTCONTEXT_HXX
#include <comphelper/componentcontext.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTY_HPP_
#include <com/sun/star/beans/Property.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XRENAME_HPP_
#include <com/sun/star/sdbcx/XRename.hpp>
-#endif
-#ifndef CONNECTIVITY_SQLERROR_HXX
#include <connectivity/sqlerror.hxx>
-#endif
-#ifndef BOOST_SHARED_PTR_HPP_INCLUDED
#include <boost/shared_ptr.hpp>
-#endif
namespace dbaccess
{
@@ -243,7 +200,8 @@ namespace dbaccess
virtual ::rtl::OUString determineContentType() const = 0;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
+
#endif // DBA_CONTENTHELPER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/DatabaseDataProvider.hxx b/dbaccess/source/core/inc/DatabaseDataProvider.hxx
index 5d7a4a4e368e..eb6dba6f54b8 100644
--- a/dbaccess/source/core/inc/DatabaseDataProvider.hxx
+++ b/dbaccess/source/core/inc/DatabaseDataProvider.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -276,3 +277,5 @@ private:
} // namespace dbaccess
#endif // DBA_DATABASEDATAPROVIDER_HXX_INCLUDED
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/FilteredContainer.hxx b/dbaccess/source/core/inc/FilteredContainer.hxx
index f02c3da87d19..561ef67778f9 100644
--- a/dbaccess/source/core/inc/FilteredContainer.hxx
+++ b/dbaccess/source/core/inc/FilteredContainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -142,3 +143,5 @@ namespace dbaccess
// ..............................................................................
#endif // DBACCESS_CORE_FILTERED_CONTAINER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/PropertyForward.hxx b/dbaccess/source/core/inc/PropertyForward.hxx
index b0e5696387b4..4a685b037be0 100644
--- a/dbaccess/source/core/inc/PropertyForward.hxx
+++ b/dbaccess/source/core/inc/PropertyForward.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,31 +28,17 @@
#ifndef DBA_PROPERTYSETFORWARD_HXX
#define DBA_PROPERTYSETFORWARD_HXX
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYCHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertyChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP_
#include <com/sun/star/beans/XPropertySetInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
#include <vector>
-//........................................................................
namespace dbaccess
{
-//........................................................................
// ===================================================================
// = OPropertyForward
@@ -89,8 +76,8 @@ namespace dbaccess
inline ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > getDefinition() const { return m_xDest; }
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
+
#endif // DBA_PROPERTYSETFORWARD_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/RefreshListener.hxx b/dbaccess/source/core/inc/RefreshListener.hxx
index 2b4bdda0f5a0..80e490c4a34c 100644
--- a/dbaccess/source/core/inc/RefreshListener.hxx
+++ b/dbaccess/source/core/inc/RefreshListener.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBA_CORE_REFRESHLISTENER_HXX
#define DBA_CORE_REFRESHLISTENER_HXX
-#ifndef _COM_SUN_STAR_UNO_REFERENCE_H_
#include <com/sun/star/uno/Reference.h>
-#endif
namespace com { namespace sun { namespace star { namespace container
{
@@ -38,10 +37,8 @@ namespace com { namespace sun { namespace star { namespace container
}
}}}
-//.........................................................................
namespace dbaccess
{
-//.........................................................................
//=====================================================================
//= IRefreshListener
@@ -51,9 +48,9 @@ namespace dbaccess
public:
virtual void refresh(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _rToBeRefreshed) = 0;
};
-//.........................................................................
+
} // namespace dbaccess
-//.........................................................................
#endif // DBA_CORE_REFRESHLISTENER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/SingleSelectQueryComposer.hxx b/dbaccess/source/core/inc/SingleSelectQueryComposer.hxx
index 412fbb1c5231..305d3493d353 100644
--- a/dbaccess/source/core/inc/SingleSelectQueryComposer.hxx
+++ b/dbaccess/source/core/inc/SingleSelectQueryComposer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -156,7 +157,7 @@ namespace dbaccess
getStructuredCondition( TGetParseNode& _aGetFunctor );
::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess >
- setCurrentColumns( EColumnType _eType, const ::vos::ORef< ::connectivity::OSQLColumns >& _rCols );
+ setCurrentColumns( EColumnType _eType, const ::rtl::Reference< ::connectivity::OSQLColumns >& _rCols );
//helper methods for mem_fun_t
inline bool implSetFilter(::rtl::OUString _sFilter) { setFilter(_sFilter); return true;}
@@ -251,3 +252,5 @@ namespace dbaccess
};
}
#endif // DBACCESS_CORE_API_SINGLESELECTQUERYCOMPOSER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/TableDeco.hxx b/dbaccess/source/core/inc/TableDeco.hxx
index 8f8ec5bf9652..659f667e0544 100644
--- a/dbaccess/source/core/inc/TableDeco.hxx
+++ b/dbaccess/source/core/inc/TableDeco.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,61 +29,25 @@
#ifndef _DBA_CORE_TABLEDECORATOR_HXX_
#define _DBA_CORE_TABLEDECORATOR_HXX_
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATSSUPPLIER_HPP_
#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XINDEXESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XIndexesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XKEYSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XRENAME_HPP_
#include <com/sun/star/sdbcx/XRename.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XALTERTABLE_HPP_
#include <com/sun/star/sdbcx/XAlterTable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _CPPUHELPER_COMPBASE9_HXX_
#include <cppuhelper/compbase9.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DBA_CORE_DATASETTINGS_HXX_
#include "datasettings.hxx"
-#endif
-#ifndef _DBA_COREAPI_COLUMN_HXX_
#include "column.hxx"
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _CONNECTIVITY_SDBCX_IREFRESHABLE_HXX_
#include <connectivity/sdbcx/IRefreshable.hxx>
-#endif
-#ifndef COMPHELPER_IDPROPERTYARRAYUSAGEHELPER_HXX
#include <comphelper/IdPropArrayHelper.hxx>
-#endif
namespace dbaccess
{
@@ -218,3 +183,4 @@ namespace dbaccess
#endif // _DBA_CORE_TABLEDECORATOR_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/View.hxx b/dbaccess/source/core/inc/View.hxx
index 4e96a1882423..a2dedc5a8d57 100644
--- a/dbaccess/source/core/inc/View.hxx
+++ b/dbaccess/source/core/inc/View.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -6,9 +7,6 @@
*
* OpenOffice.org - a multi-platform office productivity suite
*
- * $RCSfile: View.hxx,v $
- * $Revision: 1.3 $
- *
* This file is part of OpenOffice.org.
*
* OpenOffice.org is free software: you can redistribute it and/or modify
@@ -41,10 +39,8 @@
#include <comphelper/uno3.hxx>
#include <cppuhelper/implbase1.hxx>
-//........................................................................
namespace dbaccess
{
-//........................................................................
//====================================================================
//= View
@@ -84,8 +80,8 @@ namespace dbaccess
using View_Base::getFastPropertyValue;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_VIEW_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/callablestatement.hxx b/dbaccess/source/core/inc/callablestatement.hxx
index 64f281e7b6aa..26230ee9c9e6 100644
--- a/dbaccess/source/core/inc/callablestatement.hxx
+++ b/dbaccess/source/core/inc/callablestatement.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef _DBA_COREAPI_CALLABLESTATEMENT_HXX_
#define _DBA_COREAPI_CALLABLESTATEMENT_HXX_
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XOUTPARAMETERS_HPP_
#include <com/sun/star/sdbc/XOutParameters.hpp>
-#endif
-#ifndef _DBA_COREAPI_PREPAREDSTATEMENT_HXX_
#include <preparedstatement.hxx>
-#endif
namespace dbaccess
{
@@ -93,3 +88,4 @@ namespace dbaccess
}
#endif // _DBA_COREAPI_CALLABLESTATEMENT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/column.hxx b/dbaccess/source/core/inc/column.hxx
index 543e999f715f..b6e533a81a35 100644
--- a/dbaccess/source/core/inc/column.hxx
+++ b/dbaccess/source/core/inc/column.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -61,7 +62,7 @@
#include <cppuhelper/propshlp.hxx>
#include <osl/diagnose.h>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
namespace dbaccess
{
@@ -73,7 +74,6 @@ namespace dbaccess
::com::sun::star::container::XNamed
> OColumnBase;
- //------------------------------------------------------------
class OColumn :public comphelper::OBaseMutex
,public OColumnBase
,public ::comphelper::OPropertyContainer
@@ -157,13 +157,13 @@ namespace dbaccess
//= general columns map, could be used for readonly access
//= no appending and dropping is supported
//============================================================
- typedef ::std::hash_map<rtl::OUString, OColumn*, ::comphelper::UStringMixHash, ::comphelper::UStringMixEqual> OColumnMap;
+ typedef ::boost::unordered_map<rtl::OUString, OColumn*, ::comphelper::UStringMixHash, ::comphelper::UStringMixEqual> OColumnMap;
typedef ::std::vector<OColumn*> OColumnArray;
class OContainerMediator;
typedef ::cppu::ImplHelper1< ::com::sun::star::container::XChild > TXChild;
typedef connectivity::OColumnsHelper OColumns_BASE;
- //------------------------------------------------------------
+
class OColumns : public OColumns_BASE
,public TXChild
{
@@ -256,3 +256,4 @@ namespace dbaccess
}
#endif // _DBA_COREAPI_COLUMN_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/columnsettings.hxx b/dbaccess/source/core/inc/columnsettings.hxx
index c9f6fa5b1cda..c407b60820a8 100644
--- a/dbaccess/source/core/inc/columnsettings.hxx
+++ b/dbaccess/source/core/inc/columnsettings.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -31,10 +32,8 @@
#include <com/sun/star/beans/XPropertySet.hpp>
/** === end UNO includes === **/
-//........................................................................
namespace dbaccess
{
-//........................................................................
// TODO: move the following to comphelper/propertycontainerhelper.hxx
class IPropertyContainer
@@ -102,8 +101,8 @@ namespace dbaccess
static bool hasDefaultSettings( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet >& _rxColumn );
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // COLUMNSETTINGS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/commandbase.hxx b/dbaccess/source/core/inc/commandbase.hxx
index ea0e9644c714..05b9ca849276 100644
--- a/dbaccess/source/core/inc/commandbase.hxx
+++ b/dbaccess/source/core/inc/commandbase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,17 +29,11 @@
#ifndef _DBA_CORE_COMMANDBASE_HXX_
#define _DBA_CORE_COMMANDBASE_HXX_
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= OCommandBase - a base class (in fact just a container for some members)
@@ -62,10 +57,8 @@ protected:
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_CORE_COMMANDBASE_HXX_
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/composertools.hxx b/dbaccess/source/core/inc/composertools.hxx
index 4f7c4b7f66ef..eaaba4cdd26b 100644
--- a/dbaccess/source/core/inc/composertools.hxx
+++ b/dbaccess/source/core/inc/composertools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,16 +32,12 @@
/** === begin UNO includes === **/
/** === end UNO includes === **/
-#ifndef _RTL_USTRBUF_HXX_
#include <rtl/ustrbuf.hxx>
-#endif
#include <functional>
-//........................................................................
namespace dbaccess
{
-//........................................................................
//====================================================================
//= TokenComposer
@@ -134,9 +131,8 @@ namespace dbaccess
}
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_SOURCE_CORE_INC_COMPOSERTOOLS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/containerapprove.hxx b/dbaccess/source/core/inc/containerapprove.hxx
index 0f27559201d7..abedd666e0f3 100644
--- a/dbaccess/source/core/inc/containerapprove.hxx
+++ b/dbaccess/source/core/inc/containerapprove.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,17 +30,13 @@
#define DBACCESS_CONTAINERAPPROVE_HXX
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_UNO_XINTERFACE_HPP_
#include <com/sun/star/uno/XInterface.hpp>
-#endif
/** === end UNO includes === **/
#include <boost/shared_ptr.hpp>
-//........................................................................
namespace dbaccess
{
-//........................................................................
//====================================================================
//= IContainerApprove
@@ -72,9 +69,8 @@ namespace dbaccess
typedef ::boost::shared_ptr< IContainerApprove > PContainerApprove;
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_CONTAINERAPPROVE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/core_resource.hrc b/dbaccess/source/core/inc/core_resource.hrc
index fb6320f38932..05c8aebe0b26 100644
--- a/dbaccess/source/core/inc/core_resource.hrc
+++ b/dbaccess/source/core/inc/core_resource.hrc
@@ -32,10 +32,8 @@
#include <svl/solar.hrc>
#endif
-//------------------------------------------------------------------------------
#define RID_CORE_STRINGS_START RID_DBACCESS_START
-//------------------------------------------------------------------------------
//- String-IDs
#define RID_STR_TRIED_OPEN_TABLE ( RID_CORE_STRINGS_START + 0 )
#define RID_STR_CONNECTION_INVALID ( RID_CORE_STRINGS_START + 1 )
@@ -110,4 +108,3 @@
#define RID_NO_SUCH_DATA_SOURCE ( RID_CORE_STRINGS_START + 67 )
#endif // _DBA_CORE_RESOURCE_HRC_
-
diff --git a/dbaccess/source/core/inc/core_resource.hxx b/dbaccess/source/core/inc/core_resource.hxx
index fd8023e15322..42677cd5a72d 100644
--- a/dbaccess/source/core/inc/core_resource.hxx
+++ b/dbaccess/source/core/inc/core_resource.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,13 +29,12 @@
#ifndef _DBA_CORE_RESOURCE_HXX_
#define _DBA_CORE_RESOURCE_HXX_
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
#include <osl/mutex.hxx>
+#include <sal/macros.h>
class ResMgr;
-//.........................................................................
+
namespace dbaccess
{
@@ -120,11 +120,8 @@ namespace dbaccess
OModuleClient() { ResourceManager::registerClient(); }
~OModuleClient() { ResourceManager::revokeClient(); }
};
-
-
-//.........................................................................
}
-//.........................................................................
#endif // _DBA_CORE_RESOURCE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/datasettings.hxx b/dbaccess/source/core/inc/datasettings.hxx
index 9b42c7d57cf9..cd2b4e715702 100644
--- a/dbaccess/source/core/inc/datasettings.hxx
+++ b/dbaccess/source/core/inc/datasettings.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,29 +29,15 @@
#ifndef _DBA_CORE_DATASETTINGS_HXX_
#define _DBA_CORE_DATASETTINGS_HXX_
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTY_HPP_
#include <com/sun/star/beans/Property.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTDESCRIPTOR_HPP_
#include <com/sun/star/awt/FontDescriptor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_ILLEGALARGUMENTEXCEPTION_HPP_
#include <com/sun/star/lang/IllegalArgumentException.hpp>
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef COMPHELPER_PROPERTYSTATECONTAINER_HXX
#include <comphelper/propertystatecontainer.hxx>
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
//==========================================================================
//= ODataSettings_Base - a base class which implements the property member
@@ -101,9 +88,8 @@ protected:
void registerPropertiesFor(ODataSettings_Base* _pItem);
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_CORE_DATASETTINGS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/definitioncolumn.hxx b/dbaccess/source/core/inc/definitioncolumn.hxx
index 185e7d1426d8..f98c633a5396 100644
--- a/dbaccess/source/core/inc/definitioncolumn.hxx
+++ b/dbaccess/source/core/inc/definitioncolumn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -316,3 +317,4 @@ namespace dbaccess
}
#endif // _DBACORE_DEFINITIONCOLUMN_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/definitioncontainer.hxx b/dbaccess/source/core/inc/definitioncontainer.hxx
index d70a0813e18c..72a5a9fbbfd7 100644
--- a/dbaccess/source/core/inc/definitioncontainer.hxx
+++ b/dbaccess/source/core/inc/definitioncontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,67 +29,28 @@
#ifndef _DBA_CORE_DEFINITIONCONTAINER_HXX_
#define _DBA_CORE_DEFINITIONCONTAINER_HXX_
-#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_
#include <cppuhelper/interfacecontainer.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE7_HXX_
#include <cppuhelper/implbase7.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XENUMERATIONACCESS_HPP_
#include <com/sun/star/container/XEnumerationAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYCHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertyChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XVETOABLECHANGELISTENER_HPP_
#include <com/sun/star/beans/XVetoableChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERAPPROVEBROADCASTER_HPP_
#include <com/sun/star/container/XContainerApproveBroadcaster.hpp>
-#endif
-#ifndef DBA_CONTENTHELPER_HXX
#include "ContentHelper.hxx"
-#endif
-#ifndef DBACCESS_CONTAINERAPPROVE_HXX
#include "containerapprove.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _RTL_REF_HXX_
#include <rtl/ref.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-//........................................................................
+
namespace dbaccess
{
-//........................................................................
class ODefinitionContainer_Impl : public OContentHelper_Impl
{
@@ -367,9 +329,8 @@ private:
}
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_CORE_DEFINITIONCONTAINER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/module_dba.hxx b/dbaccess/source/core/inc/module_dba.hxx
index 03a5faefa1d2..8553348dbf00 100644
--- a/dbaccess/source/core/inc/module_dba.hxx
+++ b/dbaccess/source/core/inc/module_dba.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,16 +31,13 @@
#include <unotools/componentresmodule.hxx>
-//........................................................................
namespace dba
{
-//........................................................................
DEFINE_MODULE( DbaModule, DbaClient, DbaRes )
-//........................................................................
} // namespace sdbtools
-//........................................................................
#endif // DBACCESS_MODULE_DBA_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/object.hxx b/dbaccess/source/core/inc/object.hxx
index 917cc9e05e42..7b32511f2521 100644
--- a/dbaccess/source/core/inc/object.hxx
+++ b/dbaccess/source/core/inc/object.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -38,3 +39,4 @@ enum ObjectType
#endif // _DBA_OBJECT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/objectnameapproval.hxx b/dbaccess/source/core/inc/objectnameapproval.hxx
index bea104c77443..d641e6f1c6bd 100644
--- a/dbaccess/source/core/inc/objectnameapproval.hxx
+++ b/dbaccess/source/core/inc/objectnameapproval.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,20 +29,14 @@
#ifndef DBACCESS_OBJECTNAMEAPPROVAL_HXX
#define DBACCESS_OBJECTNAMEAPPROVAL_HXX
-#ifndef DBACCESS_CONTAINERAPPROVE_HXX
#include "containerapprove.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
/** === end UNO includes === **/
-//........................................................................
namespace dbaccess
{
-//........................................................................
//====================================================================
//= ObjectNameApproval
@@ -88,8 +83,8 @@ namespace dbaccess
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_OBJECTNAMEAPPROVAL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/preparedstatement.hxx b/dbaccess/source/core/inc/preparedstatement.hxx
index e0df114b22af..ff2337944a69 100644
--- a/dbaccess/source/core/inc/preparedstatement.hxx
+++ b/dbaccess/source/core/inc/preparedstatement.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,14 @@
#ifndef _DBA_COREAPI_PREPAREDSTATEMENT_HXX_
#define _DBA_COREAPI_PREPAREDSTATEMENT_HXX_
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPREPAREDSTATEMENT_HPP_
#include <com/sun/star/sdbc/XPreparedStatement.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPARAMETERS_HPP_
#include <com/sun/star/sdbc/XParameters.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPARAMETERS_HPP_
#include <com/sun/star/sdbc/XParameters.hpp>
-#endif
-#ifndef _DBA_COREAPI_STATEMENT_HXX_
#include <statement.hxx>
-#endif
-#ifndef _DBA_COREAPI_COLUMN_HXX_
#include <column.hxx>
-#endif
namespace dbaccess
{
@@ -130,3 +115,4 @@ namespace dbaccess
}
#endif // _DBA_COREAPI_PREPAREDSTATEMENT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/querycomposer.hxx b/dbaccess/source/core/inc/querycomposer.hxx
index 839e5e39a772..e98ec650b632 100644
--- a/dbaccess/source/core/inc/querycomposer.hxx
+++ b/dbaccess/source/core/inc/querycomposer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,45 +28,19 @@
#ifndef DBACCESS_CORE_API_QUERYCOMPOSER_HXX
#define DBACCESS_CORE_API_QUERYCOMPOSER_HXX
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSQLQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSQLQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XPARAMETERSSUPPLIER_HPP_
#include <com/sun/star/sdb/XParametersSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SCRIPT_XTYPECONVERTER_HPP_
#include <com/sun/star/script/XTypeConverter.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _CONNECTIVITY_PARSE_SQLITERATOR_HXX_
#include <connectivity/sqliterator.hxx>
-#endif
-#ifndef _CONNECTIVITY_SQLPARSE_HXX
#include <connectivity/sqlparse.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
@@ -137,3 +112,5 @@ namespace dbaccess
};
}
#endif // DBACCESS_CORE_API_QUERYCOMPOSER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/querycontainer.hxx b/dbaccess/source/core/inc/querycontainer.hxx
index 9502a7002aa7..46fea061727f 100644
--- a/dbaccess/source/core/inc/querycontainer.hxx
+++ b/dbaccess/source/core/inc/querycontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,86 +29,40 @@
#ifndef _DBA_CORE_QUERYCONTAINER_HXX_
#define _DBA_CORE_QUERYCONTAINER_HXX_
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_
#include <cppuhelper/interfacecontainer.hxx>
-#endif
/** === begin UNO includes == **/
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XENUMERATIONACCESS_HPP_
#include <com/sun/star/container/XEnumerationAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERLISTENER_HPP_
#include <com/sun/star/container/XContainerListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XREFRESHABLE_HPP_
#include <com/sun/star/util/XRefreshable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDROP_HPP_
#include <com/sun/star/sdbcx/XDrop.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYCHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertyChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERAPPROVELISTENER_HPP_
#include <com/sun/star/container/XContainerApproveListener.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _DBA_CORE_DEFINITIONCONTAINER_HXX_
#include "definitioncontainer.hxx"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
namespace dbtools
{
class IWarningsContainer;
}
-//........................................................................
namespace dbaccess
{
-//........................................................................
typedef ::cppu::ImplHelper5 < ::com::sun::star::container::XContainerListener
, ::com::sun::star::container::XContainerApproveListener
@@ -137,7 +92,6 @@ namespace dbaccess
OContainerListener* m_pCommandsListener;
- // ------------------------------------------------------------------------
/** a class which automatically resets m_eDoingCurrently in it's destructor
*/
class OAutoActionReset; // just for the following friend declaration
@@ -225,10 +179,8 @@ namespace dbaccess
::com::sun::star::uno::Reference< ::com::sun::star::ucb::XContent > implCreateWrapper(const ::com::sun::star::uno::Reference< ::com::sun::star::ucb::XContent >& _rxCommandDesc);
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // _DBA_CORE_QUERYCONTAINER_HXX_
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/recovery/dbdocrecovery.hxx b/dbaccess/source/core/inc/recovery/dbdocrecovery.hxx
index 4aa124dc7015..5808a134484e 100644
--- a/dbaccess/source/core/inc/recovery/dbdocrecovery.hxx
+++ b/dbaccess/source/core/inc/recovery/dbdocrecovery.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -41,10 +42,8 @@ namespace comphelper
class ComponentContext;
}
-//........................................................................
namespace dbaccess
{
-//........................................................................
//====================================================================
//= DatabaseDocumentRecovery
@@ -85,8 +84,8 @@ namespace dbaccess
const ::std::auto_ptr< DatabaseDocumentRecovery_Data > m_pData;
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_DBDOCRECOVERY_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/sdbcoretools.hxx b/dbaccess/source/core/inc/sdbcoretools.hxx
index d6044a6b9110..6c057018e325 100644
--- a/dbaccess/source/core/inc/sdbcoretools.hxx
+++ b/dbaccess/source/core/inc/sdbcoretools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,21 +43,14 @@ namespace comphelper
class ComponentContext;
}
-//.........................................................................
namespace dbaccess
{
-//.........................................................................
- // -----------------------------------------------------------------------------
void notifyDataSourceModified(const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& _rxObject,sal_Bool _bModified);
- // -----------------------------------------------------------------------------
::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
getDataSource( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& _rxDependentObject );
- // -----------------------------------------------------------------------------
-
- // -----------------------------------------------------------------------------
/** retrieves a to-be-displayed string for a given caught exception;
*/
::rtl::OUString extractExceptionMessage( const ::comphelper::ComponentContext& _rContext, const ::com::sun::star::uno::Any& _rError );
@@ -82,7 +76,7 @@ namespace dbaccess
}
} // namespace dbaccess
-//.........................................................................
#endif // DBACORE_SDBCORETOOLS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/statement.hxx b/dbaccess/source/core/inc/statement.hxx
index ae821c7a516b..b609aaf71213 100644
--- a/dbaccess/source/core/inc/statement.hxx
+++ b/dbaccess/source/core/inc/statement.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,49 +28,21 @@
#ifndef _DBA_COREAPI_STATEMENT_HXX_
#define _DBA_COREAPI_STATEMENT_HXX_
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XSTATEMENT_HPP_
#include <com/sun/star/sdbc/XStatement.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XCANCELLABLE_HPP_
#include <com/sun/star/util/XCancellable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XWARNINGSSUPPLIER_HPP_
#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCLOSEABLE_HPP_
#include <com/sun/star/sdbc/XCloseable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XMULTIPLERESULTS_HDL_
#include <com/sun/star/sdbc/XMultipleResults.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPREPAREDBATCHEXECUTION_HDL_
#include <com/sun/star/sdbc/XPreparedBatchExecution.hpp>
-#endif
#include <com/sun/star/sdbc/XBatchExecution.hpp>
-#ifndef _COM_SUN_STAR_SDBC_XGENERATEDRESULTSET_HPP_
#include <com/sun/star/sdbc/XGeneratedResultSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _CPPUHELPER_PROPSHLP_HXX
#include <cppuhelper/propshlp.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
#include <cppuhelper/implbase3.hxx>
@@ -218,3 +191,4 @@ private:
#endif // _DBA_COREAPI_STATEMENT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/table.hxx b/dbaccess/source/core/inc/table.hxx
index 95e984949619..63ebe2213306 100644
--- a/dbaccess/source/core/inc/table.hxx
+++ b/dbaccess/source/core/inc/table.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -142,7 +143,6 @@ namespace dbaccess
DECLARE_SERVICE_INFO();
// com::sun::star::beans::XPropertySet
- // virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw(::com::sun::star::uno::RuntimeException);
virtual void SAL_CALL getFastPropertyValue(::com::sun::star::uno::Any& rValue, sal_Int32 nHandle) const;
// ::com::sun::star::sdbcx::XRename,
@@ -162,3 +162,4 @@ namespace dbaccess
#endif // _DBA_CORE_TABLE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/tablecontainer.hxx b/dbaccess/source/core/inc/tablecontainer.hxx
index 5e64e8896d55..ab2eb7bfe293 100644
--- a/dbaccess/source/core/inc/tablecontainer.hxx
+++ b/dbaccess/source/core/inc/tablecontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,54 +29,22 @@
#ifndef _DBA_CORE_TABLECONTAINER_HXX_
#define _DBA_CORE_TABLECONTAINER_HXX_
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XENUMERATIONACCESS_HPP_
#include <com/sun/star/container/XEnumerationAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XREFRESHABLE_HPP_
#include <com/sun/star/util/XRefreshable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERLISTENER_HPP_
#include <com/sun/star/container/XContainerListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef DBACCESS_CORE_FILTERED_CONTAINER_HXX
#include "FilteredContainer.hxx"
-#endif
-#ifndef DBTOOLS_WARNINGSCONTAINER_HXX
#include <connectivity/warningscontainer.hxx>
-#endif
-#ifndef DBA_CORE_REFRESHLISTENER_HXX
#include "RefreshListener.hxx"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
namespace dbaccess
{
@@ -147,3 +116,4 @@ namespace dbaccess
#endif // _DBA_CORE_TABLECONTAINER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/userinformation.hxx b/dbaccess/source/core/inc/userinformation.hxx
index 24dbbb206f2c..f3cbcc4fd643 100644
--- a/dbaccess/source/core/inc/userinformation.hxx
+++ b/dbaccess/source/core/inc/userinformation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,13 +29,9 @@
#ifndef _DBA_CORE_USERINFORMATION_HXX_
#define _DBA_CORE_USERINFORMATION_HXX_
-#ifndef _COM_SUN_STAR_LANG_LOCALE_HPP_
#include <com/sun/star/lang/Locale.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
class UserInformation
{
@@ -48,3 +45,4 @@ public:
#endif // _DBA_CORE_USERINFORMATION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/veto.hxx b/dbaccess/source/core/inc/veto.hxx
index 00de76c7b73e..787d3d107f4a 100644
--- a/dbaccess/source/core/inc/veto.hxx
+++ b/dbaccess/source/core/inc/veto.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,19 +30,13 @@
#define DBACCESS_VETO_HXX
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_UTIL_XVETO_HPP_
#include <com/sun/star/util/XVeto.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-//........................................................................
namespace dbaccess
{
-//........................................................................
//====================================================================
//= Veto
@@ -71,9 +66,8 @@ namespace dbaccess
Veto& operator=( const Veto& ); // never implemented
};
-//........................................................................
} // namespace dbaccess
-//........................................................................
#endif // DBACCESS_VETO_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/inc/viewcontainer.hxx b/dbaccess/source/core/inc/viewcontainer.hxx
index beb5c08e6350..97e4f1393ca3 100644
--- a/dbaccess/source/core/inc/viewcontainer.hxx
+++ b/dbaccess/source/core/inc/viewcontainer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,47 +29,21 @@
#ifndef _DBA_CORE_VIEWCONTAINER_HXX_
#define _DBA_CORE_VIEWCONTAINER_HXX_
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XENUMERATIONACCESS_HPP_
#include <com/sun/star/container/XEnumerationAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XREFRESHABLE_HPP_
#include <com/sun/star/util/XRefreshable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLWARNING_HPP_
#include <com/sun/star/sdbc/SQLWarning.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERLISTENER_HPP_
#include <com/sun/star/container/XContainerListener.hpp>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef DBACCESS_CORE_FILTERED_CONTAINER_HXX
#include "FilteredContainer.hxx"
-#endif
namespace dbtools
{
@@ -137,3 +112,4 @@ namespace dbaccess
#endif // _DBA_CORE_VIEWCONTAINER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/ContainerListener.cxx b/dbaccess/source/core/misc/ContainerListener.cxx
index efdd32c1fee3..79772386d185 100644
--- a/dbaccess/source/core/misc/ContainerListener.cxx
+++ b/dbaccess/source/core/misc/ContainerListener.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBA_CONTAINERLISTENER_HXX
#include "ContainerListener.hxx"
-#endif
//........................................................................
namespace dbaccess
@@ -129,3 +128,5 @@ namespace dbaccess
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/ContainerMediator.cxx b/dbaccess/source/core/misc/ContainerMediator.cxx
index 7d7ea80f558a..417d49c9c372 100644
--- a/dbaccess/source/core/misc/ContainerMediator.cxx
+++ b/dbaccess/source/core/misc/ContainerMediator.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,38 +28,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBA_CONTAINERMEDIATOR_HXX
#include "ContainerMediator.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef DBA_PROPERTYSETFORWARD_HXX
#include "PropertyForward.hxx"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
#include <com/sun/star/sdbcx/XRename.hpp>
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
//........................................................................
@@ -94,7 +75,7 @@ OContainerMediator::OContainerMediator( const Reference< XContainer >& _xContain
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "OContainerMediator::OContainerMediator: caught an exception!");
+ OSL_FAIL("OContainerMediator::OContainerMediator: caught an exception!");
}
osl_decrementInterlockedCount( &m_refCount );
}
@@ -242,7 +223,7 @@ void OContainerMediator::notifyElementCreated( const ::rtl::OUString& _sName, co
&& aFind->second->getDefinition().is()
)
{
- OSL_ENSURE( false, "OContainerMediator::notifyElementCreated: is this really a valid case?" );
+ OSL_FAIL( "OContainerMediator::notifyElementCreated: is this really a valid case?" );
return;
}
@@ -279,3 +260,5 @@ void OContainerMediator::notifyElementCreated( const ::rtl::OUString& _sName, co
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/DatabaseDataProvider.cxx b/dbaccess/source/core/misc/DatabaseDataProvider.cxx
index dbed20058780..06c448faa700 100644
--- a/dbaccess/source/core/misc/DatabaseDataProvider.cxx
+++ b/dbaccess/source/core/misc/DatabaseDataProvider.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,6 +37,7 @@
#include <connectivity/dbtools.hxx>
#include <rtl/ustrbuf.hxx>
#include <rtl/math.hxx>
+#include <sal/macros.h>
#include <tools/diagnose_ex.h>
#include <com/sun/star/task/XInteractionHandler.hpp>
@@ -119,7 +121,7 @@ uno::Any DatabaseDataProvider::queryInterface(uno::Type const & type) throw (uno
//------------------------------------------------------------------------------
rtl::OUString DatabaseDataProvider::getImplementationName_Static( ) throw(uno::RuntimeException)
{
- return rtl::OUString::createFromAscii("com.sun.star.comp.chart2.data.DatabaseDataProvider");
+ return rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.chart2.data.DatabaseDataProvider"));
}
// -----------------------------------------------------------------------------
// -------------------------------------------------------------------------
@@ -173,26 +175,25 @@ void SAL_CALL DatabaseDataProvider::initialize(const uno::Sequence< uno::Any > &
// chart2::data::XDataProvider:
::sal_Bool SAL_CALL DatabaseDataProvider::createDataSourcePossible(const uno::Sequence< beans::PropertyValue > & _aArguments) throw (uno::RuntimeException)
{
- //::osl::ResettableMutexGuard aClearForNotifies(m_aMutex);
const beans::PropertyValue* pArgIter = _aArguments.getConstArray();
const beans::PropertyValue* pArgEnd = pArgIter + _aArguments.getLength();
for(;pArgIter != pArgEnd;++pArgIter)
{
- if ( pArgIter->Name.equalsAscii("DataRowSource") )
+ if ( pArgIter->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("DataRowSource")) )
{
::com::sun::star::chart::ChartDataRowSource eRowSource = ::com::sun::star::chart::ChartDataRowSource_COLUMNS;
pArgIter->Value >>= eRowSource;
if ( eRowSource != ::com::sun::star::chart::ChartDataRowSource_COLUMNS )
return sal_False;
- } // if ( pArgIter->Name.equalsAscii("DataRowSource") )
- else if ( pArgIter->Name.equalsAscii("CellRangeRepresentation") )
+ }
+ else if ( pArgIter->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("CellRangeRepresentation")) )
{
::rtl::OUString sRange;
pArgIter->Value >>= sRange;
- if ( !sRange.equalsAscii("all") )
+ if ( !sRange.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("all")) )
return sal_False;
}
- else if ( pArgIter->Name.equalsAscii("FirstCellAsLabel") )
+ else if ( pArgIter->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("FirstCellAsLabel")) )
{
sal_Bool bFirstCellAsLabel = sal_True;
pArgIter->Value >>= bFirstCellAsLabel;
@@ -241,7 +242,7 @@ uno::Reference< chart2::data::XDataSource > SAL_CALL DatabaseDataProvider::creat
{
}
}
- if ( !bRet ) // no command set or an error occured, use Internal data handler
+ if ( !bRet ) // no command set or an error occurred, use Internal data handler
{
uno::Reference< lang::XInitialization> xIni(m_xInternal,uno::UNO_QUERY);
if ( xIni.is() )
@@ -829,16 +830,16 @@ void DatabaseDataProvider::impl_fillInternalDataProvider_throw(sal_Bool _bHasCat
{
aRowLabels.push_back(::rtl::OUString::valueOf(h+1));
::std::vector< double > aRow;
- const sal_Int32 nSize = sizeof(fDefaultData)/sizeof(fDefaultData[0]);
+ const sal_Int32 nSize = SAL_N_ELEMENTS(fDefaultData);
for (size_t j = 0; j < (aColumns.size()-1); ++j,++k)
{
if ( k >= nSize )
k = 0;
aRow.push_back(fDefaultData[k]);
- } // for (sal_Int32 j = 0,k = 0; j < (aColumns.size()-1); ++j,++k)
+ }
aDataValues.push_back(aRow);
}
- } // if ( !nRowCount )
+ }
uno::Reference< chart::XChartDataArray> xData(m_xInternal,uno::UNO_QUERY);
xData->setRowDescriptions(uno::Sequence< ::rtl::OUString >(&(*aRowLabels.begin()),aRowLabels.size()));
@@ -1169,3 +1170,5 @@ void DatabaseDataProvider::impl_invalidateParameter_nothrow()
}
// -----------------------------------------------------------------------------
} // namespace dbaccess
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/PropertyForward.cxx b/dbaccess/source/core/misc/PropertyForward.cxx
index 4f9aa81ab28c..9940b3990562 100644
--- a/dbaccess/source/core/misc/PropertyForward.cxx
+++ b/dbaccess/source/core/misc/PropertyForward.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -171,3 +172,4 @@ namespace dbaccess
} // namespace dbaccess
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/apitools.cxx b/dbaccess/source/core/misc/apitools.cxx
index c53f936df234..281fb4902a6b 100644
--- a/dbaccess/source/core/misc/apitools.cxx
+++ b/dbaccess/source/core/misc/apitools.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,22 +29,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
#include <com/sun/star/lang/XServiceInfo.hpp>
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
@@ -153,3 +144,4 @@ Any OSubComponent::queryInterface( const Type & rType ) throw(RuntimeException)
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/dbastrings.cxx b/dbaccess/source/core/misc/dbastrings.cxx
index 80f1427842e8..f8f53df0e866 100644
--- a/dbaccess/source/core/misc/dbastrings.cxx
+++ b/dbaccess/source/core/misc/dbastrings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_SHARED_DBASTRINGS_HRC
#include "dbastrings.hrc"
-#endif
namespace dbaccess
{
@@ -47,3 +46,5 @@ namespace dbaccess
IMPLEMENT_CONSTASCII_USTRING( PROPERTY_IS_FORM, "IsForm" );
IMPLEMENT_CONSTASCII_USTRING( PROPERTY_PERSISTENT_PATH, "PersistentPath" );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/dsntypes.cxx b/dbaccess/source/core/misc/dsntypes.cxx
index 46178dba6b98..f83dc363b532 100644
--- a/dbaccess/source/core/misc/dsntypes.cxx
+++ b/dbaccess/source/core/misc/dsntypes.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,10 +29,13 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
+#include <sal/macros.h>
+
#include "dsntypes.hxx"
#include "dbamiscres.hrc"
#include <unotools/confignode.hxx>
#include <tools/debug.hxx>
+#include <osl/diagnose.h>
#include <tools/wldcrd.hxx>
#include <osl/file.hxx>
#include "dbastrings.hrc"
@@ -48,7 +52,6 @@ namespace dbaccess
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::lang;
- //using namespace ::com::sun::star::sdbc;
namespace
{
@@ -69,7 +72,7 @@ DBG_NAME(ODsnTypeCollection)
ODsnTypeCollection::ODsnTypeCollection(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _xFactory)
:m_aDriverConfig(_xFactory)
,m_xFactory(_xFactory)
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
,m_nLivingIterators(0)
#endif
{
@@ -83,7 +86,7 @@ ODsnTypeCollection::ODsnTypeCollection(const ::com::sun::star::uno::Reference< :
m_aDsnTypesDisplayNames.push_back(m_aDriverConfig.getDriverTypeDisplayName(*pIter));
}
- DBG_ASSERT(m_aDsnTypesDisplayNames.size() == m_aDsnPrefixes.size(),
+ OSL_ENSURE(m_aDsnTypesDisplayNames.size() == m_aDsnPrefixes.size(),
"ODsnTypeCollection::ODsnTypeCollection : invalid resources !");
}
@@ -91,7 +94,7 @@ ODsnTypeCollection::ODsnTypeCollection(const ::com::sun::star::uno::Reference< :
ODsnTypeCollection::~ODsnTypeCollection()
{
DBG_DTOR(ODsnTypeCollection,NULL);
- DBG_ASSERT(0 == m_nLivingIterators, "ODsnTypeCollection::~ODsnTypeCollection : there are still living iterator objects!");
+ OSL_ENSURE(0 == m_nLivingIterators, "ODsnTypeCollection::~ODsnTypeCollection : there are still living iterator objects!");
}
//-------------------------------------------------------------------------
String ODsnTypeCollection::getTypeDisplayName(const ::rtl::OUString& _sURL) const
@@ -170,7 +173,7 @@ bool ODsnTypeCollection::isConnectionUrlRequired(const ::rtl::OUString& _sURL) c
sRet = *aIter;
sOldPattern = *aIter;
}
- } // for(;aIter != aEnd;++aIter)
+ }
return sRet.GetChar(sRet.Len()-1) == '*';
}
// -----------------------------------------------------------------------------
@@ -200,7 +203,7 @@ String ODsnTypeCollection::getDatasourcePrefixFromMediaType(const ::rtl::OUStrin
if ( !sFileExtension.getLength() && _sExtension.getLength() )
sFallbackURL = *pIter;
}
- } // for(;pIter != pEnd;++pIter )
+ }
if ( !sURL.Len() && sFallbackURL.Len() )
sURL = sFallbackURL;
@@ -236,7 +239,7 @@ void ODsnTypeCollection::extractHostNamePort(const ::rtl::OUString& _rDsn,String
if ( _rsHostname.Len() )
_rsHostname = _rsHostname.GetToken(_rsHostname.GetTokenCount('@') - 1,'@');
_sDatabaseName = sUrl.GetToken(sUrl.GetTokenCount(':') - 1,':');
- } // if ( _rDsn.matchIgnoreAsciiCaseAsciiL("jdbc:oracle:thin:",sizeof("jdbc:oracle:thin:")-1) )
+ }
else if ( _rDsn.matchIgnoreAsciiCaseAsciiL("sdbc:address:ldap:",sizeof("sdbc:address:ldap:")-1) )
{
lcl_extractHostAndPort(sUrl,_sDatabaseName,_nPortNumber);
@@ -331,7 +334,7 @@ bool ODsnTypeCollection::isEmbeddedDatabase( const ::rtl::OUString& _sURL ) cons
if ( sEmbeddedDatabaseURL.getLength() )
aInstalled.getNodeValue(s_sValue + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/")) + sEmbeddedDatabaseURL + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/URL"))) >>= sEmbeddedDatabaseURL;
}
- } // if ( aInstalled.isValid() )
+ }
if ( !sEmbeddedDatabaseURL.getLength() )
sEmbeddedDatabaseURL = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:embedded:hsqldb"));
return sEmbeddedDatabaseURL;
@@ -356,7 +359,7 @@ DATASOURCE_TYPE ODsnTypeCollection::determineType(const String& _rDsn) const
if (STRING_NOTFOUND == nSeparator)
{
// there should be at least one such separator
- DBG_ERROR("ODsnTypeCollection::implDetermineType : missing the colon !");
+ OSL_FAIL("ODsnTypeCollection::implDetermineType : missing the colon !");
return DST_UNKNOWN;
}
// find first :
@@ -379,7 +382,7 @@ DATASOURCE_TYPE ODsnTypeCollection::determineType(const String& _rDsn) const
if (STRING_NOTFOUND == nSeparator)
{
// at the moment only jdbc is allowed to have just one separator
- DBG_ERROR("ODsnTypeCollection::implDetermineType : missing the second colon !");
+ OSL_FAIL("ODsnTypeCollection::implDetermineType : missing the second colon !");
return DST_UNKNOWN;
}
@@ -440,7 +443,7 @@ DATASOURCE_TYPE ODsnTypeCollection::determineType(const String& _rDsn) const
KnownPrefix( "sdbc:address:macab", DST_MACAB, true )
};
- for ( size_t i=0; i < sizeof( aKnowPrefixes ) / sizeof( aKnowPrefixes[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aKnowPrefixes ); ++i )
{
sal_uInt16 nMatchLen = aKnowPrefixes[i].bMatchComplete ? sDsn.Len() : (sal_uInt16)rtl_str_getLength( aKnowPrefixes[i].pAsciiPrefix );
if ( sDsn.EqualsIgnoreCaseAscii( aKnowPrefixes[i].pAsciiPrefix, 0, nMatchLen ) )
@@ -527,7 +530,7 @@ void ODsnTypeCollection::fillPageIds(const ::rtl::OUString& _sURL,::std::vector<
{
sOldPattern = *aIter;
}
- } // for(sal_Int32 i = 0;aIter != aEnd;++aIter,++i)
+ }
return sOldPattern;
}
// -----------------------------------------------------------------------------
@@ -563,8 +566,8 @@ ODsnTypeCollection::TypeIterator::TypeIterator(const ODsnTypeCollection* _pConta
:m_pContainer(_pContainer)
,m_nPosition(_nInitialPos)
{
- DBG_ASSERT(m_pContainer, "ODsnTypeCollection::TypeIterator::TypeIterator : invalid container!");
-#ifdef DBG_UTIL
+ OSL_ENSURE(m_pContainer, "ODsnTypeCollection::TypeIterator::TypeIterator : invalid container!");
+#if OSL_DEBUG_LEVEL > 0
++const_cast<ODsnTypeCollection*>(m_pContainer)->m_nLivingIterators;
#endif
}
@@ -574,7 +577,7 @@ ODsnTypeCollection::TypeIterator::TypeIterator(const TypeIterator& _rSource)
:m_pContainer(_rSource.m_pContainer)
,m_nPosition(_rSource.m_nPosition)
{
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
++const_cast<ODsnTypeCollection*>(m_pContainer)->m_nLivingIterators;
#endif
}
@@ -582,7 +585,7 @@ ODsnTypeCollection::TypeIterator::TypeIterator(const TypeIterator& _rSource)
//-------------------------------------------------------------------------
ODsnTypeCollection::TypeIterator::~TypeIterator()
{
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
--const_cast<ODsnTypeCollection*>(m_pContainer)->m_nLivingIterators;
#endif
}
@@ -590,19 +593,19 @@ ODsnTypeCollection::TypeIterator::~TypeIterator()
//-------------------------------------------------------------------------
String ODsnTypeCollection::TypeIterator::getDisplayName() const
{
- DBG_ASSERT(m_nPosition < (sal_Int32)m_pContainer->m_aDsnTypesDisplayNames.size(), "ODsnTypeCollection::TypeIterator::getDisplayName : invalid position!");
+ OSL_ENSURE(m_nPosition < (sal_Int32)m_pContainer->m_aDsnTypesDisplayNames.size(), "ODsnTypeCollection::TypeIterator::getDisplayName : invalid position!");
return m_pContainer->m_aDsnTypesDisplayNames[m_nPosition];
}
// -----------------------------------------------------------------------------
::rtl::OUString ODsnTypeCollection::TypeIterator::getURLPrefix() const
{
- DBG_ASSERT(m_nPosition < (sal_Int32)m_pContainer->m_aDsnPrefixes.size(), "ODsnTypeCollection::TypeIterator::getDisplayName : invalid position!");
+ OSL_ENSURE(m_nPosition < (sal_Int32)m_pContainer->m_aDsnPrefixes.size(), "ODsnTypeCollection::TypeIterator::getDisplayName : invalid position!");
return m_pContainer->m_aDsnPrefixes[m_nPosition];
}
//-------------------------------------------------------------------------
const ODsnTypeCollection::TypeIterator& ODsnTypeCollection::TypeIterator::operator++()
{
- DBG_ASSERT(m_nPosition < (sal_Int32)m_pContainer->m_aDsnTypesDisplayNames.size(), "ODsnTypeCollection::TypeIterator::operator++ : invalid position!");
+ OSL_ENSURE(m_nPosition < (sal_Int32)m_pContainer->m_aDsnTypesDisplayNames.size(), "ODsnTypeCollection::TypeIterator::operator++ : invalid position!");
if (m_nPosition < (sal_Int32)m_pContainer->m_aDsnTypesDisplayNames.size())
++m_nPosition;
return *this;
@@ -611,7 +614,7 @@ const ODsnTypeCollection::TypeIterator& ODsnTypeCollection::TypeIterator::operat
//-------------------------------------------------------------------------
const ODsnTypeCollection::TypeIterator& ODsnTypeCollection::TypeIterator::operator--()
{
- DBG_ASSERT(m_nPosition >= 0, "ODsnTypeCollection::TypeIterator::operator-- : invalid position!");
+ OSL_ENSURE(m_nPosition >= 0, "ODsnTypeCollection::TypeIterator::operator-- : invalid position!");
if (m_nPosition >= 0)
--m_nPosition;
return *this;
@@ -627,3 +630,4 @@ bool operator==(const ODsnTypeCollection::TypeIterator& lhs, const ODsnTypeColle
} // namespace dbaccess
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/makefile.mk b/dbaccess/source/core/misc/makefile.mk
deleted file mode 100644
index 3f41bbf80fe8..000000000000
--- a/dbaccess/source/core/misc/makefile.mk
+++ /dev/null
@@ -1,60 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=misc
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/dba.pmk
-
-# --- Files -------------------------------------
-
-SLOFILES= \
- $(SLO)$/sdbcoretools.obj \
- $(SLO)$/services.obj \
- $(SLO)$/PropertyForward.obj \
- $(SLO)$/ContainerMediator.obj \
- $(SLO)$/userinformation.obj \
- $(SLO)$/ContainerListener.obj \
- $(SLO)$/objectnameapproval.obj \
- $(SLO)$/DatabaseDataProvider.obj \
- $(SLO)$/module_dba.obj \
- $(SLO)$/dsntypes.obj \
- $(SLO)$/veto.obj \
- $(SLO)$/apitools.obj \
- $(SLO)$/dbastrings.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/core/misc/module_dba.cxx b/dbaccess/source/core/misc/module_dba.cxx
index 0010927f733c..c5653e6c02b0 100644
--- a/dbaccess/source/core/misc/module_dba.cxx
+++ b/dbaccess/source/core/misc/module_dba.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -41,3 +42,4 @@ namespace dba
} // namespace sdbtools
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/objectnameapproval.cxx b/dbaccess/source/core/misc/objectnameapproval.cxx
index 50b78e386d98..3773680fe891 100644
--- a/dbaccess/source/core/misc/objectnameapproval.cxx
+++ b/dbaccess/source/core/misc/objectnameapproval.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,31 +29,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_OBJECTNAMEAPPROVAL_HXX
#include "objectnameapproval.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
#include <com/sun/star/lang/DisposedException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_TOOLS_XCONNECTIONTOOLS_HPP_
#include <com/sun/star/sdb/tools/XConnectionTools.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLEXCEPTION_HPP_
#include <com/sun/star/sdbc/SQLException.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _CPPUHELPER_WEAKREF_HXX_
#include <cppuhelper/weakref.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
//........................................................................
namespace dbaccess
@@ -114,3 +101,4 @@ namespace dbaccess
} // namespace dbaccess
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/sdbcoretools.cxx b/dbaccess/source/core/misc/sdbcoretools.cxx
index dea2328dc907..a7f21ee4a3cf 100644
--- a/dbaccess/source/core/misc/sdbcoretools.cxx
+++ b/dbaccess/source/core/misc/sdbcoretools.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -173,3 +174,4 @@ namespace dbaccess
} // namespace dbaccess
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/services.cxx b/dbaccess/source/core/misc/services.cxx
index 1853ac167ce3..61e9c65d2e59 100644
--- a/dbaccess/source/core/misc/services.cxx
+++ b/dbaccess/source/core/misc/services.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,6 +36,8 @@
#include "DatabaseDataProvider.hxx"
#include "dbadllapi.hxx"
+#include <../dataaccess/databasecontext.hxx>
+
/********************************************************************************************/
using namespace ::com::sun::star::uno;
@@ -44,7 +47,6 @@ using namespace ::com::sun::star::registry;
//***************************************************************************************
//
// registry functions
-extern "C" void SAL_CALL createRegistryInfo_ODatabaseContext();
extern "C" void SAL_CALL createRegistryInfo_OCommandDefinition();
extern "C" void SAL_CALL createRegistryInfo_OComponentDefinition();
extern "C" void SAL_CALL createRegistryInfo_ORowSet();
@@ -55,23 +57,34 @@ extern "C" void SAL_CALL createRegistryInfo_DataAccessDescriptorFactory();
namespace dba{
//--------------------------------------------------------------------------
::cppu::ImplementationEntry entries[] = {
- { &::dbaccess::DatabaseDataProvider::Create, &::dbaccess::DatabaseDataProvider::getImplementationName_Static, &::dbaccess::DatabaseDataProvider::getSupportedServiceNames_Static,
- &cppu::createSingleComponentFactory, 0, 0 },
+ {
+ &::dbaccess::DatabaseDataProvider::Create,
+ &::dbaccess::DatabaseDataProvider::getImplementationName_Static,
+ &::dbaccess::DatabaseDataProvider::getSupportedServiceNames_Static,
+ &cppu::createSingleComponentFactory, 0, 0
+ },
+
+ {
+ &dbaccess::ODatabaseContext::Create,
+ &dbaccess::ODatabaseContext::getImplementationName_static,
+ &dbaccess::ODatabaseContext::getSupportedServiceNames_static,
+ &cppu::createOneInstanceComponentFactory, 0, 0
+ },
+
{ 0, 0, 0, 0, 0, 0 }
};
}
//***************************************************************************************
//
-// Die vorgeschriebene C-Api muss erfuellt werden!
-// Sie besteht aus drei Funktionen, die von dem Modul exportiert werden muessen.
+// The prescribed C api must be complied with
+// It consists of three functions which must be exported by the module.
//
extern "C" void SAL_CALL createRegistryInfo_DBA()
{
static sal_Bool bInit = sal_False;
if (!bInit)
{
- createRegistryInfo_ODatabaseContext();
createRegistryInfo_OCommandDefinition();
createRegistryInfo_OComponentDefinition();
createRegistryInfo_ORowSet();
@@ -84,7 +97,7 @@ extern "C" void SAL_CALL createRegistryInfo_DBA()
//---------------------------------------------------------------------------------------
-extern "C" OOO_DLLPUBLIC_DBA void SAL_CALL component_getImplementationEnvironment(
+extern "C" SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char **ppEnvTypeName,
uno_Environment **
)
@@ -94,7 +107,7 @@ extern "C" OOO_DLLPUBLIC_DBA void SAL_CALL component_getImplementationEnvironmen
}
//---------------------------------------------------------------------------------------
-extern "C" OOO_DLLPUBLIC_DBA void* SAL_CALL component_getFactory(
+extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName,
void* pServiceManager,
void* pRegistryKey)
@@ -114,3 +127,5 @@ extern "C" OOO_DLLPUBLIC_DBA void* SAL_CALL component_getFactory(
pImplementationName, pServiceManager, pRegistryKey, dba::entries);
return xRet.get();
};
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/userinformation.cxx b/dbaccess/source/core/misc/userinformation.cxx
index 9143b123899b..27ea6bb51f8b 100644
--- a/dbaccess/source/core/misc/userinformation.cxx
+++ b/dbaccess/source/core/misc/userinformation.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,22 +29,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef _DBA_CORE_USERINFORMATION_HXX_
#include "userinformation.hxx"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef INCLUDED_I18NPOOL_MSLANGID_HXX
#include <i18npool/mslangid.hxx>
-#endif
-#ifndef _UTL_CONFIGMGR_HXX_
#include <unotools/configmgr.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
using namespace ::utl;
using namespace ::com::sun::star::uno;
@@ -57,3 +48,4 @@ UserInformation::UserInformation()
m_aUserLocale = MsLangId::convertLanguageToLocale(eLanguage);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/misc/veto.cxx b/dbaccess/source/core/misc/veto.cxx
index b3ab20bf9beb..ead0b705b3d6 100644
--- a/dbaccess/source/core/misc/veto.cxx
+++ b/dbaccess/source/core/misc/veto.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_VETO_HXX
#include "veto.hxx"
-#endif
/** === begin UNO includes === **/
/** === end UNO includes === **/
@@ -76,3 +75,4 @@ namespace dbaccess
} // namespace dbaccess
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/dbdocrecovery.cxx b/dbaccess/source/core/recovery/dbdocrecovery.cxx
index 6f31f17682fd..42040e4b7ae2 100644
--- a/dbaccess/source/core/recovery/dbdocrecovery.cxx
+++ b/dbaccess/source/core/recovery/dbdocrecovery.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -48,6 +49,7 @@
#include <comphelper/namedvaluecollection.hxx>
#include <rtl/ustrbuf.hxx>
#include <tools/diagnose_ex.h>
+#include <sal/macros.h>
#include <algorithm>
@@ -108,7 +110,7 @@ namespace dbaccess
const sal_Int32 nEqualSignPos = i_rIniLine.indexOf( sal_Unicode( '=' ) );
if ( nEqualSignPos < 1 )
{
- OSL_ENSURE( false, "lcl_extractCompDesc: invalid map file entry - unexpected pos of '='" );
+ OSL_FAIL( "lcl_extractCompDesc: invalid map file entry - unexpected pos of '='" );
return false;
}
o_rStorName = i_rIniLine.copy( 0, nEqualSignPos );
@@ -116,7 +118,7 @@ namespace dbaccess
const sal_Int32 nCommaPos = i_rIniLine.lastIndexOf( sal_Unicode( ',' ) );
if ( nCommaPos != i_rIniLine.getLength() - 2 )
{
- OSL_ENSURE( false, "lcl_extractCompDesc: invalid map file entry - unexpected pos of ','" );
+ OSL_FAIL( "lcl_extractCompDesc: invalid map file entry - unexpected pos of ','" );
return false;
}
o_rCompDesc.sName = i_rIniLine.copy( nEqualSignPos + 1, nCommaPos - nEqualSignPos - 1 );
@@ -197,7 +199,7 @@ namespace dbaccess
ENSURE_OR_THROW( i_rStorage.is(), "invalid storage" );
if ( !i_rStorage->hasByName( lcl_getObjectMapStreamName() ) )
{ // nothing to do, though suspicious
- OSL_ENSURE( false, "lcl_readObjectMap_throw: if there's no map file, then there's expected to be no storage, too!" );
+ OSL_FAIL( "lcl_readObjectMap_throw: if there's no map file, then there's expected to be no storage, too!" );
return;
}
@@ -230,7 +232,7 @@ namespace dbaccess
continue;
// the only section we support so far is "storages"
- if ( !sCurrentSection.equalsAscii( "storages" ) )
+ if ( !sCurrentSection.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "storages" ) ) )
{
bCurrentSectionIsKnownToBeUnsupported = true;
continue;
@@ -250,7 +252,7 @@ namespace dbaccess
const Reference< XModifiable > xModify( i_rSubComponent, UNO_QUERY );
if ( !xModify.is() )
{
- OSL_ENSURE( false, "lcl_markModified: unhandled case!" );
+ OSL_FAIL( "lcl_markModified: unhandled case!" );
return;
}
@@ -357,7 +359,7 @@ namespace dbaccess
// read the map from sub storages to object names
MapCompTypeToCompDescs aMapCompDescs;
SubComponentType aKnownTypes[] = { TABLE, QUERY, FORM, REPORT, RELATION_DESIGN };
- for ( size_t i = 0; i < sizeof( aKnownTypes ) / sizeof( aKnownTypes[0] ); ++i )
+ for ( size_t i = 0; i < SAL_N_ELEMENTS( aKnownTypes ); ++i )
{
if ( !xRecoveryStorage->hasByName( SubComponentRecovery::getComponentsStorageName( aKnownTypes[i] ) ) )
continue;
@@ -396,7 +398,7 @@ namespace dbaccess
message.append( "' not found in '" );
message.append( ::rtl::OUStringToOString( SubComponentRecovery::getComponentsStorageName( eComponentType ), RTL_TEXTENCODING_ASCII_US ) );
message.append( "', but required per map file!" );
- OSL_ENSURE( false, message.makeStringAndClear() );
+ OSL_FAIL( message.makeStringAndClear() );
#endif
continue;
}
@@ -434,3 +436,5 @@ namespace dbaccess
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/makefile.mk b/dbaccess/source/core/recovery/makefile.mk
deleted file mode 100644
index c13334bbc9d9..000000000000
--- a/dbaccess/source/core/recovery/makefile.mk
+++ /dev/null
@@ -1,58 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2008 by Sun Microsystems, Inc.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# $RCSfile: makefile.mk,v $
-#
-# $Revision: 1.10.2.3 $
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=recovery
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/dba.pmk
-
-# --- Files -------------------------------------
-
-SLOFILES= \
- $(SLO)$/dbdocrecovery.obj \
- $(SLO)$/subcomponentloader.obj \
- $(SLO)$/storagestream.obj \
- $(SLO)$/storagexmlstream.obj \
- $(SLO)$/storagetextstream.obj \
- $(SLO)$/subcomponentrecovery.obj \
- $(SLO)$/settingsimport.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/core/recovery/settingsimport.cxx b/dbaccess/source/core/recovery/settingsimport.cxx
index 566bf42ae847..397c97eeb34c 100644
--- a/dbaccess/source/core/recovery/settingsimport.cxx
+++ b/dbaccess/source/core/recovery/settingsimport.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -117,7 +118,7 @@ namespace dbaccess
o_rLocalName = i_rElementName.copy( nSeparatorPos + 1 );
}
- OSL_ENSURE( o_rNamespace.equalsAscii( "config" ), "SettingsImport::split: unexpected namespace!" );
+ OSL_ENSURE( o_rNamespace.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "config" ) ), "SettingsImport::split: unexpected namespace!" );
// our recovery file is kind of hand-made, so there shouldn't be anything else than "config".
// If there is, then just ignore it ...
}
@@ -154,14 +155,14 @@ namespace dbaccess
::rtl::OUString sLocalName;
split( i_rElementName, sNamespace, sLocalName );
- if ( sLocalName.equalsAscii( "config-item-set" ) )
+ if ( sLocalName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "config-item-set" ) ) )
return new ConfigItemSetImport( m_rSettings );
#if OSL_DEBUG_LEVEL > 0
::rtl::OString sMessage( "unknown (or unsupported at this place) element name '" );
sMessage += ::rtl::OUStringToOString( i_rElementName, RTL_TEXTENCODING_UTF8 );
sMessage += "', ignoring";
- OSL_ENSURE( false, sMessage.getStr() );
+ OSL_FAIL( sMessage.getStr() );
#endif
return new IgnoringSettingsImport;
}
@@ -183,7 +184,7 @@ namespace dbaccess
//--------------------------------------------------------------------
::rtl::Reference< SettingsImport > ConfigItemImport::nextState( const ::rtl::OUString& i_rElementName )
{
- OSL_ENSURE( false, "ConfigItemImport::nextState: unexpected: this class is responsible for child-less items only!" );
+ OSL_FAIL( "ConfigItemImport::nextState: unexpected: this class is responsible for child-less items only!" );
(void)i_rElementName;
return new IgnoringSettingsImport;
}
@@ -219,17 +220,17 @@ namespace dbaccess
o_rValue <<= nValue;
else
{
- OSL_ENSURE( false, "ConfigItemImport::getItemValue: could not convert an int value!" );
+ OSL_FAIL( "ConfigItemImport::getItemValue: could not convert an int value!" );
}
}
else if ( ::xmloff::token::IsXMLToken( rItemType, ::xmloff::token::XML_BOOLEAN ) )
{
- sal_Bool nValue( sal_False );
+ bool nValue( sal_False );
if ( SvXMLUnitConverter::convertBool( nValue, sValue ) )
o_rValue <<= nValue;
else
{
- OSL_ENSURE( false, "ConfigItemImport::getItemValue: could not convert a boolean value!" );
+ OSL_FAIL( "ConfigItemImport::getItemValue: could not convert a boolean value!" );
}
}
else if ( ::xmloff::token::IsXMLToken( rItemType, ::xmloff::token::XML_STRING ) )
@@ -242,7 +243,7 @@ namespace dbaccess
::rtl::OString sMessage( "ConfigItemImport::getItemValue: unsupported item type '" );
sMessage += ::rtl::OUStringToOString( rItemType, RTL_TEXTENCODING_UTF8 );
sMessage += "', ignoring";
- OSL_ENSURE( false, sMessage.getStr() );
+ OSL_FAIL( sMessage.getStr() );
}
#endif
}
@@ -269,16 +270,16 @@ namespace dbaccess
::rtl::OUString sLocalName;
split( i_rElementName, sNamespace, sLocalName );
- if ( sLocalName.equalsAscii( "config-item-set" ) )
+ if ( sLocalName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "config-item-set" ) ) )
return new ConfigItemSetImport( m_aChildSettings );
- if ( sLocalName.equalsAscii( "config-item" ) )
+ if ( sLocalName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "config-item" ) ) )
return new ConfigItemImport( m_aChildSettings );
#if OSL_DEBUG_LEVEL > 0
::rtl::OString sMessage( "unknown element name '" );
sMessage += ::rtl::OUStringToOString( i_rElementName, RTL_TEXTENCODING_UTF8 );
sMessage += "', ignoring";
- OSL_ENSURE( false, sMessage.getStr() );
+ OSL_FAIL( sMessage.getStr() );
#endif
return new IgnoringSettingsImport;
}
@@ -292,3 +293,5 @@ namespace dbaccess
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/settingsimport.hxx b/dbaccess/source/core/recovery/settingsimport.hxx
index 3415092ee93a..1101ce0cd0cc 100644
--- a/dbaccess/source/core/recovery/settingsimport.hxx
+++ b/dbaccess/source/core/recovery/settingsimport.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -188,3 +189,5 @@ namespace dbaccess
//........................................................................
#endif // SETTINGSIMPORT_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/storagestream.cxx b/dbaccess/source/core/recovery/storagestream.cxx
index ec6ff49a6098..7c5589f864f6 100644
--- a/dbaccess/source/core/recovery/storagestream.cxx
+++ b/dbaccess/source/core/recovery/storagestream.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -124,3 +125,5 @@ namespace dbaccess
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/storagestream.hxx b/dbaccess/source/core/recovery/storagestream.hxx
index 2485cfac24cb..4f724a93e906 100644
--- a/dbaccess/source/core/recovery/storagestream.hxx
+++ b/dbaccess/source/core/recovery/storagestream.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -107,3 +108,5 @@ namespace dbaccess
//........................................................................
#endif // STORAGESTREAM_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/storagetextstream.cxx b/dbaccess/source/core/recovery/storagetextstream.cxx
index af1b832b67b3..b034b95b60a3 100644
--- a/dbaccess/source/core/recovery/storagetextstream.cxx
+++ b/dbaccess/source/core/recovery/storagetextstream.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -128,3 +129,5 @@ namespace dbaccess
//......................................................................................................................
} // namespace dbaccess
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/storagetextstream.hxx b/dbaccess/source/core/recovery/storagetextstream.hxx
index 08d02008f1a4..5283687ce163 100644
--- a/dbaccess/source/core/recovery/storagetextstream.hxx
+++ b/dbaccess/source/core/recovery/storagetextstream.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -64,3 +65,5 @@ namespace dbaccess
//......................................................................................................................
#endif // STORAGETEXTSTREAM_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/storagexmlstream.cxx b/dbaccess/source/core/recovery/storagexmlstream.cxx
index 8405cce75903..3e65d79387e7 100644
--- a/dbaccess/source/core/recovery/storagexmlstream.cxx
+++ b/dbaccess/source/core/recovery/storagexmlstream.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -195,3 +196,5 @@ namespace dbaccess
//......................................................................................................................
} // namespace dbaccess
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/storagexmlstream.hxx b/dbaccess/source/core/recovery/storagexmlstream.hxx
index 10a8aaaed5de..d14d9b62bc12 100644
--- a/dbaccess/source/core/recovery/storagexmlstream.hxx
+++ b/dbaccess/source/core/recovery/storagexmlstream.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -111,3 +112,5 @@ namespace dbaccess
//........................................................................
#endif // STORAGEXMLSTREAM_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/subcomponentloader.cxx b/dbaccess/source/core/recovery/subcomponentloader.cxx
index 5fd120a5009b..48debe206c73 100644
--- a/dbaccess/source/core/recovery/subcomponentloader.cxx
+++ b/dbaccess/source/core/recovery/subcomponentloader.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -198,3 +199,5 @@ namespace dbaccess
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/subcomponentloader.hxx b/dbaccess/source/core/recovery/subcomponentloader.hxx
index f3bec5b6b39e..30922c9d71d9 100644
--- a/dbaccess/source/core/recovery/subcomponentloader.hxx
+++ b/dbaccess/source/core/recovery/subcomponentloader.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -85,3 +86,5 @@ namespace dbaccess
//........................................................................
#endif // SUBCOMPONENTLOADER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/subcomponentrecovery.cxx b/dbaccess/source/core/recovery/subcomponentrecovery.cxx
index 0ae69402faeb..3ec74ecbb93d 100644
--- a/dbaccess/source/core/recovery/subcomponentrecovery.cxx
+++ b/dbaccess/source/core/recovery/subcomponentrecovery.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -117,7 +118,7 @@ namespace dbaccess
break;
}
- OSL_ENSURE( false, "lcl_getComponentStorageBaseName: unimplemented case!" );
+ OSL_FAIL( "lcl_getComponentStorageBaseName: unimplemented case!" );
static const ::rtl::OUString s_sFallback;
return s_sFallback;
}
@@ -334,13 +335,13 @@ namespace dbaccess
if ( m_aStates.empty() )
{
- if ( i_Name.equalsAscii( "office:settings" ) )
+ if ( i_Name.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "office:settings" ) ) )
{
pNewState = new OfficeSettingsImport( m_aSettings );
}
else
{
- OSL_ENSURE( false, "SettingsDocumentHandler::startElement: invalid settings file!" );
+ OSL_FAIL( "SettingsDocumentHandler::startElement: invalid settings file!" );
// Yes, that's not correct. Somebody could, in theory, give us a document which starts with "foo:settings",
// where "foo" is mapped to the proper namespace URL.
// However, there's no need to bother with this. The "recovery" sub storage we're recovering from is
@@ -389,7 +390,7 @@ namespace dbaccess
//--------------------------------------------------------------------
void SAL_CALL SettingsDocumentHandler::processingInstruction( const ::rtl::OUString& i_Target, const ::rtl::OUString& i_Data ) throw (SAXException, RuntimeException)
{
- OSL_ENSURE( false, "SettingsDocumentHandler::processingInstruction: unexpected ..." );
+ OSL_FAIL( "SettingsDocumentHandler::processingInstruction: unexpected ..." );
(void)i_Target;
(void)i_Data;
}
@@ -428,7 +429,7 @@ namespace dbaccess
break;
}
- OSL_ENSURE( false, "SubComponentRecovery::getComponentsStorageName: unimplemented case!" );
+ OSL_FAIL( "SubComponentRecovery::getComponentsStorageName: unimplemented case!" );
static const ::rtl::OUString s_sFallback;
return s_sFallback;
}
@@ -465,7 +466,7 @@ namespace dbaccess
default:
// TODO
- OSL_ENSURE( false, "SubComponentRecoverys::saveToRecoveryStorage: unimplemented case!" );
+ OSL_FAIL( "SubComponentRecoverys::saveToRecoveryStorage: unimplemented case!" );
break;
}
@@ -495,17 +496,17 @@ namespace dbaccess
switch ( m_eType )
{
case TABLE:
- m_aCompDesc.bForEditing = sModuleIdentifier.equalsAscii( "com.sun.star.sdb.TableDesign" );
+ m_aCompDesc.bForEditing = sModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sdb.TableDesign" ) );
break;
case QUERY:
- m_aCompDesc.bForEditing = sModuleIdentifier.equalsAscii( "com.sun.star.sdb.QueryDesign" );
+ m_aCompDesc.bForEditing = sModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sdb.QueryDesign" ) );
break;
case REPORT:
- if ( sModuleIdentifier.equalsAscii( "com.sun.star.report.ReportDefinition" ) )
+ if ( sModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.report.ReportDefinition" ) ) )
{
- // it's an SRB report desginer
+ // it's an SRB report designer
m_aCompDesc.bForEditing = true;
break;
}
@@ -516,14 +517,14 @@ namespace dbaccess
break;
default:
- if ( sModuleIdentifier.equalsAscii( "com.sun.star.sdb.RelationDesign" ) )
+ if ( sModuleIdentifier.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "com.sun.star.sdb.RelationDesign" ) ) )
{
m_eType = RELATION_DESIGN;
m_aCompDesc.bForEditing = true;
}
else
{
- OSL_ENSURE( false, "SubComponentRecovery::impl_identifyComponent_throw: couldn't classify the given sub component!" );
+ OSL_FAIL( "SubComponentRecovery::impl_identifyComponent_throw: couldn't classify the given sub component!" );
}
break;
}
@@ -691,7 +692,7 @@ namespace dbaccess
xSubComponent = impl_recoverQueryDesign_throw( i_rRecoveryStorage, i_rComponentName, i_bForEditing );
break;
default:
- OSL_ENSURE( false, "SubComponentRecovery::recoverFromStorage: unimplemented case!" );
+ OSL_FAIL( "SubComponentRecovery::recoverFromStorage: unimplemented case!" );
break;
}
return xSubComponent;
@@ -700,3 +701,5 @@ namespace dbaccess
//........................................................................
} // namespace dbaccess
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/subcomponentrecovery.hxx b/dbaccess/source/core/recovery/subcomponentrecovery.hxx
index 2cec262937a8..cb5519cf5c77 100644
--- a/dbaccess/source/core/recovery/subcomponentrecovery.hxx
+++ b/dbaccess/source/core/recovery/subcomponentrecovery.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -124,3 +125,5 @@ namespace dbaccess
//........................................................................
#endif // SUBCOMPONENTRECOVERY_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/recovery/subcomponents.hxx b/dbaccess/source/core/recovery/subcomponents.hxx
index d1ba0ccb1966..28e751d0693c 100644
--- a/dbaccess/source/core/recovery/subcomponents.hxx
+++ b/dbaccess/source/core/recovery/subcomponents.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -34,7 +35,7 @@
#include <rtl/ustring.hxx>
-#include <hash_map>
+#include <boost/unordered_map.hpp>
#include <map>
//........................................................................
@@ -77,7 +78,7 @@ namespace dbaccess
};
// -------------------------------------------------------------------
- typedef ::std::hash_map< ::rtl::OUString, SubComponentDescriptor, ::rtl::OUStringHash > MapStringToCompDesc;
+ typedef ::boost::unordered_map< ::rtl::OUString, SubComponentDescriptor, ::rtl::OUStringHash > MapStringToCompDesc;
typedef ::std::map< SubComponentType, MapStringToCompDesc > MapCompTypeToCompDescs;
@@ -86,3 +87,5 @@ namespace dbaccess
//........................................................................
#endif // SUBCOMPONENTS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/resource/core_resource.cxx b/dbaccess/source/core/resource/core_resource.cxx
index f2efb811418d..d197fe66eb20 100644
--- a/dbaccess/source/core/resource/core_resource.cxx
+++ b/dbaccess/source/core/resource/core_resource.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,14 +34,10 @@
#include <tools/resmgr.hxx>
// ---- needed as long as we have no contexts for components ---
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
//---------------------------------------------------
-#ifndef _SOLAR_HRC
#include <svl/solar.hrc>
-#endif
//.........................................................................
namespace dbaccess
@@ -117,3 +114,4 @@ namespace dbaccess
}
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/core/resource/makefile.mk b/dbaccess/source/core/resource/makefile.mk
deleted file mode 100644
index 293b92b5e4cf..000000000000
--- a/dbaccess/source/core/resource/makefile.mk
+++ /dev/null
@@ -1,48 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=core_resource
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/dba.pmk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=core_strings
-SRC1FILES= \
- strings.src \
-
-SLOFILES= $(SLO)$/core_resource.obj \
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
diff --git a/dbaccess/source/core/resource/strings.src b/dbaccess/source/core/resource/strings.src
index dd1ca4c8a184..1a572c8a151f 100644
--- a/dbaccess/source/core/resource/strings.src
+++ b/dbaccess/source/core/resource/strings.src
@@ -32,6 +32,7 @@ String RID_STR_TRIED_OPEN_TABLE
{
Text [ en-US ] = "Tried to open the table $name$.";
};
+
String RID_STR_CONNECTION_INVALID
{
Text [ en-US ] = "No connection could be established.";
@@ -47,7 +48,6 @@ String RID_STR_NEED_CONFIG_WRITE_ACCESS
Text [ en-US ] = "You have no write access to the configuration data the object is based on.";
};
-
String RID_STR_COULDNOTCONNECT_UNSPECIFIED
{
Text [ en-US ] = "The connection to the external data source could not be established. An unknown error occurred. The driver is probably defective.";
@@ -77,106 +77,132 @@ String RID_STR_DATASOURCE_NOT_STORED
{
Text [ en-US ] = "The data source was not saved. Please use the interface XStorable to save the data source.";
};
+
String RID_STR_ONLY_QUERY
{
Text [ en-US ] = "The given command is not a SELECT statement.\nOnly queries are allowed.";
};
+
String RID_STR_NO_VALUE_CHANGED
{
Text [ en-US ] = "No values were modified.";
};
+
String RID_STR_NO_XROWUPDATE
{
Text [ en-US ] = "Values could not be inserted. The XRowUpdate interface is not supported by ResultSet.";
};
+
String RID_STR_NO_XRESULTSETUPDATE
{
Text [ en-US ] = "Values could not be inserted. The XResultSetUpdate interface is not supported by ResultSet.";
};
+
String RID_STR_NO_UPDATE_MISSING_CONDITION
{
Text [ en-US ] = "Values could not be modified, due to a missing condition statement.";
};
+
String RID_STR_NO_COLUMN_ADD
{
Text [ en-US ] = "The adding of columns is not supported.";
};
+
String RID_STR_NO_COLUMN_DROP
{
Text [ en-US ] = "The dropping of columns is not supported.";
};
+
String RID_STR_NO_CONDITION_FOR_PK
{
Text [ en-US ] = "The WHERE condition could not be created for the primary key.";
};
+
String RID_STR_COLUMN_UNKNOWN_PROP
{
Text [ en-US ] = "The column does not support the property '%value'.";
};
+
String RID_STR_COLUMN_NOT_SEARCHABLE
{
Text [ en-US ] = "The column is not searchable!";
};
+
String RID_STR_NOT_SEQUENCE_INT8
{
Text [ en-US ] = "The value of the columns is not of the type Sequence<sal_Int8>.";
};
+
String RID_STR_COLUMN_NOT_VALID
{
Text [ en-US ] = "The column is not valid.";
};
+
String RID_STR_COLUMN_MUST_VISIBLE
{
Text [ en-US ] = "The column '%name' must be visible as a column.";
};
+
String RID_STR_NO_XQUERIESSUPPLIER
{
Text [ en-US ] = "The interface XQueriesSupplier is not available.";
};
+
String RID_STR_NOT_SUPPORTED_BY_DRIVER
{
Text [ en-US ] = "The driver does not support this function.";
};
+
String RID_STR_NO_ABS_ZERO
{
Text [ en-US ] = "An 'absolute(0)' call is not allowed.";
};
+
String RID_STR_NO_RELATIVE
{
Text [ en-US ] = "Relative positioning is not allowed in this state.";
};
+
String RID_STR_NO_REFESH_AFTERLAST
{
Text [ en-US ] = "A row cannot be refreshed when the ResultSet is positioned after the last row.";
};
+
String RID_STR_NO_MOVETOINSERTROW_CALLED
{
Text [ en-US ] = "A new row cannot be inserted when the ResultSet is not first moved to the insert row.";
};
+
String RID_STR_NO_UPDATEROW
{
Text [ en-US ] = "A row cannot be modified in this state";
};
+
String RID_STR_NO_DELETEROW
{
Text [ en-US ] = "A row cannot be deleted in this state.";
};
+
String RID_STR_NO_TABLE_RENAME
{
Text [ en-US ] = "The driver does not support table renaming.";
};
+
String RID_STR_NO_ALTER_COLUMN_DEF
{
Text [ en-US ] = "The driver does not support the modification of column descriptions.";
};
+
String RID_STR_COLUMN_ALTER_BY_NAME
{
Text [ en-US ] = "The driver does not support the modification of column descriptions by changing the name.";
};
+
String RID_STR_COLUMN_ALTER_BY_INDEX
{
Text [ en-US ] = "The driver does not support the modification of column descriptions by changing the index.";
};
+
String RID_STR_FILE_DOES_NOT_EXIST
{
Text[ en-US ] = "The file \"$file$\" does not exist.";
@@ -200,7 +226,6 @@ String RID_STR_CONFLICTING_NAMES
String RID_STR_COMMAND_LEADING_TO_ERROR
{
Text [ en-US ] = "The SQL command leading to this error is:\n\n$command$";
-
};
String RID_STR_STATEMENT_WITHOUT_RESULT_SET
@@ -247,79 +272,99 @@ String RID_NO_SUCH_DATA_SOURCE
{
Text [ en-US ] = "Error accessing data source '$name$':\n$error$";
};
+
String RID_STR_NO_SUB_FOLDER
{
Text [ en-US ] = "There exists no folder named \"$folder$\".";
};
+
String RID_STR_NO_DELETE_BEFORE_AFTER
{
Text [ en-US ] = "Cannot delete the before-first or after-last row.";
};
+
String RID_STR_NO_DELETE_INSERT_ROW
{
Text [ en-US ] = "Cannot delete the insert-row.";
};
+
String RID_STR_RESULT_IS_READONLY
{
Text [ en-US ] = "Result set is read only.";
};
+
String RID_STR_NO_DELETE_PRIVILEGE
{
Text [ en-US ] = "DELETE privilege not available.";
};
+
String RID_STR_ROW_ALREADY_DELETED
{
Text [ en-US ] = "Current row is already deleted.";
};
+
String RID_STR_UPDATE_FAILED
{
Text [ en-US ] = "Current row could not be updated.";
};
+
//-------------------------------------------------------------------------
+
String RID_STR_NO_INSERT_PRIVILEGE
{
Text [ en-US ] = "INSERT privilege not available.";
};
+
String RID_STR_INTERNAL_ERROR
{
Text [ en-US ] = "Internal error: no statement object provided by the database driver.";
};
+
String RID_STR_EXPRESSION1
{
Text [ en-US ] = "Expression1";
};
+
String RID_STR_NO_SQL_COMMAND
{
Text [ en-US ] = "No SQL command was provided.";
};
+
String RID_STR_INVALID_INDEX
{
Text [ en-US ] = "Invalid column index.";
};
+
String RID_STR_INVALID_CURSOR_STATE
{
Text [ en-US ] = "Invalid cursor state.";
};
+
String RID_STR_CURSOR_BEFORE_OR_AFTER
{
Text [ en-US ] = "The cursor points to before the first or after the last row.";
};
+
String RID_STR_NO_BOOKMARK_BEFORE_OR_AFTER
{
Text [ en-US ] = "The rows before the first and after the last row don't have a bookmark.";
};
+
String RID_STR_NO_BOOKMARK_DELETED
{
Text [ en-US ] = "The current row is deleted, and thus doesn't have a bookmark.";
};
+
String RID_STR_NO_EMBEDDING
{
Text [ en-US ] = "Embedding of database documents is not supported.";
};
+
String RID_STR_CONNECTION_REQUEST
{
Text [ en-US ] = "A connection for the following URL was requested \"$name$\".";
};
+
String RID_STR_MISSING_EXTENSION
{
Text [ en-US ] = "The extension is not installed.";
diff --git a/dbaccess/source/ext/adabas/ANewDb.cxx b/dbaccess/source/ext/adabas/ANewDb.cxx
index 1b2f5a50e588..38311fde9076 100644
--- a/dbaccess/source/ext/adabas/ANewDb.cxx
+++ b/dbaccess/source/ext/adabas/ANewDb.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,24 +26,12 @@
*
************************************************************************/
-#ifndef ADABASUI_NEWDB_HXX
#include "ANewDb.hxx"
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef adabasui_ADABAS_CREATEDB_HXX
#include "AdabasNewDb.hxx"
-#endif
-#ifndef adabasui_SHARED_DBUSTRINGS_HRC
#include "adabasuistrings.hrc"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
using namespace adabasui;
using namespace dbtools;
@@ -98,7 +87,7 @@ Reference< XInterface > SAL_CALL OAdabasCreateDialog::Create(const Reference< XM
//-------------------------------------------------------------------------
::rtl::OUString OAdabasCreateDialog::getImplementationName_Static() throw(RuntimeException)
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.adabasui.AdabasCreateDialog");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.adabasui.AdabasCreateDialog"));
}
//-------------------------------------------------------------------------
@@ -111,7 +100,7 @@ Reference< XInterface > SAL_CALL OAdabasCreateDialog::Create(const Reference< XM
::comphelper::StringSequence OAdabasCreateDialog::getSupportedServiceNames_Static() throw(RuntimeException)
{
::comphelper::StringSequence aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.AdabasCreationDialog");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.AdabasCreationDialog"));
return aSupported;
}
@@ -159,3 +148,4 @@ void OAdabasCreateDialog::executedDialog(sal_Int16 _nExecutionResult)
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/ANewDb.hxx b/dbaccess/source/ext/adabas/ANewDb.hxx
index 46de53c1fcaf..cf725930dd0a 100644
--- a/dbaccess/source/ext/adabas/ANewDb.hxx
+++ b/dbaccess/source/ext/adabas/ANewDb.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,15 +30,9 @@
#ifndef ADABASUI_NEWDB_HXX
#define ADABASUI_NEWDB_HXX
-#ifndef _SVT_GENERICUNODIALOG_HXX_
#include <svtools/genericunodialog.hxx>
-#endif
-#ifndef _EXTENSIONS_COMPONENT_MODULE_HXX_
#include "Acomponentmodule.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCREATECATALOG_HPP_
#include <com/sun/star/sdbcx/XCreateCatalog.hpp>
-#endif
@@ -98,3 +93,5 @@ namespace adabasui
//.........................................................................
#endif // ADABASUI_NEWDB_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/ASQLNameEdit.hxx b/dbaccess/source/ext/adabas/ASQLNameEdit.hxx
index e434eff9ee64..be2c27acf9d9 100644
--- a/dbaccess/source/ext/adabas/ASQLNameEdit.hxx
+++ b/dbaccess/source/ext/adabas/ASQLNameEdit.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef ADABASUI_SQLNAMEEDIT_HXX
#define ADABASUI_SQLNAMEEDIT_HXX
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _SV_COMBOBOX_HXX
#include <vcl/combobox.hxx>
-#endif
namespace adabasui
{
@@ -59,3 +56,4 @@ namespace adabasui
#endif // DBAUI_SQLNAMEEDIT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/ASqlNameEdit.cxx b/dbaccess/source/ext/adabas/ASqlNameEdit.cxx
index e0fd807982e6..4745568c69e8 100644
--- a/dbaccess/source/ext/adabas/ASqlNameEdit.cxx
+++ b/dbaccess/source/ext/adabas/ASqlNameEdit.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,9 +26,7 @@
*
************************************************************************/
-#ifndef ADABASUI_SQLNAMEEDIT_HXX
#include "ASQLNameEdit.hxx"
-#endif
namespace adabasui
{
//------------------------------------------------------------------
@@ -78,3 +77,4 @@ namespace adabasui
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/Acomponentmodule.cxx b/dbaccess/source/ext/adabas/Acomponentmodule.cxx
index 4a0661fff228..6f153937fe2f 100644
--- a/dbaccess/source/ext/adabas/Acomponentmodule.cxx
+++ b/dbaccess/source/ext/adabas/Acomponentmodule.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -26,22 +27,12 @@
************************************************************************/
-#ifndef _EXTENSIONS_COMPONENT_MODULE_HXX_
#include "Acomponentmodule.hxx"
-#endif
-#ifndef _TOOLS_RESMGR_HXX
#include <tools/resmgr.hxx>
-#endif
-#ifndef _SOLAR_HRC
#include <svl/solar.hrc>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
+#include <osl/diagnose.h>
#define ENTER_MOD_METHOD() \
::osl::MutexGuard aGuard(s_aMutex); \
@@ -99,12 +90,12 @@ namespace COMPMOD_NAMESPACE
// note that this method is not threadsafe, which counts for the whole class !
if (!m_pRessources && !m_bInitialized)
{
- DBG_ASSERT(m_sFilePrefix.Len(), "OModuleImpl::getResManager: no resource file prefix!");
+ OSL_ENSURE(m_sFilePrefix.Len(), "OModuleImpl::getResManager: no resource file prefix!");
// create a manager with a fixed prefix
ByteString aMgrName = m_sFilePrefix;
m_pRessources = ResMgr::CreateResMgr(aMgrName.GetBuffer());
- DBG_ASSERT(m_pRessources,
+ OSL_ENSURE(m_pRessources,
(ByteString("OModuleImpl::getResManager: could not create the resource manager (file name: ")
+= aMgrName
+= ByteString(")!")).GetBuffer());
@@ -214,7 +205,7 @@ namespace COMPMOD_NAMESPACE
{
if (!s_pImplementationNames)
{
- OSL_ASSERT("OModule::revokeComponent : have no class infos ! Are you sure called this method at the right time ?");
+ OSL_FAIL("OModule::revokeComponent : have no class infos ! Are you sure called this method at the right time ?");
return;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
@@ -257,7 +248,7 @@ namespace COMPMOD_NAMESPACE
if (!s_pImplementationNames)
{
- OSL_ASSERT("OModule::getComponentFactory : have no class infos ! Are you sure called this method at the right time ?");
+ OSL_FAIL("OModule::getComponentFactory : have no class infos ! Are you sure called this method at the right time ?");
return NULL;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
@@ -301,3 +292,4 @@ namespace COMPMOD_NAMESPACE
} // namespace COMPMOD_NAMESPACE
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/Acomponentmodule.hxx b/dbaccess/source/ext/adabas/Acomponentmodule.hxx
index 380b9571509f..7625ca26e810 100644
--- a/dbaccess/source/ext/adabas/Acomponentmodule.hxx
+++ b/dbaccess/source/ext/adabas/Acomponentmodule.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -36,30 +37,14 @@
which should be used as namespace for the classes defined herein.</p>
*/
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _TOOLS_RESID_HXX
#include <tools/resid.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_REGISTRY_XREGISTRYKEY_HPP_
#include <com/sun/star/registry/XRegistryKey.hpp>
-#endif
-#ifndef _CPPUHELPER_FACTORY_HXX_
#include <cppuhelper/factory.hxx>
-#endif
-#ifndef _RTL_STRING_HXX_
#include <rtl/string.hxx>
-#endif
class ResMgr;
@@ -277,3 +262,4 @@ typedef ::com::sun::star::uno::Reference< ::com::sun::star::lang::XSingleService
#endif // _EXTENSIONS_COMPONENT_MODULE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/AdabasNewDb.cxx b/dbaccess/source/ext/adabas/AdabasNewDb.cxx
index 4bbc9d12cca7..0438e4ae00dd 100644
--- a/dbaccess/source/ext/adabas/AdabasNewDb.cxx
+++ b/dbaccess/source/ext/adabas/AdabasNewDb.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,95 +26,39 @@
*
************************************************************************/
-#ifndef adabasui_ADABAS_CREATEDB_HXX
#include "AdabasNewDb.hxx"
-#endif
-#ifndef adabasui_ADABASNEWDB_HRC
#include "AdabasNewDb.hrc"
-#endif
-#ifndef _VOS_PROCESS_HXX_
-#include <vos/process.hxx>
-#endif
-#ifndef _OSL_PROCESS_H_
#include <osl/process.h>
-#endif
-#ifndef _MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _PASSWD_HXX //autogen
#include <sfx2/passwd.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef _STREAM_HXX
#include <tools/stream.hxx>
-#endif
-#ifndef _BIGINT_HXX
#include <tools/bigint.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _EXTENSIONS_COMPONENT_MODULE_HXX_
#include "Acomponentmodule.hxx"
-#endif
-#ifndef _UNOTOOLS_TEMPFILE_HXX
#include <unotools/tempfile.hxx>
-#endif
-#ifndef _ADABASUI_RESOURCE_HRC_
#include "adabasui_resource.hrc"
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
#include <unotools/pathoptions.hxx>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/unohlp.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _UNOTOOLS_TEMPFILE_HXX
#include <unotools/tempfile.hxx>
-#endif
-#ifndef _UNOTOOLS_LOCALFILEHELPER_HXX
#include <unotools/localfilehelper.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLEXCEPTION_HPP_
#include <com/sun/star/sdbc/SQLException.hpp>
-#endif
-#ifndef _UNOTOOLS_UCBHELPER_HXX
#include <unotools/ucbhelper.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
#include "adabasuistrings.hrc"
-#ifndef _THREAD_HXX_
#include <osl/thread.hxx>
-#endif
-#ifndef _OSL_FILE_HXX_
#include <osl/file.hxx>
-#endif
using namespace adabasui;
using namespace ucbhelper;
using namespace utl;
-using namespace vos;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::sdbcx;
@@ -162,7 +107,6 @@ namespace adabasui
catch(Exception&)
{
OSL_ASSERT(0);
- // showError(::dbtools::SQLExceptionInfo(e),this,);
}
}
void SAL_CALL ODatabaseCreator::onTerminated()
@@ -271,8 +215,6 @@ OAdabasNewDbDlg::OAdabasNewDbDlg( Window* pParent,
m_ET_CONUSR.SetModifyHdl( LINK(this,OAdabasNewDbDlg,LoseFocusHdl));
m_ET_DOMAIN_USR.Enable(sal_False);
- // m_ET_SYSUSR.setUpperCase();
- // m_ET_CONUSR.setUpperCase();
}
@@ -304,7 +246,7 @@ OAdabasNewDbDlg::OAdabasNewDbDlg( Window* pParent,
m_NF_DATADEVSPACE_SIZE.SetDecimalDigits(0);
m_NF_CACHE_SIZE.SetDecimalDigits(0);
- m_ET_DATABASENAME.SetMaxTextLen( 8 ); //98292
+ m_ET_DATABASENAME.SetMaxTextLen( 8 );
m_PB_CONPWD.SetClickHdl( LINK(this,OAdabasNewDbDlg,PwdClickHdl));
m_PB_SYSPWD.SetClickHdl( LINK(this,OAdabasNewDbDlg,PwdClickHdl));
@@ -803,3 +745,5 @@ sal_Bool OAdabasNewDbDlg::fillEnvironmentVariable(const ::rtl::OUString& _sVaria
return bError;
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/AdabasNewDb.hxx b/dbaccess/source/ext/adabas/AdabasNewDb.hxx
index 89db7be31eb4..224c175ccd3f 100644
--- a/dbaccess/source/ext/adabas/AdabasNewDb.hxx
+++ b/dbaccess/source/ext/adabas/AdabasNewDb.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,31 +30,15 @@
#define ADABASUI_ADABAS_CREATEDB_HXX
-#ifndef _SV_DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _SV_FIELD_HXX
#include <vcl/field.hxx>
-#endif
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCREATECATALOG_HPP_
#include <com/sun/star/sdbcx/XCreateCatalog.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _FILEDLGHELPER_HXX
#include <sfx2/filedlghelper.hxx>
-#endif
#include <memory>
#include "ASQLNameEdit.hxx"
@@ -163,3 +148,4 @@ namespace adabasui
}
#endif // adabasui_ADABAS_CREATEDB_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/AdabasNewDb.src b/dbaccess/source/ext/adabas/AdabasNewDb.src
index 33915b06266b..efe5879cef80 100644
--- a/dbaccess/source/ext/adabas/AdabasNewDb.src
+++ b/dbaccess/source/ext/adabas/AdabasNewDb.src
@@ -51,7 +51,8 @@ ModalDialog DLG_ADABAS_NEWDB
Pos = MAP_APPFONT ( 12 , 6) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 10 ) ;
Text[ en-US ] = "Database ~name";
-};
+ };
+
Edit ET_DATABASENAME
{
Border = TRUE ;
@@ -66,26 +67,28 @@ ModalDialog DLG_ADABAS_NEWDB
Pos = MAP_APPFONT ( 6 , 3 + MOVE_Y) ;
Size = MAP_APPFONT ( WIN_X - 12 , 8 ) ;
Text[ en-US ] = "User settings";
-};
+ };
FixedText FT_CONUSR
{
Pos = MAP_APPFONT ( 12 , 31 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 10 ) ;
Text[ en-US ] = "~Control user";
-};
+ };
+
FixedText FT_SYSUSR
{
Pos = MAP_APPFONT ( 12 , 14 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 10 ) ;
Text[ en-US ] = "~Administrator";
-};
+ };
+
FixedText FT_DOMAIN_USR
{
Pos = MAP_APPFONT ( 12 , 48 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 10 ) ;
Text[ en-US ] = "~Domain user";
-};
+ };
Edit ET_SYSUSR
{
@@ -103,7 +106,7 @@ ModalDialog DLG_ADABAS_NEWDB
TabStop = TRUE ;
HelpID = HID_DLG_ADABAS_SYSPWD ;
Text[ en-US ] = "P~assword...";
-};
+ };
Edit ET_CONUSR
{
@@ -121,7 +124,8 @@ ModalDialog DLG_ADABAS_NEWDB
TabStop = TRUE ;
HelpID = HID_DLG_ADABAS_CONPWD ;
Text[ en-US ] = "~Password...";
-};
+ };
+
Edit ET_DOMAIN_USR
{
Pos = MAP_APPFONT ( 77 + ADJUST_X, 47 + MOVE_Y) ;
@@ -140,7 +144,7 @@ ModalDialog DLG_ADABAS_NEWDB
TabStop = TRUE ;
HelpID = HID_DLG_ADABAS_DOMAINPWD ;
Text[ en-US ] = "Passwo~rd...";
-};
+ };
FixedImage BMP_CON
{
@@ -148,12 +152,14 @@ ModalDialog DLG_ADABAS_NEWDB
Size = MAP_APPFONT ( 20 , 20 ) ;
HelpID = HID_DLG_ADABAS_CON_PWD ;
};
+
FixedImage BMP_SYS
{
Pos = MAP_APPFONT ( 240 , 11 + MOVE_Y) ;
Size = MAP_APPFONT ( 20 , 20 ) ;
HelpID = HID_DLG_ADABAS_SYS_PWD ;
};
+
FixedImage BMP_DOMAIN
{
Pos = MAP_APPFONT ( 240 , 44 + MOVE_Y) ;
@@ -166,7 +172,7 @@ ModalDialog DLG_ADABAS_NEWDB
Pos = MAP_APPFONT ( 12 , 13 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 10 ) ;
Text[ en-US ] = "~Backup file";
-};
+ };
Edit ET_RESTORE
{
@@ -184,7 +190,7 @@ ModalDialog DLG_ADABAS_NEWDB
TabStop = TRUE ;
HelpID = HID_DLG_ADABAS_PBRESTORE ;
Text[ en-US ] = "...";
-};
+ };
/* DEVSPACE positions */
FixedLine FL_DBSETTINGS
@@ -192,28 +198,28 @@ ModalDialog DLG_ADABAS_NEWDB
Pos = MAP_APPFONT ( 6 , 70 + MOVE_Y) ;
Size = MAP_APPFONT ( WIN_X - 12 , 8 ) ;
Text[ en-US ] = "Database settings";
-};
+ };
FixedText FT_SYSDEVSPACE
{
Pos = MAP_APPFONT ( 12 , 83 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 8 ) ;
Text[ en-US ] = "S~YSDEVSPACE";
-};
+ };
FixedText FT_TRANSACTIONLOG
{
Pos = MAP_APPFONT ( 12 , 99 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 8 ) ;
Text[ en-US ] = "TRANSACTI~ONLOG";
-};
+ };
FixedText FT_DATADEVSPACE
{
Pos = MAP_APPFONT ( 12 , 116 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 8 ) ;
Text[ en-US ] = "DATAD~EVSPACE";
-};
+ };
Edit ET_SYSDEVSPACE
{
@@ -231,7 +237,7 @@ ModalDialog DLG_ADABAS_NEWDB
TabStop = TRUE ;
HelpID = HID_DLG_ADABAS_PBSYSDEVSPACE ;
Text[ en-US ] = "...";
-};
+ };
Edit ET_TRANSACTIONLOG
{
@@ -249,7 +255,7 @@ ModalDialog DLG_ADABAS_NEWDB
TabStop = TRUE ;
HelpID = HID_DLG_ADABAS_PBTRANSACTIONLOG ;
Text[ en-US ] = "...";
-};
+ };
Edit ET_DATADEVSPACE
{
@@ -260,7 +266,6 @@ ModalDialog DLG_ADABAS_NEWDB
HelpID = HID_DLG_ADABAS_DATADEVSPACE ;
};
-
PushButton PB_DATADEVSPACE
{
Pos = MAP_APPFONT ( WIN_X - 24, 114 + MOVE_Y) ;
@@ -268,14 +273,16 @@ ModalDialog DLG_ADABAS_NEWDB
TabStop = TRUE ;
HelpID = HID_DLG_ADABAS_PBDATADEVSPACE ;
Text[ en-US ] = "...";
-};
+ };
+
/* DEVSPACE sizes */
FixedText FT_TRANSACTIONLOG_SIZE
{
Pos = MAP_APPFONT ( 12 , 133 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 8 ) ;
Text[ en-US ] = "Transaction ~file (MB)";
-};
+ };
+
NumericField NF_TRANSACTIONLOG_SIZE
{
Pos = MAP_APPFONT ( 77 + ADJUST_X, 131 + MOVE_Y) ;
@@ -283,15 +290,17 @@ ModalDialog DLG_ADABAS_NEWDB
Border = TRUE ;
TabStop = TRUE ;
Spin = TRUE ;
-StrictFormat = TRUE;
+ StrictFormat = TRUE;
HelpID = HID_DLG_ADABAS_TRANSACTIONLOG_SIZE ;
};
+
FixedText FT_DATADEVSPACE_SIZE
{
Pos = MAP_APPFONT ( 12 , 150 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 8 ) ;
Text[ en-US ] = "Data~base size (MB)";
-};
+ };
+
NumericField NF_DATADEVSPACE_SIZE
{
Pos = MAP_APPFONT ( 77 + ADJUST_X, 148 + MOVE_Y) ;
@@ -299,15 +308,17 @@ StrictFormat = TRUE;
Border = TRUE ;
TabStop = TRUE ;
Spin = TRUE ;
-StrictFormat = TRUE;
+ StrictFormat = TRUE;
HelpID = HID_DLG_ADABAS_DATADEVSPACE_SIZE ;
};
+
FixedText FT_CACHE_SIZE
{
Pos = MAP_APPFONT ( 12 , 167 + MOVE_Y) ;
Size = MAP_APPFONT ( 64 + ADJUST_X, 8 ) ;
Text[ en-US ] = "Data ~buffer size (MB)";
-};
+ };
+
NumericField NF_CACHE_SIZE
{
Pos = MAP_APPFONT ( 77 + ADJUST_X, 165 + MOVE_Y) ;
@@ -315,14 +326,16 @@ StrictFormat = TRUE;
Border = TRUE ;
TabStop = TRUE ;
Spin = TRUE ;
-StrictFormat = TRUE;
+ StrictFormat = TRUE;
HelpID = HID_DLG_ADABAS_CACHE_SIZE ;
};
+
FixedLine FL_END
{
Pos = MAP_APPFONT ( 0 , WIN_Y - 24 + MOVE_Y) ;
Size = MAP_APPFONT ( WIN_X , 1 ) ;
};
+
OKButton PB_OK
{
Pos = MAP_APPFONT ( WIN_X - 112, WIN_Y - 20 + MOVE_Y) ;
@@ -330,6 +343,7 @@ StrictFormat = TRUE;
TabStop = TRUE ;
DefButton = TRUE ;
};
+
CancelButton PB_CANCEL
{
Pos = MAP_APPFONT ( WIN_X - 56 , WIN_Y - 20+ MOVE_Y) ;
@@ -340,26 +354,29 @@ StrictFormat = TRUE;
String STR_BACKUPFILE_LOAD
{
Text[ en-US ] = "Backup file information";
-};
+ };
Text[ en-US ] = "Create New Adabas D Database";
};
Image CHECK_GREEN
{
- ImageBitmap = Bitmap { File = "nu07.bmp"; };
+ ImageBitmap = Bitmap { File = "nu07.png"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
+
Image UNCHECK_RED
{
- ImageBitmap = Bitmap { File = "nu08.bmp"; };
+ ImageBitmap = Bitmap { File = "nu08.png"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
+
Image DEFAULT_BLUE
{
- ImageBitmap = Bitmap { File = "nu09.bmp"; };
+ ImageBitmap = Bitmap { File = "nu09.png"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
+
/* Fehlermeldungen beim Erstellen einer Adabas DB */
String STR_ADABAS_NO_PARAM_SET
@@ -376,6 +393,7 @@ String STR_ADABAS_NO_SYSTEM_TABLES
{
Text[ en-US ] = "An error occurred as the system tables were being created.";
};
+
String STR_ADABAS_NO_BACKUP_FILE
{
Text[ en-US ] = "The backup file entered does not exist.";
@@ -390,10 +408,12 @@ String STR_NO_SAME_USER
{
Text[ en-US ] = "The administrator and the control user cannot have the same name!";
};
+
String STR_DEVSPACE_NO_FILE
{
Text[ en-US ] = "No name has been entered for the $name$ file!";
};
+
String STR_NO_PERMISSION
{
Text[ en-US ] = "You have to have administrator rights to create a new database!";
@@ -423,11 +443,12 @@ String STR_ADABAS_CREATEPARAM_FILE
{
Text [ en-US ] = "Creating database configuration file." ;
};
+
String STR_ADABAS_START_DATABASE
{
Text [ en-US ] = "Starting database for the first time." ;
-
};
+
String STR_ADABAS_DB_EXISTS
{
Text[ en-US ] = "The name entered already exists.";
@@ -445,11 +466,10 @@ String STR_ADABAS_NO_ACCESSRIGHTS
String STR_ADABAS_CANNOT_CONVERT
{
- Text[ en-US ] = "The current database need to be converted. Please insert control user and password.";
+ Text[ en-US ] = "The current database need to be converted. Please insert control user and password.";
};
String STR_ADABAS_PASSWORD_ILLEGAL
{
Text[ en-US ] = "Spaces are not permitted in the password. Please enter a new password.";
};
-
diff --git a/dbaccess/source/ext/adabas/Aservices.cxx b/dbaccess/source/ext/adabas/Aservices.cxx
index b1c24bd295a5..eb83f464b473 100644
--- a/dbaccess/source/ext/adabas/Aservices.cxx
+++ b/dbaccess/source/ext/adabas/Aservices.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,15 +26,9 @@
*
************************************************************************/
-#ifndef _CPPUHELPER_FACTORY_HXX_
#include <cppuhelper/factory.hxx>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _EXTENSIONS_COMPONENT_MODULE_HXX_
#include "Acomponentmodule.hxx"
-#endif
/********************************************************************************************/
@@ -63,8 +58,7 @@ extern "C" void SAL_CALL createRegistryInfo_adabasui()
//---------------------------------------------------------------------------------------
-extern "C" SAL_DLLPUBLIC_EXPORT void SAL_CALL
-component_getImplementationEnvironment(
+extern "C" SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char **ppEnvTypeName,
uno_Environment **
)
@@ -91,3 +85,5 @@ extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
xRet->acquire();
return xRet.get();
};
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/Astringconstants.cxx b/dbaccess/source/ext/adabas/Astringconstants.cxx
index bede25514524..6fe34c212a00 100644
--- a/dbaccess/source/ext/adabas/Astringconstants.cxx
+++ b/dbaccess/source/ext/adabas/Astringconstants.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -58,3 +59,4 @@ IMPLEMENT_CONSTASCII_USTRING(SQLSTATE_GENERAL, "01000");
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/adabasuistrings.cxx b/dbaccess/source/ext/adabas/adabasuistrings.cxx
index c1dae127c868..cf1edccedc07 100644
--- a/dbaccess/source/ext/adabas/adabasuistrings.cxx
+++ b/dbaccess/source/ext/adabas/adabasuistrings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,9 +26,7 @@
*
************************************************************************/
-#ifndef ADABASUI_SHARED_DBUSTRINGS_HRC
#include "adabasuistrings.hrc"
-#endif
namespace adabasui
{
@@ -35,3 +34,4 @@ namespace adabasui
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/adabas/makefile.mk b/dbaccess/source/ext/adabas/makefile.mk
deleted file mode 100644
index 8dbbe7abc3ff..000000000000
--- a/dbaccess/source/ext/adabas/makefile.mk
+++ /dev/null
@@ -1,100 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=dbaccess
-TARGET=adabasui
-ENABLE_EXCEPTIONS=TRUE
-VISIBILITY_HIDDEN=TRUE
-
-# --- Settings ----------------------------------
-.INCLUDE : settings.mk
-
-# --- resource -----------------------------------------------------
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- AdabasNewDb.src
-
-# --- defines ------------------------------------------------------
-CDEFS+=-DCOMPMOD_NAMESPACE=adabasui
-
-# --- Files -------------------------------------
-SLOFILES=\
- $(SLO)$/ASqlNameEdit.obj \
- $(SLO)$/AdabasNewDb.obj \
- $(SLO)$/ANewDb.obj \
- $(SLO)$/adabasuistrings.obj \
- $(SLO)$/Aservices.obj \
- $(SLO)$/Acomponentmodule.obj
-
-# --- Library -----------------------------------
-SHL1TARGET=$(TARGET)$(DLLPOSTFIX)
-
-SHL1STDLIBS=\
- $(CPPULIB) \
- $(CPPUHELPERLIB) \
- $(SALLIB) \
- $(DBTOOLSLIB) \
- $(UNOTOOLSLIB) \
- $(SVTOOLLIB) \
- $(TOOLSLIB) \
- $(SVLLIB) \
- $(VCLLIB) \
- $(UCBHELPERLIB) \
- $(SFXLIB) \
- $(TKLIB) \
- $(COMPHELPERLIB)
-
-SHL1IMPLIB=i$(SHL1TARGET)
-
-SHL1DEF=$(MISC)$/$(SHL1TARGET).def
-SHL1LIBS=$(SLB)$/$(TARGET).lib
-DEF1NAME=$(SHL1TARGET)
-DEF1EXPORTFILE=$(TARGET).dxp
-SHL1VERSIONMAP=$(SOLARENV)/src/component.map
-
-# --- .res file ----------------------------------------------------------
-RES1FILELIST=\
- $(SRS)$/$(SRS1NAME).srs
-
-RESLIB1NAME=$(TARGET)
-RESLIB1IMAGES=$(PRJ)$/res
-RESLIB1SRSFILES=$(RES1FILELIST)
-
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
-ALLTAR : $(MISC)/adabasui.component
-
-$(MISC)/adabasui.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- adabasui.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt adabasui.component
diff --git a/dbaccess/source/ext/macromigration/dbmm_module.cxx b/dbaccess/source/ext/macromigration/dbmm_module.cxx
index 7878a90477e0..36a8695979f5 100644
--- a/dbaccess/source/ext/macromigration/dbmm_module.cxx
+++ b/dbaccess/source/ext/macromigration/dbmm_module.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,3 +44,4 @@ namespace dbmm
} // namespace dbmm
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/dbmm_module.hxx b/dbaccess/source/ext/macromigration/dbmm_module.hxx
index 264550f4cba4..4e27f8c18401 100644
--- a/dbaccess/source/ext/macromigration/dbmm_module.hxx
+++ b/dbaccess/source/ext/macromigration/dbmm_module.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -43,3 +44,4 @@ namespace dbmm
#endif // DBACCESS_MACROMIGRATION_MODULE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/dbmm_services.cxx b/dbaccess/source/ext/macromigration/dbmm_services.cxx
index c43ef5aa5647..5d595c63c7bc 100644
--- a/dbaccess/source/ext/macromigration/dbmm_services.cxx
+++ b/dbaccess/source/ext/macromigration/dbmm_services.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -40,15 +41,8 @@ namespace dbmm
static void initializeModule()
{
- static bool bInitialized( false );
- if ( !bInitialized )
- {
- ::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
- if ( !bInitialized )
- {
- createRegistryInfo_MacroMigrationDialogService();
- }
- }
+ ::osl::MutexGuard aGuard( ::osl::Mutex::getGlobalMutex() );
+ createRegistryInfo_MacroMigrationDialogService();
}
//........................................................................
@@ -56,3 +50,5 @@ namespace dbmm
//........................................................................
IMPLEMENT_COMPONENT_LIBRARY_API( ::dbmm::MacroMigrationModule, ::dbmm::initializeModule )
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/dbmm_types.cxx b/dbaccess/source/ext/macromigration/dbmm_types.cxx
index 36c4070d64b8..b5e10432a1aa 100644
--- a/dbaccess/source/ext/macromigration/dbmm_types.cxx
+++ b/dbaccess/source/ext/macromigration/dbmm_types.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -61,3 +62,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/dbmm_types.hxx b/dbaccess/source/ext/macromigration/dbmm_types.hxx
index 49f5de86a98b..13c02005b68c 100644
--- a/dbaccess/source/ext/macromigration/dbmm_types.hxx
+++ b/dbaccess/source/ext/macromigration/dbmm_types.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,6 +30,7 @@
#define DBACCESS_DBMM_TYPES_HXX
#include <tools/string.hxx>
+#include <sal/macros.h>
//........................................................................
namespace dbmm
@@ -67,3 +69,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_DBMM_TYPES_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/docinteraction.cxx b/dbaccess/source/ext/macromigration/docinteraction.cxx
index 068061b90e9c..3200a53cf5c1 100644
--- a/dbaccess/source/ext/macromigration/docinteraction.cxx
+++ b/dbaccess/source/ext/macromigration/docinteraction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -140,3 +141,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/docinteraction.hxx b/dbaccess/source/ext/macromigration/docinteraction.hxx
index 51036eb90d54..524aa981aac4 100644
--- a/dbaccess/source/ext/macromigration/docinteraction.hxx
+++ b/dbaccess/source/ext/macromigration/docinteraction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_DOCERRORHANDLING_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/macromigration.src b/dbaccess/source/ext/macromigration/macromigration.src
index 757c181c48cf..5d1d9db39f8b 100644
--- a/dbaccess/source/ext/macromigration/macromigration.src
+++ b/dbaccess/source/ext/macromigration/macromigration.src
@@ -347,6 +347,7 @@ TabPage TP_SUMMARY
{
Text [ en-US ] = "The migration was successful. Below is a log of the actions which have been taken to your document.";
};
+
String STR_UNSUCCESSFUL
{
Text [ en-US ] = "The migration was not successful. Examine the migration log below for details.";
@@ -451,10 +452,12 @@ String STR_INVALID_NUMBER_ARGS
{
Text [ en-US ] = "Invalid number of initialization arguments. Expected 1.";
};
+
String STR_NO_DATABASE
{
Text [ en-US ] = "No database document found in the initialization arguments.";
};
+
String STR_NOT_READONLY
{
Text [ en-US ] = "Not applicable to read-only documents.";
diff --git a/dbaccess/source/ext/macromigration/macromigrationdialog.cxx b/dbaccess/source/ext/macromigration/macromigrationdialog.cxx
index 710ffb4397f8..1c7cc12ae850 100644
--- a/dbaccess/source/ext/macromigration/macromigrationdialog.cxx
+++ b/dbaccess/source/ext/macromigration/macromigrationdialog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -270,7 +271,7 @@ namespace dbmm
break;
default:
- OSL_ENSURE( false, "MacroMigrationDialog::enterState: unhandled state!" );
+ OSL_FAIL( "MacroMigrationDialog::enterState: unhandled state!" );
}
}
@@ -295,7 +296,7 @@ namespace dbmm
case STATE_SUMMARY:
break;
default:
- OSL_ENSURE( false, "MacroMigrationDialog::prepareLeaveCurrentState: unhandled state!" );
+ OSL_FAIL( "MacroMigrationDialog::prepareLeaveCurrentState: unhandled state!" );
}
return sal_True;
@@ -534,7 +535,7 @@ namespace dbmm
if ( !xController->suspend( sal_True ) )
{ // ouch. There shouldn't be any modal dialogs and such, so there
// really is no reason why suspending shouldn't work.
- OSL_ENSURE( false, "MacroMigrationDialog::impl_reloadDocument_nothrow: could not suspend a controller!" );
+ OSL_FAIL( "MacroMigrationDialog::impl_reloadDocument_nothrow: could not suspend a controller!" );
// ignoring this would be at the cost of a crash (potentially)
// so, we cannot continue here.
throw CloseVetoException();
@@ -626,3 +627,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/macromigrationdialog.hxx b/dbaccess/source/ext/macromigration/macromigrationdialog.hxx
index 323a2422ecd0..9bda822366b2 100644
--- a/dbaccess/source/ext/macromigration/macromigrationdialog.hxx
+++ b/dbaccess/source/ext/macromigration/macromigrationdialog.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,3 +93,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_MACROMIGRATIONDIALOG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/macromigrationpages.cxx b/dbaccess/source/ext/macromigration/macromigrationpages.cxx
index 98aa52793e0d..bdbab6d93430 100644
--- a/dbaccess/source/ext/macromigration/macromigrationpages.cxx
+++ b/dbaccess/source/ext/macromigration/macromigrationpages.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -359,3 +360,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/macromigrationpages.hxx b/dbaccess/source/ext/macromigration/macromigrationpages.hxx
index 8c269982999d..93cfd04bf864 100644
--- a/dbaccess/source/ext/macromigration/macromigrationpages.hxx
+++ b/dbaccess/source/ext/macromigration/macromigrationpages.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -179,3 +180,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_MACROMIGRATIONPAGES_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/macromigrationwizard.cxx b/dbaccess/source/ext/macromigration/macromigrationwizard.cxx
index ce4fedbcbf03..0b1d27b0061d 100644
--- a/dbaccess/source/ext/macromigration/macromigrationwizard.cxx
+++ b/dbaccess/source/ext/macromigration/macromigrationwizard.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -261,3 +262,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/makefile.mk b/dbaccess/source/ext/macromigration/makefile.mk
deleted file mode 100644
index b71330f17ef5..000000000000
--- a/dbaccess/source/ext/macromigration/makefile.mk
+++ /dev/null
@@ -1,109 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=dbmm
-USE_DEFFILE=TRUE
-
-ENABLE_EXCEPTIONS=TRUE
-VISIBILITY_HIDDEN=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files -------------------------------------
-
-# ... resource files ............................
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- macromigration.src
-
-# ... object files ............................
-SLOFILES= $(SLO)$/macromigrationwizard.obj \
- $(SLO)$/macromigrationdialog.obj \
- $(SLO)$/macromigrationpages.obj \
- $(SLO)$/dbmm_module.obj \
- $(SLO)$/dbmm_services.obj \
- $(SLO)$/migrationengine.obj \
- $(SLO)$/docinteraction.obj \
- $(SLO)$/progresscapture.obj \
- $(SLO)$/progressmixer.obj \
- $(SLO)$/migrationlog.obj \
- $(SLO)$/dbmm_types.obj \
-
-# --- library -----------------------------------
-
-SHL1TARGET=$(TARGET)$(DLLPOSTFIX)
-SHL1VERSIONMAP=$(SOLARENV)/src/component.map
-
-SHL1STDLIBS= \
- $(CPPULIB) \
- $(CPPUHELPERLIB) \
- $(COMPHELPERLIB) \
- $(UNOTOOLSLIB) \
- $(TOOLSLIB) \
- $(SALLIB) \
- $(SVTOOLLIB) \
- $(SVLLIB) \
- $(VCLLIB) \
- $(SVXCORELIB) \
- $(SVXLIB) \
- $(UCBHELPERLIB) \
- $(XMLSCRIPTLIB)
-
-SHL1LIBS= $(SLB)$/$(TARGET).lib
-SHL1IMPLIB= i$(TARGET)
-SHL1DEPN= $(SHL1LIBS)
-SHL1DEF= $(MISC)$/$(SHL1TARGET).def
-
-DEF1NAME= $(SHL1TARGET)
-
-# --- .res files -------------------------------
-
-RES1FILELIST=\
- $(SRS)$/$(TARGET).srs
-
-RESLIB1NAME=$(TARGET)
-RESLIB1IMAGES=$(PRJ)$/res
-RESLIB1SRSFILES=$(RES1FILELIST)
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
-
-ALLTAR : $(MISC)/dbmm.component
-
-$(MISC)/dbmm.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- dbmm.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt dbmm.component
diff --git a/dbaccess/source/ext/macromigration/migrationengine.cxx b/dbaccess/source/ext/macromigration/migrationengine.cxx
index 775ca01cbf74..55cc8b0c6d7a 100644
--- a/dbaccess/source/ext/macromigration/migrationengine.cxx
+++ b/dbaccess/source/ext/macromigration/migrationengine.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -214,7 +215,7 @@ namespace dbmm
break;
}
- OSL_ENSURE( false, "lcl_getScriptsSubStorageName: illegal type!" );
+ OSL_FAIL( "lcl_getScriptsSubStorageName: illegal type!" );
static ::rtl::OUString s_sEmpty;
return s_sEmpty;
}
@@ -241,7 +242,7 @@ namespace dbmm
LanguageMapping( "Python", ePython ), // TODO: is this correct?
LanguageMapping( "Basic", eBasic )
};
- for ( size_t i=0; i < sizeof( aLanguageMapping ) / sizeof( aLanguageMapping[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aLanguageMapping ); ++i )
{
if ( _rLanguage.equalsAscii( aLanguageMapping[i].pAsciiLanguage ) )
{
@@ -249,7 +250,7 @@ namespace dbmm
return true;
}
}
- OSL_ENSURE( false, "lcl_getScriptTypeFromLanguage: unknown language!" );
+ OSL_FAIL( "lcl_getScriptTypeFromLanguage: unknown language!" );
return false;
}
@@ -332,7 +333,7 @@ namespace dbmm
bool bCausedByNewStyleReport =
( _rDocument.eType == eReport )
&& ( aError.isExtractableTo( ::cppu::UnoType< WrongFormatException >::get() ) )
- && ( lcl_getMimeType_nothrow( _rDocument.xCommandProcessor ).equalsAscii( "application/vnd.sun.xml.report" ) );
+ && ( lcl_getMimeType_nothrow( _rDocument.xCommandProcessor ).equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "application/vnd.sun.xml.report" ) ) );
if ( bCausedByNewStyleReport )
{
@@ -1019,7 +1020,7 @@ namespace dbmm
{
if ( m_aSubDocs.empty() )
{
- OSL_ENSURE( false, "MigrationEngine_Impl::migrateAll: no forms/reports found!" );
+ OSL_FAIL( "MigrationEngine_Impl::migrateAll: no forms/reports found!" );
// The whole migration wizard is not expected to be called when there are no forms/reports
// with macros, not to mention when there are no forms/reports at all.
return false;
@@ -1162,7 +1163,7 @@ namespace dbmm
aProgressMixer.registerPhase( PHASE_PYTHON, 1 );
aProgressMixer.registerPhase( PHASE_JAVA, 1 );
aProgressMixer.registerPhase( PHASE_BASIC, 5 );
- // more weight than then others, assuming that usually, there are much more Basic macros than any other scripts
+ // more weight than the others, assuming that usually, there are many more Basic macros than any other scripts
aProgressMixer.registerPhase( PHASE_DIALOGS, 1 );
bool bSuccess = impl_checkScriptStorageStructure_nothrow( aSubDocument );
@@ -1222,7 +1223,7 @@ namespace dbmm
const ::rtl::OUString& _rSourceLibName, const Reference< XNameAccess >& _rxTargetContainer )
{
// The new library name is composed from the prefix, the base name, and the old library name.
- const ::rtl::OUString sPrefix( ::rtl::OUString::createFromAscii( _rDocument.eType == eForm ? "Form_" : "Report_" ) );
+ const ::rtl::OUString sPrefix = (_rDocument.eType == eForm)?rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Form_")): rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Report_"));
::rtl::OUString sBaseName( _rDocument.sHierarchicalName.copy(
_rDocument.sHierarchicalName.lastIndexOf( '/' ) + 1 ) );
@@ -1231,8 +1232,8 @@ namespace dbmm
// The bug requesting to change this is #i95409#.
// Unfortunately, the storage implementation does not complain if you use invalid characters/names, but instead
// it silently accepts them, and produces garbage in the file (#i95408).
- // So, until especially the former is fixed, we need to strip the name from all invalid characters.
- // #i95865# / 2008-11-06 / frank.schoenheit@sun.com
+ // So, until especially the former is fixed, we need to strip all invalid characters from the name.
+ // #i95865#
// The general idea is to replace invalid characters with '_'. However, since "valid" essentially means
// ASCII only, this implies that for a lot of languages, we would simply replace everything with '_',
@@ -1305,7 +1306,7 @@ namespace dbmm
ScriptType aKnownStorageBasedTypes[] = {
eBeanShell, eJavaScript, ePython, eJava
};
- for ( size_t i=0; i<sizeof( aKnownStorageBasedTypes ) / sizeof( aKnownStorageBasedTypes[0] ); ++i )
+ for ( size_t i=0; i< SAL_N_ELEMENTS( aKnownStorageBasedTypes ); ++i )
aElementNames.erase( lcl_getScriptsSubStorageName( aKnownStorageBasedTypes[i] ) );
if ( !aElementNames.empty() )
@@ -1638,7 +1639,7 @@ namespace dbmm
|| !_rScriptType.getLength()
)
{
- OSL_ENSURE( false,
+ OSL_FAIL(
"MigrationEngine_Impl::impl_adjustScriptLibrary_nothrow: no or unknown script type!" );
m_rLogger.logRecoverable( MigrationError(
ERR_UNKNOWN_SCRIPT_TYPE,
@@ -1656,7 +1657,7 @@ namespace dbmm
ScriptType eScriptType = eBasic;
if ( !lcl_getScriptTypeFromLanguage( sScriptLanguage, eScriptType ) )
{
- OSL_ENSURE( false,
+ OSL_FAIL(
"MigrationEngine_Impl::impl_adjustScriptLibrary_nothrow: unknown script language!" );
m_rLogger.logRecoverable( MigrationError(
ERR_UNKNOWN_SCRIPT_LANGUAGE,
@@ -1667,7 +1668,7 @@ namespace dbmm
::rtl::OUString sLocation = xUri->getParameter(
::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "location" ) ) );
- if ( !sLocation.equalsAscii( "document" ) )
+ if ( !sLocation.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "document" ) ) )
{
// only document libraries must be migrated, of course
return false;
@@ -1677,7 +1678,7 @@ namespace dbmm
sal_Int32 nLibModuleSeparator = sScriptName.indexOf( '.' );
if ( nLibModuleSeparator < 0 )
{
- OSL_ENSURE( false,
+ OSL_FAIL(
"MigrationEngine_Impl::impl_adjustScriptLibrary_nothrow: invalid/unknown location format!" );
m_rLogger.logRecoverable( MigrationError(
ERR_UNKNOWN_SCRIPT_NAME_FORMAT,
@@ -1835,7 +1836,7 @@ namespace dbmm
Reference< XInputStream > xInput( xISP->createInputStream(), UNO_QUERY_THROW );
Reference< XNameContainer > xDialogModel( m_aContext.createComponent( "com.sun.star.awt.UnoControlDialogModel" ), UNO_QUERY_THROW );
- ::xmlscript::importDialogModel( xInput, xDialogModel, m_aContext.getUNOContext() );
+ ::xmlscript::importDialogModel( xInput, xDialogModel, m_aContext.getUNOContext(), m_xDocumentModel );
// adjust the events of the dialog
impl_adjustDialogElementEvents_throw( xDialogModel );
@@ -1850,7 +1851,7 @@ namespace dbmm
}
// export dialog model
- xISP = ::xmlscript::exportDialogModel( xDialogModel, m_aContext.getUNOContext() );
+ xISP = ::xmlscript::exportDialogModel( xDialogModel, m_aContext.getUNOContext(), m_xDocumentModel );
_inout_rDialogLibraryElement <<= xISP;
}
catch( const Exception& )
@@ -1988,3 +1989,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/migrationengine.hxx b/dbaccess/source/ext/macromigration/migrationengine.hxx
index 2a203c9a82eb..8cecd2faac2b 100644
--- a/dbaccess/source/ext/macromigration/migrationengine.hxx
+++ b/dbaccess/source/ext/macromigration/migrationengine.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -98,3 +99,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_MIGRATIONENGINE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/migrationerror.hxx b/dbaccess/source/ext/macromigration/migrationerror.hxx
index 8e0a0fd29082..aee93d10bdc6 100644
--- a/dbaccess/source/ext/macromigration/migrationerror.hxx
+++ b/dbaccess/source/ext/macromigration/migrationerror.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -171,3 +172,4 @@ namespace dbmm
#endif // DBACCESS_MIGRATIONERROR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/migrationlog.cxx b/dbaccess/source/ext/macromigration/migrationlog.cxx
index b80b6ec319f9..7e2e0acf73e2 100644
--- a/dbaccess/source/ext/macromigration/migrationlog.cxx
+++ b/dbaccess/source/ext/macromigration/migrationlog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -214,7 +215,7 @@ namespace dbmm
DocumentLogs::const_iterator docPos = m_pData->aDocumentLogs.find( _nDocID );
if ( docPos == m_pData->aDocumentLogs.end() )
{
- OSL_ENSURE( false, "MigrationLog::getNewLibraryName: document is not known!" );
+ OSL_FAIL( "MigrationLog::getNewLibraryName: document is not known!" );
return s_sEmptyString;
}
@@ -230,7 +231,7 @@ namespace dbmm
return lib->sNewName;
}
- OSL_ENSURE( false, "MigrationLog::getNewLibraryName: doc is known, but library isn't!" );
+ OSL_FAIL( "MigrationLog::getNewLibraryName: doc is known, but library isn't!" );
return s_sEmptyString;
}
@@ -432,7 +433,7 @@ namespace dbmm
DocumentLogs::const_iterator docPos = m_pData->aDocumentLogs.find( _nDocID );
if ( docPos == m_pData->aDocumentLogs.end() )
{
- OSL_ENSURE( false, "MigrationLog::movedAnyLibrary: document is not known!" );
+ OSL_FAIL( "MigrationLog::movedAnyLibrary: document is not known!" );
return false;
}
return !docPos->second.aMovedLibraries.empty();
@@ -510,3 +511,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/migrationlog.hxx b/dbaccess/source/ext/macromigration/migrationlog.hxx
index c8dd0910242e..554b95763e95 100644
--- a/dbaccess/source/ext/macromigration/migrationlog.hxx
+++ b/dbaccess/source/ext/macromigration/migrationlog.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -126,3 +127,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_MIGRATIONLOG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/migrationprogress.hxx b/dbaccess/source/ext/macromigration/migrationprogress.hxx
index a38cc6365f7b..9c1598a43855 100644
--- a/dbaccess/source/ext/macromigration/migrationprogress.hxx
+++ b/dbaccess/source/ext/macromigration/migrationprogress.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -56,3 +57,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_MIGRATIONPROGRESS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/progresscapture.cxx b/dbaccess/source/ext/macromigration/progresscapture.cxx
index ecd0b5bdded3..daf8c022fb0c 100644
--- a/dbaccess/source/ext/macromigration/progresscapture.cxx
+++ b/dbaccess/source/ext/macromigration/progresscapture.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,7 +36,7 @@
/** === end UNO includes === **/
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
//........................................................................
namespace dbmm
@@ -88,14 +89,14 @@ namespace dbmm
//--------------------------------------------------------------------
void ProgressCapture::dispose()
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
m_pData->bDisposed = true;
}
//--------------------------------------------------------------------
void SAL_CALL ProgressCapture::start( const ::rtl::OUString& _rText, ::sal_Int32 _nRange ) throw (RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if ( !m_pData->bDisposed )
m_pData->rMasterProgress.startObject( m_pData->sObjectName, _rText, _nRange );
}
@@ -103,7 +104,7 @@ namespace dbmm
//--------------------------------------------------------------------
void SAL_CALL ProgressCapture::end( ) throw (RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if ( !m_pData->bDisposed )
m_pData->rMasterProgress.endObject();
}
@@ -111,7 +112,7 @@ namespace dbmm
//--------------------------------------------------------------------
void SAL_CALL ProgressCapture::setText( const ::rtl::OUString& _rText ) throw (RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if ( !m_pData->bDisposed )
m_pData->rMasterProgress.setObjectProgressText( _rText );
}
@@ -119,7 +120,7 @@ namespace dbmm
//--------------------------------------------------------------------
void SAL_CALL ProgressCapture::setValue( ::sal_Int32 _nValue ) throw (RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if ( !m_pData->bDisposed )
m_pData->rMasterProgress.setObjectProgressValue( _nValue );
}
@@ -127,9 +128,11 @@ namespace dbmm
//--------------------------------------------------------------------
void SAL_CALL ProgressCapture::reset( ) throw (RuntimeException)
{
- OSL_ENSURE( false, "ProgressCapture::reset: not implemented!" );
+ OSL_FAIL( "ProgressCapture::reset: not implemented!" );
}
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/progresscapture.hxx b/dbaccess/source/ext/macromigration/progresscapture.hxx
index 263ad9861475..eb507e6d63c1 100644
--- a/dbaccess/source/ext/macromigration/progresscapture.hxx
+++ b/dbaccess/source/ext/macromigration/progresscapture.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,3 +78,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_PROGRESSCAPTURE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/progressmixer.cxx b/dbaccess/source/ext/macromigration/progressmixer.cxx
index 5c8d873fcae1..9ec628c58380 100644
--- a/dbaccess/source/ext/macromigration/progressmixer.cxx
+++ b/dbaccess/source/ext/macromigration/progressmixer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -214,3 +215,5 @@ namespace dbmm
//........................................................................
} // namespace dbmm
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/progressmixer.hxx b/dbaccess/source/ext/macromigration/progressmixer.hxx
index 784692da07a3..dd52a72d134d 100644
--- a/dbaccess/source/ext/macromigration/progressmixer.hxx
+++ b/dbaccess/source/ext/macromigration/progressmixer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -98,3 +99,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_PROGRESSMIXER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ext/macromigration/rangeprogressbar.hxx b/dbaccess/source/ext/macromigration/rangeprogressbar.hxx
index d0afc7de090c..502dd86a4471 100644
--- a/dbaccess/source/ext/macromigration/rangeprogressbar.hxx
+++ b/dbaccess/source/ext/macromigration/rangeprogressbar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -102,3 +103,5 @@ namespace dbmm
//........................................................................
#endif // DBACCESS_RANGEPROGRESSBAR_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/dbloader2.cxx b/dbaccess/source/filter/xml/dbloader2.cxx
index 1f9aab64b817..210c5c9f7937 100644
--- a/dbaccess/source/filter/xml/dbloader2.cxx
+++ b/dbaccess/source/filter/xml/dbloader2.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -121,7 +122,7 @@ public:
// static methods
static ::rtl::OUString getImplementationName_Static() throw( )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbflt.DBTypeDetection");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbflt.DBTypeDetection"));
}
static Sequence< ::rtl::OUString> getSupportedServiceNames_Static(void) throw( );
static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
@@ -167,7 +168,7 @@ DBTypeDetection::DBTypeDetection(const Reference< XMultiServiceFactory >& _rxFac
{
::rtl::OUString sMediaType;
xStorageProperties->getPropertyValue( INFO_MEDIATYPE ) >>= sMediaType;
- if ( sMediaType.equalsAscii(MIMETYPE_OASIS_OPENDOCUMENT_DATABASE_ASCII) || sMediaType.equalsAscii(MIMETYPE_VND_SUN_XML_BASE_ASCII) )
+ if ( sMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(MIMETYPE_OASIS_OPENDOCUMENT_DATABASE_ASCII)) || sMediaType.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(MIMETYPE_VND_SUN_XML_BASE_ASCII)) )
{
if ( bStreamFromDescr && sURL.compareTo( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "private:stream" ) ), 14 ) != COMPARE_EQUAL )
{
@@ -230,7 +231,7 @@ Sequence< ::rtl::OUString > SAL_CALL DBTypeDetection::getSupportedServiceNames(v
Sequence< ::rtl::OUString > DBTypeDetection::getSupportedServiceNames_Static(void) throw( )
{
Sequence< ::rtl::OUString > aSNS( 1 );
- aSNS.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.document.ExtendedTypeDetection");
+ aSNS.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.ExtendedTypeDetection"));
return aSNS;
}
// -------------------------------------------------------------------------
@@ -261,7 +262,7 @@ public:
// static methods
static ::rtl::OUString getImplementationName_Static() throw( )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbflt.DBContentLoader2");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbflt.DBContentLoader2"));
}
static Sequence< ::rtl::OUString> getSupportedServiceNames_Static(void) throw( );
static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
@@ -329,7 +330,7 @@ Sequence< ::rtl::OUString > SAL_CALL DBContentLoader::getSupportedServiceNames(v
Sequence< ::rtl::OUString > DBContentLoader::getSupportedServiceNames_Static(void) throw( )
{
Sequence< ::rtl::OUString > aSNS( 1 );
- aSNS.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.frame.FrameLoader");
+ aSNS.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.FrameLoader"));
return aSNS;
}
@@ -348,12 +349,12 @@ namespace
URL aURL;
aURL.Complete = _rURL;
xTransformer->parseStrict( aURL );
- bDoesAllow = aURL.Arguments.equalsAscii( "Interactive" );
+ bDoesAllow = aURL.Arguments.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "Interactive" ) );
}
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "lcl_urlAllowsInteraction: caught an exception while analyzing the URL!" );
+ OSL_FAIL( "lcl_urlAllowsInteraction: caught an exception while analyzing the URL!" );
}
return bDoesAllow;
}
@@ -618,14 +619,14 @@ IMPL_LINK( DBContentLoader, OnStartTableWizard, void*, /*NOTINTERESTEDIN*/ )
aValue.Value <<= m_sCurrentURL;
aWizArgs[0] <<= aValue;
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
Reference< XJobExecutor > xTableWizard;
if ( m_aContext.createComponentWithArguments( "com.sun.star.wizards.table.CallTableWizard", aWizArgs, xTableWizard ) )
xTableWizard->trigger(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("start")));
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "caught an exception while starting the table wizard!");
+ OSL_FAIL("caught an exception while starting the table wizard!");
}
m_xMySelf = NULL;
return 0L;
@@ -642,17 +643,18 @@ extern "C" void SAL_CALL writeDBLoaderInfo2(void* pRegistryKey)
Reference< XRegistryKey> xKey(reinterpret_cast< XRegistryKey*>(pRegistryKey));
// register content loader for dispatch
- ::rtl::OUString aImpl = ::rtl::OUString::createFromAscii("/");
+ ::rtl::OUString aImpl(RTL_CONSTASCII_USTRINGPARAM("/"));
aImpl += ::dbaxml::DBContentLoader::getImplementationName_Static();
::rtl::OUString aImpltwo = aImpl;
- aImpltwo += ::rtl::OUString::createFromAscii("/UNO/Loader");
+ aImpltwo += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/UNO/Loader"));
Reference< XRegistryKey> xNewKey = xKey->createKey( aImpltwo );
aImpltwo = aImpl;
- aImpltwo += ::rtl::OUString::createFromAscii("/Loader");
+ aImpltwo += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/Loader"));
Reference< XRegistryKey > xLoaderKey = xKey->createKey( aImpltwo );
- xNewKey = xLoaderKey->createKey( ::rtl::OUString::createFromAscii("Pattern") );
- xNewKey->setAsciiValue( ::rtl::OUString::createFromAscii("private:factory/sdatabase") );
+ xNewKey = xLoaderKey->createKey( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Pattern")) );
+ xNewKey->setAsciiValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("private:factory/sdatabase")) );
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/makefile.mk b/dbaccess/source/filter/xml/makefile.mk
deleted file mode 100644
index e36173f5abac..000000000000
--- a/dbaccess/source/filter/xml/makefile.mk
+++ /dev/null
@@ -1,122 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=dbaxml
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files -------------------------------------
-
-SLOFILES= $(SLO)$/xmlfilter.obj \
- $(SLO)$/dbloader2.obj \
- $(SLO)$/xmlDatabase.obj \
- $(SLO)$/xmlDataSource.obj \
- $(SLO)$/xmlTableFilterPattern.obj \
- $(SLO)$/xmlTableFilterList.obj \
- $(SLO)$/xmlDataSourceInfo.obj \
- $(SLO)$/xmlDataSourceSetting.obj \
- $(SLO)$/xmlDataSourceSettings.obj \
- $(SLO)$/xmlDocuments.obj \
- $(SLO)$/xmlComponent.obj \
- $(SLO)$/xmlHierarchyCollection.obj \
- $(SLO)$/xmlLogin.obj \
- $(SLO)$/xmlExport.obj \
- $(SLO)$/xmlQuery.obj \
- $(SLO)$/xmlTable.obj \
- $(SLO)$/xmlColumn.obj \
- $(SLO)$/xmlStyleImport.obj \
- $(SLO)$/xmlHelper.obj \
- $(SLO)$/xmlAutoStyle.obj \
- $(SLO)$/xmlConnectionData.obj \
- $(SLO)$/xmlDatabaseDescription.obj \
- $(SLO)$/xmlFileBasedDatabase.obj \
- $(SLO)$/xmlServerDatabase.obj \
- $(SLO)$/xmlConnectionResource.obj \
- $(SLO)$/xmlservices.obj
-
-# --- Library -----------------------------------
-LIB1TARGET=$(SLB)$/dba_flt.lib
-LIB1FILES=\
- $(SLB)$/fltshared.lib \
- $(SLB)$/$(TARGET).lib
-
-SHL1TARGET=$(TARGET)$(DLLPOSTFIX)
-
-SHL1STDLIBS=\
- $(XMLOFFLIB) \
- $(VCLLIB) \
- $(TOOLSLIB) \
- $(TKLIB) \
- $(COMPHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(CPPULIB) \
- $(SFXLIB) \
- $(SVLLIB) \
- $(DBTOOLSLIB) \
- $(UNOTOOLSLIB) \
- $(SO2LIB) \
- $(SALLIB)
-
-.IF "$(GUI)"=="OS2"
-SHL1STDLIBS+= \
- idba.lib
-.ELIF "$(GUI)"!="WNT" || "$(COM)"=="GCC"
-SHL1STDLIBS+= \
- -ldba$(DLLPOSTFIX)
-.ELSE
-SHL1STDLIBS+= \
- idba.lib
-.ENDIF
-
-
-SHL1DEPN=
-SHL1LIBS=$(LIB1TARGET)
-SHL1IMPLIB= i$(SHL1TARGET)
-# SHL1LIBS= $(SLB)$/$(TARGET).lib
-SHL1VERSIONMAP=$(SOLARENV)/src/component.map
-SHL1DEF= $(MISC)$/$(SHL1TARGET).def
-
-DEF1NAME=$(SHL1TARGET)
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
-ALLTAR : $(MISC)/dbaxml.component
-
-$(MISC)/dbaxml.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- dbaxml.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt dbaxml.component
diff --git a/dbaccess/source/filter/xml/xmlAutoStyle.cxx b/dbaccess/source/filter/xml/xmlAutoStyle.cxx
index 351ed7b7d075..0d0f2ba75381 100644
--- a/dbaccess/source/filter/xml/xmlAutoStyle.cxx
+++ b/dbaccess/source/filter/xml/xmlAutoStyle.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLAUTOSTYLE_HXX
#include "xmlAutoStyle.hxx"
-#endif
-#ifndef DBA_XMLHELPER_HXX
#include "xmlHelper.hxx"
-#endif
-#ifndef DBA_XMLEXPORT_HXX
#include "xmlExport.hxx"
-#endif
-#ifndef _XMLOFF_FAMILIES_HXX_
#include <xmloff/families.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
using namespace ::com::sun::star::uno;
@@ -107,3 +98,5 @@ OXMLAutoStylePoolP::~OXMLAutoStylePoolP()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlAutoStyle.hxx b/dbaccess/source/filter/xml/xmlAutoStyle.hxx
index b966d68908d5..6d3da1fa34aa 100644
--- a/dbaccess/source/filter/xml/xmlAutoStyle.hxx
+++ b/dbaccess/source/filter/xml/xmlAutoStyle.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -26,18 +27,10 @@
************************************************************************/
#ifndef DBA_XMLAUTOSTYLE_HXX
#define DBA_XMLAUTOSTYLE_HXX
-#ifndef _XMLOFF_PROPMAPPINGTYPES_HXX
#include <xmloff/maptype.hxx>
-#endif
-#ifndef _XMLOFF_XMLASTPLP_HXX
#include <xmloff/xmlaustp.hxx>
-#endif
-#ifndef _XMLOFF_XMLTYPES_HXX
#include <xmloff/xmltypes.hxx>
-#endif
-#ifndef _XMLOFF_PROPERTYSETMAPPER_HXX
#include <xmloff/xmlprmap.hxx>
-#endif
namespace dbaxml
{
@@ -64,3 +57,4 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLAUTOSTYLE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlColumn.cxx b/dbaccess/source/filter/xml/xmlColumn.cxx
index 4c9e20ba3b45..0517e9b13282 100644
--- a/dbaccess/source/filter/xml/xmlColumn.cxx
+++ b/dbaccess/source/filter/xml/xmlColumn.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,49 +28,21 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLCOLUMN_HXX
#include "xmlColumn.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLUCONV_HXX
#include <xmloff/xmluconv.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
#include <com/sun/star/container/XChild.hpp>
-#ifndef DBA_XMLSTYLEIMPORT_HXX
#include "xmlStyleImport.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -119,7 +92,7 @@ OXMLColumn::OXMLColumn( ODBFilter& rImport
m_sHelpMessage = sValue;
break;
case XML_TOK_COLUMN_VISIBILITY:
- m_bHidden = !sValue.equalsAscii("visible");
+ m_bHidden = !sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("visible"));
break;
case XML_TOK_COLUMN_TYPE_NAME:
sType = sValue;
@@ -128,10 +101,9 @@ OXMLColumn::OXMLColumn( ODBFilter& rImport
case XML_TOK_COLUMN_DEFAULT_VALUE:
if ( sValue.getLength() && sType.getLength() )
m_aDefaultValue <<= sValue;
- // SvXMLUnitConverter::convertAny(m_aDefaultValue,sType,sValue);
break;
case XML_TOK_COLUMN_VISIBLE:
- m_bHidden = sValue.equalsAscii("false");
+ m_bHidden = sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("false"));
break;
case XML_TOK_DEFAULT_CELL_STYLE_NAME:
m_sCellStyleName = sValue;
@@ -179,7 +151,7 @@ void OXMLColumn::EndElement()
pAutoStyle->FillPropertySet(xProp);
}
}
- } // if ( m_sStyleName.getLength() )
+ }
if ( m_sCellStyleName.getLength() )
{
const SvXMLStylesContext* pAutoStyles = GetOwnImport().GetAutoStyles();
@@ -196,7 +168,7 @@ void OXMLColumn::EndElement()
}
}
- } // if ( xFac.is() && m_sName.getLength() )
+ }
else if ( m_sCellStyleName.getLength() )
{
const SvXMLStylesContext* pAutoStyles = GetOwnImport().GetAutoStyles();
@@ -219,3 +191,5 @@ ODBFilter& OXMLColumn::GetOwnImport()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlColumn.hxx b/dbaccess/source/filter/xml/xmlColumn.hxx
index d4b9c9f5bc3b..e417e0398825 100644
--- a/dbaccess/source/filter/xml/xmlColumn.hxx
+++ b/dbaccess/source/filter/xml/xmlColumn.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLCOLUMN_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlComponent.cxx b/dbaccess/source/filter/xml/xmlComponent.cxx
index 9426a097adc3..88b08533e439 100644
--- a/dbaccess/source/filter/xml/xmlComponent.cxx
+++ b/dbaccess/source/filter/xml/xmlComponent.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,39 +28,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLCOMPONENT_HXX
#include "xmlComponent.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
namespace dbaxml
{
@@ -153,3 +132,5 @@ OXMLComponent::~OXMLComponent()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlComponent.hxx b/dbaccess/source/filter/xml/xmlComponent.hxx
index 2523bad6d112..1d950173b1b4 100644
--- a/dbaccess/source/filter/xml/xmlComponent.hxx
+++ b/dbaccess/source/filter/xml/xmlComponent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLCOMPONENT_HXX
#define DBA_XMLCOMPONENT_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
namespace dbaxml
@@ -62,3 +59,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLCOMPONENT_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlConnectionData.cxx b/dbaccess/source/filter/xml/xmlConnectionData.cxx
index fbf909a7a7af..c843312e633e 100644
--- a/dbaccess/source/filter/xml/xmlConnectionData.cxx
+++ b/dbaccess/source/filter/xml/xmlConnectionData.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,37 +28,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLCONNECTIONDATA_HXX_INCLUDED
#include "xmlConnectionData.hxx"
-#endif
-#ifndef DBA_XMLLOGIN_HXX
#include "xmlLogin.hxx"
-#endif
-#ifndef DBA_XMLTABLEFILTERLIST_HXX
#include "xmlTableFilterList.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
#include "xmlEnums.hxx"
#include "xmlDatabaseDescription.hxx"
#include "xmlConnectionResource.hxx"
#include "xmlstrings.hrc"
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
namespace dbaxml
{
@@ -116,7 +99,7 @@ SvXMLImportContext* OXMLConnectionData::CreateChildContext(
if ( !m_bFoundOne )
{
m_bFoundOne = true;
- OSL_ENSURE(0,"Not supported yet!");
+ OSL_FAIL("Not supported yet!");
}
break;
}
@@ -135,3 +118,5 @@ ODBFilter& OXMLConnectionData::GetOwnImport()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlConnectionData.hxx b/dbaccess/source/filter/xml/xmlConnectionData.hxx
index 6dac18107c30..2cf32047c99c 100644
--- a/dbaccess/source/filter/xml/xmlConnectionData.hxx
+++ b/dbaccess/source/filter/xml/xmlConnectionData.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLCONNECTIONDATA_HXX_INCLUDED
#define DBA_XMLCONNECTIONDATA_HXX_INCLUDED
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
#include <vector>
namespace dbaxml
@@ -58,3 +55,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLCONNECTIONDATA_HXX_INCLUDED
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlConnectionResource.cxx b/dbaccess/source/filter/xml/xmlConnectionResource.cxx
index bd3756bbd4eb..1f490360dd61 100644
--- a/dbaccess/source/filter/xml/xmlConnectionResource.cxx
+++ b/dbaccess/source/filter/xml/xmlConnectionResource.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLCONNECTIONRESOURCE_HXX_INCLUDED
#include "xmlConnectionResource.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
namespace dbaxml
{
@@ -94,7 +77,7 @@ OXMLConnectionResource::OXMLConnectionResource( ODBFilter& rImport,
{
xDataSource->setPropertyValue(PROPERTY_URL,makeAny(sValue));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -128,3 +111,5 @@ OXMLConnectionResource::~OXMLConnectionResource()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlConnectionResource.hxx b/dbaccess/source/filter/xml/xmlConnectionResource.hxx
index 2645dba69bb2..ea6be03655fb 100644
--- a/dbaccess/source/filter/xml/xmlConnectionResource.hxx
+++ b/dbaccess/source/filter/xml/xmlConnectionResource.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLCONNECTIONRESOURCE_HXX_INCLUDED
#define DBA_XMLCONNECTIONRESOURCE_HXX_INCLUDED
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
#include <vector>
namespace dbaxml
@@ -53,3 +50,4 @@ namespace dbaxml
#endif // DBA_XMLCONNECTIONRESOURCE_HXX_INCLUDED
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSource.cxx b/dbaccess/source/filter/xml/xmlDataSource.cxx
index 7fe9ee914ba6..62431e9b01a4 100644
--- a/dbaccess/source/filter/xml/xmlDataSource.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSource.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,48 +28,20 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLDATASOURCE_HXX
#include "xmlDataSource.hxx"
-#endif
-#ifndef DBA_XMLLOGIN_HXX
#include "xmlLogin.hxx"
-#endif
-#ifndef DBA_XMLTABLEFILTERLIST_HXX
#include "xmlTableFilterList.hxx"
-#endif
-#ifndef DBA_XMLDATASOURCEINFO_HXX
#include "xmlDataSourceInfo.hxx"
-#endif
-#ifndef DBA_XMLDATASOURCESETTINGS_HXX
#include "xmlDataSourceSettings.hxx"
-#endif
-#ifndef DBA_XMLDATASOURCESETTING_HXX
#include "xmlDataSourceSetting.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
#include "xmlConnectionData.hxx"
namespace dbaxml
@@ -115,7 +88,7 @@ OXMLDataSource::OXMLDataSource( ODBFilter& rImport,
{
xDataSource->setPropertyValue(PROPERTY_URL,makeAny(sValue));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -126,7 +99,7 @@ OXMLDataSource::OXMLDataSource( ODBFilter& rImport,
xDataSource->setPropertyValue(PROPERTY_SUPPRESSVERSIONCL,makeAny(sValue == s_sTRUE ? sal_True : sal_False));
bFoundSuppressVersionColumns = true;
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -173,13 +146,13 @@ OXMLDataSource::OXMLDataSource( ODBFilter& rImport,
break;
case XML_TOK_BOOLEAN_COMPARISON_MODE:
aProperty.Name = PROPERTY_BOOLEANCOMPARISONMODE;
- if ( sValue.equalsAscii("equal-integer") )
+ if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("equal-integer")) )
aProperty.Value <<= sal_Int32(0);
- else if ( sValue.equalsAscii("is-boolean") )
+ else if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("is-boolean")) )
aProperty.Value <<= sal_Int32(1);
- else if ( sValue.equalsAscii("equal-boolean") )
+ else if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("equal-boolean")) )
aProperty.Value <<= sal_Int32(2);
- else if ( sValue.equalsAscii("equal-use-only-zero") )
+ else if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("equal-use-only-zero")) )
aProperty.Value <<= sal_Int32(3);
break;
case XML_TOK_USE_CATALOG:
@@ -230,7 +203,7 @@ OXMLDataSource::OXMLDataSource( ODBFilter& rImport,
{
xDataSource->setPropertyValue(PROPERTY_SUPPRESSVERSIONCL,makeAny(sal_True));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -307,3 +280,5 @@ ODBFilter& OXMLDataSource::GetOwnImport()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSource.hxx b/dbaccess/source/filter/xml/xmlDataSource.hxx
index 2b6a640f6576..87038f05ef30 100644
--- a/dbaccess/source/filter/xml/xmlDataSource.hxx
+++ b/dbaccess/source/filter/xml/xmlDataSource.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLDATASOURCE_HXX
#define DBA_XMLDATASOURCE_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
#include <vector>
namespace dbaxml
@@ -64,3 +61,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLDATASOURCE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx b/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx
index 440703b967f5..c1039f76c82b 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceInfo.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLDATASOURCEINFO_HXX
#include "xmlDataSourceInfo.hxx"
-#endif
-#ifndef DBA_XMLDATASOURCE_HXX
#include "xmlDataSource.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#include <vector>
namespace dbaxml
@@ -150,7 +131,7 @@ OXMLDataSourceInfo::OXMLDataSourceInfo( ODBFilter& rImport
aProperty.Name = INFO_THOUSANDSDELIMITER;
aProperty.Value <<= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(","));
rImport.addInfo(aProperty);
- } // if ( !bFoundThousand )
+ }
}
if ( XML_TOK_FONT_CHARSET == _nToken && !bFoundCharset )
{
@@ -171,3 +152,5 @@ OXMLDataSourceInfo::~OXMLDataSourceInfo()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSourceInfo.hxx b/dbaccess/source/filter/xml/xmlDataSourceInfo.hxx
index 86832af5de77..89f9dde6a242 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceInfo.hxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceInfo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBA_XMLDATASOURCEINFO_HXX
#define DBA_XMLDATASOURCEINFO_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
namespace dbaxml
{
@@ -50,3 +49,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLDATASOURCEINFO_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx b/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
index 3732d3a6ca78..2be63bdd00d5 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceSetting.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLDATASOURCESETTING_HXX
#include "xmlDataSourceSetting.hxx"
-#endif
-#ifndef DBA_XMLDATASOURCE_HXX
#include "xmlDataSource.hxx"
-#endif
-#ifndef _XMLOFF_XMLUCONV_HXX
#include <xmloff/xmluconv.hxx>
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -92,7 +73,7 @@ OXMLDataSourceSetting::OXMLDataSourceSetting( ODBFilter& rImport
switch( rTokenMap.Get( nPrefix, sLocalName ) )
{
case XML_TOK_DATA_SOURCE_SETTING_IS_LIST:
- m_bIsList = sValue.equalsAscii("true");
+ m_bIsList = sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("true"));
break;
case XML_TOK_DATA_SOURCE_SETTING_TYPE:
{
@@ -207,7 +188,7 @@ Any OXMLDataSourceSetting::convertString(const ::com::sun::star::uno::Type& _rEx
{
case TypeClass_BOOLEAN: // sal_Bool
{
- sal_Bool bValue;
+ bool bValue;
#if OSL_DEBUG_LEVEL > 0
sal_Bool bSuccess =
#endif
@@ -239,7 +220,7 @@ Any OXMLDataSourceSetting::convertString(const ::com::sun::star::uno::Type& _rEx
}
case TypeClass_HYPER:
{
- OSL_ENSURE(sal_False, "OXMLDataSourceSetting::convertString: 64-bit integers not implemented yet!");
+ OSL_FAIL("OXMLDataSourceSetting::convertString: 64-bit integers not implemented yet!");
}
break;
case TypeClass_DOUBLE:
@@ -260,7 +241,7 @@ Any OXMLDataSourceSetting::convertString(const ::com::sun::star::uno::Type& _rEx
aReturn <<= _rReadCharacters;
break;
default:
- OSL_ENSURE(sal_False, "OXMLDataSourceSetting::convertString: invalid type class!");
+ OSL_FAIL("OXMLDataSourceSetting::convertString: invalid type class!");
}
return aReturn;
@@ -269,3 +250,5 @@ Any OXMLDataSourceSetting::convertString(const ::com::sun::star::uno::Type& _rEx
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSourceSetting.hxx b/dbaccess/source/filter/xml/xmlDataSourceSetting.hxx
index e1e0891069a8..4740a7834306 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceSetting.hxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceSetting.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBA_XMLDATASOURCESETTING_HXX
#define DBA_XMLDATASOURCESETTING_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
namespace dbaxml
{
@@ -79,3 +74,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLDATASOURCESETTING_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSourceSettings.cxx b/dbaccess/source/filter/xml/xmlDataSourceSettings.cxx
index b52abdbb5b3e..c4458924452c 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceSettings.cxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceSettings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLDATASOURCESETTINGS_HXX
#include "xmlDataSourceSettings.hxx"
-#endif
-#ifndef DBA_XMLDATASOURCESETTING_HXX
#include "xmlDataSourceSetting.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#include <vector>
@@ -112,3 +93,5 @@ ODBFilter& OXMLDataSourceSettings::GetOwnImport()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDataSourceSettings.hxx b/dbaccess/source/filter/xml/xmlDataSourceSettings.hxx
index df9690dafd0f..67d3f02e432d 100644
--- a/dbaccess/source/filter/xml/xmlDataSourceSettings.hxx
+++ b/dbaccess/source/filter/xml/xmlDataSourceSettings.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBA_XMLDATASOURCESETTINGS_HXX
#define DBA_XMLDATASOURCESETTINGS_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
namespace dbaxml
{
@@ -51,3 +50,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLDATASOURCESETTINGS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDatabase.cxx b/dbaccess/source/filter/xml/xmlDatabase.cxx
index 179495869190..6795103be666 100644
--- a/dbaccess/source/filter/xml/xmlDatabase.cxx
+++ b/dbaccess/source/filter/xml/xmlDatabase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -156,3 +157,5 @@ void OXMLDatabase::EndElement()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDatabase.hxx b/dbaccess/source/filter/xml/xmlDatabase.hxx
index 3a41f3d01c7f..ed70500fdca3 100644
--- a/dbaccess/source/filter/xml/xmlDatabase.hxx
+++ b/dbaccess/source/filter/xml/xmlDatabase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBA_XMLDATABASE_HXX
#define DBA_XMLDATABASE_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
namespace dbaxml
{
@@ -54,3 +53,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLDATABASE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDatabaseDescription.cxx b/dbaccess/source/filter/xml/xmlDatabaseDescription.cxx
index 6c423b26d4ad..efe2e7237c6c 100644
--- a/dbaccess/source/filter/xml/xmlDatabaseDescription.cxx
+++ b/dbaccess/source/filter/xml/xmlDatabaseDescription.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,34 +28,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLDATABASEDESCRIPTION_HXX_INCLUDED
#include "xmlDatabaseDescription.hxx"
-#endif
-#ifndef DBA_XMLLOGIN_HXX
#include "xmlLogin.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
#include "xmlEnums.hxx"
#include "xmlFileBasedDatabase.hxx"
#include "xmlServerDatabase.hxx"
#include "xmlstrings.hrc"
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
namespace dbaxml
{
@@ -120,3 +105,5 @@ ODBFilter& OXMLDatabaseDescription::GetOwnImport()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDatabaseDescription.hxx b/dbaccess/source/filter/xml/xmlDatabaseDescription.hxx
index 03c4cd94a8ec..6a056412e57a 100644
--- a/dbaccess/source/filter/xml/xmlDatabaseDescription.hxx
+++ b/dbaccess/source/filter/xml/xmlDatabaseDescription.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLDATABASEDESCRIPTION_HXX_INCLUDED
#define DBA_XMLDATABASEDESCRIPTION_HXX_INCLUDED
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
#include <vector>
namespace dbaxml
@@ -58,3 +55,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLDATABASEDESCRIPTION_HXX_INCLUDED
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDocuments.cxx b/dbaccess/source/filter/xml/xmlDocuments.cxx
index 0cdd485a9787..6a0251a48420 100644
--- a/dbaccess/source/filter/xml/xmlDocuments.cxx
+++ b/dbaccess/source/filter/xml/xmlDocuments.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,39 +28,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLDOCUMENTS_HXX
#include "xmlDocuments.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef DBA_XMLQUERY_HXX
#include "xmlQuery.hxx"
-#endif
-#ifndef DBA_XMLTABLE_HXX
#include "xmlTable.hxx"
-#endif
-#ifndef DBA_XMLCOMPONENT_HXX
#include "xmlComponent.hxx"
-#endif
-#ifndef DBA_XMLHIERARCHYCOLLECTION_HXX
#include "xmlHierarchyCollection.hxx"
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -126,7 +105,6 @@ SvXMLImportContext* OXMLDocuments::CreateChildContext(
GetOwnImport().GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
pContext = new OXMLComponent( GetOwnImport(), nPrefix, rLocalName,xAttrList,m_xContainer,m_sComponentServiceName );
break;
- // case XML_TOK_QUERY_COLLECTION:
case XML_TOK_COMPONENT_COLLECTION:
GetOwnImport().GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
pContext = new OXMLHierarchyCollection( GetOwnImport(), nPrefix, rLocalName,xAttrList,m_xContainer,m_sCollectionServiceName,m_sComponentServiceName );
@@ -148,3 +126,5 @@ ODBFilter& OXMLDocuments::GetOwnImport()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlDocuments.hxx b/dbaccess/source/filter/xml/xmlDocuments.hxx
index 26444e9e5454..1a84dfa4c94e 100644
--- a/dbaccess/source/filter/xml/xmlDocuments.hxx
+++ b/dbaccess/source/filter/xml/xmlDocuments.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBA_XMLDOCUMENTS_HXX
#define DBA_XMLDOCUMENTS_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
namespace dbaxml
{
@@ -77,3 +72,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLDOCUMENTS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlEnums.hxx b/dbaccess/source/filter/xml/xmlEnums.hxx
index 2298b13c58e1..2248050d09b3 100644
--- a/dbaccess/source/filter/xml/xmlEnums.hxx
+++ b/dbaccess/source/filter/xml/xmlEnums.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -170,3 +171,5 @@ namespace dbaxml
} // namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLENUMS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlExport.cxx b/dbaccess/source/filter/xml/xmlExport.cxx
index a3153c610244..7e8457d34c6e 100644
--- a/dbaccess/source/filter/xml/xmlExport.cxx
+++ b/dbaccess/source/filter/xml/xmlExport.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,6 +60,7 @@
#include <tools/diagnose_ex.h>
#include <connectivity/DriversConfig.hxx>
#include <connectivity/dbtools.hxx>
+#include <sal/macros.h>
#include <boost/optional.hpp>
@@ -116,13 +118,13 @@ namespace dbaxml
//---------------------------------------------------------------------
::rtl::OUString SAL_CALL ODBExportHelper::getImplementationName_Static( ) throw (RuntimeException)
{
- return ::rtl::OUString::createFromAscii("com.sun.star.comp.sdb.XMLSettingsExporter");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.sdb.XMLSettingsExporter"));
}
//---------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL ODBExportHelper::getSupportedServiceNames_Static( ) throw(RuntimeException)
{
Sequence< ::rtl::OUString > aSupported(1);
- aSupported[0] = ::rtl::OUString::createFromAscii("com.sun.star.document.ExportFilter");
+ aSupported[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.ExportFilter"));
return aSupported;
}
@@ -135,13 +137,13 @@ namespace dbaxml
//---------------------------------------------------------------------
::rtl::OUString SAL_CALL ODBFullExportHelper::getImplementationName_Static( ) throw (RuntimeException)
{
- return ::rtl::OUString::createFromAscii("com.sun.star.comp.sdb.XMLFullExporter");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.sdb.XMLFullExporter"));
}
//---------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL ODBFullExportHelper::getSupportedServiceNames_Static( ) throw(RuntimeException)
{
Sequence< ::rtl::OUString > aSupported(1);
- aSupported[0] = ::rtl::OUString::createFromAscii("com.sun.star.document.ExportFilter");
+ aSupported[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.ExportFilter"));
return aSupported;
}
@@ -177,7 +179,7 @@ namespace dbaxml
return s_sTypeInteger;
default:
- OSL_ENSURE( false, "lcl_implGetPropertyXMLType: unsupported value type!" );
+ OSL_FAIL( "lcl_implGetPropertyXMLType: unsupported value type!" );
return s_sTypeDouble;
}
}
@@ -239,36 +241,32 @@ ODBExport::ODBExport(const Reference< XMultiServiceFactory >& _rxMSF,sal_uInt16
m_xExportHelper = new SvXMLExportPropertyMapper(GetTableStylesPropertySetMapper());
m_xColumnExportHelper = new OSpecialHanldeXMLExportPropertyMapper(GetColumnStylesPropertySetMapper());
- //UniReference < XMLPropertySetMapper > xCellStylesPropertySetMapper = new XMLPropertySetMapper(OXMLHelper::GetCellStylesPropertySetMapper(),m_xPropHdlFactory);
- //m_xCellExportHelper = new OSpecialHanldeXMLExportPropertyMapper(xCellStylesPropertySetMapper);
- //m_xCellExportHelper = new OSpecialHanldeXMLExportPropertyMapper(GetCellStylesPropertySetMapper());
- //m_xCellExportHelper->ChainExportMapper(XMLTextParagraphExport::CreateParaExtPropMapper(*this));
m_xCellExportHelper = new OSpecialHanldeXMLExportPropertyMapper(GetCellStylesPropertySetMapper());
m_xRowExportHelper = new OSpecialHanldeXMLExportPropertyMapper(OXMLHelper::GetRowStylesPropertySetMapper());
GetAutoStylePool()->AddFamily(
XML_STYLE_FAMILY_TABLE_TABLE,
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_TABLE_STYLES_NAME ),
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_TABLE_STYLES_NAME )),
m_xExportHelper.get(),
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_TABLE_STYLES_PREFIX ));
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_TABLE_STYLES_PREFIX )));
GetAutoStylePool()->AddFamily(
XML_STYLE_FAMILY_TABLE_COLUMN,
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_COLUMN_STYLES_NAME ),
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_COLUMN_STYLES_NAME )),
m_xColumnExportHelper.get(),
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_COLUMN_STYLES_PREFIX ));
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_COLUMN_STYLES_PREFIX )));
GetAutoStylePool()->AddFamily(
XML_STYLE_FAMILY_TABLE_CELL,
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_CELL_STYLES_NAME ),
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_CELL_STYLES_NAME )),
m_xCellExportHelper.get(),
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_CELL_STYLES_PREFIX ));
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_CELL_STYLES_PREFIX )));
GetAutoStylePool()->AddFamily(
XML_STYLE_FAMILY_TABLE_ROW,
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_ROW_STYLES_NAME ),
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_ROW_STYLES_NAME )),
m_xRowExportHelper.get(),
- rtl::OUString::createFromAscii( XML_STYLE_FAMILY_TABLE_ROW_STYLES_PREFIX ));
+ rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( XML_STYLE_FAMILY_TABLE_ROW_STYLES_PREFIX )));
}
// -----------------------------------------------------------------------------
IMPLEMENT_SERVICE_INFO1_STATIC( ODBExport, "com.sun.star.comp.sdb.DBExportFilter", "com.sun.star.document.ExportFilter")
@@ -370,7 +368,7 @@ void ODBExport::exportDataSource()
};
bool bIsXMLDefault = false;
- for ( size_t i=0; i < sizeof( aTokens ) / sizeof( aTokens[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aTokens ); ++i )
{
if ( pProperties->Name == aTokens[i].sPropertyName )
{
@@ -406,15 +404,15 @@ void ODBExport::exportDataSource()
{
sal_Int32 nValue = 0;
aValue >>= nValue;
- if ( sValue.equalsAscii("0") )
+ if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("0")) )
sValue = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("equal-integer"));
- else if ( sValue.equalsAscii("1") )
+ else if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("1")) )
sValue = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("is-boolean"));
- else if ( sValue.equalsAscii("2") )
+ else if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("2")) )
sValue = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("equal-boolean"));
- else if ( sValue.equalsAscii("3") )
+ else if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("3")) )
sValue = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("equal-use-only-zero"));
- if ( sValue.equalsAscii("equal-integer") )
+ if ( sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("equal-integer")) )
continue;
eToken = XML_BOOLEAN_COMPARISON_MODE;
}
@@ -504,7 +502,7 @@ void ODBExport::exportApplicationConnectionSettings(const TSettingsMap& _aSettin
,XML_MAX_ROW_COUNT
,XML_SUPPRESS_VERSION_COLUMNS
};
- for (size_t i = 0; i< sizeof(pSettings)/sizeof(pSettings[0]); ++i)
+ for (size_t i = 0; i< SAL_N_ELEMENTS(pSettings); ++i)
{
TSettingsMap::const_iterator aFind = _aSettings.find(pSettings[i]);
if ( aFind != _aSettings.end() )
@@ -537,7 +535,7 @@ void ODBExport::exportDriverSettings(const TSettingsMap& _aSettings)
,XML_IS_FIRST_ROW_HEADER_LINE
,XML_PARAMETER_NAME_SUBSTITUTION
};
- for (size_t i = 0; i< sizeof(pSettings)/sizeof(pSettings[0]); ++i)
+ for (size_t i = 0; i< SAL_N_ELEMENTS(pSettings); ++i)
{
TSettingsMap::const_iterator aFind = _aSettings.find(pSettings[i]);
if ( aFind != _aSettings.end() )
@@ -572,7 +570,7 @@ void ODBExport::exportConnectionData()
sURL.append(sal_Unicode('/'));
AddAttribute(XML_NAMESPACE_XLINK,XML_HREF,GetRelativeReference(sURL.makeStringAndClear()));
- } // if ( sOrigUrl == sFileName )
+ }
else
AddAttribute(XML_NAMESPACE_XLINK,XML_HREF,sOrigUrl);
AddAttribute(XML_NAMESPACE_DB,XML_MEDIA_TYPE,m_aTypeCollection.getMediaType(sValue));
@@ -593,7 +591,6 @@ void ODBExport::exportConnectionData()
}
catch(const Exception&)
{
- // nii
}
SvXMLElementExport aFileBasedDB(*this,XML_NAMESPACE_DB, XML_FILE_BASED_DATABASE, sal_True, sal_True);
}
@@ -640,7 +637,7 @@ void ODBExport::exportConnectionData()
};
for ( size_t i=0;
- i < sizeof( aProperties ) / sizeof( aProperties[0] );
+ i < SAL_N_ELEMENTS( aProperties );
++i
)
{
@@ -742,7 +739,7 @@ void ODBExport::exportDataSourceSettings()
pSequenceIterator.reset( new OSequenceIterator< Any >( aIter->Value ) );
break;
default:
- OSL_ENSURE(sal_False, "unsupported sequence type !");
+ OSL_FAIL("unsupported sequence type !");
break;
}
if ( pSequenceIterator.get() )
@@ -1160,7 +1157,7 @@ void ODBExport::exportAutoStyle(XPropertySet* _xProp)
};
::std::vector< XMLPropertyState > aPropertyStates;
- for (size_t i = 0 ; i < sizeof(pExportHelper)/sizeof(pExportHelper[0]); ++i)
+ for (size_t i = 0 ; i < SAL_N_ELEMENTS(pExportHelper); ++i)
{
aPropertyStates = pExportHelper[i].first->Filter(_xProp);
if ( !aPropertyStates.empty() )
@@ -1192,7 +1189,7 @@ void ODBExport::exportAutoStyle(XPropertySet* _xProp)
exportCollection(xCollection,XML_TOKEN_INVALID,XML_TOKEN_INVALID,sal_False,aMemFunc);
}
}
- catch(Exception&)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -1204,7 +1201,7 @@ void ODBExport::exportAutoStyle(XPropertySet* _xProp)
TExportPropMapperPair(m_xColumnExportHelper,TEnumMapperPair(&m_aAutoStyleNames,XML_STYLE_FAMILY_TABLE_COLUMN ))
,TExportPropMapperPair(m_xCellExportHelper,TEnumMapperPair(&m_aCellAutoStyleNames,XML_STYLE_FAMILY_TABLE_CELL))
};
- for (size_t i = 0 ; i < sizeof(pExportHelper)/sizeof(pExportHelper[0]); ++i)
+ for (size_t i = 0 ; i < SAL_N_ELEMENTS(pExportHelper); ++i)
{
::std::vector< XMLPropertyState > aPropStates = pExportHelper[i].first->Filter( _xProp );
if ( !aPropStates.empty() )
@@ -1232,9 +1229,9 @@ void ODBExport::exportAutoStyle(XPropertySet* _xProp)
}
}
++aItr;
- } // while ( aItr != aEnd )
+ }
- } // if ( !aPropStates.empty() )
+ }
if ( XML_STYLE_FAMILY_TABLE_CELL == pExportHelper[i].second.second )
::std::copy( m_aCurrentPropertyStates.begin(), m_aCurrentPropertyStates.end(), ::std::back_inserter( aPropStates ));
if ( !aPropStates.empty() )
@@ -1326,9 +1323,9 @@ void ODBExport::GetViewSettings(Sequence<PropertyValue>& aProps)
}
aProps[nLength].Value <<= aQueries;
}
- catch(Exception)
+ catch(const Exception&)
{
- OSL_ENSURE(0,"ODBExport::GetViewSettings: Exception catched!");
+ OSL_FAIL("ODBExport::GetViewSettings: Exception caught!");
}
}
}
@@ -1353,9 +1350,9 @@ void ODBExport::GetConfigurationSettings(Sequence<PropertyValue>& aProps)
aProps[nLength].Value = aValue;
}
}
- catch(Exception)
+ catch(const Exception&)
{
- OSL_ENSURE(0,"Could not access layout information from the data source!");
+ OSL_FAIL("Could not access layout information from the data source!");
}
}
}
@@ -1386,7 +1383,7 @@ void ODBExport::GetConfigurationSettings(Sequence<PropertyValue>& aProps)
GetMM100UnitConverter().convertNumber(aBuffer, getINT32(_rValue));
break;
default:
- OSL_ENSURE(0,"ODBExport::implConvertAny: Invalid type");
+ OSL_FAIL("ODBExport::implConvertAny: Invalid type");
}
return aBuffer.makeStringAndClear();
@@ -1453,3 +1450,5 @@ void ODBExport::collectComponentStyles()
// -----------------------------------------------------------------------------
}// dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlExport.hxx b/dbaccess/source/filter/xml/xmlExport.hxx
index 7c1b64952bed..8dc662f85705 100644
--- a/dbaccess/source/filter/xml/xmlExport.hxx
+++ b/dbaccess/source/filter/xml/xmlExport.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,70 +29,28 @@
#ifndef DBA_XMLEXPORT_HXX
#define DBA_XMLEXPORT_HXX
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMED_HPP_
#include <com/sun/star/container/XNamed.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XFILTER_HPP_
#include <com/sun/star/document/XFilter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XIMPORTER_HPP_
#include <com/sun/star/document/XImporter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XEXPORTER_HPP_
#include <com/sun/star/document/XExporter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XINITIALIZATION_HPP_
#include <com/sun/star/lang/XInitialization.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XCOMPONENT_HPP_
#include <com/sun/star/lang/XComponent.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XACTIVEDATASOURCE_HPP_
#include <com/sun/star/io/XActiveDataSource.hpp>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _UNOTOOLS_TEMPFILE_HXX
#include <unotools/tempfile.hxx>
-#endif
-#ifndef _UNOTOOLS_LOCALFILEHELPER_HXX
#include <unotools/localfilehelper.hxx>
-#endif
-#ifndef _UNTOOLS_UCBSTREAMHELPER_HXX
#include <unotools/ucbstreamhelper.hxx>
-#endif
-#ifndef _XMLOFF_XMLEXP_HXX
#include <xmloff/xmlexp.hxx>
-#endif
-#ifndef _XMLOFF_XMLIMP_HXX
#include <xmloff/xmlimp.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
#include "dsntypes.hxx"
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
#include <memory>
@@ -241,3 +200,5 @@ public:
} // dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLEXPORT_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlFileBasedDatabase.cxx b/dbaccess/source/filter/xml/xmlFileBasedDatabase.cxx
index a0b5e18f3904..130d1e04b525 100644
--- a/dbaccess/source/filter/xml/xmlFileBasedDatabase.cxx
+++ b/dbaccess/source/filter/xml/xmlFileBasedDatabase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLFILEBASEDDATABASE_HXX_INCLUDED
#include "xmlFileBasedDatabase.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
#include <comphelper/sequence.hxx>
#include <svl/filenotation.hxx>
#include <unotools/pathoptions.hxx>
@@ -134,7 +117,7 @@ OXMLFileBasedDatabase::OXMLFileBasedDatabase( ODBFilter& rImport,
{
xDataSource->setPropertyValue(PROPERTY_URL,makeAny(sURL));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -151,3 +134,5 @@ OXMLFileBasedDatabase::~OXMLFileBasedDatabase()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlFileBasedDatabase.hxx b/dbaccess/source/filter/xml/xmlFileBasedDatabase.hxx
index 2e5a957ebad9..9f58f4b0f03f 100644
--- a/dbaccess/source/filter/xml/xmlFileBasedDatabase.hxx
+++ b/dbaccess/source/filter/xml/xmlFileBasedDatabase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLFILEBASEDDATABASE_HXX_INCLUDED
#define DBA_XMLFILEBASEDDATABASE_HXX_INCLUDED
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
#include <vector>
namespace dbaxml
@@ -52,3 +49,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLFILEBASEDDATABASE_HXX_INCLUDED
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlHelper.cxx b/dbaccess/source/filter/xml/xmlHelper.cxx
index 357baca253d6..a1418593ad0f 100644
--- a/dbaccess/source/filter/xml/xmlHelper.cxx
+++ b/dbaccess/source/filter/xml/xmlHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,39 +28,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLHELPER_HXX
#include "xmlHelper.hxx"
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _COM_SUN_STAR_AWT_TEXTALIGN_HPP_
#include <com/sun/star/awt/TextAlign.hpp>
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef _XMLOFF_CONTEXTID_HXX_
#include <xmloff/contextid.hxx>
-#endif
-#ifndef _XMLOFF_XMLCONSTANTSPROPERTYHANDLER_HXX
#include <xmloff/XMLConstantsPropertyHandler.hxx>
-#endif
-#ifndef _XMLOFF_XMLEMENT_HXX
#include <xmloff/xmlement.hxx>
-#endif
-#ifndef _COM_SUN_STAR_AWT_TEXTALIGN_HPP_
#include <com/sun/star/awt/TextAlign.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -112,34 +91,6 @@ UniReference < XMLPropertySetMapper > OXMLHelper::GetTableStylesPropertySetMappe
{
static const XMLPropertyMapEntry s_aTableStylesProperties[] =
{
- //MAP_CONST( PROPERTY_FONTNAME, XML_NAMESPACE_STYLE, XML_FONT_NAME, XML_TYPE_STRING, 0 ),
- //MAP_CONST( PROPERTY_TEXTCOLOR, XML_NAMESPACE_FO, XML_COLOR, XML_TYPE_COLOR, 0 ),
- //MAP_CONST( PROPERTY_TEXTLINECOLOR, XML_NAMESPACE_STYLE, XML_TEXT_UNDERLINE_COLOR, XML_TYPE_TEXT_UNDERLINE_COLOR|MID_FLAG_MULTI_PROPERTY, 0 ),
-
- //MAP_CONST( PROPERTY_TEXTRELIEF, XML_NAMESPACE_STYLE, XML_FONT_RELIEF, XML_TYPE_TEXT_FONT_RELIEF|MID_FLAG_MULTI_PROPERTY, 0 ),
- //MAP_CONST( PROPERTY_TEXTEMPHASIS, XML_NAMESPACE_STYLE, XML_TEXT_EMPHASIZE, XML_TYPE_CONTROL_TEXT_EMPHASIZE, 0 ),
- //MAP_CONST( PROPERTY_FONTCHARWIDTH, XML_NAMESPACE_STYLE, XML_FONT_CHAR_WIDTH, XML_TYPE_NUMBER16, 0 ),
- //MAP_CONST( PROPERTY_FONTCHARSET, XML_NAMESPACE_STYLE, XML_FONT_CHARSET, XML_TYPE_TEXT_FONTENCODING, 0 ),
- //MAP_CONST( PROPERTY_FONTFAMILY, XML_NAMESPACE_STYLE, XML_FONT_FAMILY_GENERIC, XML_TYPE_TEXT_FONTFAMILY, 0 ),
- //MAP_CONST( PROPERTY_FONTHEIGHT, XML_NAMESPACE_FO, XML_FONT_SIZE, XML_TYPE_MEASURE16, 0 ),
- //MAP_CONST( PROPERTY_FONTKERNING, XML_NAMESPACE_STYLE, XML_LETTER_KERNING, XML_TYPE_BOOL, 0 ),
- //
- //MAP_CONST( PROPERTY_FONTORIENTATION, XML_NAMESPACE_STYLE, XML_ROTATION_ANGLE, XML_TYPE_ROTATION_ANGLE, 0 ),
- //MAP_CONST( PROPERTY_FONTPITCH, XML_NAMESPACE_STYLE, XML_FONT_PITCH, XML_TYPE_TEXT_FONTPITCH, 0 ),
- //MAP_CONST( PROPERTY_FONTSLANT, XML_NAMESPACE_FO, XML_FONT_STYLE, XML_TYPE_TEXT_POSTURE, 0 ),
- //MAP_CONST_ASCII( "CharStrikeout", XML_NAMESPACE_STYLE, XML_TEXT_LINE_THROUGH_STYLE, XML_TYPE_TEXT_CROSSEDOUT_STYLE|MID_FLAG_MERGE_PROPERTY, 0),
- //MAP_CONST_ASCII( "CharStrikeout", XML_NAMESPACE_STYLE, XML_TEXT_LINE_THROUGH_TYPE, XML_TYPE_TEXT_CROSSEDOUT_TYPE|MID_FLAG_MERGE_PROPERTY, 0),
- //MAP_CONST_ASCII( "CharStrikeout", XML_NAMESPACE_STYLE, XML_TEXT_LINE_THROUGH_WIDTH, XML_TYPE_TEXT_CROSSEDOUT_WIDTH|MID_FLAG_MERGE_PROPERTY, 0),
- //MAP_CONST_ASCII( "CharStrikeout", XML_NAMESPACE_STYLE, XML_TEXT_LINE_THROUGH_TEXT, XML_TYPE_TEXT_CROSSEDOUT_TEXT|MID_FLAG_MERGE_PROPERTY, 0),
- //MAP_CONST( PROPERTY_FONTSTYLENAME, XML_NAMESPACE_STYLE, XML_FONT_STYLE_NAME, XML_TYPE_STRING, 0 ),
- //MAP_CONST_ASCII( "CharUnderline", XML_NAMESPACE_STYLE, XML_TEXT_UNDERLINE_STYLE, XML_TYPE_TEXT_UNDERLINE_STYLE|MID_FLAG_MERGE_PROPERTY, 0 ),
- //MAP_CONST_ASCII( "CharUnderline", XML_NAMESPACE_STYLE, XML_TEXT_UNDERLINE_TYPE, XML_TYPE_TEXT_UNDERLINE_TYPE|MID_FLAG_MERGE_PROPERTY, 0 ),
- //MAP_CONST_ASCII( "CharUnderline", XML_NAMESPACE_STYLE, XML_TEXT_UNDERLINE_WIDTH, XML_TYPE_TEXT_UNDERLINE_WIDTH|MID_FLAG_MERGE_PROPERTY, 0 ),
- //MAP_CONST_ASCII( "CharUnderlineColor", XML_NAMESPACE_STYLE, XML_TEXT_UNDERLINE_COLOR, XML_TYPE_TEXT_UNDERLINE_COLOR|MID_FLAG_MULTI_PROPERTY, 0 ),
- //MAP_CONST_ASCII( "CharUnderlineHasColor",XML_NAMESPACE_STYLE, XML_TEXT_UNDERLINE_COLOR, XML_TYPE_TEXT_UNDERLINE_HASCOLOR|MID_FLAG_MERGE_ATTRIBUTE, 0 ),
- //MAP_CONST( PROPERTY_FONTWEIGHT, XML_NAMESPACE_FO, XML_FONT_WEIGHT, XML_TYPE_TEXT_WEIGHT, 0 ),
- //MAP_CONST( PROPERTY_FONTWIDTH, XML_NAMESPACE_STYLE, XML_FONT_WIDTH, XML_TYPE_FONT_WIDTH, 0 ),
- //MAP_CONST( PROPERTY_FONTWORDLINEMODE, XML_NAMESPACE_STYLE, XML_TEXT_UNDERLINE_MODE, XML_TYPE_TEXT_LINE_MODE, 0 ),
MAP_END()
};
UniReference < XMLPropertyHandlerFactory> xFac = new ::xmloff::OControlPropertyHandlerFactory();
@@ -216,3 +167,4 @@ UniReference < XMLPropertySetMapper > OXMLHelper::GetRowStylesPropertySetMapper(
// -----------------------------------------------------------------------------
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlHelper.hxx b/dbaccess/source/filter/xml/xmlHelper.hxx
index 58853f4b1b17..fcc9ca8af74e 100644
--- a/dbaccess/source/filter/xml/xmlHelper.hxx
+++ b/dbaccess/source/filter/xml/xmlHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBA_XMLHELPER_HXX
#define DBA_XMLHELPER_HXX
-#ifndef _XMLOFF_PROPERTYSETMAPPER_HXX
#include <xmloff/xmlprmap.hxx>
-#endif
-#ifndef _XMLOFF_CONTEXTID_HXX_
#include <xmloff/contextid.hxx>
-#endif
-#ifndef _XMLOFF_FORMS_CONTROLPROPERTYHDL_HXX_
#include <xmloff/controlpropertyhdl.hxx>
-#endif
#include <memory>
@@ -74,3 +69,4 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLHELPER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx b/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx
index 0d1ea16f7e52..3e55ab88f4fa 100644
--- a/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx
+++ b/dbaccess/source/filter/xml/xmlHierarchyCollection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,45 +28,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLHIERARCHYCOLLECTION_HXX
#include "xmlHierarchyCollection.hxx"
-#endif
-#ifndef DBA_XMLCOMPONENT_HXX
#include "xmlComponent.hxx"
-#endif
-#ifndef DBA_XMLQUERY_HXX
#include "xmlQuery.hxx"
-#endif
-#ifndef DBA_XMLCOLUMN_HXX
#include "xmlColumn.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
@@ -134,7 +109,7 @@ OXMLHierarchyCollection::OXMLHierarchyCollection( ODBFilter& rImport
}
catch(Exception&)
{
- OSL_ENSURE(0,"OXMLHierarchyCollection::OXMLHierarchyCollection -> exception catched");
+ OSL_FAIL("OXMLHierarchyCollection::OXMLHierarchyCollection -> exception catched");
}
}
}
@@ -169,9 +144,6 @@ SvXMLImportContext* OXMLHierarchyCollection::CreateChildContext(
switch( rTokenMap.Get( nPrefix, rLocalName ) )
{
-// case XML_TOK_QUERY:
-// pContext = new OXMLQuery( GetOwnImport(), nPrefix, rLocalName,xAttrList,m_xContainer );
-// break;
case XML_TOK_COMPONENT:
GetOwnImport().GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
pContext = new OXMLComponent( GetOwnImport(), nPrefix, rLocalName,xAttrList,m_xContainer,m_sComponentServiceName );
@@ -180,7 +152,6 @@ SvXMLImportContext* OXMLHierarchyCollection::CreateChildContext(
GetOwnImport().GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
pContext = new OXMLColumn( GetOwnImport(), nPrefix, rLocalName,xAttrList,m_xContainer,m_xTable);
break;
- // case XML_TOK_QUERY_COLLECTION:
case XML_TOK_COMPONENT_COLLECTION:
GetOwnImport().GetProgressBarHelper()->Increment( PROGRESS_BAR_STEP );
pContext = new OXMLHierarchyCollection( GetOwnImport(), nPrefix, rLocalName,xAttrList,m_xContainer,m_sCollectionServiceName,m_sComponentServiceName);
@@ -201,3 +172,5 @@ ODBFilter& OXMLHierarchyCollection::GetOwnImport()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlHierarchyCollection.hxx b/dbaccess/source/filter/xml/xmlHierarchyCollection.hxx
index 5bd7f54730df..3d87826a928d 100644
--- a/dbaccess/source/filter/xml/xmlHierarchyCollection.hxx
+++ b/dbaccess/source/filter/xml/xmlHierarchyCollection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -73,3 +74,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLHIERARCHYCOLLECTION_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlLogin.cxx b/dbaccess/source/filter/xml/xmlLogin.cxx
index a672db671d48..cf255778a349 100644
--- a/dbaccess/source/filter/xml/xmlLogin.cxx
+++ b/dbaccess/source/filter/xml/xmlLogin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLLOGIN_HXX
#include "xmlLogin.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
#include <com/sun/star/sdbc/XDataSource.hpp>
#include <vector>
@@ -99,7 +82,7 @@ OXMLLogin::OXMLLogin( ODBFilter& rImport,
{
xDataSource->setPropertyValue(PROPERTY_USER,makeAny(sValue));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -110,7 +93,7 @@ OXMLLogin::OXMLLogin( ODBFilter& rImport,
{
xDataSource->setPropertyValue(PROPERTY_ISPASSWORDREQUIRED,makeAny((sValue == s_sTRUE ? sal_True : sal_False)));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -130,14 +113,14 @@ OXMLLogin::OXMLLogin( ODBFilter& rImport,
{
Reference< XDataSource>(xDataSource,UNO_QUERY_THROW)->setLoginTimeout(sValue.toInt32());
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
break;
}
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -155,3 +138,5 @@ OXMLLogin::~OXMLLogin()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlLogin.hxx b/dbaccess/source/filter/xml/xmlLogin.hxx
index a41920d76562..6f2751eb300b 100644
--- a/dbaccess/source/filter/xml/xmlLogin.hxx
+++ b/dbaccess/source/filter/xml/xmlLogin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBA_XMLLOGIN_HXX
#define DBA_XMLLOGIN_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
namespace dbaxml
{
@@ -50,3 +49,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLLOGIN_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlQuery.cxx b/dbaccess/source/filter/xml/xmlQuery.cxx
index 8e592f5d52b6..38fa654841e2 100644
--- a/dbaccess/source/filter/xml/xmlQuery.cxx
+++ b/dbaccess/source/filter/xml/xmlQuery.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,39 +28,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLQUERY_HXX
#include "xmlQuery.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -99,7 +78,7 @@ OXMLQuery::OXMLQuery( ODBFilter& rImport
m_sCommand = sValue;
break;
case XML_TOK_ESCAPE_PROCESSING:
- m_bEscapeProcessing = sValue.equalsAscii("true");
+ m_bEscapeProcessing = sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("true"));
break;
}
}
@@ -166,9 +145,11 @@ void OXMLQuery::setProperties(Reference< XPropertySet > & _xProp )
}
catch(Exception&)
{
- OSL_ENSURE(0,"OXMLTable::EndElement -> exception catched");
+ OSL_FAIL("OXMLTable::EndElement -> exception catched");
}
}
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlQuery.hxx b/dbaccess/source/filter/xml/xmlQuery.hxx
index f751d9b7af50..4e4bfde87be0 100644
--- a/dbaccess/source/filter/xml/xmlQuery.hxx
+++ b/dbaccess/source/filter/xml/xmlQuery.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLQUERY_HXX
#define DBA_XMLQUERY_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef DBA_XMLTABLE_HXX
#include "xmlTable.hxx"
-#endif
namespace dbaxml
@@ -64,3 +61,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLQUERY_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlServerDatabase.cxx b/dbaccess/source/filter/xml/xmlServerDatabase.cxx
index 021e0851a521..f670bc1365bb 100644
--- a/dbaccess/source/filter/xml/xmlServerDatabase.cxx
+++ b/dbaccess/source/filter/xml/xmlServerDatabase.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLSERVERDATABASE_HXX_INCLUDED
#include "xmlServerDatabase.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
namespace dbaxml
{
@@ -173,7 +156,7 @@ OXMLServerDatabase::OXMLServerDatabase( ODBFilter& rImport,
{
xDataSource->setPropertyValue(PROPERTY_URL,makeAny(sURL.makeStringAndClear()));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -191,3 +174,5 @@ OXMLServerDatabase::~OXMLServerDatabase()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlServerDatabase.hxx b/dbaccess/source/filter/xml/xmlServerDatabase.hxx
index 4eb2b8de402f..c94d2184f793 100644
--- a/dbaccess/source/filter/xml/xmlServerDatabase.hxx
+++ b/dbaccess/source/filter/xml/xmlServerDatabase.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBA_XMLSERVERDATABASE_HXX_INCLUDED
#define DBA_XMLSERVERDATABASE_HXX_INCLUDED
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
#include <vector>
namespace dbaxml
@@ -53,3 +50,4 @@ namespace dbaxml
#endif // DBA_XMLSERVERDATABASE_HXX_INCLUDED
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlStyleImport.cxx b/dbaccess/source/filter/xml/xmlStyleImport.cxx
index d24edcc1264d..f48d9b96437c 100644
--- a/dbaccess/source/filter/xml/xmlStyleImport.cxx
+++ b/dbaccess/source/filter/xml/xmlStyleImport.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,58 +29,23 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLSTYLEIMPORT_HXX
#include "xmlStyleImport.hxx"
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_XMLIMPPR_HXX
#include <xmloff/xmlimppr.hxx>
-#endif
-#ifndef _XMLOFF_FAMILIES_HXX_
#include <xmloff/families.hxx>
-#endif
-#ifndef _XMLOFF_XMLNUMFI_HXX
#include <xmloff/xmlnumfi.hxx>
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _COM_SUN_STAR_STYLE_XSTYLEFAMILIESSUPPLIER_HPP_
#include <com/sun/star/style/XStyleFamiliesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TABLE_BORDERLINE_HPP_
#include <com/sun/star/table/BorderLine.hpp>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _XMLOFF_XMLPROPERTYSETCONTEXT_HXX
#include <xmloff/xmlprcon.hxx>
-#endif
-#ifndef _XMLOFF_XMLUCONV_HXX
#include <xmloff/xmluconv.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef DBA_XMLFILTER_HXX
+#include <osl/diagnose.h>
#include "xmlfilter.hxx"
-#endif
-#ifndef DBA_XMLHELPER_HXX
#include "xmlHelper.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
#define XML_LINE_LEFT 0
@@ -154,7 +120,7 @@ void OTableStyleContext::FillPropertySet(
pStyle = PTR_CAST(SvXMLNumFormatContext,pMyStyles->
FindStyleChildContext(XML_STYLE_FAMILY_DATA_STYLE, m_sDataStyleName, sal_True));
else {
- DBG_ERROR("not possible to get style");
+ OSL_FAIL("not possible to get style");
}
}
if ( pStyle )
@@ -162,7 +128,6 @@ void OTableStyleContext::FillPropertySet(
uno::Any aNumberFormat;
m_nNumberFormat = pStyle->GetKey();
aNumberFormat <<= m_nNumberFormat;
- //rPropSet->setPropertyValue(rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_NUMBERFORMAT)), aNumberFormat);
AddProperty(CTF_DB_NUMBERFORMAT, aNumberFormat);
}
}
@@ -180,7 +145,7 @@ void OTableStyleContext::SetDefaults()
void OTableStyleContext::AddProperty(const sal_Int16 nContextID, const uno::Any& rValue)
{
sal_Int32 nIndex(static_cast<OTableStylesContext *>(pStyles)->GetIndex(nContextID));
- DBG_ASSERT(nIndex != -1, "Property not found in Map");
+ OSL_ENSURE(nIndex != -1, "Property not found in Map");
XMLPropertyState aPropState(nIndex, rValue);
GetProperties().push_back(aPropState); // has to be insertes in a sort order later
}
@@ -361,3 +326,5 @@ ODBFilter& OTableStylesContext::GetOwnImport()
// -----------------------------------------------------------------------------
} // dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlStyleImport.hxx b/dbaccess/source/filter/xml/xmlStyleImport.hxx
index b9210e49e0e9..87c93c793c02 100644
--- a/dbaccess/source/filter/xml/xmlStyleImport.hxx
+++ b/dbaccess/source/filter/xml/xmlStyleImport.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,36 +29,16 @@
#ifndef DBA_XMLSTYLEIMPORT_HXX
#define DBA_XMLSTYLEIMPORT_HXX
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _XMLOFF_XMLIMP_HXX
#include <xmloff/xmlimp.hxx>
-#endif
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _XMLOFF_PROPMAPPINGTYPES_HXX
#include <xmloff/maptype.hxx>
-#endif
-#ifndef _XMLOFF_PRSTYLEI_HXX_
#include <xmloff/prstylei.hxx>
-#endif
-#ifndef _XMLOFF_XMLIMPPR_HXX
#include <xmloff/xmlimppr.hxx>
-#endif
-#ifndef _XMLTEXTMASTERPAGECONTEXT_HXX
#include <xmloff/XMLTextMasterPageContext.hxx>
-#endif
-#ifndef _XMLTEXTMASTERSTYLESCONTEXT_HXX
#include <xmloff/XMLTextMasterStylesContext.hxx>
-#endif
-#ifndef _XMLOFF_CONTEXTID_HXX_
#include <xmloff/contextid.hxx>
-#endif
-#ifndef _XMLOFF_FORMS_CONTROLPROPERTYHDL_HXX_
#include <xmloff/controlpropertyhdl.hxx>
-#endif
#include <vector>
namespace dbaxml
@@ -70,7 +51,6 @@ namespace dbaxml
::rtl::OUString sPageStyle;
const rtl::OUString sNumberFormat;
SvXMLStylesContext* pStyles;
- // std::vector<ScXMLMapContent> aMaps;
com::sun::star::uno::Any aConditionalFormat;
sal_Int32 m_nNumberFormat;
sal_Bool bConditionalFormatCreated : 1;
@@ -155,3 +135,5 @@ namespace dbaxml
} // dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLSTYLEIMPORT_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlTable.cxx b/dbaccess/source/filter/xml/xmlTable.cxx
index 8698db7cffd1..8652f77cc113 100644
--- a/dbaccess/source/filter/xml/xmlTable.cxx
+++ b/dbaccess/source/filter/xml/xmlTable.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,48 +28,20 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLTABLE_HXX
#include "xmlTable.hxx"
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef DBA_XMLSTYLEIMPORT_HXX
#include "xmlStyleImport.hxx"
-#endif
-#ifndef DBA_XMLHIERARCHYCOLLECTION_HXX
#include "xmlHierarchyCollection.hxx"
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCOMMANDENVIRONMENT_HPP_
#include <com/sun/star/ucb/XCommandEnvironment.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COMPHELPER_NAMECONTAINER_HXX_
#include <comphelper/namecontainer.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -120,10 +93,10 @@ OXMLTable::OXMLTable( ODBFilter& _rImport
m_sStyleName = sValue;
break;
case XML_TOK_APPLY_FILTER:
- m_bApplyFilter = sValue.equalsAscii("true");
+ m_bApplyFilter = sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("true"));
break;
case XML_TOK_APPLY_ORDER:
- m_bApplyOrder = sValue.equalsAscii("true");
+ m_bApplyOrder = sValue.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("true"));
break;
}
}
@@ -213,7 +186,7 @@ void OXMLTable::setProperties(uno::Reference< XPropertySet > & _xProp )
}
catch(Exception&)
{
- OSL_ENSURE(0,"OXMLTable::EndElement -> exception catched");
+ OSL_FAIL("OXMLTable::EndElement -> exception catched");
}
}
// -----------------------------------------------------------------------------
@@ -246,7 +219,7 @@ void OXMLTable::EndElement()
}
catch(Exception&)
{
- OSL_ENSURE(0,"OXMLQuery::EndElement -> exception catched");
+ OSL_FAIL("OXMLQuery::EndElement -> exception catched");
}
}
@@ -293,3 +266,5 @@ void OXMLTable::fillAttributes(sal_uInt16 /*nPrfx*/
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlTable.hxx b/dbaccess/source/filter/xml/xmlTable.hxx
index 0fab2577c32d..925497ce92a8 100644
--- a/dbaccess/source/filter/xml/xmlTable.hxx
+++ b/dbaccess/source/filter/xml/xmlTable.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBA_XMLTABLE_HXX
#define DBA_XMLTABLE_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
namespace dbaxml
{
@@ -89,3 +84,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLTABLE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlTableFilterList.cxx b/dbaccess/source/filter/xml/xmlTableFilterList.cxx
index add1494231c5..0256afa63330 100644
--- a/dbaccess/source/filter/xml/xmlTableFilterList.cxx
+++ b/dbaccess/source/filter/xml/xmlTableFilterList.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,42 +28,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLTABLEFILTERLIST_HXX
#include "xmlTableFilterList.hxx"
-#endif
-#ifndef DBA_XMLTABLEFILTERPATTERN_HXX
#include "xmlTableFilterPattern.hxx"
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _XMLOFF_XMLIMP_HXX
#include <xmloff/xmlimp.hxx>
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -130,3 +107,5 @@ void OXMLTableFilterList::EndElement()
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlTableFilterList.hxx b/dbaccess/source/filter/xml/xmlTableFilterList.hxx
index fe22ac40bb52..d288b23ae7d1 100644
--- a/dbaccess/source/filter/xml/xmlTableFilterList.hxx
+++ b/dbaccess/source/filter/xml/xmlTableFilterList.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBA_XMLTABLEFILTERLIST_HXX
#define DBA_XMLTABLEFILTERLIST_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
#include <vector>
namespace dbaxml
@@ -77,3 +76,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLTABLEFILTERLIST_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlTableFilterPattern.cxx b/dbaccess/source/filter/xml/xmlTableFilterPattern.cxx
index 6babad7b7fad..4a8a87da30b5 100644
--- a/dbaccess/source/filter/xml/xmlTableFilterPattern.cxx
+++ b/dbaccess/source/filter/xml/xmlTableFilterPattern.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef DBA_XMLTABLEFILTERPATTERN_HXX
#include "xmlTableFilterPattern.hxx"
-#endif
-#ifndef DBA_XMLTABLEFILTERLIST_HXX
#include "xmlTableFilterList.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaxml
{
@@ -74,3 +69,5 @@ void OXMLTableFilterPattern::Characters( const ::rtl::OUString& rChars )
//----------------------------------------------------------------------------
} // namespace dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlTableFilterPattern.hxx b/dbaccess/source/filter/xml/xmlTableFilterPattern.hxx
index c33136849e0e..460d896ecc89 100644
--- a/dbaccess/source/filter/xml/xmlTableFilterPattern.hxx
+++ b/dbaccess/source/filter/xml/xmlTableFilterPattern.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBA_XMLTABLEFILTERPATTERN_HXX
#define DBA_XMLTABLEFILTERPATTERN_HXX
-#ifndef _XMLOFF_XMLICTXT_HXX
#include <xmloff/xmlictxt.hxx>
-#endif
namespace dbaxml
{
@@ -54,3 +53,5 @@ namespace dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLTABLEFILTERPATTERN_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlfilter.cxx b/dbaccess/source/filter/xml/xmlfilter.cxx
index e9a2453f133c..bef47dc01ade 100644
--- a/dbaccess/source/filter/xml/xmlfilter.cxx
+++ b/dbaccess/source/filter/xml/xmlfilter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,105 +29,44 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef _COM_SUN_STAR_PACKAGES_ZIP_ZIPIOEXCEPTION_HPP_
#include <com/sun/star/packages/zip/ZipIOException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_EMBED_ELEMENTMODES_HPP_
#include <com/sun/star/embed/ElementModes.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XOFFICEDATABASEDOCUMENT_HPP_
#include <com/sun/star/sdb/XOfficeDatabaseDocument.hpp>
-#endif
-#ifndef DBA_XMLFILTER_HXX
#include "xmlfilter.hxx"
-#endif
-#ifndef _FLT_REGHELPER_HXX_
#include "flt_reghelper.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_WINDOW_HXX
#include <vcl/window.hxx>
-#endif
-#ifndef _XMLOFF_XMLNMSPE_HXX
#include <xmloff/xmlnmspe.hxx>
-#endif
-#ifndef _XMLOFF_XMLSCRIPTI_HXX
#include <xmloff/xmlscripti.hxx>
-#endif
-#ifndef _XMLOFF_XMLTOKEN_HXX
#include <xmloff/xmltoken.hxx>
-#endif
-#ifndef _XMLOFF_TEXTIMP_HXX_
#include <xmloff/txtimp.hxx>
-#endif
-#ifndef _XMLOFF_NMSPMAP_HXX
#include <xmloff/nmspmap.hxx>
-#endif
-#ifndef _RTL_LOGFILE_HXX_
#include <rtl/logfile.hxx>
-#endif
-#ifndef _COM_SUN_STAR_XML_SAX_INPUTSOURCE_HPP_
#include <com/sun/star/xml/sax/InputSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_XML_SAX_XPARSER_HPP_
#include <com/sun/star/xml/sax/XParser.hpp>
-#endif
-#ifndef _XMLOFF_PROGRESSBARHELPER_HXX
#include <xmloff/ProgressBarHelper.hxx>
-#endif
-#ifndef _SFXDOCFILE_HXX //autogen wg. SfxMedium
#include <sfx2/docfile.hxx>
-#endif
-#ifndef _COM_SUN_STAR_IO_XINPUTSTREAM_HPP_
#include <com/sun/star/io/XInputStream.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_XNAMINGSERVICE_HPP_
#include <com/sun/star/uno/XNamingService.hpp>
-#endif
-#ifndef DBA_XMLDATABASE_HXX
#include "xmlDatabase.hxx"
-#endif
-#ifndef DBA_XMLENUMS_HXX
#include "xmlEnums.hxx"
-#endif
-#ifndef _URLOBJ_HXX //autogen wg. INetURLObject
#include <tools/urlobj.hxx>
-#endif
-#ifndef DBACCESS_SHARED_XMLSTRINGS_HRC
#include "xmlstrings.hrc"
-#endif
-#ifndef _XMLOFF_DOCUMENTSETTINGSCONTEXT_HXX
#include <xmloff/DocumentSettingsContext.hxx>
-#endif
-#ifndef DBA_XMLSTYLEIMPORT_HXX
#include "xmlStyleImport.hxx"
-#endif
-#ifndef _XMLOFF_XMLUCONV_HXX
#include <xmloff/xmluconv.hxx>
-#endif
-#ifndef DBA_XMLHELPER_HXX
#include "xmlHelper.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XMODIFIABLE_HPP_
#include <com/sun/star/util/XModifiable.hpp>
-#endif
#include <com/sun/star/frame/XComponentLoader.hpp>
#include <com/sun/star/frame/FrameSearchFlag.hpp>
#include <com/sun/star/lang/WrappedTargetRuntimeException.hpp>
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
+#include <osl/mutex.hxx>
#include <svtools/sfxecode.hxx>
#include <unotools/moduleoptions.hxx>
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <comphelper/namedvaluecollection.hxx>
#include <comphelper/mimeconfighelper.hxx>
#include <comphelper/documentconstants.hxx>
@@ -185,8 +125,8 @@ namespace dbaxml
(void)ex;
OSL_ASSERT(0);
}
- } // if ( s_bFirstTime )
- } // if ( m_eWhat == E_JAVA )
+ }
+ }
else if ( m_eWhat == E_CALC )
{
static bool s_bFirstTime = true;
@@ -260,7 +200,7 @@ namespace dbaxml
if ( m_aTypeCollection.needsJVM(sURL) )
{
pCreatorThread = new FastLoader(m_xFactory,FastLoader::E_JAVA);
- } // if ( m_aTypeCollection.needsJVM(sURL) )
+ }
else if ( sURL.matchIgnoreAsciiCaseAsciiL("sdbc:calc:",10,0) )
{
pCreatorThread = new FastLoader(m_xFactory,FastLoader::E_CALC);
@@ -278,8 +218,8 @@ namespace dbaxml
}
};
}
- sal_Char __READONLY_DATA sXML_np__db[] = "_db";
- sal_Char __READONLY_DATA sXML_np___db[] = "__db";
+ sal_Char const sXML_np__db[] = "_db";
+ sal_Char const sXML_np___db[] = "__db";
using namespace ::com::sun::star::util;
/// read a component (file + filter version)
@@ -289,9 +229,9 @@ sal_Int32 ReadThroughComponent(
const uno::Reference<XMultiServiceFactory> & rFactory,
const uno::Reference< XDocumentHandler >& _xFilter )
{
- DBG_ASSERT(xInputStream.is(), "input stream missing");
- DBG_ASSERT(xModelComponent.is(), "document missing");
- DBG_ASSERT(rFactory.is(), "factory missing");
+ OSL_ENSURE(xInputStream.is(), "input stream missing");
+ OSL_ENSURE(xModelComponent.is(), "document missing");
+ OSL_ENSURE(rFactory.is(), "factory missing");
RTL_LOGFILE_CONTEXT_AUTHOR( aLog, "dbaxml", "oj", "ReadThroughComponent" );
@@ -302,15 +242,15 @@ sal_Int32 ReadThroughComponent(
// get parser
uno::Reference< XParser > xParser(
rFactory->createInstance(
- ::rtl::OUString::createFromAscii("com.sun.star.xml.sax.Parser") ),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.xml.sax.Parser"))),
UNO_QUERY );
- DBG_ASSERT( xParser.is(), "Can't create parser" );
+ OSL_ENSURE( xParser.is(), "Can't create parser" );
if( !xParser.is() )
return 1;
RTL_LOGFILE_CONTEXT_TRACE( aLog, "parser created" );
// get filter
- DBG_ASSERT( _xFilter.is(), "Can't instantiate filter component." );
+ OSL_ENSURE( _xFilter.is(), "Can't instantiate filter component." );
if( !_xFilter.is() )
return 1;
@@ -337,7 +277,7 @@ sal_Int32 ReadThroughComponent(
aError += ',';
aError += ByteString::CreateFromInt32( r.ColumnNumber );
- DBG_ERROR( aError.GetBuffer() );
+ OSL_FAIL( aError.GetBuffer() );
return 1;
}
#else
@@ -372,8 +312,8 @@ sal_Int32 ReadThroughComponent(
const uno::Reference<XMultiServiceFactory> & rFactory,
const uno::Reference< XDocumentHandler >& _xFilter)
{
- DBG_ASSERT( xStorage.is(), "Need storage!");
- DBG_ASSERT(NULL != pStreamName, "Please, please, give me a name!");
+ OSL_ENSURE( xStorage.is(), "Need storage!");
+ OSL_ENSURE(NULL != pStreamName, "Please, please, give me a name!");
if ( xStorage.is() )
{
@@ -470,7 +410,7 @@ sal_Bool SAL_CALL ODBFilter::filter( const Sequence< PropertyValue >& rDescripto
{
uno::Reference< ::com::sun::star::awt::XWindow > xWindow;
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
Window* pFocusWindow = Application::GetFocusWindow();
xWindow = VCLUnoHelper::GetInterface( pFocusWindow );
if( pFocusWindow )
@@ -483,7 +423,7 @@ sal_Bool SAL_CALL ODBFilter::filter( const Sequence< PropertyValue >& rDescripto
if ( xWindow.is() )
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
Window* pFocusWindow = VCLUnoHelper::GetWindow( xWindow );
if ( pFocusWindow )
pFocusWindow->LeaveWait();
@@ -668,7 +608,7 @@ const SvXMLTokenMap& ODBFilter::GetDocElemTokenMap() const
{
if ( !m_pDocElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_OFFICE, XML_SETTINGS, XML_TOK_DOC_SETTINGS },
{ XML_NAMESPACE_OOO, XML_SETTINGS, XML_TOK_DOC_SETTINGS },
@@ -690,7 +630,7 @@ const SvXMLTokenMap& ODBFilter::GetDatabaseElemTokenMap() const
{
if ( !m_pDatabaseElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_DATASOURCE, XML_TOK_DATASOURCE },
{ XML_NAMESPACE_DB, XML_FORMS, XML_TOK_FORMS},
@@ -710,7 +650,7 @@ const SvXMLTokenMap& ODBFilter::GetDataSourceElemTokenMap() const
{
if ( !m_pDataSourceElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_CONNECTION_RESOURCE, XML_TOK_CONNECTION_RESOURCE},
{ XML_NAMESPACE_DB, XML_SUPPRESS_VERSION_COLUMNS, XML_TOK_SUPPRESS_VERSION_COLUMNS},
@@ -761,7 +701,7 @@ const SvXMLTokenMap& ODBFilter::GetLoginElemTokenMap() const
{
if ( !m_pLoginElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_USER_NAME, XML_TOK_USER_NAME},
{ XML_NAMESPACE_DB, XML_IS_PASSWORD_REQUIRED, XML_TOK_IS_PASSWORD_REQUIRED},
@@ -778,7 +718,7 @@ const SvXMLTokenMap& ODBFilter::GetDatabaseDescriptionElemTokenMap() const
{
if ( !m_pDatabaseDescriptionElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_FILE_BASED_DATABASE, XML_TOK_FILE_BASED_DATABASE},
{ XML_NAMESPACE_DB, XML_SERVER_DATABASE, XML_TOK_SERVER_DATABASE},
@@ -793,7 +733,7 @@ const SvXMLTokenMap& ODBFilter::GetDataSourceInfoElemTokenMap() const
{
if ( !m_pDataSourceInfoElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_ADDITIONAL_COLUMN_STATEMENT,XML_TOK_ADDITIONAL_COLUMN_STATEMENT},
{ XML_NAMESPACE_DB, XML_ROW_RETRIEVING_STATEMENT, XML_TOK_ROW_RETRIEVING_STATEMENT},
@@ -819,7 +759,7 @@ const SvXMLTokenMap& ODBFilter::GetDocumentsElemTokenMap() const
{
if ( !m_pDocumentsElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_COMPONENT, XML_TOK_COMPONENT},
{ XML_NAMESPACE_DB, XML_COMPONENT_COLLECTION, XML_TOK_COMPONENT_COLLECTION},
@@ -839,7 +779,7 @@ const SvXMLTokenMap& ODBFilter::GetComponentElemTokenMap() const
{
if ( !m_pComponentElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_XLINK, XML_HREF, XML_TOK_HREF },
{ XML_NAMESPACE_XLINK, XML_TYPE, XML_TOK_TYPE },
@@ -858,7 +798,7 @@ const SvXMLTokenMap& ODBFilter::GetQueryElemTokenMap() const
{
if ( !m_pQueryElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_COMMAND, XML_TOK_COMMAND },
{ XML_NAMESPACE_DB, XML_ESCAPE_PROCESSING, XML_TOK_ESCAPE_PROCESSING },
@@ -882,7 +822,7 @@ const SvXMLTokenMap& ODBFilter::GetColumnElemTokenMap() const
{
if ( !m_pColumnElemTokenMap.get() )
{
- static __FAR_DATA SvXMLTokenMapEntry aElemTokenMap[]=
+ static SvXMLTokenMapEntry aElemTokenMap[]=
{
{ XML_NAMESPACE_DB, XML_NAME, XML_TOK_COLUMN_NAME },
{ XML_NAMESPACE_DB, XML_STYLE_NAME, XML_TOK_COLUMN_STYLE_NAME },
@@ -907,10 +847,8 @@ SvXMLImportContext* ODBFilter::CreateStylesContext(sal_uInt16 _nPrefix,const ::r
{
pContext = new OTableStylesContext(*this, _nPrefix, rLocalName, xAttrList, bIsAutoStyle);
if (bIsAutoStyle)
- //xAutoStyles = pContext;
SetAutoStyles((SvXMLStylesContext*)pContext);
else
- //xStyles = pContext;
SetStyles((SvXMLStylesContext*)pContext);
}
return pContext;
@@ -970,7 +908,7 @@ void ODBFilter::setPropertyInfo()
{
xDataSource->setPropertyValue(PROPERTY_INFO,makeAny(aInfo));
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -979,3 +917,5 @@ void ODBFilter::setPropertyInfo()
// -----------------------------------------------------------------------------
}// dbaxml
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlfilter.hxx b/dbaccess/source/filter/xml/xmlfilter.hxx
index a14e5cd90984..c4e2a16dc856 100644
--- a/dbaccess/source/filter/xml/xmlfilter.hxx
+++ b/dbaccess/source/filter/xml/xmlfilter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,63 +29,25 @@
#ifndef DBA_XMLFILTER_HXX
#define DBA_XMLFILTER_HXX
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMED_HPP_
#include <com/sun/star/container/XNamed.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XFILTER_HPP_
#include <com/sun/star/document/XFilter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XIMPORTER_HPP_
#include <com/sun/star/document/XImporter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XEXPORTER_HPP_
#include <com/sun/star/document/XExporter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XINITIALIZATION_HPP_
#include <com/sun/star/lang/XInitialization.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XCOMPONENT_HPP_
#include <com/sun/star/lang/XComponent.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XACTIVEDATASOURCE_HPP_
#include <com/sun/star/io/XActiveDataSource.hpp>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _UNOTOOLS_TEMPFILE_HXX
#include <unotools/tempfile.hxx>
-#endif
-#ifndef _UNOTOOLS_LOCALFILEHELPER_HXX
#include <unotools/localfilehelper.hxx>
-#endif
-#ifndef _UNTOOLS_UCBSTREAMHELPER_HXX
#include <unotools/ucbstreamhelper.hxx>
-#endif
-#ifndef _XMLOFF_XMLIMP_HXX
#include <xmloff/xmlimp.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
#include <memory>
@@ -208,3 +171,5 @@ public:
} // dbaxml
// -----------------------------------------------------------------------------
#endif // DBA_XMLFILTER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/filter/xml/xmlservices.cxx b/dbaccess/source/filter/xml/xmlservices.cxx
index c6110424a3d4..93df97d58ca2 100644
--- a/dbaccess/source/filter/xml/xmlservices.cxx
+++ b/dbaccess/source/filter/xml/xmlservices.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef _CPPUHELPER_FACTORY_HXX_
#include <cppuhelper/factory.hxx>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _FLT_REGHELPER_HXX_
#include "flt_reghelper.hxx"
-#endif
/********************************************************************************************/
@@ -102,3 +97,4 @@ extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
return xRet.get();
};
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/OAuthenticationContinuation.hxx b/dbaccess/source/inc/OAuthenticationContinuation.hxx
index d025ff343462..743772cdc506 100755..100644
--- a/dbaccess/source/inc/OAuthenticationContinuation.hxx
+++ b/dbaccess/source/inc/OAuthenticationContinuation.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,4 @@ public:
#endif // _DBACCESS_OAUTHENTICATIONCONTINUATION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/apitools.hxx b/dbaccess/source/inc/apitools.hxx
index d16d085f3750..f5e85f426877 100644
--- a/dbaccess/source/inc/apitools.hxx
+++ b/dbaccess/source/inc/apitools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,27 +29,13 @@
#ifndef _DBASHARED_APITOOLS_HXX_
#define _DBASHARED_APITOOLS_HXX_
-#ifndef _CPPUHELPER_COMPONENT_HXX_
#include <cppuhelper/component.hxx>
-#endif
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_
#include <cppuhelper/interfacecontainer.hxx>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
//==================================================================================
//= various typedefs
@@ -453,3 +440,4 @@ public:
#endif // _DBASHARED_APITOOLS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/constasciistring.hxx b/dbaccess/source/inc/constasciistring.hxx
index 07861a054a47..2179e2d7ffdd 100644
--- a/dbaccess/source/inc/constasciistring.hxx
+++ b/dbaccess/source/inc/constasciistring.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
#ifndef _DBASHARED_CONSTASCIISTRING_HXX_
#define _DBASHARED_CONSTASCIISTRING_HXX_
@@ -59,3 +60,5 @@ inline ConstAsciiString::operator const ::rtl::OUString& () const
#endif // _DBASHARED_CONSTASCIISTRING_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/dbadllapi.hxx b/dbaccess/source/inc/dbadllapi.hxx
index 3edf80da5643..9dfd5c3269fc 100644
--- a/dbaccess/source/inc/dbadllapi.hxx
+++ b/dbaccess/source/inc/dbadllapi.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -39,3 +40,5 @@
#endif
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/dbu_reghelper.hxx b/dbaccess/source/inc/dbu_reghelper.hxx
index 644216dbb8c4..fa2b70c1bde0 100644
--- a/dbaccess/source/inc/dbu_reghelper.hxx
+++ b/dbaccess/source/inc/dbu_reghelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
#ifndef _DBU_REGHELPER_HXX_
#define _DBU_REGHELPER_HXX_
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_REGISTRY_XREGISTRYKEY_HPP_
#include <com/sun/star/registry/XRegistryKey.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _CPPUHELPER_FACTORY_HXX_
#include <cppuhelper/factory.hxx>
-#endif
namespace dbaui
{
@@ -58,3 +47,4 @@ namespace dbaui
#endif // _DBU_REGHELPER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/dsntypes.hxx b/dbaccess/source/inc/dsntypes.hxx
index 97e2b2ff6f31..45b09601364c 100644
--- a/dbaccess/source/inc/dsntypes.hxx
+++ b/dbaccess/source/inc/dsntypes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -121,7 +122,7 @@ protected:
::connectivity::DriversConfig m_aDriverConfig;
::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory > m_xFactory;
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
sal_Int32 m_nLivingIterators; /// just for debugging reasons, counts the living iterators
#endif
@@ -239,3 +240,4 @@ protected:
#endif // _DBACCESS_DSNTYPES_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/flt_reghelper.hxx b/dbaccess/source/inc/flt_reghelper.hxx
index 6ed767c00b86..a68555add95a 100644
--- a/dbaccess/source/inc/flt_reghelper.hxx
+++ b/dbaccess/source/inc/flt_reghelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
#ifndef _FLT_REGHELPER_HXX_
#define _FLT_REGHELPER_HXX_
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_REGISTRY_XREGISTRYKEY_HPP_
#include <com/sun/star/registry/XRegistryKey.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _CPPUHELPER_FACTORY_HXX_
#include <cppuhelper/factory.hxx>
-#endif
namespace dbaxml
{
@@ -58,3 +47,4 @@ namespace dbaxml
#endif // _FLT_REGHELPER_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/registrationhelper.hxx b/dbaccess/source/inc/registrationhelper.hxx
index 1bec33866093..940fb7fe6fca 100644
--- a/dbaccess/source/inc/registrationhelper.hxx
+++ b/dbaccess/source/inc/registrationhelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -156,3 +157,4 @@ OOneInstanceAutoRegistration<TYPE>::~OOneInstanceAutoRegistration()
OModuleRegistration::revokeComponent(TYPE::getImplementationName_Static());
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/inc/stringconstants.hrc b/dbaccess/source/inc/stringconstants.hrc
index f295bb50378c..48fb8312839c 100644
--- a/dbaccess/source/inc/stringconstants.hrc
+++ b/dbaccess/source/inc/stringconstants.hrc
@@ -183,6 +183,7 @@
#define PROPERTY_ID_PERSISTENT_PATH 143
#define PROPERTY_ID_CURRENT_QUERY_DESIGN 144
#define PROPERTY_ID_SINGLESELECTQUERYCOMPOSER 145
+#define PROPERTY_ID_PROPCHANGE_NOTIFY 146
//============================================================
//= property names
@@ -340,6 +341,7 @@ DECLARE_CONSTASCII_USTRING(PROPERTY_HAVING_CLAUSE);
DECLARE_CONSTASCII_USTRING(PROPERTY_GROUP_BY);
DECLARE_CONSTASCII_USTRING(PROPERTY_EDIT_WIDTH);
DECLARE_CONSTASCII_USTRING(PROPERTY_SINGLESELECTQUERYCOMPOSER);
+DECLARE_CONSTASCII_USTRING(PROPERTY_CHANGE_NOTIFICATION_ENABLED);
//============================================================
//= service names
diff --git a/dbaccess/source/inc/stringconstants.inc b/dbaccess/source/inc/stringconstants.inc
index f2a39b06f110..5eef8a68d7bd 100644
--- a/dbaccess/source/inc/stringconstants.inc
+++ b/dbaccess/source/inc/stringconstants.inc
@@ -183,6 +183,7 @@ IMPLEMENT_CONSTASCII_USTRING(PROPERTY_HAVING_CLAUSE, "HavingClause");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_GROUP_BY, "GroupBy");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_EDIT_WIDTH, "EditWidth");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_SINGLESELECTQUERYCOMPOSER,"SingleSelectQueryComposer");
+IMPLEMENT_CONSTASCII_USTRING(PROPERTY_CHANGE_NOTIFICATION_ENABLED, "PropertyChangeNotificationEnabled");
//============================================================
//= service names
diff --git a/dbaccess/source/sdbtools/connection/connectiondependent.hxx b/dbaccess/source/sdbtools/connection/connectiondependent.hxx
index 52a418105985..ed756b98a76c 100644
--- a/dbaccess/source/sdbtools/connection/connectiondependent.hxx
+++ b/dbaccess/source/sdbtools/connection/connectiondependent.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -154,3 +155,4 @@ namespace sdbtools
#endif // DBACCESS_CONNECTION_DEPENDENT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/connectiontools.cxx b/dbaccess/source/sdbtools/connection/connectiontools.cxx
index 1de93461d106..5f1e8153f278 100644
--- a/dbaccess/source/sdbtools/connection/connectiontools.cxx
+++ b/dbaccess/source/sdbtools/connection/connectiontools.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,26 +29,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_CONNECTIONTOOLS_HXX
#include "connectiontools.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_SDBTOOLS_CONNECTION_TABLENAME_HXX
#include "tablename.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_SDBTOOLS_CONNECTION_OBJECTNAMES_HXX
#include "objectnames.hxx"
-#endif
-#ifndef DBACCESS_DATASOURCEMETADATA_HXX
#include "datasourcemetadata.hxx"
-#endif
/** === begin UNO includes === **/
/** === end UNO includes === **/
-#ifndef COMPHELPER_NAMEDVALUECOLLECTION_HXX
#include <comphelper/namedvaluecollection.hxx>
-#endif
#include <connectivity/dbtools.hxx>
#include <connectivity/statementcomposer.hxx>
@@ -195,3 +186,4 @@ namespace sdbtools
} // namespace sdbtools
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/connectiontools.hxx b/dbaccess/source/sdbtools/connection/connectiontools.hxx
index c2235e54c526..ed1372e5eb89 100644
--- a/dbaccess/source/sdbtools/connection/connectiontools.hxx
+++ b/dbaccess/source/sdbtools/connection/connectiontools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,36 +29,20 @@
#ifndef DBACCESS_CONNECTIONTOOLS_HXX
#define DBACCESS_CONNECTIONTOOLS_HXX
-#ifndef DBACCESS_MODULE_SDBT_HXX
#include "module_sdbt.hxx"
-#endif
-#ifndef DBACCESS_CONNECTION_DEPENDENT_HXX
#include "connectiondependent.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_SDB_TOOLS_XCONNECTIONTOOLS_HPP_
#include <com/sun/star/sdb/tools/XConnectionTools.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XINITIALIZATION_HPP_
#include <com/sun/star/lang/XInitialization.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_XCOMPONENTCONTEXT_HPP_
#include <com/sun/star/uno/XComponentContext.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _CPPUHELPER_IMPLBASE3_HXX_
#include <cppuhelper/implbase3.hxx>
-#endif
-#ifndef COMPHELPER_COMPONENTCONTEXT_HXX
#include <comphelper/componentcontext.hxx>
-#endif
//........................................................................
namespace sdbtools
@@ -123,3 +108,4 @@ namespace sdbtools
#endif // DBACCESS_CONNECTIONTOOLS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/datasourcemetadata.cxx b/dbaccess/source/sdbtools/connection/datasourcemetadata.cxx
index 5d9ba83fe9c3..ef76d96eed95 100644
--- a/dbaccess/source/sdbtools/connection/datasourcemetadata.cxx
+++ b/dbaccess/source/sdbtools/connection/datasourcemetadata.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,19 +29,13 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_DATASOURCEMETADATA_HXX
#include "datasourcemetadata.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_LANG_NULLPOINTEREXCEPTION_HPP_
#include <com/sun/star/lang/NullPointerException.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef CONNECTIVITY_INC_CONNECTIVITY_DBMETADATA_HXX
#include <connectivity/dbmetadata.hxx>
-#endif
//........................................................................
namespace sdbtools
@@ -91,3 +86,4 @@ namespace sdbtools
} // namespace sdbtools
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/datasourcemetadata.hxx b/dbaccess/source/sdbtools/connection/datasourcemetadata.hxx
index de4a82df1340..440b1f6c2c81 100644
--- a/dbaccess/source/sdbtools/connection/datasourcemetadata.hxx
+++ b/dbaccess/source/sdbtools/connection/datasourcemetadata.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,19 +29,13 @@
#ifndef DBACCESS_DATASOURCEMETADATA_HXX
#define DBACCESS_DATASOURCEMETADATA_HXX
-#ifndef DBACCESS_CONNECTION_DEPENDENT_HXX
#include "connectiondependent.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_SDB_TOOLS_XDATASOURCEMETADATA_HPP_
#include <com/sun/star/sdb/tools/XDataSourceMetaData.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
#include <memory>
@@ -95,3 +90,5 @@ namespace sdbtools
//........................................................................
#endif // DBACCESS_DATASOURCEMETADATA_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/makefile.mk b/dbaccess/source/sdbtools/connection/makefile.mk
deleted file mode 100644
index f8d43df01426..000000000000
--- a/dbaccess/source/sdbtools/connection/makefile.mk
+++ /dev/null
@@ -1,49 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=conntools
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files -------------------------------------
-SLOFILES= \
- $(SLO)$/connectiontools.obj \
- $(SLO)$/tablename.obj \
- $(SLO)$/objectnames.obj \
- $(SLO)$/datasourcemetadata.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/sdbtools/connection/objectnames.cxx b/dbaccess/source/sdbtools/connection/objectnames.cxx
index 01e6931de526..fc523aceb650 100644
--- a/dbaccess/source/sdbtools/connection/objectnames.cxx
+++ b/dbaccess/source/sdbtools/connection/objectnames.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_SOURCE_SDBTOOLS_CONNECTION_OBJECTNAMES_HXX
#include "objectnames.hxx"
-#endif
-#ifndef DBACCESS_MODULE_SDBT_HXX
#include "module_sdbt.hxx"
-#endif
-#ifndef DBACCESS_SDBT_RESOURCE_HRC
#include "sdbt_resource.hrc"
-#endif
/** === begin UNO includes === **/
#include <com/sun/star/lang/NullPointerException.hpp>
@@ -207,7 +202,7 @@ namespace sdbtools
|| ( _rName.indexOf( (sal_Unicode)96 ) >= 0 ) //
|| ( _rName.indexOf( (sal_Unicode)145 ) >= 0 ) //
|| ( _rName.indexOf( (sal_Unicode)146 ) >= 0 ) //
- || ( _rName.indexOf( (sal_Unicode)180 ) >= 0 ) // #86621# removed unparsable chars
+ || ( _rName.indexOf( (sal_Unicode)180 ) >= 0 ) // removed unparsable chars
)
return ErrorCondition::DB_QUERY_NAME_WITH_QUOTES;
@@ -496,3 +491,4 @@ namespace sdbtools
} // namespace sdbtools
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/objectnames.hxx b/dbaccess/source/sdbtools/connection/objectnames.hxx
index 0f72896aa118..de2b95951c62 100644
--- a/dbaccess/source/sdbtools/connection/objectnames.hxx
+++ b/dbaccess/source/sdbtools/connection/objectnames.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -96,3 +97,4 @@ namespace sdbtools
#endif // DBACCESS_SOURCE_SDBTOOLS_INC_OBJECTNAMES_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/tablename.cxx b/dbaccess/source/sdbtools/connection/tablename.cxx
index aedc62451300..47fb343a14ac 100644
--- a/dbaccess/source/sdbtools/connection/tablename.cxx
+++ b/dbaccess/source/sdbtools/connection/tablename.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,6 +43,7 @@
#include <connectivity/dbtools.hxx>
#include <tools/diagnose_ex.h>
#include <tools/string.hxx>
+#include <sal/macros.h>
//........................................................................
namespace sdbtools
@@ -210,7 +212,7 @@ namespace sdbtools
//--------------------------------------------------------------------
namespace
{
- /** translates a CopmositionType into a EComposeRule
+ /** translates a CompositionType into a EComposeRule
@throws IllegalArgumentException
if the given value does not denote a valid CompositionType
*/
@@ -232,7 +234,7 @@ namespace sdbtools
bool found = false;
size_t i = 0;
- for ( ; ( i < sizeof( TypeTable ) / sizeof( TypeTable[0] ) ) && !found; ++i )
+ for ( ; ( i < SAL_N_ELEMENTS( TypeTable ) ) && !found; ++i )
if ( TypeTable[i].nCompositionType == _nType )
found = true;
if ( !found )
@@ -273,3 +275,4 @@ namespace sdbtools
} // namespace sdbtools
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/connection/tablename.hxx b/dbaccess/source/sdbtools/connection/tablename.hxx
index fae1b8fae0be..d165fc8680fe 100644
--- a/dbaccess/source/sdbtools/connection/tablename.hxx
+++ b/dbaccess/source/sdbtools/connection/tablename.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,19 +29,13 @@
#ifndef DBACCESS_SOURCE_SDBTOOLS_CONNECTION_TABLENAME_HXX
#define DBACCESS_SOURCE_SDBTOOLS_CONNECTION_TABLENAME_HXX
-#ifndef DBACCESS_CONNECTION_DEPENDENT_HXX
#include "connectiondependent.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_SDB_TOOLS_XTABLENAME_HPP_
#include <com/sun/star/sdb/tools/XTableName.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
#include <memory>
@@ -107,3 +102,4 @@ namespace sdbtools
#endif // DBACCESS_SOURCE_SDBTOOLS_CONNECTION_TABLENAME_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/inc/module_sdbt.hxx b/dbaccess/source/sdbtools/inc/module_sdbt.hxx
index 5b17ff86b4f0..938ec38c6aca 100644
--- a/dbaccess/source/sdbtools/inc/module_sdbt.hxx
+++ b/dbaccess/source/sdbtools/inc/module_sdbt.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBACCESS_MODULE_SDBT_HXX
#define DBACCESS_MODULE_SDBT_HXX
-#ifndef UNOTOOLS_INC_UNOTOOLS_COMPONENTRESMODULE_HXX
#include <unotools/componentresmodule.hxx>
-#endif
//........................................................................
namespace sdbtools
@@ -45,3 +44,4 @@ namespace sdbtools
#endif // DBACCESS_MODULE_SDBT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/misc/makefile.mk b/dbaccess/source/sdbtools/misc/makefile.mk
deleted file mode 100644
index 8c51fc7a8363..000000000000
--- a/dbaccess/source/sdbtools/misc/makefile.mk
+++ /dev/null
@@ -1,47 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=sdbtmisc
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files -------------------------------------
-SLOFILES= \
- $(SLO)$/sdbt_services.obj \
- $(SLO)$/module_sdbt.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/sdbtools/misc/module_sdbt.cxx b/dbaccess/source/sdbtools/misc/module_sdbt.cxx
index 9c9ee6304168..f84822c1d25a 100644
--- a/dbaccess/source/sdbtools/misc/module_sdbt.cxx
+++ b/dbaccess/source/sdbtools/misc/module_sdbt.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_MODULE_SDBT_HXX
#include "module_sdbt.hxx"
-#endif
//........................................................................
namespace sdbtools
@@ -43,3 +42,4 @@ namespace sdbtools
} // namespace sdbtools
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/misc/sdbt_services.cxx b/dbaccess/source/sdbtools/misc/sdbt_services.cxx
index 395f24dfd6e1..3bef9a0b26b4 100644
--- a/dbaccess/source/sdbtools/misc/sdbt_services.cxx
+++ b/dbaccess/source/sdbtools/misc/sdbt_services.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaccess.hxx"
-#ifndef DBACCESS_MODULE_SDBT_HXX
#include "module_sdbt.hxx"
-#endif
/** === begin UNO using === **/
using ::com::sun::star::lang::XMultiServiceFactory;
@@ -84,3 +83,4 @@ extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
return xRet.get();
};
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/sdbtools/resource/makefile.mk b/dbaccess/source/sdbtools/resource/makefile.mk
deleted file mode 100644
index 9b55104c983d..000000000000
--- a/dbaccess/source/sdbtools/resource/makefile.mk
+++ /dev/null
@@ -1,45 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=sdbt_resource
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files --------------------------------------------------------
-
-SRS1NAME=sdbt_strings
-SRC1FILES= \
- sdbt_strings.src \
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
diff --git a/dbaccess/source/shared/dbu_reghelper.cxx b/dbaccess/source/shared/dbu_reghelper.cxx
index a9d7ef546b9a..1b7345d344f9 100644
--- a/dbaccess/source/shared/dbu_reghelper.cxx
+++ b/dbaccess/source/shared/dbu_reghelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,12 +31,8 @@
#include "dbu_reghelper.hxx"
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
namespace dbaui
{
@@ -46,3 +43,4 @@ namespace dbaui
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/shared/dbustrings.cxx b/dbaccess/source/shared/dbustrings.cxx
index bc2b476b9dd0..b065ec7338ac 100644
--- a/dbaccess/source/shared/dbustrings.cxx
+++ b/dbaccess/source/shared/dbustrings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -71,3 +72,5 @@ namespace dbaui
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_ENABLED, "Enabled");
IMPLEMENT_CONSTASCII_USTRING(PROPERTY_MOUSE_WHEEL_BEHAVIOR, "MouseWheelBehavior");
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/shared/flt_reghelper.cxx b/dbaccess/source/shared/flt_reghelper.cxx
index 36bb460b717e..a2f44f1590a6 100644
--- a/dbaccess/source/shared/flt_reghelper.cxx
+++ b/dbaccess/source/shared/flt_reghelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbaxml.hxx"
-#ifndef _FLT_REGHELPER_HXX_
#include "flt_reghelper.hxx"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
namespace dbaxml
{
@@ -47,3 +42,5 @@ namespace dbaxml
#undef _REGISTRATIONHELPER_CXX_INCLUDED_INDIRECTLY_
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/shared/makefile.mk b/dbaccess/source/shared/makefile.mk
deleted file mode 100644
index 5f75c13f9816..000000000000
--- a/dbaccess/source/shared/makefile.mk
+++ /dev/null
@@ -1,69 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-LIBTARGET=NO
-TARGET=shared
-LIB1TARGET=$(SLB)$/dbushared.lib
-LIB2TARGET=$(SLB)$/fltshared.lib
-LIB4TARGET=$(SLB)$/sdbtshared.lib
-
-#ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Types -------------------------------------
-
-# --- Files -------------------------------------
-EXCEPTIONSFILES= \
- $(SLO)$/dbu_reghelper.obj \
- $(SLO)$/flt_reghelper.obj
-
-SLOFILES= \
- $(EXCEPTIONSFILES) \
- $(SLO)$/xmlstrings.obj \
- $(SLO)$/dbustrings.obj
-
-LIB1OBJFILES= \
- $(SLO)$/dbu_reghelper.obj \
- $(SLO)$/dbustrings.obj
-
-LIB2OBJFILES= \
- $(SLO)$/flt_reghelper.obj \
- $(SLO)$/xmlstrings.obj
-
-LIB4OBJFILES= \
- $(SLO)$/sdbtstrings.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/shared/registrationhelper.cxx b/dbaccess/source/shared/registrationhelper.cxx
index 318454df8994..69a6879fa508 100644
--- a/dbaccess/source/shared/registrationhelper.cxx
+++ b/dbaccess/source/shared/registrationhelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -82,7 +83,7 @@ void OModuleRegistration::revokeComponent(const ::rtl::OUString& _rImplementatio
{
if (!s_pImplementationNames)
{
- OSL_ENSURE(sal_False, "OModuleRegistration::revokeComponent : have no class infos ! Are you sure called this method at the right time ?");
+ OSL_FAIL("OModuleRegistration::revokeComponent : have no class infos ! Are you sure called this method at the right time ?");
return;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
@@ -125,7 +126,7 @@ uno::Reference< uno::XInterface > OModuleRegistration::getComponentFactory(
if (!s_pImplementationNames)
{
- OSL_ENSURE(sal_False, "OModuleRegistration::getComponentFactory : have no class infos ! Are you sure called this method at the right time ?");
+ OSL_FAIL("OModuleRegistration::getComponentFactory : have no class infos ! Are you sure called this method at the right time ?");
return NULL;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
@@ -165,3 +166,4 @@ uno::Reference< uno::XInterface > OModuleRegistration::getComponentFactory(
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/shared/sdbtstrings.cxx b/dbaccess/source/shared/sdbtstrings.cxx
index b972df52bfec..aa531d01f59d 100644
--- a/dbaccess/source/shared/sdbtstrings.cxx
+++ b/dbaccess/source/shared/sdbtstrings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -33,3 +34,5 @@ namespace sdbtools
{
#include "stringconstants.inc"
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/shared/xmlstrings.cxx b/dbaccess/source/shared/xmlstrings.cxx
index c78fbfb40608..cd397b4ae25d 100644
--- a/dbaccess/source/shared/xmlstrings.cxx
+++ b/dbaccess/source/shared/xmlstrings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -34,3 +35,4 @@ namespace dbaxml
#include "stringconstants.inc"
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppController.cxx b/dbaccess/source/ui/app/AppController.cxx
index b401ec7cd07b..96e0ae16ae4c 100644
--- a/dbaccess/source/ui/app/AppController.cxx
+++ b/dbaccess/source/ui/app/AppController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,8 +79,8 @@
#include <com/sun/star/document/XDocumentEventBroadcaster.hpp>
#include <com/sun/star/container/XHierarchicalName.hpp>
/** === end UNO includes === **/
-#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <tools/string.hxx>
#include <svl/urihelper.hxx>
@@ -124,7 +125,7 @@
#include <svx/dbaobjectex.hxx>
#include <svx/svxdlg.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include "AppView.hxx"
#include "browserids.hxx"
#include "dbu_reghelper.hxx"
@@ -194,7 +195,7 @@ namespace DatabaseObjectContainer = ::com::sun::star::sdb::application::Database
Sequence< ::rtl::OUString> OApplicationController::getSupportedServiceNames_Static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString> aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.application.DefaultViewController");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.application.DefaultViewController"));
return aSupported;
}
//-------------------------------------------------------------------------
@@ -336,7 +337,7 @@ OApplicationController::~OApplicationController()
{
if ( !rBHelper.bDisposed && !rBHelper.bInDispose )
{
- OSL_ENSURE(0,"Please check who doesn't dispose this component!");
+ OSL_FAIL("Please check who doesn't dispose this component!");
// increment ref count to prevent double call of Dtor
osl_incrementInterlockedCount( &m_refCount );
dispose();
@@ -446,7 +447,7 @@ void SAL_CALL OApplicationController::disposing()
m_xModel.clear();
}
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -468,12 +469,12 @@ sal_Bool OApplicationController::Construct(Window* _pParent)
getContainer()->Construct();
bSuccess = sal_True;
}
- catch(SQLException&)
+ catch(const SQLException&)
{
}
- catch(Exception&)
+ catch(const Exception&)
{
- DBG_ERROR("OApplicationController::Construct : the construction of UnoDataBrowserView failed !");
+ OSL_FAIL("OApplicationController::Construct : the construction of UnoDataBrowserView failed !");
}
if ( !bSuccess )
@@ -504,7 +505,7 @@ void SAL_CALL OApplicationController::disposing(const EventObject& _rSource) thr
Reference<XConnection> xCon(_rSource.Source, UNO_QUERY);
if ( xCon.is() )
{
- DBG_ASSERT( m_xDataSourceConnection == xCon,
+ OSL_ENSURE( m_xDataSourceConnection == xCon,
"OApplicationController::disposing: which connection does this come from?" );
if ( getContainer() && getContainer()->getElementType() == E_TABLE )
@@ -549,7 +550,7 @@ sal_Bool SAL_CALL OApplicationController::suspend(sal_Bool bSuspend) throw( Runt
);
}
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( getView() && getView()->IsInModalMode() )
@@ -1018,7 +1019,7 @@ namespace
// -----------------------------------------------------------------------------
void OApplicationController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >& aArgs)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( isUserDefinedFeature( _nId ) )
@@ -1115,7 +1116,7 @@ void OApplicationController::Execute(sal_uInt16 _nId, const Sequence< PropertyVa
const PropertyValue* pEnd = pIter + aArgs.getLength();
for( ; pIter != pEnd ; ++pIter)
{
- if ( pIter->Name.equalsAscii("FormatStringId") )
+ if ( pIter->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("FormatStringId")) )
{
SotFormatStringId nFormatId = 0;
if ( pIter->Value >>= nFormatId )
@@ -1272,7 +1273,7 @@ void OApplicationController::Execute(sal_uInt16 _nId, const Sequence< PropertyVa
case ID_NEW_TABLE_DESIGN:
break;
default:
- OSL_ENSURE(0,"illegal switch call!");
+ OSL_FAIL("illegal switch call!");
}
if ( bAutoPilot )
getContainer()->PostUserEvent( LINK( this, OApplicationController, OnCreateWithPilot ), reinterpret_cast< void* >( eType ) );
@@ -1555,7 +1556,7 @@ OApplicationView* OApplicationController::getContainer() const
// ::com::sun::star::container::XContainerListener
void SAL_CALL OApplicationController::elementInserted( const ContainerEvent& _rEvent ) throw(RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
Reference< XContainer > xContainer(_rEvent.Source, UNO_QUERY);
@@ -1591,7 +1592,7 @@ void SAL_CALL OApplicationController::elementInserted( const ContainerEvent& _rE
// -----------------------------------------------------------------------------
void SAL_CALL OApplicationController::elementRemoved( const ContainerEvent& _rEvent ) throw(RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
Reference< XContainer > xContainer(_rEvent.Source, UNO_QUERY);
@@ -1625,7 +1626,7 @@ void SAL_CALL OApplicationController::elementRemoved( const ContainerEvent& _rEv
// -----------------------------------------------------------------------------
void SAL_CALL OApplicationController::elementReplaced( const ContainerEvent& _rEvent ) throw(RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
Reference< XContainer > xContainer(_rEvent.Source, UNO_QUERY);
@@ -1693,7 +1694,7 @@ namespace
case E_NONE:
break;
default:
- OSL_ENSURE(0,"Invalid ElementType!");
+ OSL_FAIL("Invalid ElementType!");
break;
}
return sToolbar;
@@ -1927,7 +1928,7 @@ Reference< XComponent > OApplicationController::openElementWithArguments( const
break;
default:
- OSL_ENSURE( false, "OApplicationController::openElement: illegal object type!" );
+ OSL_FAIL( "OApplicationController::openElement: illegal object type!" );
break;
}
return xRet;
@@ -2038,7 +2039,7 @@ Reference< XComponent > OApplicationController::newElement( ElementType _eType,
break;
default:
- OSL_ENSURE( false, "OApplicationController::newElement: illegal type!" );
+ OSL_FAIL( "OApplicationController::newElement: illegal type!" );
break;
}
@@ -2073,7 +2074,7 @@ void OApplicationController::addContainerListener(const Reference<XNameAccess>&
// -----------------------------------------------------------------------------
void OApplicationController::renameEntry()
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
OSL_ENSURE(getContainer(),"View is NULL! -> GPF");
@@ -2277,7 +2278,7 @@ void OApplicationController::showPreviewFor(const ElementType _eType,const ::rtl
return;
default:
- OSL_ENSURE( false, "OApplicationController::showPreviewFor: unexpected element type!" );
+ OSL_FAIL( "OApplicationController::showPreviewFor: unexpected element type!" );
break;
}
}
@@ -2339,7 +2340,7 @@ void OApplicationController::onDeleteEntry()
nId = SID_DB_APP_REPORT_DELETE;
break;
default:
- OSL_ENSURE(0,"Invalid ElementType!");
+ OSL_FAIL("Invalid ElementType!");
break;
}
executeChecked(nId,Sequence<PropertyValue>());
@@ -2499,9 +2500,6 @@ sal_Int8 OApplicationController::queryDrop( const AcceptDropEvent& _rEvt, const
nAction = DND_ACTION_NONE;
}
}
- /*else
- nAction = nActionAskedFor & DND_ACTION_COPYMOVE;
- */
}
return nAction;
}
@@ -2516,7 +2514,7 @@ sal_Int8 OApplicationController::executeDrop( const ExecuteDropEvent& _rEvt )
OApplicationView* pView = getContainer();
if ( !pView || pView->getElementType() == E_NONE )
{
- DBG_ERROR("OApplicationController::executeDrop: what the hell did queryDrop do?");
+ OSL_FAIL("OApplicationController::executeDrop: what the hell did queryDrop do?");
// queryDrop shoud not have allowed us to reach this situation ....
return DND_ACTION_NONE;
}
@@ -2653,7 +2651,7 @@ IMPL_LINK( OApplicationController, OnFirstControllerConnected, void*, /**/ )
if ( !m_xModel.is() )
{
- OSL_ENSURE( false, "OApplicationController::OnFirstControllerConnected: too late!" );
+ OSL_FAIL( "OApplicationController::OnFirstControllerConnected: too late!" );
}
// if we have forms or reports which contain macros/scripts, then show a warning
@@ -2718,7 +2716,7 @@ sal_Bool SAL_CALL OApplicationController::attachModel(const Reference< XModel >
const Reference< XModifiable > xDocModify( _rxModel, UNO_QUERY );
if ( ( !xOfficeDoc.is() || !xDocModify.is() ) && _rxModel.is() )
{
- DBG_ERROR( "OApplicationController::attachModel: invalid model!" );
+ OSL_FAIL( "OApplicationController::attachModel: invalid model!" );
return sal_False;
}
@@ -2855,7 +2853,7 @@ void SAL_CALL OApplicationController::removeSelectionChangeListener( const Refer
// -----------------------------------------------------------------------------
::sal_Bool SAL_CALL OApplicationController::select( const Any& _aSelection ) throw (IllegalArgumentException, RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
Sequence< ::rtl::OUString> aSelection;
if ( !_aSelection.hasValue() || !getView() )
@@ -2874,7 +2872,7 @@ void SAL_CALL OApplicationController::removeSelectionChangeListener( const Refer
const NamedValue* pEnd = pIter + aCurrentSelection.getLength();
for(;pIter != pEnd;++pIter)
{
- if ( pIter->Name.equalsAscii("Type") )
+ if ( pIter->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Type")) )
{
sal_Int32 nType = 0;
pIter->Value >>= nType;
@@ -2882,7 +2880,7 @@ void SAL_CALL OApplicationController::removeSelectionChangeListener( const Refer
throw IllegalArgumentException();
eType = static_cast< ElementType >( nType );
}
- else if ( pIter->Name.equalsAscii("Selection") )
+ else if ( pIter->Name.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Selection")) )
pIter->Value >>= aSelection;
}
@@ -2978,7 +2976,7 @@ void SAL_CALL OApplicationController::removeSelectionChangeListener( const Refer
// -----------------------------------------------------------------------------
Any SAL_CALL OApplicationController::getSelection( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
Sequence< NamedDatabaseObject > aCurrentSelection;
@@ -2998,7 +2996,7 @@ Any SAL_CALL OApplicationController::getSelection( ) throw (RuntimeException)
case E_FORM: aCurrentSelection[0].Type = DatabaseObjectContainer::FORMS; break;
case E_REPORT: aCurrentSelection[0].Type = DatabaseObjectContainer::REPORTS; break;
default:
- OSL_ENSURE( false, "OApplicationController::getSelection: unexpected current element type!" );
+ OSL_FAIL( "OApplicationController::getSelection: unexpected current element type!" );
break;
}
}
@@ -3036,3 +3034,4 @@ void OApplicationController::impl_migrateScripts_nothrow()
} // namespace dbaui
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppController.hxx b/dbaccess/source/ui/app/AppController.hxx
index 153661b47200..8067846c2c1e 100644
--- a/dbaccess/source/ui/app/AppController.hxx
+++ b/dbaccess/source/ui/app/AppController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -574,3 +575,4 @@ namespace dbaui
#endif // DBAUI_APPCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppControllerDnD.cxx b/dbaccess/source/ui/app/AppControllerDnD.cxx
index 16df2130520f..0789d693da03 100644
--- a/dbaccess/source/ui/app/AppControllerDnD.cxx
+++ b/dbaccess/source/ui/app/AppControllerDnD.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,196 +29,70 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_APPCONTROLLER_HXX
#include "AppController.hxx"
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_XNAMINGSERVICE_HPP_
#include <com/sun/star/uno/XNamingService.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XSTORABLE_HPP_
#include <com/sun/star/frame/XStorable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMECONTAINER_HPP_
#include <com/sun/star/container/XHierarchicalNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XBOOKMARKSSUPPLIER_HPP_
#include <com/sun/star/sdb/XBookmarksSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XQUERYDEFINITIONSSUPPLIER_HPP_
#include <com/sun/star/sdb/XQueryDefinitionsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDROP_HPP_
#include <com/sun/star/sdbcx/XDrop.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef _UNOTOOLS_UCBHELPER_HXX
#include <unotools/ucbhelper.hxx>
-#endif
-#ifndef DBAUI_DLGSAVE_HXX
#include "dlgsave.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _RTL_USTRBUF_HXX_
#include <rtl/ustrbuf.hxx>
-#endif
-#ifndef DBAUI_APPVIEW_HXX
#include "AppView.hxx"
-#endif
-#ifndef _SVX_DATACCESSDESCRIPTOR_HXX_
#include <svx/dataaccessdescriptor.hxx>
-#endif
-#ifndef SVX_DBAOBJECTEX_HXX
#include <svx/dbaobjectex.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _DBAU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _DBU_APP_HRC_
#include "dbu_app.hrc"
-#endif
-#ifndef _SV_MENU_HXX
#include <vcl/menu.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SVLBOXITM_HXX
#include <svtools/svlbitm.hxx>
-#endif
-#ifndef _DBAUI_LISTVIEWITEMS_HXX_
#include "listviewitems.hxx"
-#endif
-#ifndef DBAUI_APPDETAILVIEW_HXX
#include "AppDetailView.hxx"
-#endif
-#ifndef _DBAUI_LINKEDDOCUMENTS_HXX_
#include "linkeddocuments.hxx"
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef DBAUI_DBEXCHANGE_HXX
#include "dbexchange.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
#include <algorithm>
-#ifndef _SVTREEBOX_HXX
#include <svtools/svtreebx.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XREPORTDOCUMENTSSUPPLIER_HPP_
#include <com/sun/star/sdb/XReportDocumentsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XFORMDOCUMENTSSUPPLIER_HPP_
#include <com/sun/star/sdb/XFormDocumentsSupplier.hpp>
-#endif
-#ifndef _FILEDLGHELPER_HXX
#include <sfx2/filedlghelper.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
#include <unotools/pathoptions.hxx>
-#endif
-#ifndef _SFX_DOCFILT_HACK_HXX
#include <sfx2/docfilt.hxx>
-#endif
-#ifndef _SVT_FILEVIEW_HXX
#include <svtools/fileview.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBACCESS_SOURCE_UI_MISC_DEFAULTOBJECTNAMECHECK_HXX
+#include <osl/diagnose.h>
#include "defaultobjectnamecheck.hxx"
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
+#include <osl/mutex.hxx>
#include "subcomponentmanager.hxx"
//........................................................................
@@ -298,7 +173,7 @@ void OApplicationController::deleteTables(const ::std::vector< ::rtl::OUString>&
if(e.TargetException >>= aSql)
aErrorInfo = aSql;
else
- OSL_ENSURE(sal_False, "OApplicationController::implDropTable: something strange happended!");
+ OSL_FAIL("OApplicationController::implDropTable: something strange happended!");
}
catch( const Exception& )
{
@@ -336,7 +211,7 @@ void OApplicationController::deleteObjects( ElementType _eType, const ::std::vec
// The list of elements to delete is allowed to contain related elements: A given element may
// be the ancestor or child of another element from the list.
// We want to ensure that ancestors get deleted first, so we normalize the list in this respect.
- // #i33353# - 2004-09-27 - fs@openoffice.org
+ // #i33353#
::std::set< ::rtl::OUString > aDeleteNames;
// Note that this implicitly uses ::std::less< ::rtl::OUString > a comparison operation, which
// results in lexicographical order, which is exactly what we need, because "foo" is *before*
@@ -390,7 +265,7 @@ void OApplicationController::deleteObjects( ElementType _eType, const ::std::vec
// now that we removed the element, care for all it's child elements
// which may also be a part of the list
- // #i33353# - 2004-09-27 - fs@openoffice.org
+ // #i33353#
OSL_ENSURE( aThisRound->getLength() - 1 >= 0, "OApplicationController::deleteObjects: empty name?" );
::rtl::OUStringBuffer sSmallestSiblingName( *aThisRound );
sSmallestSiblingName.append( (sal_Unicode)( '/' + 1) );
@@ -419,7 +294,7 @@ void OApplicationController::deleteObjects( ElementType _eType, const ::std::vec
if ( e.TargetException >>= aSql )
showError( SQLExceptionInfo( e.TargetException ) );
else
- OSL_ENSURE( sal_False, "OApplicationController::deleteObjects: something strange happended!" );
+ OSL_FAIL( "OApplicationController::deleteObjects: something strange happended!" );
}
catch( const Exception& )
{
@@ -440,7 +315,7 @@ void OApplicationController::deleteObjects( ElementType _eType, const ::std::vec
// -----------------------------------------------------------------------------
void OApplicationController::deleteEntries()
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( getContainer() )
@@ -470,7 +345,7 @@ void OApplicationController::deleteEntries()
// -----------------------------------------------------------------------------
const SharedConnection& OApplicationController::ensureConnection( ::dbtools::SQLExceptionInfo* _pErrorInfo )
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( !m_xDataSourceConnection.is() )
@@ -586,7 +461,7 @@ Reference< XNameAccess > OApplicationController::getElements( ElementType _eType
// -----------------------------------------------------------------------------
void OApplicationController::getSelectionElementNames(::std::vector< ::rtl::OUString>& _rNames) const
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
OSL_ENSURE(getContainer(),"View isn't valid! -> GPF");
@@ -619,7 +494,7 @@ TransferableHelper* OApplicationController::copyObject()
{
try
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
ElementType eType = getContainer()->getElementType();
@@ -693,7 +568,7 @@ sal_Bool OApplicationController::paste( ElementType _eType,const ::svx::ODataAcc
if ( CommandType::QUERY == nCommandType || CommandType::COMMAND == nCommandType )
{
- // read all nescessary data
+ // read all necessary data
::rtl::OUString sCommand;
sal_Bool bEscapeProcessing = sal_True;
@@ -711,7 +586,7 @@ sal_Bool OApplicationController::paste( ElementType _eType,const ::svx::ODataAcc
bValidDescriptor = (0 != sCommand.getLength());
if (!bValidDescriptor)
{
- DBG_ERROR("OApplicationController::paste: invalid descriptor!");
+ OSL_FAIL("OApplicationController::paste: invalid descriptor!");
return sal_False;
}
@@ -762,7 +637,7 @@ sal_Bool OApplicationController::paste( ElementType _eType,const ::svx::ODataAcc
if (!bSuccess)
{
- DBG_ERROR("OApplicationController::paste: could not extract the source query object!");
+ OSL_FAIL("OApplicationController::paste: could not extract the source query object!");
// TODO: maybe this is worth an error message to be displayed to the user ....
return sal_False;
}
@@ -773,7 +648,7 @@ sal_Bool OApplicationController::paste( ElementType _eType,const ::svx::ODataAcc
Reference< XSingleServiceFactory > xQueryFactory(xDestQueries, UNO_QUERY);
if (!xQueryFactory.is())
{
- DBG_ERROR("OApplicationController::paste: invalid destination query container!");
+ OSL_FAIL("OApplicationController::paste: invalid destination query container!");
return sal_False;
}
@@ -805,7 +680,7 @@ sal_Bool OApplicationController::paste( ElementType _eType,const ::svx::ODataAcc
// create a new object
Reference< XPropertySet > xNewQuery(xQueryFactory->createInstance(), UNO_QUERY);
- DBG_ASSERT(xNewQuery.is(), "OApplicationController::paste: invalid object created by factory!");
+ OSL_ENSURE(xNewQuery.is(), "OApplicationController::paste: invalid object created by factory!");
if (xNewQuery.is())
{
// initialize
@@ -902,7 +777,7 @@ sal_Bool OApplicationController::isTableFormat() const
IMPL_LINK( OApplicationController, OnAsyncDrop, void*, /*NOTINTERESTEDIN*/ )
{
m_nAsyncDrop = 0;
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
@@ -940,3 +815,4 @@ IMPL_LINK( OApplicationController, OnAsyncDrop, void*, /*NOTINTERESTEDIN*/ )
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppControllerGen.cxx b/dbaccess/source/ui/app/AppControllerGen.cxx
index 49759c62d20a..9ff49f9ea1a5 100644
--- a/dbaccess/source/ui/app/AppControllerGen.cxx
+++ b/dbaccess/source/ui/app/AppControllerGen.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,12 +75,13 @@
#include <svx/dbaexchange.hxx>
#include <toolkit/unohlp.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <tools/urlobj.hxx>
#include <unotools/bootstrap.hxx>
#include <vcl/mnemonic.hxx>
#include <vcl/svapp.hxx>
#include <vcl/waitobj.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
//........................................................................
namespace dbaui
@@ -215,7 +217,7 @@ void OApplicationController::openDialog( const ::rtl::OUString& _sServiceName )
{
try
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
WaitObject aWO(getView());
@@ -225,7 +227,7 @@ void OApplicationController::openDialog( const ::rtl::OUString& _sServiceName )
Reference< ::com::sun::star::awt::XWindow> xWindow = getTopMostContainerWindow();
if ( !xWindow.is() )
{
- DBG_ASSERT( getContainer(), "OApplicationController::Construct: have no view!" );
+ OSL_ENSURE( getContainer(), "OApplicationController::Construct: have no view!" );
if ( getContainer() )
xWindow = VCLUnoHelper::GetInterface(getView()->Window::GetParent());
}
@@ -290,7 +292,7 @@ void OApplicationController::refreshTables()
}
catch(const Exception&)
{
- OSL_ENSURE(0,"Could not refresh tables!");
+ OSL_FAIL("Could not refresh tables!");
}
getContainer()->getDetailView()->clearPages(sal_False);
@@ -305,7 +307,7 @@ void OApplicationController::openDirectSQLDialog()
// -----------------------------------------------------------------------------
void SAL_CALL OApplicationController::propertyChange( const PropertyChangeEvent& evt ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( evt.PropertyName == PROPERTY_USER )
{
@@ -392,7 +394,7 @@ Reference< XConnection > SAL_CALL OApplicationController::getActiveConnection()
// -----------------------------------------------------------------------------
void SAL_CALL OApplicationController::connect( ) throw (SQLException, RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
SQLExceptionInfo aError;
@@ -431,7 +433,7 @@ beans::Pair< ::sal_Int32, ::rtl::OUString > SAL_CALL OApplicationController::ide
// -----------------------------------------------------------------------------
::sal_Bool SAL_CALL OApplicationController::closeSubComponents( ) throw (RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
return m_pSubComponentManager->closeSubComponents();
}
@@ -450,7 +452,7 @@ namespace
case DatabaseObject::FORM: eType = E_FORM; break;
case DatabaseObject::REPORT: eType = E_REPORT; break;
default:
- OSL_ENSURE( false, "lcl_objectType2ElementType: unsupported object type!" );
+ OSL_FAIL( "lcl_objectType2ElementType: unsupported object type!" );
// this should have been caught earlier
}
return eType;
@@ -516,7 +518,7 @@ Reference< XComponent > SAL_CALL OApplicationController::loadComponent( ::sal_In
Reference< XComponent > SAL_CALL OApplicationController::loadComponentWithArguments( ::sal_Int32 _ObjectType,
const ::rtl::OUString& _ObjectName, ::sal_Bool _ForEditing, const Sequence< PropertyValue >& _Arguments ) throw (IllegalArgumentException, NoSuchElementException, SQLException, RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
impl_validateObjectTypeAndName_throw( _ObjectType, _ObjectName );
@@ -541,7 +543,7 @@ Reference< XComponent > SAL_CALL OApplicationController::createComponent( ::sal_
// -----------------------------------------------------------------------------
Reference< XComponent > SAL_CALL OApplicationController::createComponentWithArguments( ::sal_Int32 i_nObjectType, const Sequence< PropertyValue >& i_rArguments, Reference< XComponent >& o_DocumentDefinition ) throw (IllegalArgumentException, SQLException, RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
impl_validateObjectTypeAndName_throw( i_nObjectType, ::boost::optional< ::rtl::OUString >() );
@@ -571,7 +573,7 @@ void SAL_CALL OApplicationController::releaseContextMenuInterceptor( const Refer
// -----------------------------------------------------------------------------
void OApplicationController::previewChanged( sal_Int32 _nMode )
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( m_xDataSource.is() && !isDataSourceReadOnly() )
@@ -596,20 +598,6 @@ void OApplicationController::previewChanged( sal_Int32 _nMode )
InvalidateFeature(SID_DB_APP_VIEW_DOC_PREVIEW);
}
// -----------------------------------------------------------------------------
-//void OApplicationController::updateTitle()
-//{
-// ::rtl::OUString sName = getStrippedDatabaseName();
-//
-// String sTitle = String(ModuleRes(STR_APP_TITLE));
-// sName = sName + sTitle;
-//#ifdef DBG_UTIL
-// ::rtl::OUString aDefault;
-// sName += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" ["));
-// sName += utl::Bootstrap::getBuildIdData( aDefault );
-// sName += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("]"));
-//#endif
-//}
-// -----------------------------------------------------------------------------
void OApplicationController::askToReconnect()
{
if ( m_bNeedToReconnect )
@@ -853,3 +841,5 @@ ElementType OApplicationController::getElementType(const Reference< XContainer >
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.cxx b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
index 00abdacd576c..a71ae69477d4 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.cxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,137 +28,51 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_APPDETAILPAGEHELPER_HXX
#include "AppDetailPageHelper.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBAUI_TABLETREE_HXX_
#include "tabletree.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_DBTREELISTBOX_HXX
#include "dbtreelistbox.hxx"
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XLAYOUTMANAGER_HPP_
#include <com/sun/star/frame/XLayoutManager.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XTABCONTROLLER_HPP_
#include <com/sun/star/awt/XTabController.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XFRAME_HPP_
#include <com/sun/star/frame/XFrame.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_
#include <com/sun/star/frame/XComponentLoader.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XFRAMES_HPP_
#include <com/sun/star/frame/XFrames.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XFRAMESSUPPLIER_HPP_
#include <com/sun/star/frame/XFramesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XWINDOW_HPP_
#include <com/sun/star/awt/XWindow.hpp>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCOMMANDENVIRONMENT_HPP_
#include <com/sun/star/ucb/XCommandEnvironment.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCOMMANDPROCESSOR_HPP_
#include <com/sun/star/ucb/XCommandProcessor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_COMMAND_HPP_
#include <com/sun/star/ucb/Command.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XLOADABLE_HPP_
#include <com/sun/star/form/XLoadable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XCLOSEABLE_HPP_
#include <com/sun/star/util/XCloseable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_XDATABASEDOCUMENTUI_HPP_
#include <com/sun/star/sdb/application/XDatabaseDocumentUI.hpp>
-#endif
#include <com/sun/star/sdb/application/DatabaseObject.hpp>
#include <com/sun/star/sdb/application/DatabaseObjectContainer.hpp>
-#ifndef DBAUI_APPVIEW_HXX
#include "AppView.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBU_APP_HRC_
#include "dbu_app.hrc"
-#endif
-#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#include "callbacks.hxx"
-#endif
-#ifndef DBAUI_ICONTROLLER_HXX
#include "IController.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBACCESS_SLOTID_HRC_
#include "dbaccess_slotid.hrc"
-#endif
-#ifndef DBACCESS_DATABASE_OBJECT_VIEW_HXX
#include "databaseobjectview.hxx"
-#endif
-#ifndef DBACCESS_IMAGEPROVIDER_HXX
#include "imageprovider.hxx"
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _STREAM_HXX
#include <tools/stream.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _RTL_USTRBUF_HXX_
#include <rtl/ustrbuf.hxx>
-#endif
#include "IApplicationController.hxx"
#include <com/sun/star/document/XDocumentProperties.hpp>
@@ -278,7 +193,7 @@ namespace
{
SetTextColor( rStyleSettings.GetFieldTextColor() );
SetTextFillColor();
- } // if( bForeground || bFont )
+ }
if( bBackground )
SetBackground( rStyleSettings.GetFieldColor() );
@@ -337,9 +252,9 @@ OAppDetailPageHelper::~OAppDetailPageHelper()
if ( xCloseable.is() )
xCloseable->close(sal_True);
}
- catch(Exception)
+ catch(const Exception&)
{
- OSL_ENSURE(0,"Exception thrown while disposing preview frame!");
+ OSL_FAIL("Exception thrown while disposing preview frame!");
}
for (int i=0; i < E_ELEMENT_TYPE_COUNT; ++i)
@@ -459,7 +374,7 @@ void OAppDetailPageHelper::describeCurrentSelectionForControl( const Control& _r
return;
}
}
- OSL_ENSURE( false, "OAppDetailPageHelper::describeCurrentSelectionForControl: invalid control!" );
+ OSL_FAIL( "OAppDetailPageHelper::describeCurrentSelectionForControl: invalid control!" );
}
// -----------------------------------------------------------------------------
@@ -515,7 +430,7 @@ void OAppDetailPageHelper::describeCurrentSelectionForType( const ElementType _e
}
break;
default:
- OSL_ENSURE( false, "OAppDetailPageHelper::describeCurrentSelectionForType: unexpected type!" );
+ OSL_FAIL( "OAppDetailPageHelper::describeCurrentSelectionForType: unexpected type!" );
break;
}
@@ -628,13 +543,11 @@ sal_Bool OAppDetailPageHelper::isCutAllowed()
// -----------------------------------------------------------------------------
sal_Bool OAppDetailPageHelper::isCopyAllowed()
{
- //int nPos = getVisibleControlIndex();
return sal_True;
}
// -----------------------------------------------------------------------------
sal_Bool OAppDetailPageHelper::isPasteAllowed()
{
- //int nPos = getVisibleControlIndex();
return sal_True;
}
// -----------------------------------------------------------------------------
@@ -708,8 +621,7 @@ void OAppDetailPageHelper::createTablesPage(const Reference< XConnection>& _xCon
ImageProvider aImageProvider( _xConnection );
createTree( pTreeView,
- aImageProvider.getDefaultImage( DatabaseObject::TABLE, false ),
- aImageProvider.getDefaultImage( DatabaseObject::TABLE, true )
+ aImageProvider.getDefaultImage( DatabaseObject::TABLE )
);
pTreeView->notifyHiContrastChanged();
@@ -729,10 +641,10 @@ void OAppDetailPageHelper::createTablesPage(const Reference< XConnection>& _xCon
}
// -----------------------------------------------------------------------------
-void OAppDetailPageHelper::getElementIcons( ElementType _eType, sal_uInt16& _rImageId, sal_uInt16& _rHighContrastImageId )
+void OAppDetailPageHelper::getElementIcons( ElementType _eType, sal_uInt16& _rImageId)
{
ImageProvider aImageProvider;
- _rImageId = _rHighContrastImageId = 0;
+ _rImageId = 0;
sal_Int32 nDatabaseObjectType( 0 );
switch(_eType )
@@ -741,11 +653,10 @@ void OAppDetailPageHelper::getElementIcons( ElementType _eType, sal_uInt16& _rIm
case E_REPORT: nDatabaseObjectType = DatabaseObject::REPORT; break;
case E_QUERY: nDatabaseObjectType = DatabaseObject::QUERY; break;
default:
- OSL_ENSURE( sal_False, "OAppDetailPageHelper::GetElementIcons: invalid element type!" );
+ OSL_FAIL( "OAppDetailPageHelper::GetElementIcons: invalid element type!" );
return;
}
- _rImageId = aImageProvider.getDefaultImageResourceID( nDatabaseObjectType, false );
- _rHighContrastImageId = aImageProvider.getDefaultImageResourceID( nDatabaseObjectType, true );
+ _rImageId = aImageProvider.getDefaultImageResourceID( nDatabaseObjectType );
}
// -----------------------------------------------------------------------------
@@ -753,42 +664,39 @@ void OAppDetailPageHelper::createPage(ElementType _eType,const Reference< XNameA
{
OSL_ENSURE(E_TABLE != _eType,"E_TABLE isn't allowed.");
- sal_uInt16 nImageId = 0, nImageIdH = 0;
+ sal_uInt16 nImageId = 0;
rtl::OString sHelpId;
ImageProvider aImageProvider;
- Image aFolderImage, aFolderImageHC;
+ Image aFolderImage;
switch( _eType )
{
case E_FORM:
sHelpId = HID_APP_FORM_TREE;
- aFolderImage = aImageProvider.getFolderImage( DatabaseObject::FORM, false );
- aFolderImageHC = aImageProvider.getFolderImage( DatabaseObject::FORM, true );
+ aFolderImage = aImageProvider.getFolderImage( DatabaseObject::FORM );
break;
case E_REPORT:
sHelpId = HID_APP_REPORT_TREE;
- aFolderImage = aImageProvider.getFolderImage( DatabaseObject::REPORT, false );
- aFolderImageHC = aImageProvider.getFolderImage( DatabaseObject::REPORT, true );
+ aFolderImage = aImageProvider.getFolderImage( DatabaseObject::REPORT );
break;
case E_QUERY:
sHelpId = HID_APP_QUERY_TREE;
- aFolderImage = aImageProvider.getFolderImage( DatabaseObject::QUERY, false );
- aFolderImageHC = aImageProvider.getFolderImage( DatabaseObject::QUERY, true );
+ aFolderImage = aImageProvider.getFolderImage( DatabaseObject::QUERY );
break;
default:
- OSL_ENSURE(0,"Illegal call!");
+ OSL_FAIL("Illegal call!");
}
- getElementIcons( _eType, nImageId, nImageIdH );
+ getElementIcons( _eType, nImageId );
if ( !m_pLists[_eType] )
{
- m_pLists[_eType] = createSimpleTree( sHelpId, aFolderImage, aFolderImageHC );
+ m_pLists[_eType] = createSimpleTree( sHelpId, aFolderImage );
}
if ( m_pLists[_eType] )
{
if ( !m_pLists[_eType]->GetEntryCount() && _xContainer.is() )
{
- fillNames( _xContainer, _eType, nImageId, nImageIdH, NULL );
+ fillNames( _xContainer, _eType, nImageId, NULL );
m_pLists[_eType]->SelectAll(sal_False);
}
@@ -836,7 +744,7 @@ namespace
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContainer, const ElementType _eType,
- const sal_uInt16 _nImageId, const sal_uInt16 _nHighContrastImageId, SvLBoxEntry* _pParent )
+ const sal_uInt16 _nImageId, SvLBoxEntry* _pParent )
{
OSL_ENSURE(_xContainer.is(),"Data source is NULL! -> GPF");
OSL_ENSURE( ( _eType >= E_TABLE ) && ( _eType < E_ELEMENT_TYPE_COUNT ), "OAppDetailPageHelper::fillNames: invalid type!" );
@@ -861,33 +769,29 @@ void OAppDetailPageHelper::fillNames( const Reference< XNameAccess >& _xContaine
{
pEntry = pList->InsertEntry( *pIter, _pParent, sal_False, LIST_APPEND, reinterpret_cast< void* >( nFolderIndicator ) );
getBorderWin().getView()->getAppController().containerFound( Reference< XContainer >( xSubElements, UNO_QUERY ) );
- fillNames( xSubElements, _eType, _nImageId, _nHighContrastImageId, pEntry );
+ fillNames( xSubElements, _eType, _nImageId, pEntry );
}
else
{
pEntry = pList->InsertEntry( *pIter, _pParent );
Image aImage = Image( ModuleRes( _nImageId ) );
- pList->SetExpandedEntryBmp( pEntry, aImage, BMP_COLOR_NORMAL );
- pList->SetCollapsedEntryBmp( pEntry, aImage, BMP_COLOR_NORMAL );
-
- Image aHCImage = Image( ModuleRes( _nHighContrastImageId ) );
- pList->SetExpandedEntryBmp( pEntry, aHCImage, BMP_COLOR_HIGHCONTRAST );
- pList->SetCollapsedEntryBmp( pEntry, aHCImage, BMP_COLOR_HIGHCONTRAST );
+ pList->SetExpandedEntryBmp( pEntry, aImage );
+ pList->SetCollapsedEntryBmp( pEntry, aImage );
}
}
}
}
// -----------------------------------------------------------------------------
-DBTreeListBox* OAppDetailPageHelper::createSimpleTree( const rtl::OString& _sHelpId, const Image& _rImage, const Image& _rImageHC )
+DBTreeListBox* OAppDetailPageHelper::createSimpleTree( const rtl::OString& _sHelpId, const Image& _rImage)
{
DBTreeListBox* pTreeView = new DBTreeListBox(this,getBorderWin().getView()->getORB(),WB_HASLINES | WB_SORT | WB_HASBUTTONS | WB_HSCROLL |WB_HASBUTTONSATROOT | WB_TABSTOP);
pTreeView->SetHelpId( _sHelpId );
- return createTree( pTreeView, _rImage, _rImageHC );
+ return createTree( pTreeView, _rImage );
}
// -----------------------------------------------------------------------------
-DBTreeListBox* OAppDetailPageHelper::createTree( DBTreeListBox* _pTreeView, const Image& _rImage, const Image& _rImageHC )
+DBTreeListBox* OAppDetailPageHelper::createTree( DBTreeListBox* _pTreeView, const Image& _rImage )
{
WaitObject aWaitCursor(this);
@@ -897,9 +801,7 @@ DBTreeListBox* OAppDetailPageHelper::createTree( DBTreeListBox* _pTreeView, cons
_pTreeView->SetSelectionMode(MULTIPLE_SELECTION);
_pTreeView->SetDefaultCollapsedEntryBmp( _rImage );
- _pTreeView->SetDefaultCollapsedEntryBmp( _rImageHC, BMP_COLOR_HIGHCONTRAST );
_pTreeView->SetDefaultExpandedEntryBmp( _rImage );
- _pTreeView->SetDefaultExpandedEntryBmp( _rImageHC, BMP_COLOR_HIGHCONTRAST );
_pTreeView->SetDoubleClickHdl(LINK(this, OAppDetailPageHelper, OnEntryDoubleClick));
_pTreeView->SetEnterKeyHdl(LINK(this, OAppDetailPageHelper, OnEntryDoubleClick));
@@ -958,7 +860,7 @@ void OAppDetailPageHelper::elementReplaced(ElementType _eType
pEntry = lcl_findEntry(*pTreeView,_rOldName,pTreeView->First());
break;
default:
- OSL_ENSURE(0,"Invalid element type");
+ OSL_FAIL("Invalid element type");
}
OSL_ENSURE(pEntry,"Do you know that the name isn't existence!");
if ( pEntry )
@@ -991,26 +893,22 @@ SvLBoxEntry* OAppDetailPageHelper::elementAdded(ElementType _eType,const ::rtl::
}
}
- sal_uInt16 nImageId = 0, nImageIdH = 0;
- getElementIcons( _eType, nImageId, nImageIdH );
+ sal_uInt16 nImageId = 0;
+ getElementIcons( _eType, nImageId );
Reference<XNameAccess> xContainer(_rObject,UNO_QUERY);
if ( xContainer.is() )
{
const sal_Int32 nFolderIndicator = lcl_getFolderIndicatorForType( _eType );
pRet = pTreeView->InsertEntry( _rName, pEntry, sal_False, LIST_APPEND, reinterpret_cast< void* >( nFolderIndicator ) );
- fillNames( xContainer, _eType, nImageId, nImageIdH, pRet );
+ fillNames( xContainer, _eType, nImageId, pRet );
}
else
{
pRet = pTreeView->InsertEntry( _rName, pEntry );
Image aImage = Image( ModuleRes( nImageId ) );
- pTreeView->SetExpandedEntryBmp( pRet, aImage, BMP_COLOR_NORMAL );
- pTreeView->SetCollapsedEntryBmp( pRet, aImage, BMP_COLOR_NORMAL );
-
- Image aHCImage = Image( ModuleRes( nImageIdH ) );
- pTreeView->SetExpandedEntryBmp( pRet, aHCImage, BMP_COLOR_HIGHCONTRAST );
- pTreeView->SetCollapsedEntryBmp( pRet, aHCImage, BMP_COLOR_HIGHCONTRAST );
+ pTreeView->SetExpandedEntryBmp( pRet, aImage );
+ pTreeView->SetCollapsedEntryBmp( pRet, aImage );
}
}
return pRet;
@@ -1047,7 +945,7 @@ void OAppDetailPageHelper::elementRemoved( ElementType _eType,const ::rtl::OUStr
}
break;
default:
- OSL_ENSURE(0,"Invalid element type");
+ OSL_FAIL("Invalid element type");
}
if ( !pTreeView->GetEntryCount() )
showPreview(NULL);
@@ -1093,8 +991,7 @@ IMPL_LINK( OAppDetailPageHelper, OnDeleteEntry, void*, /*NOINTERESTEDIN*/ )
// -----------------------------------------------------------------------------
void OAppDetailPageHelper::Resize()
{
- //////////////////////////////////////////////////////////////////////
- // Abmessungen parent window
+ // parent window dimension
Size aOutputSize( GetOutputSize() );
long nOutputWidth = aOutputSize.Width();
long nOutputHeight = aOutputSize.Height();
@@ -1231,12 +1128,6 @@ void OAppDetailPageHelper::showPreview(const Reference< XContent >& _xContent)
{
m_aPreview.Hide();
m_aDocumentInfo.Hide();
-
- // Why the below code? It might have side effects, as the tree view needs to know
- // its current selection for other purposes than the preview, too.
-// DBTreeListBox* pTreeView = getCurrentView();
-// if ( pTreeView )
-// pTreeView->clearCurrentSelection();
}
}
catch( const Exception& )
@@ -1263,9 +1154,9 @@ void OAppDetailPageHelper::showPreview( const ::rtl::OUString& _sDataSourceName,
m_xFrame = Reference < XFrame > ( getBorderWin().getView()->getORB()->createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Frame")) ), UNO_QUERY );
m_xFrame->initialize( m_xWindow );
- // work-around for #150518#: no layout manager (and thus no toolbars) in the preview
+ // no layout manager (and thus no toolbars) in the preview
// Must be called after initialize ... but before any other call to this frame.
- // Otherwhise frame throws "life time exceptions" as e.g. NON_INITIALIZED
+ // Otherwise frame throws "life time exceptions" as e.g. NON_INITIALIZED
Reference< XPropertySet > xFrameProps( m_xFrame, UNO_QUERY_THROW );
xFrameProps->setPropertyValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "LayoutManager" ) ), makeAny(Reference< XLayoutManager >()) );
@@ -1276,7 +1167,7 @@ void OAppDetailPageHelper::showPreview( const ::rtl::OUString& _sDataSourceName,
xFrames->append(m_xFrame);
}
}
- catch(Exception)
+ catch(const Exception&)
{
}
}
@@ -1334,7 +1225,7 @@ IMPL_LINK(OAppDetailPageHelper, OnDropdownClickHdl, ToolBox*, /*pToolBox*/)
, SID_DB_APP_VIEW_DOCINFO_PREVIEW
};
- for(size_t i=0; i < sizeof(pActions)/sizeof(pActions[0]);++i)
+ for(size_t i=0; i < SAL_N_ELEMENTS(pActions);++i)
{
aMenu->CheckItem(pActions[i],m_aMenu->IsItemChecked(pActions[i]));
}
@@ -1400,34 +1291,25 @@ void OAppDetailPageHelper::DataChanged( const DataChangedEvent& rDCEvt )
void OAppDetailPageHelper::ImplInitSettings()
{
const StyleSettings& rStyleSettings = GetSettings().GetStyleSettings();
- if( true )
- {
Font aFont;
aFont = rStyleSettings.GetFieldFont();
aFont.SetColor( rStyleSettings.GetWindowTextColor() );
SetPointFont( aFont );
m_aTBPreview.SetPointFont( aFont );
- }
- if( true )
- {
SetTextColor( rStyleSettings.GetFieldTextColor() );
SetTextFillColor();
m_aBorder.SetTextColor( rStyleSettings.GetFieldTextColor() );
m_aBorder.SetTextFillColor();
m_aTBPreview.SetTextColor( rStyleSettings.GetFieldTextColor() );
m_aTBPreview.SetTextFillColor();
- } // if( true )
- if( true )
- {
SetBackground( rStyleSettings.GetFieldColor() );
m_aBorder.SetBackground( rStyleSettings.GetFieldColor() );
m_aFL.SetBackground( rStyleSettings.GetFieldColor() );
m_aDocumentInfo.SetBackground( rStyleSettings.GetFieldColor() );
m_aTBPreview.SetBackground( rStyleSettings.GetFieldColor() );
m_pTablePreview->SetBackground( rStyleSettings.GetFieldColor() );
- } // if( true )
}
// -----------------------------------------------------------------------------
OPreviewWindow::OPreviewWindow(Window* _pParent)
@@ -1514,7 +1396,7 @@ void OPreviewWindow::ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal
{
SetTextColor( rStyleSettings.GetFieldTextColor() );
SetTextFillColor();
- } // if( bForeground || bFont )
+ }
if( bBackground )
SetBackground( rStyleSettings.GetFieldColor() );
@@ -1522,3 +1404,4 @@ void OPreviewWindow::ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal
// -----------------------------------------------------------------------------
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.hxx b/dbaccess/source/ui/app/AppDetailPageHelper.hxx
index 0929bd8381f5..69a050c8e2ea 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.hxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,42 +30,18 @@
#include <vector>
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_NAMEDDATABASEOBJECT_HPP_
#include <com/sun/star/sdb/application/NamedDatabaseObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_
#include <com/sun/star/ucb/XContent.hpp>
-#endif
-#ifndef DBAUI_APPELEMENTTYPE_HXX
#include "AppElementType.hxx"
-#endif
-#ifndef _SVTREEBOX_HXX
#include <svtools/svtreebx.hxx>
-#endif
-#ifndef SVTOOLS_DOCUMENTINFOPREVIEW_HXX
#include <svtools/DocumentInfoPreview.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_TOOLBOX_HXX
#include <vcl/toolbox.hxx>
-#endif
-#ifndef _SV_CVTGRF_HXX
#include <vcl/cvtgrf.hxx>
-#endif
-#ifndef _SV_GRAPH_HXX
#include <vcl/graph.hxx>
-#endif
-#ifndef _GRFMGR_HXX
#include <svtools/grfmgr.hxx>
-#endif
#include "callbacks.hxx"
#include <memory>
@@ -142,7 +119,7 @@ namespace dbaui
/** retrieves the resource ids of the images representing elements of the given type
*/
- void getElementIcons( ElementType _eType, sal_uInt16& _rImageId, sal_uInt16& _rHighContrastImageId );
+ void getElementIcons( ElementType _eType, sal_uInt16& _rImageId);
/** fills the names in the listbox
@param _xContainer
@@ -151,15 +128,12 @@ namespace dbaui
the type of elements which are being filled
@param _nImageId
the resource id of the image to use for non-container entries
- @param _nHighContrastImageId
- the resource id of the high contrast image to use for non-container entries
@param _pParent
The parent of the entries to be inserted.
*/
void fillNames( const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameAccess >& _xContainer,
const ElementType _eType,
const sal_uInt16 _nImageId,
- const sal_uInt16 _nHighContrastImageId,
SvLBoxEntry* _pParent );
/** sets the detail page
@@ -173,24 +147,20 @@ namespace dbaui
The newly created DBTreeListBox
@param _rImage
the resource id of the default icon
- @param _rImageHC
- the resource id of the default icon (HC version)
@return
The new tree.
*/
- DBTreeListBox* createTree( DBTreeListBox* _pTreeView, const Image& _rImage, const Image& _rImageHC );
+ DBTreeListBox* createTree( DBTreeListBox* _pTreeView, const Image& _rImage );
/** creates the tree and sets all HandleCallbacks
@param _nHelpId
The help id of the control
@param _nCollapsedBitmap
- The image to use for tree entries.
- @param _rImageHC
The image to use in high contrast mode.
@return
The new tree.
*/
- DBTreeListBox* createSimpleTree( const rtl::OString& _sHelpId, const Image& _rImage, const Image& _rImageHC );
+ DBTreeListBox* createSimpleTree( const rtl::OString& _sHelpId, const Image& _rImage);
DECL_LINK( OnEntryDoubleClick, SvTreeListBox* );
DECL_LINK( OnEntrySelChange, void* );
@@ -401,3 +371,4 @@ namespace dbaui
}
#endif // DBAUI_APPDETAILPAGEHELPER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppDetailView.cxx b/dbaccess/source/ui/app/AppDetailView.cxx
index 911868e144c6..520f206f769a 100644
--- a/dbaccess/source/ui/app/AppDetailView.cxx
+++ b/dbaccess/source/ui/app/AppDetailView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,75 +28,29 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_APPDETAILVIEW_HXX
#include "AppDetailView.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
+#include <osl/diagnose.h>
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBU_APP_HRC_
#include "dbu_app.hrc"
-#endif
-#ifndef DBAUI_APPVIEW_HXX
#include "AppView.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UI_XUICONFIGURATIONMANAGER_HPP_
#include <com/sun/star/ui/XUIConfigurationManager.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XMODULEUICONFIGURATIONMANAGERSUPPLIER_HPP_
#include <com/sun/star/ui/XModuleUIConfigurationManagerSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XIMAGEMANAGER_HPP_
#include <com/sun/star/ui/XImageManager.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_IMAGETYPE_HPP_
#include <com/sun/star/ui/ImageType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_GRAPHIC_XGRAPHIC_HPP_
#include <com/sun/star/graphic/XGraphic.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_URL_HPP_
#include <com/sun/star/util/URL.hpp>
-#endif
-#ifndef _DBAUI_LISTVIEWITEMS_HXX_
#include "listviewitems.hxx"
-#endif
-#ifndef _IMAGE_HXX //autogen
#include <vcl/image.hxx>
-#endif
-#ifndef _SV_MNEMONIC_HXX
#include <vcl/mnemonic.hxx>
-#endif
-#ifndef _SV_MNEMONIC_HXX
#include <vcl/mnemonic.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef DBAUI_APPDETAILPAGEHELPER_HXX
#include "AppDetailPageHelper.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#include "callbacks.hxx"
-#endif
-#ifndef DBAUI_ICONTROLLER_HXX
#include "IController.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _SVTOOLS_LOCALRESACCESS_HXX_
#include <svtools/localresaccess.hxx>
-#endif
#include <algorithm>
#include "dbtreelistbox.hxx"
#include "IApplicationController.hxx"
@@ -185,7 +140,7 @@ void OCreationList::PreparePaint( SvLBoxEntry* _pEntry )
void OCreationList::SelectSearchEntry( const void* _pEntry )
{
SvLBoxEntry* pEntry = const_cast< SvLBoxEntry* >( static_cast< const SvLBoxEntry* >( _pEntry ) );
- DBG_ASSERT( pEntry, "OCreationList::SelectSearchEntry: invalid entry!" );
+ OSL_ENSURE( pEntry, "OCreationList::SelectSearchEntry: invalid entry!" );
if ( pEntry )
setCurrentEntryInvalidate( pEntry );
@@ -198,8 +153,8 @@ void OCreationList::SelectSearchEntry( const void* _pEntry )
void OCreationList::ExecuteSearchEntry( const void* _pEntry ) const
{
SvLBoxEntry* pEntry = const_cast< SvLBoxEntry* >( static_cast< const SvLBoxEntry* >( _pEntry ) );
- DBG_ASSERT( pEntry, "OCreationList::ExecuteSearchEntry: invalid entry!" );
- DBG_ASSERT( pEntry == GetCurEntry(), "OCreationList::ExecuteSearchEntry: SelectSearchEntry should have been called before!" );
+ OSL_ENSURE( pEntry, "OCreationList::ExecuteSearchEntry: invalid entry!" );
+ OSL_ENSURE( pEntry == GetCurEntry(), "OCreationList::ExecuteSearchEntry: SelectSearchEntry should have been called before!" );
if ( pEntry )
onSelected( pEntry );
@@ -215,7 +170,7 @@ Rectangle OCreationList::GetFocusRect( SvLBoxEntry* _pEntry, long _nLine )
SvLBoxItem* pBitmapItem = _pEntry->GetFirstItem( SV_ITEM_ID_LBOXCONTEXTBMP );
SvLBoxTab* pTab = pBitmapItem ? GetTab( _pEntry, pBitmapItem ) : NULL;
SvViewDataItem* pItemData = pBitmapItem ? GetViewDataItem( _pEntry, pBitmapItem ) : NULL;
- DBG_ASSERT( pTab && pItemData, "OCreationList::GetFocusRect: could not find the first bitmap item!" );
+ OSL_ENSURE( pTab && pItemData, "OCreationList::GetFocusRect: could not find the first bitmap item!" );
if ( pTab && pItemData )
aRect.Left() = pTab->GetPos() - pItemData->aSize.Width() / 2;
@@ -259,7 +214,7 @@ void OCreationList::MouseButtonDown( const MouseEvent& rMEvt )
{
SvTreeListBox::MouseButtonDown( rMEvt );
- DBG_ASSERT( !m_pMouseDownEntry, "OCreationList::MouseButtonDown: I missed some mouse event!" );
+ OSL_ENSURE( !m_pMouseDownEntry, "OCreationList::MouseButtonDown: I missed some mouse event!" );
m_pMouseDownEntry = GetCurEntry();
if ( m_pMouseDownEntry )
{
@@ -281,14 +236,14 @@ void OCreationList::MouseMove( const MouseEvent& rMEvt )
if ( m_pMouseDownEntry )
{
// we're currently in a "mouse down" phase
- DBG_ASSERT( IsMouseCaptured(), "OCreationList::MouseMove: inconsistence (1)!" );
+ OSL_ENSURE( IsMouseCaptured(), "OCreationList::MouseMove: inconsistence (1)!" );
if ( pEntry == m_pMouseDownEntry )
{
setCurrentEntryInvalidate( m_pMouseDownEntry );
}
else
{
- DBG_ASSERT( ( GetCurEntry() == m_pMouseDownEntry ) || !GetCurEntry(),
+ OSL_ENSURE( ( GetCurEntry() == m_pMouseDownEntry ) || !GetCurEntry(),
"OCreationList::MouseMove: inconsistence (2)!" );
setCurrentEntryInvalidate( NULL );
}
@@ -321,7 +276,7 @@ void OCreationList::MouseButtonUp( const MouseEvent& rMEvt )
if ( m_pMouseDownEntry )
{
- DBG_ASSERT( IsMouseCaptured(), "OCreationList::MouseButtonUp: hmmm .... no mouse captured, but an active entry?" );
+ OSL_ENSURE( IsMouseCaptured(), "OCreationList::MouseButtonUp: hmmm .... no mouse captured, but an active entry?" );
ReleaseMouse();
InvalidateEntry( m_pMouseDownEntry );
@@ -362,7 +317,7 @@ void OCreationList::updateHelpText()
// -----------------------------------------------------------------------------
void OCreationList::onSelected( SvLBoxEntry* _pEntry ) const
{
- DBG_ASSERT( _pEntry, "OCreationList::onSelected: invalid entry!" );
+ OSL_ENSURE( _pEntry, "OCreationList::onSelected: invalid entry!" );
URL aCommand;
aCommand.Complete = reinterpret_cast< TaskEntry* >( _pEntry->GetUserData() )->sUNOCommand;
m_rTaskWindow.getDetailView()->getBorderWin().getView()->getAppController().executeChecked( aCommand, Sequence< PropertyValue >() );
@@ -393,7 +348,7 @@ void OCreationList::KeyInput( const KeyEvent& rKEvt )
{
InvalidateEntry( pNewCurrent );
CallEventListeners( VCLEVENT_LISTBOX_SELECT, pNewCurrent );
- } // if ( pNewCurrent )
+ }
updateHelpText();
}
}
@@ -416,7 +371,7 @@ OTasksWindow::OTasksWindow(Window* _pParent,OApplicationDetailView* _pDetailView
m_aDescription.SetText(ModuleRes(STR_DESCRIPTION));
ImageProvider aImageProvider;
- Image aFolderImage = aImageProvider.getFolderImage( DatabaseObject::FORM, false );
+ Image aFolderImage = aImageProvider.getFolderImage( DatabaseObject::FORM );
m_aCreation.SetDefaultCollapsedEntryBmp( aFolderImage );
m_aCreation.SetDefaultExpandedEntryBmp( aFolderImage );
@@ -462,8 +417,6 @@ void OTasksWindow::ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal_B
m_aHelpText.SetTextFillColor();
m_aDescription.SetTextColor( rStyleSettings.GetFieldTextColor() );
m_aDescription.SetTextFillColor();
- //m_aFL.SetTextColor( rStyleSettings.GetFieldTextColor() );
- //m_aFL.SetTextFillColor();
}
if( bBackground )
@@ -486,11 +439,6 @@ void OTasksWindow::setHelpText(sal_uInt16 _nId)
{
String sText = ModuleRes(_nId);
- // calulate the size of the text field
- // Size aHelpTextSize = m_aHelpText.GetSizePixel();
- // Size aHelpTextPixelSize = LogicToPixel( aHelpTextSize, MAP_APPFONT );
- // Rectangle aPrimaryRect( Point(0,0), aHelpTextSize );
- // Rectangle aSuggestedRect( GetTextRect( aPrimaryRect, sText, TEXT_DRAW_MULTILINE | TEXT_DRAW_LEFT | TEXT_DRAW_WORDBREAK ) );
m_aHelpText.SetText(sText);
}
else
@@ -511,8 +459,8 @@ IMPL_LINK(OTasksWindow, OnEntrySelectHdl, SvTreeListBox*, /*_pTreeBox*/)
void OTasksWindow::Resize()
{
DBG_CHKTHIS(OTasksWindow,NULL);
- //////////////////////////////////////////////////////////////////////
- // Abmessungen parent window
+
+ // parent window dimension
Size aOutputSize( GetOutputSize() );
long nOutputWidth = aOutputSize.Width();
long nOutputHeight = aOutputSize.Height();
@@ -524,9 +472,6 @@ void OTasksWindow::Resize()
m_aCreation.SetPosSizePixel( Point(0, 0), Size(nHalfOutputWidth - n6PPT, nOutputHeight) );
// i77897 make the m_aHelpText a little bit smaller. (-5)
sal_Int32 nNewWidth = nOutputWidth - nHalfOutputWidth - aFLSize.Width() - 5;
- // m_aHelpText.SetBackground( MAKE_SALCOLOR( 0xe0, 0xe0, 0xe0 ) );
- // Wallpaper aLightGray(Color(0xe0, 0xe0, 0xe0));
- // m_aHelpText.SetBackground( aLightGray );
m_aDescription.SetPosSizePixel( Point(nHalfOutputWidth + n6PPT, 0), Size(nNewWidth, nOutputHeight) );
Size aDesc = m_aDescription.CalcMinimumSize();
m_aHelpText.SetPosSizePixel( Point(nHalfOutputWidth + n6PPT, aDesc.Height() ), Size(nNewWidth, nOutputHeight - aDesc.Height() - n6PPT) );
@@ -541,9 +486,16 @@ void OTasksWindow::fillTaskEntryList( const TaskEntryList& _rList )
try
{
- Reference<XModuleUIConfigurationManagerSupplier> xModuleCfgMgrSupplier(getDetailView()->getBorderWin().getView()->getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.ModuleUIConfigurationManagerSupplier"))),UNO_QUERY);
- Reference<XUIConfigurationManager> xUIConfigMgr = xModuleCfgMgrSupplier->getUIConfigurationManager(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.OfficeDatabaseDocument")));
- Reference<XImageManager> xImageMgr(xUIConfigMgr->getImageManager(),UNO_QUERY);
+ Reference< XModuleUIConfigurationManagerSupplier > xModuleCfgMgrSupplier(
+ getDetailView()->getBorderWin().getView()->getORB()->createInstance(
+ ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.ui.ModuleUIConfigurationManagerSupplier" ) )
+ ) ,
+ UNO_QUERY
+ );
+ Reference< XUIConfigurationManager > xUIConfigMgr = xModuleCfgMgrSupplier->getUIConfigurationManager(
+ ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "com.sun.star.sdb.OfficeDatabaseDocument" ) )
+ );
+ Reference< XImageManager > xImageMgr( xUIConfigMgr->getImageManager(), UNO_QUERY );
// copy the commands so we can use them with the config managers
Sequence< ::rtl::OUString > aCommands( _rList.size() );
@@ -552,24 +504,21 @@ void OTasksWindow::fillTaskEntryList( const TaskEntryList& _rList )
for ( TaskEntryList::const_iterator pCopyTask = _rList.begin(); pCopyTask != aEnd; ++pCopyTask, ++pCommands )
*pCommands = pCopyTask->sUNOCommand;
- Sequence< Reference< XGraphic> > aImages = xImageMgr->getImages( ImageType::SIZE_DEFAULT | ImageType::COLOR_NORMAL, aCommands );
- Sequence< Reference< XGraphic> > aHCImages = xImageMgr->getImages( ImageType::SIZE_DEFAULT | ImageType::COLOR_HIGHCONTRAST, aCommands );
+ Sequence< Reference< XGraphic> > aImages = xImageMgr->getImages(
+ ImageType::SIZE_DEFAULT | ImageType::COLOR_NORMAL ,
+ aCommands
+ );
const Reference< XGraphic >* pImages( aImages.getConstArray() );
- const Reference< XGraphic >* pHCImages( aHCImages.getConstArray() );
- for ( TaskEntryList::const_iterator pTask = _rList.begin(); pTask != aEnd; ++pTask, ++pImages, ++pHCImages )
+ for ( TaskEntryList::const_iterator pTask = _rList.begin(); pTask != aEnd; ++pTask, ++pImages )
{
SvLBoxEntry* pEntry = m_aCreation.InsertEntry( pTask->sTitle );
pEntry->SetUserData( reinterpret_cast< void* >( new TaskEntry( *pTask ) ) );
Image aImage = Image( *pImages );
- m_aCreation.SetExpandedEntryBmp( pEntry, aImage, BMP_COLOR_NORMAL );
- m_aCreation.SetCollapsedEntryBmp( pEntry, aImage, BMP_COLOR_NORMAL );
-
- Image aHCImage = Image( *pHCImages );
- m_aCreation.SetExpandedEntryBmp( pEntry, aHCImage, BMP_COLOR_HIGHCONTRAST );
- m_aCreation.SetCollapsedEntryBmp( pEntry, aHCImage, BMP_COLOR_HIGHCONTRAST );
+ m_aCreation.SetExpandedEntryBmp( pEntry, aImage );
+ m_aCreation.SetCollapsedEntryBmp( pEntry, aImage );
}
}
catch(Exception&)
@@ -664,7 +613,6 @@ void OApplicationDetailView::ImplInitSettings( sal_Bool bFont, sal_Bool bForegro
if( bBackground )
SetBackground( rStyleSettings.GetFieldColor() );
- //SetBackground( Wallpaper( GetSettings().GetStyleSettings().GetDialogColor() ) );
m_aHorzSplitter.SetBackground( rStyleSettings.GetDialogColor() );
m_aHorzSplitter.SetFillColor( rStyleSettings.GetDialogColor() );
m_aHorzSplitter.SetTextFillColor(rStyleSettings.GetDialogColor() );
@@ -757,7 +705,6 @@ const TaskPaneData& OApplicationDetailView::impl_getTaskPaneData( ElementType _e
OSL_ENSURE( ( _eType >= 0 ) && ( _eType < E_ELEMENT_TYPE_COUNT ), "OApplicationDetailView::impl_getTaskPaneData: illegal element type!" );
TaskPaneData& rData = m_aTaskPaneData[ _eType ];
-// if ( rData.aTasks.empty() )
//oj: do not check, otherwise extensions will only be visible after a reload.
impl_fillTaskPaneData( _eType, rData );
@@ -799,7 +746,7 @@ void OApplicationDetailView::impl_fillTaskPaneData( ElementType _eType, TaskPane
break;
default:
- OSL_ENSURE( false, "OApplicationDetailView::impl_fillTaskPaneData: illegal element type!" );
+ OSL_FAIL( "OApplicationDetailView::impl_fillTaskPaneData: illegal element type!" );
}
MnemonicGenerator aAllMnemonics( m_aExternalMnemonics );
@@ -1013,3 +960,4 @@ Window* OApplicationDetailView::getTreeWindow() const
return m_pControlHelper->getCurrentView();
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppDetailView.hxx b/dbaccess/source/ui/app/AppDetailView.hxx
index c110f90ed4fd..df890bbafb4b 100644
--- a/dbaccess/source/ui/app/AppDetailView.hxx
+++ b/dbaccess/source/ui/app/AppDetailView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,45 +28,19 @@
#ifndef DBAUI_APPDETAILVIEW_HXX
#define DBAUI_APPDETAILVIEW_HXX
-#ifndef _COM_SUN_STAR_FRAME_XCONTROLLER_HPP_
#include <com/sun/star/frame/XController.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_
#include <com/sun/star/ucb/XContent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_NAMEDDATABASEOBJECT_HPP_
#include <com/sun/star/sdb/application/NamedDatabaseObject.hpp>
-#endif
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_MNEMONIC_HXX
#include <vcl/mnemonic.hxx>
-#endif
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
-#ifndef DBAUI_TITLE_WINDOW_HXX
#include "AppTitleWindow.hxx"
-#endif
-#ifndef DBAUI_APPELEMENTTYPE_HXX
#include "AppElementType.hxx"
-#endif
-#ifndef _SVTREEBOX_HXX
#include <svtools/svtreebx.hxx>
-#endif
-#ifndef DBAUI_VERTSPLITVIEW_HXX
#include "VertSplitView.hxx"
-#endif
#include <vector>
@@ -196,7 +171,6 @@ namespace dbaui
OApplicationDetailView(OAppBorderWindow& _rParent,PreviewMode _ePreviewMode);
virtual ~OApplicationDetailView();
// window overloads
- // virtual void Resize();
virtual void GetFocus();
/** creates the tables page
@@ -403,3 +377,4 @@ namespace dbaui
}
#endif // DBAUI_APPDETAILVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppIconControl.cxx b/dbaccess/source/ui/app/AppIconControl.cxx
index 40fd0522c803..b2a3b6e51a86 100644
--- a/dbaccess/source/ui/app/AppIconControl.cxx
+++ b/dbaccess/source/ui/app/AppIconControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_APPICONCONTROL_HXX
#include "AppIconControl.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _DBU_APP_HRC_
#include "dbu_app.hrc"
-#endif
-#ifndef _IMAGE_HXX //autogen
#include <vcl/image.hxx>
-#endif
-#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#include "callbacks.hxx"
-#endif
-#ifndef DBAUI_APPELEMENTTYPE_HXX
#include "AppElementType.hxx"
-#endif
#include <memory>
using namespace ::dbaui;
@@ -71,19 +56,17 @@ OApplicationIconControl::OApplicationIconControl(Window* _pParent)
sal_uInt16 nLabelResId;
ElementType eType;
sal_uInt16 nImageResId;
- sal_uInt16 nImageResIdHC;
} aCategories[] = {
- { RID_STR_TABLES_CONTAINER, E_TABLE, IMG_TABLEFOLDER_TREE_L, IMG_TABLEFOLDER_TREE_LHC },
- { RID_STR_QUERIES_CONTAINER, E_QUERY, IMG_QUERYFOLDER_TREE_L, IMG_QUERYFOLDER_TREE_LHC },
- { RID_STR_FORMS_CONTAINER, E_FORM, IMG_FORMFOLDER_TREE_L, IMG_FORMFOLDER_TREE_LHC },
- { RID_STR_REPORTS_CONTAINER, E_REPORT, IMG_REPORTFOLDER_TREE_L,IMG_REPORTFOLDER_TREE_LHC }
+ { RID_STR_TABLES_CONTAINER, E_TABLE, IMG_TABLEFOLDER_TREE_L },
+ { RID_STR_QUERIES_CONTAINER, E_QUERY, IMG_QUERYFOLDER_TREE_L },
+ { RID_STR_FORMS_CONTAINER, E_FORM, IMG_FORMFOLDER_TREE_L },
+ { RID_STR_REPORTS_CONTAINER, E_REPORT, IMG_REPORTFOLDER_TREE_L }
};
- for ( size_t i=0; i < sizeof(aCategories)/sizeof(aCategories[0]); ++i)
+ for ( size_t i=0; i < SAL_N_ELEMENTS(aCategories); ++i)
{
SvxIconChoiceCtrlEntry* pEntry = InsertEntry(
- String( ModuleRes( aCategories[i].nLabelResId ) ),
- Image( ModuleRes( aCategories[i].nImageResId ) ),
- Image( ModuleRes( aCategories[i].nImageResIdHC ) ) );
+ String( ModuleRes( aCategories[i].nLabelResId ) ) ,
+ Image( ModuleRes( aCategories[i].nImageResId ) ) );
if ( pEntry )
pEntry->SetUserData( new ElementType( aCategories[i].eType ) );
}
@@ -133,3 +116,5 @@ sal_Int8 OApplicationIconControl::ExecuteDrop( const ExecuteDropEvent& _rEvt )
return DND_ACTION_NONE;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppIconControl.hxx b/dbaccess/source/ui/app/AppIconControl.hxx
index 0cd6bfdbbf76..3bd27a99a56b 100644
--- a/dbaccess/source/ui/app/AppIconControl.hxx
+++ b/dbaccess/source/ui/app/AppIconControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_APPICONCONTROL_HXX
#define DBAUI_APPICONCONTROL_HXX
-#ifndef _ICNVW_HXX
#include <svtools/ivctrl.hxx>
-#endif
-#ifndef _TRANSFER_HXX
#include <svtools/transfer.hxx>
-#endif
namespace dbaui
@@ -60,3 +57,4 @@ namespace dbaui
}
#endif // DBAUI_APPICONCONTROL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppSwapWindow.cxx b/dbaccess/source/ui/app/AppSwapWindow.cxx
index bc279de46c5a..9e161d86908e 100644
--- a/dbaccess/source/ui/app/AppSwapWindow.cxx
+++ b/dbaccess/source/ui/app/AppSwapWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_APPSWAPWINDOW_HXX
#include "AppSwapWindow.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBU_APP_HRC_
#include "dbu_app.hrc"
-#endif
-#ifndef DBAUI_APPVIEW_HXX
#include "AppView.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_SYSWIN_HXX
#include <vcl/syswin.hxx>
-#endif
-#ifndef _SV_MENU_HXX
#include <vcl/menu.hxx>
-#endif
-#ifndef _SV_MNEMONIC_HXX
#include <vcl/mnemonic.hxx>
-#endif
#include "IApplicationController.hxx"
#include <memory>
@@ -75,7 +58,6 @@ OApplicationSwapWindow::OApplicationSwapWindow( Window* _pParent, OAppBorderWind
,m_rBorderWin( _rBorderWindow )
{
DBG_CTOR(OApplicationSwapWindow,NULL);
-// SetCompoundControl( sal_True );
ImplInitSettings( sal_True, sal_True, sal_True );
@@ -83,7 +65,6 @@ OApplicationSwapWindow::OApplicationSwapWindow( Window* _pParent, OAppBorderWind
m_aIconControl.setControlActionListener( &m_rBorderWin.getView()->getAppController() );
m_aIconControl.SetHelpId(HID_APP_SWAP_ICONCONTROL);
m_aIconControl.Show();
- //m_aIconControl.Enable(sal_True);
}
// -----------------------------------------------------------------------------
OApplicationSwapWindow::~OApplicationSwapWindow()
@@ -186,7 +167,7 @@ bool OApplicationSwapWindow::onContainerSelected( ElementType _eType )
if ( _eType != E_NONE )
m_eLastType = _eType;
return true;
- } // if ( m_rBorderWin.getView()->getAppController().onContainerSelect( _eType ) )
+ }
PostUserEvent( LINK( this, OApplicationSwapWindow, ChangeToLastSelected ) );
return false;
@@ -230,3 +211,5 @@ void OApplicationSwapWindow::selectContainer(ElementType _eType)
else
onContainerSelected( _eType );
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppSwapWindow.hxx b/dbaccess/source/ui/app/AppSwapWindow.hxx
index 9d4ce8d36814..89d535806bd9 100644
--- a/dbaccess/source/ui/app/AppSwapWindow.hxx
+++ b/dbaccess/source/ui/app/AppSwapWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
#ifndef DBAUI_APPSWAPWINDOW_HXX
#define DBAUI_APPSWAPWINDOW_HXX
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef DBAUI_APPICONCONTROL_HXX
#include "AppIconControl.hxx"
-#endif
-#ifndef DBAUI_APPELEMENTTYPE_HXX
#include "AppElementType.hxx"
-#endif
namespace dbaui
{
@@ -110,3 +103,4 @@ namespace dbaui
// .............................................................
#endif // DBAUI_APPSWAPWINDOW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppTitleWindow.cxx b/dbaccess/source/ui/app/AppTitleWindow.cxx
index da15c47b9b34..448f6ea6e9f7 100644
--- a/dbaccess/source/ui/app/AppTitleWindow.cxx
+++ b/dbaccess/source/ui/app/AppTitleWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,19 +28,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TITLE_WINDOW_HXX
#include "AppTitleWindow.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
#include "memory"
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
namespace dbaui
{
@@ -60,7 +53,7 @@ OTitleWindow::OTitleWindow(Window* _pParent,sal_uInt16 _nTitleId,WinBits _nBits,
ImplInitSettings( sal_True, sal_True, sal_True );
Window* pWindows [] = { &m_aSpace1, &m_aSpace2, &m_aTitle };
- for (size_t i=0; i < sizeof(pWindows)/sizeof(pWindows[0]); ++i)
+ for (size_t i=0; i < SAL_N_ELEMENTS(pWindows); ++i)
pWindows[i]->Show();
}
// -----------------------------------------------------------------------------
@@ -84,8 +77,7 @@ void OTitleWindow::setChildWindow(Window* _pChild)
// -----------------------------------------------------------------------------
void OTitleWindow::Resize()
{
- //////////////////////////////////////////////////////////////////////
- // Abmessungen parent window
+ // parent window dimension
Size aOutputSize( GetOutputSize() );
long nOutputWidth = aOutputSize.Width();
long nOutputHeight = aOutputSize.Height();
@@ -174,7 +166,7 @@ void OTitleWindow::ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal_B
Window* pWindows [] = { &m_aSpace1, &m_aSpace2, &m_aTitle};
- for (size_t i=0; i < sizeof(pWindows)/sizeof(pWindows[0]); ++i)
+ for (size_t i=0; i < SAL_N_ELEMENTS(pWindows); ++i)
{
Font aFont = pWindows[i]->GetFont();
aFont.SetWeight(WEIGHT_BOLD);
@@ -186,3 +178,5 @@ void OTitleWindow::ImplInitSettings( sal_Bool bFont, sal_Bool bForeground, sal_B
// .............................................................
} // namespace dbaui
// .............................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppTitleWindow.hxx b/dbaccess/source/ui/app/AppTitleWindow.hxx
index 176d5d5785b9..ab1719977f23 100644
--- a/dbaccess/source/ui/app/AppTitleWindow.hxx
+++ b/dbaccess/source/ui/app/AppTitleWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_TITLE_WINDOW_HXX
#define DBAUI_TITLE_WINDOW_HXX
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
namespace dbaui
{
@@ -83,3 +82,4 @@ namespace dbaui
// .............................................................
#endif // DBAUI_TITLE_WINDOW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppView.cxx b/dbaccess/source/ui/app/AppView.cxx
index bb8e6c937a29..c670c3558737 100644
--- a/dbaccess/source/ui/app/AppView.cxx
+++ b/dbaccess/source/ui/app/AppView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,84 +28,32 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_APPVIEW_HXX
#include "AppView.hxx"
-#endif
-#ifndef _DBU_APP_HRC_
#include "dbu_app.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _SV_TOOLBOX_HXX
#include <vcl/toolbox.hxx>
-#endif
-#ifndef _UTL_CONFIGMGR_HXX_
#include <unotools/configmgr.hxx>
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_DATATRANSFER_CLIPBOARD_XCLIPBOARD_HPP_
#include <com/sun/star/datatransfer/clipboard/XClipboard.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XQUERIESSUPPLIER_HPP_
#include <com/sun/star/sdb/XQueriesSupplier.hpp>
-#endif
-#ifndef INCLUDED_SVTOOLS_SYSLOCALE_HXX
#include <unotools/syslocale.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_APPDETAILVIEW_HXX
#include "AppDetailView.hxx"
-#endif
-#ifndef _DBAUI_TABLETREE_HXX_
#include "tabletree.hxx"
-#endif
-#ifndef DBAUI_APPSWAPWINDOW_HXX
#include "AppSwapWindow.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef DBAUI_APPSWAPWINDOW_HXX
#include "AppSwapWindow.hxx"
-#endif
-#ifndef DBAUI_TITLE_WINDOW_HXX
#include "AppTitleWindow.hxx"
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef DBAUI_ICONTROLLER_HXX
#include "IController.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
#include <unotools/pathoptions.hxx>
-#endif
#include "IApplicationController.hxx"
using namespace ::dbaui;
@@ -152,8 +101,7 @@ OAppBorderWindow::OAppBorderWindow(OApplicationView* _pParent,PreviewMode _ePrev
// -----------------------------------------------------------------------------
OAppBorderWindow::~OAppBorderWindow()
{
- //////////////////////////////////////////////////////////////////////
- // Childs zerstoeren
+ // destroy children
if ( m_pPanel )
{
m_pPanel->Hide();
@@ -178,8 +126,7 @@ void OAppBorderWindow::GetFocus()
// -----------------------------------------------------------------------------
void OAppBorderWindow::Resize()
{
- //////////////////////////////////////////////////////////////////////
- // Abmessungen parent window
+ // parent window dimension
Size aOutputSize( GetOutputSize() );
long nOutputWidth = aOutputSize.Width();
long nOutputHeight = aOutputSize.Height();
@@ -236,10 +183,6 @@ void OAppBorderWindow::ImplInitSettings()
if( true )
SetBackground( rStyleSettings.GetDialogColor() );
-
- /*SetBackground( Wallpaper( Application::GetSettings().GetStyleSettings().GetDialogColor() ) );
- SetFillColor( Application::GetSettings().GetStyleSettings().GetDialogColor() );
- SetTextFillColor( Application::GetSettings().GetStyleSettings().GetDialogColor() );*/
}
// -----------------------------------------------------------------------------
OApplicationView* OAppBorderWindow::getView() const
@@ -364,11 +307,11 @@ long OApplicationView::PreNotify( NotifyEvent& rNEvt )
{
const KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
// give the pane the chance to intercept mnemonic accelerators
- // #i34790# - 2004-09-30 - fs@openoffice.org
+ // #i34790#
if ( getPanel() && getPanel()->interceptKeyInput( *pKeyEvent ) )
return 1L;
// and ditto the detail view
- // #i72799# - 2006-12-20 / frank.schoenheit@sun.com
+ // #i72799#
if ( getDetailView() && getDetailView()->interceptKeyInput( *pKeyEvent ) )
return 1L;
}
@@ -652,8 +595,7 @@ void OApplicationView::ImplInitSettings()
if( true )
SetBackground( rStyleSettings.GetFieldColor() );
- /*SetBackground( Wallpaper( Application::GetSettings().GetStyleSettings().GetDialogColor() ) );
- SetFillColor( Application::GetSettings().GetStyleSettings().GetDialogColor() );
- SetTextFillColor( Application::GetSettings().GetStyleSettings().GetDialogColor() );*/
}
//-----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/AppView.hxx b/dbaccess/source/ui/app/AppView.hxx
index 7de14399f8ed..d4fa76c35849 100644
--- a/dbaccess/source/ui/app/AppView.hxx
+++ b/dbaccess/source/ui/app/AppView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
#ifndef DBAUI_APPVIEW_HXX
#define DBAUI_APPVIEW_HXX
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_
#include <com/sun/star/ucb/XContent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_NAMEDDATABASEOBJECT_HPP_
#include <com/sun/star/sdb/application/NamedDatabaseObject.hpp>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _UNOTOOLS_EVENTLISTENERADAPTER_HXX_
#include <unotools/eventlisteneradapter.hxx>
-#endif
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
-#ifndef DBAUI_APPELEMENTTYPE_HXX
#include "AppElementType.hxx"
-#endif
namespace com{ namespace sun { namespace star { namespace beans { class XPropertySet; } } } }
@@ -330,3 +313,4 @@ namespace dbaui
}
#endif // DBAUI_APPVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/IApplicationController.hxx b/dbaccess/source/ui/app/IApplicationController.hxx
index 2e495a93a77b..5e7123e4d3ed 100644
--- a/dbaccess/source/ui/app/IApplicationController.hxx
+++ b/dbaccess/source/ui/app/IApplicationController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -98,3 +99,5 @@ namespace dbaui
//........................................................................
#endif // DBA30D_IAPPLICATIONCONTROLLER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/app.src b/dbaccess/source/ui/app/app.src
index 529e6ac55009..d47e0cbcdf17 100644
--- a/dbaccess/source/ui/app/app.src
+++ b/dbaccess/source/ui/app/app.src
@@ -296,43 +296,53 @@ String RID_STR_REPORTS_HELP_TEXT_WIZARD
{
Text [ en-US ] = "The wizard will guide you through the steps necessary to create a report." ;
};
+
String RID_STR_FORMS_HELP_TEXT
{
Text [ en-US ] = "Create a form by specifying the record source, controls, and control properties." ;
};
+
String RID_STR_REPORT_HELP_TEXT
{
Text [ de ] ="Erstellen Sie einen Bericht, indem Sie die Datensatzquelle, Steuerelemente und Steuerelementeigenschaften angeben." ;
Text [ en-US ] = "Create a report by specifying the record source, controls, and control properties." ;
};
+
String RID_STR_FORMS_HELP_TEXT_WIZARD
{
Text [ en-US ] = "The wizard will guide you through the steps necessary to create a form." ;
};
+
String RID_STR_QUERIES_HELP_TEXT
{
- Text [ en-US ] = "Create a query by specifying the filters, input tables, field names, and properties for sorting or grouping." ;
+ Text [ en-US ] = "Create a query by specifying the filters, input tables, field names, and properties for sorting or grouping." ;
};
+
String RID_STR_QUERIES_HELP_TEXT_SQL
{
- Text [ en-US ] = "Create a query entering an SQL statement directly." ;
+ Text [ en-US ] = "Create a query entering an SQL statement directly." ;
};
+
String RID_STR_QUERIES_HELP_TEXT_WIZARD
{
Text [ en-US ] = "The wizard will guide you through the steps necessary to create a query." ;
};
+
String RID_STR_TABLES_HELP_TEXT_DESIGN
{
Text [ en-US ] = "Create a table by specifying the field names and properties, as well as the data types." ;
};
+
String RID_STR_TABLES_HELP_TEXT_WIZARD
{
Text [ en-US ] = "Choose from a selection of business and personal table samples, which you customize to create a table." ;
};
+
String RID_STR_VIEWS_HELP_TEXT_DESIGN
{
Text [ en-US ] = "Create a view by specifying the tables and field names you would like to have visible." ;
};
+
String RID_STR_VIEWS_HELP_TEXT_WIZARD
{
Text [ en-US ] = "Opens the view wizard" ;
@@ -342,28 +352,34 @@ String STR_DATABASE
{
Text [ en-US ] = "Database" ;
};
+
String STR_TASKS
{
Text [ en-US ] = "Tasks" ;
};
+
String STR_DESCRIPTION
{
Text [ en-US ] = "Description" ;
};
+
String STR_PREVIEW
{
Text [ en-US ] = "Preview" ;
};
+
String STR_DISABLEPREVIEW
{
Text [ en-US ] = "Disable Preview" ;
};
+
QueryBox APP_SAVEMODIFIED
{
Buttons = WB_YES_NO_CANCEL ;
DefButton = WB_DEF_YES ;
Message [ en-US ] = "The database has been modified.\nDo you want to save the changes?" ;
};
+
QueryBox APP_CLOSEDOCUMENTS
{
Buttons = WB_YES_NO ;
@@ -404,6 +420,7 @@ Menu RID_MENU_APP_PREVIEW
};
};
};
+
String RID_STR_FORM
{
Text [ en-US ] = "Form";
@@ -413,10 +430,12 @@ String RID_STR_REPORT
{
Text [ en-US ] = "Report";
};
+
String STR_FRM_LABEL
{
Text [ en-US ] = "F~orm name" ;
};
+
String STR_RPT_LABEL
{
Text [ en-US ] = "~Report name" ;
@@ -447,10 +466,12 @@ String RID_STR_EMBEDDED_DATABASE
{
Text [ en-US ] = "Embedded database";
};
+
String RID_STR_NO_DIFF_CAT
{
Text [ en-US ] = "You cannot select different categories.";
};
+
String RID_STR_UNSUPPORTED_OBJECT_TYPE
{
Text [ en-US ] = "Unsupported object type found ($type$).";
diff --git a/dbaccess/source/ui/app/makefile.mk b/dbaccess/source/ui/app/makefile.mk
deleted file mode 100644
index e26927d99628..000000000000
--- a/dbaccess/source/ui/app/makefile.mk
+++ /dev/null
@@ -1,70 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=app
-
-# BMP_IN=$(PRJ)$/res
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-# IMGLST_SRS=$(SRS)$/$(TARGET).srs
-# --- Files --------------------------------------------------------
-
-EXCEPTIONSFILES=\
- $(SLO)$/AppDetailView.obj \
- $(SLO)$/AppController.obj \
- $(SLO)$/AppControllerDnD.obj \
- $(SLO)$/AppControllerGen.obj \
- $(SLO)$/AppDetailPageHelper.obj \
- $(SLO)$/AppSwapWindow.obj \
- $(SLO)$/AppTitleWindow.obj \
- $(SLO)$/AppView.obj \
- $(SLO)$/subcomponentmanager.obj \
- $(SLO)$/closeveto.obj
-
-
-SLOFILES =\
- $(SLO)$/AppIconControl.obj \
- $(EXCEPTIONSFILES)
-
-SRS1NAME=$(TARGET)
-SRC1FILES = app.src
-
-
-# --- Targets -------------------------------------------------------
-
-
-.INCLUDE : target.mk
-
-$(SRS)$/$(TARGET).srs: $(SOLARINCDIR)$/svx$/globlmn.hrc
-
-
diff --git a/dbaccess/source/ui/app/subcomponentmanager.cxx b/dbaccess/source/ui/app/subcomponentmanager.cxx
index 7d3027706306..dc25272395af 100644
--- a/dbaccess/source/ui/app/subcomponentmanager.cxx
+++ b/dbaccess/source/ui/app/subcomponentmanager.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -42,9 +43,8 @@
#include <tools/diagnose_ex.h>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
-#include <hash_map>
#include <algorithm>
#include <functional>
@@ -179,7 +179,7 @@ namespace dbaui
//..............................................................................................................
struct SelectSubComponent : public ::std::unary_function< SubComponentDescriptor, Reference< XComponent > >
{
- Reference< XComponent > operator()( const SubComponentDescriptor _desc ) const
+ Reference< XComponent > operator()( const SubComponentDescriptor &_desc ) const
{
if ( _desc.xModel.is() )
return _desc.xModel.get();
@@ -463,7 +463,7 @@ namespace dbaui
//------------------------------------------------------------------------------------------------------------------
sal_Bool SubComponentManager::closeSubComponents()
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( m_pData->getMutex() );
try
@@ -610,3 +610,5 @@ namespace dbaui
//......................................................................................................................
} // namespace dbaui
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/app/subcomponentmanager.hxx b/dbaccess/source/ui/app/subcomponentmanager.hxx
index 72b0a548e533..c66732528471 100644
--- a/dbaccess/source/ui/app/subcomponentmanager.hxx
+++ b/dbaccess/source/ui/app/subcomponentmanager.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -134,3 +135,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_SUBCOMPONENTMANAGER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/AsyncronousLink.cxx b/dbaccess/source/ui/browser/AsyncronousLink.cxx
index 99c4858aaf73..f4072f5e6d1f 100644
--- a/dbaccess/source/ui/browser/AsyncronousLink.cxx
+++ b/dbaccess/source/ui/browser/AsyncronousLink.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_ASYNCRONOUSLINK_HXX
#include "AsyncronousLink.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
//==================================================================
//= OAsyncronousLink
@@ -110,3 +105,5 @@ IMPL_LINK(OAsyncronousLink, OnAsyncCall, void*, _pArg)
return 0L;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/bcommon.src b/dbaccess/source/ui/browser/bcommon.src
index 8c79179eda20..d5b8401b4e8c 100644
--- a/dbaccess/source/ui/browser/bcommon.src
+++ b/dbaccess/source/ui/browser/bcommon.src
@@ -32,4 +32,3 @@ String RID_STR_TBL_TITLE
{
Text [ en-US ] = "Table #" ;
};
-
diff --git a/dbaccess/source/ui/browser/brwctrlr.cxx b/dbaccess/source/ui/browser/brwctrlr.cxx
index d804a9c9f26b..b6a42cfc9cda 100644
--- a/dbaccess/source/ui/browser/brwctrlr.cxx
+++ b/dbaccess/source/ui/browser/brwctrlr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -94,6 +95,7 @@
#include <svx/svxdlg.hxx>
#include <tools/color.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <vcl/msgbox.hxx>
#include <vcl/waitobj.hxx>
@@ -132,7 +134,7 @@ using namespace ::svt;
DBG_UNHANDLED_EXCEPTION(); \
} \
-#define DO_SAFE( action, message ) try { action; } catch(Exception&) { DBG_ERROR(message); } ;
+#define DO_SAFE( action, message ) try { action; } catch(Exception&) { OSL_FAIL(message); } ;
//..................................................................
namespace dbaui
@@ -281,7 +283,7 @@ SbaXDataBrowserController::FormControllerImpl::~FormControllerImpl()
//------------------------------------------------------------------
Reference< runtime::XFormOperations > SAL_CALL SbaXDataBrowserController::FormControllerImpl::getFormOperations() throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::getFormOperations: not supported!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::getFormOperations: not supported!" );
return NULL;
}
@@ -313,27 +315,27 @@ void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addChildController(
//------------------------------------------------------------------
Reference< runtime::XFormControllerContext > SAL_CALL SbaXDataBrowserController::FormControllerImpl::getContext() throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::getContext: no support!!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::getContext: no support!!" );
return NULL;
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setContext( const Reference< runtime::XFormControllerContext >& /*_context*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::setContext: no support!!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::setContext: no support!!" );
}
//------------------------------------------------------------------
Reference< XInteractionHandler > SAL_CALL SbaXDataBrowserController::FormControllerImpl::getInteractionHandler() throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::getInteractionHandler: no support!!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::getInteractionHandler: no support!!" );
return NULL;
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setInteractionHandler( const Reference< XInteractionHandler >& /*_interactionHandler*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::setInteractionHandler: no support!!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::setInteractionHandler: no support!!" );
}
//------------------------------------------------------------------
@@ -352,19 +354,19 @@ void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setParent( const Re
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::dispose( ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::dispose: no, you do *not* want to do this!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::dispose: no, you do *not* want to do this!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addEventListener( const Reference< XEventListener >& /*xListener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::addEventListener: no support!!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::addEventListener: no support!!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::removeEventListener( const Reference< XEventListener >& /*aListener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::removeEventListener: no support!!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::removeEventListener: no support!!" );
}
//------------------------------------------------------------------
@@ -403,73 +405,73 @@ Reference< XEnumeration > SAL_CALL SbaXDataBrowserController::FormControllerImpl
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addModifyListener( const Reference< XModifyListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::addModifyListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::addModifyListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::removeModifyListener( const Reference< XModifyListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::removeModifyListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::removeModifyListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addConfirmDeleteListener( const Reference< XConfirmDeleteListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::addConfirmDeleteListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::addConfirmDeleteListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::removeConfirmDeleteListener( const Reference< XConfirmDeleteListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::removeConfirmDeleteListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::removeConfirmDeleteListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addSQLErrorListener( const Reference< XSQLErrorListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::addSQLErrorListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::addSQLErrorListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::removeSQLErrorListener( const Reference< XSQLErrorListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::removeSQLErrorListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::removeSQLErrorListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addRowSetApproveListener( const Reference< XRowSetApproveListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::addRowSetApproveListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::addRowSetApproveListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::removeRowSetApproveListener( const Reference< XRowSetApproveListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::removeRowSetApproveListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::removeRowSetApproveListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addDatabaseParameterListener( const Reference< XDatabaseParameterListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::addDatabaseParameterListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::addDatabaseParameterListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::removeDatabaseParameterListener( const Reference< XDatabaseParameterListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::removeDatabaseParameterListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::removeDatabaseParameterListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::addParameterListener( const Reference< XDatabaseParameterListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::addParameterListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::addParameterListener: no support!" );
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::removeParameterListener( const Reference< XDatabaseParameterListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SbaXDataBrowserController::FormControllerImpl::removeParameterListener: no support!" );
+ OSL_FAIL( "SbaXDataBrowserController::FormControllerImpl::removeParameterListener: no support!" );
}
//------------------------------------------------------------------
@@ -502,7 +504,7 @@ Sequence< ::rtl::OUString > SAL_CALL SbaXDataBrowserController::FormControllerIm
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setModel(const Reference< ::com::sun::star::awt::XTabControllerModel > & /*Model*/) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::setModel : invalid call, can't change my model !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::setModel : invalid call, can't change my model !");
}
//------------------------------------------------------------------
@@ -514,7 +516,7 @@ Reference< ::com::sun::star::awt::XTabControllerModel > SAL_CALL SbaXDataBrowse
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::setContainer(const Reference< ::com::sun::star::awt::XControlContainer > & /*_Container*/) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::setContainer : invalid call, can't change my container !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::setContainer : invalid call, can't change my container !");
}
//------------------------------------------------------------------
@@ -539,13 +541,13 @@ Sequence< Reference< ::com::sun::star::awt::XControl > > SAL_CALL SbaXDataBrowse
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::autoTabOrder(void) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::autoTabOrder : nothing to do (always have only one control) !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::autoTabOrder : nothing to do (always have only one control) !");
}
//------------------------------------------------------------------
void SAL_CALL SbaXDataBrowserController::FormControllerImpl::activateTabOrder(void) throw( RuntimeException )
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::FormControllerImpl::activateTabOrder : nothing to do (always have only one control) !");
+ OSL_FAIL("SbaXDataBrowserController::FormControllerImpl::activateTabOrder : nothing to do (always have only one control) !");
}
//------------------------------------------------------------------
@@ -791,7 +793,7 @@ void SbaXDataBrowserController::initFormatter()
{
// create a new formatter
m_xFormatter = Reference< ::com::sun::star::util::XNumberFormatter > (
- getORB()->createInstance(::rtl::OUString::createFromAscii("com.sun.star.util.NumberFormatter")), UNO_QUERY);
+ getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.NumberFormatter"))), UNO_QUERY);
if (m_xFormatter.is())
m_xFormatter->attachNumberFormatsSupplier(xSupplier);
}
@@ -878,7 +880,7 @@ sal_Bool SbaXDataBrowserController::Construct(Window* pParent)
}
catch(Exception&)
{
- DBG_ERROR("SbaXDataBrowserController::Construct : the construction of UnoDataBrowserView failed !");
+ OSL_FAIL("SbaXDataBrowserController::Construct : the construction of UnoDataBrowserView failed !");
}
if (!bSuccess)
@@ -902,7 +904,7 @@ sal_Bool SbaXDataBrowserController::Construct(Window* pParent)
// set the callbacks for the grid control
SbaGridControl* pVclGrid = getBrowserView()->getVclControl();
- DBG_ASSERT(pVclGrid, "SbaXDataBrowserController::Construct : have no VCL control !");
+ OSL_ENSURE(pVclGrid, "SbaXDataBrowserController::Construct : have no VCL control !");
pVclGrid->SetMasterListener(this);
// --------------------------
@@ -963,14 +965,14 @@ void SbaXDataBrowserController::RemoveColumnListener(const Reference< XPropertyS
Reference< XRowSet > SbaXDataBrowserController::CreateForm()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::CreateForm" );
- return Reference< XRowSet > (getORB()->createInstance(::rtl::OUString::createFromAscii("com.sun.star.form.component.Form")), UNO_QUERY);
+ return Reference< XRowSet > (getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.component.Form"))), UNO_QUERY);
}
//------------------------------------------------------------------------------
Reference< ::com::sun::star::form::XFormComponent > SbaXDataBrowserController::CreateGridModel()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::CreateGridModel" );
- return Reference< ::com::sun::star::form::XFormComponent > (getORB()->createInstance(::rtl::OUString::createFromAscii("com.sun.star.form.component.GridControl")), UNO_QUERY);
+ return Reference< ::com::sun::star::form::XFormComponent > (getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.component.GridControl"))), UNO_QUERY);
}
// -------------------------------------------------------------------------
@@ -1095,7 +1097,7 @@ void SAL_CALL SbaXDataBrowserController::focusLost(const FocusEvent& e) throw( R
if (xCommitable.is())
xCommitable->commit();
else
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::focusLost : why is my control not commitable ?");
+ OSL_FAIL("SbaXDataBrowserController::focusLost : why is my control not commitable ?");
}
// -------------------------------------------------------------------------
@@ -1213,7 +1215,7 @@ void SbaXDataBrowserController::propertyChange(const PropertyChangeEvent& evt) t
if (!xSource.is())
return;
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// the IsModified changed to sal_False ?
if ( (evt.PropertyName.equals(PROPERTY_ISMODIFIED))
&& (::comphelper::getBOOL(evt.NewValue) == sal_False)
@@ -1269,7 +1271,7 @@ void SbaXDataBrowserController::modified(const ::com::sun::star::lang::EventObje
void SbaXDataBrowserController::elementInserted(const ::com::sun::star::container::ContainerEvent& evt) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::elementInserted" );
- DBG_ASSERT(Reference< XInterface >(evt.Source, UNO_QUERY).get() == Reference< XInterface >(getControlModel(), UNO_QUERY).get(),
+ OSL_ENSURE(Reference< XInterface >(evt.Source, UNO_QUERY).get() == Reference< XInterface >(getControlModel(), UNO_QUERY).get(),
"SbaXDataBrowserController::elementInserted: where did this come from (not from the grid model)?!");
Reference< XPropertySet > xNewColumn(evt.Element,UNO_QUERY);
if ( xNewColumn.is() )
@@ -1280,7 +1282,7 @@ void SbaXDataBrowserController::elementInserted(const ::com::sun::star::containe
void SbaXDataBrowserController::elementRemoved(const ::com::sun::star::container::ContainerEvent& evt) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::elementRemoved" );
- DBG_ASSERT(Reference< XInterface >(evt.Source, UNO_QUERY).get() == Reference< XInterface >(getControlModel(), UNO_QUERY).get(),
+ OSL_ENSURE(Reference< XInterface >(evt.Source, UNO_QUERY).get() == Reference< XInterface >(getControlModel(), UNO_QUERY).get(),
"SbaXDataBrowserController::elementRemoved: where did this come from (not from the grid model)?!");
Reference< XPropertySet > xOldColumn(evt.Element,UNO_QUERY);
if ( xOldColumn.is() )
@@ -1291,7 +1293,7 @@ void SbaXDataBrowserController::elementRemoved(const ::com::sun::star::container
void SbaXDataBrowserController::elementReplaced(const ::com::sun::star::container::ContainerEvent& evt) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::elementReplaced" );
- DBG_ASSERT(Reference< XInterface >(evt.Source, UNO_QUERY).get() == Reference< XInterface >(getControlModel(), UNO_QUERY).get(),
+ OSL_ENSURE(Reference< XInterface >(evt.Source, UNO_QUERY).get() == Reference< XInterface >(getControlModel(), UNO_QUERY).get(),
"SbaXDataBrowserController::elementReplaced: where did this come from (not from the grid model)?!");
Reference< XPropertySet > xOldColumn(evt.ReplacedElement,UNO_QUERY);
if ( xOldColumn.is() )
@@ -1306,7 +1308,7 @@ void SbaXDataBrowserController::elementReplaced(const ::com::sun::star::containe
sal_Bool SbaXDataBrowserController::suspend(sal_Bool /*bSuspend*/) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::suspend" );
- DBG_ASSERT(m_nPendingLoadFinished == 0, "SbaXDataBrowserController::suspend : there shouldn't be a pending load !");
+ OSL_ENSURE(m_nPendingLoadFinished == 0, "SbaXDataBrowserController::suspend : there shouldn't be a pending load !");
m_aAsyncGetCellFocus.CancelCall();
m_aAsyncDisplayError.CancelCall();
@@ -1434,7 +1436,7 @@ IMPL_LINK( SbaXDataBrowserController, OnAsyncDisplayError, void*, /* _pNotIntere
//------------------------------------------------------------------------------
void SbaXDataBrowserController::errorOccured(const ::com::sun::star::sdb::SQLErrorEvent& aEvent) throw( RuntimeException )
{
- RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::errorOccured" );
+ RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::errorOccurred" );
::osl::MutexGuard aGuard( getMutex() );
SQLExceptionInfo aInfo( aEvent.Reason );
@@ -1443,7 +1445,7 @@ void SbaXDataBrowserController::errorOccured(const ::com::sun::star::sdb::SQLErr
if ( m_nFormActionNestingLevel )
{
- OSL_ENSURE( !m_aCurrentError.isValid(), "SbaXDataBrowserController::errorOccured: can handle one error per transaction only!" );
+ OSL_ENSURE( !m_aCurrentError.isValid(), "SbaXDataBrowserController::errorOccurred: can handle one error per transaction only!" );
m_aCurrentError = aInfo;
}
else
@@ -1460,19 +1462,12 @@ sal_Bool SbaXDataBrowserController::approveParameter(const ::com::sun::star::for
if (aEvent.Source != getRowSet())
{
// not my data source -> allow anything
- DBG_ERROR("SbaXDataBrowserController::approveParameter : invalid event source !");
+ OSL_FAIL("SbaXDataBrowserController::approveParameter : invalid event source !");
return sal_True;
}
Reference< ::com::sun::star::container::XIndexAccess > xParameters = aEvent.Parameters;
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
- // this may be executed in a non-main thread and we want to use vcl ...
- Window* pParent = Application::GetDefDialogParent();
- // don't use the content as parent if it isn't visible
- // (and don't use NULL as parent : this may be displayed in the beamer and really shouldn't be task-local)
- // 69297 - FS - 25.10.99
- if (getBrowserView() && getBrowserView()->IsVisible())
- pParent = getBrowserView();
+ SolarMutexGuard aSolarGuard;
// default handling: instantiate an interaction handler and let it handle the parameter request
try
@@ -1505,7 +1500,7 @@ sal_Bool SbaXDataBrowserController::approveParameter(const ::com::sun::star::for
Sequence< PropertyValue > aFinalValues = pParamValues->getValues();
if (aFinalValues.getLength() != aRequest.Parameters->getCount())
{
- DBG_ERROR("SbaXDataBrowserController::approveParameter: the InteractionHandler returned nonsense!");
+ OSL_FAIL("SbaXDataBrowserController::approveParameter: the InteractionHandler returned nonsense!");
setLoadingCancelled();
return sal_False;
}
@@ -1514,18 +1509,18 @@ sal_Bool SbaXDataBrowserController::approveParameter(const ::com::sun::star::for
{
Reference< XPropertySet > xParam;
::cppu::extractInterface(xParam, aRequest.Parameters->getByIndex(i));
- DBG_ASSERT(xParam.is(), "SbaXDataBrowserController::approveParameter: one of the parameters is no property set!");
+ OSL_ENSURE(xParam.is(), "SbaXDataBrowserController::approveParameter: one of the parameters is no property set!");
if (xParam.is())
{
#ifdef DBG_UTIL
::rtl::OUString sName;
xParam->getPropertyValue(PROPERTY_NAME) >>= sName;
- DBG_ASSERT(sName.equals(pFinalValues->Name), "SbaXDataBrowserController::approveParameter: suspicious value names!");
+ OSL_ENSURE(sName.equals(pFinalValues->Name), "SbaXDataBrowserController::approveParameter: suspicious value names!");
#endif
try { xParam->setPropertyValue(PROPERTY_VALUE, pFinalValues->Value); }
catch(Exception&)
{
- DBG_ERROR("SbaXDataBrowserController::approveParameter: setting one of the properties failed!");
+ OSL_FAIL("SbaXDataBrowserController::approveParameter: setting one of the properties failed!");
}
}
}
@@ -1550,7 +1545,7 @@ sal_Bool SbaXDataBrowserController::approveReset(const ::com::sun::star::lang::E
void SbaXDataBrowserController::resetted(const ::com::sun::star::lang::EventObject& rEvent) throw( RuntimeException )
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::resetted" );
- DBG_ASSERT(rEvent.Source == getControlModel(), "SbaXDataBrowserController::resetted : where did this come from ?");
+ OSL_ENSURE(rEvent.Source == getControlModel(), "SbaXDataBrowserController::resetted : where did this come from ?");
(void)rEvent;
setCurrentModified( sal_False );
}
@@ -1610,7 +1605,7 @@ FeatureState SbaXDataBrowserController::GetState(sal_uInt16 nId) const
try
{
Reference< XPropertySet > xRowSetProps( getRowSet(), UNO_QUERY_THROW );
- OSL_VERIFY( xRowSetProps->getPropertyValue( ::rtl::OUString::createFromAscii( "AllowInserts" ) ) >>= bAllowInsertions );
+ OSL_VERIFY( xRowSetProps->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowInserts")) ) >>= bAllowInsertions );
}
catch( const Exception& )
{
@@ -1629,7 +1624,7 @@ FeatureState SbaXDataBrowserController::GetState(sal_uInt16 nId) const
try
{
Reference< XPropertySet > xRowSetProps( getRowSet(), UNO_QUERY_THROW );
- OSL_VERIFY( xRowSetProps->getPropertyValue( ::rtl::OUString::createFromAscii( "AllowDeletes" ) ) >>= bAllowDeletions );
+ OSL_VERIFY( xRowSetProps->getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowDeletes")) ) >>= bAllowDeletions );
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_ROWCOUNT ) >>= nRowCount );
OSL_VERIFY( xRowSetProps->getPropertyValue( PROPERTY_ISNEW ) >>= bInsertionRow );
}
@@ -1746,9 +1741,9 @@ FeatureState SbaXDataBrowserController::GetState(sal_uInt16 nId) const
break; // no datasource -> no edit mode
sal_Int32 nDataSourcePrivileges = ::comphelper::getINT32(xDataSourceSet->getPropertyValue(PROPERTY_PRIVILEGES));
- sal_Bool bInsertAllowedAndPossible = ((nDataSourcePrivileges & ::com::sun::star::sdbcx::Privilege::INSERT) != 0) && ::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString::createFromAscii("AllowInserts")));
- sal_Bool bUpdateAllowedAndPossible = ((nDataSourcePrivileges & ::com::sun::star::sdbcx::Privilege::UPDATE) != 0) && ::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString::createFromAscii("AllowUpdates")));
- sal_Bool bDeleteAllowedAndPossible = ((nDataSourcePrivileges & ::com::sun::star::sdbcx::Privilege::DELETE) != 0) && ::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString::createFromAscii("AllowDeletes")));
+ sal_Bool bInsertAllowedAndPossible = ((nDataSourcePrivileges & ::com::sun::star::sdbcx::Privilege::INSERT) != 0) && ::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowInserts"))));
+ sal_Bool bUpdateAllowedAndPossible = ((nDataSourcePrivileges & ::com::sun::star::sdbcx::Privilege::UPDATE) != 0) && ::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowUpdates"))));
+ sal_Bool bDeleteAllowedAndPossible = ((nDataSourcePrivileges & ::com::sun::star::sdbcx::Privilege::DELETE) != 0) && ::comphelper::getBOOL(xDataSourceSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AllowDeletes"))));
if (!bInsertAllowedAndPossible && !bUpdateAllowedAndPossible && !bDeleteAllowedAndPossible)
break; // no insert/update/delete -> no edit mode
@@ -1798,7 +1793,7 @@ void SbaXDataBrowserController::applyParserOrder(const ::rtl::OUString& _rOldOrd
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
if (!m_xLoadable.is())
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::applyParserOrder: invalid row set!");
+ OSL_FAIL("SbaXDataBrowserController::applyParserOrder: invalid row set!");
return;
}
@@ -1816,7 +1811,6 @@ void SbaXDataBrowserController::applyParserOrder(const ::rtl::OUString& _rOldOrd
if (!bSuccess)
{
xFormSet->setPropertyValue(PROPERTY_ORDER, makeAny(_rOldOrder));
- //DO_SAFE( _xParser->setOrder(_rOldOrder), "SbaXDataBrowserController::applyParserOrder: could not restore the old order of my parser !" );
try
{
@@ -1841,7 +1835,7 @@ void SbaXDataBrowserController::applyParserFilter(const ::rtl::OUString& _rOldFi
Reference< XPropertySet > xFormSet(getRowSet(), UNO_QUERY);
if (!m_xLoadable.is())
{
- OSL_ENSURE(sal_False, "SbaXDataBrowserController::applyParserFilter: invalid row set!");
+ OSL_FAIL("SbaXDataBrowserController::applyParserFilter: invalid row set!");
return;
}
@@ -1999,11 +1993,11 @@ void SbaXDataBrowserController::ExecuteSearch()
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::ExecuteSearch" );
// calculate the control source of the active field
Reference< ::com::sun::star::form::XGrid > xGrid(getBrowserView()->getGridControl(), UNO_QUERY);
- DBG_ASSERT(xGrid.is(), "SbaXDataBrowserController::ExecuteSearch : the control should have an ::com::sun::star::form::XGrid interface !");
+ OSL_ENSURE(xGrid.is(), "SbaXDataBrowserController::ExecuteSearch : the control should have an ::com::sun::star::form::XGrid interface !");
Reference< ::com::sun::star::form::XGridPeer > xGridPeer(getBrowserView()->getGridControl()->getPeer(), UNO_QUERY);
Reference< ::com::sun::star::container::XIndexContainer > xColumns = xGridPeer->getColumns();
- DBG_ASSERT(xGridPeer.is() && xColumns.is(), "SbaXDataBrowserController::ExecuteSearch : invalid peer !");
+ OSL_ENSURE(xGridPeer.is() && xColumns.is(), "SbaXDataBrowserController::ExecuteSearch : invalid peer !");
sal_Int16 nViewCol = xGrid->getCurrentColumnPosition();
sal_Int16 nModelCol = getBrowserView()->View2ModelPos(nViewCol);
@@ -2017,14 +2011,14 @@ void SbaXDataBrowserController::ExecuteSearch()
Reference< XInterface > xCurControl(xColControls->getByIndex(nViewCol),UNO_QUERY);
::rtl::OUString aInitialText;
if (IsSearchableControl(xCurControl, &aInitialText))
- sInitialText = (const sal_Unicode*)aInitialText;
+ sInitialText = aInitialText;
// prohibit the synchronization of the grid's display with the cursor's position
Reference< XPropertySet > xModelSet(getControlModel(), UNO_QUERY);
- DBG_ASSERT(xModelSet.is(), "SbaXDataBrowserController::ExecuteSearch : no model set ?!");
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"), ::comphelper::makeBoolAny(sal_Bool(sal_False)));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("AlwaysShowCursor"), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("CursorColor"), makeAny(sal_Int32(COL_LIGHTRED)));
+ OSL_ENSURE(xModelSet.is(), "SbaXDataBrowserController::ExecuteSearch : no model set ?!");
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")), ::comphelper::makeBoolAny(sal_Bool(sal_False)));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AlwaysShowCursor")), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CursorColor")), makeAny(sal_Int32(COL_LIGHTRED)));
Reference< ::com::sun::star::util::XNumberFormatsSupplier > xNFS(::dbtools::getNumberFormats(::dbtools::getConnection(m_xRowSet), sal_True,getORB()));
@@ -2036,7 +2030,7 @@ void SbaXDataBrowserController::ExecuteSearch()
aContextNames.push_back( String::CreateFromAscii("Standard") );
pDialog = pFact->CreateFmSearchDialog(getBrowserView(), sInitialText, aContextNames, 0, LINK(this, SbaXDataBrowserController, OnSearchContextRequest));
}
- DBG_ASSERT( pDialog, "SbaXDataBrowserController::ExecuteSearch: could not get the search dialog!" );
+ OSL_ENSURE( pDialog, "SbaXDataBrowserController::ExecuteSearch: could not get the search dialog!" );
if ( pDialog )
{
pDialog->SetActiveField( sActiveField );
@@ -2047,9 +2041,9 @@ void SbaXDataBrowserController::ExecuteSearch()
}
// restore the grid's normal operating state
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("AlwaysShowCursor"), ::comphelper::makeBoolAny(sal_Bool(sal_False)));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("CursorColor"), Any());
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AlwaysShowCursor")), ::comphelper::makeBoolAny(sal_Bool(sal_False)));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CursorColor")), Any());
}
//------------------------------------------------------------------------------
@@ -2077,7 +2071,7 @@ void SbaXDataBrowserController::Execute(sal_uInt16 nId, const Sequence< Property
}
catch(Exception&)
{
- OSL_ENSURE(0,"Exception caught!");
+ OSL_FAIL("Exception caught!");
}
break;
case SID_FM_DELETEROWS:
@@ -2149,7 +2143,6 @@ void SbaXDataBrowserController::Execute(sal_uInt16 nId, const Sequence< Property
// should be intercepted by GetState. Normally.
// Unfortunately ID_BROWSER_PASTE is a 'fast call' slot, which means it may be executed without checking if it is
// enabled. This would be really deadly herein if the current cell has no controller ...
- // (FS - 13.04.99 - #64694#)
return;
Edit& rEdit = (Edit&)xCurrentController->GetWindow();
@@ -2411,7 +2404,7 @@ sal_Bool SbaXDataBrowserController::SaveModified(sal_Bool bAskFor)
}
catch(Exception&)
{
- DBG_ERROR("SbaXDataBrowserController::SaveModified : could not save the current record !");
+ OSL_FAIL("SbaXDataBrowserController::SaveModified : could not save the current record !");
bResult = sal_False;
}
@@ -2498,7 +2491,7 @@ void SbaXDataBrowserController::CellDeactivated()
//------------------------------------------------------------------------------
IMPL_LINK( SbaXDataBrowserController, OnClipboardChanged, void*, EMPTYARG )
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
return OnInvalidateClipboard( NULL );
}
@@ -2554,9 +2547,9 @@ IMPL_LINK(SbaXDataBrowserController, OnSearchContextRequest, FmSearchContext*, p
// check all grid columns for their control source
Reference< ::com::sun::star::container::XIndexAccess > xModelColumns(getFormComponent(), UNO_QUERY);
- DBG_ASSERT(xModelColumns.is(), "SbaXDataBrowserController::OnSearchContextRequest : there is a grid control without columns !");
+ OSL_ENSURE(xModelColumns.is(), "SbaXDataBrowserController::OnSearchContextRequest : there is a grid control without columns !");
// the case 'no columns' should be indicated with an empty container, I think ...
- DBG_ASSERT(xModelColumns->getCount() >= xPeerContainer->getCount(), "SbaXDataBrowserController::OnSearchContextRequest : impossible : have more view than model columns !");
+ OSL_ENSURE(xModelColumns->getCount() >= xPeerContainer->getCount(), "SbaXDataBrowserController::OnSearchContextRequest : impossible : have more view than model columns !");
String sFieldList;
for (sal_Int32 nViewPos=0; nViewPos<xPeerContainer->getCount(); ++nViewPos)
@@ -2565,15 +2558,15 @@ IMPL_LINK(SbaXDataBrowserController, OnSearchContextRequest, FmSearchContext*, p
if (!xCurrentColumn.is())
continue;
- // can we use this column control fo searching ?
+ // can we use this column control for searching ?
if (!IsSearchableControl(xCurrentColumn))
continue;
sal_uInt16 nModelPos = getBrowserView()->View2ModelPos((sal_uInt16)nViewPos);
Reference< XPropertySet > xCurrentColModel(xModelColumns->getByIndex(nModelPos),UNO_QUERY);
- ::rtl::OUString aName = ::comphelper::getString(xCurrentColModel->getPropertyValue(PROPERTY_CONTROLSOURCE));
+ String aName = ::comphelper::getString(xCurrentColModel->getPropertyValue(PROPERTY_CONTROLSOURCE));
- sFieldList += (const sal_Unicode*)aName;
+ sFieldList += aName;
sFieldList += ';';
pContext->arrFields.push_back(xCurrentColumn);
@@ -2585,7 +2578,7 @@ IMPL_LINK(SbaXDataBrowserController, OnSearchContextRequest, FmSearchContext*, p
// if the cursor is in a mode other than STANDARD -> reset
Reference< XPropertySet > xCursorSet(pContext->xCursor, UNO_QUERY);
- DBG_ASSERT(xCursorSet.is() && !::comphelper::getBOOL(xCursorSet->getPropertyValue(PROPERTY_ISMODIFIED)),
+ OSL_ENSURE(xCursorSet.is() && !::comphelper::getBOOL(xCursorSet->getPropertyValue(PROPERTY_ISMODIFIED)),
"SbaXDataBrowserController::OnSearchContextRequest : please do not call for cursors with modified rows !");
if (xCursorSet.is() && ::comphelper::getBOOL(xCursorSet->getPropertyValue(PROPERTY_ISNEW)))
{
@@ -2599,17 +2592,17 @@ IMPL_LINK(SbaXDataBrowserController, OnSearchContextRequest, FmSearchContext*, p
IMPL_LINK(SbaXDataBrowserController, OnFoundData, FmFoundRecordInformation*, pInfo)
{
Reference< ::com::sun::star::sdbcx::XRowLocate > xCursor(getRowSet(), UNO_QUERY);
- DBG_ASSERT(xCursor.is(), "SbaXDataBrowserController::OnFoundData : shit happens. sometimes. but this is simply impossible !");
+ OSL_ENSURE(xCursor.is(), "SbaXDataBrowserController::OnFoundData : shit happens. sometimes. but this is simply impossible !");
// move the cursor
xCursor->moveToBookmark(pInfo->aPosition);
// let the grid snyc it's display with the cursor
Reference< XPropertySet > xModelSet(getControlModel(), UNO_QUERY);
- DBG_ASSERT(xModelSet.is(), "SbaXDataBrowserController::OnFoundData : no model set ?!");
- Any aOld = xModelSet->getPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"), aOld);
+ OSL_ENSURE(xModelSet.is(), "SbaXDataBrowserController::OnFoundData : no model set ?!");
+ Any aOld = xModelSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")), aOld);
// and move to the field
Reference< ::com::sun::star::container::XIndexAccess > aColumnControls(getBrowserView()->getGridControl()->getPeer(), UNO_QUERY);
@@ -2640,7 +2633,7 @@ IMPL_LINK(SbaXDataBrowserController, OnCanceledNotFound, FmFoundRecordInformatio
try
{
- DBG_ASSERT(xCursor.is(), "SbaXDataBrowserController::OnCanceledNotFound : shit happens. sometimes. but this is simply impossible !");
+ OSL_ENSURE(xCursor.is(), "SbaXDataBrowserController::OnCanceledNotFound : shit happens. sometimes. but this is simply impossible !");
// move the cursor
xCursor->moveToBookmark(pInfo->aPosition);
}
@@ -2651,12 +2644,12 @@ IMPL_LINK(SbaXDataBrowserController, OnCanceledNotFound, FmFoundRecordInformatio
try
{
- // let the grid snyc it's display with the cursor
+ // let the grid snyc its display with the cursor
Reference< XPropertySet > xModelSet(getControlModel(), UNO_QUERY);
- DBG_ASSERT(xModelSet.is(), "SbaXDataBrowserController::OnCanceledNotFound : no model set ?!");
- Any aOld = xModelSet->getPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
- xModelSet->setPropertyValue(::rtl::OUString::createFromAscii("DisplayIsSynchron"), aOld);
+ OSL_ENSURE(xModelSet.is(), "SbaXDataBrowserController::OnCanceledNotFound : no model set ?!");
+ Any aOld = xModelSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")), ::comphelper::makeBoolAny(sal_Bool(sal_True)));
+ xModelSet->setPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DisplayIsSynchron")), aOld);
}
catch( const Exception& )
{
@@ -2769,7 +2762,7 @@ void SbaXDataBrowserController::unloaded(const EventObject& /*aEvent*/) throw( R
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaui", "Ocke.Janssen@sun.com", "SbaXDataBrowserController::unloaded" );
m_xParser.clear();
InvalidateAll();
- // do this asynchron, there are other listeners reacting on this message ...
+ // do this asynchronously, there are other listeners reacting on this message ...
// (it's a little hack : the grid columns are listening to this event, too, and their bound field may
// change as a reaction on that event. as we have no chance to be notified of this change (which is
// the one we're interested in) we give them time to do what they want to before invalidating our
@@ -2807,7 +2800,7 @@ void SbaXDataBrowserController::enterFormAction()
//------------------------------------------------------------------------------
void SbaXDataBrowserController::leaveFormAction()
{
- DBG_ASSERT( m_nFormActionNestingLevel > 0, "SbaXDataBrowserController::leaveFormAction : invalid call !" );
+ OSL_ENSURE( m_nFormActionNestingLevel > 0, "SbaXDataBrowserController::leaveFormAction : invalid call !" );
if ( --m_nFormActionNestingLevel > 0 )
return;
@@ -2843,7 +2836,7 @@ sal_Bool SbaXDataBrowserController::isValidCursor() const
{
bIsValid = m_xParser.is();
}
- } // if ( !bIsValid )
+ }
return bIsValid;
}
@@ -2932,7 +2925,7 @@ void LoadFormHelper::implDispose()
void SAL_CALL LoadFormHelper::loaded(const ::com::sun::star::lang::EventObject& /*aEvent*/) throw( RuntimeException )
{
::osl::MutexGuard aGuard(m_aAccessSafety);
- DBG_ASSERT(m_eState == STARTED || m_eState == DISPOSED, "LoadFormHelper::loaded : wrong call !");
+ OSL_ENSURE(m_eState == STARTED || m_eState == DISPOSED, "LoadFormHelper::loaded : wrong call !");
if (m_eState == STARTED)
m_eState = LOADED;
}
@@ -2941,7 +2934,7 @@ void SAL_CALL LoadFormHelper::loaded(const ::com::sun::star::lang::EventObject&
void SAL_CALL LoadFormHelper::unloaded(const ::com::sun::star::lang::EventObject& /*aEvent*/) throw( RuntimeException )
{
::osl::MutexGuard aGuard(m_aAccessSafety);
- DBG_ERROR("LoadFormHelper::unloaded : shouldn't be called !");
+ OSL_FAIL("LoadFormHelper::unloaded : shouldn't be called !");
implDispose();
}
@@ -3085,3 +3078,5 @@ sal_Bool SbaXDataBrowserController::InitializeGridModel(const Reference< ::com::
//..................................................................
} // namespace dbaui
//..................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/brwview.cxx b/dbaccess/source/ui/browser/brwview.cxx
index 37dfdaefb0c3..179ae16eaac4 100644
--- a/dbaccess/source/ui/browser/brwview.cxx
+++ b/dbaccess/source/ui/browser/brwview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,49 +29,25 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _SBA_BWRCTRLR_HXX
#include "brwctrlr.hxx"
-#endif
-#ifndef _SBX_BRWVIEW_HXX
#include "brwview.hxx"
-#endif
-#ifndef _SBA_GRID_HXX
#include "sbagrid.hxx"
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
-#ifndef DBACCESS_UI_DBTREEVIEW_HXX
#include "dbtreeview.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBU_BRW_HRC_
#include "dbu_brw.hrc"
-#endif
-#ifndef _COM_SUN_STAR_FORM_XLOADABLE_HPP_
#include <com/sun/star/form/XLoadable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XCONTROLCONTAINER_HPP_
#include <com/sun/star/awt/XControlContainer.hpp>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
+#include <osl/diagnose.h>
using namespace dbaui;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::form;
-// using namespace ::com::sun::star::sdbcx;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::lang;
@@ -128,7 +105,7 @@ void UnoDataBrowserView::Construct(const Reference< ::com::sun::star::awt::XCont
// create the (UNO-) control
m_xGrid = new SbaXGridControl(getORB());
- DBG_ASSERT(m_xGrid.is(), "UnoDataBrowserView::Construct : could not create a grid control !");
+ OSL_ENSURE(m_xGrid.is(), "UnoDataBrowserView::Construct : could not create a grid control !");
// in design mode (for the moment)
m_xGrid->setDesignMode(sal_True);
@@ -146,9 +123,9 @@ void UnoDataBrowserView::Construct(const Reference< ::com::sun::star::awt::XCont
m_pVclControl = NULL;
getVclControl();
- DBG_ASSERT(m_pVclControl != NULL, "UnoDataBrowserView::Construct : no real grid control !");
+ OSL_ENSURE(m_pVclControl != NULL, "UnoDataBrowserView::Construct : no real grid control !");
}
- catch(Exception&)
+ catch(const Exception&)
{
::comphelper::disposeComponent(m_xGrid);
throw;
@@ -174,7 +151,7 @@ UnoDataBrowserView::~UnoDataBrowserView()
::comphelper::disposeComponent(m_xGrid);
::comphelper::disposeComponent(m_xMe);
}
- catch(Exception)
+ catch(const Exception&)
{}
DBG_DTOR(UnoDataBrowserView,NULL);
@@ -393,3 +370,5 @@ BrowserViewStatusDisplay::~BrowserViewStatusDisplay( )
DBG_DTOR(BrowserViewStatusDisplay,NULL);
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dataview.cxx b/dbaccess/source/ui/browser/dataview.cxx
index f4e79d25781d..d58eee0feb35 100644
--- a/dbaccess/source/ui/browser/dataview.cxx
+++ b/dbaccess/source/ui/browser/dataview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,34 +29,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/unohlp.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
#include <comphelper/namedvaluecollection.hxx>
-#ifndef _SFXAPP_HXX //autogen wg. SFX_APP
#include <sfx2/app.hxx>
-#endif
-#ifndef _SFXIMGMGR_HXX
#include <sfx2/imgmgr.hxx>
-#endif
-#ifndef DBAUI_ICONTROLLER_HXX
#include "IController.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _SFX_HRC
#include <sfx2/sfx.hrc>
-#endif
-#ifndef _SVTOOLS_IMGDEF_HXX
#include <svtools/imgdef.hxx>
-#endif
#include <tools/diagnose_ex.h>
//.........................................................................
@@ -239,3 +222,5 @@ namespace dbaui
}
// namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dbexchange.cxx b/dbaccess/source/ui/browser/dbexchange.cxx
index 4cc6bdcc2cb3..867805bc6761 100644
--- a/dbaccess/source/ui/browser/dbexchange.cxx
+++ b/dbaccess/source/ui/browser/dbexchange.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -261,3 +262,4 @@ namespace dbaui
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dbloader.cxx b/dbaccess/source/ui/browser/dbloader.cxx
index dd0699856a05..0997b2f863c5 100644
--- a/dbaccess/source/ui/browser/dbloader.cxx
+++ b/dbaccess/source/ui/browser/dbloader.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -59,6 +60,7 @@
#include <tools/diagnose_ex.h>
#include <tools/urlobj.hxx>
#include <vcl/svapp.hxx>
+#include <sal/macros.h>
using namespace ::com::sun::star;
using namespace ::com::sun::star::uno;
@@ -91,7 +93,7 @@ public:
// static methods
static ::rtl::OUString getImplementationName_Static() throw( )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.DBContentLoader");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.DBContentLoader"));
}
static Sequence< ::rtl::OUString> getSupportedServiceNames_Static(void) throw( );
static ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >
@@ -159,8 +161,8 @@ Sequence< ::rtl::OUString > SAL_CALL DBContentLoader::getSupportedServiceNames(v
Sequence< ::rtl::OUString > DBContentLoader::getSupportedServiceNames_Static(void) throw( )
{
Sequence< ::rtl::OUString > aSNS( 2 );
- aSNS.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.frame.FrameLoader");
- aSNS.getArray()[1] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.ContentLoader");
+ aSNS.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.FrameLoader"));
+ aSNS.getArray()[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ContentLoader"));
return aSNS;
}
// -------------------------------------------------------------------------
@@ -169,17 +171,17 @@ extern "C" void SAL_CALL writeDBLoaderInfo(void* pRegistryKey)
Reference< XRegistryKey> xKey(reinterpret_cast< XRegistryKey*>(pRegistryKey));
// register content loader for dispatch
- ::rtl::OUString aImpl = ::rtl::OUString::createFromAscii("/");
+ ::rtl::OUString aImpl(RTL_CONSTASCII_USTRINGPARAM("/"));
aImpl += DBContentLoader::getImplementationName_Static();
::rtl::OUString aImpltwo = aImpl;
- aImpltwo += ::rtl::OUString::createFromAscii("/UNO/Loader");
+ aImpltwo += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/UNO/Loader"));
Reference< XRegistryKey> xNewKey = xKey->createKey( aImpltwo );
aImpltwo = aImpl;
- aImpltwo += ::rtl::OUString::createFromAscii("/Loader");
+ aImpltwo += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/Loader"));
Reference< XRegistryKey > xLoaderKey = xKey->createKey( aImpltwo );
- xNewKey = xLoaderKey->createKey( ::rtl::OUString::createFromAscii("Pattern") );
- xNewKey->setAsciiValue( ::rtl::OUString::createFromAscii(".component:DB*") );
+ xNewKey = xLoaderKey->createKey( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Pattern")) );
+ xNewKey->setAsciiValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".component:DB*")) );
}
// -----------------------------------------------------------------------
@@ -216,7 +218,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
Reference< XController2 > xController;
const ::rtl::OUString sComponentURL( aParser.GetMainURL( INetURLObject::DECODE_TO_IURI ) );
- for ( size_t i=0; i < sizeof( aImplementations ) / sizeof( aImplementations[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aImplementations ); ++i )
{
if ( sComponentURL.equalsAscii( aImplementations[i].pAsciiServiceName ) )
{
@@ -227,7 +229,7 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
// if a data source browser is loaded without its tree pane, then we assume it to be a
// table data view, effectively. In this case, we need to adjust the module identifier.
- // 2008-02-05 / i85879 / frank.schoenheit@sun.com
+ // #i85879#
::comphelper::NamedValueCollection aLoadArgs( rArgs );
if ( sComponentURL == URL_COMPONENT_DATASOURCEBROWSER )
@@ -301,11 +303,11 @@ void SAL_CALL DBContentLoader::load(const Reference< XFrame > & rFrame, const ::
}
// init controller
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
try
{
Reference<XInitialization > xIni(xController,UNO_QUERY);
- PropertyValue aFrame(::rtl::OUString::createFromAscii("Frame"),0,makeAny(rFrame),PropertyState_DIRECT_VALUE);
+ PropertyValue aFrame(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Frame")),0,makeAny(rFrame),PropertyState_DIRECT_VALUE);
Sequence< Any > aInitArgs(m_aArgs.getLength()+1);
Any* pBegin = aInitArgs.getArray();
@@ -356,3 +358,4 @@ void DBContentLoader::cancel(void) throw()
{
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dbtreemodel.cxx b/dbaccess/source/ui/browser/dbtreemodel.cxx
index 94a3f7e93696..44b3508e786e 100644
--- a/dbaccess/source/ui/browser/dbtreemodel.cxx
+++ b/dbaccess/source/ui/browser/dbtreemodel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_DBTREEMODEL_HXX
#include "dbtreemodel.hxx"
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
namespace dbaui
{
@@ -53,3 +48,5 @@ namespace dbaui
DBG_DTOR(DBTreeListUserData,NULL);
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dbtreemodel.hxx b/dbaccess/source/ui/browser/dbtreemodel.hxx
index 33186543afab..12ce3ed3925a 100644
--- a/dbaccess/source/ui/browser/dbtreemodel.hxx
+++ b/dbaccess/source/ui/browser/dbtreemodel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,21 +29,11 @@
#ifndef DBAUI_DBTREEMODEL_HXX
#define DBAUI_DBTREEMODEL_HXX
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _SVLBOX_HXX
#include <svtools/svlbox.hxx>
-#endif
-#ifndef _SVLBOXITM_HXX
#include <svtools/svlbitm.hxx>
-#endif
-#ifndef _SBA_UNODATBR_HXX_
#include "unodatbr.hxx"
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
// syntax of the tree userdata
// datasource holds the connection
@@ -77,3 +68,5 @@ namespace dbaui
}
#endif // DBAUI_DBTREEMODEL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dbtreeview.cxx b/dbaccess/source/ui/browser/dbtreeview.cxx
index 0da64c8160b0..55452581dbb1 100644
--- a/dbaccess/source/ui/browser/dbtreeview.cxx
+++ b/dbaccess/source/ui/browser/dbtreeview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_UI_DBTREEVIEW_HXX
#include "dbtreeview.hxx"
-#endif
-#ifndef _SVTREEBOX_HXX
#include <svtools/svtreebx.hxx>
-#endif
-#ifndef DBAUI_DBTREELISTBOX_HXX
#include "dbtreelistbox.hxx"
-#endif
-#ifndef DBAUI_DBTREEMODEL_HXX
#include "dbtreemodel.hxx"
-#endif
#include "dbaccess_helpid.hrc"
// .........................................................................
@@ -129,3 +122,4 @@ void DBTreeView::GetFocus()
// .........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dbtreeview.hxx b/dbaccess/source/ui/browser/dbtreeview.hxx
index b008a79a4195..2cba0dd10b08 100644
--- a/dbaccess/source/ui/browser/dbtreeview.hxx
+++ b/dbaccess/source/ui/browser/dbtreeview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,13 +29,9 @@
#ifndef DBACCESS_UI_DBTREEVIEW_HXX
#define DBACCESS_UI_DBTREEVIEW_HXX
-#ifndef _SV_WINDOW_HXX //autogen
#include <vcl/window.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
class SvTreeListBox;
class SvLBoxTreeList;
@@ -80,3 +77,4 @@ namespace dbaui
#endif // DBACCESS_UI_DBTREEVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
index bfed5bbbe749..d0d6bb663a53 100644
--- a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
+++ b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _SBA_UNODATBR_HXX_
#include "unodatbr.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _DBAUI_LISTVIEWITEMS_HXX_
#include "listviewitems.hxx"
-#endif
-#ifndef DBACCESS_IMAGEPROVIDER_HXX
#include "imageprovider.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef DBACCESS_UI_DBTREEVIEW_HXX
+#include <osl/diagnose.h>
#include "dbtreeview.hxx"
-#endif
-#ifndef DBAUI_DBTREELISTBOX_HXX
#include "dbtreelistbox.hxx"
-#endif
-#ifndef _DBU_BRW_HRC_
#include "dbu_brw.hrc"
-#endif
-#ifndef DBAUI_DBTREEMODEL_HXX
#include "dbtreemodel.hxx"
-#endif
using namespace ::com::sun::star::frame;
using namespace ::dbtools;
@@ -67,7 +50,7 @@ namespace dbaui
// -----------------------------------------------------------------------------
SbaTableQueryBrowser::EntryType SbaTableQueryBrowser::getChildType( SvLBoxEntry* _pEntry ) const
{
- DBG_ASSERT(isContainer(_pEntry), "SbaTableQueryBrowser::getChildType: invalid entry!");
+ OSL_ENSURE(isContainer(_pEntry), "SbaTableQueryBrowser::getChildType: invalid entry!");
switch (getEntryType(_pEntry))
{
case etTableContainer:
@@ -142,7 +125,7 @@ void SbaTableQueryBrowser::select(SvLBoxEntry* _pEntry, sal_Bool _bSelect)
m_pTreeModel->InvalidateEntry(_pEntry);
}
else {
- DBG_ERROR("SbaTableQueryBrowser::select: invalid entry!");
+ OSL_FAIL("SbaTableQueryBrowser::select: invalid entry!");
}
}
@@ -162,7 +145,7 @@ sal_Bool SbaTableQueryBrowser::isSelected(SvLBoxEntry* _pEntry) const
if (pTextItem)
return static_cast<OBoldListboxString*>(pTextItem)->isEmphasized();
else {
- DBG_ERROR("SbaTableQueryBrowser::isSelected: invalid entry!");
+ OSL_FAIL("SbaTableQueryBrowser::isSelected: invalid entry!");
}
return sal_False;
}
@@ -174,7 +157,7 @@ void SbaTableQueryBrowser::SelectionChanged()
InvalidateFeature(ID_BROWSER_INSERTCOLUMNS);
InvalidateFeature(ID_BROWSER_INSERTCONTENT);
InvalidateFeature(ID_BROWSER_FORMLETTER);
- } // if ( !m_bShowMenu )
+ }
InvalidateFeature(ID_BROWSER_COPY);
InvalidateFeature(ID_BROWSER_CUT);
}
@@ -217,7 +200,7 @@ sal_Int32 SbaTableQueryBrowser::getDatabaseObjectType( EntryType _eType )
default:
break;
}
- OSL_ENSURE( false, "SbaTableQueryBrowser::getDatabaseObjectType: folder types and 'Unknown' not allowed here!" );
+ OSL_FAIL( "SbaTableQueryBrowser::getDatabaseObjectType: folder types and 'Unknown' not allowed here!" );
return DatabaseObject::TABLE;
}
@@ -241,25 +224,21 @@ void SbaTableQueryBrowser::notifyHiContrastChanged()
::std::auto_ptr< ImageProvider > pImageProvider( getImageProviderFor( pEntryLoop ) );
// the images for this entry
- Image aImage, aImageHC;
+ Image aImage;
if ( pData->eType == etDatasource )
- {
- aImage = pImageProvider->getDatabaseImage( false );
- aImageHC = pImageProvider->getDatabaseImage( true );
- }
+ aImage = pImageProvider->getDatabaseImage();
else
{
bool bIsFolder = !isObject( pData->eType );
if ( bIsFolder )
{
sal_Int32 nObjectType( getDatabaseObjectType( pData->eType ) );
- aImage = pImageProvider->getFolderImage( nObjectType, false );
- aImageHC = pImageProvider->getFolderImage( nObjectType, true );
+ aImage = pImageProvider->getFolderImage( nObjectType );
}
else
{
sal_Int32 nObjectType( getDatabaseObjectType( pData->eType ) );
- pImageProvider->getImages( GetEntryText( pEntryLoop ), nObjectType, aImage, aImageHC );
+ pImageProvider->getImages( GetEntryText( pEntryLoop ), nObjectType, aImage );
}
}
@@ -273,10 +252,8 @@ void SbaTableQueryBrowser::notifyHiContrastChanged()
SvLBoxContextBmp* pContextBitmapItem = static_cast< SvLBoxContextBmp* >( pItem );
- pContextBitmapItem->SetBitmap1( aImage, BMP_COLOR_NORMAL );
- pContextBitmapItem->SetBitmap2( aImage, BMP_COLOR_NORMAL );
- pContextBitmapItem->SetBitmap1( aImageHC, BMP_COLOR_HIGHCONTRAST );
- pContextBitmapItem->SetBitmap2( aImageHC, BMP_COLOR_HIGHCONTRAST );
+ pContextBitmapItem->SetBitmap1( aImage );
+ pContextBitmapItem->SetBitmap2( aImage );
break;
}
@@ -289,3 +266,4 @@ void SbaTableQueryBrowser::notifyHiContrastChanged()
} // namespace dbaui
// .........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/dsbrowserDnD.cxx b/dbaccess/source/ui/browser/dsbrowserDnD.cxx
index 8ca7ad79f385..f30345757ddf 100644
--- a/dbaccess/source/ui/browser/dsbrowserDnD.cxx
+++ b/dbaccess/source/ui/browser/dsbrowserDnD.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,9 +48,9 @@
#include <connectivity/dbexception.hxx>
#include <connectivity/dbtools.hxx>
#include <cppuhelper/exc_hlp.hxx>
-#include <svtools/treelist.hxx>
#include <svx/dataaccessdescriptor.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <functional>
// .........................................................................
@@ -136,7 +137,7 @@ namespace dbaui
EntryType eEntryType = getEntryType( pHitEntry );
if (!isContainer(eEntryType))
{
- DBG_ERROR("SbaTableQueryBrowser::executeDrop: what the hell did queryDrop do?");
+ OSL_FAIL("SbaTableQueryBrowser::executeDrop: what the hell did queryDrop do?");
// queryDrop shoud not have allowed us to reach this situation ....
return DND_ACTION_NONE;
}
@@ -241,7 +242,7 @@ namespace dbaui
IMPL_LINK( SbaTableQueryBrowser, OnAsyncDrop, void*, /*NOTINTERESTEDIN*/ )
{
m_nAsyncDrop = 0;
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( m_aAsyncDrop.nType == E_TABLE )
@@ -277,7 +278,7 @@ namespace dbaui
if ( pData->xConnection.is() )
{
- DBG_ASSERT( impl_isDataSourceEntry( pEntryLoop ), "SbaTableQueryBrowser::clearTreeModel: no data source entry, but a connection?" );
+ OSL_ENSURE( impl_isDataSourceEntry( pEntryLoop ), "SbaTableQueryBrowser::clearTreeModel: no data source entry, but a connection?" );
// connections are to be stored *only* at the data source entries
impl_releaseConnection( pData->xConnection );
}
@@ -293,3 +294,4 @@ namespace dbaui
} // namespace dbaui
// .........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/exsrcbrw.cxx b/dbaccess/source/ui/browser/exsrcbrw.cxx
index b0dd7e72696e..0d93b52eabd2 100644
--- a/dbaccess/source/ui/browser/exsrcbrw.cxx
+++ b/dbaccess/source/ui/browser/exsrcbrw.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,39 +29,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _SBA_EXTCTRLR_HXX
#include "exsrcbrw.hxx"
-#endif
-#ifndef _COM_SUN_STAR_FORM_FORMCOMPONENTTYPE_HPP_
#include <com/sun/star/form/FormComponentType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XURLTRANSFORMER_HPP_
#include <com/sun/star/util/XURLTransformer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XGRIDCOLUMNFACTORY_HPP_
#include <com/sun/star/form/XGridColumnFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XLOADABLE_HPP_
#include <com/sun/star/form/XLoadable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
-#endif
-#ifndef _SBA_FORMADAPTER_HXX
#include "formadapter.hxx"
-#endif
-#ifndef _COMPHELPER_PROCESSFACTORY_HXX_
#include <comphelper/processfactory.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::sdb;
@@ -175,7 +154,7 @@ void SbaExternalSourceBrowser::modified(const ::com::sun::star::lang::EventObjec
void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::URL& aURL, const Sequence< ::com::sun::star::beans::PropertyValue>& aArgs) throw(::com::sun::star::uno::RuntimeException)
{
const ::com::sun::star::beans::PropertyValue* pArguments = aArgs.getConstArray();
- if (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/AddGridColumn")))
+ if (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/AddGridColumn"))))
{
// search the argument describing the column to create
::rtl::OUString sControlType;
@@ -184,21 +163,21 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
sal_uInt16 i;
for ( i = 0; i < aArgs.getLength(); ++i, ++pArguments )
{
- if (pArguments->Name.equals(::rtl::OUString::createFromAscii("ColumnType")))
+ if (pArguments->Name.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnType"))))
{
sal_Bool bCorrectType = pArguments->Value.getValueType().equals(::getCppuType((const ::rtl::OUString*)0));
OSL_ENSURE(bCorrectType, "invalid type for argument \"ColumnType\" !");
if (bCorrectType)
sControlType = ::comphelper::getString(pArguments->Value);
}
- else if (pArguments->Name.equals(::rtl::OUString::createFromAscii("ColumnPosition")))
+ else if (pArguments->Name.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnPosition"))))
{
sal_Bool bCorrectType = pArguments->Value.getValueType().equals(::getCppuType((const sal_Int16*)0));
OSL_ENSURE(bCorrectType, "invalid type for argument \"ColumnPosition\" !");
if (bCorrectType)
nControlPos = ::comphelper::getINT16(pArguments->Value);
}
- else if (pArguments->Name.equals(::rtl::OUString::createFromAscii("ColumnProperties")))
+ else if (pArguments->Name.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnProperties"))))
{
sal_Bool bCorrectType = pArguments->Value.getValueType().equals(::getCppuType((const Sequence< ::com::sun::star::beans::PropertyValue>*)0));
OSL_ENSURE(bCorrectType, "invalid type for argument \"ColumnProperties\" !");
@@ -206,12 +185,12 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
aControlProps = *(Sequence< ::com::sun::star::beans::PropertyValue>*)pArguments->Value.getValue();
}
else
- OSL_ENSURE(sal_False, ((ByteString("SbaExternalSourceBrowser::dispatch(AddGridColumn) : unknown argument (") += ByteString((const sal_Unicode*)pArguments->Name, gsl_getSystemTextEncoding()).GetBuffer()) += ") !").GetBuffer());
+ OSL_FAIL(((ByteString("SbaExternalSourceBrowser::dispatch(AddGridColumn) : unknown argument (") += ByteString((const sal_Unicode*)pArguments->Name, gsl_getSystemTextEncoding()).GetBuffer()) += ") !").GetBuffer());
}
if (!sControlType.getLength())
{
- OSL_ENSURE(sal_False, "SbaExternalSourceBrowser::dispatch(AddGridColumn) : missing argument (ColumnType) !");
- sControlType = ::rtl::OUString::createFromAscii("TextField");
+ OSL_FAIL("SbaExternalSourceBrowser::dispatch(AddGridColumn) : missing argument (ColumnType) !");
+ sControlType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TextField"));
}
OSL_ENSURE(aControlProps.getLength(), "SbaExternalSourceBrowser::dispatch(AddGridColumn) : missing argument (ColumnProperties) !");
@@ -221,7 +200,7 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
Reference< XPropertySetInfo > xNewColProperties;
if (xNewCol.is())
xNewColProperties = xNewCol->getPropertySetInfo();
- // set it's properties
+ // set its properties
if (xNewColProperties.is())
{
const ::com::sun::star::beans::PropertyValue* pControlProps = aControlProps.getConstArray();
@@ -234,8 +213,7 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
}
catch(Exception&)
{
- OSL_ENSURE(sal_False,
- ( ByteString("SbaExternalSourceBrowser::dispatch : could not set a column property (")
+ OSL_FAIL(( ByteString("SbaExternalSourceBrowser::dispatch : could not set a column property (")
+= ByteString(pControlProps->Name.getStr(), (sal_uInt16)pControlProps->Name.getLength(), RTL_TEXTENCODING_ASCII_US)
+= ByteString(")!")).GetBuffer());
}
@@ -253,20 +231,20 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
// append the column
xColContainer->insertByIndex(nControlPos, makeAny(xNewCol));
}
- else if (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/ClearView")))
+ else if (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/ClearView"))))
{
ClearView();
}
- else if (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/AttachToForm")))
+ else if (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/AttachToForm"))))
{
if (!m_pDataSourceImpl)
return;
Reference< XRowSet > xMasterForm;
- // search the arguments for he master form
+ // search the arguments for the master form
for (sal_uInt16 i=0; i<aArgs.getLength(); ++i, ++pArguments)
{
- if ((pArguments->Name.equals(::rtl::OUString::createFromAscii("MasterForm"))) && (pArguments->Value.getValueTypeClass() == TypeClass_INTERFACE))
+ if ((pArguments->Name.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("MasterForm")))) && (pArguments->Value.getValueTypeClass() == TypeClass_INTERFACE))
{
xMasterForm = Reference< XRowSet > (*(Reference< XInterface > *)pArguments->Value.getValue(), UNO_QUERY);
break;
@@ -274,7 +252,7 @@ void SAL_CALL SbaExternalSourceBrowser::dispatch(const ::com::sun::star::util::U
}
if (!xMasterForm.is())
{
- OSL_ENSURE(sal_False, "SbaExternalSourceBrowser::dispatch(FormSlots/AttachToForm) : please specify a form to attach to as argument !");
+ OSL_FAIL("SbaExternalSourceBrowser::dispatch(FormSlots/AttachToForm) : please specify a form to attach to as argument !");
return;
}
@@ -293,22 +271,22 @@ Reference< ::com::sun::star::frame::XDispatch > SAL_CALL SbaExternalSourceBrows
m_bInQueryDispatch = sal_True;
- if ( (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/AttachToForm")))
+ if ( (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/AttachToForm"))))
// attach a new external form
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/AddGridColumn")))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/AddGridColumn"))))
// add a column to the grid
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/ClearView")))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/ClearView"))))
// clear the grid
)
xReturn = (::com::sun::star::frame::XDispatch*)this;
if ( !xReturn.is()
- && ( (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/moveToFirst")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/moveToPrev")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/moveToNext")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/moveToLast")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/moveToNew")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:FormSlots/undoRecord")))
+ && ( (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/moveToFirst"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/moveToPrev"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/moveToNext"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/moveToLast"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/moveToNew"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:FormSlots/undoRecord"))))
)
)
{
@@ -321,7 +299,7 @@ Reference< ::com::sun::star::frame::XDispatch > SAL_CALL SbaExternalSourceBrows
m_xUrlTransformer->parseStrict( aNewUrl );
// set a new mark
- aNewUrl.Mark = ::rtl::OUString::createFromAscii("DB/FormGridView");
+ aNewUrl.Mark = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DB/FormGridView"));
// this controller is instantiated when somebody dispatches the ".component:DB/FormGridView" in any
// frame, so we use "FormGridView" as mark that a dispatch request came from this view
@@ -446,7 +424,7 @@ void SbaExternalSourceBrowser::Attach(const Reference< XRowSet > & xMaster)
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "SbaExternalSourceBrowser::Attach : couldn't restore the cursor position !");
+ OSL_FAIL("SbaExternalSourceBrowser::Attach : couldn't restore the cursor position !");
}
}
@@ -498,3 +476,5 @@ void SbaExternalSourceBrowser::stopListening()
//==================================================================
//==================================================================
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/formadapter.cxx b/dbaccess/source/ui/browser/formadapter.cxx
index 03b8f5358751..c74af7b41750 100644
--- a/dbaccess/source/ui/browser/formadapter.cxx
+++ b/dbaccess/source/ui/browser/formadapter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,36 +29,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _SBA_FORMADAPTER_HXX
#include "formadapter.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX //autogen
#include <tools/debug.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
+#include <osl/diagnose.h>
#include <comphelper/types.hxx>
-#endif
-#ifndef _COMPHELPER_ENUMHELPER_HXX_
#include <comphelper/enumhelper.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _DBU_BRW_HRC_
#include "dbu_brw.hrc"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
using namespace dbaui;
using namespace ::com::sun::star::uno;
@@ -211,7 +193,7 @@ void SbaXFormAdapter::AttachForm(const Reference< ::com::sun::star::sdbc::XRowSe
if (xNewMaster == m_xMainForm)
return;
- DBG_ASSERT(xNewMaster.get() != static_cast< ::com::sun::star::sdbc::XRowSet* >(this), "SbaXFormAdapter::AttachForm : invalid argument !");
+ OSL_ENSURE(xNewMaster.get() != static_cast< ::com::sun::star::sdbc::XRowSet* >(this), "SbaXFormAdapter::AttachForm : invalid argument !");
if (m_xMainForm.is())
{
@@ -1097,52 +1079,52 @@ IMPLEMENT_LISTENER_ADMINISTRATION(SbaXFormAdapter, form, SubmitListener, m_aSubm
// -------------------------------------------------------------------------
sal_Bool SAL_CALL SbaXFormAdapter::getGroupControl() throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::getGroupControl : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::getGroupControl : not supported !");
return sal_False;
}
// -------------------------------------------------------------------------
void SAL_CALL SbaXFormAdapter::setGroupControl(sal_Bool /*GroupControl*/) throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::setGroupControl : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::setGroupControl : not supported !");
}
// -------------------------------------------------------------------------
void SAL_CALL SbaXFormAdapter::setControlModels(const Sequence< Reference< ::com::sun::star::awt::XControlModel > >& /*Controls*/) throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::setControlModels : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::setControlModels : not supported !");
}
// -------------------------------------------------------------------------
Sequence< Reference< ::com::sun::star::awt::XControlModel > > SAL_CALL SbaXFormAdapter::getControlModels() throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::getControlModels : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::getControlModels : not supported !");
return Sequence< Reference< ::com::sun::star::awt::XControlModel > >();
}
// -------------------------------------------------------------------------
void SAL_CALL SbaXFormAdapter::setGroup(const Sequence< Reference< ::com::sun::star::awt::XControlModel > >& /*_rGroup*/, const ::rtl::OUString& /*GroupName*/) throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::setGroup : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::setGroup : not supported !");
}
// -------------------------------------------------------------------------
sal_Int32 SAL_CALL SbaXFormAdapter::getGroupCount() throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::getGroupCount : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::getGroupCount : not supported !");
return 0;
}
// -------------------------------------------------------------------------
void SAL_CALL SbaXFormAdapter::getGroup(sal_Int32 /*nGroup*/, Sequence< Reference< ::com::sun::star::awt::XControlModel > >& /*_rGroup*/, ::rtl::OUString& /*Name*/) throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::getGroup : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::getGroup : not supported !");
}
// -------------------------------------------------------------------------
void SAL_CALL SbaXFormAdapter::getGroupByName(const ::rtl::OUString& /*Name*/, Sequence< Reference< ::com::sun::star::awt::XControlModel > >& /*_rGroup*/) throw( RuntimeException )
{
- DBG_ERROR("SAL_CALL SbaXFormAdapter::getGroupByName : not supported !");
+ OSL_FAIL("SAL_CALL SbaXFormAdapter::getGroupByName : not supported !");
}
// ::com::sun::star::lang::XComponent
@@ -1207,7 +1189,7 @@ void SAL_CALL SbaXFormAdapter::removeEventListener(const Reference< ::com::sun::
void SAL_CALL SbaXFormAdapter::setFastPropertyValue(sal_Int32 nHandle, const Any& aValue) throw( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, RuntimeException )
{
Reference< ::com::sun::star::beans::XFastPropertySet > xSet(m_xMainForm, UNO_QUERY);
- DBG_ASSERT(xSet.is(), "SAL_CALL SbaXFormAdapter::setFastPropertyValue : have no master form !");
+ OSL_ENSURE(xSet.is(), "SAL_CALL SbaXFormAdapter::setFastPropertyValue : have no master form !");
if (m_nNamePropHandle == nHandle)
{
@@ -1240,7 +1222,7 @@ void SAL_CALL SbaXFormAdapter::setFastPropertyValue(sal_Int32 nHandle, const Any
Any SAL_CALL SbaXFormAdapter::getFastPropertyValue(sal_Int32 nHandle) throw( ::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, RuntimeException )
{
Reference< ::com::sun::star::beans::XFastPropertySet > xSet(m_xMainForm, UNO_QUERY);
- DBG_ASSERT(xSet.is(), "SAL_CALL SbaXFormAdapter::getFastPropertyValue : have no master form !");
+ OSL_ENSURE(xSet.is(), "SAL_CALL SbaXFormAdapter::getFastPropertyValue : have no master form !");
if (m_nNamePropHandle == nHandle)
return makeAny(m_sName);
@@ -1334,7 +1316,7 @@ Sequence< Any > SAL_CALL SbaXFormAdapter::getPropertyValues(const Sequence< ::rt
// search for (and fake) the NAME property
const ::rtl::OUString* pNames = aPropertyNames.getConstArray();
Any* pValues = aReturn.getArray();
- DBG_ASSERT(aReturn.getLength() == aPropertyNames.getLength(), "SAL_CALL SbaXFormAdapter::getPropertyValues : the main form returned an invalid-length sequence !");
+ OSL_ENSURE(aReturn.getLength() == aPropertyNames.getLength(), "SAL_CALL SbaXFormAdapter::getPropertyValues : the main form returned an invalid-length sequence !");
for (sal_Int32 i=0; i<aPropertyNames.getLength(); ++i, ++pNames, ++pValues)
if (pNames->equals(PROPERTY_NAME))
{
@@ -1516,7 +1498,7 @@ void SbaXFormAdapter::implInsert(const Any& aElement, sal_Int32 nIndex, const ::
if (sal::static_int_cast< sal_uInt32 >(nIndex) > m_aChildren.size())
nIndex = m_aChildren.size();
- DBG_ASSERT(m_aChildren.size() == m_aChildNames.size(), "SAL_CALL SbaXFormAdapter::implInsert : inconsistent container state !");
+ OSL_ENSURE(m_aChildren.size() == m_aChildNames.size(), "SAL_CALL SbaXFormAdapter::implInsert : inconsistent container state !");
m_aChildren.insert(m_aChildren.begin() + nIndex, xElement);
m_aChildNames.insert(m_aChildNames.begin() + nIndex, sName);
@@ -1635,7 +1617,7 @@ void SAL_CALL SbaXFormAdapter::removeByIndex(sal_Int32 _rIndex) throw( ::com::su
Reference< ::com::sun::star::form::XFormComponent > xAffected = *(m_aChildren.begin() + _rIndex);
- DBG_ASSERT(m_aChildren.size() == m_aChildNames.size(), "SAL_CALL SbaXFormAdapter::removeByIndex : inconsistent container state !");
+ OSL_ENSURE(m_aChildren.size() == m_aChildNames.size(), "SAL_CALL SbaXFormAdapter::removeByIndex : inconsistent container state !");
m_aChildren.erase(m_aChildren.begin() + _rIndex);
m_aChildNames.erase(m_aChildNames.begin() + _rIndex);
@@ -1694,7 +1676,7 @@ void SAL_CALL SbaXFormAdapter::replaceByIndex(sal_Int32 _rIndex, const Any& Elem
Reference< ::com::sun::star::form::XFormComponent > xOld = *(m_aChildren.begin() + _rIndex);
- DBG_ASSERT(m_aChildren.size() == m_aChildNames.size(), "SAL_CALL SbaXFormAdapter::replaceByIndex : inconsistent container state !");
+ OSL_ENSURE(m_aChildren.size() == m_aChildNames.size(), "SAL_CALL SbaXFormAdapter::replaceByIndex : inconsistent container state !");
*(m_aChildren.begin() + _rIndex) = xElement;
*(m_aChildNames.begin() + _rIndex) = sName;
@@ -1769,7 +1751,7 @@ void SAL_CALL SbaXFormAdapter::propertyChange(const ::com::sun::star::beans::Pro
if(aIter != m_aChildren.end())
{
sal_Int32 nPos = aIter - m_aChildren.begin();
- DBG_ASSERT(*(m_aChildNames.begin() + nPos) == ::comphelper::getString(evt.OldValue), "SAL_CALL SbaXFormAdapter::propertyChange : object has a wrong name !");
+ OSL_ENSURE(*(m_aChildNames.begin() + nPos) == ::comphelper::getString(evt.OldValue), "SAL_CALL SbaXFormAdapter::propertyChange : object has a wrong name !");
*(m_aChildNames.begin() + nPos) = ::comphelper::getString(evt.NewValue);
}
}
@@ -1792,3 +1774,4 @@ void SAL_CALL SbaXFormAdapter::disposing(const ::com::sun::star::lang::EventObje
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/genericcontroller.cxx b/dbaccess/source/ui/browser/genericcontroller.cxx
index aa6640d4edd5..77489aa422ae 100644
--- a/dbaccess/source/ui/browser/genericcontroller.cxx
+++ b/dbaccess/source/ui/browser/genericcontroller.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,106 +28,44 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_GENERICCONTROLLER_HXX
#include "genericcontroller.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _TOOLKIT_AWT_VCLXWINDOW_HXX_
#include <toolkit/awt/vclxwindow.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
+#include <osl/diagnose.h>
#include "dbustrings.hrc"
-#endif
-#ifndef _VCL_STDTEXT_HXX
#include <vcl/stdtext.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
#include <framework/titlehelper.hxx>
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XCOMPLETEDCONNECTION_HPP_
#include <com/sun/star/sdb/XCompletedConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XCLOSEABLE_HPP_
#include <com/sun/star/util/XCloseable.hpp>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
-#ifndef _SV_WAITOBJ_HXX
+#include <sal/macros.h>
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef SVTOOLS_URIHELPER_HXX
#include <svl/urihelper.hxx>
-#endif
-#ifndef _DBAUI_DATASOURCECONNECTOR_HXX_
#include "datasourceconnector.hxx"
-#endif
-#ifndef INCLUDED_SVTOOLS_MODULEOPTIONS_HXX
#include <unotools/moduleoptions.hxx>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_STATUS_VISIBILITY_HPP_
#include <com/sun/star/frame/status/Visibility.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XMODIFIABLE_HPP_
#include <com/sun/star/util/XModifiable.hpp>
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _RTL_LOGFILE_HXX_
#include <rtl/logfile.hxx>
-#endif
#include <algorithm>
-#include <hash_map>
+#include <o3tl/compat_functional.hxx>
+#include <boost/unordered_map.hpp>
#include <cppuhelper/implbase1.hxx>
#include <limits>
@@ -152,7 +91,7 @@ using namespace ::comphelper;
#define LAST_USER_DEFINED_FEATURE ( ::std::numeric_limits< sal_uInt16 >::max() )
// -------------------------------------------------------------------------
-typedef ::std::hash_map< sal_Int16, sal_Int16 > CommandHashMap;
+typedef ::boost::unordered_map< sal_Int16, sal_Int16 > CommandHashMap;
typedef ::std::list< DispatchInformation > DispatchInfoList;
@@ -213,7 +152,7 @@ void UserDefinedFeatures::execute( const URL& _rFeatureURL, const Sequence< Prop
if ( xDispatch == xController )
{
- OSL_ENSURE( false, "UserDefinedFeatures::execute: the controller shouldn't be the dispatcher here!" );
+ OSL_FAIL( "UserDefinedFeatures::execute: the controller shouldn't be the dispatcher here!" );
xDispatch.clear();
}
@@ -271,7 +210,7 @@ OGenericUnoController::OGenericUnoController(const Reference< XMultiServiceFacto
try
{
- m_xUrlTransformer = Reference< XURLTransformer > (_rM->createInstance(::rtl::OUString::createFromAscii("com.sun.star.util.URLTransformer")), UNO_QUERY);
+ m_xUrlTransformer = Reference< XURLTransformer > (_rM->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.URLTransformer"))), UNO_QUERY);
}
catch(Exception&)
{
@@ -294,7 +233,7 @@ OGenericUnoController::OGenericUnoController()
,m_bReadOnly(sal_False)
,m_bCurrentlyModified(sal_False)
{
- OSL_ENSURE( false, "OGenericUnoController::OGenericUnoController: illegal call!" );
+ OSL_FAIL( "OGenericUnoController::OGenericUnoController: illegal call!" );
// This ctor only exists because the MSVC compiler complained about an unresolved external
// symbol. It should not be used at all. Since using it yields strange runtime problems,
// we simply abort here.
@@ -324,14 +263,14 @@ sal_Bool OGenericUnoController::Construct(Window* /*pParent*/)
fillSupportedFeatures();
// create the database context
- DBG_ASSERT(getORB().is(), "OGenericUnoController::Construct need a service factory!");
+ OSL_ENSURE(getORB().is(), "OGenericUnoController::Construct need a service factory!");
try
{
m_xDatabaseContext = Reference< XNameAccess >(getORB()->createInstance(SERVICE_SDB_DATABASECONTEXT), UNO_QUERY);
}
catch(Exception&)
{
- DBG_ERROR("OGenericUnoController::Construct: could not create (or start listening at) the database context!");
+ OSL_FAIL("OGenericUnoController::Construct: could not create (or start listening at) the database context!");
}
if (!m_xDatabaseContext.is())
@@ -354,7 +293,7 @@ void OGenericUnoController::impl_initialize()
// -------------------------------------------------------------------------
void SAL_CALL OGenericUnoController::initialize( const Sequence< Any >& aArguments ) throw(Exception, RuntimeException)
{
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
Reference< XWindow > xParent;
@@ -370,12 +309,6 @@ void SAL_CALL OGenericUnoController::initialize( const Sequence< Any >& aArgumen
{
xFrame.set(aValue.Value,UNO_QUERY_THROW);
}
- /* #i42316#
- else if ( ( *pIter >>= aValue ) && ( 0 == aValue.Name.compareToAscii( "ReadOnly" ) ) )
- {
- aValue.Value >>= m_bReadOnly;
- }
- */
else if ( ( *pIter >>= aValue ) && ( 0 == aValue.Name.compareToAscii( "Preview" ) ) )
{
aValue.Value >>= m_bPreview;
@@ -392,7 +325,7 @@ void SAL_CALL OGenericUnoController::initialize( const Sequence< Any >& aArgumen
Window* pParentWin = pParentComponent ? pParentComponent->GetWindow() : NULL;
if (!pParentWin)
{
- throw IllegalArgumentException( ::rtl::OUString::createFromAscii( "Parent window is null" ), *this, 1 );
+ throw IllegalArgumentException( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Parent window is null")), *this, 1 );
}
m_aInitParameters.assign( aArguments );
@@ -400,7 +333,7 @@ void SAL_CALL OGenericUnoController::initialize( const Sequence< Any >& aArgumen
ODataView* pView = getView();
if ( !pView )
- throw RuntimeException( ::rtl::OUString::createFromAscii( "unable to create a view" ), *this );
+ throw RuntimeException( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("unable to create a view")), *this );
if ( m_bReadOnly || m_bPreview )
pView->EnableInput( sal_False );
@@ -487,7 +420,7 @@ Sequence< PropertyValue > SAL_CALL OGenericUnoController::getCreationArguments()
// -----------------------------------------------------------------------
void OGenericUnoController::attachFrame( const Reference< XFrame >& _rxFrame ) throw( RuntimeException )
{
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
stopFrameListening( m_aCurrentFrame.getFrame() );
@@ -545,7 +478,6 @@ namespace
// #i67882# is the bug which was caused by the real fix which we did in framework
// #i68216# is the bug which requests to fix the code in Draw which relies on
// framework's implementation details
- // 2006-08-07 / frank.schoenheit@sun.com
if ( !!_rFeatureState.sTitle )
_out_rStates.push_back( makeAny( *_rFeatureState.sTitle ) );
if ( !!_rFeatureState.bChecked )
@@ -607,7 +539,6 @@ void OGenericUnoController::ImplBroadcastFeatureState(const ::rtl::OUString& _rF
// it is possible that listeners are registered or revoked while
// we are notifying them, so we must use a copy of m_arrStatusListener, not
// m_arrStatusListener itself
- // #121276# / 2005-05-19 / frank.schoenheit@sun.com
Dispatch aNotifyLoop( m_arrStatusListener );
DispatchIterator iterSearch = aNotifyLoop.begin();
DispatchIterator iterEnd = aNotifyLoop.end();
@@ -681,7 +612,7 @@ void OGenericUnoController::InvalidateFeature_Impl()
::rtl::OString sMessage( "OGenericUnoController::InvalidateFeature_Impl: feature id " );
sMessage += ::rtl::OString::valueOf( aNextFeature.nId );
sMessage += ::rtl::OString( " has been invalidated, but is not supported!" );
- OSL_ENSURE( false, sMessage.getStr() );
+ OSL_FAIL( sMessage.getStr() );
}
#endif
if ( m_aSupportedFeatures.end() != aFeaturePos )
@@ -748,7 +679,7 @@ void OGenericUnoController::InvalidateAll()
void OGenericUnoController::InvalidateAll_Impl()
{
// ---------------------------------
- // invalidate all aupported features
+ // invalidate all supported features
for ( SupportedFeatures::const_iterator aIter = m_aSupportedFeatures.begin();
aIter != m_aSupportedFeatures.end();
@@ -758,7 +689,7 @@ void OGenericUnoController::InvalidateAll_Impl()
{
::osl::MutexGuard aGuard( m_aFeatureMutex);
- DBG_ASSERT(m_aFeaturesToInvalidate.size(), "OGenericUnoController::InvalidateAll_Impl: to be called from within InvalidateFeature_Impl only!");
+ OSL_ENSURE(m_aFeaturesToInvalidate.size(), "OGenericUnoController::InvalidateAll_Impl: to be called from within InvalidateFeature_Impl only!");
m_aFeaturesToInvalidate.pop_front();
if(!m_aFeaturesToInvalidate.empty())
m_aAsyncInvalidateAll.Call();
@@ -841,13 +772,13 @@ void OGenericUnoController::setMasterDispatchProvider(const Reference< XDispatch
// -----------------------------------------------------------------------
void OGenericUnoController::dispatch(const URL& _aURL, const Sequence< PropertyValue >& aArgs) throw(RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
- // Since the fix for #123967#, the SolarMutex is not locked anymore when the framework calls into
+ SolarMutexGuard aSolarGuard;
+ // The SolarMutex is not locked anymore when the framework calls into
// here. So, lock it ourself. The real solution would be to lock it only in the places
// where it's needed, but a) this might turn out difficult, since we then also need to care
// for locking in the proper order (SolarMutex and m_aMutex), and b) this would be too many places
// for the time frame of the fix.
- // #i52602# / frank.schoenheit@sun.com / 2005-07-29
+ // #i52602#
#ifdef TIMELOG
::rtl::OString sLog( "OGenericUnoController::dispatch( '" );
@@ -867,12 +798,12 @@ void OGenericUnoController::addStatusListener(const Reference< XStatusListener >
if ( m_xUrlTransformer.is() )
m_xUrlTransformer->parseStrict( aParsedURL );
- // remeber the listener together with the URL
+ // remember the listener together with the URL
m_arrStatusListener.insert( m_arrStatusListener.end(), DispatchTarget( aParsedURL, aListener ) );
// initially broadcast the state
ImplBroadcastFeatureState( aParsedURL.Complete, aListener, sal_True );
- // force the new state to be broadcasted to the new listener
+ // force the new state to be broadcast to the new listener
}
// -----------------------------------------------------------------------
@@ -997,7 +928,7 @@ void OGenericUnoController::implDescribeSupportedFeature( const sal_Char* _pAsci
sal_uInt16 _nFeatureId, sal_Int16 _nCommandGroup )
{
#ifdef DBG_UTIL
- DBG_ASSERT( m_bDescribingSupportedFeatures, "OGenericUnoController::implDescribeSupportedFeature: bad timing for this call!" );
+ OSL_ENSURE( m_bDescribingSupportedFeatures, "OGenericUnoController::implDescribeSupportedFeature: bad timing for this call!" );
#endif
OSL_PRECOND( _nFeatureId < FIRST_USER_DEFINED_FEATURE, "OGenericUnoController::implDescribeSupportedFeature: invalid feature id!" );
@@ -1239,7 +1170,7 @@ Reference< XFrame > SAL_CALL OGenericUnoController::getFrame(void) throw( Runtim
// -----------------------------------------------------------------------------
sal_Bool SAL_CALL OGenericUnoController::attachModel(const Reference< XModel > & /*xModel*/) throw( RuntimeException )
{
- OSL_ENSURE( false, "OGenericUnoController::attachModel: not supported!" );
+ OSL_FAIL( "OGenericUnoController::attachModel: not supported!" );
return sal_False;
}
@@ -1327,11 +1258,11 @@ namespace
"com.sun.star.formula.FormularProperties", "smath",
"com.sun.star.chart.ChartDocument", "schart"
};
- OSL_ENSURE( ( sizeof( pTransTable ) / sizeof( pTransTable[0] ) ) % 2 == 0,
+ OSL_ENSURE( ( SAL_N_ELEMENTS( pTransTable ) ) % 2 == 0,
"lcl_getModuleHelpModuleName: odd size of translation table!" );
// loop through the table
- sal_Int32 nTableEntries = ( sizeof( pTransTable ) / sizeof( pTransTable[0] ) ) / 2;
+ sal_Int32 nTableEntries = ( SAL_N_ELEMENTS( pTransTable ) ) / 2;
const sal_Char** pDocumentService = pTransTable;
const sal_Char** pHelpModuleName = pTransTable + 1;
for ( sal_Int32 j=0; j<nTableEntries; ++j )
@@ -1370,7 +1301,7 @@ namespace
pReturn = "sbasic";
else
{
- OSL_ENSURE( sal_False, "lcl_getModuleHelpModuleName: no installed module found" );
+ OSL_FAIL( "lcl_getModuleHelpModuleName: no installed module found" );
}
}
}
@@ -1391,7 +1322,7 @@ namespace
void OGenericUnoController::openHelpAgent(rtl::OUString const& _suHelpStringURL )
{
rtl::OUString suURL(_suHelpStringURL);
- rtl::OUString sLanguage = rtl::OUString::createFromAscii("Language=");
+ rtl::OUString sLanguage(RTL_CONSTASCII_USTRINGPARAM("Language="));
if (suURL.indexOf(sLanguage) == -1)
{
AppendConfigToken(suURL, sal_False /* sal_False := add '&' */ );
@@ -1454,7 +1385,7 @@ Reference< awt::XWindow> OGenericUnoController::getTopMostContainerWindow() cons
// -----------------------------------------------------------------------------
Reference< XTitle > OGenericUnoController::impl_getTitleHelper_throw()
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( ! m_xTitleHelper.is ())
@@ -1488,7 +1419,7 @@ Reference< XTitle > OGenericUnoController::impl_getTitleHelper_throw()
void SAL_CALL OGenericUnoController::setTitle(const ::rtl::OUString& sTitle)
throw (RuntimeException)
{
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
m_bExternalTitle = sal_True;
impl_getTitleHelper_throw()->setTitle (sTitle);
@@ -1571,7 +1502,7 @@ sal_uInt16 OGenericUnoController::registerCommandURL( const ::rtl::OUString& _rC
++nFeatureId;
if ( nFeatureId == LAST_USER_DEFINED_FEATURE )
{
- OSL_ENSURE( false, "OGenericUnoController::registerCommandURL: no more space for user defined features!" );
+ OSL_FAIL( "OGenericUnoController::registerCommandURL: no more space for user defined features!" );
return 0L;
}
@@ -1642,12 +1573,22 @@ Sequence< ::sal_Int16 > SAL_CALL OGenericUnoController::getSupportedCommandGroup
::std::transform( aCmdHashMap.begin(),
aCmdHashMap.end(),
aCommandGroups.getArray(),
- ::std::select1st< CommandHashMap::value_type >()
+ ::o3tl::select1st< CommandHashMap::value_type >()
);
return aCommandGroups;
}
+namespace
+{
+ //Current c++0x draft (apparently) has std::identity, but not operator()
+ template<typename T> struct SGI_identity : public std::unary_function<T,T>
+ {
+ T& operator()(T& x) const { return x; }
+ const T& operator()(const T& x) const { return x; }
+ };
+}
+
// -----------------------------------------------------------------------------
Sequence< DispatchInformation > SAL_CALL OGenericUnoController::getConfigurableDispatchInformation( ::sal_Int16 CommandGroup ) throw (RuntimeException)
{
@@ -1669,7 +1610,7 @@ Sequence< DispatchInformation > SAL_CALL OGenericUnoController::getConfigurableD
::std::transform( aInformationList.begin(),
aInformationList.end(),
aInformation.getArray(),
- ::std::identity< DispatchInformation >()
+ SGI_identity< DispatchInformation >()
);
return aInformation;
@@ -1690,8 +1631,9 @@ void OGenericUnoController::fillSupportedFeatures()
void SAL_CALL OGenericUnoController::dispose() throw(::com::sun::star::uno::RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
OGenericUnoController_Base::dispose();
}
} // namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/makefile.mk b/dbaccess/source/ui/browser/makefile.mk
deleted file mode 100644
index a7dbd7413d78..000000000000
--- a/dbaccess/source/ui/browser/makefile.mk
+++ /dev/null
@@ -1,71 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=browser
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-# --- Files --------------------------------------------------------
-
-EXCEPTIONSFILES=\
- $(SLO)$/genericcontroller.obj \
- $(SLO)$/dsbrowserDnD.obj \
- $(SLO)$/dataview.obj \
- $(SLO)$/dbexchange.obj \
- $(SLO)$/dbloader.obj \
- $(SLO)$/sbagrid.obj \
- $(SLO)$/formadapter.obj \
- $(SLO)$/brwview.obj \
- $(SLO)$/brwctrlr.obj \
- $(SLO)$/unodatbr.obj \
- $(SLO)$/sbamultiplex.obj \
- $(SLO)$/exsrcbrw.obj \
- $(SLO)$/dbtreemodel.obj \
- $(SLO)$/dsEntriesNoExp.obj \
- $(SLO)$/dbtreeview.obj
-
-SLOFILES =\
- $(EXCEPTIONSFILES)\
- $(SLO)$/AsyncronousLink.obj
-
-SRS1NAME=$(TARGET)
-SRC1FILES = sbabrw.src \
- sbagrid.src
-
-# --- Targets -------------------------------------------------------
-
-
-.INCLUDE : target.mk
-
-$(SRS)$/$(TARGET).srs: $(SOLARINCDIR)$/svx$/globlmn.hrc
-
-
diff --git a/dbaccess/source/ui/browser/sbabrw.src b/dbaccess/source/ui/browser/sbabrw.src
index 476fcf683b3f..eebcc013788d 100644
--- a/dbaccess/source/ui/browser/sbabrw.src
+++ b/dbaccess/source/ui/browser/sbabrw.src
@@ -33,7 +33,6 @@
#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
#endif
-// #include <sfx2/sfx.hrc>
#ifndef _GLOBLMN_HRC
#include <svx/globlmn.hrc>
#endif
@@ -43,14 +42,12 @@ QueryBox QUERY_BRW_SAVEMODIFIED
{
Buttons = WB_YES_NO_CANCEL ;
DefButton = WB_DEF_YES ;
- /* ### ACHTUNG: Neuer Text in Resource? Soll der geänderte Datensatz gespeichert werden? : Soll der geänderte Datensatz gespeichert werden? */
Message [ en-US ] = "The current record has been changed.\nDo you want to save the changes?" ;
};
QueryBox QUERY_BRW_DELETE_ROWS
{
Buttons = WB_YES_NO ;
- /* ### ACHTUNG: Neuer Text in Resource? Sollen die selektierten Daten gelöscht werden? : Sollen die selektierten Daten gel÷scht werden? */
Message [ en-US ] = "Do you want to delete the selected data?" ;
};
@@ -63,6 +60,7 @@ String SBA_BROWSER_SETTING_ORDER
{
Text [ en-US ] = "Error setting the sort criteria";
};
+
String SBA_BROWSER_SETTING_FILTER
{
Text [ en-US ] = "Error setting the filter criteria";
@@ -140,13 +138,13 @@ QueryBox QUERY_BRW_DELETE_QUERY_CONFIRM
{
Buttons = WB_YES_NO ;
Message [ en-US ] = "The query already exists. Do you want to delete it?" ;
- };
+};
QueryBox QUERY_CONNECTION_LOST
{
Buttons = WB_YES_NO ;
Message [ en-US ] = "The connection to the database has been lost. Do you want to reconnect?" ;
- };
+};
String STR_OPENTABLES_WARNINGS
{
@@ -161,22 +159,22 @@ String STR_OPENTABLES_WARNINGS_DETAILS
String STR_CONNECTING_DATASOURCE
{
Text [ en-US ] = "Connecting to \"$name$\" ...";
- };
+};
String STR_LOADING_QUERY
{
Text [ en-US ] = "Loading query $name$ ...";
- };
+};
String STR_LOADING_TABLE
{
Text [ en-US ] = "Loading table $name$ ...";
- };
+};
String STR_NO_TABLE_FORMAT_INSIDE
{
Text [ en-US ] = "No table format could be found." ;
- };
+};
String STR_COULDNOTCONNECT_DATASOURCE
{
@@ -200,4 +198,3 @@ Menu RID_MENU_REFRESH_DATA
};
};
};
-
diff --git a/dbaccess/source/ui/browser/sbagrid.cxx b/dbaccess/source/ui/browser/sbagrid.cxx
index 29362d14e261..cfd2bc0ec109 100644
--- a/dbaccess/source/ui/browser/sbagrid.cxx
+++ b/dbaccess/source/ui/browser/sbagrid.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,206 +29,88 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_SBA_GRID_HRC
#include "sbagrid.hrc"
-#endif
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#define ITEMID_HORJUSTIFY SID_ATTR_ALIGN_HOR_JUSTIFY
#define ITEMID_VERJUSTIFY SID_ATTR_ALIGN_VER_JUSTIFY
-//#define ITEMID_ORIENTATION SID_ATTR_ALIGN_ORIENTATION
#define ITEMID_LINEBREAK SID_ATTR_ALIGN_LINEBREAK
#define ITEMID_MARGIN SID_ATTR_ALIGN_MARGIN
#define ITEMID_NUMBERINFO SID_ATTR_NUMBERFORMAT_INFO
#define _ZFORLIST_DECLARE_TABLE
-#ifndef _SVX_NUMINF_HXX
#include <svx/numinf.hxx>
-#endif
-#ifndef _SVX_DBAEXCHANGE_HXX_
#include <svx/dbaexchange.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XEXECUTABLEDIALOG_HPP_
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
-#endif
-#ifndef _SBA_GRID_HXX
#include "sbagrid.hxx"
-#endif
-#ifndef DBAUI_SBATTRDLG_HXX
#include "dlgattr.hxx"
-#endif
-#ifndef _DBAUI_DLGSIZE_HXX
#include "dlgsize.hxx"
-#endif
-#ifndef _COM_SUN_STAR_FORM_XLOADABLE_HPP_
#include <com/sun/star/form/XLoadable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSQLQUERYCOMPOSERFACTORY_HPP_
#include <com/sun/star/sdb/XSQLQueryComposerFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XRESULTSETACCESS_HPP_
#include <com/sun/star/sdb/XResultSetAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XFORM_HPP_
#include <com/sun/star/form/XForm.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXCONTAINER_HPP_
#include <com/sun/star/container/XIndexContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_NUMBERFORMAT_HPP_
#include <com/sun/star/util/NumberFormat.hpp>
-#endif
-#ifndef _COM_SUN_STAR_VIEW_XSELECTIONSUPPLIER_HPP_
#include <com/sun/star/view/XSelectionSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_DATASELECTIONTYPE_HPP_
#include <com/sun/star/form/DataSelectionType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_TEXTALIGN_HPP_
#include <com/sun/star/awt/TextAlign.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XTEXTCOMPONENT_HPP_
#include <com/sun/star/awt/XTextComponent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_DATE_HPP_
#include <com/sun/star/util/Date.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_TIME_HPP_
#include <com/sun/star/util/Time.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_DATETIME_HPP_
#include <com/sun/star/util/DateTime.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETUPDATE_HPP_
#include <com/sun/star/sdbc/XResultSetUpdate.hpp>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef _SVX_ALGITEM_HXX //autogen
#include <svx/algitem.hxx>
-#endif
-#ifndef _SV_MULTISEL_HXX //autogen
#include <tools/multisel.hxx>
-#endif
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
-#ifndef _NUMUNO_HXX
#include <svl/numuno.hxx>
-#endif
-#ifndef _SFXITEMPOOL_HXX //autogen wg. SfxItemInfo
#include <svl/itempool.hxx>
-#endif
-#ifndef _SFXITEMSET_HXX //autogen wg. SfxItemSet
#include <svl/itemset.hxx>
-#endif
-#ifndef _SFXRNGITEM_HXX
#include <svl/rngitem.hxx>
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef _ZFORLIST_HXX
#include <svl/zforlist.hxx>
-#endif
-#ifndef _CPPUHELPER_QUERYINTERFACE_HXX_
#include <cppuhelper/queryinterface.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBHELPER_DBCONVERSION_HXX_
#include <connectivity/dbconversion.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _RTL_UUID_H_
-#include <rtl/uuid.h>
-#endif
-#ifndef _RTL_MEMORY_H_
#include <rtl/memory.h>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
+#include <comphelper/servicehelper.hxx>
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _SVX_DBEXCH_HRC
#include <svx/dbexch.hrc>
-#endif
-#ifndef _DBU_BRW_HRC_
#include "dbu_brw.hrc"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef DBAUI_DBEXCHANGE_HXX
#include "dbexchange.hxx"
-#endif
-#ifndef DBAUI_TABLEROW_EXCHANGE_HXX
#include "TableRowExchange.hxx"
-#endif
-#ifndef DBAUI_TABLEROW_HXX
#include "TableRow.hxx"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
-#ifndef _SVTOOLS_STRINGTRANSFER_HXX_
#include <svtools/stringtransfer.hxx>
-#endif
-#ifndef _VCL_STDTEXT_HXX
#include <vcl/stdtext.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_TOKENWRITER_HXX
#include "TokenWriter.hxx"
-#endif
+#include <osl/diagnose.h>
using namespace ::com::sun::star::ui::dialogs;
using namespace ::com::sun::star::uno;
@@ -278,16 +161,16 @@ Reference< XInterface > SAL_CALL SbaXGridControl::Create(const Reference<XMultiS
//------------------------------------------------------------------------------
::rtl::OUString SbaXGridControl::getImplementationName_Static() throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("com.sun.star.comp.dbu.SbaXGridControl");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.dbu.SbaXGridControl"));
}
//------------------------------------------------------------------------------
Sequence< ::rtl::OUString> SbaXGridControl::getSupportedServiceNames_Static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString> aSupported(3);
- aSupported[0] = ::rtl::OUString::createFromAscii("com.sun.star.form.control.InteractionGridControl");
- aSupported[1] = ::rtl::OUString::createFromAscii("com.sun.star.form.control.GridControl");
- aSupported[2] = ::rtl::OUString::createFromAscii("com.sun.star.awt.UnoControl");
+ aSupported[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.control.InteractionGridControl"));
+ aSupported[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.control.GridControl"));
+ aSupported[2] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.awt.UnoControl"));
return aSupported;
}
DBG_NAME(SbaXGridControl );
@@ -369,14 +252,11 @@ void SAL_CALL SbaXGridControl::createPeer(const Reference< ::com::sun::star::awt
{
FmXGridControl::createPeer(rToolkit, rParentPeer);
- DBG_ASSERT(/*(0 == m_nPeerCreationLevel) && */!mbCreatingPeer, "FmXGridControl::createPeer : recursion!");
+ OSL_ENSURE(!mbCreatingPeer, "FmXGridControl::createPeer : recursion!");
// see the base class' createPeer for a comment on this
- // 14.05.2001 - 86836 - frank.schoenheit@germany.sun.com
// TODO: why the hell this whole class does not use any mutex?
-// if (0 == m_nPeerCreationLevel)
- {
Reference< ::com::sun::star::frame::XDispatch > xDisp(getPeer(), UNO_QUERY);
for ( StatusMultiplexerArray::iterator aIter = m_aStatusMultiplexer.begin();
aIter != m_aStatusMultiplexer.end();
@@ -385,7 +265,6 @@ void SAL_CALL SbaXGridControl::createPeer(const Reference< ::com::sun::star::awt
if ((*aIter).second && (*aIter).second->getLength())
xDisp->addStatusListener((*aIter).second, (*aIter).first);
}
- }
}
//---------------------------------------------------------------------------------------
@@ -447,7 +326,7 @@ void SAL_CALL SbaXGridControl::removeStatusListener(const Reference< ::com::sun:
//---------------------------------------------------------------------------------------
void SAL_CALL SbaXGridControl::dispose(void) throw( RuntimeException )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
EventObject aEvt;
aEvt.Source = *this;
@@ -541,10 +420,10 @@ Any SAL_CALL SbaXGridPeer::queryInterface(const Type& _rType) throw (RuntimeExce
//---------------------------------------------------------------------------------------
Reference< ::com::sun::star::frame::XDispatch > SAL_CALL SbaXGridPeer::queryDispatch(const ::com::sun::star::util::URL& aURL, const ::rtl::OUString& aTargetFrameName, sal_Int32 nSearchFlags) throw( RuntimeException )
{
- if ( (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:GridSlots/BrowserAttribs")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:GridSlots/RowHeight")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:GridSlots/ColumnAttribs")))
- || (aURL.Complete.equals(::rtl::OUString::createFromAscii(".uno:GridSlots/ColumnWidth")))
+ if ( (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:GridSlots/BrowserAttribs"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:GridSlots/RowHeight"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:GridSlots/ColumnAttribs"))))
+ || (aURL.Complete.equals(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:GridSlots/ColumnWidth"))))
)
{
return (::com::sun::star::frame::XDispatch*)this;
@@ -559,7 +438,7 @@ IMPL_LINK( SbaXGridPeer, OnDispatchEvent, void*, /*NOTINTERESTEDIN*/ )
SbaGridControl* pGrid = static_cast< SbaGridControl* >( GetWindow() );
if ( pGrid ) // if this fails, we were disposing before arriving here
{
- if ( Application::GetMainThreadIdentifier() != ::vos::OThread::getCurrentIdentifier() )
+ if ( Application::GetMainThreadIdentifier() != ::osl::Thread::getCurrentIdentifier() )
{
// still not in the main thread (see SbaXGridPeer::dispatch). post an event, again
// without moving the special even to the back of the queue
@@ -581,13 +460,13 @@ IMPL_LINK( SbaXGridPeer, OnDispatchEvent, void*, /*NOTINTERESTEDIN*/ )
SbaXGridPeer::DispatchType SbaXGridPeer::classifyDispatchURL( const URL& _rURL )
{
DispatchType eURLType = dtUnknown;
- if ( _rURL.Complete.equalsAscii( ".uno:GridSlots/BrowserAttribs" ) )
+ if ( _rURL.Complete.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:GridSlots/BrowserAttribs" ) ) )
eURLType = dtBrowserAttribs;
- else if ( _rURL.Complete.equalsAscii( ".uno:GridSlots/RowHeight" ) )
+ else if ( _rURL.Complete.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:GridSlots/RowHeight" ) ) )
eURLType = dtRowHeight;
- else if ( _rURL.Complete.equalsAscii( ".uno:GridSlots/ColumnAttribs" ) )
+ else if ( _rURL.Complete.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:GridSlots/ColumnAttribs" ) ) )
eURLType = dtColumnAttribs;
- else if ( _rURL.Complete.equalsAscii( ".uno:GridSlots/ColumnWidth" ) )
+ else if ( _rURL.Complete.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( ".uno:GridSlots/ColumnWidth" ) ) )
eURLType = dtColumnWidth;
return eURLType;
}
@@ -599,7 +478,7 @@ void SAL_CALL SbaXGridPeer::dispatch(const URL& aURL, const Sequence< PropertyVa
if (!pGrid)
return;
- if ( Application::GetMainThreadIdentifier() != ::vos::OThread::getCurrentIdentifier() )
+ if ( Application::GetMainThreadIdentifier() != ::osl::Thread::getCurrentIdentifier() )
{
// we're not in the main thread. This is bad, as we want to raise windows here,
// and VCL does not like windows to be opened in non-main threads (at least on Win32).
@@ -622,22 +501,22 @@ void SAL_CALL SbaXGridPeer::dispatch(const URL& aURL, const Sequence< PropertyVa
return;
}
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
sal_Int16 nColId = -1;
const PropertyValue* pArgs = aArgs.getConstArray();
for (sal_uInt16 i=0; i<aArgs.getLength(); ++i, ++pArgs)
{
- if (pArgs->Name == ::rtl::OUString::createFromAscii("ColumnViewPos"))
+ if (pArgs->Name == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnViewPos")))
{
nColId = pGrid->GetColumnIdFromViewPos(::comphelper::getINT16(pArgs->Value));
break;
}
- if (pArgs->Name == ::rtl::OUString::createFromAscii("ColumnModelPos"))
+ if (pArgs->Name == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnModelPos")))
{
nColId = pGrid->GetColumnIdFromModelPos(::comphelper::getINT16(pArgs->Value));
break;
}
- if (pArgs->Name == ::rtl::OUString::createFromAscii("ColumnId"))
+ if (pArgs->Name == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ColumnId")))
{
nColId = ::comphelper::getINT16(pArgs->Value);
break;
@@ -665,7 +544,7 @@ void SAL_CALL SbaXGridPeer::dispatch(const URL& aURL, const Sequence< PropertyVa
case dtColumnAttribs:
{
- DBG_ASSERT(nColId != -1, "SbaXGridPeer::dispatch : invalid parameter !");
+ OSL_ENSURE(nColId != -1, "SbaXGridPeer::dispatch : invalid parameter !");
if (nColId != -1)
break;
pGrid->SetColAttrs(nColId);
@@ -674,7 +553,7 @@ void SAL_CALL SbaXGridPeer::dispatch(const URL& aURL, const Sequence< PropertyVa
case dtColumnWidth:
{
- DBG_ASSERT(nColId != -1, "SbaXGridPeer::dispatch : invalid parameter !");
+ OSL_ENSURE(nColId != -1, "SbaXGridPeer::dispatch : invalid parameter !");
if (nColId != -1)
break;
pGrid->SetColWidth(nColId);
@@ -710,24 +589,16 @@ void SAL_CALL SbaXGridPeer::removeStatusListener(const Reference< ::com::sun::st
pCont->removeInterface(xControl);
}
-//---------------------------------------------------------------------------------------
+namespace
+{
+ class theSbaXGridPeerUnoTunnelId : public rtl::Static< UnoTunnelIdInit, theSbaXGridPeerUnoTunnelId > {};
+}
+
const Sequence< sal_Int8 > & SbaXGridPeer::getUnoTunnelId()
{
- static Sequence< sal_Int8 > * pSeq = 0;
- if( !pSeq )
- {
- ::osl::Guard< ::osl::Mutex > aGuard( ::osl::Mutex::getGlobalMutex() );
- if( !pSeq )
- {
- static Sequence< sal_Int8 > aSeq( 16 );
- rtl_createUuid( (sal_uInt8*)aSeq.getArray(), 0,sal_True );
- pSeq = &aSeq;
- }
- }
- return *pSeq;
+ return theSbaXGridPeerUnoTunnelId::get().getSeq();
}
-//---------------------------------------------------------------------------------------
Sequence< Type > SAL_CALL SbaXGridPeer::getTypes() throw (RuntimeException)
{
Sequence< Type > aTypes = FmXGridPeer::getTypes();
@@ -778,7 +649,7 @@ SbaGridHeader::SbaGridHeader(BrowseBox* pParent, WinBits nWinBits)
//---------------------------------------------------------------------------------------
void SbaGridHeader::StartDrag( sal_Int8 _nAction, const Point& _rPosPixel )
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// in the new DnD API, the solar mutex is not locked when StartDrag get's called
ImplStartColumnDrag( _nAction, _rPosPixel );
@@ -793,10 +664,6 @@ void SbaGridHeader::MouseButtonDown( const MouseEvent& _rMEvt )
// the base class will start a column move here, which we don't want to allow
// (at the moment. If we store relative positions with the columns, we can allow column moves ....)
-// sal_uInt16 nPos(0);
-// sal_uInt16 nHitTest = ImplHitTest( _rMEvt.GetPosPixel(), mnMouseOff, nPos );
-// if (!nHitTest & HEAD_HITTEST_DIVIDER)
-// return;
}
FmGridHeader::MouseButtonDown(_rMEvt);
@@ -981,7 +848,7 @@ void SbaGridControl::PreExecuteRowContextMenu(sal_uInt16 nRow, PopupMenu& rMenu)
rMenu.InsertItem(ID_BROWSER_ROWHEIGHT, aNewItems.GetItemText(ID_BROWSER_ROWHEIGHT), 0, nPos++);
rMenu.SetHelpId(ID_BROWSER_ROWHEIGHT, aNewItems.GetHelpId(ID_BROWSER_ROWHEIGHT));
rMenu.InsertSeparator(nPos++);
- } // if (!IsReadOnlyDB())
+ }
if ( GetSelectRowCount() > 0 )
{
@@ -1076,7 +943,7 @@ void SbaGridControl::SetRowHeight()
}
catch(Exception&)
{
- OSL_ENSURE(0,"setPropertyValue: PROPERTY_ROW_HEIGHT throws a exception");
+ OSL_FAIL("setPropertyValue: PROPERTY_ROW_HEIGHT throws a exception");
}
}
}
@@ -1112,13 +979,13 @@ void SbaGridControl::SetBrowserAttrs()
try
{
PropertyValue aArg;
- aArg.Name = ::rtl::OUString::createFromAscii("IntrospectedObject");
+ aArg.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IntrospectedObject"));
aArg.Value <<= xGridModel;
Sequence< Any > aDialogArgs(1);
aDialogArgs[0] <<= aArg;
Reference< XInterface > xDialog = getServiceManager()->createInstanceWithArguments(
- ::rtl::OUString::createFromAscii("com.sun.star.form.ControlFontDialog"),
+ ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.ControlFontDialog")),
aDialogArgs
);
if (!xDialog.is())
@@ -1234,11 +1101,11 @@ Reference< XPropertySet > SbaGridControl::getField(sal_uInt16 nModelPos)
xEmptyReturn.set(xCol->getPropertyValue(PROPERTY_BOUNDFIELD),UNO_QUERY);
}
else
- OSL_ENSURE(0,"SbaGridControl::getField getColumns returns NULL or ModelPos is > than count!");
+ OSL_FAIL("SbaGridControl::getField getColumns returns NULL or ModelPos is > than count!");
}
catch(Exception&)
{
- OSL_ENSURE(0,"SbaGridControl::getField Exception occured!");
+ OSL_FAIL("SbaGridControl::getField Exception occurred!");
}
return xEmptyReturn;
@@ -1290,7 +1157,7 @@ void SbaGridControl::MouseButtonDown( const BrowserMouseEvent& rMEvt)
//---------------------------------------------------------------------------------------
void SbaGridControl::StartDrag( sal_Int8 _nAction, const Point& _rPosPixel )
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// in the new DnD API, the solar mutex is not locked when StartDrag get's called
sal_Bool bHandled = sal_False;
@@ -1324,14 +1191,14 @@ void SbaGridControl::StartDrag( sal_Int8 _nAction, const Point& _rPosPixel )
// check which kind of dragging has to be initiated
if ( bHitHandle // the handle column
// AND
- && ( GetSelectRowCount() // at least one row is selected
- // OR
- || ( (nRow >= 0) // a row below the header
- && !bCurrentRowVirtual // we aren't appending a new record
- && (nRow != GetCurrentPos()) // a row which is not the current one
- ) // OR
- || ( (0 == GetSelectRowCount()) // no rows selected
- && (-1 == nRow) // hit the header
+ && ( GetSelectRowCount() // at least one row is selected
+ // OR
+ || ( (nRow >= 0) // a row below the header
+ && !bCurrentRowVirtual // we aren't appending a new record
+ && (nRow != GetCurrentPos()) // a row which is not the current one
+ ) // OR
+ || ( (0 == GetSelectRowCount()) // no rows selected
+ && (-1 == nRow) // hit the header
)
)
)
@@ -1391,7 +1258,7 @@ void SbaGridControl::Command(const CommandEvent& rEvt)
void SbaGridControl::DoColumnDrag(sal_uInt16 nColumnPos)
{
Reference< XPropertySet > xDataSource(getDataSource(), UNO_QUERY);
- DBG_ASSERT(xDataSource.is(), "SbaGridControl::DoColumnDrag : invalid data source !");
+ OSL_ENSURE(xDataSource.is(), "SbaGridControl::DoColumnDrag : invalid data source !");
Reference< XPropertySet > xAffectedCol;
Reference< XPropertySet > xAffectedField;
@@ -1414,7 +1281,7 @@ void SbaGridControl::DoColumnDrag(sal_uInt16 nColumnPos)
}
catch(Exception&)
{
- DBG_ERROR("SbaGridControl::DoColumnDrag : something went wrong while getting the column");
+ OSL_FAIL("SbaGridControl::DoColumnDrag : something went wrong while getting the column");
}
if (0 == sField.getLength())
return;
@@ -1427,7 +1294,7 @@ void SbaGridControl::DoColumnDrag(sal_uInt16 nColumnPos)
// -----------------------------------------------------------------------
void SbaGridControl::CopySelectedRowsToClipboard()
{
- DBG_ASSERT( GetSelectRowCount() > 0, "SbaGridControl::CopySelectedRowsToClipboard: invalid call!" );
+ OSL_ENSURE( GetSelectRowCount() > 0, "SbaGridControl::CopySelectedRowsToClipboard: invalid call!" );
implTransferSelectedRows( (sal_Int16)FirstSelectedRow(), true );
}
@@ -1441,7 +1308,7 @@ void SbaGridControl::DoRowDrag( sal_Int16 nRowPos )
void SbaGridControl::implTransferSelectedRows( sal_Int16 nRowPos, bool _bTrueIfClipboardFalseIfDrag )
{
Reference< XPropertySet > xForm( getDataSource(), UNO_QUERY );
- DBG_ASSERT( xForm.is(), "SbaGridControl::implTransferSelectedRows: invalid form!" );
+ OSL_ENSURE( xForm.is(), "SbaGridControl::implTransferSelectedRows: invalid form!" );
// build the sequence of numbers of selected rows
Sequence< Any > aSelectedRows;
@@ -1497,7 +1364,7 @@ void SbaGridControl::DoFieldDrag(sal_uInt16 nColumnPos, sal_Int16 nRowPos)
}
catch(Exception&)
{
- DBG_ERROR("SbaGridControl::DoFieldDrag : could not retrieve the cell's contents !");
+ OSL_FAIL("SbaGridControl::DoFieldDrag : could not retrieve the cell's contents !");
return;
}
@@ -1515,8 +1382,6 @@ void SbaGridControl::DoFieldDrag(sal_uInt16 nColumnPos, sal_Int16 nRowPos)
{
switch (_aType.mnSotId)
{
-// case SOT_FORMAT_RTF: // RTF data descriptions
-// case SOT_FORMATSTR_ID_HTML: // HTML data descriptions
case SOT_FORMATSTR_ID_DBACCESS_TABLE: // table descriptor
case SOT_FORMATSTR_ID_DBACCESS_QUERY: // query descriptor
case SOT_FORMATSTR_ID_DBACCESS_COMMAND: // SQL command
@@ -1658,7 +1523,7 @@ sal_Int8 SbaGridControl::ExecuteDrop( const BrowserExecuteDropEvent& rEvt )
if (IsCurrentAppending())
--nCorrectRowCount; // the current data record doesn't really exist, we are appending a new one
- DBG_ASSERT((nCol != BROWSER_INVALIDID) && (nRow < nCorrectRowCount), "SbaGridControl::Drop : dropped on an invalid position !");
+ OSL_ENSURE((nCol != BROWSER_INVALIDID) && (nRow < nCorrectRowCount), "SbaGridControl::Drop : dropped on an invalid position !");
// AcceptDrop should have caught this
// from now we work with ids instead of positions
@@ -1770,7 +1635,7 @@ IMPL_LINK(SbaGridControl, AsynchDropEvent, void*, /*EMPTY_ARG*/)
::rtl::OUString sRet;
if ( ::svt::BBTYPE_BROWSEBOX == eObjType )
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
sRet = String(ModuleRes(STR_DATASOURCE_GRIDCONTROL_DESC));
}
else
@@ -1784,3 +1649,4 @@ void SbaGridControl::DeleteSelectedRows()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/sbagrid.src b/dbaccess/source/ui/browser/sbagrid.src
index 1362944d5847..b3fd77757364 100644
--- a/dbaccess/source/ui/browser/sbagrid.src
+++ b/dbaccess/source/ui/browser/sbagrid.src
@@ -102,10 +102,12 @@ String STR_QRY_TITLE
{
Text [ en-US ] = "Query #" ;
};
+
String STR_TBL_TITLE
{
Text [ en-US ] = "Table #" ;
};
+
String STR_VIEW_TITLE
{
Text [ en-US ] = "View #" ;
@@ -122,7 +124,7 @@ String STR_NO_COLUMNNAME_MATCHING
Text [ en-US ] = "No matching column names were found.";
};
-String STR_ERROR_OCCURED_WHILE_COPYING
+String STR_ERROR_OCCURRED_WHILE_COPYING
{
Text [ en-US ] = "An error occurred. Do you want to continue copying?";
};
@@ -136,4 +138,3 @@ String STR_DATASOURCE_GRIDCONTROL_DESC
{
Text [ en-US ] = "Shows the selected table or query.";
};
-
diff --git a/dbaccess/source/ui/browser/sbamultiplex.cxx b/dbaccess/source/ui/browser/sbamultiplex.cxx
index a3986ad7117e..a37722ff489b 100644
--- a/dbaccess/source/ui/browser/sbamultiplex.cxx
+++ b/dbaccess/source/ui/browser/sbamultiplex.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _SBA_MULTIPLEX_HXX
#include "sbamultiplex.hxx"
-#endif
using namespace dbaui;
//==================================================================
@@ -109,3 +108,4 @@ void SbaXPropertiesChangeMultiplexer::propertiesChange(const ::com::sun::star::u
((::com::sun::star::beans::XPropertiesChangeListener*)aIt.next())->propertiesChange(aMulti);
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx
index 2a3fdd428ade..0da24c5a3f9a 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -122,9 +123,9 @@
#include <svx/algitem.hxx>
#include <svx/dataaccessdescriptor.hxx>
#include <svx/databaseregistrationui.hxx>
-#include <svx/gridctrl.hxx>
#include <toolkit/unohlp.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <tools/multisel.hxx>
#include <tools/urlobj.hxx>
#include <unotools/confignode.hxx>
@@ -207,19 +208,19 @@ void SafeRemovePropertyListener(const Reference< XPropertySet > & xSet, const ::
// -------------------------------------------------------------------------
::rtl::OUString SbaTableQueryBrowser::getImplementationName_Static() throw(RuntimeException)
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.ODatasourceBrowser");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.ODatasourceBrowser"));
}
//-------------------------------------------------------------------------
::comphelper::StringSequence SbaTableQueryBrowser::getSupportedServiceNames_Static() throw(RuntimeException)
{
::comphelper::StringSequence aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.DataSourceBrowser");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.DataSourceBrowser"));
return aSupported;
}
//-------------------------------------------------------------------------
Reference< XInterface > SAL_CALL SbaTableQueryBrowser::Create(const Reference<XMultiServiceFactory >& _rxFactory)
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
return *(new SbaTableQueryBrowser(_rxFactory));
}
@@ -250,7 +251,7 @@ SbaTableQueryBrowser::~SbaTableQueryBrowser()
DBG_DTOR(SbaTableQueryBrowser,NULL);
if ( !rBHelper.bDisposed && !rBHelper.bInDispose )
{
- OSL_ENSURE(0,"Please check who doesn't dispose this component!");
+ OSL_FAIL("Please check who doesn't dispose this component!");
// increment ref count to prevent double call of Dtor
osl_incrementInterlockedCount( &m_refCount );
dispose();
@@ -316,7 +317,7 @@ Sequence< sal_Int8 > SAL_CALL SbaTableQueryBrowser::getImplementationId( ) thro
//------------------------------------------------------------------------------
void SAL_CALL SbaTableQueryBrowser::disposing()
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// doin' a lot of VCL stuff here -> lock the SolarMutex
// kiss our listeners goodbye
@@ -370,12 +371,12 @@ sal_Bool SbaTableQueryBrowser::Construct(Window* pParent)
xDatabaseRegistrations->addDatabaseRegistrationsListener( this );
// the collator for the string compares
- m_xCollator = Reference< XCollator >( getORB()->createInstance(::rtl::OUString::createFromAscii( "com.sun.star.i18n.Collator" ) ), UNO_QUERY_THROW );
+ m_xCollator = Reference< XCollator >( getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.i18n.Collator")) ), UNO_QUERY_THROW );
m_xCollator->loadDefaultCollator( Application::GetSettings().GetLocale(), 0 );
}
- catch(Exception&)
+ catch(const Exception&)
{
- DBG_ERROR("SbaTableQueryBrowser::Construct: could not create (or start listening at) the database context!");
+ OSL_FAIL("SbaTableQueryBrowser::Construct: could not create (or start listening at) the database context!");
}
// some help ids
if (getBrowserView() && getBrowserView()->getVclControl())
@@ -744,7 +745,7 @@ sal_Bool SbaTableQueryBrowser::InitializeGridModel(const Reference< ::com::sun::
case DataType::BIT:
case DataType::BOOLEAN:
{
- aCurrentModelType = ::rtl::OUString::createFromAscii("CheckBox");
+ aCurrentModelType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CheckBox"));
aInitialValues.push_back( NamedValue( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "VisualEffect" ) ), makeAny( VisualEffect::FLAT ) ) );
sDefaultProperty = PROPERTY_DEFAULTSTATE;
@@ -766,7 +767,7 @@ sal_Bool SbaTableQueryBrowser::InitializeGridModel(const Reference< ::com::sun::
case DataType::BINARY:
case DataType::VARBINARY:
case DataType::LONGVARBINARY:
- aCurrentModelType = ::rtl::OUString::createFromAscii("TextField");
+ aCurrentModelType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TextField"));
sDefaultProperty = PROPERTY_DEFAULTTEXT;
break;
@@ -775,12 +776,12 @@ sal_Bool SbaTableQueryBrowser::InitializeGridModel(const Reference< ::com::sun::
bFormattedIsNumeric = sal_False;
// NO break!
default:
- aCurrentModelType = ::rtl::OUString::createFromAscii("FormattedField");
+ aCurrentModelType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FormattedField"));
sDefaultProperty = PROPERTY_EFFECTIVEDEFAULT;
if ( xSupplier.is() )
- aInitialValues.push_back( NamedValue( ::rtl::OUString::createFromAscii( "FormatsSupplier" ), makeAny( xSupplier ) ) );
- aInitialValues.push_back( NamedValue( ::rtl::OUString::createFromAscii( "TreatAsNumber" ), makeAny( (sal_Bool)bFormattedIsNumeric ) ) );
+ aInitialValues.push_back( NamedValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FormatsSupplier")), makeAny( xSupplier ) ) );
+ aInitialValues.push_back( NamedValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TreatAsNumber")), makeAny( (sal_Bool)bFormattedIsNumeric ) ) );
aCopyProperties.push_back( PROPERTY_FORMATKEY );
break;
}
@@ -858,7 +859,7 @@ sal_Bool SbaTableQueryBrowser::InitializeGridModel(const Reference< ::com::sun::
}
}
}
- catch(Exception&)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
return sal_False;
@@ -1007,7 +1008,7 @@ void SbaTableQueryBrowser::propertyChange(const PropertyChangeEvent& evt) throw(
// -----------------------------------------------------------------------
sal_Bool SbaTableQueryBrowser::suspend(sal_Bool bSuspend) throw( RuntimeException )
{
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( getView() && getView()->IsInModalMode() )
return sal_False;
@@ -1041,7 +1042,7 @@ void SAL_CALL SbaTableQueryBrowser::statusChanged( const FeatureStateEvent& _rEv
{
if ( _rEvent.FeatureURL.Complete == aLoop->second.aURL.Complete)
{
- DBG_ASSERT( xSource.get() == aLoop->second.xDispatcher.get(), "SbaTableQueryBrowser::statusChanged: inconsistent!" );
+ OSL_ENSURE( xSource.get() == aLoop->second.xDispatcher.get(), "SbaTableQueryBrowser::statusChanged: inconsistent!" );
// update the enabled state
aLoop->second.bEnabled = _rEvent.IsEnabled;
@@ -1079,7 +1080,7 @@ void SAL_CALL SbaTableQueryBrowser::statusChanged( const FeatureStateEvent& _rEv
}
}
- DBG_ASSERT(aLoop != m_aExternalFeatures.end(), "SbaTableQueryBrowser::statusChanged: don't know who sent this!");
+ OSL_ENSURE(aLoop != m_aExternalFeatures.end(), "SbaTableQueryBrowser::statusChanged: don't know who sent this!");
}
// -------------------------------------------------------------------------
@@ -1092,7 +1093,7 @@ void SbaTableQueryBrowser::checkDocumentDataSource()
if (!bKnownDocDataSource)
{
if (NULL != pDataSourceEntry)
- { // at least the data source is know
+ { // at least the data source is known
if (NULL != pContainerEntry)
bKnownDocDataSource = sal_True; // assume we know it.
// TODO: should we expand the object container? This may be too expensive just for checking ....
@@ -1143,7 +1144,6 @@ namespace
if ( aURL.GetProtocol() != INET_PROT_NOT_VALID )
{
_rDisplayName = aURL.getBase(INetURLObject::LAST_SEGMENT,true,INetURLObject::DECODE_WITH_CHARSET);
- // _rDisplayName = aURL.getName(INetURLObject::LAST_SEGMENT,true,INetURLObject::DECODE_WITH_CHARSET);
_rUniqueId = aURL.GetMainURL( INetURLObject::NO_DECODE );
return true;
}
@@ -1173,11 +1173,11 @@ namespace
// -------------------------------------------------------------------------
String SbaTableQueryBrowser::getDataSourceAcessor( SvLBoxEntry* _pDataSourceEntry ) const
{
- DBG_ASSERT( _pDataSourceEntry, "SbaTableQueryBrowser::getDataSourceAcessor: invalid entry!" );
+ OSL_ENSURE( _pDataSourceEntry, "SbaTableQueryBrowser::getDataSourceAcessor: invalid entry!" );
DBTreeListUserData* pData = static_cast< DBTreeListUserData* >( _pDataSourceEntry->GetUserData() );
- DBG_ASSERT( pData, "SbaTableQueryBrowser::getDataSourceAcessor: invalid entry data!" );
- DBG_ASSERT( pData->eType == etDatasource, "SbaTableQueryBrowser::getDataSourceAcessor: entry does not denote a data source!" );
+ OSL_ENSURE( pData, "SbaTableQueryBrowser::getDataSourceAcessor: invalid entry data!" );
+ OSL_ENSURE( pData->eType == etDatasource, "SbaTableQueryBrowser::getDataSourceAcessor: entry does not denote a data source!" );
return pData->sAccessor.Len() ? pData->sAccessor : GetEntryText( _pDataSourceEntry );
}
@@ -1198,7 +1198,7 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataS
String sDisplayName, sDataSourceId;
bool bIsDataSourceURL = getDataSourceDisplayName_isURL( _rDataSource, sDisplayName, sDataSourceId );
// the display name may differ from the URL for readability reasons
- // #i33699# - 2004-09-24 - fs@openoffice.org
+ // #i33699#
FilterByEntryDataId aFilter( sDataSourceId );
SvLBoxEntry* pDataSource = m_pTreeView->getListBox().GetEntryPosByName( sDisplayName, NULL, &aFilter );
@@ -1210,7 +1210,7 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataS
// add new entries to the list box model
implAddDatasource( _rDataSource, _rxConnection );
pDataSource = m_pTreeView->getListBox().GetEntryPosByName( sDisplayName, NULL, &aFilter );
- DBG_ASSERT( pDataSource, "SbaTableQueryBrowser::getObjectEntry: hmm - did not find it again!" );
+ OSL_ENSURE( pDataSource, "SbaTableQueryBrowser::getObjectEntry: hmm - did not find it again!" );
}
}
if (_ppDataSourceEntry)
@@ -1280,13 +1280,12 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::rtl::OUString& _rDataS
}
}
}
- catch(Exception&)
+ catch(const Exception&)
{
- DBG_ERROR("SbaTableQueryBrowser::populateTree: could not fill the tree");
+ OSL_FAIL("SbaTableQueryBrowser::populateTree: could not fill the tree");
}
}
}
- // m_pTreeView->getListBox().Expand(pCommandType);
}
while ( nIndex >= 0 );
}
@@ -1314,7 +1313,7 @@ SvLBoxEntry* SbaTableQueryBrowser::getObjectEntry(const ::svx::ODataAccessDescri
void SbaTableQueryBrowser::connectExternalDispatches()
{
Reference< XDispatchProvider > xProvider( getFrame(), UNO_QUERY );
- DBG_ASSERT(xProvider.is(), "SbaTableQueryBrowser::connectExternalDispatches: no DispatchProvider !");
+ OSL_ENSURE(xProvider.is(), "SbaTableQueryBrowser::connectExternalDispatches: no DispatchProvider !");
if (xProvider.is())
{
if ( m_aExternalFeatures.empty() )
@@ -1332,7 +1331,7 @@ void SbaTableQueryBrowser::connectExternalDispatches()
ID_BROWSER_INSERTCONTENT
};
- for ( size_t i=0; i < sizeof( pURLs ) / sizeof( pURLs[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( pURLs ); ++i )
{
URL aURL;
aURL.Complete = ::rtl::OUString::createFromAscii( pURLs[i] );
@@ -1348,12 +1347,12 @@ void SbaTableQueryBrowser::connectExternalDispatches()
)
{
feature->second.xDispatcher = xProvider->queryDispatch(
- feature->second.aURL, ::rtl::OUString::createFromAscii("_parent"), FrameSearchFlag::PARENT
+ feature->second.aURL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_parent")), FrameSearchFlag::PARENT
);
if ( feature->second.xDispatcher.get() == static_cast< XDispatch* >( this ) )
{
- OSL_ENSURE( sal_False, "SbaTableQueryBrowser::connectExternalDispatches: this should not happen anymore!" );
+ OSL_FAIL( "SbaTableQueryBrowser::connectExternalDispatches: this should not happen anymore!" );
// (nowadays, the URLs aren't in our SupportedFeatures list anymore, so we should
// not supply a dispatcher for this)
feature->second.xDispatcher.clear();
@@ -1445,7 +1444,7 @@ void SAL_CALL SbaTableQueryBrowser::disposing( const ::com::sun::star::lang::Eve
DBTreeListUserData* pData = static_cast<DBTreeListUserData*>(pDSLoop->GetUserData());
if ( pData && pData->xConnection == xCon )
{
- // we set the conenction to null to avoid a second disposing of the connection
+ // we set the connection to null to avoid a second disposing of the connection
pData->xConnection.clear();
closeConnection(pDSLoop,sal_False);
break;
@@ -1477,7 +1476,7 @@ void SbaTableQueryBrowser::implRemoveStatusListeners()
}
catch (Exception&)
{
- DBG_ERROR("SbaTableQueryBrowser::implRemoveStatusListeners: could not remove a status listener!");
+ OSL_FAIL("SbaTableQueryBrowser::implRemoveStatusListeners: could not remove a status listener!");
}
}
}
@@ -1487,7 +1486,7 @@ void SbaTableQueryBrowser::implRemoveStatusListeners()
// -------------------------------------------------------------------------
sal_Bool SAL_CALL SbaTableQueryBrowser::select( const Any& _rSelection ) throw (IllegalArgumentException, RuntimeException)
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// doin' a lot of VCL stuff here -> lock the SolarMutex
Sequence< PropertyValue > aDescriptorSequence;
@@ -1502,7 +1501,7 @@ sal_Bool SAL_CALL SbaTableQueryBrowser::select( const Any& _rSelection ) throw (
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::select: could not extract the descriptor!");
+ OSL_FAIL("SbaTableQueryBrowser::select: could not extract the descriptor!");
}
// check the precense of the props we need
@@ -1565,7 +1564,7 @@ void SbaTableQueryBrowser::attachFrame(const Reference< ::com::sun::star::frame:
Reference< XFrame > xCurrentFrame( getFrame() );
if ( xCurrentFrame.is() )
{
- m_xCurrentFrameParent = xCurrentFrame->findFrame(::rtl::OUString::createFromAscii("_parent"),FrameSearchFlag::PARENT);
+ m_xCurrentFrameParent = xCurrentFrame->findFrame(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("_parent")),FrameSearchFlag::PARENT);
if ( m_xCurrentFrameParent.is() )
m_xCurrentFrameParent->addFrameActionListener((::com::sun::star::frame::XFrameActionListener*)this);
@@ -1822,7 +1821,6 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
aReturn.bEnabled = aReturn.bEnabled && getBrowserView()->getVclControl()->GetSelectRowCount();
// disabled for native queries which are not saved within the database
- // 67706 - 23.08.99 - FS
Reference< XPropertySet > xDataSource(getRowSet(), UNO_QUERY);
try
{
@@ -1836,7 +1834,7 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
}
catch(DisposedException&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::GetState: object already disposed!");
+ OSL_FAIL("SbaTableQueryBrowser::GetState: object already disposed!");
}
catch( const Exception& )
{
@@ -1859,7 +1857,7 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
case CommandType::COMMAND:
sTitle = String(ModuleRes(STR_QRY_TITLE)); break;
default:
- DBG_ASSERT(sal_False, "SbaTableQueryBrowser::GetState: unknown command type!");
+ OSL_FAIL("SbaTableQueryBrowser::GetState: unknown command type!");
}
::rtl::OUString aName;
xProp->getPropertyValue(PROPERTY_COMMAND) >>= aName;
@@ -1887,7 +1885,7 @@ FeatureState SbaTableQueryBrowser::GetState(sal_uInt16 nId) const
{
aReturn.bEnabled = m_aCurrentFrame.isActive();
break;
- } // if ( getBrowserView()->getVclControl()->GetSelectRowCount() )
+ }
else
aReturn.bEnabled = pControl->canCopyCellText(pControl->GetCurRow(), pControl->GetCurColumnId());
break;
@@ -2012,7 +2010,7 @@ void SbaTableQueryBrowser::Execute(sal_uInt16 nId, const Sequence< PropertyValue
if ( !pGrid->IsAllSelected() )
{ // transfer the selected rows only if not all rows are selected
// (all rows means the whole table)
- // i3832 - 03.04.2002 - fs@openoffice.org
+ // #i3832#
if (pSelection != NULL)
{
aSelection.realloc(pSelection->GetSelectCount());
@@ -2035,11 +2033,11 @@ void SbaTableQueryBrowser::Execute(sal_uInt16 nId, const Sequence< PropertyValue
}
catch(DisposedException&)
{
- OSL_ENSURE(0,"Object already disposed!");
+ OSL_FAIL("Object already disposed!");
}
- catch(Exception&)
+ catch(const Exception&)
{
- DBG_ERROR("SbaTableQueryBrowser::Execute(ID_BROWSER_?): could not clone the cursor!");
+ OSL_FAIL("SbaTableQueryBrowser::Execute(ID_BROWSER_?): could not clone the cursor!");
}
Reference<XPropertySet> xProp(getRowSet(),UNO_QUERY);
@@ -2108,7 +2106,7 @@ void SbaTableQueryBrowser::implAddDatasource(const String& _rDbName, Image& _rDb
String& _rQueryName, Image& _rQueryImage, String& _rTableName, Image& _rTableImage,
const SharedConnection& _rxConnection)
{
- vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// initialize the names/images if necessary
if (!_rQueryName.Len())
_rQueryName = String(ModuleRes(RID_STR_QUERIES_CONTAINER));
@@ -2117,16 +2115,16 @@ void SbaTableQueryBrowser::implAddDatasource(const String& _rDbName, Image& _rDb
ImageProvider aImageProvider;
if (!_rQueryImage)
- _rQueryImage = aImageProvider.getFolderImage( DatabaseObject::QUERY, isHiContrast() );
+ _rQueryImage = aImageProvider.getFolderImage( DatabaseObject::QUERY );
if (!_rTableImage)
- _rTableImage = aImageProvider.getFolderImage( DatabaseObject::TABLE, isHiContrast() );
+ _rTableImage = aImageProvider.getFolderImage( DatabaseObject::TABLE );
if (!_rDbImage)
- _rDbImage = aImageProvider.getDatabaseImage( isHiContrast() );
+ _rDbImage = aImageProvider.getDatabaseImage();
// add the entry for the data source
// special handling for data sources denoted by URLs - we do not want to display this ugly URL, do we?
- // #i33699# - 2004-09-24 - fs@openoffice.org
+ // #i33699#
String sDSDisplayName, sDataSourceId;
getDataSourceDisplayName_isURL( _rDbName, sDSDisplayName, sDataSourceId );
@@ -2203,9 +2201,9 @@ void SbaTableQueryBrowser::populateTree(const Reference<XNameAccess>& _xNameAcce
}
}
}
- catch(Exception&)
+ catch(const Exception&)
{
- DBG_ERROR("SbaTableQueryBrowser::populateTree: could not fill the tree");
+ OSL_FAIL("SbaTableQueryBrowser::populateTree: could not fill the tree");
}
}
@@ -2214,15 +2212,13 @@ SvLBoxEntry* SbaTableQueryBrowser::implAppendEntry( SvLBoxEntry* _pParent, const
{
::std::auto_ptr< ImageProvider > pImageProvider( getImageProviderFor( _pParent ) );
- Image aImage, aImageHC;
- pImageProvider->getImages( _rName, getDatabaseObjectType( _eEntryType ), aImage, aImageHC );
+ Image aImage;
+ pImageProvider->getImages( _rName, getDatabaseObjectType( _eEntryType ), aImage );
SvLBoxEntry* pNewEntry = m_pTreeView->getListBox().InsertEntry( _rName, _pParent, _eEntryType == etQueryContainer , LIST_APPEND, _pUserData );
- m_pTreeView->getListBox().SetExpandedEntryBmp( pNewEntry, aImage, BMP_COLOR_NORMAL );
- m_pTreeView->getListBox().SetCollapsedEntryBmp( pNewEntry, aImage, BMP_COLOR_NORMAL );
- m_pTreeView->getListBox().SetExpandedEntryBmp( pNewEntry, aImageHC, BMP_COLOR_HIGHCONTRAST );
- m_pTreeView->getListBox().SetCollapsedEntryBmp( pNewEntry, aImageHC, BMP_COLOR_HIGHCONTRAST );
+ m_pTreeView->getListBox().SetExpandedEntryBmp( pNewEntry, aImage );
+ m_pTreeView->getListBox().SetCollapsedEntryBmp( pNewEntry, aImage );
return pNewEntry;
}
@@ -2304,7 +2300,7 @@ IMPL_LINK(SbaTableQueryBrowser, OnExpandEntry, SvLBoxEntry*, _pParent)
if(e.TargetException >>= aSql)
aInfo = aSql;
else
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::OnExpandEntry: something strange happended!");
+ OSL_FAIL("SbaTableQueryBrowser::OnExpandEntry: something strange happended!");
}
catch( const Exception& )
{
@@ -2315,7 +2311,7 @@ IMPL_LINK(SbaTableQueryBrowser, OnExpandEntry, SvLBoxEntry*, _pParent)
}
else
return 0L;
- // 0 indicates that an error occured
+ // 0 indicates that an error occurred
}
else
{ // we have to expand the queries or bookmarks
@@ -2332,7 +2328,7 @@ IMPL_LINK(SbaTableQueryBrowser, OnExpandEntry, SvLBoxEntry*, _pParent)
//------------------------------------------------------------------------------
sal_Bool SbaTableQueryBrowser::ensureEntryObject( SvLBoxEntry* _pEntry )
{
- DBG_ASSERT(_pEntry, "SbaTableQueryBrowser::ensureEntryObject: invalid argument!");
+ OSL_ENSURE(_pEntry, "SbaTableQueryBrowser::ensureEntryObject: invalid argument!");
if (!_pEntry)
return sal_False;
@@ -2394,7 +2390,7 @@ sal_Bool SbaTableQueryBrowser::ensureEntryObject( SvLBoxEntry* _pEntry )
bSuccess = pEntryData->xContainer.is();
}
else {
- DBG_ERROR("SbaTableQueryBrowser::ensureEntryObject: no XQueryDefinitionsSupplier interface!");
+ OSL_FAIL("SbaTableQueryBrowser::ensureEntryObject: no XQueryDefinitionsSupplier interface!");
}
}
catch( const Exception& )
@@ -2406,7 +2402,7 @@ sal_Bool SbaTableQueryBrowser::ensureEntryObject( SvLBoxEntry* _pEntry )
break;
default:
- DBG_ERROR("SbaTableQueryBrowser::ensureEntryObject: ooops ... missing some implementation here!");
+ OSL_FAIL("SbaTableQueryBrowser::ensureEntryObject: ooops ... missing some implementation here!");
// TODO ...
break;
}
@@ -2503,7 +2499,7 @@ sal_Bool SbaTableQueryBrowser::implLoadAnything(const ::rtl::OUString& _rDataSou
DBG_UNHANDLED_EXCEPTION();
}
}
- catch(Exception&)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -2777,12 +2773,12 @@ bool SbaTableQueryBrowser::implSelect( SvLBoxEntry* _pEntry )
if(e.TargetException >>= aSql)
showError(SQLExceptionInfo(aSql));
else
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::implSelect: something strange happended!");
+ OSL_FAIL("SbaTableQueryBrowser::implSelect: something strange happended!");
// reset the values
xRowSetProps->setPropertyValue(PROPERTY_DATASOURCENAME,Any());
xRowSetProps->setPropertyValue(PROPERTY_ACTIVE_CONNECTION,Any());
}
- catch(Exception&)
+ catch(const Exception&)
{
// reset the values
xRowSetProps->setPropertyValue(PROPERTY_DATASOURCENAME,Any());
@@ -2819,7 +2815,7 @@ SvLBoxEntry* SbaTableQueryBrowser::getEntryFromContainer(const Reference<XNameAc
// -------------------------------------------------------------------------
void SAL_CALL SbaTableQueryBrowser::elementInserted( const ContainerEvent& _rEvent ) throw(RuntimeException)
{
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
Reference< XNameAccess > xNames(_rEvent.Source, UNO_QUERY);
// first search for a definition container where we can insert this element
@@ -2864,7 +2860,7 @@ sal_Bool SbaTableQueryBrowser::isCurrentlyDisplayedChanged(const String& _sName,
// -------------------------------------------------------------------------
void SAL_CALL SbaTableQueryBrowser::elementRemoved( const ContainerEvent& _rEvent ) throw(RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
Reference< XNameAccess > xNames(_rEvent.Source, UNO_QUERY);
// get the top-level representing the removed data source
@@ -2917,7 +2913,7 @@ void SAL_CALL SbaTableQueryBrowser::elementRemoved( const ContainerEvent& _rEven
// -------------------------------------------------------------------------
void SAL_CALL SbaTableQueryBrowser::elementReplaced( const ContainerEvent& _rEvent ) throw(RuntimeException)
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
Reference< XNameAccess > xNames(_rEvent.Source, UNO_QUERY);
SvLBoxEntry* pContainer = getEntryFromContainer(xNames);
@@ -2978,7 +2974,7 @@ void SAL_CALL SbaTableQueryBrowser::elementReplaced( const ContainerEvent& _rEve
}
else if (xNames.get() == m_xDatabaseContext.get())
{ // a datasource has been replaced in the context
- DBG_ERROR("SbaTableQueryBrowser::elementReplaced: no support for replaced data sources!");
+ OSL_FAIL("SbaTableQueryBrowser::elementReplaced: no support for replaced data sources!");
// very suspicious: the database context should not allow to replace data source, only to register
// and revoke them
}
@@ -3017,8 +3013,8 @@ void SbaTableQueryBrowser::impl_releaseConnection( SharedConnection& _rxConnecti
// -------------------------------------------------------------------------
void SbaTableQueryBrowser::disposeConnection( SvLBoxEntry* _pDSEntry )
{
- DBG_ASSERT( _pDSEntry, "SbaTableQueryBrowser::disposeConnection: invalid entry (NULL)!" );
- DBG_ASSERT( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::disposeConnection: invalid entry (not top-level)!" );
+ OSL_ENSURE( _pDSEntry, "SbaTableQueryBrowser::disposeConnection: invalid entry (NULL)!" );
+ OSL_ENSURE( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::disposeConnection: invalid entry (not top-level)!" );
if ( _pDSEntry )
{
@@ -3031,8 +3027,8 @@ void SbaTableQueryBrowser::disposeConnection( SvLBoxEntry* _pDSEntry )
// -------------------------------------------------------------------------
void SbaTableQueryBrowser::closeConnection(SvLBoxEntry* _pDSEntry,sal_Bool _bDisposeConnection)
{
- DBG_ASSERT(_pDSEntry, "SbaTableQueryBrowser::closeConnection: invalid entry (NULL)!");
- DBG_ASSERT( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::closeConnection: invalid entry (not top-level)!");
+ OSL_ENSURE(_pDSEntry, "SbaTableQueryBrowser::closeConnection: invalid entry (NULL)!");
+ OSL_ENSURE( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::closeConnection: invalid entry (not top-level)!");
// if one of the entries of the given DS is displayed currently, unload the form
if (m_pCurrentlyDisplayed && (m_pTreeView->getListBox().GetRootLevelParent(m_pCurrentlyDisplayed) == _pDSEntry))
@@ -3116,11 +3112,11 @@ void SbaTableQueryBrowser::unloadAndCleanup( sal_Bool _bDisposeConnection )
if(e.TargetException >>= aSql)
showError(SQLExceptionInfo(aSql));
else
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::unloadAndCleanup: something strange happended!");
+ OSL_FAIL("SbaTableQueryBrowser::unloadAndCleanup: something strange happended!");
}
- catch(Exception&)
+ catch(const Exception&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::unloadAndCleanup: could not reset the form");
+ OSL_FAIL("SbaTableQueryBrowser::unloadAndCleanup: could not reset the form");
}
}
@@ -3154,7 +3150,7 @@ namespace
// -------------------------------------------------------------------------
void SbaTableQueryBrowser::impl_initialize()
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// doin' a lot of VCL stuff here -> lock the SolarMutex
// first initialize the parent
@@ -3229,7 +3225,7 @@ void SbaTableQueryBrowser::impl_initialize()
if ( xFormMultiSet.is() )
xFormMultiSet->setPropertyValues(aProperties, aValues);
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -3281,7 +3277,7 @@ void SbaTableQueryBrowser::impl_initialize()
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "SbaTableQueryBrowser::impl_initialize: a connection parent which does not have a 'Name'!??" );
+ OSL_FAIL( "SbaTableQueryBrowser::impl_initialize: a connection parent which does not have a 'Name'!??" );
}
}
}
@@ -3318,7 +3314,7 @@ void SbaTableQueryBrowser::impl_initialize()
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "SbaTableQueryBrowser::impl_initialize: could not set the update related names!");
+ OSL_FAIL("SbaTableQueryBrowser::impl_initialize: could not set the update related names!");
}
}
@@ -3397,7 +3393,7 @@ sal_Bool SbaTableQueryBrowser::getExistentConnectionFor( SvLBoxEntry* _pAnyEntry
return _rConnection.is();
}
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
// -----------------------------------------------------------------------------
bool SbaTableQueryBrowser::impl_isDataSourceEntry( SvLBoxEntry* _pEntry ) const
{
@@ -3408,7 +3404,7 @@ bool SbaTableQueryBrowser::impl_isDataSourceEntry( SvLBoxEntry* _pEntry ) const
// -----------------------------------------------------------------------------
sal_Bool SbaTableQueryBrowser::ensureConnection( SvLBoxEntry* _pDSEntry, void* pDSData, SharedConnection& _rConnection )
{
- DBG_ASSERT( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::ensureConnection: this entry does not denote a data source!" );
+ OSL_ENSURE( impl_isDataSourceEntry( _pDSEntry ), "SbaTableQueryBrowser::ensureConnection: this entry does not denote a data source!" );
if(_pDSEntry)
{
DBTreeListUserData* pTreeListData = static_cast<DBTreeListUserData*>(pDSData);
@@ -3447,7 +3443,7 @@ IMPL_LINK( SbaTableQueryBrowser, OnTreeEntryCompare, const SvSortData*, _pSortDa
{
SvLBoxEntry* pLHS = static_cast<SvLBoxEntry*>(_pSortData->pLeft);
SvLBoxEntry* pRHS = static_cast<SvLBoxEntry*>(_pSortData->pRight);
- DBG_ASSERT(pLHS && pRHS, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid tree entries!");
+ OSL_ENSURE(pLHS && pRHS, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid tree entries!");
// we want the table entry and the end so we have to do a check
if (isContainer(pRHS))
@@ -3477,13 +3473,13 @@ IMPL_LINK( SbaTableQueryBrowser, OnTreeEntryCompare, const SvSortData*, _pSortDa
if ( ( eLeft == etQueryContainer ) && ( eRight == etTableContainer ) )
return COMPARE_LESS;
- OSL_ENSURE( false, "SbaTableQueryBrowser::OnTreeEntryCompare: unexpected case!" );
+ OSL_FAIL( "SbaTableQueryBrowser::OnTreeEntryCompare: unexpected case!" );
return COMPARE_EQUAL;
}
SvLBoxString* pLeftTextItem = static_cast<SvLBoxString*>(pLHS->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
SvLBoxString* pRightTextItem = static_cast<SvLBoxString*>(pRHS->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
- DBG_ASSERT(pLeftTextItem && pRightTextItem, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid text items!");
+ OSL_ENSURE(pLeftTextItem && pRightTextItem, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid text items!");
String sLeftText = pLeftTextItem->GetText();
String sRightText = pRightTextItem->GetText();
@@ -3496,7 +3492,7 @@ IMPL_LINK( SbaTableQueryBrowser, OnTreeEntryCompare, const SvSortData*, _pSortDa
{
nCompareResult = m_xCollator->compareString(sLeftText, sRightText);
}
- catch(Exception&)
+ catch(const Exception&)
{
}
}
@@ -3633,7 +3629,7 @@ Any SbaTableQueryBrowser::getCurrentSelection( Control& _rControl ) const
break;
default:
- OSL_ENSURE( false, "SbaTableQueryBrowser::getCurrentSelection: invalid (unexpected) object type!" );
+ OSL_FAIL( "SbaTableQueryBrowser::getCurrentSelection: invalid (unexpected) object type!" );
break;
}
@@ -3648,7 +3644,7 @@ sal_Bool SbaTableQueryBrowser::implGetQuerySignature( ::rtl::OUString& _rCommand
try
{
- // ontain the dss (data source signature) of the form
+ // contain the dss (data source signature) of the form
::rtl::OUString sDataSourceName;
::rtl::OUString sCommand;
sal_Int32 nCommandType = CommandType::COMMAND;
@@ -3718,14 +3714,6 @@ void SbaTableQueryBrowser::clearGridColumns(const Reference< XNameContainer >& _
}
}
// -----------------------------------------------------------------------------
-sal_Bool SbaTableQueryBrowser::isHiContrast() const
-{
- sal_Bool bRet = sal_False;
- if ( m_pTreeView )
- bRet = m_pTreeView->getListBox().GetSettings().GetStyleSettings().GetHighContrastMode();
- return bRet;
-}
-// -----------------------------------------------------------------------------
void SbaTableQueryBrowser::loadMenu(const Reference< XFrame >& _xFrame)
{
if ( m_bShowMenu )
@@ -3762,7 +3750,7 @@ void SbaTableQueryBrowser::loadMenu(const Reference< XFrame >& _xFrame)
sTitle = aURL.getBase(INetURLObject::LAST_SEGMENT,true,INetURLObject::DECODE_WITH_CHARSET);
if ( sName.getLength() )
{
- sName += ::rtl::OUString::createFromAscii(" - ");
+ sName += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" - "));
sName += sTitle;
sTitle = sName;
}
@@ -3803,7 +3791,6 @@ void SbaTableQueryBrowser::postReloadForm()
{
InitializeGridModel(getFormComponent());
LoadFinished(sal_True);
- //updateTitle();
}
//------------------------------------------------------------------------------
@@ -3849,7 +3836,7 @@ void SAL_CALL SbaTableQueryBrowser::releaseContextMenuInterceptor( const Referen
//------------------------------------------------------------------------------
void SAL_CALL SbaTableQueryBrowser::registeredDatabaseLocation( const DatabaseRegistrationEvent& _Event ) throw (RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
implAddDatasource( _Event.Name, SharedConnection() );
}
@@ -3886,13 +3873,12 @@ void SbaTableQueryBrowser::impl_cleanupDataSourceEntry( const String& _rDataSour
SvTreeEntryList* pList = m_pTreeModel->GetChildList( pDataSourceEntry );
if ( pList )
{
- SvLBoxEntry* pEntryLoop = static_cast<SvLBoxEntry*>( pList->First() );
- while ( pEntryLoop )
+ 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;
- pEntryLoop = static_cast< SvLBoxEntry* >( pList->Next() );
}
}
@@ -3906,7 +3892,7 @@ void SbaTableQueryBrowser::impl_cleanupDataSourceEntry( const String& _rDataSour
//------------------------------------------------------------------------------
void SAL_CALL SbaTableQueryBrowser::revokedDatabaseLocation( const DatabaseRegistrationEvent& _Event ) throw (RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
impl_cleanupDataSourceEntry( _Event.Name );
@@ -3917,7 +3903,7 @@ void SAL_CALL SbaTableQueryBrowser::revokedDatabaseLocation( const DatabaseRegis
//------------------------------------------------------------------------------
void SAL_CALL SbaTableQueryBrowser::changedDatabaseLocation( const DatabaseRegistrationEvent& _Event ) throw (RuntimeException)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
// in case the data source was expanded, and connected, we need to clean it up
// for simplicity, just do as if the data source were completely removed and re-added
@@ -3931,3 +3917,4 @@ void SAL_CALL SbaTableQueryBrowser::changedDatabaseLocation( const DatabaseRegis
// .........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/ColumnControlWindow.cxx b/dbaccess/source/ui/control/ColumnControlWindow.cxx
index 01e4988f5b34..015cecc76531 100644
--- a/dbaccess/source/ui/control/ColumnControlWindow.cxx
+++ b/dbaccess/source/ui/control/ColumnControlWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_COLUMNCONTROLWINDOW_HXX
#include "ColumnControlWindow.hxx"
-#endif
-#ifndef DBAUI_FIELDCONTROLS_HXX
#include "FieldControls.hxx"
-#endif
-#ifndef INCLUDED_SVTOOLS_SYSLOCALE_HXX
#include <unotools/syslocale.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
using namespace ::dbaui;
@@ -84,7 +73,6 @@ void OColumnControlWindow::ActivateAggregate( EControlType eType )
{
case tpFormat:
case tpDefault:
-// case tpAutoIncrement:
case tpColumnName:
break;
default:
@@ -98,7 +86,6 @@ void OColumnControlWindow::DeactivateAggregate( EControlType eType )
{
case tpFormat:
case tpDefault:
-// case tpAutoIncrement:
case tpColumnName:
break;
default:
@@ -196,3 +183,5 @@ TOTypeInfoSP OColumnControlWindow::getDefaultTyp() const
return m_pTypeInfo;
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/FieldDescControl.cxx b/dbaccess/source/ui/control/FieldDescControl.cxx
index 19fdbaad3e24..74be4d23d182 100644
--- a/dbaccess/source/ui/control/FieldDescControl.cxx
+++ b/dbaccess/source/ui/control/FieldDescControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,13 +31,11 @@
#define ITEMID_HORJUSTIFY SID_ATTR_ALIGN_HOR_JUSTIFY
#define ITEMID_VERJUSTIFY SID_ATTR_ALIGN_VER_JUSTIFY
-//#define ITEMID_ORIENTATION SID_ATTR_ALIGN_ORIENTATION
#define ITEMID_LINEBREAK SID_ATTR_ALIGN_LINEBREAK
#define ITEMID_MARGIN SID_ATTR_ALIGN_MARGIN
#include "FieldDescControl.hxx"
#include "FieldControls.hxx"
-#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
#include "TableDesignHelpBar.hxx"
#include <vcl/scrbar.hxx>
@@ -71,6 +70,7 @@
#include <memory>
#include "dbu_control.hrc"
#include "dbu_tbl.hrc"
+#include <osl/diagnose.h>
using namespace dbaui;
@@ -312,7 +312,7 @@ String OFieldDescControl::BoolStringUI(const String& rPersistentString) const
static String aOne('1');
static String aNone(ModuleRes(STR_VALUE_NONE));
- // FS - 66161 - 14.05.1999 - aeltere Versionen haben eventuell einen sprachabhaengigen String als Default gespeichert
+ // aeltere Versionen haben eventuell einen sprachabhaengigen String als Default gespeichert
if (rPersistentString.Equals(aYes) || rPersistentString.Equals(aNo))
return rPersistentString;
@@ -367,7 +367,7 @@ void OFieldDescControl::CheckScrollBars()
// horizontal :
long lMaxXPosition = 0;
Control* ppAggregates[] = { pRequired, pNumType, pAutoIncrement, pDefault, pTextLen, pLength, pScale, pFormat, m_pColumnName, m_pType,m_pAutoIncrementValue};
- for (sal_uInt16 i=0; i<sizeof(ppAggregates)/sizeof(ppAggregates[0]); ++i)
+ for (sal_uInt16 i=0; i < SAL_N_ELEMENTS(ppAggregates); ++i)
getMaxXPosition(ppAggregates[i],lMaxXPosition);
if (m_pHorzScroll)
@@ -410,7 +410,6 @@ void OFieldDescControl::CheckScrollBars()
{
m_pVertScroll->Show();
m_pVertScroll->SetRangeMax(nActive - nLastVisible);
-// m_pVertScroll->SetThumbPos(0);
m_pVertScroll->SetPosSizePixel( Point(nNewHWidth, 0), Size(nVScrollWidth, szOverallSize.Height()) );
}
@@ -425,7 +424,6 @@ void OFieldDescControl::CheckScrollBars()
{
m_pHorzScroll->Show();
m_pHorzScroll->SetRangeMax((lMaxXPosition - lMaxXAvailable + HSCROLL_STEP - 1 )/HSCROLL_STEP);
-// m_pHorzScroll->SetThumbPos(0);
m_pHorzScroll->SetPosSizePixel( Point(0, nNewVHeight), Size(bNeedVScrollBar ? nNewHWidth : szOverallSize.Width(), nHScrollHeight) );
}
@@ -485,9 +483,9 @@ void OFieldDescControl::ScrollAllAggregates()
, pTextLenText, pLengthText
, pScaleText, m_pColumnNameText
, m_pTypeText, m_pAutoIncrementValueText};
- OSL_ENSURE(sizeof(ppAggregates)/sizeof(ppAggregates[0]) == sizeof(ppAggregatesText)/sizeof(ppAggregatesText[0]),"Lists are not identical!");
+ OSL_ENSURE(SAL_N_ELEMENTS(ppAggregates) == SAL_N_ELEMENTS(ppAggregatesText),"Lists are not identical!");
- for (sal_uInt16 i=0; i<sizeof(ppAggregates)/sizeof(ppAggregates[0]); ++i)
+ for (sal_uInt16 i=0; i < SAL_N_ELEMENTS(ppAggregates); ++i)
ScrollAggregate(ppAggregatesText[i],ppAggregates[i],NULL,nDeltaX, nDeltaY);
ScrollAggregate(pFormatText,pFormatSample,pFormat,nDeltaX, nDeltaY);
@@ -499,7 +497,7 @@ sal_uInt16 OFieldDescControl::CountActiveAggregates() const
{
Control* ppAggregates[] = { pRequired, pNumType, pAutoIncrement, pDefault, pTextLen, pLength, pScale, pFormat, m_pColumnName, m_pType,m_pAutoIncrementValue};
sal_uInt16 nVisibleAggregates = 0;
- for (sal_uInt16 i=0; i<sizeof(ppAggregates)/sizeof(ppAggregates[0]); ++i)
+ for (sal_uInt16 i=0; i < SAL_N_ELEMENTS(ppAggregates); ++i)
if (ppAggregates[i])
++nVisibleAggregates;
return nVisibleAggregates;
@@ -509,14 +507,14 @@ sal_Int32 OFieldDescControl::GetMaxControlHeight() const
{
Size aHeight;
Control* ppAggregates[] = { pRequired, pNumType, pAutoIncrement, pDefault, pTextLen, pLength, pScale, pFormat, m_pColumnName, m_pType,m_pAutoIncrementValue};
- for (sal_uInt16 i=0; i<sizeof(ppAggregates)/sizeof(ppAggregates[0]); ++i)
+ for (sal_uInt16 i=0; i < SAL_N_ELEMENTS(ppAggregates); ++i)
{
if ( ppAggregates[i] )
{
const Size aTemp( ppAggregates[i]->GetOptimalSize(WINDOWSIZE_PREFERRED) );
if ( aTemp.Height() > aHeight.Height() )
aHeight.Height() = aTemp.Height();
- } // if ( ppAggregates[i] )
+ }
}
return aHeight.Height();
@@ -540,9 +538,9 @@ void OFieldDescControl::SetReadOnly( sal_Bool bReadOnly )
, m_pTypeText, m_pAutoIncrementValueText
, pFormatText};
- OSL_ENSURE(sizeof(ppAggregates)/sizeof(ppAggregates[0]) == sizeof(ppAggregatesText)/sizeof(ppAggregatesText[0]),"Lists are not identical!");
+ OSL_ENSURE(SAL_N_ELEMENTS(ppAggregates) == SAL_N_ELEMENTS(ppAggregatesText),"Lists are not identical!");
- for (sal_uInt16 i=0; i<sizeof(ppAggregates)/sizeof(ppAggregates[0]); ++i)
+ for (sal_uInt16 i=0; i < SAL_N_ELEMENTS(ppAggregates); ++i)
{
if ( ppAggregatesText[i] )
ppAggregatesText[i]->Enable( !bReadOnly );
@@ -834,7 +832,7 @@ void OFieldDescControl::ArrangeAggregates()
};
long nMaxWidth = 0;
- for (size_t i=0; i<sizeof(adAggregates)/sizeof(adAggregates[0]); i++)
+ for (size_t i=0; i < SAL_N_ELEMENTS(adAggregates); i++)
{
if (adAggregates[i].pctrlTextControl)
{
@@ -847,7 +845,7 @@ void OFieldDescControl::ArrangeAggregates()
// und los ...
int nCurrentControlPos = 0;
Control* pZOrderPredecessor = NULL;
- for (size_t i=0; i<sizeof(adAggregates)/sizeof(adAggregates[0]); i++)
+ for (size_t i=0; i < SAL_N_ELEMENTS(adAggregates); i++)
{
if (adAggregates[i].pctrlInputControl)
{
@@ -1194,7 +1192,7 @@ void OFieldDescControl::SetPosSize( Control** ppControl, long nRow, sal_uInt16 n
case 4:
aSize.Width() = CONTROL_WIDTH_4;
break;
- } // switch( nCol )
+ }
}
@@ -1426,7 +1424,7 @@ void OFieldDescControl::DisplayData(OFieldDescription* pFieldDescr )
break;
default:
- OSL_ENSURE(0,"Unknown type");
+ OSL_FAIL("Unknown type");
}
m_pPreviousType = pFieldType;
}
@@ -1520,7 +1518,7 @@ void OFieldDescControl::DisplayData(OFieldDescription* pFieldDescr )
if( pNumType )
{
- OSL_ENSURE(sal_False, "OFieldDescControl::DisplayData: invalid num type!");
+ OSL_FAIL("OFieldDescControl::DisplayData: invalid num type!");
}
if( pLength )
@@ -1733,7 +1731,7 @@ void OFieldDescControl::GetFocus()
void OFieldDescControl::implFocusLost(Window* _pWhich)
{
DBG_CHKTHIS(OFieldDescControl,NULL);
- DBG_ASSERT(!_pWhich || IsChild(_pWhich), "OFieldDescControl::implFocusLost : invalid window !");
+ OSL_ENSURE(!_pWhich || IsChild(_pWhich), "OFieldDescControl::implFocusLost : invalid window !");
//////////////////////////////////////////////////////////////////////
// Das aktive Control merken
@@ -1879,7 +1877,7 @@ String OFieldDescControl::getControlDefault( const OFieldDescription* _pFieldDes
Reference<XPropertySet> xFormSet = xNumberFormatter->getNumberFormatsSupplier()->getNumberFormats()->getByKey(nFormatKey);
OSL_ENSURE(xFormSet.is(),"XPropertySet is null!");
::rtl::OUString sFormat;
- xFormSet->getPropertyValue(::rtl::OUString::createFromAscii("FormatString")) >>= sFormat;
+ xFormSet->getPropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("FormatString"))) >>= sFormat;
if ( !bTextFormat )
{
@@ -1911,3 +1909,5 @@ String OFieldDescControl::getControlDefault( const OFieldDescription* _pFieldDes
return sDefault;
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/RelationControl.cxx b/dbaccess/source/ui/control/RelationControl.cxx
index 85de5d777025..f3efb7c741b1 100644
--- a/dbaccess/source/ui/control/RelationControl.cxx
+++ b/dbaccess/source/ui/control/RelationControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,58 +28,23 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_RELATIONCONTROL_HXX
#include "RelationControl.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_UI_INC_RELATIONCONTROL_HRC
#include "RelationControl.hrc"
-#endif
-#ifndef _SVTOOLS_EDITBROWSEBOX_HXX_
#include <svtools/editbrowsebox.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBAUI_RELCONTROLIFACE_HXX
#include "RelControliFace.hxx"
-#endif
-#ifndef _DBU_CONTROL_HRC_
#include "dbu_control.hrc"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
+#include <osl/diagnose.h>
#include <algorithm>
@@ -167,7 +133,7 @@ namespace dbaui
DBG_NAME(ORelationControl)
//------------------------------------------------------------------------
ORelationControl::ORelationControl( OTableListBoxControl* pParent ,const OJoinTableView::OTableWindowMap* _pTableMap)
- :EditBrowseBox( pParent, EBBF_SMART_TAB_TRAVEL | EBBF_NOROWPICTURE, WB_TABSTOP | /*WB_3DLOOK | */WB_BORDER | BROWSER_AUTOSIZE_LASTCOL)
+ :EditBrowseBox( pParent, EBBF_SMART_TAB_TRAVEL | EBBF_NOROWPICTURE, WB_TABSTOP | WB_BORDER | BROWSER_AUTOSIZE_LASTCOL)
,m_pTableMap(_pTableMap)
,m_pBoxControl(pParent)
,m_xSourceDef( NULL )
@@ -529,7 +495,7 @@ OTableListBoxControl::OTableListBoxControl( Window* _pParent
// -----------------------------------------------------------------------------
void OTableListBoxControl::fillListBoxes()
{
- DBG_ASSERT( !m_pTableMap->empty(), "OTableListBoxControl::fillListBoxes: no table window!");
+ OSL_ENSURE( !m_pTableMap->empty(), "OTableListBoxControl::fillListBoxes: no table window!");
OTableWindow* pInitialLeft = NULL;
OTableWindow* pInitialRight = NULL;
@@ -551,7 +517,7 @@ OTableListBoxControl::OTableListBoxControl( Window* _pParent
pInitialRight = aIter->second;
m_strCurrentRight = aIter->first;
}
- } // for(;aIter != m_pTableMap->end();++aIter)
+ }
if ( !pInitialRight )
{
@@ -616,7 +582,7 @@ OTableListBoxControl::OTableListBoxControl( Window* _pParent
OTableWindow* pLoop = NULL;
if( aFind != m_pTableMap->end() )
pLoop = aFind->second;
- DBG_ASSERT(pLoop != NULL, "ORelationDialog::OnTableChanged : ungueltiger Eintrag in ListBox !");
+ OSL_ENSURE(pLoop != NULL, "ORelationDialog::OnTableChanged : ungueltiger Eintrag in ListBox !");
// da ich die ListBoxen selber mit eben diesen Tabellennamen, mit denen ich sie jetzt vergleiche, gefuellt habe,
// MUSS ich strSelected finden
if (pListBox == &m_lmbLeftTable)
@@ -701,7 +667,6 @@ OTableListBoxControl::OTableListBoxControl( Window* _pParent
{
_pTableSeparator->SetZOrder(&m_lmbRightTable, WINDOW_ZORDER_BEHIND);
m_pRC_Tables->SetZOrder(_pTableSeparator, WINDOW_ZORDER_BEHIND);
- //aDlgPoint = m_pTableSeparator->GetPosPixel() + Point(0,aSize.Height()) + LogicToPixel( Point(0,6), MAP_APPFONT );
_pTableSeparator->SetPosPixel(Point(0,m_aFL_InvolvedFields.GetPosPixel().Y()));
const Size aSize = _pTableSeparator->GetSizePixel();
aDlgPoint.Y() = _pTableSeparator->GetPosPixel().Y() + aSize.Height();
@@ -749,3 +714,4 @@ OTableListBoxControl::OTableListBoxControl( Window* _pParent
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/ScrollHelper.cxx b/dbaccess/source/ui/control/ScrollHelper.cxx
index 7aaf8fbaceb6..7f80abd3e2c8 100644
--- a/dbaccess/source/ui/control/ScrollHelper.cxx
+++ b/dbaccess/source/ui/control/ScrollHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_SCROLLHELPER_HXX
#include "ScrollHelper.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#define LISTBOX_SCROLLING_AREA 12
namespace dbaui
@@ -79,3 +76,4 @@ DBG_NAME(OScrollHelper)
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/SqlNameEdit.cxx b/dbaccess/source/ui/control/SqlNameEdit.cxx
index e471085abe1c..80cf34bbc18c 100644
--- a/dbaccess/source/ui/control/SqlNameEdit.cxx
+++ b/dbaccess/source/ui/control/SqlNameEdit.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_SQLNAMEEDIT_HXX
#include "SqlNameEdit.hxx"
-#endif
namespace dbaui
{
//------------------------------------------------------------------
@@ -98,3 +97,4 @@ namespace dbaui
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/TableGrantCtrl.cxx b/dbaccess/source/ui/control/TableGrantCtrl.cxx
index 3cff731a341b..cb8be985c104 100644
--- a/dbaccess/source/ui/control/TableGrantCtrl.cxx
+++ b/dbaccess/source/ui/control/TableGrantCtrl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEGRANTCONTROL_HXX
#include "TableGrantCtrl.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_PRIVILEGE_HPP_
#include <com/sun/star/sdbcx/Privilege.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_PRIVILEGEOBJECT_HPP_
#include <com/sun/star/sdbcx/PrivilegeObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XUSERSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XUsersSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAUTHORIZABLE_HPP_
#include <com/sun/star/sdbcx/XAuthorizable.hpp>
-#endif
-#ifndef _DBU_CONTROL_HRC_
#include "dbu_control.hrc"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
using namespace ::com::sun::star::accessibility;
using namespace ::com::sun::star::container;
@@ -514,3 +497,4 @@ Reference< XAccessible > OTableGrantControl::CreateAccessibleCell( sal_Int32 _nR
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/TableGrantCtrl.src b/dbaccess/source/ui/control/TableGrantCtrl.src
index 8da72a1f9fe1..8b870e4927b6 100644
--- a/dbaccess/source/ui/control/TableGrantCtrl.src
+++ b/dbaccess/source/ui/control/TableGrantCtrl.src
@@ -53,6 +53,7 @@ String STR_TABLE_PRIV_ALTER
{
Text [ en-US ] = "Alter structure";
};
+
String STR_TABLE_PRIV_SELECT
{
Text [ en-US ] = "Read data";
@@ -67,30 +68,3 @@ String STR_TABLE_PRIV_DROP
{
Text [ en-US ] = "Drop structure";
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/control/VertSplitView.cxx b/dbaccess/source/ui/control/VertSplitView.cxx
index 8fa996ac1d35..52c3ca5a0c9e 100644
--- a/dbaccess/source/ui/control/VertSplitView.cxx
+++ b/dbaccess/source/ui/control/VertSplitView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,13 +28,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_VERTSPLITVIEW_HXX
#include "VertSplitView.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#define SPLITTER_WIDTH 80
@@ -218,3 +215,5 @@ void OSplitterView::setSplitter(Splitter* _pSplitter)
LINK( this, OSplitterView, SplitHdl ).Call(m_pSplitter);
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/charsetlistbox.cxx b/dbaccess/source/ui/control/charsetlistbox.cxx
index 668b887b3126..6fb77f0293e5 100644
--- a/dbaccess/source/ui/control/charsetlistbox.cxx
+++ b/dbaccess/source/ui/control/charsetlistbox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,6 +36,7 @@
#include <svl/itemset.hxx>
#include <svl/stritem.hxx>
+#include <osl/diagnose.h>
//........................................................................
namespace dbaui
@@ -72,7 +74,7 @@ namespace dbaui
OCharsetDisplay::const_iterator aFind = m_aCharSets.findIanaName( _rIanaName );
if (aFind == m_aCharSets.end())
{
- DBG_ERROR( "CharSetListBox::SelectEntryByIanaName: unknown charset falling back to system language!" );
+ OSL_FAIL( "CharSetListBox::SelectEntryByIanaName: unknown charset falling back to system language!" );
aFind = m_aCharSets.findEncoding( RTL_TEXTENCODING_DONTKNOW );
}
@@ -88,7 +90,7 @@ namespace dbaui
// in our settings, there was an encoding selected which is not valid for the current
// data source type
// This is worth at least an assertion.
- DBG_ERROR( "CharSetListBox::SelectEntryByIanaName: invalid character set!" );
+ OSL_FAIL( "CharSetListBox::SelectEntryByIanaName: invalid character set!" );
sDisplayName = String();
}
@@ -103,7 +105,7 @@ namespace dbaui
if ( GetSelectEntryPos() != GetSavedValue() )
{
OCharsetDisplay::const_iterator aFind = m_aCharSets.findDisplayName( GetSelectEntry() );
- DBG_ASSERT( aFind != m_aCharSets.end(), "CharSetListBox::StoreSelectedCharSet: could not translate the selected character set!" );
+ OSL_ENSURE( aFind != m_aCharSets.end(), "CharSetListBox::StoreSelectedCharSet: could not translate the selected character set!" );
if ( aFind != m_aCharSets.end() )
{
_rSet.Put( SfxStringItem( _nItemId, (*aFind).getIanaName() ) );
@@ -116,3 +118,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/curledit.cxx b/dbaccess/source/ui/control/curledit.cxx
index ce5d707672f8..e4bc004e1298 100644
--- a/dbaccess/source/ui/control/curledit.cxx
+++ b/dbaccess/source/ui/control/curledit.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_CURLEDIT_HXX_
#include "curledit.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
+#include <osl/diagnose.h>
//.........................................................................
namespace dbaui
@@ -66,7 +64,7 @@ OConnectionURLEdit::~OConnectionURLEdit()
//-------------------------------------------------------------------------
void OConnectionURLEdit::SetTextNoPrefix(const String& _rText)
{
- DBG_ASSERT(GetSubEdit(), "OConnectionURLEdit::SetTextNoPrefix: have no current type, not changing the text!");
+ OSL_ENSURE(GetSubEdit(), "OConnectionURLEdit::SetTextNoPrefix: have no current type, not changing the text!");
if (GetSubEdit())
GetSubEdit()->SetText(_rText);
}
@@ -156,3 +154,4 @@ void OConnectionURLEdit::ShowPrefix(sal_Bool _bShowPrefix)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/dbtreelistbox.cxx b/dbaccess/source/ui/control/dbtreelistbox.cxx
index 7f600c0bd1df..4bce0d3b8720 100644
--- a/dbaccess/source/ui/control/dbtreelistbox.cxx
+++ b/dbaccess/source/ui/control/dbtreelistbox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,56 +29,24 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_DBTREELISTBOX_HXX
#include "dbtreelistbox.hxx"
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _DBAUI_LISTVIEWITEMS_HXX_
#include "listviewitems.hxx"
-#endif
-#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#include "callbacks.hxx"
-#endif
-#ifndef _COM_SUN_STAR_DATATRANSFER_DND_XDRAGGESTURELISTENER_HDL_
#include <com/sun/star/datatransfer/dnd/XDragGestureListener.hdl>
-#endif
-#ifndef _COM_SUN_STAR_DATATRANSFER_DND_XDRAGGESTURERECOGNIZER_HPP_
#include <com/sun/star/datatransfer/dnd/XDragGestureRecognizer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XCONTEXTMENUINTERCEPTOR_HPP_
#include <com/sun/star/ui/XContextMenuInterceptor.hpp>
-#endif
#include <com/sun/star/frame/XFrame.hpp>
-#ifndef _COM_SUN_STAR_UTIL_URL_HPP_
#include <com/sun/star/util/URL.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_
#include <cppuhelper/interfacecontainer.hxx>
-#endif
-#ifndef _SV_HELP_HXX
#include <vcl/help.hxx>
-#endif
-#ifndef _DBAUI_TABLETREE_HRC_
#include "tabletree.hrc"
-#endif
-#ifndef DBAUI_ICONTROLLER_HXX
#include "IController.hxx"
-#endif
-#ifndef __FRAMEWORK_HELPER_ACTIONTRIGGERHELPER_HXX_
#include <framework/actiontriggerhelper.hxx>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
#include <framework/imageproducer.hxx>
#include <vcl/svapp.hxx>
#include <memory>
@@ -157,10 +126,10 @@ SvLBoxEntry* DBTreeListBox::GetEntryPosByName( const String& aName, SvLBoxEntry*
SvLBoxEntry* pEntry = NULL;
if ( pChilds )
{
- sal_uLong nCount = pChilds->Count();
- for (sal_uLong i=0; i < nCount; ++i)
+ size_t nCount = pChilds->size();
+ for (size_t i = 0; i < nCount; ++i)
{
- pEntry = static_cast<SvLBoxEntry*>(pChilds->GetObject(i));
+ pEntry = static_cast<SvLBoxEntry*>((*pChilds)[ i ]);
SvLBoxString* pItem = (SvLBoxString*)(pEntry->GetFirstItem(SV_ITEM_ID_LBOXSTRING));
if ( pItem->GetText().Equals(aName) )
{
@@ -188,7 +157,7 @@ void DBTreeListBox::RequestingChilds( SvLBoxEntry* pParent )
{
if (!m_aPreExpandHandler.Call(pParent))
{
- // an error occured. The method calling us will reset the entry flags, so it can't be expanded again.
+ // an error occurred. The method calling us will reset the entry flags, so it can't be expanded again.
// But we want that the user may do a second try (i.e. because he misstypes a password in this try), so
// we have to reset these flags controlling the expand ability
PostUserEvent(LINK(this, DBTreeListBox, OnResetEntry), pParent);
@@ -436,8 +405,6 @@ void DBTreeListBox::KeyInput( const KeyEvent& rKEvt )
// is used by the document will raise a similar bug once somebody discovers it.
// If this is the case, we should discuss a real solution with the framework (SFX) and the
// applications.
- //
- // 2002-12-02 - 105831 - fs@openoffice.org
}
if ( !bHandled )
@@ -548,7 +515,7 @@ namespace
{
lcl_adjustMenuItemIDs( *pPopup, _rCommandController );
continue;
- } // if ( pPopup )
+ }
const sal_uInt16 nCommandId = _rCommandController.registerCommandURL( aCommand );
_rMenu.InsertItem( nCommandId, _rMenu.GetItemText( nId ), _rMenu.GetItemImage( nId ),
@@ -566,8 +533,6 @@ namespace
}
void lcl_insertMenuItemImages( Menu& _rMenu, IController& _rCommandController )
{
- const StyleSettings& rSettings = Application::GetSettings().GetStyleSettings();
- const sal_Bool bHiContrast = rSettings.GetHighContrastMode();
uno::Reference< frame::XController > xController = _rCommandController.getXController();
uno::Reference< frame::XFrame> xFrame;
if ( xController.is() )
@@ -586,10 +551,10 @@ namespace
{
lcl_insertMenuItemImages( *pPopup, _rCommandController );
continue;
- } // if ( pPopup )
+ }
if ( xFrame.is() )
- _rMenu.SetItemImage(nId,framework::GetImageFromURL(xFrame,aCommand,sal_False,bHiContrast));
+ _rMenu.SetItemImage(nId,framework::GetImageFromURL(xFrame,aCommand,sal_False));
}
}
// =========================================================================
@@ -635,14 +600,14 @@ namespace
//--------------------------------------------------------------------
void SAL_CALL SelectionSupplier::addSelectionChangeListener( const Reference< XSelectionChangeListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SelectionSupplier::removeSelectionChangeListener: no support!" );
+ OSL_FAIL( "SelectionSupplier::removeSelectionChangeListener: no support!" );
// API bug: this should be a NoSupportException
}
//--------------------------------------------------------------------
void SAL_CALL SelectionSupplier::removeSelectionChangeListener( const Reference< XSelectionChangeListener >& /*_Listener*/ ) throw (RuntimeException)
{
- OSL_ENSURE( false, "SelectionSupplier::removeSelectionChangeListener: no support!" );
+ OSL_FAIL( "SelectionSupplier::removeSelectionChangeListener: no support!" );
// API bug: this should be a NoSupportException
}
}
@@ -702,7 +667,7 @@ PopupMenu* DBTreeListBox::CreateContextMenu( void )
break;
default:
- DBG_ERROR( "DBTreeListBox::CreateContextMenu: unexpected return value of the interceptor call!" );
+ OSL_FAIL( "DBTreeListBox::CreateContextMenu: unexpected return value of the interceptor call!" );
case ContextMenuInterceptorAction_IGNORED:
break;
@@ -727,7 +692,7 @@ PopupMenu* DBTreeListBox::CreateContextMenu( void )
// the interceptors only know command URLs, but our menus primarily work
// with IDs -> we need to translate the commands to IDs
lcl_adjustMenuItemIDs( *pModifiedMenu, m_pContextMenuProvider->getCommandController() );
- } // if ( bModifiedMenu )
+ }
return pContextMenu.release();
}
@@ -756,3 +721,5 @@ void DBTreeListBox::StateChanged( StateChangedType nStateChange )
// .........................................................................
} // namespace dbaui
// .........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/listviewitems.cxx b/dbaccess/source/ui/control/listviewitems.cxx
index c122fedc060b..3d109f8b713e 100644
--- a/dbaccess/source/ui/control/listviewitems.cxx
+++ b/dbaccess/source/ui/control/listviewitems.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_LISTVIEWITEMS_HXX_
#include "listviewitems.hxx"
-#endif
//........................................................................
namespace dbaui
{
@@ -82,3 +81,4 @@ namespace dbaui
} // namespace dbaui
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/makefile.mk b/dbaccess/source/ui/control/makefile.mk
deleted file mode 100644
index 76857497cb6b..000000000000
--- a/dbaccess/source/ui/control/makefile.mk
+++ /dev/null
@@ -1,78 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=uicontrols
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files -------------------------------------
-
-# ... resource files ............................
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- TableGrantCtrl.src \
- undosqledit.src \
- tabletree.src
-
-# ... exception files .........................
-
-EXCEPTIONSFILES=\
- $(SLO)$/statusbarontroller.obj \
- $(SLO)$/RelationControl.obj \
- $(SLO)$/toolboxcontroller.obj \
- $(SLO)$/tabletree.obj \
- $(SLO)$/TableGrantCtrl.obj \
- $(SLO)$/dbtreelistbox.obj \
- $(SLO)$/sqledit.obj \
- $(SLO)$/ColumnControlWindow.obj \
- $(SLO)$/FieldDescControl.obj \
- $(SLO)$/opendoccontrols.obj
-
-# ... object files ............................
-
-SLOFILES= \
- $(EXCEPTIONSFILES) \
- $(SLO)$/ScrollHelper.obj \
- $(SLO)$/VertSplitView.obj \
- $(SLO)$/SqlNameEdit.obj \
- $(SLO)$/listviewitems.obj \
- $(SLO)$/undosqledit.obj \
- $(SLO)$/marktree.obj \
- $(SLO)$/curledit.obj \
- $(SLO)$/charsetlistbox.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/ui/control/marktree.cxx b/dbaccess/source/ui/control/marktree.cxx
index 4e372ff3ee23..9f07857936fa 100644
--- a/dbaccess/source/ui/control/marktree.cxx
+++ b/dbaccess/source/ui/control/marktree.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_MARKTREE_HXX_
#include "marktree.hxx"
-#endif
-#ifndef _DBU_CONTROL_HRC_
#include "dbu_control.hrc"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
//.........................................................................
namespace dbaui
@@ -157,10 +152,9 @@ SvButtonState OMarkableTreeListBox::implDetermineState(SvLBoxEntry* _pEntry)
// we did not finish the loop because at least one of the children is in tristate
eState = SV_BUTTON_TRISTATE;
- // but this means that we did not finish all the siblings of pChildLoop, so their checking may be
- // incorrect at the moment
+ // but this means that we did not finish all the siblings of pChildLoop,
+ // so their checking may be incorrect at the moment
// -> correct this
- // 88485 - 20.06.2001 - frank.schoenheit@sun.com
while (pChildLoop)
{
implDetermineState(pChildLoop);
@@ -168,9 +162,9 @@ SvButtonState OMarkableTreeListBox::implDetermineState(SvLBoxEntry* _pEntry)
}
}
else
- // none if the children is in tristate
+ // none if the children are in tristate
if (nCheckedChildren)
- // we have at least one chil checked
+ // we have at least one child checked
if (nCheckedChildren != nChildrenOverall)
// not all children are checked
eState = SV_BUTTON_TRISTATE;
@@ -245,3 +239,4 @@ void OMarkableTreeListBox::checkedButton_noBroadcast(SvLBoxEntry* _pEntry)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/opendoccontrols.cxx b/dbaccess/source/ui/control/opendoccontrols.cxx
index ce9846bda8df..dc88dfb555a6 100644
--- a/dbaccess/source/ui/control/opendoccontrols.cxx
+++ b/dbaccess/source/ui/control/opendoccontrols.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,58 +29,27 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_SOURCE_UI_INC_OPENDOCCONTROLS_HXX
#include "opendoccontrols.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XMODULEUICONFIGURATIONMANAGERSUPPLIER_HPP_
#include <com/sun/star/ui/XModuleUIConfigurationManagerSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XUICONFIGURATIONMANAGER_HPP_
#include <com/sun/star/ui/XUIConfigurationManager.hpp>
-#endif
-#ifndef _COM_SUN_STAR_GRAPHIC_XGRAPHIC_HPP_
#include <com/sun/star/graphic/XGraphic.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XIMAGEMANAGER_HPP_
#include <com/sun/star/ui/XImageManager.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _COMPHELPER_PROCESSFACTORY_HXX_
#include <comphelper/processfactory.hxx>
-#endif
-#ifndef _SV_GRAPH_HXX
#include <vcl/graph.hxx>
-#endif
-#ifndef _SV_HELP_HXX
#include <vcl/help.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_HISTORYOPTIONS_HXX
#include <unotools/historyoptions.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCEASHASHMAP_HXX_
#include <comphelper/sequenceashashmap.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef SVTOOLS_FILENOTATION_HXX
#include <svl/filenotation.hxx>
-#endif
+#include <osl/diagnose.h>
//........................................................................
namespace dbaui
@@ -137,7 +107,7 @@ namespace dbaui
for ( sal_Int32 i=0; i<nCount; ++i )
{
::rtl::OUString sPropertyName( aProperties[i].Name );
- if ( sPropertyName.equalsAscii("Label" ) )
+ if ( sPropertyName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM("Label" ) ) )
{
aProperties[i].Value >>= sLabel;
break;
@@ -216,7 +186,7 @@ namespace dbaui
//--------------------------------------------------------------------
void OpenDocumentButton::impl_init( const sal_Char* _pAsciiModuleName )
{
- DBG_ASSERT( _pAsciiModuleName, "OpenDocumentButton::impl_init: invalid module name!" );
+ OSL_ENSURE( _pAsciiModuleName, "OpenDocumentButton::impl_init: invalid module name!" );
m_sModule = ::rtl::OUString::createFromAscii( _pAsciiModuleName );
// our label should equal the UI text of the "Open" command
@@ -226,7 +196,7 @@ namespace dbaui
SetText( sLabel );
// Place icon left of text and both centered in the button.
- SetModeImage( GetCommandIcon( ".uno:Open", m_sModule ), BMP_COLOR_NORMAL );
+ SetModeImage( GetCommandIcon( ".uno:Open", m_sModule ) );
EnableImageDisplay( sal_True );
EnableTextDisplay( sal_True );
SetImageAlign( IMAGEALIGN_LEFT );
@@ -246,7 +216,7 @@ namespace dbaui
//--------------------------------------------------------------------
void OpenDocumentListBox::impl_init( const sal_Char* _pAsciiModuleName )
{
- DBG_ASSERT( _pAsciiModuleName, "OpenDocumentListBox::impl_init: invalid module name!" );
+ OSL_ENSURE( _pAsciiModuleName, "OpenDocumentListBox::impl_init: invalid module name!" );
Sequence< Sequence< PropertyValue> > aHistory = SvtHistoryOptions().GetList( ePICKLIST );
Reference< XNameAccess > xFilterFactory;
@@ -322,7 +292,7 @@ namespace dbaui
OpenDocumentListBox::StringPair OpenDocumentListBox::impl_getDocumentAtIndex( sal_uInt16 _nListIndex, bool _bSystemNotation ) const
{
MapIndexToStringPair::const_iterator pos = m_aURLs.find( _nListIndex );
- DBG_ASSERT( pos != m_aURLs.end(), "OpenDocumentListBox::impl_getDocumentAtIndex: invalid index!" );
+ OSL_ENSURE( pos != m_aURLs.end(), "OpenDocumentListBox::impl_getDocumentAtIndex: invalid index!" );
StringPair aDocumentDescriptor;
if ( pos != m_aURLs.end() )
@@ -361,3 +331,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/sqledit.cxx b/dbaccess/source/ui/control/sqledit.cxx
index f10e4c6c1dcb..579740e43b42 100644
--- a/dbaccess/source/ui/control/sqledit.cxx
+++ b/dbaccess/source/ui/control/sqledit.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -222,3 +223,5 @@ void OSqlEdit::ImplSetFont()
SetSettings(aSettings);
}
//==============================================================================
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/statusbarontroller.cxx b/dbaccess/source/ui/control/statusbarontroller.cxx
index 0d2226cfdde8..c71c5f86a289 100644
--- a/dbaccess/source/ui/control/statusbarontroller.cxx
+++ b/dbaccess/source/ui/control/statusbarontroller.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
#include "statusbarontroller.hxx"
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
extern "C" void SAL_CALL createRegistryInfo_OStatusbarController()
{
@@ -48,3 +47,5 @@ namespace dbaui
IMPLEMENT_SERVICE_INFO1_STATIC(OStatusbarController,"com.sun.star.sdb.ApplicationStatusbarController","com.sun.star.frame.StatusbarController")
IMPLEMENT_FORWARD_XINTERFACE2(OStatusbarController,StatusbarController,OStatusbarController_BASE)
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/tabletree.cxx b/dbaccess/source/ui/control/tabletree.cxx
index 5d3513cc8cd5..c86cac49e5ad 100644
--- a/dbaccess/source/ui/control/tabletree.cxx
+++ b/dbaccess/source/ui/control/tabletree.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,75 +29,33 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_TABLETREE_HXX_
#include "tabletree.hxx"
-#endif
-#ifndef _DBAUI_TABLETREE_HRC_
#include "tabletree.hrc"
-#endif
-#ifndef DBACCESS_IMAGEPROVIDER_HXX
#include "imageprovider.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _DBU_CONTROL_HRC_
#include "dbu_control.hrc"
-#endif
-#ifndef _SV_MENU_HXX
#include <vcl/menu.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_DATABASEOBJECT_HPP_
#include <com/sun/star/sdb/application/DatabaseObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_DATABASEOBJECTFOLDER_HPP_
#include <com/sun/star/sdb/application/DatabaseObjectContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDRIVERACCESS_HPP_
#include <com/sun/star/sdbc/XDriverAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADEFINITIONSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XDataDefinitionSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
-#ifndef _DBAUI_LISTVIEWITEMS_HXX_
#include "listviewitems.hxx"
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _RTL_USTRBUF_HXX_
+#include <osl/diagnose.h>
#include <rtl/ustrbuf.hxx>
-#endif
#include <connectivity/dbmetadata.hxx>
#include <algorithm>
+#include <o3tl/compat_functional.hxx>
//.........................................................................
namespace dbaui
@@ -148,10 +107,8 @@ OTableTreeListBox::~OTableTreeListBox()
void OTableTreeListBox::implSetDefaultImages()
{
ImageProvider aImageProvider;
- SetDefaultExpandedEntryBmp( aImageProvider.getFolderImage( DatabaseObject::TABLE, false ), BMP_COLOR_NORMAL );
- SetDefaultExpandedEntryBmp( aImageProvider.getFolderImage( DatabaseObject::TABLE, true ), BMP_COLOR_HIGHCONTRAST );
- SetDefaultCollapsedEntryBmp( aImageProvider.getFolderImage( DatabaseObject::TABLE, false ), BMP_COLOR_NORMAL );
- SetDefaultCollapsedEntryBmp( aImageProvider.getFolderImage( DatabaseObject::TABLE, true ), BMP_COLOR_HIGHCONTRAST );
+ SetDefaultExpandedEntryBmp( aImageProvider.getFolderImage( DatabaseObject::TABLE ) );
+ SetDefaultCollapsedEntryBmp( aImageProvider.getFolderImage( DatabaseObject::TABLE ) );
}
// -----------------------------------------------------------------------------
@@ -182,25 +139,19 @@ void OTableTreeListBox::notifyHiContrastChanged()
{
SvLBoxContextBmp* pContextBitmapItem = static_cast< SvLBoxContextBmp* >( pItem );
- Image aImage, aImageHC;
+ Image aImage;
if ( isFolderEntry( pEntryLoop ) )
{
- aImage = m_pImageProvider->getFolderImage( DatabaseObject::TABLE, false );
- aImageHC = m_pImageProvider->getFolderImage( DatabaseObject::TABLE, true );
+ aImage = m_pImageProvider->getFolderImage( DatabaseObject::TABLE );
}
else
{
String sCompleteName( getQualifiedTableName( pEntryLoop ) );
- m_pImageProvider->getImages( sCompleteName, DatabaseObject::TABLE, aImage, aImageHC );
+ m_pImageProvider->getImages( sCompleteName, DatabaseObject::TABLE, aImage );
}
- pContextBitmapItem->SetBitmap1( aImage, BMP_COLOR_NORMAL );
- pContextBitmapItem->SetBitmap2( aImage, BMP_COLOR_NORMAL );
- pContextBitmapItem->SetBitmap1( aImageHC, BMP_COLOR_HIGHCONTRAST );
- pContextBitmapItem->SetBitmap2( aImageHC, BMP_COLOR_HIGHCONTRAST );
- // TODO: Now that we give both images to the entry item, it is not necessary anymore
- // to do this anytime HC changes - the tree control will do this itself now.
- // We would only need to properly initialize newly inserted entries.
+ pContextBitmapItem->SetBitmap1( aImage );
+ pContextBitmapItem->SetBitmap2( aImage );
break;
}
}
@@ -242,7 +193,7 @@ void OTableTreeListBox::UpdateTableList( const Reference< XConnection >& _rxConn
}
catch(RuntimeException&)
{
- DBG_ERROR("OTableTreeListBox::UpdateTableList : caught an RuntimeException!");
+ OSL_FAIL("OTableTreeListBox::UpdateTableList : caught an RuntimeException!");
}
catch ( const SQLException& )
{
@@ -250,7 +201,7 @@ void OTableTreeListBox::UpdateTableList( const Reference< XConnection >& _rxConn
}
catch(Exception&)
{
- // a non-SQLException exception occured ... simply throw an SQLException
+ // a non-SQLException exception occurred ... simply throw an SQLException
SQLException aInfo;
aInfo.Message = sCurrentActionError;
throw aInfo;
@@ -333,15 +284,13 @@ void OTableTreeListBox::UpdateTableList( const Reference< XConnection >& _rxConn
try
{
- // the root entry saying "all objects"
- SvLBoxEntry* pAllObjects = NULL;
if (haveVirtualRoot())
{
String sRootEntryText;
TNames::const_iterator aViews = ::std::find_if(_rTables.begin(),_rTables.end(),
- ::std::compose1(::std::bind2nd(::std::equal_to<sal_Bool>(),sal_False),::std::select2nd<TNames::value_type>()));
+ ::o3tl::compose1(::std::bind2nd(::std::equal_to<sal_Bool>(),sal_False),::o3tl::select2nd<TNames::value_type>()));
TNames::const_iterator aTables = ::std::find_if(_rTables.begin(),_rTables.end(),
- ::std::compose1(::std::bind2nd(::std::equal_to<sal_Bool>(),sal_True),::std::select2nd<TNames::value_type>()));
+ ::o3tl::compose1(::std::bind2nd(::std::equal_to<sal_Bool>(),sal_True),::o3tl::select2nd<TNames::value_type>()));
if ( aViews == _rTables.end() )
sRootEntryText = String(ModuleRes(STR_ALL_TABLES));
@@ -349,7 +298,7 @@ void OTableTreeListBox::UpdateTableList( const Reference< XConnection >& _rxConn
sRootEntryText = String(ModuleRes(STR_ALL_VIEWS));
else
sRootEntryText = String(ModuleRes(STR_ALL_TABLES_AND_VIEWS));
- pAllObjects = InsertEntry( sRootEntryText, NULL, sal_False, LIST_APPEND, reinterpret_cast< void* >( DatabaseObjectContainer::TABLES ) );
+ InsertEntry( sRootEntryText, NULL, sal_False, LIST_APPEND, reinterpret_cast< void* >( DatabaseObjectContainer::TABLES ) );
}
if ( _rTables.empty() )
@@ -435,22 +384,21 @@ void OTableTreeListBox::checkedButton_noBroadcast(SvLBoxEntry* _pEntry)
{
OMarkableTreeListBox::checkedButton_noBroadcast(_pEntry);
- // if an entry has children, it makes a difference if the entry is checked because alls children are checked
- // or if the user checked it explicitly.
+ // if an entry has children, it makes a difference if the entry is checked
+ // because all children are checked or if the user checked it explicitly.
// So we track explicit (un)checking
SvButtonState eState = GetCheckButtonState(_pEntry);
- DBG_ASSERT(SV_BUTTON_TRISTATE != eState, "OTableTreeListBox::CheckButtonHdl: user action which lead to TRISTATE?");
+ OSL_ENSURE(SV_BUTTON_TRISTATE != eState, "OTableTreeListBox::CheckButtonHdl: user action which lead to TRISTATE?");
implEmphasize(_pEntry, SV_BUTTON_CHECKED == eState);
}
//------------------------------------------------------------------------
void OTableTreeListBox::implEmphasize(SvLBoxEntry* _pEntry, sal_Bool _bChecked, sal_Bool _bUpdateDescendants, sal_Bool _bUpdateAncestors)
{
- DBG_ASSERT(_pEntry, "OTableTreeListBox::implEmphasize: invalid entry (NULL)!");
+ OSL_ENSURE(_pEntry, "OTableTreeListBox::implEmphasize: invalid entry (NULL)!");
// special emphasizing handling for the "all objects" entry
- // 89709 - 16.07.2001 - frank.schoenheit@sun.com
sal_Bool bAllObjectsEntryAffected = haveVirtualRoot() && (getAllObjectsEntry() == _pEntry);
if ( GetModel()->HasChilds(_pEntry) // the entry has children
|| bAllObjectsEntryAffected // or it is the "all objects" entry
@@ -491,9 +439,9 @@ void OTableTreeListBox::InitEntry(SvLBoxEntry* _pEntry, const XubString& _rStrin
// replace the text item with our own one
SvLBoxItem* pTextItem = _pEntry->GetFirstItem(SV_ITEM_ID_LBOXSTRING);
- DBG_ASSERT(pTextItem, "OTableTreeListBox::InitEntry: no text item!?");
+ OSL_ENSURE(pTextItem, "OTableTreeListBox::InitEntry: no text item!?");
sal_uInt16 nTextPos = _pEntry->GetPos(pTextItem);
- DBG_ASSERT(((sal_uInt16)-1) != nTextPos, "OTableTreeListBox::InitEntry: no text item pos!");
+ OSL_ENSURE(((sal_uInt16)-1) != nTextPos, "OTableTreeListBox::InitEntry: no text item pos!");
_pEntry->ReplaceItem(new OBoldListboxString(_pEntry, 0, _rString), nTextPos);
}
@@ -550,13 +498,11 @@ SvLBoxEntry* OTableTreeListBox::implAddEntry(
{
pRet = InsertEntry( sName, pParentEntry, sal_False, LIST_APPEND );
- Image aImage, aImageHC;
- m_pImageProvider->getImages( _rTableName, DatabaseObject::TABLE, aImage, aImageHC );
+ Image aImage;
+ m_pImageProvider->getImages( _rTableName, DatabaseObject::TABLE, aImage );
- SetExpandedEntryBmp( pRet, aImage, BMP_COLOR_NORMAL );
- SetCollapsedEntryBmp( pRet, aImage, BMP_COLOR_NORMAL );
- SetExpandedEntryBmp( pRet, aImageHC, BMP_COLOR_HIGHCONTRAST );
- SetCollapsedEntryBmp( pRet, aImageHC, BMP_COLOR_HIGHCONTRAST );
+ SetExpandedEntryBmp( pRet, aImage );
+ SetCollapsedEntryBmp( pRet, aImage );
}
return pRet;
}
@@ -736,3 +682,4 @@ void OTableTreeListBox::removedTable( const ::rtl::OUString& _rName )
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/tabletree.src b/dbaccess/source/ui/control/tabletree.src
index d08535f3e8da..71f3945e245e 100644
--- a/dbaccess/source/ui/control/tabletree.src
+++ b/dbaccess/source/ui/control/tabletree.src
@@ -33,7 +33,6 @@
#endif
#include "browserids.hxx"
-
Menu MENU_TABLETREE_POPUP
{
ItemList =
@@ -65,24 +64,28 @@ String STR_COULDNOTCONNECT
{
Text [ en-US ] = "No connection could be established for the URL #connurl#.";
};
+
String STR_COULDNOTCONNECT_PLEASECHECK
{
Text [ en-US ] = "Please check the current settings, for example user name and password.";
};
+
String STR_NOTABLEINFO
{
Text [ en-US ] = "Successfully connected, but information about database tables is not available.";
};
+
String STR_ALL_TABLES
{
Text [ en-US ] = "All tables";
};
+
String STR_ALL_VIEWS
{
Text [ en-US ] = "All views";
};
+
String STR_ALL_TABLES_AND_VIEWS
{
Text [ en-US ] = "All tables and views";
};
-
diff --git a/dbaccess/source/ui/control/toolboxcontroller.cxx b/dbaccess/source/ui/control/toolboxcontroller.cxx
index f517f5712976..5ce59b5f804a 100644
--- a/dbaccess/source/ui/control/toolboxcontroller.cxx
+++ b/dbaccess/source/ui/control/toolboxcontroller.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,66 +28,26 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_TOOLBOXCONTROLLER_HXX
#include "toolboxcontroller.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UI_IMAGETYPE_HPP_
#include <com/sun/star/ui/ImageType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCHPROVIDER_HPP_
#include <com/sun/star/frame/XDispatchProvider.hpp>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef _SV_MENU_HXX
#include <vcl/menu.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UI_XUICONFIGURATIONMANAGER_HPP_
#include <com/sun/star/ui/XUIConfigurationManager.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XMODULEUICONFIGURATIONMANAGERSUPPLIER_HPP_
#include <com/sun/star/ui/XModuleUIConfigurationManagerSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XIMAGEMANAGER_HPP_
#include <com/sun/star/ui/XImageManager.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_IMAGETYPE_HPP_
#include <com/sun/star/ui/ImageType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_GRAPHIC_XGRAPHIC_HPP_
#include <com/sun/star/graphic/XGraphic.hpp>
-#endif
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_TOOLBOX_HXX
#include <vcl/toolbox.hxx>
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
-#ifndef INCLUDED_SVTOOLS_MISCOPT_HXX
#include <svtools/miscopt.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_MODULEOPTIONS_HXX
#include <unotools/moduleoptions.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef INCLUDED_SVTOOLS_MENUOPTIONS_HXX
#include <svtools/menuoptions.hxx>
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
-#ifndef _DBU_REGHELPER_HXX_
+#include <osl/mutex.hxx>
#include "dbu_reghelper.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
extern "C" void SAL_CALL createRegistryInfo_OToolboxController()
@@ -151,10 +112,10 @@ namespace dbaui
void SAL_CALL OToolboxController::initialize( const Sequence< Any >& _rArguments ) throw (Exception, RuntimeException)
{
ToolboxController::initialize(_rArguments);
- vos::OGuard aSolarMutexGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarMutexGuard;
::osl::MutexGuard aGuard(m_aMutex);
- if ( m_aCommandURL.equalsAscii(".uno:DBNewForm") )
+ if ( m_aCommandURL.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM(".uno:DBNewForm")) )
{
m_aStates.insert(TCommandState::value_type(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:DBNewForm")) ,sal_True));
m_aStates.insert(TCommandState::value_type(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:DBNewView")) ,sal_True));
@@ -197,7 +158,7 @@ namespace dbaui
// -----------------------------------------------------------------------------
void SAL_CALL OToolboxController::statusChanged( const FeatureStateEvent& Event ) throw ( RuntimeException )
{
- vos::OGuard aSolarMutexGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarMutexGuard;
::osl::MutexGuard aGuard(m_aMutex);
TCommandState::iterator aFind = m_aStates.find( Event.FeatureURL.Complete );
if ( aFind != m_aStates.end() )
@@ -231,8 +192,6 @@ namespace dbaui
{
pMenu.reset( new PopupMenu( ModuleRes( RID_MENU_APP_NEW ) ) );
- sal_Bool bHighContrast = isHighContrast();
-
try
{
Reference<XModuleUIConfigurationManagerSupplier> xModuleCfgMgrSupplier(getServiceManager()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ui.ModuleUIConfigurationManagerSupplier"))),UNO_QUERY);
@@ -241,8 +200,6 @@ namespace dbaui
short nImageType = hasBigImages() ? ImageType::SIZE_LARGE : ImageType::SIZE_DEFAULT;
- if ( bHighContrast )
- nImageType |= ImageType::COLOR_HIGHCONTRAST;
Sequence< ::rtl::OUString> aSeq(1);
sal_uInt16 nCount = pMenu->GetItemCount();
@@ -279,7 +236,7 @@ namespace dbaui
Reference< ::com::sun::star::awt::XWindow > SAL_CALL OToolboxController::createPopupWindow() throw (RuntimeException)
{
// execute the menu
- vos::OGuard aSolarMutexGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarMutexGuard;
::osl::MutexGuard aGuard(m_aMutex);
ToolBox* pToolBox = static_cast<ToolBox*>(VCLUnoHelper::GetWindow(getParent()));
@@ -319,3 +276,4 @@ namespace dbaui
//..........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/undosqledit.cxx b/dbaccess/source/ui/control/undosqledit.cxx
index a1c5808f91b9..edf12cb78bb7 100644
--- a/dbaccess/source/ui/control/undosqledit.cxx
+++ b/dbaccess/source/ui/control/undosqledit.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_GENERALUNDO_HXX
#include "undosqledit.hxx"
-#endif
-#ifndef DBAUI_SQLEDIT_HXX
#include "sqledit.hxx"
-#endif
namespace dbaui
{
@@ -48,3 +45,4 @@ void OSqlEditUndoAct::ToggleText()
} // namespace
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/control/undosqledit.src b/dbaccess/source/ui/control/undosqledit.src
index 814a304d18c0..aab44ad5e7db 100644
--- a/dbaccess/source/ui/control/undosqledit.src
+++ b/dbaccess/source/ui/control/undosqledit.src
@@ -33,34 +33,3 @@ String STR_QUERY_UNDO_MODIFYSQLEDIT
{
Text [ en-US ] = "Modify SQL statement(s)" ;
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/dlg/AdabasStat.cxx b/dbaccess/source/ui/dlg/AdabasStat.cxx
index 10bc3331b154..fae3a5e6efb3 100644
--- a/dbaccess/source/ui/dlg/AdabasStat.cxx
+++ b/dbaccess/source/ui/dlg/AdabasStat.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,51 +29,21 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBAUI_ADASTAT_HXX_
+#include <osl/diagnose.h>
#include "AdabasStat.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XSTATEMENT_HPP_
#include <com/sun/star/sdbc/XStatement.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSET_HPP_
#include <com/sun/star/sdbc/XResultSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef DBAUI_ADABASSTAT_HRC
#include "AdabasStat.hrc"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
using namespace dbaui;
DBG_NAME(OAdabasStatistics)
@@ -113,7 +84,7 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
FreeResource();
- DBG_ASSERT(m_xConnection.is(),"No connection");
+ OSL_ENSURE(m_xConnection.is(),"No connection");
if(m_xConnection.is())
{
Reference<XStatement> xStmt;
@@ -128,14 +99,14 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
try
{
xMetaData = m_xConnection->getMetaData();
- bCanSelect = checkSystemTable(::rtl::OUString::createFromAscii("SERVERDBSTATISTICS"),sSchema);
+ bCanSelect = checkSystemTable(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SERVERDBSTATISTICS")), sSchema);
if(bCanSelect)
{
- aStmt = ::rtl::OUString::createFromAscii("SELECT SERVERDBSIZE, UNUSEDPAGES FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT SERVERDBSIZE, UNUSEDPAGES FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".\"SERVERDBSTATISTICS\"");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".\"SERVERDBSTATISTICS\""));
xStmt = m_xConnection->createStatement();
xRes = xStmt->executeQuery(aStmt);
@@ -182,14 +153,14 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
{
try
{
- bCanSelect = checkSystemTable(::rtl::OUString::createFromAscii("DATADEVSPACES"),sSchema);
+ bCanSelect = checkSystemTable(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DATADEVSPACES")), sSchema);
if(bCanSelect)
{
// then the db files
- aStmt = ::rtl::OUString::createFromAscii("SELECT DEVSPACENAME FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT DEVSPACENAME FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".\"DATADEVSPACES\"");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".\"DATADEVSPACES\""));
xStmt = m_xConnection->createStatement();
xRes = xStmt->executeQuery(aStmt);
@@ -226,13 +197,13 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
{
try
{
- bCanSelect = checkSystemTable(::rtl::OUString::createFromAscii("CONFIGURATION"),sSchema);
+ bCanSelect = checkSystemTable(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CONFIGURATION")), sSchema);
if(bCanSelect)
{
- aStmt = ::rtl::OUString::createFromAscii("SELECT * FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT * FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".CONFIGURATION WHERE DESCRIPTION LIKE 'SYS%DEVSPACE%NAME'");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".CONFIGURATION WHERE DESCRIPTION LIKE 'SYS%DEVSPACE%NAME'"));
xStmt = m_xConnection->createStatement();
xRes = xStmt->executeQuery(aStmt);
if(xRes.is() && xRes->next())
@@ -243,9 +214,9 @@ OAdabasStatistics::OAdabasStatistics( Window* pParent,
else
showError();
- aStmt = ::rtl::OUString::createFromAscii("SELECT * FROM ");
+ aStmt = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT * FROM "));
aStmt += ::dbtools::quoteTableName(xMetaData,sSchema,::dbtools::eInDataManipulation);
- aStmt += ::rtl::OUString::createFromAscii(".CONFIGURATION WHERE DESCRIPTION = 'TRANSACTION LOG NAME'");
+ aStmt += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".CONFIGURATION WHERE DESCRIPTION = 'TRANSACTION LOG NAME'"));
xRes = xStmt->executeQuery(aStmt);
if(xRes.is() && xRes->next())
{
@@ -297,11 +268,11 @@ sal_Bool OAdabasStatistics::checkSystemTable(const ::rtl::OUString& _rsSystemTab
Reference<XDatabaseMetaData> xMeta = m_xConnection->getMetaData();
if ( xMeta.is() )
{
- Reference<XResultSet> xRes = xMeta->getTablePrivileges(Any(),::rtl::OUString::createFromAscii("%"), _rsSystemTable);
+ Reference<XResultSet> xRes = xMeta->getTablePrivileges(Any(), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("%")), _rsSystemTable);
if(xRes.is())
{
Reference<XRow> xRow(xRes,UNO_QUERY);
- static const ::rtl::OUString sSelect = ::rtl::OUString::createFromAscii("SELECT");
+ static const ::rtl::OUString sSelect(RTL_CONSTASCII_USTRINGPARAM("SELECT"));
// first the db sizes
while( xRow.is() && xRes->next() )
{
@@ -331,3 +302,4 @@ void OAdabasStatistics::showError()
// -----------------------------------------------------------------------------
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/AdabasStat.hxx b/dbaccess/source/ui/dlg/AdabasStat.hxx
index 2f222462d4df..7bba19f59724 100644
--- a/dbaccess/source/ui/dlg/AdabasStat.hxx
+++ b/dbaccess/source/ui/dlg/AdabasStat.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,27 +28,13 @@
#ifndef _DBAUI_ADASTAT_HXX_
#define _DBAUI_ADASTAT_HXX_
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _SV_DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
-#ifndef DBAUI_FIELDCONTROLS_HXX
#include "FieldControls.hxx"
-#endif
-#ifndef _PRGSBAR_HXX
#include <svtools/prgsbar.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
namespace dbaui
@@ -96,3 +83,4 @@ namespace dbaui
#endif //_DBAUI_ADASTAT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/AdabasStat.src b/dbaccess/source/ui/dlg/AdabasStat.src
index 37bf187b6c90..476750f7b531 100644
--- a/dbaccess/source/ui/dlg/AdabasStat.src
+++ b/dbaccess/source/ui/dlg/AdabasStat.src
@@ -206,33 +206,3 @@ String STR_ADABAS_ERROR_SYSTEMTABLES
{
Text [ en-US ] = "No information could be displayed because no access rights exist for the required system tables.";
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/dlg/AutoControls.src b/dbaccess/source/ui/dlg/AutoControls.src
index 1bfe3c0233a9..e43e2a13a7fb 100644
--- a/dbaccess/source/ui/dlg/AutoControls.src
+++ b/dbaccess/source/ui/dlg/AutoControls.src
@@ -69,13 +69,11 @@ String STR_MSACCESS_MDB_FILE
Text[ en-US ] = "Microsoft Access database file";
};
-
String STR_NO_ADDITIONAL_SETTINGS
{
Text[ en-US ] = "No more settings are necessary. To verify that the connection is working, click the '%test' button.";
};
-
String STR_COMMONURL
{
Text [ en-US ] = "Datasource URL" ;
@@ -85,18 +83,15 @@ String STR_HOSTNAME
{
Text[ en-US ] = "~Host name";
};
+
String STR_MOZILLA_PROFILE_NAME
{
Text[ en-US ] = "~Mozilla profile name";
};
+
String STR_THUNDERBIRD_PROFILE_NAME
{
Text[ en-US ] = "~Thunderbird profile name";
};
-
// -------------------------------------------------------------------------------------------------
-
-
-
-
diff --git a/dbaccess/source/ui/dlg/CollectionView.cxx b/dbaccess/source/ui/dlg/CollectionView.cxx
index c480fdd2093e..71ce69138934 100644
--- a/dbaccess/source/ui/dlg/CollectionView.cxx
+++ b/dbaccess/source/ui/dlg/CollectionView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,90 +28,34 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_COLLECTIONVIEW_HXX
#include "CollectionView.hxx"
-#endif
-#ifndef DBAUI_COLLECTIONVIEW_HRC
#include "CollectionView.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _COMPHELPER_INTERACTION_HXX_
#include <comphelper/interaction.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef SVT_QUERYFOLDER_HXX
#include <svtools/QueryFolderName.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XINITIALIZATION_HPP_
#include <com/sun/star/lang/XInitialization.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMECONTAINER_HPP_
#include <com/sun/star/container/XHierarchicalNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_INTERACTIVEAUGMENTEDIOEXCEPTION_HPP_
#include <com/sun/star/ucb/InteractiveAugmentedIOException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_IOERRORCODE_HPP_
#include <com/sun/star/ucb/IOErrorCode.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_INTERACTIONCLASSIFICATION_HPP_
#include <com/sun/star/task/InteractionClassification.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLEXCEPTION_HPP_
#include <com/sun/star/sdbc/SQLException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XWINDOW_HPP_
#include <com/sun/star/awt/XWindow.hpp>
-#endif
-#ifndef INCLUDED_SVTOOLS_VIEWOPTIONS_HXX
#include <unotools/viewoptions.hxx>
-#endif
-#ifndef _OSL_THREAD_H_
#include <osl/thread.h>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
#define FILEDIALOG_DEF_IMAGEBORDER 10
//.........................................................................
@@ -162,9 +107,7 @@ OCollectionView::OCollectionView( Window * pParent
m_aNewFolder.SetStyle( m_aNewFolder.GetStyle() | WB_NOPOINTERFOCUS );
m_aUp.SetModeImage(ModuleRes(IMG_NAVIGATION_BTN_UP_SC));
- m_aUp.SetModeImage(ModuleRes(IMG_NAVIGATION_BTN_UP_SCH),BMP_COLOR_HIGHCONTRAST);
m_aNewFolder.SetModeImage(ModuleRes(IMG_NAVIGATION_CREATEFOLDER_SC));
- m_aNewFolder.SetModeImage(ModuleRes(IMG_NAVIGATION_CREATEFOLDER_SCH),BMP_COLOR_HIGHCONTRAST);
m_aView.SetDoubleClickHdl( LINK( this, OCollectionView, Dbl_Click_FileView ) );
m_aView.EnableAutoResize();
@@ -268,7 +211,6 @@ IMPL_LINK( OCollectionView, Save_Click, PushButton*, EMPTYARG )
QueryBox aBox( this, WB_YES_NO, ModuleRes( STR_ALREADYEXISTOVERWRITE ) );
if ( aBox.Execute() != RET_YES )
return 0;
- // xNameContainer->removeByName(sName);
}
m_aName.SetText(sName);
EndDialog( sal_True );
@@ -395,3 +337,4 @@ void OCollectionView::initCurrentPath()
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/CollectionView.src b/dbaccess/source/ui/dlg/CollectionView.src
index 86ac75a0d9e9..e431a6502e81 100644
--- a/dbaccess/source/ui/dlg/CollectionView.src
+++ b/dbaccess/source/ui/dlg/CollectionView.src
@@ -43,14 +43,12 @@
#define FIXEDLINE_HEIGHT 1
#define IMG_SIZE 15
-
ModalDialog DLG_COLLECTION_VIEW
{
OutputSize = TRUE ;
SVLook = TRUE ;
Moveable = TRUE ;
Closeable = TRUE ;
- //Sizeable = TRUE;
HelpId = HID_EXPLORERDLG_COLLECTION ;
Size = MAP_APPFONT ( WIN_X , WIN_Y ) ;
@@ -132,7 +130,6 @@ ModalDialog DLG_COLLECTION_VIEW
Size = MAP_APPFONT ( 50 , BUTTON_HEIGHT ) ;
};
-
String STR_PATHNAME
{
Text [ en-US ] = "~Path:" ;
@@ -143,29 +140,20 @@ String STR_NEW_FOLDER
{
Text [ en-US ] = "Folder" ;
};
+
Image IMG_NAVIGATION_BTN_UP_SC
{
ImageBitmap = Bitmap { File = "fp010"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
-Image IMG_NAVIGATION_BTN_UP_SCH
-{
- ImageBitmap = Bitmap { File = "fph010"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
+
Image IMG_NAVIGATION_CREATEFOLDER_SC
{
ImageBitmap = Bitmap { File = "fp015"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
-Image IMG_NAVIGATION_CREATEFOLDER_SCH
-{
- ImageBitmap = Bitmap { File = "fph015"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
String STR_ALREADYEXISTOVERWRITE
{
Text [ en-US ] = "The file already exists. Overwrite?" ;
};
-
diff --git a/dbaccess/source/ui/dlg/ConnectionHelper.cxx b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
index 490d654a88cc..efb8a38dcfd2 100644
--- a/dbaccess/source/ui/dlg/ConnectionHelper.cxx
+++ b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,7 +31,6 @@
#include "dsnItem.hxx"
#include "ConnectionHelper.hxx"
-#include "AutoControlsDef.hrc"
#include "dbu_dlg.hrc"
#include "dbu_misc.hrc"
#include <svl/itemset.hxx>
@@ -44,6 +44,7 @@
#include "dbaccess_helpid.hrc"
#include "localresaccess.hxx"
#include <osl/process.h>
+#include <osl/diagnose.h>
#include <vcl/msgbox.hxx>
#include <sfx2/filedlghelper.hxx>
#include "dbadmin.hxx"
@@ -57,7 +58,6 @@
#include <com/sun/star/ui/dialogs/XFolderPicker.hpp>
#include <com/sun/star/sdbc/XRow.hpp>
#include <com/sun/star/awt/XWindow.hpp>
-// #106016# ------------------------------------
#include <com/sun/star/task/XInteractionHandler.hpp>
#include <com/sun/star/ucb/XProgressHandler.hpp>
#include "UITools.hxx"
@@ -69,27 +69,13 @@
#include <tools/urlobj.hxx>
#include <tools/diagnose_ex.h>
#include <sfx2/docfilt.hxx>
-#if !defined(WINDOWS_VISTA_PSDK) && defined(WNT)
-#define _ADO_DATALINK_BROWSE_
-#endif
#ifdef _ADO_DATALINK_BROWSE_
-#if defined( WNT )
- #include <tools/prewin.h>
- #include <windows.h>
- #include <tools/postwin.h>
-#endif
-#ifndef _SV_SYSDATA_HXX
#include <vcl/sysdata.hxx>
-#endif
-#ifndef _DBAUI_ADO_DATALINK_HXX_
#include "adodatalinks.hxx"
-#endif
#endif //_ADO_DATALINK_BROWSE_
-#ifndef _COM_SUN_STAR_MOZILLA_XMOZILLABOOTSTRAP_HPP_
#include <com/sun/star/mozilla/XMozillaBootstrap.hpp>
-#endif
#include <unotools/processfactory.hxx>
@@ -125,7 +111,7 @@ DBG_NAME(OConnectionHelper)
if (pCollectionItem)
m_pCollection = pCollectionItem->getCollection();
m_aPB_Connection.SetClickHdl(LINK(this, OConnectionHelper, OnBrowseConnections));
- DBG_ASSERT(m_pCollection, "OConnectionHelper::OConnectionHelper : really need a DSN type collection !");
+ OSL_ENSURE(m_pCollection, "OConnectionHelper::OConnectionHelper : really need a DSN type collection !");
m_aConnectionURL.SetTypeCollection(m_pCollection);
}
@@ -189,7 +175,7 @@ DBG_NAME(OConnectionHelper)
{
try
{
- ::rtl::OUString sFolderPickerService = ::rtl::OUString::createFromAscii(SERVICE_UI_FOLDERPICKER);
+ ::rtl::OUString sFolderPickerService(SERVICE_UI_FOLDERPICKER);
Reference< XFolderPicker > xFolderPicker(m_xORB->createInstance(sFolderPickerService), UNO_QUERY);
if (!xFolderPicker.is())
{
@@ -333,7 +319,6 @@ DBG_NAME(OConnectionHelper)
if (RET_OK == aSelector.Execute())
{
setURLNoPrefix(aSelector.GetSelected());
- // checkCreateDatabase( ::dbaccess::DST_ADABAS);
SetRoadmapStateValue(sal_True);
callModifiedHdl();
}
@@ -411,7 +396,7 @@ DBG_NAME(OConnectionHelper)
aProfiles.insert(pArray[index]);
- // excute the select dialog
+ // execute the select dialog
ODatasourceSelectDialog aSelector(GetParent(), aProfiles, eType);
::rtl::OUString sOldProfile=getURLNoPrefix();
@@ -445,13 +430,13 @@ DBG_NAME(OConnectionHelper)
void OConnectionHelper::impl_setURL( const String& _rURL, sal_Bool _bPrefix )
{
String sURL( _rURL );
- DBG_ASSERT( m_pCollection, "OConnectionHelper::impl_setURL: have no interpreter for the URLs!" );
+ OSL_ENSURE( m_pCollection, "OConnectionHelper::impl_setURL: have no interpreter for the URLs!" );
if ( m_pCollection && sURL.Len() )
{
if ( m_pCollection->isFileSystemBased( m_eType ) )
{
- // get the tow parts: prefix and file URL
+ // get the two parts: prefix and file URL
String sTypePrefix, sFileURLEncoded;
if ( _bPrefix )
{
@@ -491,13 +476,13 @@ DBG_NAME(OConnectionHelper)
// get the pure text
String sURL = _bPrefix ? m_aConnectionURL.GetText() : m_aConnectionURL.GetTextNoPrefix();
- DBG_ASSERT( m_pCollection, "OConnectionHelper::impl_getURL: have no interpreter for the URLs!" );
+ OSL_ENSURE( m_pCollection, "OConnectionHelper::impl_getURL: have no interpreter for the URLs!" );
if ( m_pCollection && sURL.Len() )
{
if ( m_pCollection->isFileSystemBased( m_eType ) )
{
- // get the tow parts: prefix and file URL
+ // get the two parts: prefix and file URL
String sTypePrefix, sFileURLDecoded;
if ( _bPrefix )
{
@@ -589,7 +574,6 @@ DBG_NAME(OConnectionHelper)
break;
case RET_NO:
- // SetRoadmapStateValue(sal_False);
callModifiedHdl();
return RET_OK;
@@ -658,7 +642,7 @@ DBG_NAME(OConnectionHelper)
}
catch(Exception&)
{
- DBG_ERROR("OConnectionHelper::getInstalledAdabasDBDirs: could not enumerate the adabas config files!");
+ OSL_FAIL("OConnectionHelper::getInstalledAdabasDBDirs: could not enumerate the adabas config files!");
}
}
@@ -702,7 +686,7 @@ DBG_NAME(OConnectionHelper)
}
return aInstalledDBs;
}
- // #106016# -------------------------------------------------------------------
+ // -----------------------------------------------------------------------------
IS_PATH_EXIST OConnectionHelper::pathExists(const ::rtl::OUString& _rURL, sal_Bool bIsFile) const
{
::ucbhelper::Content aCheckExistence;
@@ -747,7 +731,7 @@ DBG_NAME(OConnectionHelper)
return 1L; // handled
}
break;
- } // switch (_rNEvt.GetType())
+ }
}
return OGenericAdministrationPage::PreNotify( _rNEvt );
@@ -768,7 +752,6 @@ DBG_NAME(OConnectionHelper)
::std::vector< ::rtl::OUString > aToBeCreated; // the to-be-created levels
// search a level which exists
- // #106016# ---------------------
IS_PATH_EXIST eParentExists = PATH_NOT_EXIST;
while ( eParentExists == PATH_NOT_EXIST && aParser.getSegmentCount())
{
@@ -790,18 +773,18 @@ DBG_NAME(OConnectionHelper)
::rtl::OUString sContentType;
if ( INET_PROT_FILE == eProtocol )
{
- sContentType = ::rtl::OUString::createFromAscii( "application/vnd.sun.staroffice.fsys-folder" );
+ sContentType = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("application/vnd.sun.staroffice.fsys-folder"));
// the file UCP currently does not support the ContentType property
}
else
{
- Any aContentType = aParent.getPropertyValue( ::rtl::OUString::createFromAscii( "ContentType" ) );
+ Any aContentType = aParent.getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ContentType")) );
aContentType >>= sContentType;
}
// the properties which need to be set on the new content
Sequence< ::rtl::OUString > aNewDirectoryProperties(1);
- aNewDirectoryProperties[0] = ::rtl::OUString::createFromAscii("Title");
+ aNewDirectoryProperties[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Title"));
// the values to be set
Sequence< Any > aNewDirectoryAttributes(1);
@@ -861,7 +844,7 @@ DBG_NAME(OConnectionHelper)
const ::dbaccess::DATASOURCE_TYPE eType = m_pCollection->determineType(m_eType);
if ( ( ::dbaccess::DST_CALC == eType) || ( ::dbaccess::DST_MSACCESS == eType) || ( ::dbaccess::DST_MSACCESS_2007 == eType) )
- { // #106016# --------------------------
+ {
if( pathExists(sURL, sal_True) == PATH_NOT_EXIST )
{
String sFile = String( ModuleRes( STR_FILE_DOES_NOT_EXIST ) );
@@ -914,3 +897,5 @@ DBG_NAME(OConnectionHelper)
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/ConnectionHelper.hxx b/dbaccess/source/ui/dlg/ConnectionHelper.hxx
index 94c2678f9714..cd1e491dfb6b 100644
--- a/dbaccess/source/ui/dlg/ConnectionHelper.hxx
+++ b/dbaccess/source/ui/dlg/ConnectionHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef DBAUI_CONNECTIONHELPER_HXX
#define DBAUI_CONNECTIONHELPER_HXX
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _DBAUI_CURLEDIT_HXX_
#include "curledit.hxx"
-#endif
-#ifndef _SFX_FILEDLGHELPER_HXX
#include <sfx2/filedlghelper.hxx>
-#endif
#define FILL_STRING_ITEM(editcontrol, itemset, itemid, modifiedflag) \
@@ -54,7 +47,6 @@ namespace dbaui
{
//.........................................................................
- // #106016# --------------
enum IS_PATH_EXIST
{
PATH_NOT_EXIST = 0,
@@ -138,3 +130,5 @@ namespace dbaui
//.........................................................................
#endif // DBAUI_CONNECTIONHELPER_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/ConnectionPage.cxx b/dbaccess/source/ui/dlg/ConnectionPage.cxx
index 1ee072cf5c7a..96ed31cd2f09 100644
--- a/dbaccess/source/ui/dlg/ConnectionPage.cxx
+++ b/dbaccess/source/ui/dlg/ConnectionPage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,147 +29,55 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_CONNECTIONPAGE_HXX
#include "ConnectionPage.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONPAGE_HRC
#include "ConnectionPage.hrc"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef DBACCESS_DSMETA_HXX
#include "dsmeta.hxx"
-#endif
-#ifndef _SFXITEMSET_HXX
#include <svl/itemset.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
#include <unotools/pathoptions.hxx>
-#endif
-#ifndef _SFXSTRITEM_HXX
#include <svl/stritem.hxx>
-#endif
-#ifndef _SFXENUMITEM_HXX
#include <svl/eitem.hxx>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_MODULEOPTIONS_HXX
#include <unotools/moduleoptions.hxx>
-#endif
-#ifndef _DBAUI_DATASOURCEITEMS_HXX_
#include "dsitems.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBAUI_LOCALRESACCESS_HXX_
#include "localresaccess.hxx"
-#endif
-#ifndef _OSL_PROCESS_H_
#include <osl/process.h>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _FILEDLGHELPER_HXX
#include <sfx2/filedlghelper.hxx>
-#endif
-#ifndef _DBAUI_DBADMIN_HXX_
#include "dbadmin.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _VCL_STDTEXT_HXX
#include <vcl/stdtext.hxx>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _DBAUI_ODBC_CONFIG_HXX_
#include "odbcconfig.hxx"
-#endif
-#ifndef _DBAUI_DSSELECT_HXX_
#include "dsselect.hxx"
-#endif
-#ifndef SVTOOLS_FILENOTATION_HXX_
#include <svl/filenotation.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XFOLDERPICKER_HPP_
#include <com/sun/star/ui/dialogs/XFolderPicker.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XWINDOW_HPP_
#include <com/sun/star/awt/XWindow.hpp>
-#endif
-// #106016# ------------------------------------
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XPROGRESSHANDLER_HPP_
#include <com/sun/star/ucb/XProgressHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_EXTENDEDFILEPICKERELEMENTIDS_HPP_
#include <com/sun/star/ui/dialogs/ExtendedFilePickerElementIds.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XFILEPICKERCONTROLACCESS_HPP_
#include <com/sun/star/ui/dialogs/XFilePickerControlAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XFILEPICKER_HPP_
#include <com/sun/star/ui/dialogs/XFilePicker.hpp>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _UNOTOOLS_LOCALFILEHELPER_HXX
#include <unotools/localfilehelper.hxx>
-#endif
-#ifndef _UNOTOOLS_UCBHELPER_HXX
#include <unotools/ucbhelper.hxx>
-#endif
-#ifndef _UCBHELPER_COMMANDENVIRONMENT_HXX
#include <ucbhelper/commandenvironment.hxx>
-#endif
-#ifndef DBAUI_FILEPICKER_INTERACTION_HXX
#include "finteraction.hxx"
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef _SFX_DOCFILT_HACK_HXX
#include <sfx2/docfilt.hxx>
-#endif
#include "dsnItem.hxx"
#if defined(WNT)
#define _ADO_DATALINK_BROWSE_
#endif
#ifdef _ADO_DATALINK_BROWSE_
-#if defined( WNT )
- #include <tools/prewin.h>
- #include <windows.h>
- #include <tools/postwin.h>
-#endif
-#ifndef _SV_SYSDATA_HXX
#include <vcl/sysdata.hxx>
-#endif
-#ifndef _DBAUI_ADO_DATALINK_HXX_
#include "adodatalinks.hxx"
-#endif
#endif //_ADO_DATALINK_BROWSE_
#include "AutoControlsDef.hrc"
@@ -355,7 +264,7 @@ namespace dbaui
m_aJavaDriver.SetText(sDefaultJdbcDriverName);
m_aJavaDriver.SetModifyFlag();
}
- } // if ( !pJdbcDrvItem->GetValue().Len() )
+ }
else
m_aJavaDriver.SetText(pJdbcDrvItem->GetValue());
@@ -466,3 +375,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/ConnectionPage.hxx b/dbaccess/source/ui/dlg/ConnectionPage.hxx
index 6406b9547427..bd0034a22a91 100644
--- a/dbaccess/source/ui/dlg/ConnectionPage.hxx
+++ b/dbaccess/source/ui/dlg/ConnectionPage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef DBAUI_CONNECTIONPAGE_HXX
#define DBAUI_CONNECTIONPAGE_HXX
-#ifndef DBAUI_CONNECTIONHELPER_HXX
#include "ConnectionHelper.hxx"
-#endif
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _DBAUI_CURLEDIT_HXX_
#include "curledit.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -112,3 +105,5 @@ namespace dbaui
//.........................................................................
#endif // _DBAUI_DETAILPAGES_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/ConnectionPage.src b/dbaccess/source/ui/dlg/ConnectionPage.src
index 33b70033b0f0..63c400b0a77a 100644
--- a/dbaccess/source/ui/dlg/ConnectionPage.src
+++ b/dbaccess/source/ui/dlg/ConnectionPage.src
@@ -55,10 +55,8 @@ TabPage PAGE_CONNECTION
Text[ en-US ] = "General";
};
-
AUTO_BROWSECONTROLGROUP( 6, UNRELATED_CONTROLS + FIXEDTEXT_HEIGHT + RELATED_CONTROLS, PAGE_X, HID_DSADMIN_URL_GENERAL, HID_DSADMIN_BROWSECONN)
-
FixedText FT_NO_ADDITIONAL_SETTINGS
{
Hide = TRUE;
@@ -67,7 +65,6 @@ TabPage PAGE_CONNECTION
Size = MAP_APPFONT ( PAGE_X - 12 , 3*FIXEDTEXT_HEIGHT ) ;
};
-
FixedText FT_HOSTNAME
{
Hide = TRUE;
@@ -76,7 +73,6 @@ TabPage PAGE_CONNECTION
Text[ en-US ] = "~Host name";
};
-
FixedLine FL_SEPARATOR2
{
Pos = MAP_APPFONT ( 4 , 3*FIXEDTEXT_HEIGHT + 3*UNRELATED_CONTROLS + RELATED_CONTROLS ) ;
@@ -90,6 +86,7 @@ TabPage PAGE_CONNECTION
Size = MAP_APPFONT ( 90 - 12 , FIXEDTEXT_HEIGHT ) ;
Text [ en-US ] = "~User name" ;
};
+
Edit ET_USERNAME
{
HelpID = "dbaccess:Edit:PAGE_CONNECTION:ET_USERNAME";
@@ -98,6 +95,7 @@ TabPage PAGE_CONNECTION
Size = MAP_APPFONT ( 105 , EDIT_HEIGHT ) ;
TabStop = TRUE ;
};
+
CheckBox CB_PASSWORD_REQUIRED
{
HelpID = "dbaccess:CheckBox:PAGE_CONNECTION:CB_PASSWORD_REQUIRED";
@@ -121,6 +119,7 @@ TabPage PAGE_CONNECTION
Size = MAP_APPFONT ( 90 - 12 , FIXEDTEXT_HEIGHT ) ;
Text [ en-US ] = "~JDBC driver class" ;
};
+
Edit ET_JDBCDRIVERCLASS
{
Border = TRUE ;
@@ -189,4 +188,3 @@ String STR_MSACCESS_2007_FILTERNAME
{
Text [ en-US ] = "MS Access 2007 file";
};
-
diff --git a/dbaccess/source/ui/dlg/ConnectionPageSetup.cxx b/dbaccess/source/ui/dlg/ConnectionPageSetup.cxx
index ae86566ec210..1bfab47ead99 100644
--- a/dbaccess/source/ui/dlg/ConnectionPageSetup.cxx
+++ b/dbaccess/source/ui/dlg/ConnectionPageSetup.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_CONNECTIONPAGESETUP_HXX
#include "ConnectionPageSetup.hxx"
-#endif
#include "AutoControlsDef.hrc"
#include "dbadminsetup.hrc"
#include "dbu_dlg.hrc"
@@ -57,7 +56,6 @@
#include <com/sun/star/ui/dialogs/XFolderPicker.hpp>
#include <com/sun/star/sdbc/XRow.hpp>
#include <com/sun/star/awt/XWindow.hpp>
-// #106016# ------------------------------------
#include <com/sun/star/task/XInteractionHandler.hpp>
#include <com/sun/star/ucb/XProgressHandler.hpp>
#include <com/sun/star/sdbc/XConnection.hpp>
@@ -204,7 +202,7 @@ namespace dbaui
//{
// String sDisplayName = m_pCollection->getTypeDisplayName(m_eType);
// FixedText* ppTextControls[] ={&m_aFT_Connection};
- // for (size_t i = 0; i < sizeof(ppTextControls)/sizeof(ppTextControls[0]); ++i)
+ // for (size_t i = 0; i < SAL_N_ELEMENTS(ppTextControls); ++i)
// {
// ppTextControls[i]->SetText(sDisplayName);
// }
@@ -243,3 +241,4 @@ namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/ConnectionPageSetup.hxx b/dbaccess/source/ui/dlg/ConnectionPageSetup.hxx
index 01f25b1ac175..0fd31cf58101 100644
--- a/dbaccess/source/ui/dlg/ConnectionPageSetup.hxx
+++ b/dbaccess/source/ui/dlg/ConnectionPageSetup.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,37 +29,19 @@
#ifndef DBAUI_CONNECTIONPAGESETUP_HXX
#define DBAUI_CONNECTIONPAGESETUP_HXX
-#ifndef DBAUI_CONNECTIONHELPER_HXX
#include "ConnectionHelper.hxx"
-#endif
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _DBAUI_CURLEDIT_HXX_
#include "curledit.hxx"
-#endif
-#ifndef _SV_FIELD_HXX
#include <vcl/field.hxx>
-#endif
//.........................................................................
namespace dbaui
{
//.........................................................................
-/* // #106016# --------------
- enum IS_PATH_EXIST
- {
- PATH_NOT_EXIST = 0,
- PATH_EXIST,
- PATH_NOT_KNOWN
- };
- */
class IDatabaseSettingsDialog;
//=========================================================================
@@ -115,3 +98,5 @@ namespace dbaui
//.........................................................................
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
index 374d15ec3588..0253c97a1fba 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,76 +28,33 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_DBSETUPCONNECTIONPAGES_HXX
#include "DBSetupConnectionPages.hxx"
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
#include "AutoControlsDef.hrc"
-#ifndef _DBAUI_DBADMINSETUP_HRC_
#include "dbadminsetup.hrc"
-#endif
-#ifndef _SFXITEMSET_HXX
#include <svl/itemset.hxx>
-#endif
-#ifndef _SFXSTRITEM_HXX
#include <svl/stritem.hxx>
-#endif
-#ifndef _SFXENUMITEM_HXX
#include <svl/eitem.hxx>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef _DBAUI_DATASOURCEITEMS_HXX_
#include "dsitems.hxx"
-#endif
#include "dsnItem.hxx"
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBAUI_LOCALRESACCESS_HXX_
#include "localresaccess.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _SV_MNEMONIC_HXX
#include <vcl/mnemonic.hxx>
-#endif
-#ifndef _SVTOOLS_CJKOPTIONS_HXX
#include <svl/cjkoptions.hxx>
-#endif
#include <jvmaccess/virtualmachine.hxx>
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef DBAUI_DRIVERSETTINGS_HXX
#include "DriverSettings.hxx"
-#endif
-#ifndef _DBAUI_DBADMIN_HXX_
#include "dbadmin.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XFOLDERPICKER_HPP_
#include <com/sun/star/ui/dialogs/XFolderPicker.hpp>
-#endif
-// #106016# ------------------------------------
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
#include <com/sun/star/sdbc/XDriverAccess.hpp>
#include "dbustrings.hrc"
-#ifndef SVTOOLS_FILENOTATION_HXX_
#include <svl/filenotation.hxx>
-#endif
#include <unotools/localfilehelper.hxx>
#include <unotools/ucbhelper.hxx>
@@ -107,6 +65,7 @@
#include <unotools/pathoptions.hxx>
#include <svtools/roadmapwizard.hxx>
#include "TextConnectionHelper.hxx"
+#include <osl/diagnose.h>
//.........................................................................
@@ -114,14 +73,6 @@ namespace dbaui
{
//.........................................................................
using namespace ::com::sun::star;
-// using namespace ::com::sun::star::ucb;
-// using namespace ::com::sun::star::ui::dialogs;
-// using namespace ::com::sun::star::sdbc;
-// using namespace ::com::sun::star::beans;
-// using namespace ::com::sun::star::lang;
-// using namespace ::com::sun::star::container;
-// using namespace ::dbtools;
-// using namespace ::svt;
OGenericAdministrationPage* OTextConnectionPageSetup::CreateTextTabPage( Window* pParent, const SfxItemSet& _rAttrSet )
{
@@ -251,7 +202,7 @@ DBG_NAME(OTextConnectionPageSetup)
::dbaccess::ODsnTypeCollection* pCollection = NULL;
if (pCollectionItem)
pCollection = pCollectionItem->getCollection();
- DBG_ASSERT(pCollection, "OLDAPConnectionPageSetup::FillItemSet : really need a DSN type collection !");
+ OSL_ENSURE(pCollection, "OLDAPConnectionPageSetup::FillItemSet : really need a DSN type collection !");
String sUrl = pCollection->getPrefix( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:address:ldap:")));
sUrl += m_aETHostServer.GetText();
@@ -259,7 +210,6 @@ DBG_NAME(OTextConnectionPageSetup)
bChangedSomething = sal_True;
}
- // fillString(_rSet,&m_aETHostServer, DSID_CONNECTURL, bChangedSomething);
fillBool(_rSet,&m_aCBUseSSL,DSID_CONN_LDAP_USESSL,bChangedSomething);
return bChangedSomething;
}
@@ -385,7 +335,7 @@ DBG_NAME(OMySQLIntroPageSetup)
// -----------------------------------------------------------------------
sal_Bool OMySQLIntroPageSetup::FillItemSet(SfxItemSet& /*_rSet*/)
{
- OSL_ENSURE(sal_False,"Who called me?! Please ask oj for more information.");
+ OSL_FAIL("Who called me?! Please ask oj for more information.");
return sal_True;
}
@@ -705,8 +655,8 @@ DBG_NAME(OMySQLIntroPageSetup)
{
m_aETDriverClass.SetText(sDefaultJdbcDriverName);
m_aETDriverClass.SetModifyFlag();
- } // if ( sDefaultJdbcDriverName.Len() )
- } // if ( !pJdbcDrvItem->GetValue().Len() )
+ }
+ }
else
{
m_aETDriverClass.SetText(pDrvItem->GetValue());
@@ -727,7 +677,6 @@ DBG_NAME(OMySQLIntroPageSetup)
sal_Bool bEnableTestConnection = !m_aConnectionURL.IsVisible() || (m_aConnectionURL.GetTextNoPrefix().Len() != 0);
bEnableTestConnection = bEnableTestConnection && (m_aETDriverClass.GetText().Len() != 0);
return bEnableTestConnection;
-// m_aTestConnection.Enable(bEnableTestConnection);
}
@@ -943,7 +892,7 @@ DBG_NAME(OFinalDBPageSetup)
Point aPos(m_aFTFinalHeader.GetPosPixel());
Size aStart(m_aFTFinalHeader.GetSizePixel());
aPos.Y() += aStart.Height() + nUnrelatedHeight;
- sal_Int32 nCount = sizeof(pWindows) / sizeof(pWindows[0]);
+ sal_Int32 nCount = SAL_N_ELEMENTS(pWindows);
for (sal_Int32 i=0; i < nCount; ++i)
{
aPos.X() = pWindows[i].first->GetPosPixel().X();
@@ -1025,3 +974,5 @@ DBG_NAME(OFinalDBPageSetup)
}
// namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
index 441bd61fd61d..00fe40ffbce1 100644
--- a/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
+++ b/dbaccess/source/ui/dlg/DBSetupConnectionPages.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBAUI_DBSETUPCONNECTIONPAGES_HXX
#define DBAUI_DBSETUPCONNECTIONPAGES_HXX
-#ifndef DBAUI_CONNECTIONPAGESETUP_HXX
#include "ConnectionPageSetup.hxx"
-#endif
#include "adminpages.hxx"
#include "admincontrols.hxx"
@@ -49,7 +48,6 @@ namespace dbaui
//.........................................................................
class IDatabaseSettingsDialog;
-// static OGenericAdministrationPage* CreateDbaseTabPage( Window* pParent, const SfxItemSet& _rAttrSet );
//========================================================================
@@ -342,3 +340,5 @@ namespace dbaui
//.........................................................................
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/DbAdminImpl.cxx b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
index 852a5556415c..b3145475143b 100644
--- a/dbaccess/source/ui/dlg/DbAdminImpl.cxx
+++ b/dbaccess/source/ui/dlg/DbAdminImpl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -75,15 +76,18 @@
#include <svl/stritem.hxx>
#include <tools/urlobj.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <typelib/typedescription.hxx>
#include <vcl/svapp.hxx>
#include <vcl/msgbox.hxx>
#include <vcl/stdtext.hxx>
#include <vcl/waitobj.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#include <algorithm>
#include <functional>
+#include <o3tl/compat_functional.hxx>
+
//.........................................................................
namespace dbaui
{
@@ -109,7 +113,7 @@ namespace
sal_Bool bCorrectType = sal_False;
SfxItemPool* pPool = _rSet.GetPool();
- DBG_ASSERT( pPool, "implCheckItemType: invalid item pool!" );
+ OSL_ENSURE( pPool, "implCheckItemType: invalid item pool!" );
if ( pPool )
{
const SfxPoolItem& rDefItem = pPool->GetDefaultItem( _nId );
@@ -127,11 +131,11 @@ namespace
}
catch(Exception&)
{
- #ifdef DBG_UTIL
+ #if OSL_DEBUG_LEVEL > 0
::rtl::OString sMessage("ODbAdminDialog::implTranslateProperty: could not set the property ");
sMessage += ::rtl::OString(_rName.getStr(), _rName.getLength(), RTL_TEXTENCODING_ASCII_US);
sMessage += ::rtl::OString("!");
- DBG_ERROR(sMessage.getStr());
+ OSL_FAIL(sMessage.getStr());
#endif
}
@@ -208,18 +212,18 @@ ODbDataSourceAdministrationHelper::ODbDataSourceAdministrationHelper(const Refer
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_MAX_ROW_SCAN, ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "MaxRowScan" ) ) ) );
// special settings for adabas
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_SHUTSERVICE, ::rtl::OUString::createFromAscii("ShutdownDatabase")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_DATAINC, ::rtl::OUString::createFromAscii("DataCacheSizeIncrement")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CACHESIZE, ::rtl::OUString::createFromAscii("DataCacheSize")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLUSER, ::rtl::OUString::createFromAscii("ControlUser")));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLPWD, ::rtl::OUString::createFromAscii("ControlPassword")));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_SHUTSERVICE, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ShutdownDatabase"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_DATAINC, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataCacheSizeIncrement"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CACHESIZE, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DataCacheSize"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLUSER, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ControlUser"))));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_CTRLPWD, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ControlPassword"))));
// extra settings for odbc
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_USECATALOG, INFO_USECATALOG));
// extra settings for a ldap address book
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_BASEDN, INFO_CONN_LDAP_BASEDN));
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_ROWCOUNT, INFO_CONN_LDAP_ROWCOUNT));
- m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_USESSL, ::rtl::OUString::createFromAscii("UseSSL")));
+ m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_CONN_LDAP_USESSL, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("UseSSL"))));
m_aIndirectPropTranslator.insert(MapInt2String::value_type(DSID_DOCUMENT_URL, PROPERTY_URL));
// oracle
@@ -239,12 +243,12 @@ ODbDataSourceAdministrationHelper::ODbDataSourceAdministrationHelper(const Refer
ShowServiceNotAvailableError(_pParent->GetParent(), String(SERVICE_SDB_DATABASECONTEXT), sal_True);
}
- DBG_ASSERT(m_xDynamicContext.is(), "ODbAdminDialog::ODbAdminDialog : no XNamingService interface !");
+ OSL_ENSURE(m_xDynamicContext.is(), "ODbAdminDialog::ODbAdminDialog : no XNamingService interface !");
}
//-------------------------------------------------------------------------
sal_Bool ODbDataSourceAdministrationHelper::getCurrentSettings(Sequence< PropertyValue >& _rDriverParam)
{
- DBG_ASSERT(m_pItemSetHelper->getOutputSet(), "ODbDataSourceAdministrationHelper::getCurrentSettings : not to be called without an example set!");
+ OSL_ENSURE(m_pItemSetHelper->getOutputSet(), "ODbDataSourceAdministrationHelper::getCurrentSettings : not to be called without an example set!");
if (!m_pItemSetHelper->getOutputSet())
return sal_False;
@@ -324,7 +328,7 @@ sal_Bool ODbDataSourceAdministrationHelper::getCurrentSettings(Sequence< Propert
// handle the request
try
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
// release the mutex when calling the handler, it may need to lock the SolarMutex
xHandler->handle(xRequest);
}
@@ -357,7 +361,7 @@ sal_Bool ODbDataSourceAdministrationHelper::getCurrentSettings(Sequence< Propert
//-------------------------------------------------------------------------
void ODbDataSourceAdministrationHelper::successfullyConnected()
{
- DBG_ASSERT(m_pItemSetHelper->getOutputSet(), "ODbDataSourceAdministrationHelper::successfullyConnected: not to be called without an example set!");
+ OSL_ENSURE(m_pItemSetHelper->getOutputSet(), "ODbDataSourceAdministrationHelper::successfullyConnected: not to be called without an example set!");
if (!m_pItemSetHelper->getOutputSet())
return;
@@ -423,7 +427,7 @@ Reference< XDriver > ODbDataSourceAdministrationHelper::getDriver(const ::rtl::O
try
{
xDriverManager = Reference< XDriverAccess >(getORB()->createInstance(SERVICE_SDBC_CONNECTIONPOOL), UNO_QUERY);
- DBG_ASSERT(xDriverManager.is(), "ODbDataSourceAdministrationHelper::getDriver: could not instantiate the driver manager, or it does not provide the necessary interface!");
+ OSL_ENSURE(xDriverManager.is(), "ODbDataSourceAdministrationHelper::getDriver: could not instantiate the driver manager, or it does not provide the necessary interface!");
}
catch (Exception& e)
{
@@ -478,16 +482,16 @@ Reference< XPropertySet > ODbDataSourceAdministrationHelper::getCurrentDataSourc
}
- DBG_ASSERT(m_xDatasource.is(), "ODbDataSourceAdministrationHelper::getCurrentDataSource: no data source!");
+ OSL_ENSURE(m_xDatasource.is(), "ODbDataSourceAdministrationHelper::getCurrentDataSource: no data source!");
return m_xDatasource;
}
//-------------------------------------------------------------------------
::rtl::OUString ODbDataSourceAdministrationHelper::getDatasourceType( const SfxItemSet& _rSet )
{
SFX_ITEMSET_GET( _rSet, pConnectURL, SfxStringItem, DSID_CONNECTURL, sal_True );
- DBG_ASSERT( pConnectURL , "ODbDataSourceAdministrationHelper::getDatasourceType: invalid items in the source set!" );
+ OSL_ENSURE( pConnectURL , "ODbDataSourceAdministrationHelper::getDatasourceType: invalid items in the source set!" );
SFX_ITEMSET_GET(_rSet, pTypeCollection, DbuTypeCollectionItem, DSID_TYPECOLLECTION, sal_True);
- DBG_ASSERT(pTypeCollection, "ODbDataSourceAdministrationHelper::getDatasourceType: invalid items in the source set!");
+ OSL_ENSURE(pTypeCollection, "ODbDataSourceAdministrationHelper::getDatasourceType: invalid items in the source set!");
::dbaccess::ODsnTypeCollection* pCollection = pTypeCollection->getCollection();
return pCollection->getType(pConnectURL->GetValue());
}
@@ -508,9 +512,9 @@ String ODbDataSourceAdministrationHelper::getConnectionURL() const
SFX_ITEMSET_GET(*m_pItemSetHelper->getOutputSet(), pTypeCollection, DbuTypeCollectionItem, DSID_TYPECOLLECTION, sal_True);
OSL_ENSURE(pUrlItem,"Connection URL is NULL. -> GPF!");
- DBG_ASSERT(pTypeCollection, "ODbDataSourceAdministrationHelper::getDatasourceType: invalid items in the source set!");
+ OSL_ENSURE(pTypeCollection, "ODbDataSourceAdministrationHelper::getDatasourceType: invalid items in the source set!");
::dbaccess::ODsnTypeCollection* pCollection = pTypeCollection->getCollection();
- DBG_ASSERT(pCollection, "ODbDataSourceAdministrationHelper::getDatasourceType: invalid type collection!");
+ OSL_ENSURE(pCollection, "ODbDataSourceAdministrationHelper::getDatasourceType: invalid type collection!");
switch( pCollection->determineType(eType) )
{
@@ -587,7 +591,6 @@ String ODbDataSourceAdministrationHelper::getConnectionURL() const
break;
case ::dbaccess::DST_LDAP:
{
- // SFX_ITEMSET_GET(*m_pItemSetHelper->getOutputSet(), pHostName, SfxStringItem, DSID_CONN_HOSTNAME, sal_True);
SFX_ITEMSET_GET(*m_pItemSetHelper->getOutputSet(), pPortNumber, SfxInt32Item, DSID_CONN_LDAP_PORTNUMBER, sal_True);
sNewUrl = pCollection->cutPrefix(pUrlItem->GetValue());
sNewUrl += lcl_createHostWithPort(NULL,pPortNumber);
@@ -638,11 +641,11 @@ void ODbDataSourceAdministrationHelper::translateProperties(const Reference< XPr
}
catch(Exception&)
{
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
::rtl::OString aMessage("ODbDataSourceAdministrationHelper::translateProperties: could not extract the property ");
aMessage += ::rtl::OString(aDirect->second.getStr(), aDirect->second.getLength(), RTL_TEXTENCODING_ASCII_US);
aMessage += ::rtl::OString("!");
- DBG_ERROR(aMessage.getStr());
+ OSL_FAIL(aMessage.getStr());
#endif
}
// transfer it into an item
@@ -665,7 +668,7 @@ void ODbDataSourceAdministrationHelper::translateProperties(const Reference< XPr
if (0 == pAdditionalInfo->Name.compareToAscii("JDBCDRV"))
{ // compatibility
PropertyValue aCompatibility(*pAdditionalInfo);
- aCompatibility.Name = ::rtl::OUString::createFromAscii("JavaDriverClass");
+ aCompatibility.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("JavaDriverClass"));
aInfos.insert(aCompatibility);
}
else
@@ -701,14 +704,14 @@ void ODbDataSourceAdministrationHelper::translateProperties(const Reference< XPr
}
catch(Exception&)
{
- OSL_ENSURE(0,"IsReadOnly throws an exception!");
+ OSL_FAIL("IsReadOnly throws an exception!");
}
}
//-------------------------------------------------------------------------
void ODbDataSourceAdministrationHelper::translateProperties(const SfxItemSet& _rSource, const Reference< XPropertySet >& _rxDest)
{
- DBG_ASSERT(_rxDest.is(), "ODbDataSourceAdministrationHelper::translateProperties: invalid property set!");
+ OSL_ENSURE(_rxDest.is(), "ODbDataSourceAdministrationHelper::translateProperties: invalid property set!");
if (!_rxDest.is())
return;
@@ -834,14 +837,13 @@ void ODbDataSourceAdministrationHelper::fillDatasourceInfo(const SfxItemSet& _rS
// * are known as indirect properties
// * but not relevant for the current data source type
// These settings have to be removed: If they're not relevant, we have no UI for changing them.
- // 25.06.2001 - 88004/87182 - frank.schoenheit@sun.com
// for this, we need a string-controlled quick access to m_aIndirectPropTranslator
StringSet aIndirectProps;
::std::transform(m_aIndirectPropTranslator.begin(),
m_aIndirectPropTranslator.end(),
::std::insert_iterator<StringSet>(aIndirectProps,aIndirectProps.begin()),
- ::std::select2nd<MapInt2String::value_type>());
+ ::o3tl::select2nd<MapInt2String::value_type>());
// now check the to-be-preserved props
::std::vector< sal_Int32 > aRemoveIndexes;
@@ -854,7 +856,7 @@ void ODbDataSourceAdministrationHelper::fillDatasourceInfo(const SfxItemSet& _rS
{
if (aIndirectProps.end() != aIndirectProps.find(aPreserved->second))
{
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
const ::rtl::OUString sName = aPreserved->second;
#endif
aRemoveIndexes.push_back(aPreserved->first - nPositionCorrector);
@@ -868,7 +870,7 @@ void ODbDataSourceAdministrationHelper::fillDatasourceInfo(const SfxItemSet& _rS
++aRemoveIndex
)
::comphelper::removeElementAt(_rInfo, *aRemoveIndex);
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
const PropertyValue* pWhatsLeft = _rInfo.getConstArray();
const PropertyValue* pWhatsLeftEnd = pWhatsLeft + _rInfo.getLength();
for (; pWhatsLeft != pWhatsLeftEnd; ++pWhatsLeft)
@@ -949,7 +951,7 @@ Any ODbDataSourceAdministrationHelper::implTranslateProperty(const SfxPoolItem*
}
else
{
- DBG_ERROR("ODbDataSourceAdministrationHelper::implTranslateProperty: unsupported item type!");
+ OSL_FAIL("ODbDataSourceAdministrationHelper::implTranslateProperty: unsupported item type!");
return aValue;
}
@@ -961,7 +963,8 @@ void ODbDataSourceAdministrationHelper::implTranslateProperty(const Reference< X
Any aValue = implTranslateProperty(_pItem);
lcl_putProperty(_rxSet, _rName,aValue);
}
-#ifdef DBG_UTIL
+
+#if OSL_DEBUG_LEVEL > 0
//-------------------------------------------------------------------------
::rtl::OString ODbDataSourceAdministrationHelper::translatePropertyId( sal_Int32 _nId )
{
@@ -997,7 +1000,7 @@ void ODbDataSourceAdministrationHelper::implTranslateProperty( SfxItemSet& _rSet
_rSet.Put(SfxStringItem(_nId, sValue.getStr()));
}
else {
- DBG_ERROR(
+ OSL_FAIL(
( ::rtl::OString( "ODbDataSourceAdministrationHelper::implTranslateProperty: invalid property value (" )
+= ::rtl::OString( translatePropertyId( _nId ) )
+= ::rtl::OString( " should be no string)!" )
@@ -1027,7 +1030,7 @@ void ODbDataSourceAdministrationHelper::implTranslateProperty( SfxItemSet& _rSet
_rSet.Put( aItem );
}
else {
- DBG_ERROR(
+ OSL_FAIL(
( ::rtl::OString( "ODbDataSourceAdministrationHelper::implTranslateProperty: invalid property value (" )
+= ::rtl::OString( translatePropertyId( _nId ) )
+= ::rtl::OString( " should be no boolean)!" )
@@ -1044,7 +1047,7 @@ void ODbDataSourceAdministrationHelper::implTranslateProperty( SfxItemSet& _rSet
_rSet.Put( SfxInt32Item( _nId, nValue ) );
}
else {
- DBG_ERROR(
+ OSL_FAIL(
( ::rtl::OString( "ODbDataSourceAdministrationHelper::implTranslateProperty: invalid property value (" )
+= ::rtl::OString( translatePropertyId( _nId ) )
+= ::rtl::OString( " should be no int)!" )
@@ -1060,7 +1063,7 @@ void ODbDataSourceAdministrationHelper::implTranslateProperty( SfxItemSet& _rSet
TypeDescription aTD(_rValue.getValueType());
typelib_IndirectTypeDescription* pSequenceTD =
reinterpret_cast< typelib_IndirectTypeDescription* >(aTD.get());
- DBG_ASSERT(pSequenceTD && pSequenceTD->pType, "ODbDataSourceAdministrationHelper::implTranslateProperty: invalid sequence type!");
+ OSL_ENSURE(pSequenceTD && pSequenceTD->pType, "ODbDataSourceAdministrationHelper::implTranslateProperty: invalid sequence type!");
Type aElementType(pSequenceTD->pType);
switch (aElementType.getTypeClass())
@@ -1073,11 +1076,11 @@ void ODbDataSourceAdministrationHelper::implTranslateProperty( SfxItemSet& _rSet
}
break;
default:
- DBG_ERROR("ODbDataSourceAdministrationHelper::implTranslateProperty: unsupported property value type!");
+ OSL_FAIL("ODbDataSourceAdministrationHelper::implTranslateProperty: unsupported property value type!");
}
}
else {
- DBG_ERROR(
+ OSL_FAIL(
( ::rtl::OString( "ODbDataSourceAdministrationHelper::implTranslateProperty: invalid property value (" )
+= ::rtl::OString( translatePropertyId( _nId ) )
+= ::rtl::OString( " should be no string sequence)!" )
@@ -1091,7 +1094,7 @@ void ODbDataSourceAdministrationHelper::implTranslateProperty( SfxItemSet& _rSet
break;
default:
- DBG_ERROR("ODbDataSourceAdministrationHelper::implTranslateProperty: unsupported property value type!");
+ OSL_FAIL("ODbDataSourceAdministrationHelper::implTranslateProperty: unsupported property value type!");
}
}
@@ -1113,14 +1116,13 @@ void ODbDataSourceAdministrationHelper::convertUrl(SfxItemSet& _rDest)
SFX_ITEMSET_GET(_rDest, pTypeCollection, DbuTypeCollectionItem, DSID_TYPECOLLECTION, sal_True);
OSL_ENSURE(pUrlItem,"Connection URL is NULL. -> GPF!");
- DBG_ASSERT(pTypeCollection, "ODbAdminDialog::getDatasourceType: invalid items in the source set!");
+ OSL_ENSURE(pTypeCollection, "ODbAdminDialog::getDatasourceType: invalid items in the source set!");
::dbaccess::ODsnTypeCollection* pCollection = pTypeCollection->getCollection();
- DBG_ASSERT(pCollection, "ODbAdminDialog::getDatasourceType: invalid type collection!");
+ OSL_ENSURE(pCollection, "ODbAdminDialog::getDatasourceType: invalid type collection!");
sal_uInt16 nPortNumberId = 0;
sal_Int32 nPortNumber = -1;
String sNewHostName;
- //String sUrl = pCollection->cutPrefix(pUrlItem->GetValue());
String sUrlPart;
pCollection->extractHostNamePort(pUrlItem->GetValue(),sUrlPart,sNewHostName,nPortNumber);
@@ -1178,7 +1180,7 @@ sal_Bool ODbDataSourceAdministrationHelper::saveChanges(const SfxItemSet& _rSour
// -----------------------------------------------------------------------------
void ODbDataSourceAdministrationHelper::setDataSourceOrName( const Any& _rDataSourceOrName )
{
- DBG_ASSERT( !m_aDataSourceOrName.hasValue(), "ODbDataSourceAdministrationHelper::setDataSourceOrName: already have one!" );
+ OSL_ENSURE( !m_aDataSourceOrName.hasValue(), "ODbDataSourceAdministrationHelper::setDataSourceOrName: already have one!" );
// hmm. We could reset m_xDatasource/m_xModel, probably, and continue working
m_aDataSourceOrName = _rDataSourceOrName;
}
@@ -1219,3 +1221,4 @@ SfxPoolItem* DbuTypeCollectionItem::Clone(SfxItemPool* /*_pPool*/) const
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/DbAdminImpl.hxx b/dbaccess/source/ui/dlg/DbAdminImpl.hxx
index 4ed86867618e..2e4c2b251a53 100644
--- a/dbaccess/source/ui/dlg/DbAdminImpl.hxx
+++ b/dbaccess/source/ui/dlg/DbAdminImpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,39 +29,17 @@
#ifndef _DBAUI_DBADMINIMPL_HXX_
#define _DBAUI_DBADMINIMPL_HXX_
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_XNAMINGSERVICE_HPP_
#include <com/sun/star/uno/XNamingService.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDRIVER_HPP_
#include <com/sun/star/sdbc/XDriver.hpp>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef _SFXITEMSET_HXX
#include <svl/itemset.hxx>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XMODEL_HPP_
#include <com/sun/star/frame/XModel.hpp>
-#endif
#include <svl/poolitem.hxx>
class Window;
@@ -203,7 +182,7 @@ namespace dbaui
*/
sal_Bool hasAuthentication(const SfxItemSet& _rSet) const;
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
::rtl::OString translatePropertyId( sal_Int32 _nId );
#endif
};
@@ -214,3 +193,4 @@ namespace dbaui
#endif // _DBAUI_DBADMINIMPL_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/DriverSettings.cxx b/dbaccess/source/ui/dlg/DriverSettings.cxx
index 1544deb6c85f..aaa6b6379a7f 100644
--- a/dbaccess/source/ui/dlg/DriverSettings.cxx
+++ b/dbaccess/source/ui/dlg/DriverSettings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -114,3 +115,5 @@ void ODriversSettings::getSupportedIndirectSettings( const ::rtl::OUString& _sUR
_out_rDetailsIds.push_back(pProps->first);
}
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/DriverSettings.hxx b/dbaccess/source/ui/dlg/DriverSettings.hxx
index c09977f276a7..13b4b50e5943 100644
--- a/dbaccess/source/ui/dlg/DriverSettings.hxx
+++ b/dbaccess/source/ui/dlg/DriverSettings.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_DRIVERSETTINGS_HXX
#define DBAUI_DRIVERSETTINGS_HXX
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
#include <svl/poolitem.hxx>
#include <vector>
@@ -110,3 +109,4 @@ namespace dbaui
#endif // DBAUI_DRIVERSETTINGS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/RelationDlg.cxx b/dbaccess/source/ui/dlg/RelationDlg.cxx
index c8f9240ed7b8..b5ef913b3c6d 100644
--- a/dbaccess/source/ui/dlg/RelationDlg.cxx
+++ b/dbaccess/source/ui/dlg/RelationDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,60 +28,25 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-//#ifndef _SVX_TABWIN_HXX
-//#include "tabwin.hxx"
-//#endif
-#ifndef DBAUI_RELATIONDIALOG_HRC
#include "RelationDlg.hrc"
-#endif
-#ifndef DBAUI_RELATIONDIALOG_HXX
#include "RelationDlg.hxx"
-#endif
-#ifndef _WRKWIN_HXX //autogen
#include <vcl/wrkwin.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX //autogen
#include <vcl/svapp.hxx>
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_KEYRULE_HPP_
#include <com/sun/star/sdbc/KeyRule.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef DBAUI_RTABLECONNECTIONDATA_HXX
#include "RTableConnectionData.hxx"
-#endif
-#ifndef DBAUI_RELATIONCONTROL_HXX
#include "RelationControl.hxx"
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
#include <algorithm>
@@ -301,3 +267,4 @@ void ORelationDialog::notifyConnectionChange()
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/RelationDlg.src b/dbaccess/source/ui/dlg/RelationDlg.src
index 81e183e4b77b..90602e37c4a9 100644
--- a/dbaccess/source/ui/dlg/RelationDlg.src
+++ b/dbaccess/source/ui/dlg/RelationDlg.src
@@ -33,7 +33,6 @@
#endif
#include "dbaccess_helpid.hrc"
-
ModalDialog DLG_REL_PROPERTIES
{
HelpID = "dbaccess:ModalDialog:DLG_REL_PROPERTIES";
@@ -44,7 +43,6 @@ ModalDialog DLG_REL_PROPERTIES
Moveable = TRUE ;
Closeable = TRUE ;
-
Window WND_CONTROL
{
Pos = MAP_APPFONT( 0, 0 );
@@ -87,9 +85,6 @@ ModalDialog DLG_REL_PROPERTIES
};
};
-
-
-
FixedLine FL_CASC_UPD
{
Pos = MAP_APPFONT ( 6 , 114 ) ;
@@ -125,7 +120,6 @@ ModalDialog DLG_REL_PROPERTIES
HelpId = HID_DLG_REL_CASC_UPD_DEFAULT ;
Text [ en-US ] = "Set ~default" ;
};
-// zweite FixedLine
FixedLine FL_CASC_DEL
{
Pos = MAP_APPFONT ( 96 , 114 ) ;
@@ -183,4 +177,3 @@ ModalDialog DLG_REL_PROPERTIES
};
};
-
diff --git a/dbaccess/source/ui/dlg/TablesSingleDlg.cxx b/dbaccess/source/ui/dlg/TablesSingleDlg.cxx
index 5ab742d5293c..b717b1384200 100644
--- a/dbaccess/source/ui/dlg/TablesSingleDlg.cxx
+++ b/dbaccess/source/ui/dlg/TablesSingleDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,25 +29,13 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_TABLESSINGLEDLG_HXX_
#include "TablesSingleDlg.hxx"
-#endif
-#ifndef _DBAUI_DBADMINIMPL_HXX_
#include "DbAdminImpl.hxx"
-#endif
-#ifndef _DBAUI_TABLESPAGE_HXX_
#include "tablespage.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _DBAUI_DATASOURCEITEMS_HXX_
#include "dsitems.hxx"
-#endif
-#ifndef _DBAUI_PROPERTYSETITEM_HXX_
#include "propertysetitem.hxx"
-#endif
#include "dbu_dlg.hrc"
@@ -148,3 +137,4 @@ SfxItemSet* OTableSubscriptionDialog::getWriteOutputSet()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/TextConnectionHelper.cxx b/dbaccess/source/ui/dlg/TextConnectionHelper.cxx
index d6cee59919e7..3213b324acb6 100644
--- a/dbaccess/source/ui/dlg/TextConnectionHelper.cxx
+++ b/dbaccess/source/ui/dlg/TextConnectionHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -26,122 +27,53 @@
************************************************************************/
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef DBAUI_TEXTCONNECTIONHELPER_HXX
#include "TextConnectionHelper.hxx"
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
#include "AutoControlsDef.hrc"
-#ifndef _SFXITEMSET_HXX
#include <svl/itemset.hxx>
-#endif
-#ifndef _SFXSTRITEM_HXX
#include <svl/stritem.hxx>
-#endif
-#ifndef _SFXENUMITEM_HXX
#include <svl/eitem.hxx>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef _DBAUI_DATASOURCEITEMS_HXX_
#include "dsitems.hxx"
-#endif
-#ifndef _DBAUI_DBFINDEX_HXX_
#include "dbfindex.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBAUI_LOCALRESACCESS_HXX_
#include "localresaccess.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _SV_MNEMONIC_HXX
#include <vcl/mnemonic.hxx>
-#endif
-#ifndef _SVTOOLS_CJKOPTIONS_HXX
#include <svl/cjkoptions.hxx>
-#endif
#include <jvmaccess/virtualmachine.hxx>
-#ifndef _DBAUI_ADASTAT_HXX_
#include "AdabasStat.hxx"
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef DBAUI_DRIVERSETTINGS_HXX
#include "DriverSettings.hxx"
-#endif
-#ifndef _DBAUI_DBADMIN_HXX_
#include "dbadmin.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XFOLDERPICKER_HPP_
#include <com/sun/star/ui/dialogs/XFolderPicker.hpp>
-#endif
-// #106016# ------------------------------------
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef SVTOOLS_FILENOTATION_HXX_
#include <svl/filenotation.hxx>
-#endif
-#ifndef _UNOTOOLS_LOCALFILEHELPER_HXX
#include <unotools/localfilehelper.hxx>
-#endif
-#ifndef _UNOTOOLS_UCBHELPER_HXX
#include <unotools/ucbhelper.hxx>
-#endif
-#ifndef _UCBHELPER_COMMANDENVIRONMENT_HXX
#include <ucbhelper/commandenvironment.hxx>
-#endif
-#ifndef DBAUI_FILEPICKER_INTERACTION_HXX
#include "finteraction.hxx"
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef DBAUI_DBSETUPCONNECTIONPAGES_HXX
#include "DBSetupConnectionPages.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
#include <unotools/pathoptions.hxx>
-#endif
-#ifndef SVTOOLS_INC_ROADMAPWIZARD_HXX
#include <svtools/roadmapwizard.hxx>
-#endif
namespace dbaui
@@ -220,7 +152,7 @@ DBG_NAME(OTextConnectionHelper)
{ 0, NULL }
};
- for ( size_t section=0; section < sizeof( aSections ) / sizeof( aSections[0] ) - 1; ++section )
+ for ( size_t section=0; section < SAL_N_ELEMENTS( aSections ) - 1; ++section )
{
if ( ( m_nAvailableSections & aSections[section].nFlag ) != 0 )
{
@@ -402,9 +334,6 @@ DBG_NAME(OTextConnectionHelper)
String sExtension = GetExtension();
String aErrorText;
Control* pErrorWin = NULL;
- // if (!m_aFieldSeparator.GetText().Len())
- // bug (#42168) if this line is compiled under OS2 (in a product environent)
- // -> use a temporary variable
String aDelText(m_aFieldSeparator.GetText());
if(!aDelText.Len())
{ // Kein FeldTrenner
@@ -613,3 +542,5 @@ DBG_NAME(OTextConnectionHelper)
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/TextConnectionHelper.hxx b/dbaccess/source/ui/dlg/TextConnectionHelper.hxx
index 911994553a4c..8c1d0aa0c0fd 100644
--- a/dbaccess/source/ui/dlg/TextConnectionHelper.hxx
+++ b/dbaccess/source/ui/dlg/TextConnectionHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
#ifndef DBAUI_TEXTCONNECTIONHELPER_HXX
#define DBAUI_TEXTCONNECTIONHELPER_HXX
-#ifndef DBAUI_CONNECTIONPAGESETUP_HXX
#include "ConnectionPageSetup.hxx"
-#endif
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef CHARSETLISTBOX_HXX
#include "charsetlistbox.hxx"
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _DBAUI_CURLEDIT_HXX_
#include "curledit.hxx"
-#endif
-#ifndef SVTOOLS_INC_ROADMAPWIZARD_HXX
#include <svtools/roadmapwizard.hxx>
-#endif
-#ifndef _SV_FIELD_HXX
#include <vcl/field.hxx>
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
//.........................................................................
@@ -138,3 +121,4 @@ namespace dbaui
#endif // DBAUI_DBWIZ2_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/UserAdmin.cxx b/dbaccess/source/ui/dlg/UserAdmin.cxx
index c38110da1ca0..05879d05df20 100644
--- a/dbaccess/source/ui/dlg/UserAdmin.cxx
+++ b/dbaccess/source/ui/dlg/UserAdmin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,69 +29,27 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_USERADMIN_HXX
#include "UserAdmin.hxx"
-#endif
-#ifndef DBAUI_USERADMIN_HRC
#include "UserAdmin.hrc"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADEFINITIONSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XDataDefinitionSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XUSERSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XUsersSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDROP_HPP_
#include <com/sun/star/sdbcx/XDrop.hpp>
-#endif
-#ifndef _UCBHELPER_INTERATIONREQUEST_HXX
#include <ucbhelper/interactionrequest.hxx>
-#endif
-#ifndef _UCBHELPER_SIMPLEAUTHENTICATIONREQUEST_HXX
#include <ucbhelper/simpleauthenticationrequest.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XUSER_HPP_
#include <com/sun/star/sdbcx/XUser.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _DBAUI_DBADMIN_HXX_
#include "dbadmin.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _SFX_PASSWD_HXX
#include <sfx2/passwd.hxx>
-#endif
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::beans;
@@ -391,3 +350,5 @@ void OUserAdmin::implInitControls(const SfxItemSet& _rSet, sal_Bool _bSaveValue)
OGenericAdministrationPage::implInitControls(_rSet, _bSaveValue);
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/UserAdmin.hxx b/dbaccess/source/ui/dlg/UserAdmin.hxx
index 13700201a5c1..73458126dbb1 100644
--- a/dbaccess/source/ui/dlg/UserAdmin.hxx
+++ b/dbaccess/source/ui/dlg/UserAdmin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
#ifndef DBAUI_USERADMIN_HXX
#define DBAUI_USERADMIN_HXX
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_FIELD_HXX
#include <vcl/field.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _SV_DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
-#ifndef _SV_GROUP_HXX
#include <vcl/group.hxx>
-#endif
-#ifndef DBAUI_TABLEGRANTCONTROL_HXX
#include "TableGrantCtrl.hxx"
-#endif
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
FORWARD_DECLARE_INTERFACE(beans,XPropertySet)
FORWARD_DECLARE_INTERFACE(sdbc,XConnection)
@@ -105,3 +88,5 @@ public:
};
}
#endif // DBAUI_USERADMIN_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/UserAdmin.src b/dbaccess/source/ui/dlg/UserAdmin.src
index 8d88dcf8f1ce..26dc60d0bf64 100644
--- a/dbaccess/source/ui/dlg/UserAdmin.src
+++ b/dbaccess/source/ui/dlg/UserAdmin.src
@@ -71,7 +71,6 @@ TabPage TAB_PAGE_USERADMIN
HelpId = HID_TAB_PAGE_LBUSER ;
};
-
PushButton PB_NEWUSER
{
Pos = MAP_APPFONT ( 12 , 29 ) ;
@@ -150,7 +149,6 @@ ModalDialog DLG_PASSWORD
Size = MAP_APPFONT ( WIN_X - 3 - 6 - 6 - 50 , 8 ) ;
Text [ en-US ] = "User \"$name$: $\"";
};
-
FixedText FT_OLDPASSWORD
{
Pos = MAP_APPFONT ( 6 , 17 ) ;
@@ -184,7 +182,7 @@ ModalDialog DLG_PASSWORD
{
Pos = MAP_APPFONT ( 6 , 52 ) ;
Size = MAP_APPFONT ( FT_SIZE_X , 10 ) ;
- Text [ en-US ] = "~Confirm password";
+ Text [ en-US ] = "~Confirm password";
};
Edit ED_PASSWORD_REPEAT
{
@@ -218,28 +216,3 @@ String STR_ERROR_PASSWORDS_NOT_IDENTICAL
{
Text [ en-US ] = "The passwords do not match. Please enter the password again.";
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/dlg/UserAdminDlg.cxx b/dbaccess/source/ui/dlg/UserAdminDlg.cxx
index 68474ab64134..726a4ab70a10 100644
--- a/dbaccess/source/ui/dlg/UserAdminDlg.cxx
+++ b/dbaccess/source/ui/dlg/UserAdminDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -95,11 +96,15 @@ DBG_NAME(OUserAdminDlg)
OUserAdminDlg::~OUserAdminDlg()
{
if ( m_bOwnConnection )
+ {
try
{
::comphelper::disposeComponent(m_xConnection);
}
- catch(Exception){}
+ catch(const Exception&)
+ {
+ }
+ }
SetInputSet(NULL);
DELETEZ(pExampleSet);
@@ -118,12 +123,12 @@ DBG_NAME(OUserAdminDlg)
throw SQLException(sError,NULL,::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("S1000")) ,0,Any());
}
}
- catch(const SQLException& e)
+ catch(const SQLException&)
{
::dbaui::showError( ::dbtools::SQLExceptionInfo( ::cppu::getCaughtException() ), GetParent(), getORB() );
return RET_CANCEL;
}
- catch( const Exception& )
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -204,3 +209,5 @@ DBG_NAME(OUserAdminDlg)
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/UserAdminDlg.src b/dbaccess/source/ui/dlg/UserAdminDlg.src
index d3a59a511deb..5b07b43093b5 100644
--- a/dbaccess/source/ui/dlg/UserAdminDlg.src
+++ b/dbaccess/source/ui/dlg/UserAdminDlg.src
@@ -35,7 +35,6 @@
#include "dbu_dlg.hrc"
#endif
-
TabDialog DLG_DATABASE_USERADMIN
{
OutputSize = TRUE ;
diff --git a/dbaccess/source/ui/dlg/admincontrols.cxx b/dbaccess/source/ui/dlg/admincontrols.cxx
index 7038019c0dfd..d9c591f3221f 100755..100644
--- a/dbaccess/source/ui/dlg/admincontrols.cxx
+++ b/dbaccess/source/ui/dlg/admincontrols.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -107,7 +108,7 @@ namespace dbaui
break;
default:
- OSL_ENSURE( false, "TextResetOperator::operateOn: unexpected event ID!" );
+ OSL_FAIL( "TextResetOperator::operateOn: unexpected event ID!" );
// all those IDs should have been filtered out by payAttentionTo
break;
}
@@ -309,3 +310,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/admincontrols.hxx b/dbaccess/source/ui/dlg/admincontrols.hxx
index 70ee08d5ca28..83353be4b8d0 100755..100644
--- a/dbaccess/source/ui/dlg/admincontrols.hxx
+++ b/dbaccess/source/ui/dlg/admincontrols.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -80,3 +81,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_ADMINCONTROLS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/admincontrols.src b/dbaccess/source/ui/dlg/admincontrols.src
index 8ce3bb4030dc..8ce3bb4030dc 100755..100644
--- a/dbaccess/source/ui/dlg/admincontrols.src
+++ b/dbaccess/source/ui/dlg/admincontrols.src
diff --git a/dbaccess/source/ui/dlg/adminpages.cxx b/dbaccess/source/ui/dlg/adminpages.cxx
index 93f1850b37e8..d65c2ff8d572 100644
--- a/dbaccess/source/ui/dlg/adminpages.cxx
+++ b/dbaccess/source/ui/dlg/adminpages.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -162,7 +163,7 @@ namespace dbaui
else
{
aEnumeration.getDatasourceNames(aOdbcDatasources);
- // excute the select dialog
+ // execute the select dialog
ODatasourceSelectDialog aSelector(GetParent(), aOdbcDatasources, false);
if (_sCurr.getLength())
aSelector.Select(_sCurr);
@@ -352,3 +353,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/adminpages.hxx b/dbaccess/source/ui/dlg/adminpages.hxx
index c3773b8109cd..51fd7f025965 100644
--- a/dbaccess/source/ui/dlg/adminpages.hxx
+++ b/dbaccess/source/ui/dlg/adminpages.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
#ifndef _DBAUI_ADMINPAGES_HXX_
#define _DBAUI_ADMINPAGES_HXX_
-#ifndef _SFXTABDLG_HXX
#include <sfx2/tabdlg.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
-#ifndef _SVTOOLS_WIZARDMACHINE_HXX_
#include <svtools/wizardmachine.hxx>
-#endif
-#ifndef _SV_FIELD_HXX
#include <vcl/field.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
class NumericField;
@@ -162,7 +151,7 @@ namespace dbaui
@param _sReturn
<OUT/> contains the selected name.
@return
- <FALSE/> if an error occured, otherwise <TRUE/>
+ <FALSE/> if an error occurred, otherwise <TRUE/>
*/
sal_Bool getSelectedDataSource(::rtl::OUString& _sReturn,::rtl::OUString& _sCurr);
@@ -301,3 +290,4 @@ namespace dbaui
#endif // _DBAUI_ADMINPAGES_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/adodatalinks.cxx b/dbaccess/source/ui/dlg/adodatalinks.cxx
index 18bca9f0e31e..7fc484ad4c56 100644
--- a/dbaccess/source/ui/dlg/adodatalinks.cxx
+++ b/dbaccess/source/ui/dlg/adodatalinks.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -44,9 +45,7 @@
#include <adoid.h> // needed for CLSID_CADOConnection
#include <adoint.h> // needed for ADOConnection
-#ifndef _DBAUI_ADO_DATALINK_HXX_
#include "adodatalinks.hxx"
-#endif
BSTR PromptEdit(long hWnd,BSTR connstr);
BSTR PromptNew(long hWnd);
@@ -209,3 +208,5 @@ BSTR PromptEdit(long hWnd,BSTR connstr)
return _result;
}
#endif
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/adodatalinks.hxx b/dbaccess/source/ui/dlg/adodatalinks.hxx
index 2084bb850402..e5f299e7a7be 100644
--- a/dbaccess/source/ui/dlg/adodatalinks.hxx
+++ b/dbaccess/source/ui/dlg/adodatalinks.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,9 @@
#ifndef _DBAUI_ADO_DATALINK_HXX_
#define _DBAUI_ADO_DATALINK_HXX_
-#ifndef _OSL_MODULE_H_
#include <osl/module.h>
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
::rtl::OUString getAdoDatalink(long hWnd,::rtl::OUString& oldLink);
#endif
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/adtabdlg.cxx b/dbaccess/source/ui/dlg/adtabdlg.cxx
index b47d2182489a..fa16813dd8fa 100644
--- a/dbaccess/source/ui/dlg/adtabdlg.cxx
+++ b/dbaccess/source/ui/dlg/adtabdlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -189,7 +190,7 @@ void TableListFacade::updateTableObjectList( bool _bAllowViews )
m_pContainerListener = new ::comphelper::OContainerListenerAdapter(this,xContainer);
}
sTables = xTables->getElementNames();
- } // if ( xTables.is() )
+ }
xViewSupp.set( xTableSupp, UNO_QUERY );
if ( xViewSupp.is() )
@@ -297,13 +298,10 @@ void QueryListFacade::updateTableObjectList( bool /*_bAllowViews*/ )
try
{
ImageProvider aImageProvider( m_xConnection );
- Image aQueryImage( aImageProvider.getDefaultImage( DatabaseObject::QUERY, false ) );
- Image aQueryImageHC( aImageProvider.getDefaultImage( DatabaseObject::QUERY, true ) );
+ Image aQueryImage( aImageProvider.getDefaultImage( DatabaseObject::QUERY ) );
- m_rQueryList.SetDefaultExpandedEntryBmp( aQueryImage, BMP_COLOR_NORMAL );
- m_rQueryList.SetDefaultCollapsedEntryBmp( aQueryImage, BMP_COLOR_NORMAL );
- m_rQueryList.SetDefaultExpandedEntryBmp( aQueryImageHC, BMP_COLOR_HIGHCONTRAST );
- m_rQueryList.SetDefaultCollapsedEntryBmp( aQueryImageHC, BMP_COLOR_HIGHCONTRAST );
+ m_rQueryList.SetDefaultExpandedEntryBmp( aQueryImage );
+ m_rQueryList.SetDefaultCollapsedEntryBmp( aQueryImage );
Reference< XQueriesSupplier > xSuppQueries( m_xConnection, UNO_QUERY_THROW );
Reference< XNameAccess > xQueries( xSuppQueries->getQueries(), UNO_QUERY_THROW );
@@ -531,3 +529,4 @@ String OAddTableDlg::getDialogTitleForContext( IAddTableDialogContext& _rContext
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/adtabdlg.src b/dbaccess/source/ui/dlg/adtabdlg.src
index 7a36bddb378f..deb914dd831d 100644
--- a/dbaccess/source/ui/dlg/adtabdlg.src
+++ b/dbaccess/source/ui/dlg/adtabdlg.src
@@ -69,6 +69,7 @@ ModelessDialog DLG_JOIN_TABADD
Hide = TRUE;
Group = TRUE;
};
+
PushButton PB_ADDTABLE
{
HelpID = "dbaccess:PushButton:DLG_JOIN_TABADD:PB_ADDTABLE";
@@ -78,6 +79,7 @@ ModelessDialog DLG_JOIN_TABADD
TabStop = TRUE ;
DefButton = TRUE ;
};
+
CancelButton PB_CLOSE
{
Pos = MAP_APPFONT ( 123 , 22 ) ;
@@ -86,6 +88,7 @@ ModelessDialog DLG_JOIN_TABADD
Text [ en-US ] = "~Close" ;
TabStop = TRUE ;
};
+
HelpButton PB_HELP
{
Pos = MAP_APPFONT ( 123 , 43 ) ;
diff --git a/dbaccess/source/ui/dlg/advancedsettings.cxx b/dbaccess/source/ui/dlg/advancedsettings.cxx
index 1f251f517329..4b8d244fb03b 100644
--- a/dbaccess/source/ui/dlg/advancedsettings.cxx
+++ b/dbaccess/source/ui/dlg/advancedsettings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -313,7 +314,7 @@ namespace dbaui
aValue = PTR_CAST( OptionalBoolItem, pItem )->GetFullValue();
}
else
- DBG_ERROR( "SpecialSettingsPage::implInitControls: unknown boolean item type!" );
+ OSL_FAIL( "SpecialSettingsPage::implInitControls: unknown boolean item type!" );
if ( !aValue )
{
@@ -602,3 +603,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/advancedsettings.hxx b/dbaccess/source/ui/dlg/advancedsettings.hxx
index e3a70f98c509..3b29d4ba15ad 100644
--- a/dbaccess/source/ui/dlg/advancedsettings.hxx
+++ b/dbaccess/source/ui/dlg/advancedsettings.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -154,3 +155,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_ADVANCEDSETTINGS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dbadmin.cxx b/dbaccess/source/ui/dlg/dbadmin.cxx
index cbe3b35cddfe..c77d2aa133cb 100644
--- a/dbaccess/source/ui/dlg/dbadmin.cxx
+++ b/dbaccess/source/ui/dlg/dbadmin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -148,7 +149,6 @@ void ODbAdminDialog::impl_selectDataSource(const ::com::sun::star::uno::Any& _aD
{
case ::dbaccess::DST_DBASE:
addDetailPage(PAGE_DBASE, STR_PAGETITLE_ADVANCED, ODriversSettings::CreateDbase);
- // bResetPasswordRequired = sal_True;
break;
case ::dbaccess::DST_ADO:
@@ -157,7 +157,6 @@ void ODbAdminDialog::impl_selectDataSource(const ::com::sun::star::uno::Any& _aD
case ::dbaccess::DST_FLAT:
addDetailPage(PAGE_TEXT, STR_PAGETITLE_ADVANCED, ODriversSettings::CreateText);
- // bResetPasswordRequired = sal_True;
break;
case ::dbaccess::DST_ODBC:
@@ -414,7 +413,7 @@ SfxItemSet* ODbAdminDialog::createItemSet(SfxItemSet*& _rpSet, SfxItemPool*& _rp
*pCounter++ = new SfxBoolItem( DSID_RESPECTRESULTSETTYPE,sal_False );
// create the pool
- static SfxItemInfo __READONLY_DATA aItemInfos[DSID_LAST_ITEM_ID - DSID_FIRST_ITEM_ID + 1] =
+ static SfxItemInfo const aItemInfos[DSID_LAST_ITEM_ID - DSID_FIRST_ITEM_ID + 1] =
{
{0,0},
{0,0},
@@ -479,7 +478,7 @@ SfxItemSet* ODbAdminDialog::createItemSet(SfxItemSet*& _rpSet, SfxItemPool*& _rp
{0,0}
};
- OSL_ENSURE(sizeof(aItemInfos)/sizeof(aItemInfos[0]) == DSID_LAST_ITEM_ID,"Invalid Ids!");
+ OSL_ENSURE(SAL_N_ELEMENTS(aItemInfos) == DSID_LAST_ITEM_ID,"Invalid Ids!");
_rpPool = new SfxItemPool(String::CreateFromAscii("DSAItemPool"), DSID_FIRST_ITEM_ID, DSID_LAST_ITEM_ID,
aItemInfos, _rppDefaults);
_rpPool->FreezeIdRanges();
@@ -517,3 +516,4 @@ void ODbAdminDialog::destroyItemSet(SfxItemSet*& _rpSet, SfxItemPool*& _rpPool,
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dbadmin.src b/dbaccess/source/ui/dlg/dbadmin.src
index f16edc83a761..d3a356fc95bf 100644
--- a/dbaccess/source/ui/dlg/dbadmin.src
+++ b/dbaccess/source/ui/dlg/dbadmin.src
@@ -82,7 +82,6 @@
Pos = MAP_APPFONT ( EDIT_X , AUTO_Y ) ; \
Size = MAP_APPFONT ( 97 , EDIT_HEIGHT ) ; \
}; \
- \
FixedText FT_PORTNUMBER \
{ \
Pos = MAP_APPFONT ( 6 , AUTO_Y + UNRELATED_CONTROLS + FIXEDTEXT_HEIGHT + 2 ) ; \
@@ -336,7 +335,7 @@ TabPage PAGE_DBASE
WordBreak = TRUE;
Pos = MAP_APPFONT ( 6 , 3*UNRELATED_CONTROLS + 2*RELATED_CONTROLS + 3*FIXEDTEXT_HEIGHT + CHECKBOX_HEIGHT) ;
Size = MAP_APPFONT ( PAGE_X - 12 , 2*FIXEDTEXT_HEIGHT ) ;
- Text [ en-US ] = "Note: When deleted, and thus inactive, records are displayed, you will not be able to delete records from the data source." ;
+ Text [ en-US ] = "Note: When deleted, and thus inactive, records are displayed, you will not be able to delete records from the data source." ;
};
PushButton PB_INDICIES
@@ -743,8 +742,8 @@ TabPage PAGE_TEXT
HelpId = HID_DSADMIN_PAGE_TEXT;
AUTO_SEPARATORCONTROLGROUP(UNRELATED_CONTROLS, PAGE_X)
-
};
+
//.........................................................................
TabPage PAGE_USERDRIVER
{
diff --git a/dbaccess/source/ui/dlg/dbadmin2.src b/dbaccess/source/ui/dlg/dbadmin2.src
index 76cfebb8dcb0..44ef3f024e3a 100644
--- a/dbaccess/source/ui/dlg/dbadmin2.src
+++ b/dbaccess/source/ui/dlg/dbadmin2.src
@@ -62,6 +62,11 @@ String STR_COULD_NOT_CREATE_DIRECTORY
Text [ en-US ] = "The directory $name$ could not be created.";
};
+
+
+
+
+
#define EDIT_SIZE_X 50
#define FT_SIZE_X 90
#define WIN_X 220
@@ -147,4 +152,3 @@ TabPage PAGE_TABLESUBSCRIPTION
Text [ en-US ] = "Mark the tables that should be visible for the applications.";
};
};
-
diff --git a/dbaccess/source/ui/dlg/dbadminsetup.hrc b/dbaccess/source/ui/dlg/dbadminsetup.hrc
index b53e12425af7..7d6757951089 100644
--- a/dbaccess/source/ui/dlg/dbadminsetup.hrc
+++ b/dbaccess/source/ui/dlg/dbadminsetup.hrc
@@ -72,7 +72,6 @@
#define STR_DEFAULTLDAPPORTNUMBER 60
#define STR_ADABASNAME 61
-//#define STR_ADOURL 62
#define STR_ODBCDATASOURCENAME 63
#define STR_SPREADSHEETPATH 64
#define STR_DBLOCATIONLABEL 65
diff --git a/dbaccess/source/ui/dlg/dbadminsetup.src b/dbaccess/source/ui/dlg/dbadminsetup.src
index 4d6812143598..ea4341914e82 100644
--- a/dbaccess/source/ui/dlg/dbadminsetup.src
+++ b/dbaccess/source/ui/dlg/dbadminsetup.src
@@ -141,7 +141,6 @@ ModalDialog DLG_DATABASE_WIZARD
};
};
-
String STR_DATABASEDEFAULTNAME
{
Text[ en-US ] = "New Database" ;
@@ -164,7 +163,6 @@ TabPage PAGE_DBWIZARD_MYSQL_INTRO
WordBreak = TRUE;
};
-
FixedText FT_MYSQL_HELPTEXT
{
Pos = MAP_APPFONT (START_X , 27 ) ;
@@ -203,7 +201,6 @@ TabPage PAGE_DBWIZARD_MYSQL_INTRO
Text[ en-US ] = "Connect directly" ;
Hide = TRUE ;
};
-
};
#define AUTHENTEDIT_X (EDIT_X - 10)
@@ -224,7 +221,6 @@ TabPage PAGE_DBWIZARD_AUTHENTIFICATION
WordBreak = TRUE;
};
-
FixedText FT_AUTHENTIFICATIONHELPTEXT\
{
Pos = MAP_APPFONT (START_X , 27 ) ;
@@ -263,7 +259,6 @@ TabPage PAGE_DBWIZARD_AUTHENTIFICATION
Size = MAP_APPFONT ( BUTTON_WIDTH , BUTTON_HEIGHT ) ;
Text[ en-US ] = "~Test Connection" ;
};
-
};
@@ -275,7 +270,6 @@ TabPage PAGE_DBWIZARD_FINAL
Size = MAP_APPFONT ( WIZARD_PAGE_X , WIZARD_PAGE_Y ) ;
Hide = TRUE ;
-
FixedText FT_FINALHEADER
{
Pos = MAP_APPFONT ( START_X , 8 ) ;
@@ -292,7 +286,6 @@ TabPage PAGE_DBWIZARD_FINAL
WordBreak = TRUE ;
};
-
RadioButton RB_REGISTERDATASOURCE
{
HelpId = HID_PAGE_DBWIZARD_FINAL_RB_REGISTERDATASOURCE;
@@ -302,7 +295,6 @@ TabPage PAGE_DBWIZARD_FINAL
Text[ en-US ] = "~Yes, register the database for me" ;
};
-
RadioButton RB_DONTREGISTERDATASOURCE
{
HelpId = HID_PAGE_DBWIZARD_FINAL_RB_DONTREGISTERDATASOURCE ;
@@ -352,7 +344,6 @@ TabPage PAGE_DBWIZARD_MYSQL_JDBC
Size = MAP_APPFONT ( WIZARD_PAGE_X , WIZARD_PAGE_Y ) ;
Hide = TRUE ;
-
String STR_MYSQLJDBC_HEADERTEXT
{
Text[ en-US ] = "Set up connection to a MySQL database using JDBC" ;
@@ -416,7 +407,6 @@ TabPage PAGE_DBWIZARD_DBASE
Text[ en-US ] = "Set up a connection to dBASE files" ;
};
-
String STR_DBASE_HELPTEXT
{
Text[ en-US ] = "Select the folder where the dBASE files are stored." ;
@@ -425,34 +415,27 @@ TabPage PAGE_DBWIZARD_DBASE
AUTO_HELP_BROWSECONTROLGROUP( 3, HID_PAGE_DBWIZARD_DBASE_ET_DBASELOCATION,HID_PAGE_DBWIZARD_DBASE_PB_DBASELOCATION)
};
-
TabPage PAGE_DBWIZARD_TEXT
{
HelpID = "dbaccess:TabPage:PAGE_DBWIZARD_TEXT";
-
String STR_TEXT_HEADERTEXT
{
Text[ en-US ] = "Set up a connection to text files" ;
};
-
String STR_TEXT_HELPTEXT
{
Text[ en-US ] = "Select the folder where the CSV (Comma Separated Values) text files are stored. %PRODUCTNAME Base will open these files in read-only mode." ;
};
-
String STR_TEXT_PATH_OR_FILE{
Text[ en-US ] = "Path to text files";
};
-
AUTO_HELP_BROWSECONTROLGROUP(3, HID_PAGE_DBWIZARD_TEXT_ET_LOCATIONTEXTFILE,HID_PAGE_DBWIZARD_TEXT_PB_LOCATIONTEXTFILE)
AUTO_SEPARATORCONTROLGROUP(82, WIZARD_PAGE_X)
};
-
-
TabPage PAGE_DBWIZARD_MSACCESS
{
HelpID = "dbaccess:TabPage:PAGE_DBWIZARD_MSACCESS";
@@ -466,17 +449,14 @@ TabPage PAGE_DBWIZARD_MSACCESS
Text[ en-US ] = "Set up a connection to a Microsoft Access database" ;
};
-
String STR_MSACCESS_HELPTEXT
{
Text[ en-US ] = "Please select the Microsoft Access file you want to access.";
};
AUTO_HELP_BROWSECONTROLGROUP(3, HID_PAGE_DBWIZARD_MSACCESS_ET_MSACCESSLOCATION, HID_PAGE_DBWIZARD_MSACCESS_PB_MSACCESSLOCATION)
-// FT_MSACCESS_MDB_FILE
};
-
TabPage PAGE_DBWIZARD_LDAP
{
HelpID = "dbaccess:TabPage:PAGE_DBWIZARD_LDAP";
@@ -493,7 +473,6 @@ TabPage PAGE_DBWIZARD_LDAP
WordBreak = TRUE;
};
-
FixedText FT_LDAP_HELPTEXT
{
Pos = MAP_APPFONT (START_X , 27 ) ;
@@ -518,7 +497,6 @@ TabPage PAGE_DBWIZARD_LDAP
};
};
-
TabPage PAGE_DBWIZARD_ADABAS
{
HelpID = "dbaccess:TabPage:PAGE_DBWIZARD_ADABAS";
@@ -532,7 +510,6 @@ TabPage PAGE_DBWIZARD_ADABAS
Text[ en-US ] = "Set up a connection to an Adabas D database" ;
};
-
String STR_ADABAS_HELPTEXT{
Text[ en-US ] = "Enter the name of the Adabas D database you want to connect to.\nClick 'Browse...' to select an Adabas D database that is already registered in %PRODUCTNAME." ;
};
@@ -540,7 +517,6 @@ TabPage PAGE_DBWIZARD_ADABAS
AUTO_HELP_BROWSECONTROLGROUP(4, HID_PAGE_DBWIZARD_ADABAS_ET_ADABASNAME, HID_PAGE_DBWIZARD_ADABAS_PB_ADABASNAME)
};
-
TabPage PAGE_DBWIZARD_ADO
{
HelpID = "dbaccess:TabPage:PAGE_DBWIZARD_ADO";
@@ -559,7 +535,6 @@ TabPage PAGE_DBWIZARD_ADO
};
AUTO_HELP_BROWSECONTROLGROUP(5, HID_PAGE_DBWIZARD_ADO_ET_ADOURL, HID_PAGE_DBWIZARD_ADO_PB_ADOURL)
-
};
@@ -594,8 +569,6 @@ TabPage PAGE_DBWIZARD_USERDEFINED
AUTO_HELP_BROWSECONTROLGROUP(6, HID_PAGE_DBWIZARD_USERDEFINED_ET_BROWSE, HID_PAGE_DBWIZARD_USERDEFINED_BROWSE)
};
-
-
TabPage PAGE_DBWIZARD_JDBC
{
HelpID = "dbaccess:TabPage:PAGE_DBWIZARD_JDBC";
@@ -637,12 +610,10 @@ TabPage PAGE_DBWIZARD_ORACLE
Text[ en-US ] = "Default: 1521" ;
};
-
String STR_ORACLE_DRIVERCLASSTEXT{
Text [ en-US ] = "Oracle JDBC ~driver class";
};
-
String STR_ORACLE_HELPTEXT{
Text[ en-US ] = "Please enter the required information to connect to an Oracle database.Note that a JDBC Driver Class must be installed on your system and registered with %PRODUCTNAME.\nPlease contact your system administrator if you are unsure about the following settings." ;
};
@@ -664,12 +635,10 @@ TabPage PAGE_DBWIZARD_SPREADSHEET
Text[ en-US ] = "Set up a connection to spreadsheets";
};
-
String STR_SPREADSHEET_HELPTEXT{
Text[ en-US ] = "Click 'Browse...' to select a %PRODUCTNAME spreadsheet or Microsoft Excel workbook.\n%PRODUCTNAME will open this file in read-only mode." ;
};
-
AUTO_HELP_BROWSECONTROLGROUP(3, HID_PAGE_DBWIZARD_SPREADSHEET_ET_SPREADSHEETPATH,HID_PAGE_DBWIZARD_SPREADSHEET_PB_SPREADSHEETPATH )
String STR_SPREADSHEETPATH{
@@ -685,5 +654,3 @@ TabPage PAGE_DBWIZARD_SPREADSHEET
Text[ en-US ] = "~Password required" ;
};
};
-
-
diff --git a/dbaccess/source/ui/dlg/dbfindex.cxx b/dbaccess/source/ui/dlg/dbfindex.cxx
index 99cf4bdf95fa..464aba52b7df 100644
--- a/dbaccess/source/ui/dlg/dbfindex.cxx
+++ b/dbaccess/source/ui/dlg/dbfindex.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,43 +29,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_DBFINDEX_HXX_
#include "dbfindex.hxx"
-#endif
-#ifndef _CONFIG_HXX
#include <tools/config.hxx>
-#endif
-#ifndef _SFXAPP_HXX //autogen
#include <sfx2/app.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBAUI_DBF_INDEXES_HRC_
#include "dbfindex.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _UNOTOOLS_LOCALFILEHELPER_HXX
+#include <osl/diagnose.h>
#include <unotools/localfilehelper.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
#include <unotools/pathoptions.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef SVTOOLS_FILENOTATION_HXX_
#include <svl/filenotation.hxx>
-#endif
//.........................................................................
@@ -117,12 +94,6 @@ ODbaseIndexDialog::ODbaseIndexDialog( Window * pParent, String aDataSrcName )
Init();
SetCtrls();
FreeResource();
-
- // set Hi contrast bitmaps
- aIB_Add.SetModeImage( ModuleRes(IMG_ONE_LEFT_H),BMP_COLOR_HIGHCONTRAST);
- aIB_AddAll.SetModeImage( ModuleRes(IMG_ALL_LEFT_H),BMP_COLOR_HIGHCONTRAST);
- aIB_Remove.SetModeImage( ModuleRes(IMG_ONE_RIGHT_H),BMP_COLOR_HIGHCONTRAST);
- aIB_RemoveAll.SetModeImage( ModuleRes(IMG_ALL_RIGHT_H),BMP_COLOR_HIGHCONTRAST);
}
//-------------------------------------------------------------------------
@@ -195,7 +166,7 @@ OTableIndex ODbaseIndexDialog::implRemoveIndex(const String& _rName, TableIndexL
}
(void)_bMustExist;
- DBG_ASSERT(!_bMustExist || (aSearch != _rList.end()), "ODbaseIndexDialog::implRemoveIndex : did not find the index!");
+ OSL_ENSURE(!_bMustExist || (aSearch != _rList.end()), "ODbaseIndexDialog::implRemoveIndex : did not find the index!");
return aReturn;
}
@@ -377,8 +348,8 @@ void ODbaseIndexDialog::Init()
Sequence< ::rtl::OUString> aFolderContent( ::utl::LocalFileHelper::GetFolderContents(m_aDSN,bFolder));
- ::rtl::OUString aIndexExt = ::rtl::OUString::createFromAscii("ndx");
- ::rtl::OUString aTableExt = ::rtl::OUString::createFromAscii("dbf");
+ ::rtl::OUString aIndexExt(RTL_CONSTASCII_USTRINGPARAM("ndx"));
+ ::rtl::OUString aTableExt(RTL_CONSTASCII_USTRINGPARAM("dbf"));
::std::vector< String > aUsedIndexes;
@@ -564,7 +535,7 @@ void OTableInfo::WriteInfFile( const String& rDSN ) const
try
{
::ucbhelper::Content aContent(aURL.GetURLNoPass(),Reference<XCommandEnvironment>());
- aContent.executeCommand( rtl::OUString::createFromAscii( "delete" ),makeAny( sal_Bool( sal_True ) ) );
+ aContent.executeCommand( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("delete")),makeAny( sal_Bool( sal_True ) ) );
}
catch (const Exception& e )
{
@@ -572,7 +543,6 @@ void OTableInfo::WriteInfFile( const String& rDSN ) const
// simply silent this. The strange algorithm here does a lot of things even if no files at all were
// created or accessed, so it's possible that the file we're trying to delete does not even exist,
// and this is a valid condition.
- // 2003-05-15 - #109677# - fs@openoffice.org
}
}
}
@@ -581,3 +551,4 @@ void OTableInfo::WriteInfFile( const String& rDSN ) const
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dbfindex.hxx b/dbaccess/source/ui/dlg/dbfindex.hxx
index 28e80aac5963..c10b2362027b 100644
--- a/dbaccess/source/ui/dlg/dbfindex.hxx
+++ b/dbaccess/source/ui/dlg/dbfindex.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,27 +29,15 @@
#ifndef _DBAUI_DBFINDEX_HXX_
#define _DBAUI_DBFINDEX_HXX_
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _COMBOBOX_HXX //autogen
#include <vcl/combobox.hxx>
-#endif
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
#ifndef __SGI_STL_LIST
#include <list>
#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
//.........................................................................
namespace dbaui
@@ -164,3 +153,4 @@ public:
#endif // _DBAUI_DBFINDEX_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dbfindex.src b/dbaccess/source/ui/dlg/dbfindex.src
index 83ce7090c195..ca8b6e4a3622 100644
--- a/dbaccess/source/ui/dlg/dbfindex.src
+++ b/dbaccess/source/ui/dlg/dbfindex.src
@@ -35,62 +35,6 @@
#define WIN_X 264
#define WIN_Y 149
-Image IMG_ONE_LEFT_H
-{
- ImageBitmap = Bitmap
- {
- File = "one_left_h.bmp" ;
- };
- MaskColor = Color
- {
- Red = 0xFFFF ;
- Green = 0x0000 ;
- Blue = 0xFFFF ;
- };
-};
-
-Image IMG_ALL_LEFT_H
-{
- ImageBitmap = Bitmap
- {
- File = "all_left_h.bmp" ;
- };
- MaskColor = Color
- {
- Red = 0xFFFF ;
- Green = 0x0000 ;
- Blue = 0xFFFF ;
- };
-};
-
-Image IMG_ONE_RIGHT_H
-{
- ImageBitmap = Bitmap
- {
- File = "one_right_h.bmp" ;
- };
- MaskColor = Color
- {
- Red = 0xFFFF ;
- Green = 0x0000 ;
- Blue = 0xFFFF ;
- };
-};
-
-Image IMG_ALL_RIGHT_H
-{
- ImageBitmap = Bitmap
- {
- File = "all_right_h.bmp" ;
- };
- MaskColor = Color
- {
- Red = 0xFFFF ;
- Green = 0x0000 ;
- Blue = 0xFFFF ;
- };
-};
-
ModalDialog DLG_DBASE_INDEXES
{
HelpID = "dbaccess:ModalDialog:DLG_DBASE_INDEXES";
@@ -180,7 +124,7 @@ ModalDialog DLG_DBASE_INDEXES
{
ImageBitmap = Bitmap
{
- File = "one_left.bmp" ;
+ File = "one_left.png" ;
};
MaskColor = Color
{
@@ -200,7 +144,7 @@ ModalDialog DLG_DBASE_INDEXES
{
ImageBitmap = Bitmap
{
- File = "all_left.bmp" ;
+ File = "all_left.png" ;
};
MaskColor = Color
{
@@ -220,7 +164,7 @@ ModalDialog DLG_DBASE_INDEXES
{
ImageBitmap = Bitmap
{
- File = "one_right.bmp" ;
+ File = "one_right.png" ;
};
MaskColor = Color
{
@@ -240,7 +184,7 @@ ModalDialog DLG_DBASE_INDEXES
{
ImageBitmap = Bitmap
{
- File = "all_right.bmp" ;
+ File = "all_right.png" ;
};
MaskColor = Color
{
@@ -250,5 +194,4 @@ ModalDialog DLG_DBASE_INDEXES
};
};
};
-
};
diff --git a/dbaccess/source/ui/dlg/dbwiz.cxx b/dbaccess/source/ui/dlg/dbwiz.cxx
index e909ae107053..0fb8484f5f8b 100644
--- a/dbaccess/source/ui/dlg/dbwiz.cxx
+++ b/dbaccess/source/ui/dlg/dbwiz.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,64 +29,26 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_DBWIZ_HXX
#include "dbwiz.hxx"
-#endif
-#ifndef _DBAUI_DBADMIN_HRC_
#include "dbadmin.hrc"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBAUI_DATASOURCEITEMS_HXX_
#include "dsitems.hxx"
-#endif
#include "dsnItem.hxx"
-#ifndef _SFXSTRITEM_HXX
#include <svl/stritem.hxx>
-#endif
-#ifndef _SFXENUMITEM_HXX
#include <svl/eitem.hxx>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef _DBAUI_GENERALPAGE_HXX_
#include "generalpage.hxx"
-#endif
-#ifndef _DBAUI_LOCALRESACCESS_HXX_
#include "localresaccess.hxx"
-#endif
-#ifndef _DBAUI_STRINGLISTITEM_HXX_
#include "stringlistitem.hxx"
-#endif
-#ifndef _DBAUI_PROPERTYSETITEM_HXX_
#include "propertysetitem.hxx"
-#endif
-#ifndef _UNOTOOLS_CONFIGNODE_HXX_
#include <unotools/confignode.hxx>
-#endif
-#ifndef DBAUI_CONNECTIONPAGE_HXX
#include "ConnectionPage.hxx"
-#endif
-#ifndef DBAUI_DRIVERSETTINGS_HXX
#include "DriverSettings.hxx"
-#endif
-#ifndef _DBAUI_DBADMINIMPL_HXX_
#include "DbAdminImpl.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
//.........................................................................
namespace dbaui
@@ -347,7 +310,7 @@ TabPage* ODbTypeWizDialog::createPage(WizardState _nState)
pPage = ODriversSettings::CreateUser(this,*m_pOutSet);
break;
default:
- OSL_ENSURE(0,"Wrong state!");
+ OSL_FAIL("Wrong state!");
break;
}
@@ -384,7 +347,7 @@ void ODbTypeWizDialog::enableConfirmSettings( bool _bEnable )
{
enableButtons( WZB_FINISH, _bEnable );
// TODO:
- // this is hacky. At the moment, this method is used in only one case (#b6532894#).
+ // this is hacky. At the moment, this method is used in only one case.
// As soon as it is to be used more wide-spread, we should find a proper concept
// for enabling both the Next and Finish buttons, depending on the current page state.
// Plus, the concept must also care for the case where those pages are embedded into
@@ -419,3 +382,5 @@ sal_Bool ODbTypeWizDialog::onFinish()
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dbwizsetup.cxx b/dbaccess/source/ui/dlg/dbwizsetup.cxx
index 4c9c2c6470f4..07793cea5c19 100644
--- a/dbaccess/source/ui/dlg/dbwizsetup.cxx
+++ b/dbaccess/source/ui/dlg/dbwizsetup.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -60,63 +61,25 @@
#include <cppuhelper/exc_hlp.hxx>
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_FRAME_XSTORABLE_HPP_
#include <com/sun/star/frame/XStorable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_XNAMINGSERVICE_HPP_
#include <com/sun/star/uno/XNamingService.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XDOCUMENTDATASOURCE_HPP_
#include <com/sun/star/sdb/XDocumentDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_
#include <com/sun/star/frame/XComponentLoader.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XMODEL_HPP_
#include <com/sun/star/frame/XModel.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XSIMPLEFILEACCESS_HPP_
#include <com/sun/star/ucb/XSimpleFileAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XJOBEXECUTOR_HPP_
#include <com/sun/star/task/XJobExecutor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XINITIALIZATION_HPP_
#include <com/sun/star/lang/XInitialization.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_INTERACTIVEIOEXCEPTION_HPP_
#include <com/sun/star/ucb/InteractiveIOException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_IOEXCEPTION_HPP_
#include <com/sun/star/io/IOException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XTERMINATELISTENER_HPP_
#include <com/sun/star/frame/XTerminateListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDESKTOP_HPP_
#include <com/sun/star/frame/XDesktop.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDRIVERACCESS_HPP_
#include <com/sun/star/sdbc/XDriverAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_MACROEXECMODE_HPP_
#include <com/sun/star/document/MacroExecMode.hpp>
-#endif
#include <com/sun/star/ucb/IOErrorCode.hpp>
#include <com/sun/star/task/XInteractionHandler2.hpp>
#include <com/sun/star/ui/dialogs/TemplateDescription.hpp>
@@ -129,6 +92,7 @@
#include <comphelper/namedvaluecollection.hxx>
#include <comphelper/sequenceashashmap.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <connectivity/DriversConfig.hxx>
#include <memory>
@@ -160,40 +124,8 @@ using namespace ::cppu;
#define START_PAGE 0
#define CONNECTION_PAGE 1
-
-
-
-//#define DBASE_PATH 1
-//#define TEXT_PATH 2
-//#define MSACCESS_PATH 3
-//#define LDAP_PATH 4
-//#define ADABAS_PATH 5
-//#define ADO_PATH 6
-//#define JDBC_PATH 7
-//#define ORACLE_PATH 8
-//#define MYSQL_JDBC_PATH 9
-//#define MYSQL_ODBC_PATH 10
-//#define ODBC_PATH 11
-//#define SPREADSHEET_PATH 12
-//#define OUTLOOKEXP_PATH 13
-//#define OUTLOOK_PATH 14
-//#define MOZILLA_PATH 15
-//#define EVOLUTION_PATH 16
-//#define EVOLUTION_PATH_GROUPWISE 17
-//#define EVOLUTION_PATH_LDAP 18
-//#define KAB_PATH 19
-//#define MACAB_PATH 20
-//#define THUNDERBIRD_PATH 21
-//#define CREATENEW_PATH 22
-//#define USERDEFINED_PATH 23
-//#define OPEN_DOC_PATH 24
-//#define MSACCESS2007_PATH 25
-//#define MYSQL_NATIVE_PATH 26
-
OFinalDBPageSetup* pFinalPage;
-
-
DBG_NAME(ODbTypeWizDialogSetup)
//=========================================================================
//= ODbTypeWizDialogSetup
@@ -240,7 +172,7 @@ ODbTypeWizDialogSetup::ODbTypeWizDialogSetup(Window* _pParent
if (pCollectionItem)
m_pCollection = pCollectionItem->getCollection();
- DBG_ASSERT(m_pCollection, "ODbTypeWizDialogSetup::ODbTypeWizDialogSetup : really need a DSN type collection !");
+ OSL_ENSURE(m_pCollection, "ODbTypeWizDialogSetup::ODbTypeWizDialogSetup : really need a DSN type collection !");
FreeResource();
@@ -250,7 +182,6 @@ ODbTypeWizDialogSetup::ODbTypeWizDialogSetup(Window* _pParent
m_pOutSet = new SfxItemSet( *_pItems->GetPool(), _pItems->GetRanges() );
m_pImpl->translateProperties(xDatasource, *m_pOutSet);
-// eType = m_pImpl->getDatasourceType(*m_pOutSet);
SetPageSizePixel(LogicToPixel(::Size(WIZARD_PAGE_X, WIZARD_PAGE_Y), MAP_APPFONT));
ShowButtonFixedLine(sal_True);
@@ -298,7 +229,7 @@ void ODbTypeWizDialogSetup::declareAuthDepPath( const ::rtl::OUString& _sURL, Pa
{
if ( bHasAuthentication || ( *aIter != PAGE_DBSETUPWIZARD_AUTHENTIFICATION ) )
aPath.push_back( *aIter );
- } // for(;aIter != aEnd;++aIter)
+ }
// call base method
::svt::RoadmapWizard::declarePath( _nPathId, aPath );
@@ -428,7 +359,7 @@ void ODbTypeWizDialogSetup::activateDatabasePath()
{
sal_Int32 nCreateNewDBIndex = m_pCollection->getIndexOf( m_pCollection->getEmbeddedDatabase() );
if ( nCreateNewDBIndex == -1 )
- nCreateNewDBIndex = m_pCollection->getIndexOf( ::rtl::OUString::createFromAscii( "sdbc:dbase:" ) );
+ nCreateNewDBIndex = m_pCollection->getIndexOf( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:dbase:")) );
OSL_ENSURE( nCreateNewDBIndex != -1, "ODbTypeWizDialogSetup::activateDatabasePath: the GeneralPage should have prevented this!" );
activatePath( static_cast< PathId >( nCreateNewDBIndex + 1 ), sal_True );
@@ -457,7 +388,7 @@ void ODbTypeWizDialogSetup::activateDatabasePath()
}
break;
default:
- DBG_ERROR( "ODbTypeWizDialogSetup::activateDatabasePath: unknown creation mode!" );
+ OSL_FAIL( "ODbTypeWizDialogSetup::activateDatabasePath: unknown creation mode!" );
}
enableButtons( WZB_NEXT, m_pGeneralPage->GetDatabaseCreationMode() != OGeneralPage::eOpenExisting );
@@ -724,7 +655,7 @@ IMPL_LINK(ODbTypeWizDialogSetup, ImplClickHdl, OMySQLIntroPageSetup*, _pMySQLInt
case OMySQLIntroPageSetup::VIA_NATIVE:
sURLPrefix = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:mysql:mysqlc:"));
break;
- } // switch( _pMySQLIntroPageSetup->getMySQLMode() )
+ }
activatePath( static_cast<PathId>(m_pCollection->getIndexOf(sURLPrefix) + 1), sal_True);
return sal_True;
}
@@ -795,7 +726,7 @@ sal_Bool ODbTypeWizDialogSetup::leaveState(WizardState _nState)
// -----------------------------------------------------------------------------
void ODbTypeWizDialogSetup::setTitle(const ::rtl::OUString& /*_sTitle*/)
{
- DBG_ERROR( "ODbTypeWizDialogSetup::setTitle: not implemented!" );
+ OSL_FAIL( "ODbTypeWizDialogSetup::setTitle: not implemented!" );
// why?
}
@@ -929,15 +860,13 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
}
else if ( m_pCollection->isFileSystemBased(eType) )
{
- Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString::createFromAscii( "com.sun.star.ucb.SimpleFileAccess" )), UNO_QUERY);
+ Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SimpleFileAccess"))), UNO_QUERY);
INetURLObject aDBPathURL(m_sWorkPath);
aDBPathURL.Append(m_aDocURL.getBase());
createUniqueFolderName(&aDBPathURL);
::rtl::OUString sPrefix = eType;
sUrl = aDBPathURL.GetMainURL( INetURLObject::NO_DECODE);
xSimpleFileAccess->createFolder(sUrl);
- //OFileNotation aFileNotation(sUrl);
- //sUrl = aFileNotation.get(OFileNotation::N_SYSTEM);
sUrl = sPrefix.concat(sUrl);
}
m_pOutSet->Put(SfxStringItem(DSID_CONNECTURL, sUrl));
@@ -998,7 +927,7 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
//-------------------------------------------------------------------------
void ODbTypeWizDialogSetup::createUniqueFolderName(INetURLObject* pURL)
{
- Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString::createFromAscii( "com.sun.star.ucb.SimpleFileAccess" )), UNO_QUERY);
+ Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SimpleFileAccess"))), UNO_QUERY);
:: rtl::OUString sLastSegmentName = pURL->getName();
sal_Bool bFolderExists = sal_True;
sal_Int32 i = 1;
@@ -1016,7 +945,7 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
//-------------------------------------------------------------------------
String ODbTypeWizDialogSetup::createUniqueFileName(const INetURLObject& _rURL)
{
- Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString::createFromAscii( "com.sun.star.ucb.SimpleFileAccess" )), UNO_QUERY);
+ Reference< XSimpleFileAccess > xSimpleFileAccess(getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.ucb.SimpleFileAccess"))), UNO_QUERY);
:: rtl::OUString sFilename = _rURL.getName();
::rtl::OUString BaseName = _rURL.getBase();
::rtl::OUString sExtension = _rURL.getExtension();
@@ -1207,3 +1136,4 @@ sal_Bool ODbTypeWizDialogSetup::SaveDatabaseDocument()
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/detailpages.cxx b/dbaccess/source/ui/dlg/detailpages.cxx
index e5e968396490..a1050a603d33 100644
--- a/dbaccess/source/ui/dlg/detailpages.cxx
+++ b/dbaccess/source/ui/dlg/detailpages.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -42,46 +43,20 @@
#include "dbu_dlg.hrc"
#include "dbadmin.hrc"
-#ifndef _SFXITEMSET_HXX
#include <svl/itemset.hxx>
-#endif
-#ifndef _SFXSTRITEM_HXX
#include <svl/stritem.hxx>
-#endif
-#ifndef _SFXENUMITEM_HXX
#include <svl/eitem.hxx>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _SV_MNEMONIC_HXX
#include <vcl/mnemonic.hxx>
-#endif
-#ifndef _SVTOOLS_CJKOPTIONS_HXX
#include <svl/cjkoptions.hxx>
-#endif
#include <jvmaccess/virtualmachine.hxx>
-#ifndef DBAUI_ADABASPAGE_HRC
#include "AdabasPage.hrc"
-#endif
-#ifndef _DBAUI_ADASTAT_HXX_
#include "AdabasStat.hxx"
-#endif
-#ifndef _CONNECTIVITY_COMMONTOOLS_HXX_
#include <connectivity/CommonTools.hxx>
-#endif
-#ifndef DBAUI_DRIVERSETTINGS_HXX
#include "DriverSettings.hxx"
-#endif
-#ifndef _DBAUI_DBADMIN_HXX_
#include "dbadmin.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
#include "AutoControlsDef.hrc"
//.........................................................................
@@ -139,7 +114,7 @@ namespace dbaui
m_pAutoIncrementLabel, m_pAutoIncrement,
m_pAutoRetrievingLabel, m_pAutoRetrieving };
- sal_Int32 nCount = sizeof(pWindows) / sizeof(pWindows[0]);
+ sal_Int32 nCount = SAL_N_ELEMENTS(pWindows);
for (sal_Int32 i=1; i < nCount; ++i)
{
if ( pWindows[i] )
@@ -392,7 +367,7 @@ namespace dbaui
,m_pOptionsLabel,m_pOptions,&m_aUseCatalog
};
- sal_Int32 nCount = sizeof(pWindows) / sizeof(pWindows[0]);
+ sal_Int32 nCount = SAL_N_ELEMENTS(pWindows);
for (sal_Int32 i=1; i < nCount; ++i)
pWindows[i]->SetZOrder(pWindows[i-1], WINDOW_ZORDER_BEHIND);
}
@@ -573,7 +548,7 @@ namespace dbaui
&m_aFTDriverClass, &m_aEDDriverClass,&m_aTestJavaDriver,
m_pCharsetLabel, m_pCharset};
- sal_Int32 nCount = sizeof(pWindows) / sizeof(pWindows[0]);
+ sal_Int32 nCount = SAL_N_ELEMENTS(pWindows);
for (sal_Int32 i=1; i < nCount; ++i)
pWindows[i]->SetZOrder(pWindows[i-1], WINDOW_ZORDER_BEHIND);
@@ -705,7 +680,7 @@ namespace dbaui
Window* pWindows[] = { &m_aMySQLSettings, &m_aSeparator2, &m_aUserNameLabel, &m_aUserName,
&m_aPasswordRequired, m_pCharsetLabel, m_pCharset};
- sal_Int32 nCount = sizeof(pWindows) / sizeof(pWindows[0]);
+ sal_Int32 nCount = SAL_N_ELEMENTS(pWindows);
for (sal_Int32 i=1; i < nCount; ++i)
pWindows[i]->SetZOrder(pWindows[i-1], WINDOW_ZORDER_BEHIND);
@@ -845,7 +820,7 @@ namespace dbaui
,&m_CB_SHUTDB
,m_pCharsetLabel, m_pCharset,&m_PB_STAT};
- sal_Int32 nCount = sizeof(pWindows) / sizeof(pWindows[0]);
+ sal_Int32 nCount = SAL_N_ELEMENTS(pWindows);
for (sal_Int32 i=1; i < nCount; ++i)
pWindows[i]->SetZOrder(pWindows[i-1], WINDOW_ZORDER_BEHIND);
}
@@ -1149,3 +1124,5 @@ namespace dbaui
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/detailpages.hxx b/dbaccess/source/ui/dlg/detailpages.hxx
index 2e7b90cd00ab..6d48d2fd2711 100644
--- a/dbaccess/source/ui/dlg/detailpages.hxx
+++ b/dbaccess/source/ui/dlg/detailpages.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
#ifndef _DBAUI_DETAILPAGES_HXX_
#define _DBAUI_DETAILPAGES_HXX_
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef _DBAUI_CHARSETS_HXX_
#include "charsets.hxx"
-#endif
-#ifndef CHARSETLISTBOX_HXX
#include "charsetlistbox.hxx"
-#endif
-#ifndef _SV_FIELD_HXX
#include <vcl/field.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef DBAUI_TEXTCONNECTIONHELPER_HXX
#include "TextConnectionHelper.hxx"
-#endif
#include "admincontrols.hxx"
#include <svtools/dialogcontrolling.hxx>
@@ -386,3 +369,5 @@ namespace dbaui
//.........................................................................
#endif // _DBAUI_DETAILPAGES_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/directsql.cxx b/dbaccess/source/ui/dlg/directsql.cxx
index 30d0e669687b..96541a21da17 100644
--- a/dbaccess/source/ui/dlg/directsql.cxx
+++ b/dbaccess/source/ui/dlg/directsql.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBACCESS_UI_DIRECTSQL_HXX_
#include "directsql.hxx"
-#endif
-#ifndef _DBACCESS_UI_DIRECTSQL_HRC_
#include "directsql.hrc"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
+#include <osl/mutex.hxx>
#include <tools/diagnose_ex.h>
-#endif
//........................................................................
namespace dbaui
@@ -151,7 +134,7 @@ DBG_NAME(DirectSQLDialog)
//--------------------------------------------------------------------
void DirectSQLDialog::_disposing( const EventObject& _rSource )
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard(m_aMutex);
OSL_ENSURE(Reference< XConnection >(_rSource.Source, UNO_QUERY).get() == m_xConnection.get(),
@@ -325,7 +308,7 @@ DBG_NAME(DirectSQLDialog)
m_aSQL.SetSelection(Selection(sStatement.Len(), sStatement.Len()));
}
else
- OSL_ENSURE(sal_False, "DirectSQLDialog::switchToHistory: invalid position!");
+ OSL_FAIL("DirectSQLDialog::switchToHistory: invalid position!");
}
//--------------------------------------------------------------------
@@ -365,3 +348,4 @@ DBG_NAME(DirectSQLDialog)
} // namespace dbaui
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/directsql.src b/dbaccess/source/ui/dlg/directsql.src
index cdde8fca5ed6..5428535c365a 100644
--- a/dbaccess/source/ui/dlg/directsql.src
+++ b/dbaccess/source/ui/dlg/directsql.src
@@ -137,4 +137,3 @@ String STR_DIRECTSQL_CONNECTIONLOST
{
Text [ en-US ] = "The connection to the database has been lost. This dialog will be closed.";
};
-
diff --git a/dbaccess/source/ui/dlg/dlgattr.cxx b/dbaccess/source/ui/dlg/dlgattr.cxx
index 143433837c2d..414853448b79 100644
--- a/dbaccess/source/ui/dlg/dlgattr.cxx
+++ b/dbaccess/source/ui/dlg/dlgattr.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,54 +30,23 @@
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_SBATTRDLG_HXX
#include "dlgattr.hxx"
-#endif
-#ifndef _SFXTABDLG_HXX //autogen
#include <sfx2/tabdlg.hxx>
-#endif
-#ifndef _SVX_NUMINF_HXX //autogen
#include <svx/numinf.hxx>
-#endif
-//CHINA001 #ifndef _SVX_CHARDLG_HXX //autogen
-//CHINA001 #include <svx/chardlg.hxx>
-//CHINA001 #endif
-
-//CHINA001 #ifndef _SVX_NUMFMT_HXX //autogen
-//CHINA001 #include <svx/numfmt.hxx>
-//CHINA001 #endif
-#ifndef _SVX_NUMINF_HXX
#include <svx/numinf.hxx>
-#endif
-
-//CHINA001 #ifndef _SVX_ALIGN_HXX //autogen
-//CHINA001 #include <svx/align.hxx>
-//CHINA001 #endif
-#ifndef _SVX_DIALOGS_HRC
#include <svx/dialogs.hrc>
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _SFXITEMSET_HXX
#include <svl/itemset.hxx>
-#endif
#define _ZFORLIST_DECLARE_TABLE
-#ifndef _ZFORLIST_HXX
#include <svl/zforlist.hxx>
-#endif
-#include <svx/svxids.hrc> //CHINA001
-#include <svx/flagsdef.hxx> //CHINA001
-#ifndef _SFXINTITEM_HXX //CHINA001
-#include <svl/intitem.hxx> //CHINA001
-#endif //CHINA001
-#ifndef _DBAUI_MODULE_DBU_HXX_
+#include <svx/svxids.hrc>
+#include <svx/flagsdef.hxx>
+#include <svl/intitem.hxx>
#include "moduledbu.hxx"
-#endif
using namespace dbaui;
DBG_NAME(SbaSbAttrDlg)
@@ -93,13 +63,12 @@ SbaSbAttrDlg::SbaSbAttrDlg(Window* pParent, const SfxItemSet* pCellAttrs, SvNumb
SetText(aTitle);
if( nFlags & TP_ATTR_CHAR )
{
-// AddTabPage( RID_SVXPAGE_CHAR_STD,String(ModuleRes(TP_ATTR_CHAR)),SvxCharStdPage::Create, 0 );
- DBG_ERROR( "found flag TP_ATTR_CHAR" );
+ OSL_FAIL( "found flag TP_ATTR_CHAR" );
}
if( nFlags & TP_ATTR_NUMBER )
- AddTabPage( RID_SVXPAGE_NUMBERFORMAT,String(ModuleRes(TP_ATTR_NUMBER)) ); //CHINA001 AddTabPage( RID_SVXPAGE_NUMBERFORMAT,String(ModuleRes(TP_ATTR_NUMBER)),SvxNumberFormatTabPage::Create, 0 );
+ AddTabPage( RID_SVXPAGE_NUMBERFORMAT,String(ModuleRes(TP_ATTR_NUMBER)) );
if( nFlags & TP_ATTR_ALIGN )
- AddTabPage( RID_SVXPAGE_ALIGNMENT,String(ModuleRes(TP_ATTR_ALIGN)) );//CHINA001 AddTabPage( RID_SVXPAGE_ALIGNMENT,String(ModuleRes(TP_ATTR_ALIGN)),SvxAlignmentTabPage::Create, 0 );
+ AddTabPage( RID_SVXPAGE_ALIGNMENT,String(ModuleRes(TP_ATTR_ALIGN)) );
FreeResource();
}
@@ -119,8 +88,6 @@ void SbaSbAttrDlg::PageCreated( sal_uInt16 nPageId, SfxTabPage& rTabPage )
{
case RID_SVXPAGE_NUMBERFORMAT:
{
- //CHINA001 ((SvxNumberFormatTabPage&)rTabPage).
- //CHINA001 SetNumberFormatList( *pNumberInfoItem );
aSet.Put (SvxNumberInfoItem( pNumberInfoItem->GetNumberFormatter(), (const sal_uInt16)SID_ATTR_NUMBERFORMAT_INFO));
rTabPage.PageCreated(aSet);
}
@@ -128,15 +95,11 @@ void SbaSbAttrDlg::PageCreated( sal_uInt16 nPageId, SfxTabPage& rTabPage )
case RID_SVXPAGE_CHAR_STD:
{
- // ((SvxCharStdPage&)rTabPage).SetFontList(SBA_MOD_EXT()->FontListItem());
}
break;
case RID_SVXPAGE_ALIGNMENT:
{
- //CHINA001 ((SvxAlignmentTabPage&)rTabPage).SetFlags(WBA_NO_ORIENTATION|WBA_NO_LINEBREAK|WBA_NO_GRIDLINES|WBA_NO_VERTICAL|WBA_NO_LEFTINDENT);
-// aSet.Put (SfxUInt32Item(SID_FLAG_TYPE, WBA_NO_ORIENTATION|WBA_NO_LINEBREAK|WBA_NO_GRIDLINES|WBA_NO_VERTICAL|WBA_NO_LEFTINDENT));
-// rTabPage.PageCreated(aSet);
}
break;
@@ -146,3 +109,4 @@ void SbaSbAttrDlg::PageCreated( sal_uInt16 nPageId, SfxTabPage& rTabPage )
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dlgattr.src b/dbaccess/source/ui/dlg/dlgattr.src
index 8dce0835aa69..4ed8c1c5644a 100644
--- a/dbaccess/source/ui/dlg/dlgattr.src
+++ b/dbaccess/source/ui/dlg/dlgattr.src
@@ -36,6 +36,7 @@
#ifndef DBAUI_SBATTRDLG_HRC
#include "dlgattr.hrc"
#endif
+
//================================================
// Der Attributdialog:
TabDialog DLG_ATTR
@@ -73,7 +74,6 @@ TabDialog DLG_ATTR
};
String TP_ATTR_CHAR
{
- /* ### ACHTUNG: Neuer Text in Resource? Schrift : Zeichen */
Text [ en-US ] = "Font" ;
};
String TP_ATTR_NUMBER
@@ -89,34 +89,3 @@ TabDialog DLG_ATTR
Text [ en-US ] = "Table Format" ;
};
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/dlg/dlgsave.cxx b/dbaccess/source/ui/dlg/dlgsave.cxx
index 3c6bb87c757e..4a7bdf349505 100644
--- a/dbaccess/source/ui/dlg/dlgsave.cxx
+++ b/dbaccess/source/ui/dlg/dlgsave.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,66 +29,26 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_DLGSAVE_HXX
#include "dlgsave.hxx"
-#endif
-#ifndef DBAUI_DLGSAVE_HRC
#include "dlgsave.hrc"
-#endif
-#ifndef _SV_MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef DBAUI_SQLNAMEEDIT_HXX
#include "SqlNameEdit.hxx"
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _EDIT_HXX //autogen
#include <vcl/edit.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMEACCESS_HPP_
#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_UI_INC_OBJECTNAMECHECK_HXX
#include "objectnamecheck.hxx"
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
using namespace dbaui;
@@ -348,7 +309,7 @@ OSaveAsDlg::OSaveAsDlg( Window * pParent,
break;
default:
- OSL_ENSURE( false, "OSaveAsDlg::OSaveAsDlg: Type not supported yet!" );
+ OSL_FAIL( "OSaveAsDlg::OSaveAsDlg: Type not supported yet!" );
}
implInit();
@@ -484,3 +445,4 @@ String OSaveAsDlg::getName() const { return m_pImpl->m_aName; }
String OSaveAsDlg::getCatalog() const { return m_pImpl->m_aCatalog.IsVisible() ? m_pImpl->m_aCatalog.GetText() : String(); }
String OSaveAsDlg::getSchema() const { return m_pImpl->m_aSchema.IsVisible() ? m_pImpl->m_aSchema.GetText() : String(); }
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dlgsave.src b/dbaccess/source/ui/dlg/dlgsave.src
index 802f88d0869a..bc94b77eee37 100644
--- a/dbaccess/source/ui/dlg/dlgsave.src
+++ b/dbaccess/source/ui/dlg/dlgsave.src
@@ -141,4 +141,3 @@ ModalDialog DLG_SAVE_AS
Text [ en-US ] = "Insert as";
};
};
-
diff --git a/dbaccess/source/ui/dlg/dlgsize.cxx b/dbaccess/source/ui/dlg/dlgsize.cxx
index 10bbac679b32..089b70a6d3e3 100644
--- a/dbaccess/source/ui/dlg/dlgsize.cxx
+++ b/dbaccess/source/ui/dlg/dlgsize.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_DLGSIZE_HRC
#include "dlgsize.hrc"
-#endif
-#ifndef _DBAUI_DLGSIZE_HXX
#include "dlgsize.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -128,3 +121,4 @@ IMPL_LINK( DlgSize, CbClickHdl, Button *, pButton )
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dlgsize.src b/dbaccess/source/ui/dlg/dlgsize.src
index ea2a97d5910c..556c53974c9a 100644
--- a/dbaccess/source/ui/dlg/dlgsize.src
+++ b/dbaccess/source/ui/dlg/dlgsize.src
@@ -149,34 +149,3 @@ ModalDialog DLG_COLWIDTH
};
Text [ en-US ] = "Column Width" ;
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/dlg/dsnItem.hxx b/dbaccess/source/ui/dlg/dsnItem.hxx
index ac66e4386bf9..a3b542a1d4f6 100644
--- a/dbaccess/source/ui/dlg/dsnItem.hxx
+++ b/dbaccess/source/ui/dlg/dsnItem.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -67,3 +68,4 @@ namespace dbaui
#endif // _DBAUI_DSNITEM_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dsselect.cxx b/dbaccess/source/ui/dlg/dsselect.cxx
index 0851fddb5249..9f6dfda58a97 100644
--- a/dbaccess/source/ui/dlg/dsselect.cxx
+++ b/dbaccess/source/ui/dlg/dsselect.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,70 +29,29 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_DSSELECT_HXX_
#include "dsselect.hxx"
-#endif
-#ifndef _DBAUI_DSSELECT_HRC_
#include "dsselect.hrc"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _DBAUI_LOCALRESACCESS_HXX_
#include "localresaccess.hxx"
-#endif
-#ifndef _TOOLS_RCID_H
#include <tools/rcid.h>
-#endif
+#include <sal/macros.h>
-#ifndef _COM_SUN_STAR_SDBCX_XCREATECATALOG_HPP_
#include <com/sun/star/sdbcx/XCreateCatalog.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP_
#include <com/sun/star/beans/XPropertySetInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XEXECUTABLEDIALOG_HPP_
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XWINDOW_HPP_
#include <com/sun/star/awt/XWindow.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COMPHELPER_PROCESSFACTORY_HXX_
#include <comphelper/processfactory.hxx>
-#endif
-#ifndef _DBAUI_DATASOURCEITEMS_HXX_
#include "dsitems.hxx"
-#endif
-#ifndef _SFXSTRITEM_HXX
#include <svl/stritem.hxx>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef _SFXENUMITEM_HXX
#include <svl/eitem.hxx>
-#endif
-#ifndef _SFXITEMSET_HXX
#include <svl/itemset.hxx>
-#endif
//.........................................................................
namespace dbaui
@@ -141,7 +101,7 @@ ODatasourceSelectDialog::ODatasourceSelectDialog(Window* _pParent, const StringB
// move the buttons
PushButton* pButtons[] = { &m_aOk, &m_aCancel, &m_aHelp ,&m_aCreateAdabasDB};
- for (size_t i=0; i<sizeof(pButtons)/sizeof(pButtons[0]); ++i)
+ for (size_t i=0; i < SAL_N_ELEMENTS(pButtons); ++i)
{
Point aOldPos = pButtons[i]->GetPosPixel();
pButtons[i]->SetPosPixel(Point(aOldPos.X() - nLostPixels, aOldPos.Y()));
@@ -189,7 +149,7 @@ IMPL_LINK( ODatasourceSelectDialog, CreateDBClickHdl, PushButton*, /*pButton*/ )
if ( xCatalog.is() && m_pOutputSet )
{
Sequence< Any > aArgs(2);
- aArgs[0] <<= PropertyValue(::rtl::OUString::createFromAscii("CreateCatalog"), 0,makeAny(xCatalog) , PropertyState_DIRECT_VALUE);
+ aArgs[0] <<= PropertyValue(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("CreateCatalog")), 0, makeAny(xCatalog), PropertyState_DIRECT_VALUE);
aArgs[1] <<= PropertyValue(PROPERTY_PARENTWINDOW, 0, makeAny(VCLUnoHelper::GetInterface(this)), PropertyState_DIRECT_VALUE);
Reference< XExecutableDialog > xDialog(
@@ -316,3 +276,4 @@ void ODatasourceSelectDialog::fillListBox(const StringBag& _rDatasources)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dsselect.hxx b/dbaccess/source/ui/dlg/dsselect.hxx
index 93509a044d45..34050aff9cb9 100644
--- a/dbaccess/source/ui/dlg/dsselect.hxx
+++ b/dbaccess/source/ui/dlg/dsselect.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,3 +94,4 @@ protected:
#endif // _DBAUI_DSSELECT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/dsselect.src b/dbaccess/source/ui/dlg/dsselect.src
index f6fca187ba58..d6a8855559a2 100644
--- a/dbaccess/source/ui/dlg/dsselect.src
+++ b/dbaccess/source/ui/dlg/dsselect.src
@@ -107,5 +107,3 @@ ModalDialog DLG_DATASOURCE_SELECTION
Text [ en-US ] = "Choose a database";
};
};
-
-
diff --git a/dbaccess/source/ui/dlg/finteraction.cxx b/dbaccess/source/ui/dlg/finteraction.cxx
index afaad9788211..2a0e6be0715a 100644
--- a/dbaccess/source/ui/dlg/finteraction.cxx
+++ b/dbaccess/source/ui/dlg/finteraction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_FILEPICKER_INTERACTION_HXX
#include "finteraction.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UCB_INTERACTIVEIOEXCEPTION_HPP_
+#include <osl/diagnose.h>
#include <com/sun/star/ucb/InteractiveIOException.hpp>
-#endif
//........................................................................
namespace dbaui
@@ -56,7 +52,7 @@ namespace dbaui
,m_bDoesNotExist(sal_False)
{
DBG_CTOR( OFilePickerInteractionHandler, NULL );
- DBG_ASSERT( m_xMaster.is(), "OFilePickerInteractionHandler::OFilePickerInteractionHandler: invalid master handler!" );
+ OSL_ENSURE( m_xMaster.is(), "OFilePickerInteractionHandler::OFilePickerInteractionHandler: invalid master handler!" );
}
//--------------------------------------------------------------------
@@ -86,3 +82,4 @@ namespace dbaui
} // namespace svt
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/finteraction.hxx b/dbaccess/source/ui/dlg/finteraction.hxx
index b11e960a144e..bbc837e0b074 100644
--- a/dbaccess/source/ui/dlg/finteraction.hxx
+++ b/dbaccess/source/ui/dlg/finteraction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef DBAUI_FILEPICKER_INTERACTION_HXX
#define DBAUI_FILEPICKER_INTERACTION_HXX
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
//........................................................................
namespace dbaui
@@ -73,3 +70,4 @@ namespace dbaui
#endif // DBAUI_FILEPICKER_INTERACTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/generalpage.cxx b/dbaccess/source/ui/dlg/generalpage.cxx
index 8bff43cfc0c6..b9628fe046cc 100644
--- a/dbaccess/source/ui/dlg/generalpage.cxx
+++ b/dbaccess/source/ui/dlg/generalpage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -51,6 +52,7 @@
#include "UITools.hxx"
#include <comphelper/processfactory.hxx>
#include <unotools/confignode.hxx>
+#include <osl/diagnose.h>
//.........................................................................
namespace dbaui
@@ -99,12 +101,12 @@ namespace dbaui
DbuTypeCollectionItem* pCollectionItem = PTR_CAST(DbuTypeCollectionItem, _rItems.GetItem(DSID_TYPECOLLECTION));
if (pCollectionItem)
m_pCollection = pCollectionItem->getCollection();
- DBG_ASSERT(m_pCollection, "OGeneralPage::OGeneralPage : really need a DSN type collection !");
+ OSL_ENSURE(m_pCollection, "OGeneralPage::OGeneralPage : really need a DSN type collection !");
// If no driver for embedded DBs is installed, and no dBase driver, then hide the "Create new database" option
sal_Int32 nCreateNewDBIndex = m_pCollection->getIndexOf( m_pCollection->getEmbeddedDatabase() );
if ( nCreateNewDBIndex == -1 )
- nCreateNewDBIndex = m_pCollection->getIndexOf( ::rtl::OUString::createFromAscii( "sdbc:dbase:" ) );
+ nCreateNewDBIndex = m_pCollection->getIndexOf( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("sdbc:dbase:")) );
bool bHideCreateNew = ( nCreateNewDBIndex == -1 );
// also, if our application policies tell us to hide the option, do it
@@ -126,7 +128,7 @@ namespace dbaui
&m_aTypePostLabel
};
const long nOffset = m_aRB_OpenDocument.GetPosPixel().Y() - m_aRB_CreateDatabase.GetPosPixel().Y();
- for ( size_t i=0; i < sizeof( pWindowsToMove ) / sizeof( pWindowsToMove[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( pWindowsToMove ); ++i )
{
Point aPos( pWindowsToMove[i]->GetPosPixel() );
aPos.Y() -= nOffset;
@@ -212,7 +214,7 @@ namespace dbaui
++loop
)
insertDatasourceTypeEntryData( loop->eType, loop->sDisplayName );
- } // if ( m_pCollection )
+ }
}
}
@@ -359,8 +361,8 @@ namespace dbaui
// collect some items and some values
SFX_ITEMSET_GET(_rSet, pNameItem, SfxStringItem, DSID_NAME, sal_True);
SFX_ITEMSET_GET(_rSet, pUrlItem, SfxStringItem, DSID_CONNECTURL, sal_True);
- DBG_ASSERT(pUrlItem, "OGeneralPage::implInitControls : missing the type attribute !");
- DBG_ASSERT(pNameItem, "OGeneralPage::implInitControls : missing the type attribute !");
+ OSL_ENSURE(pUrlItem, "OGeneralPage::implInitControls : missing the type attribute !");
+ OSL_ENSURE(pNameItem, "OGeneralPage::implInitControls : missing the type attribute !");
sName = pNameItem->GetValue();
sConnectURL = pUrlItem->GetValue();
}
@@ -606,7 +608,6 @@ namespace dbaui
const SfxFilter* pFilter = getStandardDatabaseFilter();
if ( pFilter )
{
-// aFileDlg.AddFilter(pFilter->GetUIName(),pFilter->GetDefaultExtension());
aFileDlg.SetCurrentFilter(pFilter->GetUIName());
}
if ( aFileDlg.Execute() == ERRCODE_NONE )
@@ -634,3 +635,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/generalpage.hxx b/dbaccess/source/ui/dlg/generalpage.hxx
index 729e38eb7dff..5bd2dbe189fa 100644
--- a/dbaccess/source/ui/dlg/generalpage.hxx
+++ b/dbaccess/source/ui/dlg/generalpage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,21 +29,11 @@
#ifndef _DBAUI_GENERALPAGE_HXX_
#define _DBAUI_GENERALPAGE_HXX_
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_UI_INC_OPENDOCCONTROLS_HXX
#include "opendoccontrols.hxx"
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
#include <svtools/dialogcontrolling.hxx>
#include <memory>
@@ -175,3 +166,5 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
#endif // _DBAUI_GENERALPAGE_HXX_
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/indexdialog.cxx b/dbaccess/source/ui/dlg/indexdialog.cxx
index ea6735ab0234..10af9cdcc3cf 100644
--- a/dbaccess/source/ui/dlg/indexdialog.cxx
+++ b/dbaccess/source/ui/dlg/indexdialog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,42 +29,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_INDEXDIALOG_HXX_
#include "indexdialog.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBAUI_INDEXDIALOG_HRC_
#include "indexdialog.hrc"
-#endif
-#ifndef _DBAUI_INDEXFIELDSCONTROL_HXX_
#include "indexfieldscontrol.hxx"
-#endif
-#ifndef _DBAUI_INDEXCOLLECTION_HXX_
#include "indexcollection.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _SVTOOLS_IMGDEF_HXX
#include <svtools/imgdef.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
+#include <osl/diagnose.h>
//......................................................................
namespace dbaui
{
@@ -168,14 +146,14 @@ namespace dbaui
//------------------------------------------------------------------
void DbaIndexList::enableSelectHandler()
{
- DBG_ASSERT(m_bSuspendSelectHdl, "DbaIndexList::enableSelectHandler: invalid call (this is not cumulative)!");
+ OSL_ENSURE(m_bSuspendSelectHdl, "DbaIndexList::enableSelectHandler: invalid call (this is not cumulative)!");
m_bSuspendSelectHdl = sal_False;
}
//------------------------------------------------------------------
void DbaIndexList::disableSelectHandler()
{
- DBG_ASSERT(!m_bSuspendSelectHdl, "DbaIndexList::enableSelectHandler: invalid call (this is not cumulative)!");
+ OSL_ENSURE(!m_bSuspendSelectHdl, "DbaIndexList::enableSelectHandler: invalid call (this is not cumulative)!");
m_bSuspendSelectHdl = sal_True;
}
@@ -209,7 +187,7 @@ DBG_NAME(DbaIndexDialog)
const Reference< XMultiServiceFactory >& _rxORB,sal_Int32 _nMaxColumnsInIndex)
:ModalDialog( _pParent, ModuleRes(DLG_INDEXDESIGN))
,m_xConnection(_rxConnection)
- ,m_aGeometrySettings(E_DIALOG, ::rtl::OUString::createFromAscii("dbaccess.tabledesign.indexdialog"))
+ ,m_aGeometrySettings(E_DIALOG, ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("dbaccess.tabledesign.indexdialog")))
,m_aActions (this, ModuleRes(TLB_ACTIONS))
,m_aIndexes (this, ModuleRes(CTR_INDEXLIST))
,m_aIndexDetails (this, ModuleRes(FL_INDEXDETAILS))
@@ -252,7 +230,7 @@ DBG_NAME(DbaIndexDialog)
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "DbaIndexDialog::DbaIndexDialog: could not retrieve basic information from the UNO collection!");
+ OSL_FAIL("DbaIndexDialog::DbaIndexDialog: could not retrieve basic information from the UNO collection!");
}
fillIndexList();
@@ -262,14 +240,6 @@ DBG_NAME(DbaIndexDialog)
m_aClose.SetClickHdl(LINK(this, DbaIndexDialog, OnCloseDialog));
- // get our most recent geometry settings
-// if (m_aGeometrySettings.Exists())
-// {
-// Point aPos;
-// m_aGeometrySettings.GetPosition(aPos.X(), aPos.Y());
-// SetPosPixel(aPos);
-// }
-
// if all of the indexes have an empty description, we're not interested in displaying it
Indexes::const_iterator aCheck;
@@ -339,8 +309,7 @@ DBG_NAME(DbaIndexDialog)
//------------------------------------------------------------------
void DbaIndexDialog::fillIndexList()
{
- sal_Bool bHiContrast = GetSettings().GetStyleSettings().GetHighContrastMode();
- Image aPKeyIcon(ModuleRes( bHiContrast ? IMG_PKEYICON_SCH : IMG_PKEYICON));
+ Image aPKeyIcon(ModuleRes( IMG_PKEYICON ));
// fill the list with the index names
m_aIndexes.Clear();
Indexes::iterator aIndexLoop = m_pIndexes->begin();
@@ -366,17 +335,13 @@ DBG_NAME(DbaIndexDialog)
delete m_pIndexes;
delete m_pFields;
- // save our geometry settings
-// Point aPos = GetPosPixel();
-// m_aGeometrySettings.SetPosition(aPos.X(), aPos.Y());
-
DBG_DTOR(DbaIndexDialog,NULL);
}
//------------------------------------------------------------------
sal_Bool DbaIndexDialog::implCommit(SvLBoxEntry* _pEntry)
{
- DBG_ASSERT(_pEntry, "DbaIndexDialog::implCommit: invalid entry!");
+ OSL_ENSURE(_pEntry, "DbaIndexDialog::implCommit: invalid entry!");
Indexes::iterator aCommitPos = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(_pEntry->GetUserData());
@@ -431,7 +396,7 @@ DBG_NAME(DbaIndexDialog)
}
if ((i>0x7FFFFFFF) || (i<0))
{
- DBG_ERROR("DbaIndexDialog::OnNewIndex: no free index name found!");
+ OSL_FAIL("DbaIndexDialog::OnNewIndex: no free index name found!");
// can't do anything ... of course we try another base, but this could end with the same result ...
return;
}
@@ -444,7 +409,7 @@ DBG_NAME(DbaIndexDialog)
for (SvLBoxEntry* pAdjust = m_aIndexes.First(); pAdjust; pAdjust = m_aIndexes.Next(pAdjust))
{
Indexes::iterator aAfterInsertPos = m_pIndexes->find(m_aIndexes.GetEntryText(pAdjust));
- DBG_ASSERT(aAfterInsertPos != m_pIndexes->end(), "DbaIndexDialog::OnNewIndex: problems with on of the entries!");
+ OSL_ENSURE(aAfterInsertPos != m_pIndexes->end(), "DbaIndexDialog::OnNewIndex: problems with on of the entries!");
pAdjust->SetUserData(reinterpret_cast< void* >(sal_Int32(aAfterInsertPos - m_pIndexes->begin())));
}
@@ -460,7 +425,7 @@ DBG_NAME(DbaIndexDialog)
{
// the selected index
SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
- DBG_ASSERT(pSelected, "DbaIndexDialog::OnDropIndex: invalid call!");
+ OSL_ENSURE(pSelected, "DbaIndexDialog::OnDropIndex: invalid call!");
if (pSelected)
{
// let the user confirm the drop
@@ -486,7 +451,7 @@ DBG_NAME(DbaIndexDialog)
{
// do the drop
Indexes::iterator aDropPos = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(_pEntry->GetUserData());
- DBG_ASSERT(aDropPos != m_pIndexes->end(), "DbaIndexDialog::OnDropIndex: did not find the index in my collection!");
+ OSL_ENSURE(aDropPos != m_pIndexes->end(), "DbaIndexDialog::OnDropIndex: did not find the index in my collection!");
SQLExceptionInfo aExceptionInfo;
sal_Bool bSuccess = sal_False;
@@ -516,7 +481,7 @@ DBG_NAME(DbaIndexDialog)
for (SvLBoxEntry* pAdjust = m_aIndexes.First(); pAdjust; pAdjust = m_aIndexes.Next(pAdjust))
{
Indexes::iterator aAfterDropPos = m_pIndexes->find(m_aIndexes.GetEntryText(pAdjust));
- DBG_ASSERT(aAfterDropPos != m_pIndexes->end(), "DbaIndexDialog::OnDropIndex: problems with on of the remaining entries!");
+ OSL_ENSURE(aAfterDropPos != m_pIndexes->end(), "DbaIndexDialog::OnDropIndex: problems with on of the remaining entries!");
pAdjust->SetUserData(reinterpret_cast< void* >(sal_Int32(aAfterDropPos - m_pIndexes->begin())));
}
@@ -537,7 +502,7 @@ DBG_NAME(DbaIndexDialog)
{
// the selected index
SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
- DBG_ASSERT(pSelected, "DbaIndexDialog::OnRenameIndex: invalid call!");
+ OSL_ENSURE(pSelected, "DbaIndexDialog::OnRenameIndex: invalid call!");
// save the changes made 'til here
// Upon leaving the edit mode, the control will be re-initialized with the
@@ -566,7 +531,7 @@ DBG_NAME(DbaIndexDialog)
{
// the selected index
SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
- DBG_ASSERT(pSelected, "DbaIndexDialog::OnResetIndex: invalid call!");
+ OSL_ENSURE(pSelected, "DbaIndexDialog::OnResetIndex: invalid call!");
Indexes::iterator aResetPos = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(pSelected->GetUserData());
@@ -624,7 +589,7 @@ DBG_NAME(DbaIndexDialog)
{
if (m_aIndexes.IsEditingActive())
{
- DBG_ASSERT(!m_bEditAgain, "DbaIndexDialog::OnCloseDialog: somebody was faster than hell!");
+ OSL_ENSURE(!m_bEditAgain, "DbaIndexDialog::OnCloseDialog: somebody was faster than hell!");
// this means somebody entered a new name, which was invalid, which cause us to posted us an event,
// and before the event arrived the user clicked onto "close". VERY fast, this user ....
m_aIndexes.EndEditing(sal_False);
@@ -635,7 +600,7 @@ DBG_NAME(DbaIndexDialog)
// the currently selected entry
const SvLBoxEntry* pSelected = m_aIndexes.FirstSelected();
- DBG_ASSERT(pSelected == m_pPreviousSelection, "DbaIndexDialog::OnCloseDialog: inconsistence!");
+ OSL_ENSURE(pSelected == m_pPreviousSelection, "DbaIndexDialog::OnCloseDialog: inconsistence!");
sal_Int32 nResponse = RET_NO;
if (pSelected)
@@ -680,7 +645,7 @@ DBG_NAME(DbaIndexDialog)
{
Indexes::iterator aPosition = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(_pEntry->GetUserData());
- DBG_ASSERT(aPosition >= m_pIndexes->begin() && aPosition < m_pIndexes->end(),
+ OSL_ENSURE(aPosition >= m_pIndexes->begin() && aPosition < m_pIndexes->end(),
"DbaIndexDialog::OnEntryEdited: invalid entry!");
String sNewName = m_aIndexes.GetEntryText(_pEntry);
@@ -804,7 +769,7 @@ DBG_NAME(DbaIndexDialog)
//------------------------------------------------------------------
IMPL_LINK( DbaIndexDialog, OnModified, void*, /*NOTINTERESTEDIN*/ )
{
- DBG_ASSERT(m_pPreviousSelection, "DbaIndexDialog, OnModified: invalid call!");
+ OSL_ENSURE(m_pPreviousSelection, "DbaIndexDialog, OnModified: invalid call!");
Indexes::iterator aPosition = m_pIndexes->begin() + reinterpret_cast<sal_IntPtr>(m_pPreviousSelection->GetUserData());
aPosition->setModified(sal_True);
@@ -912,22 +877,19 @@ DBG_NAME(DbaIndexDialog)
}
}
//------------------------------------------------------------------
- ImageList DbaIndexDialog::getImageList(sal_Int16 _eBitmapSet,sal_Bool _bHiContast) const
+ ImageList DbaIndexDialog::getImageList(sal_Int16 _eBitmapSet) const
{
sal_Int16 nN = IMG_INDEX_DLG_SC;
- sal_Int16 nH = IMG_INDEX_DLG_SCH;
if ( _eBitmapSet == SFX_SYMBOLS_SIZE_LARGE )
{
nN = IMG_INDEX_DLG_LC;
- nH = IMG_INDEX_DLG_LCH;
- } // if ( _eBitmapSet == SFX_SYMBOLS_LARGE )
- return ImageList(ModuleRes( _bHiContast ? nH : nN ));
+ }
+ return ImageList( nN );
}
//------------------------------------------------------------------
void DbaIndexDialog::resizeControls(const Size& _rDiff)
{
// we use large images so we must change them
- Size aTbNewSize = m_aActions.GetSizePixel();
if ( _rDiff.Width() || _rDiff.Height() )
{
Size aDlgSize = GetSizePixel();
@@ -960,3 +922,4 @@ DBG_NAME(DbaIndexDialog)
} // namespace dbaui
//......................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/indexdialog.src b/dbaccess/source/ui/dlg/indexdialog.src
index e4102b9c6f84..2071684c37b6 100644
--- a/dbaccess/source/ui/dlg/indexdialog.src
+++ b/dbaccess/source/ui/dlg/indexdialog.src
@@ -58,7 +58,6 @@ ModalDialog DLG_INDEXDESIGN
ToolBox TLB_ACTIONS
{
Pos = MAP_APPFONT ( 6 , 6 ) ;
- // Size = MAP_APPFONT ( DIALOG_SIZE_X - 14 , 14 ) ;
ButtonType = BUTTON_SYMBOL;
Align = BOXALIGN_TOP;
HelpId = HID_INDEX_DIALOG_ACTION_TB;
@@ -174,14 +173,17 @@ String STR_TAB_INDEX_SORTORDER
{
Text [ en-US ] = "Sort order" ;
};
+
String STR_TAB_INDEX_FIELD
{
Text [ en-US ] = "Index field" ;
};
+
String STR_ORDER_ASCENDING
{
Text [ en-US ] = "Ascending" ;
};
+
String STR_ORDER_DESCENDING
{
Text [ en-US ] = "Descending" ;
@@ -199,12 +201,7 @@ String STR_LOGICAL_INDEX_NAME
Image IMG_PKEYICON
{
- ImageBitmap = Bitmap { File = "pkey.bmp"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
-Image IMG_PKEYICON_SCH
-{
- ImageBitmap = Bitmap { File = "pkey_sch.bmp"; };
+ ImageBitmap = Bitmap { File = "pkey.png"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
@@ -236,4 +233,3 @@ String STR_INDEXDESIGN_DOUBLE_COLUMN_NAME
{
Text [ en-US ] = "In an index definition, no table column may occur more than once. However, you have entered column \"$name$\" twice.";
};
-
diff --git a/dbaccess/source/ui/dlg/indexfieldscontrol.cxx b/dbaccess/source/ui/dlg/indexfieldscontrol.cxx
index bb29db6f43bd..ae6b365859d6 100644
--- a/dbaccess/source/ui/dlg/indexfieldscontrol.cxx
+++ b/dbaccess/source/ui/dlg/indexfieldscontrol.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_INDEXFIELDSCONTROL_HXX_
#include "indexfieldscontrol.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
//......................................................................
namespace dbaui
@@ -205,7 +198,6 @@ DBG_NAME(IndexFieldsControl)
// insert rows for the the fields
RowInserted(GetRowCount(), m_aFields.size(), sal_False);
// insert an additional row for a new field for that index
-// if(!m_nMaxColumnsInIndex || GetRowCount() < m_nMaxColumnsInIndex )
RowInserted(GetRowCount(), 1, sal_False);
SetUpdateMode(sal_True);
@@ -318,7 +310,7 @@ DBG_NAME(IndexFieldsControl)
break;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::GetController: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::GetController: invalid column id!");
}
if (pReturn)
@@ -408,7 +400,7 @@ DBG_NAME(IndexFieldsControl)
}
break;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::SaveModified: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::SaveModified: invalid column id!");
}
return sal_True;
}
@@ -432,7 +424,7 @@ DBG_NAME(IndexFieldsControl)
break;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::InitController: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::InitController: invalid column id!");
}
}
@@ -498,7 +490,7 @@ DBG_NAME(IndexFieldsControl)
else
return _rRow->bSortAscending ? m_sAscendingText : m_sDescendingText;
default:
- OSL_ENSURE(sal_False, "IndexFieldsControl::GetCurrentRowCellText: invalid column id!");
+ OSL_FAIL("IndexFieldsControl::GetCurrentRowCellText: invalid column id!");
}
}
return String();
@@ -514,3 +506,4 @@ DBG_NAME(IndexFieldsControl)
} // namespace dbaui
//......................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/makefile.mk b/dbaccess/source/ui/dlg/makefile.mk
deleted file mode 100644
index ca0d3ab8cde7..000000000000
--- a/dbaccess/source/ui/dlg/makefile.mk
+++ /dev/null
@@ -1,154 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=uidlg
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-.IF "$(SYSTEM_ODBC_HEADERS)" == "YES"
-CFLAGS+=-DSYSTEM_ODBC_HEADERS
-.ENDIF
-
-.IF "$(WINDOWS_VISTA_PSDK)"!="" && "$(PROF_EDITION)"==""
-CDEFS+=-DWINDOWS_VISTA_PSDK
-.ENDIF
-
-.IF "$(GUI)$(COM)"=="WNTGCC" # for adoint.h
-CFLAGS+=-fpermissive
-.ENDIF
-
-# --- Files -------------------------------------
-
-# ... resource files ............................
-
-
-LOCALIZE_ME=AutoControls_tmpl.hrc
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- AutoControls.src \
- ConnectionPage.src \
- UserAdmin.src \
- admincontrols.src \
- directsql.src \
- AdabasStat.src \
- indexdialog.src \
- RelationDlg.src \
- adtabdlg.src \
- dlgsave.src \
- queryorder.src \
- queryfilter.src \
- paramdialog.src \
- dsselect.src \
- dbadmin.src \
- dbadmin2.src \
- dbadminsetup.src \
- dbfindex.src \
- dlgsize.src \
- CollectionView.src \
- dlgattr.src \
- advancedsettings.src\
- UserAdminDlg.src \
- sqlmessage.src \
- textconnectionsettings.src
-
-
-# ... object files ............................
-EXCEPTIONSFILES= \
- $(SLO)$/directsql.obj \
- $(SLO)$/dbwiz.obj \
- $(SLO)$/dbwizsetup.obj \
- $(SLO)$/generalpage.obj \
- $(SLO)$/indexfieldscontrol.obj \
- $(SLO)$/indexdialog.obj \
- $(SLO)$/RelationDlg.obj \
- $(SLO)$/adtabdlg.obj \
- $(SLO)$/dlgsave.obj \
- $(SLO)$/admincontrols.obj \
- $(SLO)$/adminpages.obj \
- $(SLO)$/queryorder.obj \
- $(SLO)$/queryfilter.obj \
- $(SLO)$/paramdialog.obj \
- $(SLO)$/dbadmin.obj \
- $(SLO)$/detailpages.obj \
- $(SLO)$/sqlmessage.obj \
- $(SLO)$/finteraction.obj \
- $(SLO)$/ConnectionPage.obj \
- $(SLO)$/ConnectionHelper.obj \
- $(SLO)$/TextConnectionHelper.obj \
- $(SLO)$/ConnectionPageSetup.obj \
- $(SLO)$/DBSetupConnectionPages.obj \
- $(SLO)$/UserAdminDlg.obj \
- $(SLO)$/UserAdmin.obj \
- $(SLO)$/AdabasStat.obj \
- $(SLO)$/tablespage.obj \
- $(SLO)$/DbAdminImpl.obj \
- $(SLO)$/TablesSingleDlg.obj \
- $(SLO)$/CollectionView.obj \
- $(SLO)$/dsselect.obj \
- $(SLO)$/dbfindex.obj \
- $(SLO)$/DriverSettings.obj \
- $(SLO)$/odbcconfig.obj \
- $(SLO)$/advancedsettings.obj \
- $(SLO)$/textconnectionsettings.obj
-
-SLOFILES= \
- $(EXCEPTIONSFILES) \
- $(SLO)$/dlgsize.obj \
- $(SLO)$/dlgattr.obj \
- $(SLO)$/optionalboolitem.obj
-
-.IF "$(WINDOWS_VISTA_PSDK)"!="" && "$(PROF_EDITION)"==""
-DISABLE_ADO=TRUE
-.ENDIF # "$(WINDOWS_VISTA_PSDK)"!="" && "$(PROF_EDITION)"==""
-
-.IF "$(GUI)"=="WNT" && "$(DISABLE_ADO)"==""
-SLOFILES+= $(SLO)$/adodatalinks.obj
-.ENDIF
-
-# --- Targets ----------------------------------
-.INCLUDE : target.mk
-
-$(SLO)$/ConnectionHelper.obj : $(LOCALIZE_ME_DEST)
-
-$(SLO)$/ConnectionPageSetup.obj : $(LOCALIZE_ME_DEST)
-
-$(SLO)$/DBSetupConnectionPages.obj : $(LOCALIZE_ME_DEST)
-
-$(SLO)$/TextConnectionHelper.obj : $(LOCALIZE_ME_DEST)
-
-$(SLO)$/detailpages.obj : $(LOCALIZE_ME_DEST)
-
-$(SLO)$/tablespage.obj : $(LOCALIZE_ME_DEST)
-
-$(SLO)$/ConnectionPage.obj : $(LOCALIZE_ME_DEST)
diff --git a/dbaccess/source/ui/dlg/odbcconfig.cxx b/dbaccess/source/ui/dlg/odbcconfig.cxx
index d31405cce9d2..a31e9ebed021 100644
--- a/dbaccess/source/ui/dlg/odbcconfig.cxx
+++ b/dbaccess/source/ui/dlg/odbcconfig.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,38 +29,25 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_ODBC_CONFIG_HXX_
#include "odbcconfig.hxx"
+
+#ifdef SYSTEM_ODBC_HEADERS
+#include <sqltypes.h>
+#else
+#include <odbc/sqltypes.h>
#endif
+
#include <rtl/bootstrap.hxx>
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _RTL_USTRBUF_HXX_
#include <rtl/ustrbuf.hxx>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _OSL_PROCESS_H_
#include <osl/process.h>
-#endif
-#ifndef _THREAD_HXX_
#include <osl/thread.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
#ifdef HAVE_ODBC_SUPPORT
-#if defined(OS2)
-#define ODBC_LIBRARY "ODBC.DLL"
-#define ODBC_UI_LIBRARY "ODBCINST.DLL"
-#endif
#if defined WNT
#define ODBC_LIBRARY "ODBC32.DLL"
#define ODBC_UI_LIBRARY "ODBCCP32.DLL"
@@ -90,18 +78,11 @@
#endif
#endif // defined(WNT)
-#if defined(OS2)
-#define ALLREADY_HAVE_OS2_TYPES
-#define DONT_TD_VOID
-#endif
-
#ifdef SYSTEM_ODBC_HEADERS
#include <sqlext.h>
#else
-#ifndef __SQLEXT_H
#include <odbc/sqlext.h>
#endif
-#endif
#if defined(WNT)
#if defined _MSC_VER
@@ -112,10 +93,6 @@
#endif // defined(WNT)
// from here on you can do what you want to
-#if defined(OS2)
-#define SQL_API _System
-#endif // defined(OS2)
-
#else
#define ODBC_LIBRARY ""
@@ -295,7 +272,7 @@ void OOdbcEnumeration::getDatasourceNames(StringBag& _rNames)
if (!allocEnv())
{
- OSL_ENSURE(sal_False, "OOdbcEnumeration::getDatasourceNames: could not allocate an ODBC environment!");
+ OSL_FAIL("OOdbcEnumeration::getDatasourceNames: could not allocate an ODBC environment!");
return;
}
@@ -401,3 +378,5 @@ bool OOdbcManagement::isRunning() const
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/odbcconfig.hxx b/dbaccess/source/ui/dlg/odbcconfig.hxx
index 8c0c70defe07..2c950ba5f473 100644
--- a/dbaccess/source/ui/dlg/odbcconfig.hxx
+++ b/dbaccess/source/ui/dlg/odbcconfig.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,11 +31,11 @@
#include "commontypes.hxx"
-#if defined(WNT) || defined (UNX) || defined (OS2)
+#if defined(WNT) || defined (UNX)
#define HAVE_ODBC_SUPPORT
#endif
-#if ( defined(WNT) || defined (OS2) ) && defined(HAVE_ODBC_SUPPORT)
+#if defined(WNT) && defined(HAVE_ODBC_SUPPORT)
#define HAVE_ODBC_ADMINISTRATION
#endif
@@ -138,3 +139,4 @@ public:
#endif // _DBAUI_ODBC_CONFIG_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/optionalboolitem.cxx b/dbaccess/source/ui/dlg/optionalboolitem.cxx
index 688a47eef7b6..963a12b1a300 100644
--- a/dbaccess/source/ui/dlg/optionalboolitem.cxx
+++ b/dbaccess/source/ui/dlg/optionalboolitem.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -74,3 +75,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/optionalboolitem.hxx b/dbaccess/source/ui/dlg/optionalboolitem.hxx
index 89d7d0d5de3b..0fdb2dedf611 100644
--- a/dbaccess/source/ui/dlg/optionalboolitem.hxx
+++ b/dbaccess/source/ui/dlg/optionalboolitem.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -65,3 +66,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_OPTIONALBOOLITEM_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/paramdialog.cxx b/dbaccess/source/ui/dlg/paramdialog.cxx
index 163675229bca..8293b6231e42 100644
--- a/dbaccess/source/ui/dlg/paramdialog.cxx
+++ b/dbaccess/source/ui/dlg/paramdialog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,49 +29,21 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_PARAMDIALOG_HXX_
#include "paramdialog.hxx"
-#endif
-#ifndef _DBAUI_PARAMDIALOG_HRC_
#include "paramdialog.hrc"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
+#include <osl/diagnose.h>
#include <tools/diagnose_ex.h>
-#ifndef _DBAUI_LOCALRESACCESS_HXX_
#include "localresaccess.hxx"
-#endif
-#ifndef INCLUDED_SVTOOLS_SYSLOCALE_HXX
#include <unotools/syslocale.hxx>
-#endif
#define EF_VISITED 0x0001
#define EF_DIRTY 0x0002
@@ -122,7 +95,7 @@ DBG_NAME(OParameterDialog)
m_xFormatter = Reference< XNumberFormatter>(_rxORB->createInstance(
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.NumberFormatter"))), UNO_QUERY);
else {
- DBG_ERROR("OParameterDialog::OParameterDialog: need a service factory!");
+ OSL_FAIL("OParameterDialog::OParameterDialog: need a service factory!");
}
Reference< XNumberFormatsSupplier > xNumberFormats = ::dbtools::getNumberFormats(m_xConnection, sal_True);
@@ -132,7 +105,7 @@ DBG_NAME(OParameterDialog)
m_xFormatter->attachNumberFormatsSupplier(xNumberFormats);
try
{
- DBG_ASSERT(rParamContainer->getCount(), "OParameterDialog::OParameterDialog : can't handle empty containers !");
+ OSL_ENSURE(rParamContainer->getCount(), "OParameterDialog::OParameterDialog : can't handle empty containers !");
m_aFinalValues.realloc(rParamContainer->getCount());
PropertyValue* pValues = m_aFinalValues.getArray();
@@ -325,7 +298,7 @@ DBG_NAME(OParameterDialog)
{
sal_uInt16 nCurrent = m_aAllParams.GetSelectEntryPos();
sal_uInt16 nCount = m_aAllParams.GetEntryCount();
- DBG_ASSERT(nCount == m_aVisitedParams.size(), "OParameterDialog::OnButtonClicked : inconsistent lists !");
+ OSL_ENSURE(nCount == m_aVisitedParams.size(), "OParameterDialog::OnButtonClicked : inconsistent lists !");
// search the next entry in list we haven't visited yet
sal_uInt16 nNext = (nCurrent + 1) % nCount;
@@ -370,13 +343,13 @@ DBG_NAME(OParameterDialog)
// initialize the controls with the new values
sal_uInt16 nSelected = m_aAllParams.GetSelectEntryPos();
- DBG_ASSERT(nSelected != LISTBOX_ENTRY_NOTFOUND, "OParameterDialog::OnEntrySelected : no current entry !");
+ OSL_ENSURE(nSelected != LISTBOX_ENTRY_NOTFOUND, "OParameterDialog::OnEntrySelected : no current entry !");
m_aParam.SetText(::comphelper::getString(m_aFinalValues[nSelected].Value));
m_nCurrentlySelected = nSelected;
// with this the value isn't dirty
- DBG_ASSERT(m_nCurrentlySelected < m_aVisitedParams.size(), "OParameterDialog::OnEntrySelected : invalid current entry !");
+ OSL_ENSURE(m_nCurrentlySelected < m_aVisitedParams.size(), "OParameterDialog::OnEntrySelected : invalid current entry !");
m_aVisitedParams[m_nCurrentlySelected] &= ~EF_DIRTY;
m_aResetVisitFlag.SetTimeout(1000);
@@ -388,10 +361,10 @@ DBG_NAME(OParameterDialog)
//------------------------------------------------------------------------------
IMPL_LINK(OParameterDialog, OnVisitedTimeout, Timer*, /*pTimer*/)
{
- DBG_ASSERT(m_nCurrentlySelected != LISTBOX_ENTRY_NOTFOUND, "OParameterDialog::OnVisitedTimeout : invalid call !");
+ OSL_ENSURE(m_nCurrentlySelected != LISTBOX_ENTRY_NOTFOUND, "OParameterDialog::OnVisitedTimeout : invalid call !");
// mark the currently selected entry as visited
- DBG_ASSERT(m_nCurrentlySelected < m_aVisitedParams.size(), "OParameterDialog::OnVisitedTimeout : invalid entry !");
+ OSL_ENSURE(m_nCurrentlySelected < m_aVisitedParams.size(), "OParameterDialog::OnVisitedTimeout : invalid entry !");
m_aVisitedParams[m_nCurrentlySelected] |= EF_VISITED;
// was it the last "not visited yet" entry ?
@@ -438,7 +411,7 @@ DBG_NAME(OParameterDialog)
IMPL_LINK(OParameterDialog, OnValueModified, Control*, /*pBox*/)
{
// mark the currently selected entry as dirty
- DBG_ASSERT(m_nCurrentlySelected < m_aVisitedParams.size(), "OParameterDialog::OnValueModified : invalid entry !");
+ OSL_ENSURE(m_nCurrentlySelected < m_aVisitedParams.size(), "OParameterDialog::OnValueModified : invalid entry !");
m_aVisitedParams[m_nCurrentlySelected] |= EF_DIRTY;
m_bNeedErrorOnCurrent = sal_True;
@@ -450,3 +423,5 @@ DBG_NAME(OParameterDialog)
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/paramdialog.src b/dbaccess/source/ui/dlg/paramdialog.src
index f654f5627808..1f78123c6096 100644
--- a/dbaccess/source/ui/dlg/paramdialog.src
+++ b/dbaccess/source/ui/dlg/paramdialog.src
@@ -44,7 +44,6 @@ ModalDialog DLG_PARAMETERS
Moveable = TRUE ;
Closeable = TRUE ;
-
FixedLine FL_PARAMS
{
Pos = MAP_APPFONT ( 4 , 3 ) ;
@@ -101,4 +100,3 @@ ModalDialog DLG_PARAMETERS
Text [ en-US ] = "The entry could not be converted to a valid value for the \"$name$\"column";
};
};
-
diff --git a/dbaccess/source/ui/dlg/queryfilter.cxx b/dbaccess/source/ui/dlg/queryfilter.cxx
index 0591ec668aef..6432334b79e4 100644
--- a/dbaccess/source/ui/dlg/queryfilter.cxx
+++ b/dbaccess/source/ui/dlg/queryfilter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,75 +29,28 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYFILTER_HXX
#include "queryfilter.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_DATE_HPP_
#include <com/sun/star/util/Date.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_DATETIME_HPP_
#include <com/sun/star/util/DateTime.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_TIME_HPP_
#include <com/sun/star/util/Time.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSQLQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSQLQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNSEARCH_HPP_
#include <com/sun/star/sdbc/ColumnSearch.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLFILTEROPERATOR_HPP_
#include <com/sun/star/sdb/SQLFilterOperator.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSET_HPP_
#include <com/sun/star/sdbc/XResultSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
-#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
+#include <osl/diagnose.h>
#include "moduledbu.hxx"
-#endif
-#ifndef _CONNECTIVITY_PARSE_SQLITERATOR_HXX_
#include <connectivity/sqliterator.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef DBAUI_QUERYFILTER_HRC
#include "queryfilter.hrc"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLFILTEROPERATOR_HPP_
#include <com/sun/star/sdb/SQLFilterOperator.hpp>
-#endif
using namespace dbaui;
using namespace connectivity;
@@ -235,7 +189,7 @@ DlgFilterCrit::DlgFilterCrit(Window * pParent,
fillLines(aValues);
}
- catch(Exception&)
+ catch(const Exception&)
{
FreeResource();
throw;
@@ -314,7 +268,7 @@ sal_Int32 DlgFilterCrit::GetOSQLPredicateType( const String& _rSelectedPredicate
nPredicateType = SQLFilterOperator::NOT_SQLNULL;
break;
default:
- OSL_ENSURE( false, "DlgFilterCrit::GetOSQLPredicateType: unknown predicate string!" );
+ OSL_FAIL( "DlgFilterCrit::GetOSQLPredicateType: unknown predicate string!" );
break;
}
@@ -408,10 +362,10 @@ sal_Bool DlgFilterCrit::getCondition(const ListBox& _rField,const ListBox& _rCom
sTableName += _rFilter.Name;
_rFilter.Name = sTableName;
}
- } // if ( !bFunction )
+ }
}
}
- catch(Exception)
+ catch(const Exception&)
{
}
@@ -500,7 +454,7 @@ Reference< XPropertySet > DlgFilterCrit::getMatchingColumn( const Edit& _rValueI
sField = aLB_WHEREFIELD3.GetSelectEntry();
}
else {
- DBG_ERROR( "DlgFilterCrit::getMatchingColumn: invalid event source!" );
+ OSL_FAIL( "DlgFilterCrit::getMatchingColumn: invalid event source!" );
}
// the field itself
@@ -510,7 +464,7 @@ Reference< XPropertySet > DlgFilterCrit::getMatchingColumn( const Edit& _rValueI
//------------------------------------------------------------------------------
IMPL_LINK( DlgFilterCrit, PredicateLoseFocus, Edit*, _pField )
{
- DBG_ASSERT( _pField, "DlgFilterCrit::PredicateLoseFocus: invalid event source!" );
+ OSL_ENSURE( _pField, "DlgFilterCrit::PredicateLoseFocus: invalid event source!" );
if ( _pField )
{
// retrieve the field affected
@@ -631,11 +585,9 @@ void DlgFilterCrit::SelectField( ListBox& rBox, const String& rField )
{
DBG_CHKTHIS(DlgFilterCrit,NULL);
sal_uInt16 nCnt = rBox.GetEntryCount();
- // sal_Bool bCase = m_rIterator.TablesAreSensitive();
for( sal_uInt16 i=0 ; i<nCnt ; i++ )
{
- // if(bCase ? rBox.GetEntry(i) == rField : rBox.GetEntry(i).EqualsIgnoreCaseAscii(rField))
if(rBox.GetEntry(i) == rField)
{
rBox.SelectEntryPos(i);
@@ -801,7 +753,7 @@ IMPL_LINK( DlgFilterCrit, ListSelectHdl, ListBox *, pListBox )
}
else
{
- DBG_ASSERT(0,"DlgFilterCrit::ListSelectHdl: Diese Column d�rfte garnicht vorhanden sein!");
+ OSL_FAIL("DlgFilterCrit::ListSelectHdl: Diese Column d�rfte garnicht vorhanden sein!");
}
}
pComp->SelectEntryPos(0);
@@ -826,7 +778,6 @@ void DlgFilterCrit::BuildWherePart()
Sequence<Sequence<PropertyValue> > aFilter,aHaving;
aFilter.realloc(1);
aHaving.realloc(1);
- // ::rtl::OUString aFilter;
if( LbPos(aLB_WHEREFIELD1) != 0 )
{
@@ -895,7 +846,7 @@ void DlgFilterCrit::BuildWherePart()
m_xQueryComposer->setStructuredFilter(aFilter);
m_xQueryComposer->setStructuredHavingClause(aHaving);
}
- catch(Exception)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -919,3 +870,4 @@ void DlgFilterCrit::fillLines(const Sequence<Sequence<PropertyValue > >& _aValue
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/queryfilter.src b/dbaccess/source/ui/dlg/queryfilter.src
index a92110a6eefd..6d273b5c53aa 100644
--- a/dbaccess/source/ui/dlg/queryfilter.src
+++ b/dbaccess/source/ui/dlg/queryfilter.src
@@ -30,15 +30,6 @@
#endif
#include "dbaccess_helpid.hrc"
-/*
-#define STRLST_AND_OR \
- StringList [ en-US ] = \
- {\
- < "AND" ; Default ; > ; \
- < "OR" ; Default ; > ; \
- };\
-*/
-
ModalDialog DLG_FILTERCRIT
{
OutputSize = TRUE ;
@@ -88,7 +79,6 @@ ModalDialog DLG_FILTERCRIT
TabStop = TRUE ;
DropDown = TRUE ;
CurPos = 0 ;
-// STRLST_AND_OR
StringList [ en-US ] =
{
< "AND" ; Default ; > ;
@@ -132,7 +122,6 @@ ModalDialog DLG_FILTERCRIT
TabStop = TRUE ;
DropDown = TRUE ;
CurPos = 0 ;
-// STRLST_AND_OR
StringList [ en-US ] =
{
< "AND" ; Default ; > ;
@@ -192,7 +181,6 @@ ModalDialog DLG_FILTERCRIT
{
Pos = MAP_APPFONT ( 15 , 14 ) ;
Size = MAP_APPFONT ( 40 , 8 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Verknüpfung : Verkn³pfung */
Center = TRUE ;
Text [ en-US ] = "Operator" ;
};
@@ -230,4 +218,3 @@ ModalDialog DLG_FILTERCRIT
Text [ en-US ] = "=;<>;<;<=;>;>=;like;not like;null;not null";
};
};
-
diff --git a/dbaccess/source/ui/dlg/queryorder.cxx b/dbaccess/source/ui/dlg/queryorder.cxx
index ff4d2738ebf1..98c388ec16a6 100644
--- a/dbaccess/source/ui/dlg/queryorder.cxx
+++ b/dbaccess/source/ui/dlg/queryorder.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,48 +28,22 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYORDER_HRC
#include "queryorder.hrc"
-#endif
-#ifndef DBAUI_QUERYORDER_HXX
#include "queryorder.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNSEARCH_HPP_
#include <com/sun/star/sdbc/ColumnSearch.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _CONNECTIVITY_PARSE_SQLITERATOR_HXX_
#include <connectivity/sqliterator.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
#include <algorithm>
@@ -272,8 +247,8 @@ void DlgOrderCrit::EnableLines()
DBG_CHKTHIS(DlgOrderCrit,NULL);
Reference<XDatabaseMetaData> xMetaData = m_xConnection->getMetaData();
::rtl::OUString sQuote = xMetaData.is() ? xMetaData->getIdentifierQuoteString() : ::rtl::OUString();
- static const ::rtl::OUString sDESC = ::rtl::OUString::createFromAscii(" DESC ");
- static const ::rtl::OUString sASC = ::rtl::OUString::createFromAscii(" ASC ");
+ static const ::rtl::OUString sDESC(RTL_CONSTASCII_USTRINGPARAM(" DESC "));
+ static const ::rtl::OUString sASC(RTL_CONSTASCII_USTRINGPARAM(" ASC "));
Reference< XNameAccess> xColumns = Reference< XColumnsSupplier >(m_xQueryComposer,UNO_QUERY)->getColumns();
@@ -283,7 +258,7 @@ void DlgOrderCrit::EnableLines()
if(m_aColumnList[i]->GetSelectEntryPos() != 0)
{
if(sOrder.getLength())
- sOrder += ::rtl::OUString::createFromAscii(",");
+ sOrder += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(","));
String sName = m_aColumnList[i]->GetSelectEntry();
try
@@ -308,7 +283,7 @@ void DlgOrderCrit::EnableLines()
else
sOrder += ::dbtools::quoteName(sQuote,sName);
}
- catch(Exception)
+ catch(const Exception&)
{
}
if(m_aValueList[i]->GetSelectEntryPos())
@@ -332,3 +307,4 @@ void DlgOrderCrit::BuildOrderPart()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/queryorder.src b/dbaccess/source/ui/dlg/queryorder.src
index a0806f41988c..7c349dda037b 100644
--- a/dbaccess/source/ui/dlg/queryorder.src
+++ b/dbaccess/source/ui/dlg/queryorder.src
@@ -139,7 +139,6 @@ ModalDialog DLG_ORDERCRIT
{
Pos = MAP_APPFONT ( 12 , 14 ) ;
Size = MAP_APPFONT ( 46 , 8 ) ;
- /* ### ACHTUNG: Neuer Text in Resource? Verknüpfung : Verkn³pfung */
Text [ en-US ] = "Operator" ;
};
FixedText FT_ORDERDIR
@@ -179,39 +178,3 @@ ModalDialog DLG_ORDERCRIT
Text [ en-US ] = "<none>" ;
};
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/dlg/sqlmessage.cxx b/dbaccess/source/ui/dlg/sqlmessage.cxx
index 0aa02675bdf0..cfdb702d23ff 100644
--- a/dbaccess/source/ui/dlg/sqlmessage.cxx
+++ b/dbaccess/source/ui/dlg/sqlmessage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,54 +29,23 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HRC_
#include "sqlmessage.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLEXCEPTION_HPP_
#include <com/sun/star/sdbc/SQLException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _SV_GROUP_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SVTREEBOX_HXX
+#include <osl/diagnose.h>
#include <svtools/svtreebx.hxx>
-#endif
-#ifndef _SVEDIT_HXX //autogen
#include <svtools/svmedit.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef CONNECTIVITY_SQLERROR_HXX
#include <connectivity/sqlerror.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX //autogen
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _UTL_CONFIGMGR_HXX_
#include <unotools/configmgr.hxx>
-#endif
-#ifndef _SFX_SFXUNO_HXX
#include <sfx2/sfxuno.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
#include <tools/urlobj.hxx>
@@ -103,7 +73,7 @@ namespace
class IImageProvider
{
public:
- virtual Image getImage( bool _highContrast ) const = 0;
+ virtual Image getImage() const = 0;
virtual ~IImageProvider() { }
};
@@ -122,27 +92,17 @@ namespace
{
private:
sal_uInt16 m_defaultImageID;
- sal_uInt16 m_highContrastImageID;
mutable Image m_defaultImage;
- mutable Image m_highContrastImage;
public:
- ImageProvider( sal_uInt16 _defaultImageID, sal_uInt16 _highContrastImageID )
+ ImageProvider( sal_uInt16 _defaultImageID )
:m_defaultImageID( _defaultImageID )
- ,m_highContrastImageID( _highContrastImageID )
{
}
- virtual Image getImage( bool _highContrast ) const
+ virtual Image getImage() const
{
- if ( _highContrast )
- {
- if ( !m_highContrastImage )
- m_highContrastImage = Image( ModuleRes( m_highContrastImageID ) );
- return m_highContrastImage;
- }
-
if ( !m_defaultImage )
m_defaultImage = Image( ModuleRes( m_defaultImageID ) );
return m_defaultImage;
@@ -186,20 +146,17 @@ namespace
{
::boost::shared_ptr< IImageProvider >* ppProvider( &m_pErrorImage );
sal_uInt16 nNormalImageID( BMP_EXCEPTION_ERROR );
- sal_uInt16 nHCImageID( BMP_EXCEPTION_ERROR_SCH );
switch ( _eType )
{
case SQLExceptionInfo::SQL_WARNING:
ppProvider = &m_pWarningsImage;
nNormalImageID = BMP_EXCEPTION_WARNING;
- nHCImageID = BMP_EXCEPTION_WARNING_SCH;
break;
case SQLExceptionInfo::SQL_CONTEXT:
ppProvider = &m_pInfoImage;
nNormalImageID = BMP_EXCEPTION_INFO;
- nHCImageID = BMP_EXCEPTION_INFO_SCH;
break;
default:
@@ -207,7 +164,7 @@ namespace
}
if ( !ppProvider->get() )
- ppProvider->reset( new ImageProvider( nNormalImageID, nHCImageID ) );
+ ppProvider->reset( new ImageProvider( nNormalImageID ) );
return *ppProvider;
}
@@ -305,7 +262,7 @@ namespace
iter.next( aCurrentElement );
const SQLException* pCurrentError = (const SQLException*)aCurrentElement;
- DBG_ASSERT( pCurrentError, "lcl_buildExceptionChain: iterator failure!" );
+ OSL_ENSURE( pCurrentError, "lcl_buildExceptionChain: iterator failure!" );
// hasMoreElements should not have returned <TRUE/> in this case
ExceptionDisplayInfo aDisplayInfo( aCurrentElement.getType() );
@@ -319,7 +276,7 @@ namespace
&& !lcl_hasDetails( aDisplayInfo )
)
{
- OSL_ENSURE( false, "lcl_buildExceptionChain: useles exception: no state, no error code, no message!" );
+ OSL_FAIL( "lcl_buildExceptionChain: useles exception: no state, no error code, no message!" );
continue;
}
@@ -347,9 +304,9 @@ namespace
}
//------------------------------------------------------------------------------
- void lcl_insertExceptionEntry( SvTreeListBox& _rList, bool _bHiContrast, size_t _nElementPos, const ExceptionDisplayInfo& _rEntry )
+ void lcl_insertExceptionEntry( SvTreeListBox& _rList, size_t _nElementPos, const ExceptionDisplayInfo& _rEntry )
{
- Image aEntryImage( _rEntry.pImageProvider->getImage( _bHiContrast ) );
+ Image aEntryImage( _rEntry.pImageProvider->getImage() );
SvLBoxEntry* pListEntry =
_rList.InsertEntry( _rEntry.pLabelProvider->getLabel(), aEntryImage, aEntryImage );
pListEntry->SetUserData( reinterpret_cast< void* >( _nElementPos ) );
@@ -408,7 +365,6 @@ OExceptionChainDialog::OExceptionChainDialog( Window* pParent, const ExceptionDi
m_aExceptionText.SetReadOnly(sal_True);
bool bHave22018 = false;
- bool bHiContrast = isHiContrast( this );
size_t elementPos = 0;
for ( ExceptionDisplayChain::const_iterator loop = m_aExceptions.begin();
@@ -416,12 +372,12 @@ OExceptionChainDialog::OExceptionChainDialog( Window* pParent, const ExceptionDi
++loop, ++elementPos
)
{
- lcl_insertExceptionEntry( m_aExceptionList, bHiContrast, elementPos, *loop );
+ lcl_insertExceptionEntry( m_aExceptionList, elementPos, *loop );
bHave22018 = loop->sSQLState.EqualsAscii( "22018" );
}
// if the error has the code 22018, then add an additional explanation
- // #i24021# / 2004-10-14 / frank.schoenheit@sun.com
+ // #i24021#
if ( bHave22018 )
{
ProviderFactory aProviderFactory;
@@ -432,7 +388,7 @@ OExceptionChainDialog::OExceptionChainDialog( Window* pParent, const ExceptionDi
aInfo22018.pImageProvider = aProviderFactory.getImageProvider( SQLExceptionInfo::SQL_CONTEXT );
m_aExceptions.push_back( aInfo22018 );
- lcl_insertExceptionEntry( m_aExceptionList, bHiContrast, m_aExceptions.size() - 1, aInfo22018 );
+ lcl_insertExceptionEntry( m_aExceptionList, m_aExceptions.size() - 1, aInfo22018 );
}
}
@@ -446,7 +402,7 @@ OExceptionChainDialog::~OExceptionChainDialog()
IMPL_LINK(OExceptionChainDialog, OnExceptionSelected, void*, EMPTYARG)
{
SvLBoxEntry* pSelected = m_aExceptionList.FirstSelected();
- DBG_ASSERT(!pSelected || !m_aExceptionList.NextSelected(pSelected), "OExceptionChainDialog::OnExceptionSelected : multi selection ?");
+ OSL_ENSURE(!pSelected || !m_aExceptionList.NextSelected(pSelected), "OExceptionChainDialog::OnExceptionSelected : multi selection ?");
String sText;
@@ -526,7 +482,7 @@ namespace
case BUTTON_RETRY: nButtonID = BUTTONID_RETRY; break;
case BUTTON_HELP: nButtonID = BUTTONID_HELP; break;
default:
- OSL_ENSURE( false, "lcl_addButton: invalid button id!" );
+ OSL_FAIL( "lcl_addButton: invalid button id!" );
break;
}
_rDialog.AddButton( _eType, nButtonID, _bDefault ? BUTTONDIALOG_DEFBUTTON | BUTTONDIALOG_FOCUSBUTTON : 0 );
@@ -640,7 +596,7 @@ void OSQLMessageBox::impl_initImage( MessageType _eImage )
switch (_eImage)
{
default:
- DBG_ERROR( "OSQLMessageBox::impl_initImage: unsupported image type!" );
+ OSL_FAIL( "OSQLMessageBox::impl_initImage: unsupported image type!" );
case Info:
m_aInfoImage.SetImage(InfoBox::GetStandardImage());
@@ -754,7 +710,7 @@ void OSQLMessageBox::Construct( WinBits _nStyle, MessageType _eImage )
case SQLExceptionInfo::SQL_EXCEPTION: eType = Error; break;
case SQLExceptionInfo::SQL_WARNING: eType = Warning; break;
case SQLExceptionInfo::SQL_CONTEXT: eType = Info; break;
- default: OSL_ENSURE( false, "OSQLMessageBox::Construct: invalid type!" );
+ default: OSL_FAIL( "OSQLMessageBox::Construct: invalid type!" );
}
}
impl_initImage( eType );
@@ -820,3 +776,4 @@ OSQLWarningBox::OSQLWarningBox( Window* _pParent, const UniString& _rMessage, Wi
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/sqlmessage.src b/dbaccess/source/ui/dlg/sqlmessage.src
index f409477267f9..94b2e394d527 100644
--- a/dbaccess/source/ui/dlg/sqlmessage.src
+++ b/dbaccess/source/ui/dlg/sqlmessage.src
@@ -38,36 +38,19 @@
//-------------------------------------------------------------------------
Image BMP_EXCEPTION_ERROR
{
- ImageBitmap = Bitmap { File = "exerror.bmp"; };
+ ImageBitmap = Bitmap { File = "exerror.png"; };
MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
};
Image BMP_EXCEPTION_WARNING
{
- ImageBitmap = Bitmap { File = "exwarning.bmp"; };
+ ImageBitmap = Bitmap { File = "exwarning.png"; };
MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
};
Image BMP_EXCEPTION_INFO
{
- ImageBitmap = Bitmap { File = "exinfo.bmp"; };
- MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
-};
-Image BMP_EXCEPTION_ERROR_SCH
-{
- ImageBitmap = Bitmap { File = "exerror_sch.bmp"; };
- MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
-};
-
-Image BMP_EXCEPTION_WARNING_SCH
-{
- ImageBitmap = Bitmap { File = "exwarning_sch.bmp"; };
- MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
-};
-
-Image BMP_EXCEPTION_INFO_SCH
-{
- ImageBitmap = Bitmap { File = "exinfo_sch.bmp"; };
+ ImageBitmap = Bitmap { File = "exinfo.png"; };
MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
};
diff --git a/dbaccess/source/ui/dlg/tablespage.cxx b/dbaccess/source/ui/dlg/tablespage.cxx
index e083371afc22..8d0f261cbafc 100644
--- a/dbaccess/source/ui/dlg/tablespage.cxx
+++ b/dbaccess/source/ui/dlg/tablespage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,96 +29,37 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_TABLESPAGE_HXX_
#include "tablespage.hxx"
-#endif
-#ifndef _DBU_DLG_HRC_
#include "dbu_dlg.hrc"
-#endif
-#ifndef _DBAUI_DBADMIN_HRC_
#include "dbadmin.hrc"
-#endif
-#ifndef _DBAUI_DATASOURCEITEMS_HXX_
#include "dsitems.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _DBAUI_DATASOURCECONNECTOR_HXX_
#include "datasourceconnector.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _DBAUI_STRINGLISTITEM_HXX_
#include "stringlistitem.hxx"
-#endif
-#ifndef _SFXENUMITEM_HXX
#include <svl/eitem.hxx>
-#endif
-#ifndef _SFXSTRITEM_HXX
#include <svl/stritem.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XMODIFIABLE_HPP_
#include <com/sun/star/util/XModifiable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDROP_HPP_
#include <com/sun/star/sdbcx/XDrop.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADEFINITIONSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XDataDefinitionSupplier.hpp>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
-#ifndef _SVTOOLS_IMGDEF_HXX
+#include <osl/mutex.hxx>
+#include <osl/diagnose.h>
#include <svtools/imgdef.hxx>
-#endif
-#ifndef _DBAUI_TABLESSINGLEDLG_HXX_
#include "TablesSingleDlg.hxx"
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
#include "AutoControlsDef.hrc"
//.........................................................................
@@ -232,7 +174,7 @@ DBG_NAME(OTableSubscriptionPage)
}
catch(SQLException&)
{
- DBG_ERROR("OTableSubscriptionPage::implCheckTables : could not retrieve the current connection's meta data!");
+ OSL_FAIL("OTableSubscriptionPage::implCheckTables : could not retrieve the current connection's meta data!");
}
// uncheck all
@@ -315,7 +257,7 @@ DBG_NAME(OTableSubscriptionPage)
// get the name of the data source we're working for
SFX_ITEMSET_GET(_rSet, pNameItem, SfxStringItem, DSID_NAME, sal_True);
- DBG_ASSERT(pNameItem, "OTableSubscriptionPage::implInitControls: missing the name attribute!");
+ OSL_ENSURE(pNameItem, "OTableSubscriptionPage::implInitControls: missing the name attribute!");
String sDSName = pNameItem->GetValue();
if (bValid && sDSName.Len() && !m_xCurrentConnection.is() )
@@ -323,7 +265,7 @@ DBG_NAME(OTableSubscriptionPage)
// the PropertyValues for the current dialog settings
Sequence< PropertyValue > aConnectionParams;
- DBG_ASSERT(m_pTablesDlg, "OTableSubscriptionPage::implInitControls: need a parent dialog doing the translation!");
+ OSL_ENSURE(m_pTablesDlg, "OTableSubscriptionPage::implInitControls: need a parent dialog doing the translation!");
if ( m_pTablesDlg )
{
if (!m_pTablesDlg->getCurrentSettings(aConnectionParams))
@@ -446,13 +388,9 @@ DBG_NAME(OTableSubscriptionPage)
// get the current table filter
SFX_ITEMSET_GET(_rSet, pTableFilter, OStringListItem, DSID_TABLEFILTER, sal_True);
- SFX_ITEMSET_GET(_rSet, pSuppress, SfxBoolItem, DSID_SUPPRESSVERSIONCL, sal_True);
Sequence< ::rtl::OUString > aTableFilter;
- sal_Bool bSuppressVersionColumns = sal_True;
if (pTableFilter)
aTableFilter = pTableFilter->getList();
- if (pSuppress)
- bSuppressVersionColumns = pSuppress->GetValue();
implCompleteTablesCheck( aTableFilter );
@@ -509,11 +447,11 @@ DBG_NAME(OTableSubscriptionPage)
{
SvLBoxEntry* pLHS = static_cast<SvLBoxEntry*>(_pSortData->pLeft);
SvLBoxEntry* pRHS = static_cast<SvLBoxEntry*>(_pSortData->pRight);
- DBG_ASSERT(pLHS && pRHS, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid tree entries!");
+ 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));
- DBG_ASSERT(pLeftTextItem && pRightTextItem, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid text items!");
+ OSL_ENSURE(pLeftTextItem && pRightTextItem, "SbaTableQueryBrowser::OnTreeEntryCompare: invalid text items!");
String sLeftText = pLeftTextItem->GetText();
String sRightText = pRightTextItem->GetText();
@@ -690,3 +628,4 @@ DBG_NAME(OTableSubscriptionPage)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/tablespage.hxx b/dbaccess/source/ui/dlg/tablespage.hxx
index 0591eb396ae3..81566ed7faf5 100644
--- a/dbaccess/source/ui/dlg/tablespage.hxx
+++ b/dbaccess/source/ui/dlg/tablespage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,27 +29,13 @@
#ifndef _DBAUI_TABLESPAGE_HXX_
#define _DBAUI_TABLESPAGE_HXX_
-#ifndef _DBAUI_ADMINPAGES_HXX_
#include "adminpages.hxx"
-#endif
-#ifndef _COM_SUN_STAR_I18N_XCOLLATOR_HPP_
#include <com/sun/star/i18n/XCollator.hpp>
-#endif
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _DBAUI_TABLETREE_HXX_
#include "tabletree.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
//.........................................................................
@@ -133,3 +120,4 @@ namespace dbaui
#endif // _DBAUI_TABLESPAGE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/dlg/textconnectionsettings.cxx b/dbaccess/source/ui/dlg/textconnectionsettings.cxx
index d2a39627461b..44471469d401 100644
--- a/dbaccess/source/ui/dlg/textconnectionsettings.cxx
+++ b/dbaccess/source/ui/dlg/textconnectionsettings.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -104,3 +105,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/imagelists/dbimagelists.src b/dbaccess/source/ui/imagelists/dbimagelists.src
index 2e2a64d87448..8f993554f7c7 100644
--- a/dbaccess/source/ui/imagelists/dbimagelists.src
+++ b/dbaccess/source/ui/imagelists/dbimagelists.src
@@ -56,13 +56,6 @@ ImageList IMG_INDEX_DLG_SC
IL_TOOL_2 ;
};
-ImageList IMG_INDEX_DLG_SCH
-{
- MASKCOLOR;
- prefix = "sch";
- IL_TOOL_2 ;
-};
-
ImageList IMG_INDEX_DLG_LC
{
MASKCOLOR;
@@ -70,53 +63,29 @@ ImageList IMG_INDEX_DLG_LC
IL_TOOL_2 ;
};
-ImageList IMG_INDEX_DLG_LCH
-{
- MASKCOLOR;
- prefix = "lch";
- IL_TOOL_2 ;
-};
-
Image IMG_FORMFOLDER_TREE_L
{
ImageBitmap = Bitmap { File = "forms_32"; };
MASKCOLOR;
};
-Image IMG_FORMFOLDER_TREE_LHC
-{
- ImageBitmap = Bitmap { File = "forms_32_h"; };
- MASKCOLOR;
-};
+
Image IMG_REPORTFOLDER_TREE_L
{
ImageBitmap = Bitmap { File = "reports_32"; };
MASKCOLOR;
};
-Image IMG_REPORTFOLDER_TREE_LHC
-{
- ImageBitmap = Bitmap { File = "reports_32_h"; };
- MASKCOLOR;
-};
+
Image IMG_QUERYFOLDER_TREE_L
{
ImageBitmap = Bitmap { File = "queries_32"; };
MASKCOLOR;
};
-Image IMG_QUERYFOLDER_TREE_LHC
-{
- ImageBitmap = Bitmap { File = "queries_32_h"; };
- MASKCOLOR;
-};
+
Image IMG_TABLEFOLDER_TREE_L
{
ImageBitmap = Bitmap { File = "tables_32"; };
MASKCOLOR;
};
-Image IMG_TABLEFOLDER_TREE_LHC
-{
- ImageBitmap = Bitmap { File = "tables_32_h"; };
- MASKCOLOR;
-};
//========================================================================
//= database object icons
@@ -126,13 +95,7 @@ Image IMG_TABLEFOLDER_TREE_LHC
Image DATABASE_TREE_ICON
{
- ImageBitmap = Bitmap { File = "db.bmp"; };
- MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
-};
-
-Image DATABASE_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "db_sch.bmp"; };
+ ImageBitmap = Bitmap { File = "db.png"; };
MaskColor = Color { Red = 0xff00 ; Green = 0x0000 ; Blue = 0xff00 ; };
};
@@ -145,24 +108,12 @@ Image TABLE_TREE_ICON
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
-Image TABLE_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "sxh03188.png"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
-
Image TABLEFOLDER_TREE_ICON
{
ImageBitmap = Bitmap { File = "sx03187.png"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
-Image TABLEFOLDER_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "sxh03187.png"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
-
//------------------------------------------------------------------------
// views
@@ -172,36 +123,18 @@ Image VIEW_TREE_ICON
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
-Image VIEW_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "sxh16670.png"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
-
//------------------------------------------------------------------------
// queries and query folders
Image QUERY_TREE_ICON
{
- ImageBitmap = Bitmap { File = "sx03202.bmp"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
-
-Image QUERY_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "sxh03202.bmp"; };
+ ImageBitmap = Bitmap { File = "sx03202.png"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
Image QUERYFOLDER_TREE_ICON
{
- ImageBitmap = Bitmap { File = "sx03201.bmp"; };
- MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
-};
-
-Image QUERYFOLDER_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "sxh03201.bmp"; };
+ ImageBitmap = Bitmap { File = "sx03201.png"; };
MaskColor = Color { Red = 0xFFFF; Green = 0x0; Blue = 0xFFFF; };
};
@@ -214,24 +147,12 @@ Image FORM_TREE_ICON
MASKCOLOR;
};
-Image FORM_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "form_16_h"; };
- MASKCOLOR;
-};
-
Image FORMFOLDER_TREE_ICON
{
ImageBitmap = Bitmap { File = "forms_16"; };
MASKCOLOR;
};
-Image FORMFOLDER_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "forms_16_h"; };
- MASKCOLOR;
-};
-
//------------------------------------------------------------------------
// reports and report folders
@@ -241,22 +162,8 @@ Image REPORT_TREE_ICON
MASKCOLOR;
};
-Image REPORT_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "report_16_h"; };
- MASKCOLOR;
-};
Image REPORTFOLDER_TREE_ICON
{
ImageBitmap = Bitmap { File = "reports_16"; };
MASKCOLOR;
};
-
-Image REPORTFOLDER_TREE_ICON_SCH
-{
- ImageBitmap = Bitmap { File = "reports_16_h"; };
- MASKCOLOR;
-};
-
-//========================================================================
-
diff --git a/dbaccess/source/ui/imagelists/makefile.mk b/dbaccess/source/ui/imagelists/makefile.mk
deleted file mode 100644
index 3620f6329889..000000000000
--- a/dbaccess/source/ui/imagelists/makefile.mk
+++ /dev/null
@@ -1,49 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJNAME=dbaccess
-TARGET=uiimglst
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-IMGLST_SRS=$(SRS)$/$(TARGET).srs
-# --- Files -------------------------------------
-
-# ... resource files ............................
-
-SRS1NAME=$(TARGET)
-SRC1FILES=dbimagelists.src
-
-# ... object files ............................
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
-
diff --git a/dbaccess/source/ui/inc/AccessibleBaseIFace.hxx b/dbaccess/source/ui/inc/AccessibleBaseIFace.hxx
index eb2bb5dcd031..adcd7bf75c4b 100644
--- a/dbaccess/source/ui/inc/AccessibleBaseIFace.hxx
+++ b/dbaccess/source/ui/inc/AccessibleBaseIFace.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_ACCESSIBLE_HELPER_IFACE_HXX
#define DBAUI_ACCESSIBLE_HELPER_IFACE_HXX
-#ifndef _SAL_TYPES_H_
#include <sal/types.h>
-#endif
namespace dbaui
{
@@ -52,3 +51,5 @@ namespace dbaui
};
}
#endif // DBAUI_ACCESSIBLE_HELPER_IFACE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/AppElementType.hxx b/dbaccess/source/ui/inc/AppElementType.hxx
index d615fa034692..006f5ced1c73 100644
--- a/dbaccess/source/ui/inc/AppElementType.hxx
+++ b/dbaccess/source/ui/inc/AppElementType.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -64,3 +65,4 @@ namespace dbaui
//........................................................................
#endif // DBAUI_APPELEMENTTYPE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/CollectionView.hxx b/dbaccess/source/ui/inc/CollectionView.hxx
index 1790f5dc1f4a..395ad71f3e0c 100644
--- a/dbaccess/source/ui/inc/CollectionView.hxx
+++ b/dbaccess/source/ui/inc/CollectionView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
#ifndef DBAUI_COLLECTIONVIEW_HXX
#define DBAUI_COLLECTIONVIEW_HXX
-#ifndef _SVT_FILEVIEW_HXX
#include <svtools/fileview.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_
#include <com/sun/star/ucb/XContent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
//.........................................................................
namespace dbaui
@@ -98,3 +87,4 @@ namespace dbaui
#endif //DBAUI_COLLECTIONVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/ColumnControlWindow.hxx b/dbaccess/source/ui/inc/ColumnControlWindow.hxx
index fa414c3d67ec..5cd8d93a337a 100644
--- a/dbaccess/source/ui/inc/ColumnControlWindow.hxx
+++ b/dbaccess/source/ui/inc/ColumnControlWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
#ifndef DBAUI_COLUMNCONTROLWINDOW_HXX
#define DBAUI_COLUMNCONTROLWINDOW_HXX
-#ifndef DBAUI_FIELDDESCRIPTIONCONTROL_HXX
#include "FieldDescControl.hxx"
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
//.........................................................................
namespace dbaui
@@ -88,3 +81,5 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
#endif // DBAUI_COLUMNCONTROLWINDOW_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/ConnectionLine.hxx b/dbaccess/source/ui/inc/ConnectionLine.hxx
index f845cd5cbddd..9dfce6c0dfff 100644
--- a/dbaccess/source/ui/inc/ConnectionLine.hxx
+++ b/dbaccess/source/ui/inc/ConnectionLine.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_CONNECTIONLINE_HXX
#define DBAUI_CONNECTIONLINE_HXX
-#ifndef _SV_GEN_HXX
#include <tools/gen.hxx>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
#include <functional>
class OutputDevice;
@@ -69,7 +64,7 @@ namespace dbaui
OConnectionLine( const OConnectionLine& rLine );
virtual ~OConnectionLine();
- virtual OConnectionLine& operator=( const OConnectionLine& rLine );
+ OConnectionLine& operator=( const OConnectionLine& rLine );
Rectangle GetBoundingRect();
sal_Bool RecalcLine();
@@ -113,3 +108,5 @@ namespace dbaui
}
#endif // DBAUI_CONNECTIONLINE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/ConnectionLineAccess.hxx b/dbaccess/source/ui/inc/ConnectionLineAccess.hxx
index 14fdbfa6d325..d36af945165f 100644
--- a/dbaccess/source/ui/inc/ConnectionLineAccess.hxx
+++ b/dbaccess/source/ui/inc/ConnectionLineAccess.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBACCESS_CONNECTIONLINEACCESS_HXX
#define DBACCESS_CONNECTIONLINEACCESS_HXX
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_XACCESSIBLERELATIONSET_HPP_
#include <com/sun/star/accessibility/XAccessibleRelationSet.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE2_HXX_
#include <cppuhelper/implbase2.hxx>
-#endif
-#ifndef _TOOLKIT_AWT_VCLXACCESSIBLECOMPONENT_HXX_
#include <toolkit/awt/vclxaccessiblecomponent.hxx>
-#endif
namespace dbaui
{
@@ -111,3 +106,5 @@ namespace dbaui
};
}
#endif // DBACCESS_CONNECTIONLINEACCESS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/ConnectionLineData.hxx b/dbaccess/source/ui/inc/ConnectionLineData.hxx
index 0a8d145bd92b..50898937894c 100644
--- a/dbaccess/source/ui/inc/ConnectionLineData.hxx
+++ b/dbaccess/source/ui/inc/ConnectionLineData.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,13 @@
#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#define DBAUI_CONNECTIONLINEDATA_HXX
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _VOS_REFERNCE_HXX_
-#include <vos/refernce.hxx>
-#endif
#include <vector>
-#ifndef _VOS_REF_HXX_
-#include <vos/ref.hxx>
-#endif
-
-#ifndef DBAUI_REFFUNCTOR_HXX
+#include <rtl/ref.hxx>
+#include <salhelper/simplereferenceobject.hxx>
#include "RefFunctor.hxx"
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
namespace dbaui
{
@@ -62,7 +52,7 @@ namespace dbaui
the class OConnectionLineData contains the data of a connection
e.g. the source and the destanation field
**/
- class OConnectionLineData : public ::vos::OReference
+ class OConnectionLineData : public ::salhelper::SimpleReferenceObject
{
::rtl::OUString m_aSourceFieldName;
::rtl::OUString m_aDestFieldName;
@@ -104,8 +94,9 @@ namespace dbaui
//-------------------------------------------------------------------------
//------------------------------------------------------------------
- typedef ::vos::ORef< OConnectionLineData > OConnectionLineDataRef;
+ typedef ::rtl::Reference< OConnectionLineData > OConnectionLineDataRef;
typedef ::std::vector< OConnectionLineDataRef > OConnectionLineDataVec;
}
#endif // DBAUI_CONNECTIONLINEDATA_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/DExport.hxx b/dbaccess/source/ui/inc/DExport.hxx
index de320d363173..d186b457e4a0 100644
--- a/dbaccess/source/ui/inc/DExport.hxx
+++ b/dbaccess/source/ui/inc/DExport.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -93,10 +94,9 @@ namespace dbaui
SvNumberFormatter* m_pFormatter;
SvStream& m_rInputStream;
- //dyf add 2006/06/01
//for save the selected tablename
::rtl::OUString m_sDefaultTableName;
- //dyf add end
+
String m_sTextToken; // Zellen Inhalt
String m_sNumToken; /// SDNUM value
String m_sValToken; /// SDVAL value
@@ -166,9 +166,7 @@ namespace dbaui
void SetColumnTypes(const TColumnVector* rList,const OTypeInfoMap* _pInfoMap);
- //dyf add 20070601
inline void SetTableName(const ::rtl::OUString &_sTableName){ m_sDefaultTableName = _sTableName ; }
- //dyf add end
virtual void release() = 0;
@@ -187,3 +185,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/FieldControls.hxx b/dbaccess/source/ui/inc/FieldControls.hxx
index 6174d0efca23..661f66a96bda 100644
--- a/dbaccess/source/ui/inc/FieldControls.hxx
+++ b/dbaccess/source/ui/inc/FieldControls.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
#ifndef DBAUI_FIELDCONTROLS_HXX
#define DBAUI_FIELDCONTROLS_HXX
-#ifndef _SV_FIELD_HXX
#include <vcl/field.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef DBAUI_SQLNAMEEDIT_HXX
#include "SqlNameEdit.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
namespace dbaui
@@ -197,3 +188,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/FieldDescControl.hxx b/dbaccess/source/ui/inc/FieldDescControl.hxx
index 4f5f3036448c..cd038229deab 100644
--- a/dbaccess/source/ui/inc/FieldDescControl.hxx
+++ b/dbaccess/source/ui/inc/FieldDescControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
#ifndef DBAUI_FIELDDESCRIPTIONCONTROL_HXX
#define DBAUI_FIELDDESCRIPTIONCONTROL_HXX
-#ifndef _SV_TABPAGE_HXX
#include <vcl/tabpage.hxx>
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
//------------------------------------------------------------------
// die Spalten einer Feld-Beschreibung einer Tabelle
@@ -240,3 +231,4 @@ namespace dbaui
#endif // DBAUI_FIELDDESCRIPTIONCONTROL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/FieldDescriptions.hxx b/dbaccess/source/ui/inc/FieldDescriptions.hxx
index ef98ef61492b..980b23050f3e 100644
--- a/dbaccess/source/ui/inc/FieldDescriptions.hxx
+++ b/dbaccess/source/ui/inc/FieldDescriptions.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#define DBAUI_FIELDDESCRIPTIONS_HXX
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _SVX_SVXENUM_HXX
#include <editeng/svxenum.hxx>
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP_
#include <com/sun/star/beans/XPropertySetInfo.hpp>
-#endif
namespace dbaui
{
@@ -133,3 +122,4 @@ namespace dbaui
#endif // DBAUI_FIELDDESCRIPTIONS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/GeneralUndo.hxx b/dbaccess/source/ui/inc/GeneralUndo.hxx
index aaea53232644..de99bd3706f3 100644
--- a/dbaccess/source/ui/inc/GeneralUndo.hxx
+++ b/dbaccess/source/ui/inc/GeneralUndo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_GENERALUNDO_HXX
#define DBAUI_GENERALUNDO_HXX
-#ifndef _UNDO_HXX
#include <svl/undo.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
namespace dbaui
{
@@ -57,3 +54,4 @@ namespace dbaui
#endif // DBAUI_GENERALUNDO_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/HtmlReader.hxx b/dbaccess/source/ui/inc/HtmlReader.hxx
index 18af2d2d9e4f..59c5bfc7f2b5 100644
--- a/dbaccess/source/ui/inc/HtmlReader.hxx
+++ b/dbaccess/source/ui/inc/HtmlReader.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
#ifndef DBAUI_HTMLREADER_HXX
#define DBAUI_HTMLREADER_HXX
-#ifndef DBAUI_DATABASEEXPORT_HXX
#include "DExport.hxx"
-#endif
-#ifndef _PARHTML_HXX //autogen
#include <svtools/parhtml.hxx>
-#endif
-#ifndef _SVX_SVXENUM_HXX
#include <editeng/svxenum.hxx>
-#endif
-#ifndef _STREAM_HXX
#include <tools/stream.hxx>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTDESCRIPTOR_HPP_
#include <com/sun/star/awt/FontDescriptor.hpp>
-#endif
namespace dbaui
@@ -64,7 +55,7 @@ namespace dbaui
virtual TypeSelectionPageFactory
getTypeSelectionPageFactory();
- void TableDataOn(SvxCellHorJustify& eVal,int nToken);
+ void TableDataOn(SvxCellHorJustify& eVal);
void TableFontOn(::com::sun::star::awt::FontDescriptor& _rFont,sal_Int32 &_rTextColor);
sal_Int16 GetWidthPixel( const HTMLOption* pOption );
void setTextEncoding();
@@ -98,3 +89,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/IClipBoardTest.hxx b/dbaccess/source/ui/inc/IClipBoardTest.hxx
index e41112fc95fe..2f64d667379d 100644
--- a/dbaccess/source/ui/inc/IClipBoardTest.hxx
+++ b/dbaccess/source/ui/inc/IClipBoardTest.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -26,9 +27,7 @@
************************************************************************/
#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#define DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
-#ifndef _SAL_TYPES_H_
#include <sal/types.h>
-#endif
namespace dbaui
{
@@ -47,3 +46,5 @@ namespace dbaui
};
}
#endif // DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/IItemSetHelper.hxx b/dbaccess/source/ui/inc/IItemSetHelper.hxx
index 764a6dde6c17..8d39925c33e0 100644
--- a/dbaccess/source/ui/inc/IItemSetHelper.hxx
+++ b/dbaccess/source/ui/inc/IItemSetHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
#ifndef DBAUI_ITEMSETHELPER_HXX
#define DBAUI_ITEMSETHELPER_HXX
-#ifndef _SAL_TYPES_H_
#include <sal/types.h>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
FORWARD_DECLARE_INTERFACE(beans,XPropertySet)
FORWARD_DECLARE_INTERFACE(sdbc,XConnection)
@@ -74,3 +69,4 @@ namespace dbaui
}
#endif // DBAUI_ITEMSETHELPER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/IUpdateHelper.hxx b/dbaccess/source/ui/inc/IUpdateHelper.hxx
index 8a08bd1e0229..b9976efe9935 100644
--- a/dbaccess/source/ui/inc/IUpdateHelper.hxx
+++ b/dbaccess/source/ui/inc/IUpdateHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -50,3 +51,4 @@ namespace dbaui
#endif // DBAUI_IUPDATEHELPER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/JAccess.hxx b/dbaccess/source/ui/inc/JAccess.hxx
index 15ebbc9aa1ee..7ecb0dbf4aa4 100644
--- a/dbaccess/source/ui/inc/JAccess.hxx
+++ b/dbaccess/source/ui/inc/JAccess.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBACCESS_JACCESS_HXX
#define DBACCESS_JACCESS_HXX
-#ifndef _TOOLKIT_AWT_VCLXACCESSIBLECOMPONENT_HXX_
#include <toolkit/awt/vclxaccessiblecomponent.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
namespace dbaui
{
@@ -88,3 +85,5 @@ namespace dbaui
};
}
#endif // DBACCESS_JACCESS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/JoinController.hxx b/dbaccess/source/ui/inc/JoinController.hxx
index 8ff5fe99b727..cc35323db7fd 100644
--- a/dbaccess/source/ui/inc/JoinController.hxx
+++ b/dbaccess/source/ui/inc/JoinController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -147,14 +148,14 @@ namespace dbaui
/** only defines a method to save a SQLException in d&d methods to show the error at a later state
set the internal member m_aExceptionInfo to _rInfo
*/
- void setErrorOccured(const ::dbtools::SQLExceptionInfo& _rInfo)
+ void setErrorOccurred(const ::dbtools::SQLExceptionInfo& _rInfo)
{
m_aExceptionInfo = _rInfo;
}
/**
just returns the internal member and clears it
*/
- ::dbtools::SQLExceptionInfo clearOccuredError()
+ ::dbtools::SQLExceptionInfo clearOccurredError()
{
::dbtools::SQLExceptionInfo aInfo = m_aExceptionInfo;
m_aExceptionInfo = ::dbtools::SQLExceptionInfo();
@@ -174,3 +175,4 @@ namespace dbaui
}
#endif // DBAUI_JOINCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/JoinDesignView.hxx b/dbaccess/source/ui/inc/JoinDesignView.hxx
index 60d820a42a11..ce67cc1b8990 100644
--- a/dbaccess/source/ui/inc/JoinDesignView.hxx
+++ b/dbaccess/source/ui/inc/JoinDesignView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,12 @@
#ifndef DBAUI_JOINDESIGNVIEW_HXX
#define DBAUI_JOINDESIGNVIEW_HXX
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
#ifndef _VECTOR_
#include <vector>
#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
#include <memory>
@@ -89,3 +84,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/JoinExchange.hxx b/dbaccess/source/ui/inc/JoinExchange.hxx
index 48205effafb5..44f19b89c528 100644
--- a/dbaccess/source/ui/inc/JoinExchange.hxx
+++ b/dbaccess/source/ui/inc/JoinExchange.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,22 +28,12 @@
#ifndef DBAUI_JOINEXCHANGE_HXX
#define DBAUI_JOINEXCHANGE_HXX
-#ifndef DBAUI_DBEXCHANGE_HXX
#include "dbexchange.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef _TRANSFER_HXX
#include <svtools/transfer.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XUNOTUNNEL_HPP_
#include <com/sun/star/lang/XUnoTunnel.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
namespace dbaui
{
@@ -95,3 +86,4 @@ namespace dbaui
#endif // DBAUI_JOINEXCHANGE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/JoinTableView.hxx b/dbaccess/source/ui/inc/JoinTableView.hxx
index f390f1724afc..48073242a301 100644
--- a/dbaccess/source/ui/inc/JoinTableView.hxx
+++ b/dbaccess/source/ui/inc/JoinTableView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,28 +28,14 @@
#ifndef DBAUI_JOINTABLEVIEW_HXX
#define DBAUI_JOINTABLEVIEW_HXX
-#ifndef _SV_WINDOW_HXX
#include <vcl/window.hxx>
-#endif
-#ifndef _SV_TIMER_HXX
#include <vcl/timer.hxx>
-#endif
-#ifndef _SV_SCRBAR_HXX
#include <vcl/scrbar.hxx>
-#endif
-#ifndef _RTTI_HXX
#include <tools/rtti.hxx>
-#endif
-#ifndef _TRANSFER_HXX
#include <svtools/transfer.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#include "callbacks.hxx"
-#endif
#include "TableConnectionData.hxx"
#include "TableWindowData.hxx"
#include <memory>
@@ -335,3 +322,5 @@ namespace dbaui
};
}
#endif // DBAUI_JOINTABLEVIEW_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/QEnumTypes.hxx b/dbaccess/source/ui/inc/QEnumTypes.hxx
index 687b40dcb4c6..13ea803c3866 100644
--- a/dbaccess/source/ui/inc/QEnumTypes.hxx
+++ b/dbaccess/source/ui/inc/QEnumTypes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -88,3 +89,4 @@ namespace dbaui
#endif // DBAUI_ENUMTYPES_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/QueryDesignView.hxx b/dbaccess/source/ui/inc/QueryDesignView.hxx
index 5f117815ce5f..4fa761fa3b64 100644
--- a/dbaccess/source/ui/inc/QueryDesignView.hxx
+++ b/dbaccess/source/ui/inc/QueryDesignView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,27 +28,13 @@
#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#define DBAUI_QUERYDESIGNVIEW_HXX
-#ifndef DBAUI_QUERYVIEW_HXX
#include "queryview.hxx"
-#endif
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
namespace connectivity
{
@@ -187,3 +174,4 @@ namespace dbaui
}
#endif // DBAUI_QUERYDESIGNVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/QueryTableView.hxx b/dbaccess/source/ui/inc/QueryTableView.hxx
index bd8d8fe63b5a..8089b1a2744b 100644
--- a/dbaccess/source/ui/inc/QueryTableView.hxx
+++ b/dbaccess/source/ui/inc/QueryTableView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_QUERYTABLEVIEW_HXX
#define DBAUI_QUERYTABLEVIEW_HXX
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
namespace dbaui
{
@@ -147,3 +142,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/QueryTextView.hxx b/dbaccess/source/ui/inc/QueryTextView.hxx
index f2dbf833c56b..d541e972169c 100644
--- a/dbaccess/source/ui/inc/QueryTextView.hxx
+++ b/dbaccess/source/ui/inc/QueryTextView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_QUERYVIEW_TEXT_HXX
#define DBAUI_QUERYVIEW_TEXT_HXX
-#ifndef DBAUI_QUERYVIEW_HXX
#include "queryview.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTAINERWINDOW_HXX
#include "querycontainerwindow.hxx"
-#endif
class Splitter;
namespace dbaui
@@ -74,3 +71,4 @@ namespace dbaui
#endif // DBAUI_QUERYVIEW_TEXT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/QueryViewSwitch.hxx b/dbaccess/source/ui/inc/QueryViewSwitch.hxx
index 57ff2b5b29ff..9ddc6ce20108 100644
--- a/dbaccess/source/ui/inc/QueryViewSwitch.hxx
+++ b/dbaccess/source/ui/inc/QueryViewSwitch.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -102,3 +103,4 @@ namespace dbaui
}
#endif // DBAUI_QUERYVIEWSWITCH_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RTableConnectionData.hxx b/dbaccess/source/ui/inc/RTableConnectionData.hxx
index 488c2e32cb97..096f97ba4675 100644
--- a/dbaccess/source/ui/inc/RTableConnectionData.hxx
+++ b/dbaccess/source/ui/inc/RTableConnectionData.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
#ifndef DBAUI_RTABLECONNECTIONDATA_HXX
#define DBAUI_RTABLECONNECTIONDATA_HXX
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
namespace dbaui
{
@@ -106,3 +99,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RefFunctor.hxx b/dbaccess/source/ui/inc/RefFunctor.hxx
index 0cd287d18448..41d48ca7b094 100644
--- a/dbaccess/source/ui/inc/RefFunctor.hxx
+++ b/dbaccess/source/ui/inc/RefFunctor.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBAUI_REFFUNCTOR_HXX
#define DBAUI_REFFUNCTOR_HXX
-#ifndef _VOS_REF_HXX_
-#include <vos/ref.hxx>
-#endif
+#include <rtl/ref.hxx>
#ifndef INCLUDED_FUNCTIONAL
#define INCLUDED_FUNCTIONAL
#include <functional>
@@ -38,23 +37,20 @@
namespace dbaui
{
- template <class T> class OUnaryRefFunctor : public ::std::unary_function< ::vos::ORef<T> ,void>
+ template <class T> class OUnaryRefFunctor : public ::std::unary_function< ::rtl::Reference<T> ,void>
{
::std::mem_fun_t<bool,T> m_aFunction;
public:
OUnaryRefFunctor(const ::std::mem_fun_t<bool,T>& _aFunc) : m_aFunction(_aFunc)
{}
- inline void operator()(const ::vos::ORef<T>& _aType) const
+ inline void operator()(const ::rtl::Reference<T>& _aType) const
{
- m_aFunction(_aType.getBodyPtr());
+ m_aFunction(_aType.get());
}
-// inline void operator()(const ::vos::ORef<T>& _aType)
-// {
-// m_aFunction(_aType.getBodyPtr());
-// }
};
// -----------------------------------------------------------------------------
} // namespace dbaui
// -----------------------------------------------------------------------------
#endif //DBAUI_REFFUNCTOR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RelControliFace.hxx b/dbaccess/source/ui/inc/RelControliFace.hxx
index 0780bfaa2244..ab0366263e50 100644
--- a/dbaccess/source/ui/inc/RelControliFace.hxx
+++ b/dbaccess/source/ui/inc/RelControliFace.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_RELCONTROLIFACE_HXX
#define DBAUI_RELCONTROLIFACE_HXX
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
#include "TableConnectionData.hxx"
namespace dbaui
@@ -58,3 +57,5 @@ namespace dbaui
};
}
#endif // DBAUI_RELCONTROLIFACE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RelationControl.hxx b/dbaccess/source/ui/inc/RelationControl.hxx
index d90bbe6fbaaa..62b812f4f98f 100644
--- a/dbaccess/source/ui/inc/RelationControl.hxx
+++ b/dbaccess/source/ui/inc/RelationControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_RELATIONCONTROL_HXX
#define DBAUI_RELATIONCONTROL_HXX
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
namespace dbaui
{
@@ -106,3 +101,5 @@ namespace dbaui
};
}
#endif // DBAUI_RELATIONCONTROL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RelationController.hxx b/dbaccess/source/ui/inc/RelationController.hxx
index 1314f7e884e9..38253627fcc5 100644
--- a/dbaccess/source/ui/inc/RelationController.hxx
+++ b/dbaccess/source/ui/inc/RelationController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_RELATIONCONTROLLER_HXX
#define DBAUI_RELATIONCONTROLLER_HXX
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef DBAUI_RELATIONDESIGNVIEW_HXX
#include "RelationDesignView.hxx"
-#endif
class VCLXWindow;
class WaitObject;
@@ -99,3 +96,4 @@ namespace dbaui
}
#endif // DBAUI_RELATIONCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RelationDesignView.hxx b/dbaccess/source/ui/inc/RelationDesignView.hxx
index 346e3a4ea065..423885b3ee38 100644
--- a/dbaccess/source/ui/inc/RelationDesignView.hxx
+++ b/dbaccess/source/ui/inc/RelationDesignView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,21 +29,13 @@
#ifndef DBAUI_RELATIONDESIGNVIEW_HXX
#define DBAUI_RELATIONDESIGNVIEW_HXX
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
#ifndef _VECTOR_
#include <vector>
#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef DBAUI_RELATION_TABLEVIEW_HXX
#include "RelationTableView.hxx"
-#endif
namespace dbaui
{
@@ -72,3 +65,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RelationDlg.hxx b/dbaccess/source/ui/inc/RelationDlg.hxx
index a2c51941d93c..7320a8d14908 100644
--- a/dbaccess/source/ui/inc/RelationDlg.hxx
+++ b/dbaccess/source/ui/inc/RelationDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,31 +28,14 @@
#ifndef DBAUI_RELATIONDIALOG_HXX
#define DBAUI_RELATIONDIALOG_HXX
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-//#ifndef _EDIT_HXX //autogen
-//#include <vcl/edit.hxx>
-//#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef DBAUI_RELCONTROLIFACE_HXX
#include "RelControliFace.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
namespace dbaui
@@ -128,3 +112,4 @@ namespace dbaui
#endif // DBAUI_RELATIONDIALOG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RelationTableView.hxx b/dbaccess/source/ui/inc/RelationTableView.hxx
index a22b3e59ca7d..d708cbac1424 100644
--- a/dbaccess/source/ui/inc/RelationTableView.hxx
+++ b/dbaccess/source/ui/inc/RelationTableView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -80,3 +81,4 @@ namespace dbaui
#endif // DBAUI_RELATION_TABLEVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/RtfReader.hxx b/dbaccess/source/ui/inc/RtfReader.hxx
index 3f73e947389a..299274aef315 100644
--- a/dbaccess/source/ui/inc/RtfReader.hxx
+++ b/dbaccess/source/ui/inc/RtfReader.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,15 +31,9 @@
#ifndef _VECTOR_
#include <vector>
#endif
-#ifndef _PARRTF_HXX //autogen
#include <svtools/parrtf.hxx>
-#endif
-#ifndef DBAUI_DATABASEEXPORT_HXX
#include "DExport.hxx"
-#endif
-#ifndef _STREAM_HXX
#include <tools/stream.hxx>
-#endif
namespace dbaui
{
@@ -82,3 +77,4 @@ namespace dbaui
#endif // DBAUI_RTFREADER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/ScrollHelper.hxx b/dbaccess/source/ui/inc/ScrollHelper.hxx
index f9666e7d651c..6835c99eef3e 100644
--- a/dbaccess/source/ui/inc/ScrollHelper.hxx
+++ b/dbaccess/source/ui/inc/ScrollHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_SCROLLHELPER_HXX
#define DBAUI_SCROLLHELPER_HXX
-#ifndef _LINK_HXX
#include <tools/link.hxx>
-#endif
-#ifndef _SV_GEN_HXX
#include <tools/gen.hxx>
-#endif
-#ifndef _SV_TIMER_HXX
#include <vcl/timer.hxx>
-#endif
namespace dbaui
{
@@ -79,3 +74,4 @@ namespace dbaui
}
#endif // DBAUI_SCROLLHELPER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/SqlNameEdit.hxx b/dbaccess/source/ui/inc/SqlNameEdit.hxx
index c7f82806c742..edeed2d4f40b 100644
--- a/dbaccess/source/ui/inc/SqlNameEdit.hxx
+++ b/dbaccess/source/ui/inc/SqlNameEdit.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_SQLNAMEEDIT_HXX
#define DBAUI_SQLNAMEEDIT_HXX
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _SV_COMBOBOX_HXX
#include <vcl/combobox.hxx>
-#endif
namespace dbaui
{
@@ -110,3 +107,4 @@ namespace dbaui
#endif // DBAUI_SQLNAMEEDIT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableConnection.hxx b/dbaccess/source/ui/inc/TableConnection.hxx
index 8edc25c5f1dc..8d4629c36425 100644
--- a/dbaccess/source/ui/inc/TableConnection.hxx
+++ b/dbaccess/source/ui/inc/TableConnection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,25 +28,11 @@
#ifndef DBAUI_TABLECONNECTION_HXX
#define DBAUI_TABLECONNECTION_HXX
-//#ifndef _SV_GEN_HXX
-//#include <tools/gen.hxx>
-//#endif
-//#ifndef DBAUI_CONNECTIONLINE_HXX
-//#include "ConnectionLine.hxx"
-//#endif
#include <vector>
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _SV_WINDOW_HXX
#include <vcl/window.hxx>
-#endif
-#ifndef _RTTI_HXX
#include <tools/rtti.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UNO_REFERENCE_H_
#include <com/sun/star/uno/Reference.h>
-#endif
#include "TableConnectionData.hxx"
class Point;
@@ -121,3 +108,4 @@ namespace dbaui
}
#endif // DBAUI_TABLECONNECTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableConnectionData.hxx b/dbaccess/source/ui/inc/TableConnectionData.hxx
index 496471a903ca..79ccd802d564 100644
--- a/dbaccess/source/ui/inc/TableConnectionData.hxx
+++ b/dbaccess/source/ui/inc/TableConnectionData.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,22 +28,15 @@
#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#define DBAUI_TABLECONNECTIONDATA_HXX
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
#include "TableWindowData.hxx"
#include <vector>
-#ifndef _RTTI_HXX
#include <tools/rtti.hxx>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
#include <boost/shared_ptr.hpp>
namespace dbaui
{
-#define MAX_CONN_COUNT 2
//==================================================================
// ConnData ---------->* ConnLineData
// ^1 ^1
@@ -117,3 +111,4 @@ namespace dbaui
#endif // DBAUI_TABLECONNECTIONDATA_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableController.hxx b/dbaccess/source/ui/inc/TableController.hxx
index a1f1b8158c65..5747cd20ac10 100644
--- a/dbaccess/source/ui/inc/TableController.hxx
+++ b/dbaccess/source/ui/inc/TableController.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -153,3 +154,4 @@ namespace dbaui
#endif // DBUI_TABLECONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableCopyHelper.hxx b/dbaccess/source/ui/inc/TableCopyHelper.hxx
index 9b56d0729fa4..4745c232eaef 100644
--- a/dbaccess/source/ui/inc/TableCopyHelper.hxx
+++ b/dbaccess/source/ui/inc/TableCopyHelper.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,27 +28,13 @@
#ifndef DBUI_TABLECOPYHELPER_HXX
#define DBUI_TABLECOPYHELPER_HXX
-#ifndef DBAUI_APPELEMENTTYPE_HXX
#include "AppElementType.hxx"
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
-#ifndef _SVX_DATACCESSDESCRIPTOR_HXX_
#include <svx/dataaccessdescriptor.hxx>
-#endif
-#ifndef _SOT_STORAGE_HXX
#include <sot/storage.hxx>
-#endif
-#ifndef _TRANSFER_HXX
#include <svtools/transfer.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSET_HPP_
#include <com/sun/star/sdbc/XResultSet.hpp>
-#endif
#include <functional>
class SvLBoxEntry;
@@ -94,10 +81,10 @@ namespace dbaui
struct DropDescriptor
{
::svx::ODataAccessDescriptor aDroppedData;
- //dyf add 20070601
+
//for transfor the tablename
::rtl::OUString sDefaultTableName;
- //dyf add end
+
String aUrl;
SotStorageStreamRef aHtmlRtfStorage;
ElementType nType;
@@ -210,3 +197,4 @@ namespace dbaui
//........................................................................
#endif // DBUI_TABLECOPYHELPER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableDesignControl.hxx b/dbaccess/source/ui/inc/TableDesignControl.hxx
index a448b720bc1a..0e905a459cc2 100644
--- a/dbaccess/source/ui/inc/TableDesignControl.hxx
+++ b/dbaccess/source/ui/inc/TableDesignControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,19 +28,11 @@
#ifndef DBAUI_TABLEDESIGNCONTROL_HXX
#define DBAUI_TABLEDESIGNCONTROL_HXX
-#ifndef _TABBAR_HXX //autogen
#include <svtools/tabbar.hxx>
-#endif
-#ifndef _SVTOOLS_EDITBROWSEBOX_HXX_
#include <svtools/editbrowsebox.hxx>
-#endif
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
#define TABPAGESIZE 70
namespace dbaui
@@ -106,3 +99,4 @@ namespace dbaui
#endif // DBAUI_TABLEDESIGNCONTROL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableDesignHelpBar.hxx b/dbaccess/source/ui/inc/TableDesignHelpBar.hxx
index 7f23f6d5f482..a3bef0769a8c 100644
--- a/dbaccess/source/ui/inc/TableDesignHelpBar.hxx
+++ b/dbaccess/source/ui/inc/TableDesignHelpBar.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,25 +28,17 @@
#ifndef DBAUI_TABLEDESIGNHELPBAR_HXX
#define DBAUI_TABLEDESIGNHELPBAR_HXX
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _SV_TABCTRL_HXX
#include <vcl/tabctrl.hxx>
-#endif
-#ifndef _SV_TABPAGE_HXX
#include <vcl/tabpage.hxx>
-#endif
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
class MultiLineEdit;
namespace dbaui
{
//==================================================================
// Ableitung von TabPage ist ein Trick von TH,
- // um Aenderungen der Systemfarben zu bemerken (Bug #53905)
+ // um Aenderungen der Systemfarben zu bemerken
class OTableDesignHelpBar : public TabPage
,public IClipboardTest
{
@@ -79,3 +72,4 @@ namespace dbaui
}
#endif // DBAUI_TABLEDESIGNHELPBAR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableDesignView.hxx b/dbaccess/source/ui/inc/TableDesignView.hxx
index b8d688ff9668..9f4a96b6844d 100644
--- a/dbaccess/source/ui/inc/TableDesignView.hxx
+++ b/dbaccess/source/ui/inc/TableDesignView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
#ifndef DBAUI_TABLEDESIGNVIEW_HXX
#define DBAUI_TABLEDESIGNVIEW_HXX
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCONTROLLER_HPP_
#include <com/sun/star/frame/XController.hpp>
-#endif
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
namespace dbaui
{
@@ -129,3 +120,4 @@ namespace dbaui
}
#endif // DBAUI_TABLEDESIGNVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableFieldDescription.hxx b/dbaccess/source/ui/inc/TableFieldDescription.hxx
index 7160edbbfbfb..6f716e30d5e8 100644
--- a/dbaccess/source/ui/inc/TableFieldDescription.hxx
+++ b/dbaccess/source/ui/inc/TableFieldDescription.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,18 +32,12 @@
#define INCLUDED_VECTOR
#include <vector>
#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _VOS_REF_HXX_
-#include <vos/ref.hxx>
-#endif
+#include <rtl/ref.hxx>
+
+#include <salhelper/simplereferenceobject.hxx>
namespace comphelper
{
@@ -52,7 +47,7 @@ namespace comphelper
class Window;
namespace dbaui
{
- class OTableFieldDesc : public ::vos::OReference
+ class OTableFieldDesc : public ::salhelper::SimpleReferenceObject
{
private:
::std::vector< ::rtl::OUString >
@@ -160,8 +155,9 @@ namespace dbaui
return bEmpty;
}
//------------------------------------------------------------------
- typedef ::vos::ORef< OTableFieldDesc> OTableFieldDescRef;
+ typedef ::rtl::Reference< OTableFieldDesc> OTableFieldDescRef;
typedef ::std::vector<OTableFieldDescRef> OTableFields;
}
#endif //
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableGrantCtrl.hxx b/dbaccess/source/ui/inc/TableGrantCtrl.hxx
index 9d6716f389b1..a0010fdbc82d 100644
--- a/dbaccess/source/ui/inc/TableGrantCtrl.hxx
+++ b/dbaccess/source/ui/inc/TableGrantCtrl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
#ifndef DBAUI_TABLEGRANTCONTROL_HXX
#define DBAUI_TABLEGRANTCONTROL_HXX
-#ifndef _SVTOOLS_EDITBROWSEBOX_HXX_
#include <svtools/editbrowsebox.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAUTHORIZABLE_HPP_
#include <com/sun/star/sdbcx/XAuthorizable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
class Edit;
namespace dbaui
@@ -124,3 +113,5 @@ private:
}
#endif // DBAUI_TABLEGRANTCONTROL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableRow.hxx b/dbaccess/source/ui/inc/TableRow.hxx
index bdf734ea528c..9e02a0df0662 100644
--- a/dbaccess/source/ui/inc/TableRow.hxx
+++ b/dbaccess/source/ui/inc/TableRow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,28 +28,15 @@
#ifndef DBAUI_TABLEROW_HXX
#define DBAUI_TABLEROW_HXX
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _STREAM_HXX
#include <tools/stream.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
namespace dbaui
{
-// class OTableRow;
-// friend SvStream& operator<<( SvStream& rStr, OTableRow& _rRow );
-
class OFieldDescription;
class OTypeInfo;
class OTableRow
@@ -99,3 +87,4 @@ namespace dbaui
}
#endif // DBAUI_TABLEROW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableRowExchange.hxx b/dbaccess/source/ui/inc/TableRowExchange.hxx
index 55f662fb1d79..4a433f7c849e 100644
--- a/dbaccess/source/ui/inc/TableRowExchange.hxx
+++ b/dbaccess/source/ui/inc/TableRowExchange.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_TABLEROW_EXCHANGE_HXX
#define DBAUI_TABLEROW_EXCHANGE_HXX
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE2_HXX_
#include <cppuhelper/implbase2.hxx>
-#endif
-#ifndef _TRANSFER_HXX
#include <svtools/transfer.hxx>
-#endif
#include <boost/shared_ptr.hpp>
namespace dbaui
@@ -55,3 +50,4 @@ namespace dbaui
}
#endif // DBAUI_TABLEROW_EXCHANGE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableWindow.hxx b/dbaccess/source/ui/inc/TableWindow.hxx
index d76ca7a15937..382a278dee2c 100644
--- a/dbaccess/source/ui/inc/TableWindow.hxx
+++ b/dbaccess/source/ui/inc/TableWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -207,3 +208,4 @@ namespace dbaui
#endif //DBAUI_TABLEWINDOW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableWindowAccess.hxx b/dbaccess/source/ui/inc/TableWindowAccess.hxx
index 78828a30cfbc..f8351362c001 100644
--- a/dbaccess/source/ui/inc/TableWindowAccess.hxx
+++ b/dbaccess/source/ui/inc/TableWindowAccess.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBACCESS_TABLEWINDOWACCESS_HXX
#define DBACCESS_TABLEWINDOWACCESS_HXX
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_XACCESSIBLERELATIONSET_HPP_
#include <com/sun/star/accessibility/XAccessibleRelationSet.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE2_HXX_
#include <cppuhelper/implbase2.hxx>
-#endif
-#ifndef _TOOLKIT_AWT_VCLXACCESSIBLECOMPONENT_HXX_
#include <toolkit/awt/vclxaccessiblecomponent.hxx>
-#endif
namespace dbaui
{
@@ -122,3 +117,5 @@ namespace dbaui
};
}
#endif // DBACCESS_TABLEWINDOWACCESS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableWindowData.hxx b/dbaccess/source/ui/inc/TableWindowData.hxx
index 51644184bcb2..9a3bd21f1664 100644
--- a/dbaccess/source/ui/inc/TableWindowData.hxx
+++ b/dbaccess/source/ui/inc/TableWindowData.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_TABLEWINDOWDATA_HXX
#define DBAUI_TABLEWINDOWDATA_HXX
-#ifndef _SV_GEN_HXX
#include <tools/gen.hxx>
-#endif
#include <com/sun/star/beans/XPropertySet.hpp>
#include <com/sun/star/container/XNameAccess.hpp>
#include <com/sun/star/container/XIndexAccess.hpp>
@@ -104,3 +103,4 @@ namespace dbaui
}
#endif // DBAUI_TABLEWINDOWDATA_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableWindowListBox.hxx b/dbaccess/source/ui/inc/TableWindowListBox.hxx
index bd25e3a244fb..bf8fab0ac395 100644
--- a/dbaccess/source/ui/inc/TableWindowListBox.hxx
+++ b/dbaccess/source/ui/inc/TableWindowListBox.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -107,3 +108,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TableWindowTitle.hxx b/dbaccess/source/ui/inc/TableWindowTitle.hxx
index 4291f11fecb9..e81ab0be5597 100644
--- a/dbaccess/source/ui/inc/TableWindowTitle.hxx
+++ b/dbaccess/source/ui/inc/TableWindowTitle.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_TABLEWINDOWTITLE_HXX
#define DBAUI_TABLEWINDOWTITLE_HXX
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
namespace dbaui
{
@@ -57,3 +56,4 @@ namespace dbaui
}
#endif // DBAUI_TABLEWINDOWTITLE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TablesSingleDlg.hxx b/dbaccess/source/ui/inc/TablesSingleDlg.hxx
index 0c686921f30f..e9c7880caf9c 100644
--- a/dbaccess/source/ui/inc/TablesSingleDlg.hxx
+++ b/dbaccess/source/ui/inc/TablesSingleDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef _DBAUI_TABLESSINGLEDLG_HXX_
#define _DBAUI_TABLESSINGLEDLG_HXX_
-#ifndef _BASEDLGS_HXX
#include <sfx2/basedlgs.hxx>
-#endif
-#ifndef DBAUI_ITEMSETHELPER_HXX
#include "IItemSetHelper.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
#include <memory>
@@ -91,3 +84,4 @@ class ODbDataSourceAdministrationHelper;
#endif // _DBAUI_TABLESSINGLEDLG_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TokenWriter.hxx b/dbaccess/source/ui/inc/TokenWriter.hxx
index bbefbe3f85e7..e3b2ffcb3efb 100644
--- a/dbaccess/source/ui/inc/TokenWriter.hxx
+++ b/dbaccess/source/ui/inc/TokenWriter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -83,18 +84,18 @@ namespace dbaui
::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory> m_xFactory;
::rtl::OUString m_sName;
- //dyf add 20070601
+
//for transfor the tablename
::rtl::OUString m_sDefaultTableName;
- //dyf add end
+
::rtl::OUString m_sDataSourceName;
sal_Int32 m_nCommandType;
bool m_bNeedToReInitialize;
#if defined UNX
- static const char __FAR_DATA sNewLine;
+ static const char sNewLine;
#else
- static const char __FAR_DATA sNewLine[];
+ static const char sNewLine[];
#endif
ODatabaseExport* m_pReader;
@@ -120,10 +121,8 @@ namespace dbaui
public:
void setStream(SvStream* _pStream){ m_pStream = _pStream; }
- //dyf add 20070601
//for set the tablename
void setSTableName(const ::rtl::OUString &_sTableName){ m_sDefaultTableName = _sTableName; }
- //dyf add end
virtual sal_Bool Write(); // Export
virtual sal_Bool Read(); // Import
@@ -177,10 +176,10 @@ namespace dbaui
// HtmlFontSz[1-7] in s*3.ini [user]
static sal_Int16 nFontSize[SBA_HTML_FONTSIZES];
static const sal_Int16 nCellSpacing;
- static const char __FAR_DATA sIndentSource[];
+ static const char sIndentSource[];
char sIndent[nIndentMax+1];
sal_Int16 m_nIndent;
- #ifdef DBG_UTIL
+ #if OSL_DEBUG_LEVEL > 0
sal_Bool m_bCheckFont;
#endif
@@ -255,3 +254,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/TypeInfo.hxx b/dbaccess/source/ui/inc/TypeInfo.hxx
index 89f9863855c2..10ea51cf58aa 100644
--- a/dbaccess/source/ui/inc/TypeInfo.hxx
+++ b/dbaccess/source/ui/inc/TypeInfo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#define DBAUI_TYPEINFO_HXX
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNSEARCH_HPP_
#include <com/sun/star/sdbc/ColumnSearch.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNVALUE_HPP_
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#endif
#include <boost/shared_ptr.hpp>
#include <map>
@@ -150,3 +143,4 @@ const sal_uInt16 TYPE_BIT = 31;
#endif // DBAUI_TYPEINFO_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/UITools.hxx b/dbaccess/source/ui/inc/UITools.hxx
index e2268a627a50..c4c8ccb96d74 100644
--- a/dbaccess/source/ui/inc/UITools.hxx
+++ b/dbaccess/source/ui/inc/UITools.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
#ifndef DBAUI_TOOLS_HXX
#define DBAUI_TOOLS_HXX
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
-#ifndef _SVX_SVXENUM_HXX
#include <editeng/svxenum.hxx>
-#endif
-#ifndef _SV_TASKPANELIST_HXX
#include <vcl/taskpanelist.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
#define RET_ALL 10
@@ -277,14 +266,6 @@ namespace dbaui
*/
void adjustToolBoxSize(ToolBox* _pToolBox);
- /** isHiContrast check if we are in hi contrast mode.
- @param _pWindow
- The window we have to check on.
- @return
- <TRUE/> if so, otherwise <FALSE/>
- */
- sal_Bool isHiContrast(Window* _pWindow);
-
void adjustBrowseBoxColumnWidth( ::svt::EditBrowseBox* _pBox, sal_uInt16 _nColId );
/** check if SQL92 name checking is enabled
@@ -472,3 +453,4 @@ namespace dbaui
#endif // DBAUI_TOOLS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/UserAdminDlg.hxx b/dbaccess/source/ui/inc/UserAdminDlg.hxx
index 96dcc4394a95..6315528cda88 100644
--- a/dbaccess/source/ui/inc/UserAdminDlg.hxx
+++ b/dbaccess/source/ui/inc/UserAdminDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,21 +29,11 @@
#ifndef DBAUI_USERADMINDLG_HXX
#define DBAUI_USERADMINDLG_HXX
-#ifndef _SFXTABDLG_HXX
#include <sfx2/tabdlg.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef DBAUI_ITEMSETHELPER_HXX
#include "IItemSetHelper.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
#include <memory>
FORWARD_DECLARE_INTERFACE(beans,XPropertySet)
@@ -98,3 +89,5 @@ namespace dbaui
//.........................................................................
#endif // DBAUI_USERADMINDLG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/VertSplitView.hxx b/dbaccess/source/ui/inc/VertSplitView.hxx
index 3e45dc2a29c7..b9d52b36fabd 100644
--- a/dbaccess/source/ui/inc/VertSplitView.hxx
+++ b/dbaccess/source/ui/inc/VertSplitView.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_VERTSPLITVIEW_HXX
#define DBAUI_VERTSPLITVIEW_HXX
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
namespace dbaui
{
@@ -58,3 +57,4 @@ namespace dbaui
}
#endif // DBAUI_VERTSPLITVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/WCPage.hxx b/dbaccess/source/ui/inc/WCPage.hxx
index 9312a490891f..f754e5d9429d 100644
--- a/dbaccess/source/ui/inc/WCPage.hxx
+++ b/dbaccess/source/ui/inc/WCPage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,24 +30,12 @@
#include "WTabPage.hxx"
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_GROUP_HXX
#include <vcl/group.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
namespace dbaui
{
@@ -81,9 +70,7 @@ namespace dbaui
DECL_LINK( KeyClickHdl, Button* );
sal_Bool checkAppendData();
- //--------dyf add
void SetAppendDataRadio();
- //--------add end
public:
virtual void Reset();
@@ -118,3 +105,4 @@ namespace dbaui
#endif // DBAUI_WIZARD_CPAGE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/WColumnSelect.hxx b/dbaccess/source/ui/inc/WColumnSelect.hxx
index 42cb2527a426..a0819255f615 100644
--- a/dbaccess/source/ui/inc/WColumnSelect.hxx
+++ b/dbaccess/source/ui/inc/WColumnSelect.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,15 +31,9 @@
#include "WTabPage.hxx"
#include "WCopyTable.hxx"
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
#include <comphelper/stl_types.hxx>
namespace dbaui
@@ -107,3 +102,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/WCopyTable.hxx b/dbaccess/source/ui/inc/WCopyTable.hxx
index 6596eea8c7c5..7249dcdc1104 100644
--- a/dbaccess/source/ui/inc/WCopyTable.hxx
+++ b/dbaccess/source/ui/inc/WCopyTable.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -418,3 +419,5 @@ namespace dbaui
}
#endif // DBAUI_WIZ_COPYTABLEDIALOG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/WExtendPages.hxx b/dbaccess/source/ui/inc/WExtendPages.hxx
index 0045bb859328..b12578deda6b 100644
--- a/dbaccess/source/ui/inc/WExtendPages.hxx
+++ b/dbaccess/source/ui/inc/WExtendPages.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_WIZ_EXTENDPAGES_HXX
#define DBAUI_WIZ_EXTENDPAGES_HXX
-#ifndef DBAUI_WIZ_TYPESELECT_HXX
#include "WTypeSelect.hxx"
-#endif
class SvStream;
namespace dbaui
@@ -84,3 +83,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/WNameMatch.hxx b/dbaccess/source/ui/inc/WNameMatch.hxx
index ba11df243717..06d6a76fe655 100644
--- a/dbaccess/source/ui/inc/WNameMatch.hxx
+++ b/dbaccess/source/ui/inc/WNameMatch.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
#ifndef DBAUI_WIZ_NAMEMATCHING_HXX
#define DBAUI_WIZ_NAMEMATCHING_HXX
-#ifndef DBAUI_WIZ_TABBPAGE_HXX
#include "WTabPage.hxx"
-#endif
-#ifndef _DBAUI_MARKTREE_HXX_
#include "marktree.hxx"
-#endif
-#ifndef DBAUI_DATABASEEXPORT_HXX
#include "DExport.hxx"
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef DBAUI_WIZ_COPYTABLEDIALOG_HXX
#include "WCopyTable.hxx"
-#endif
namespace dbaui
{
@@ -110,3 +99,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/WTabPage.hxx b/dbaccess/source/ui/inc/WTabPage.hxx
index 51746e1e6aae..d36a4438c554 100644
--- a/dbaccess/source/ui/inc/WTabPage.hxx
+++ b/dbaccess/source/ui/inc/WTabPage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBAUI_WIZ_TABBPAGE_HXX
#define DBAUI_WIZ_TABBPAGE_HXX
-#ifndef _SV_TABPAGE_HXX
#include <vcl/tabpage.hxx>
-#endif
namespace dbaui
{
@@ -44,7 +43,7 @@ namespace dbaui
OCopyTableWizard* m_pParent;
sal_Bool m_bFirstTime; // Page wird das erste mal gerufen ; should be set in the reset methode
- OWizardPage( Window* pParent, const ResId& rResId );// : TabPage(pParent,rResId),m_pParent((OCopyTableWizard*)pParent),m_bFirstTime(sal_True) {};
+ OWizardPage( Window* pParent, const ResId& rResId );
public:
virtual void Reset ( ) = 0;
@@ -58,3 +57,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/WTypeSelect.hxx b/dbaccess/source/ui/inc/WTypeSelect.hxx
index 3f3c8433d124..ab57648adf90 100644
--- a/dbaccess/source/ui/inc/WTypeSelect.hxx
+++ b/dbaccess/source/ui/inc/WTypeSelect.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -140,3 +141,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/adtabdlg.hxx b/dbaccess/source/ui/inc/adtabdlg.hxx
index b00a008d83b5..d2d7c6d8a98e 100644
--- a/dbaccess/source/ui/inc/adtabdlg.hxx
+++ b/dbaccess/source/ui/inc/adtabdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,35 +28,19 @@
#ifndef DBAUI_QYDLGTAB_HXX
#define DBAUI_QYDLGTAB_HXX
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
-#ifndef _STRING_HXX //autogen
#include <tools/string.hxx>
-#endif
-#ifndef _DBAUI_TABLETREE_HXX_
#include "tabletree.hxx"
-#endif
#include <memory>
@@ -138,3 +123,5 @@ namespace dbaui
};
}
#endif // DBAUI_QYDLGTAB_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/advancedsettingsdlg.hxx b/dbaccess/source/ui/inc/advancedsettingsdlg.hxx
index 8353e97be093..6afc8f6ddd1c 100644
--- a/dbaccess/source/ui/inc/advancedsettingsdlg.hxx
+++ b/dbaccess/source/ui/inc/advancedsettingsdlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,3 +93,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_ADVANCEDSETTINGSDLG_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/asyncmodaldialog.hxx b/dbaccess/source/ui/inc/asyncmodaldialog.hxx
index 376512912da6..4cdc83d70dfc 100644
--- a/dbaccess/source/ui/inc/asyncmodaldialog.hxx
+++ b/dbaccess/source/ui/inc/asyncmodaldialog.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,9 +30,7 @@
#define DBACCESS_ASYNCMODALDIALOG_HXX
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XEXECUTABLEDIALOG_HPP_
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
-#endif
/** === end UNO includes === **/
//........................................................................
@@ -65,3 +64,4 @@ namespace dbaui
#endif // DBACCESS_ASYNCMODALDIALOG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/browserids.hxx b/dbaccess/source/ui/inc/browserids.hxx
index 94fea5a5c067..7bd5a7c67171 100644
--- a/dbaccess/source/ui/inc/browserids.hxx
+++ b/dbaccess/source/ui/inc/browserids.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBACCESS_UI_BROWSER_ID_HXX
#define DBACCESS_UI_BROWSER_ID_HXX
-#ifndef _SBASLTID_HRC
#include <svx/svxids.hrc>
-#endif
-#ifndef _DBACCESS_SLOTID_HRC_
#include "dbaccess_slotid.hrc"
-#endif
#define ID_BROWSER_COPY SID_COPY
#define ID_BROWSER_CUT SID_CUT
@@ -120,3 +117,5 @@
#endif // DBACCESS_UI_BROWSER_ID_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/brwctrlr.hxx b/dbaccess/source/ui/inc/brwctrlr.hxx
index 2b0f1c471356..47c510a68840 100644
--- a/dbaccess/source/ui/inc/brwctrlr.hxx
+++ b/dbaccess/source/ui/inc/brwctrlr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -52,7 +53,7 @@
#include <vcl/timer.hxx>
#include <svtools/transfer.hxx>
#include <osl/mutex.hxx>
-#include <vos/thread.hxx>
+#include <osl/thread.hxx>
#include <cppuhelper/implbase9.hxx>
#include <svtools/cliplistener.hxx>
@@ -368,3 +369,4 @@ namespace dbaui
#endif // _SBA_BWRCTRLR_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/brwview.hxx b/dbaccess/source/ui/inc/brwview.hxx
index 519c9792019c..b73016ea34e8 100644
--- a/dbaccess/source/ui/inc/brwview.hxx
+++ b/dbaccess/source/ui/inc/brwview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,23 +29,13 @@
#ifndef _SBX_BRWVIEW_HXX
#define _SBX_BRWVIEW_HXX
-#ifndef _SV_WINDOW_HXX //autogen
#include <vcl/window.hxx>
-#endif
-#ifndef _TOOLS_RESID_HXX //autogen wg. ResId
#include <tools/resid.hxx>
-#endif
-#ifndef _COM_SUN_STAR_AWT_POSSIZE_HPP_
#include <com/sun/star/awt/PosSize.hpp>
-#endif
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
-#ifndef _UNOTOOLS_EVENTLISTENERADAPTER_HXX_
#include <unotools/eventlisteneradapter.hxx>
-#endif
namespace com { namespace sun { namespace star { namespace awt {
@@ -123,3 +114,4 @@ namespace dbaui
}
#endif // _SBX_BRWVIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/callbacks.hxx b/dbaccess/source/ui/inc/callbacks.hxx
index 2d9fdd95d60a..355e8faafcad 100644
--- a/dbaccess/source/ui/inc/callbacks.hxx
+++ b/dbaccess/source/ui/inc/callbacks.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#define _DBACCESS_UI_CALLBACKS_HXX_
-#ifndef _SOT_EXCHANGE_HXX
#include <sot/exchange.hxx>
-#endif
-#ifndef _SOT_FORMATS_HXX
#include <sot/formats.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
class CommandEvent;
class SvLBoxEntry;
@@ -131,3 +126,4 @@ namespace dbaui
#endif // _DBACCESS_UI_CALLBACKS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/charsetlistbox.hxx b/dbaccess/source/ui/inc/charsetlistbox.hxx
index 17936f3dc791..c0fde800c2e4 100644
--- a/dbaccess/source/ui/inc/charsetlistbox.hxx
+++ b/dbaccess/source/ui/inc/charsetlistbox.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -63,3 +64,5 @@ namespace dbaui
//........................................................................
#endif // CHARSETLISTBOX_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/charsets.hxx b/dbaccess/source/ui/inc/charsets.hxx
index bded889bcb2a..f5f51690178c 100644
--- a/dbaccess/source/ui/inc/charsets.hxx
+++ b/dbaccess/source/ui/inc/charsets.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef _DBAUI_CHARSETS_HXX_
#define _DBAUI_CHARSETS_HXX_
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _TOOLS_RC_HXX
#include <tools/rc.hxx>
-#endif
-#ifndef _DBHELPER_DBCHARSET_HXX_
#include <connectivity/dbcharset.hxx>
-#endif
-#ifndef _SVX_TXENCTAB_HXX
#include <svx/txenctab.hxx>
-#endif
//.........................................................................
namespace dbaui
@@ -148,3 +141,4 @@ namespace dbaui
#endif // _DBAUI_CHARSETS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/commontypes.hxx b/dbaccess/source/ui/inc/commontypes.hxx
index 1bf15631ba95..4fde4f6d1b38 100644
--- a/dbaccess/source/ui/inc/commontypes.hxx
+++ b/dbaccess/source/ui/inc/commontypes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef _DBAUI_COMMON_TYPES_HXX_
#define _DBAUI_COMMON_TYPES_HXX_
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef UNOTOOLS_INC_SHAREDUNOCOMPONENT_HXX
#include <unotools/sharedunocomponent.hxx>
-#endif
namespace com { namespace sun { namespace star {
namespace sdbc {
@@ -58,3 +55,4 @@ namespace dbaui
#endif // _DBAUI_COMMON_TYPES_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/curledit.hxx b/dbaccess/source/ui/inc/curledit.hxx
index b2e7e6d0c4d3..1257cf31f4f1 100644
--- a/dbaccess/source/ui/inc/curledit.hxx
+++ b/dbaccess/source/ui/inc/curledit.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
#ifndef _DBAUI_CURLEDIT_HXX_
#define _DBAUI_CURLEDIT_HXX_
-#ifndef _SV_EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
#include <memory>
//.........................................................................
@@ -91,3 +86,4 @@ public:
#endif // _DBAUI_CURLEDIT_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/databaseobjectview.hxx b/dbaccess/source/ui/inc/databaseobjectview.hxx
index 782555b106af..97659f454888 100644
--- a/dbaccess/source/ui/inc/databaseobjectview.hxx
+++ b/dbaccess/source/ui/inc/databaseobjectview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,42 +29,18 @@
#ifndef DBACCESS_DATABASE_OBJECT_VIEW_HXX
#define DBACCESS_DATABASE_OBJECT_VIEW_HXX
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCH_HPP_
#include <com/sun/star/frame/XDispatch.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XCOMPONENT_HPP_
#include <com/sun/star/lang/XComponent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_
#include <com/sun/star/frame/XComponentLoader.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XFRAME_HPP_
#include <com/sun/star/frame/XFrame.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XEXECUTABLEDIALOG_HPP_
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_XDATABASEDOCUMENTUI_HPP_
#include <com/sun/star/sdb/application/XDatabaseDocumentUI.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
#include <comphelper/namedvaluecollection.hxx>
#include <boost/shared_ptr.hpp>
@@ -284,3 +261,4 @@ namespace dbaui
#endif // DBACCESS_DATABASE_OBJECT_VIEW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/datasourceconnector.hxx b/dbaccess/source/ui/inc/datasourceconnector.hxx
index c74ede36d0af..cb2842591dd6 100644
--- a/dbaccess/source/ui/inc/datasourceconnector.hxx
+++ b/dbaccess/source/ui/inc/datasourceconnector.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef _DBAUI_DATASOURCECONNECTOR_HXX_
#define _DBAUI_DATASOURCECONNECTOR_HXX_
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
namespace dbtools
{
@@ -100,3 +93,4 @@ namespace dbaui
#endif // _DBAUI_DATASOURCECONNECTOR_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/datasourcemap.hxx b/dbaccess/source/ui/inc/datasourcemap.hxx
index e39515d35b75..54802093e17d 100644
--- a/dbaccess/source/ui/inc/datasourcemap.hxx
+++ b/dbaccess/source/ui/inc/datasourcemap.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,21 +29,11 @@
#ifndef DBAUI_DATASOURCEMAP_HXX
#define DBAUI_DATASOURCEMAP_HXX
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
class SfxItemPool;
class SfxItemSet;
@@ -122,7 +113,7 @@ namespace dbaui
void clearModifiedFlag(const ::rtl::OUString& _rName);
/** tell the map that a data source is scheduled to be deleted.
- @return id for accessing the deleted data source later. -1 if no free id existed or an error occured
+ @return id for accessing the deleted data source later. -1 if no free id existed or an error occurred
*/
sal_Int32 markDeleted(const ::rtl::OUString& _rName);
@@ -272,3 +263,4 @@ namespace dbaui
#endif // DBAUI_DATASOURCEMAP_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dbadmin.hxx b/dbaccess/source/ui/inc/dbadmin.hxx
index 012edecee040..a01314d188c1 100644
--- a/dbaccess/source/ui/inc/dbadmin.hxx
+++ b/dbaccess/source/ui/inc/dbadmin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,11 @@
#ifndef _DBAUI_DBADMIN_HXX_
#define _DBAUI_DBADMIN_HXX_
-#ifndef _SFXTABDLG_HXX
+#include <sal/macros.h>
#include <sfx2/tabdlg.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef DBAUI_ITEMSETHELPER_HXX
#include "IItemSetHelper.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
#include <memory>
FORWARD_DECLARE_INTERFACE(beans,XPropertySet)
@@ -129,7 +123,7 @@ private:
{
AR_LEAVE_MODIFIED, // somthing was modified and has successfully been committed
AR_LEAVE_UNCHANGED, // no changes were made
- AR_KEEP // don't leave the page (e.g. because an error occured)
+ AR_KEEP // don't leave the page (e.g. because an error occurred)
};
/** apply all changes made
*/
@@ -142,3 +136,4 @@ private:
#endif // _DBAUI_DBADMIN_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dbexchange.hxx b/dbaccess/source/ui/inc/dbexchange.hxx
index 7d7d0bf8cab0..29a8c3c2867e 100644
--- a/dbaccess/source/ui/inc/dbexchange.hxx
+++ b/dbaccess/source/ui/inc/dbexchange.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,14 @@
#ifndef DBAUI_DBEXCHANGE_HXX
#define DBAUI_DBEXCHANGE_HXX
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XEVENTLISTENER_HPP_
#include <com/sun/star/lang/XEventListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _SVX_DBAEXCHANGE_HXX_
#include <svx/dbaexchange.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
#include <vector>
#include <rtl/ref.hxx>
@@ -111,3 +96,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dbtreelistbox.hxx b/dbaccess/source/ui/inc/dbtreelistbox.hxx
index fb32fc665e23..86e8ee277226 100644
--- a/dbaccess/source/ui/inc/dbtreelistbox.hxx
+++ b/dbaccess/source/ui/inc/dbtreelistbox.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -165,3 +166,5 @@ namespace dbaui
}
#endif // DBAUI_DBTREELISTBOX_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dbu_resource.hrc b/dbaccess/source/ui/inc/dbu_resource.hrc
index 730235b207ad..7ba85bc6dfcb 100644
--- a/dbaccess/source/ui/inc/dbu_resource.hrc
+++ b/dbaccess/source/ui/inc/dbu_resource.hrc
@@ -249,48 +249,23 @@
// free
// free
#define IMG_PKEYICON RID_IMAGE_START + 12
-#define REPORTFOLDER_TREE_ICON_SCH RID_IMAGE_START + 13
-#define FORMFOLDER_TREE_ICON_SCH RID_IMAGE_START + 14
-#define IMG_DATABASE_CONNECTED RID_IMAGE_START + 15
-#define QUERYFOLDER_TREE_ICON_SCH RID_IMAGE_START + 16
-#define TABLEFOLDER_TREE_ICON_SCH RID_IMAGE_START + 17
// free
-#define DATABASE_TREE_ICON_SCH RID_IMAGE_START + 19
-#define IMG_DATABASE_CONNECTED_SCH RID_IMAGE_START + 20
-#define TABLE_TREE_ICON_SCH RID_IMAGE_START + 21
-#define VIEW_TREE_ICON_SCH RID_IMAGE_START + 22
-#define QUERY_TREE_ICON_SCH RID_IMAGE_START + 23
-#define REPORTFOLDER_TREE_ICON RID_IMAGE_START + 24
// free
+#define IMG_DATABASE_CONNECTED RID_IMAGE_START + 15
// free
+// ...
// free
-#define BMP_EXCEPTION_ERROR_SCH RID_IMAGE_START + 28
-#define BMP_EXCEPTION_WARNING_SCH RID_IMAGE_START + 29
-#define BMP_EXCEPTION_INFO_SCH RID_IMAGE_START + 30
-#define IMG_PKEYICON_SCH RID_IMAGE_START + 31
-#define IMG_JOINS_H RID_IMAGE_START + 32
-#define IMG_ALL_LEFT_H RID_IMAGE_START + 33
-#define IMG_ONE_LEFT_H RID_IMAGE_START + 34
-#define IMG_ONE_RIGHT_H RID_IMAGE_START + 35
-#define IMG_ALL_RIGHT_H RID_IMAGE_START + 36
-#define IMG_SORTUP_H RID_IMAGE_START + 37
-#define IMG_SORTDOWN_H RID_IMAGE_START + 38
+#define REPORTFOLDER_TREE_ICON RID_IMAGE_START + 24
#define IMG_FORMFOLDER_TREE_L RID_IMAGE_START + 39
#define IMG_REPORTFOLDER_TREE_L RID_IMAGE_START + 40
#define IMG_QUERYFOLDER_TREE_L RID_IMAGE_START + 41
#define IMG_TABLEFOLDER_TREE_L RID_IMAGE_START + 42
-#define IMG_FORMFOLDER_TREE_LHC RID_IMAGE_START + 43
-#define IMG_REPORTFOLDER_TREE_LHC RID_IMAGE_START + 44
-#define IMG_QUERYFOLDER_TREE_LHC RID_IMAGE_START + 45
-#define IMG_TABLEFOLDER_TREE_LHC RID_IMAGE_START + 46
#define IMG_NAVIGATION_BTN_UP_SC RID_IMAGE_START + 47
-#define IMG_NAVIGATION_BTN_UP_SCH RID_IMAGE_START + 48
#define IMG_NAVIGATION_CREATEFOLDER_SC RID_IMAGE_START + 49
-#define IMG_NAVIGATION_CREATEFOLDER_SCH RID_IMAGE_START + 50
#define FORM_TREE_ICON RID_IMAGE_START + 51
#define REPORT_TREE_ICON RID_IMAGE_START + 52
-#define FORM_TREE_ICON_SCH RID_IMAGE_START + 53
-#define REPORT_TREE_ICON_SCH RID_IMAGE_START + 54
+// free
+// free
#define FORMFOLDER_TREE_ICON RID_IMAGE_START + 55
@@ -298,17 +273,17 @@
// image lists
#define IMG_JOINS RID_IMAGELIST_START + 0
#define IMG_INDEX_DLG_SC RID_IMAGELIST_START + 1
-#define IMG_INDEX_DLG_SCH RID_IMAGELIST_START + 2
+// free
#define IMG_INDEX_DLG_LC RID_IMAGELIST_START + 3
-#define IMG_INDEX_DLG_LCH RID_IMAGELIST_START + 4
+// free
#define IMP_FORM_SC RID_IMAGELIST_START + 5
-#define IMP_FORM_SCH RID_IMAGELIST_START + 6
+// free
#define IMP_FORM_LC RID_IMAGELIST_START + 7
-#define IMP_FORM_LCH RID_IMAGELIST_START + 8
+// free
#define IMP_REPORT_SC RID_IMAGELIST_START + 9
-#define IMP_REPORT_SCH RID_IMAGELIST_START + 10
+// free
#define IMP_REPORT_LC RID_IMAGELIST_START + 11
-#define IMP_REPORT_LCH RID_IMAGELIST_START + 12
+// free
//========================================================================
// menues
@@ -353,7 +328,7 @@
#define STR_TABLEDESIGN_DBFIELDTYPES RID_STR_GEN_START + 8
#define STR_QRY_CONTINUE RID_STR_GEN_START + 9
#define STR_COLUMN_NAME RID_STR_GEN_START + 10
-#define STR_ERROR_OCCURED_WHILE_COPYING RID_STR_GEN_START + 11
+#define STR_ERROR_OCCURRED_WHILE_COPYING RID_STR_GEN_START + 11
#define STR_MISSING_TABLES_XDROP RID_STR_GEN_START + 12
#define STR_QUERY_DELETE_TABLE RID_STR_GEN_START + 13
#define STR_BUTTON_TEXT_ALL RID_STR_GEN_START + 14
@@ -393,17 +368,17 @@
// free
#define RSC_QUERY_OBJECT_TYPE RID_UNTYPED_START + 4
#define IMG_TABLESUBCRIPTION_SC RID_UNTYPED_START + 5
-#define IMG_TABLESUBCRIPTION_SCH RID_UNTYPED_START + 6
+// free
#define IMG_TABLESUBCRIPTION_LC RID_UNTYPED_START + 7
-#define IMG_TABLESUBCRIPTION_LCH RID_UNTYPED_START + 8
+// free
#define IMG_QUERYADMINISTRATION_SC RID_UNTYPED_START + 9
-#define IMG_QUERYADMINISTRATION_SCH RID_UNTYPED_START + 10
+// free
#define IMG_QUERYADMINISTRATION_LC RID_UNTYPED_START + 11
-#define IMG_QUERYADMINISTRATION_LCH RID_UNTYPED_START + 12
+// free
#define IMG_DOCUMENTLINKS_SC RID_UNTYPED_START + 13
-#define IMG_DOCUMENTLINKS_SCH RID_UNTYPED_START + 14
+// free
#define IMG_DOCUMENTLINKS_LC RID_UNTYPED_START + 15
-#define IMG_DOCUMENTLINKS_LCH RID_UNTYPED_START + 16
+// free
//========================================================================
// various
diff --git a/dbaccess/source/ui/inc/dbwiz.hxx b/dbaccess/source/ui/inc/dbwiz.hxx
index 94b3fd683336..414a3a0b5108 100644
--- a/dbaccess/source/ui/inc/dbwiz.hxx
+++ b/dbaccess/source/ui/inc/dbwiz.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
#ifndef DBAUI_DBWIZ_HXX
#define DBAUI_DBWIZ_HXX
-#ifndef _SFXTABDLG_HXX
#include <sfx2/tabdlg.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef DBAUI_ITEMSETHELPER_HXX
#include "IItemSetHelper.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _SVTOOLS_WIZARDMACHINE_HXX_
#include <svtools/wizardmachine.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
#include <memory>
FORWARD_DECLARE_INTERFACE(beans,XPropertySet)
@@ -127,7 +116,7 @@ protected:
{
AR_LEAVE_MODIFIED, // somthing was modified and has successfully been committed
AR_LEAVE_UNCHANGED, // no changes were made
- AR_KEEP // don't leave the page (e.g. because an error occured)
+ AR_KEEP // don't leave the page (e.g. because an error occurred)
};
/** apply all changes made
*/
@@ -143,3 +132,4 @@ private:
#endif // DBAUI_DBWIZ_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dbwizsetup.hxx b/dbaccess/source/ui/inc/dbwizsetup.hxx
index 039fc64392de..a6b4db6b6b02 100644
--- a/dbaccess/source/ui/inc/dbwizsetup.hxx
+++ b/dbaccess/source/ui/inc/dbwizsetup.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,31 +29,15 @@
#ifndef DBAUI_DBWIZ2_HXX
#define DBAUI_DBWIZ2_HXX
-#ifndef _SFXTABDLG_HXX
#include <sfx2/tabdlg.hxx>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef DBAUI_ITEMSETHELPER_HXX
#include "IItemSetHelper.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
#include <memory>
-#ifndef SVTOOLS_INC_ROADMAPWIZARD_HXX
#include <svtools/roadmapwizard.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
FORWARD_DECLARE_INTERFACE(beans,XPropertySet)
FORWARD_DECLARE_INTERFACE(sdbc,XConnection)
@@ -164,7 +149,7 @@ protected:
{
AR_LEAVE_MODIFIED, // somthing was modified and has successfully been committed
AR_LEAVE_UNCHANGED, // no changes were made
- AR_KEEP // don't leave the page (e.g. because an error occured)
+ AR_KEEP // don't leave the page (e.g. because an error occurred)
};
private:
@@ -209,3 +194,4 @@ private:
#endif // DBAUI_DBWIZ2_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/defaultobjectnamecheck.hxx b/dbaccess/source/ui/inc/defaultobjectnamecheck.hxx
index 41bee7ef3bfb..c84b1dcdfd69 100644
--- a/dbaccess/source/ui/inc/defaultobjectnamecheck.hxx
+++ b/dbaccess/source/ui/inc/defaultobjectnamecheck.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,20 +29,12 @@
#ifndef DBACCESS_SOURCE_UI_INC_DEFAULTOBJECTNAMECHECK_HXX
#define DBACCESS_SOURCE_UI_INC_DEFAULTOBJECTNAMECHECK_HXX
-#ifndef DBACCESS_SOURCE_UI_INC_OBJECTNAMECHECK_HXX
#include "objectnamecheck.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMEACCESS_HPP_
#include <com/sun/star/container/XHierarchicalNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
/** === end UNO includes === **/
#include <memory>
@@ -150,3 +143,4 @@ namespace dbaui
#endif // DBACCESS_SOURCE_UI_INC_DEFAULTOBJECTNAMECHECK_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/directsql.hxx b/dbaccess/source/ui/inc/directsql.hxx
index 2299d8a4656e..250c667166be 100644
--- a/dbaccess/source/ui/inc/directsql.hxx
+++ b/dbaccess/source/ui/inc/directsql.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,38 +29,18 @@
#ifndef _DBACCESS_UI_DIRECTSQL_HXX_
#define _DBACCESS_UI_DIRECTSQL_HXX_
-#ifndef _SV_DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
-#ifndef _SVEDIT_HXX
#include <svtools/editsyntaxhighlighter.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
#include <deque>
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _UNOTOOLS_EVENTLISTENERADAPTER_HXX_
#include <unotools/eventlisteneradapter.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
//........................................................................
namespace dbaui
@@ -145,7 +126,7 @@ namespace dbaui
{ \
const sal_Char* pError = impl_CheckInvariants(); \
if (pError) \
- OSL_ENSURE(sal_False, (ByteString(methodname) += ByteString(": ") += ByteString(pError)).GetBuffer()); \
+ OSL_FAIL((ByteString(methodname) += ByteString(": ") += ByteString(pError)).GetBuffer()); \
}
#else
#define CHECK_INVARIANTS(methodname)
@@ -157,3 +138,4 @@ namespace dbaui
#endif // _DBACCESS_UI_DIRECTSQL_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dlgattr.hxx b/dbaccess/source/ui/inc/dlgattr.hxx
index 968636286133..e4fe6e158c96 100644
--- a/dbaccess/source/ui/inc/dlgattr.hxx
+++ b/dbaccess/source/ui/inc/dlgattr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,10 @@
#define DBAUI_SBATTRDLG_HXX
-#ifndef DBAUI_SBATTRDLG_HRC
#include "dlgattr.hrc"
-#endif
-#ifndef _SFXTABDLG_HXX //autogen
#include <sfx2/tabdlg.hxx>
-#endif
-#ifndef _SOLAR_H
#include <tools/solar.h>
-#endif
@@ -66,3 +61,4 @@ namespace dbaui
#endif//DBAUI_SBATTRDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dlgsave.hxx b/dbaccess/source/ui/inc/dlgsave.hxx
index 080ced79a0d9..315aad0e7aa5 100644
--- a/dbaccess/source/ui/inc/dlgsave.hxx
+++ b/dbaccess/source/ui/inc/dlgsave.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef DBAUI_DLGSAVE_HXX
#define DBAUI_DLGSAVE_HXX
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
namespace com { namespace sun { namespace star {
namespace container {
@@ -103,3 +96,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dlgsize.hxx b/dbaccess/source/ui/inc/dlgsize.hxx
index dc616ba47df6..7b2e0152d226 100644
--- a/dbaccess/source/ui/inc/dlgsize.hxx
+++ b/dbaccess/source/ui/inc/dlgsize.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,13 @@
#ifndef _DBAUI_DLGSIZE_HXX
#define _DBAUI_DLGSIZE_HXX
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _FIELD_HXX //autogen
#include <vcl/field.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
//.........................................................................
namespace dbaui
@@ -76,3 +69,4 @@ namespace dbaui
#endif // _DBAUI_DLGSIZE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dsitems.hxx b/dbaccess/source/ui/inc/dsitems.hxx
index a29e2201f370..d54cf88e4a94 100644
--- a/dbaccess/source/ui/inc/dsitems.hxx
+++ b/dbaccess/source/ui/inc/dsitems.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -105,3 +106,4 @@ typedef sal_Int32 ItemID;
#endif // _DBAUI_DATASOURCEITEMS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/dsmeta.hxx b/dbaccess/source/ui/inc/dsmeta.hxx
index 9d1275e073ff..8f7b4f4f1283 100644
--- a/dbaccess/source/ui/inc/dsmeta.hxx
+++ b/dbaccess/source/ui/inc/dsmeta.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -142,3 +143,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_DSMETA_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/exsrcbrw.hxx b/dbaccess/source/ui/inc/exsrcbrw.hxx
index 5fbdfed65953..34b6e96ec86d 100644
--- a/dbaccess/source/ui/inc/exsrcbrw.hxx
+++ b/dbaccess/source/ui/inc/exsrcbrw.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -110,3 +111,5 @@ namespace dbaui
}
#endif // _SBA_EXTCTRLR_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/formadapter.hxx b/dbaccess/source/ui/inc/formadapter.hxx
index f4d91540a1b3..f85cc2bd62e9 100644
--- a/dbaccess/source/ui/inc/formadapter.hxx
+++ b/dbaccess/source/ui/inc/formadapter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,121 +29,45 @@
#ifndef _SBA_FORMADAPTER_HXX
#define _SBA_FORMADAPTER_HXX
-#ifndef _SBA_MULTIPLEX_HXX
#include "sbamultiplex.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPARAMETERS_HPP_
#include <com/sun/star/sdbc/XParameters.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCOLUMNLOCATE_HPP_
#include <com/sun/star/sdbc/XColumnLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCLOSEABLE_HPP_
#include <com/sun/star/sdbc/XCloseable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XROWLOCATE_HPP_
#include <com/sun/star/sdbcx/XRowLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWUPDATE_HPP_
#include <com/sun/star/sdbc/XRowUpdate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETUPDATE_HPP_
#include <com/sun/star/sdbc/XResultSetUpdate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWSET_HPP_
#include <com/sun/star/sdbc/XRowSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDELETEROWS_HPP_
#include <com/sun/star/sdbcx/XDeleteRows.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XWARNINGSSUPPLIER_HPP_
#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XSQLERRORBROADCASTER_HPP_
#include <com/sun/star/sdb/XSQLErrorBroadcaster.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XROWSETAPPROVEBROADCASTER_HPP_
#include <com/sun/star/sdb/XRowSetApproveBroadcaster.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XLOADABLE_HPP_
#include <com/sun/star/form/XLoadable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XRESULTSETACCESS_HPP_
#include <com/sun/star/sdb/XResultSetAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XFORM_HPP_
#include <com/sun/star/form/XForm.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XMULTIPROPERTYSET_HPP_
#include <com/sun/star/beans/XMultiPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XFASTPROPERTYSET_HPP_
#include <com/sun/star/beans/XFastPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXCONTAINER_HPP_
#include <com/sun/star/container/XIndexContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XRESET_HPP_
#include <com/sun/star/form/XReset.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XSUBMIT_HPP_
#include <com/sun/star/form/XSubmit.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XDATABASEPARAMETERBROADCASTER_HPP_
#include <com/sun/star/form/XDatabaseParameterBroadcaster.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XENUMERATIONACCESS_HPP_
#include <com/sun/star/container/XEnumerationAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSTATE_HPP_
#include <com/sun/star/beans/XPropertyState.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XTABCONTROLLERMODEL_HPP_
#include <com/sun/star/awt/XTabControllerModel.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XPERSISTOBJECT_HPP_
#include <com/sun/star/io/XPersistObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMED_HPP_
#include <com/sun/star/container/XNamed.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XCANCELLABLE_HPP_
#include <com/sun/star/util/XCancellable.hpp>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE12_HXX_
#include <cppuhelper/implbase12.hxx>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE10_HXX_
#include <cppuhelper/implbase10.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
namespace dbaui
{
@@ -521,3 +446,4 @@ namespace dbaui
}
#endif // _SBA_FORMADAPTER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/imageprovider.hxx b/dbaccess/source/ui/inc/imageprovider.hxx
index bbc0ccced557..e3b5489203b0 100644
--- a/dbaccess/source/ui/inc/imageprovider.hxx
+++ b/dbaccess/source/ui/inc/imageprovider.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,17 +29,11 @@
#ifndef DBACCESS_IMAGEPROVIDER_HXX
#define DBACCESS_IMAGEPROVIDER_HXX
-#ifndef _SV_IMAGE_HXX
#include <vcl/image.hxx>
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_DATABASEOBJECT_HPP_
#include <com/sun/star/sdb/application/DatabaseObject.hpp>
-#endif
/** === end UNO includes === **/
#include <boost/shared_ptr.hpp>
@@ -92,16 +87,13 @@ namespace dbaui
the name of the object
@param _out_rImage
the normal image to use for the object
- @param _out_rImageHC
- the high-contrast version of the image to use for the object
@return
the image to be used for the object.
*/
void getImages(
const String& _rName,
const sal_Int32 _nDatabaseObjectType,
- Image& _out_rImage,
- Image& _out_rImageHC
+ Image& _out_rImage
);
/** returns the default image to be used for a database object
@@ -113,18 +105,11 @@ namespace dbaui
@param _nDatabaseObjectType
the type of the object. Must be one of the css.sdb.application.DatabaseObject
constants.
- @param _bHighContrast
- indicates whether High-Contrast icons should be used.
- Note that normally, this would be some application-wide setting. However,
- in current OOo, HC support is decided on a per-control basis, means every
- control decides itself whether its images must be HC versions or not.
- Thus callers need to specify this flag.
@return
the image to be used for the object type.
*/
Image getDefaultImage(
- sal_Int32 _nDatabaseObjectType,
- bool _bHighContrast
+ sal_Int32 _nDatabaseObjectType
);
/** returns the resource ID for the default image to be used for a database object
@@ -136,19 +121,12 @@ namespace dbaui
@param _nDatabaseObjectType
the type of the object. Must be one of the css.sdb.application.DatabaseObject
constants.
- @param _bHighContrast
- indicates whether High-Contrast icons should be used.
- Note that normally, this would be some application-wide setting. However,
- in current OOo, HC support is decided on a per-control basis, means every
- control decides itself whether its images must be HC versions or not.
- Thus callers need to specify this flag.
@return
the resource ID image to be used for the object type. Must be fed into a
ModuleRes instance to actually load the image.
*/
sal_uInt16 getDefaultImageResourceID(
- sal_Int32 _nDatabaseObjectType,
- bool _bHighContrast
+ sal_Int32 _nDatabaseObjectType
);
/** retrieves the image to be used for folders of database objects
@@ -157,31 +135,18 @@ namespace dbaui
constants.
@param _rName
the name of the object
- @param _bHighContrast
- indicates whether High-Contrast icons should be used.
- Note that normally, this would be some application-wide setting. However,
- in current OOo, HC support is decided on a per-control basis, means every
- control decides itself whether its images must be HC versions or not.
- Thus callers need to specify this flag.
@return
the image to be used for folders of the given type
*/
Image getFolderImage(
- sal_Int32 _nDatabaseObjectType,
- bool _bHighContrast
+ sal_Int32 _nDatabaseObjectType
);
/** retrieves the image to be used for a database as a whole.
- @param _bHighContrast
- indicates whether High-Contrast icons should be used.
- Note that normally, this would be some application-wide setting. However,
- in current OOo, HC support is decided on a per-control basis, means every
- control decides itself whether its images must be HC versions or not.
- Thus callers need to specify this flag.
@return
the image to be used for folders of this type
*/
- Image getDatabaseImage( bool _bHighContrast );
+ Image getDatabaseImage();
};
//........................................................................
@@ -190,3 +155,4 @@ namespace dbaui
#endif // DBACCESS_IMAGEPROVIDER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/indexcollection.hxx b/dbaccess/source/ui/inc/indexcollection.hxx
index ac7ea0f6c2a6..7e01de118b72 100644
--- a/dbaccess/source/ui/inc/indexcollection.hxx
+++ b/dbaccess/source/ui/inc/indexcollection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef _DBAUI_INDEXCOLLECTION_HXX_
#define _DBAUI_INDEXCOLLECTION_HXX_
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLEXCEPTION_HPP_
#include <com/sun/star/sdbc/SQLException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _DBAUI_INDEXES_HXX_
#include "indexes.hxx"
-#endif
//......................................................................
namespace dbaui
@@ -123,3 +116,4 @@ namespace dbaui
#endif // _DBAUI_INDEXCOLLECTION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/indexdialog.hxx b/dbaccess/source/ui/inc/indexdialog.hxx
index 7faad262ddd3..10839459626b 100644
--- a/dbaccess/source/ui/inc/indexdialog.hxx
+++ b/dbaccess/source/ui/inc/indexdialog.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,45 +29,19 @@
#ifndef _DBAUI_INDEXDIALOG_HXX_
#define _DBAUI_INDEXDIALOG_HXX_
-#ifndef _SV_DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _SV_TOOLBOX_HXX
#include <vcl/toolbox.hxx>
-#endif
-#ifndef _SVTREEBOX_HXX
#include <svtools/svtreebx.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_VIEWOPTIONS_HXX
#include <unotools/viewoptions.hxx>
-#endif
-#ifndef _DBAUI_INDEXES_HXX_
#include "indexes.hxx"
-#endif
-#ifndef DBAUI_TOOLBOXHELPER_HXX
#include "ToolBoxHelper.hxx"
-#endif
//......................................................................
namespace dbaui
@@ -161,7 +136,7 @@ namespace dbaui
@param _bHiContast
<TRUE/> when in high contrast mode.
*/
- virtual ImageList getImageList(sal_Int16 _eBitmapSet,sal_Bool _bHiContast) const;
+ virtual ImageList getImageList(sal_Int16 _eBitmapSet) const;
/** will be called when the controls need to be resized.
*/
@@ -207,3 +182,4 @@ namespace dbaui
#endif // _DBAUI_INDEXDIALOG_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/indexes.hxx b/dbaccess/source/ui/inc/indexes.hxx
index a1eda99c4f7f..18e8f4ff0b5c 100644
--- a/dbaccess/source/ui/inc/indexes.hxx
+++ b/dbaccess/source/ui/inc/indexes.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef _DBAUI_INDEXES_HXX_
#define _DBAUI_INDEXES_HXX_
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
//......................................................................
namespace dbaui
@@ -105,3 +102,4 @@ namespace dbaui
#endif // _DBAUI_INDEXES_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/indexfieldscontrol.hxx b/dbaccess/source/ui/inc/indexfieldscontrol.hxx
index 634a19cc0f42..d3802b03746d 100644
--- a/dbaccess/source/ui/inc/indexfieldscontrol.hxx
+++ b/dbaccess/source/ui/inc/indexfieldscontrol.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef _DBAUI_INDEXFIELDSCONTROL_HXX_
#define _DBAUI_INDEXFIELDSCONTROL_HXX_
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _SVTOOLS_EDITBROWSEBOX_HXX_
#include <svtools/editbrowsebox.hxx>
-#endif
-#ifndef _DBAUI_INDEXCOLLECTION_HXX_
#include "indexcollection.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
//......................................................................
namespace dbaui
@@ -116,3 +109,4 @@ namespace dbaui
#endif // _DBAUI_INDEXFIELDSCONTROL_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/linkeddocuments.hxx b/dbaccess/source/ui/inc/linkeddocuments.hxx
index 3c1b574d3300..84609bb1e5d2 100644
--- a/dbaccess/source/ui/inc/linkeddocuments.hxx
+++ b/dbaccess/source/ui/inc/linkeddocuments.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,38 +31,18 @@
#include "AppElementType.hxx"
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XCOMPONENT_HPP_
#include <com/sun/star/lang/XComponent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
#include <com/sun/star/frame/XFrame.hpp>
-#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_
#include <com/sun/star/frame/XComponentLoader.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_
#include <com/sun/star/ucb/XContent.hpp>
-#endif
#include <com/sun/star/sdb/application/XDatabaseDocumentUI.hpp>
-#ifndef _LINK_HXX
#include <tools/link.hxx>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef COMPHELPER_NAMEDVALUECOLLECTION_HXX
#include <comphelper/namedvaluecollection.hxx>
-#endif
class Window;
//......................................................................
@@ -157,3 +138,4 @@ namespace dbaui
#endif // _DBAUI_LINKEDDOCUMENTS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/listviewitems.hxx b/dbaccess/source/ui/inc/listviewitems.hxx
index c19854e38afc..3cf5ba748681 100644
--- a/dbaccess/source/ui/inc/listviewitems.hxx
+++ b/dbaccess/source/ui/inc/listviewitems.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef _DBAUI_LISTVIEWITEMS_HXX_
#define _DBAUI_LISTVIEWITEMS_HXX_
-#ifndef _SVLBOXITM_HXX
#include <svtools/svlbitm.hxx>
-#endif
//........................................................................
namespace dbaui
@@ -68,3 +67,4 @@ namespace dbaui
#endif // _DBAUI_LISTVIEWITEMS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/localresaccess.hxx b/dbaccess/source/ui/inc/localresaccess.hxx
index 718ae8cdadde..9760ac354aac 100644
--- a/dbaccess/source/ui/inc/localresaccess.hxx
+++ b/dbaccess/source/ui/inc/localresaccess.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef _DBAUI_LOCALRESACCESS_HXX_
#define _DBAUI_LOCALRESACCESS_HXX_
-#ifndef _SVTOOLS_LOCALRESACCESS_HXX_
#include <svtools/localresaccess.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -62,3 +59,4 @@ public:
#endif // _DBAUI_LOCALRESACCESS_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/makefile.mk b/dbaccess/source/ui/inc/makefile.mk
deleted file mode 100644
index 5e1454d57f61..000000000000
--- a/dbaccess/source/ui/inc/makefile.mk
+++ /dev/null
@@ -1,43 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=dbaccess
-TARGET=dba_uiinc
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-LOCALIZE_ME=toolbox_tmpl.hrc
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/ui/inc/marktree.hxx b/dbaccess/source/ui/inc/marktree.hxx
index 70574312c3c1..cc5f10791b2f 100644
--- a/dbaccess/source/ui/inc/marktree.hxx
+++ b/dbaccess/source/ui/inc/marktree.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef _DBAUI_MARKTREE_HXX_
#define _DBAUI_MARKTREE_HXX_
-#ifndef DBAUI_DBTREELISTBOX_HXX
#include "dbtreelistbox.hxx"
-#endif
@@ -84,3 +83,4 @@ private:
#endif // _DBAUI_MARKTREE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/moduledbu.hxx b/dbaccess/source/ui/inc/moduledbu.hxx
index bfeeee749cf3..4297cdef693a 100644
--- a/dbaccess/source/ui/inc/moduledbu.hxx
+++ b/dbaccess/source/ui/inc/moduledbu.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,9 @@
#ifndef _DBAUI_MODULE_DBU_HXX_
#define _DBAUI_MODULE_DBU_HXX_
-#ifndef _OSL_MUTEX_HXX_
#include <osl/mutex.hxx>
-#endif
-#ifndef _TOOLS_RESID_HXX
#include <tools/resid.hxx>
-#endif
+#include <sal/macros.h>
class ResMgr;
@@ -105,3 +103,4 @@ public:
#endif // _DBAUI_MODULE_DBU_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/objectnamecheck.hxx b/dbaccess/source/ui/inc/objectnamecheck.hxx
index 5b9b95b83f63..144877d56d62 100644
--- a/dbaccess/source/ui/inc/objectnamecheck.hxx
+++ b/dbaccess/source/ui/inc/objectnamecheck.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,3 +73,5 @@ namespace dbaui
//........................................................................
#endif // DBACCESS_SOURCE_UI_INC_OBJECTNAMECHECK_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/opendoccontrols.hxx b/dbaccess/source/ui/inc/opendoccontrols.hxx
index 26957bbf8f70..b4c73bfb9521 100644
--- a/dbaccess/source/ui/inc/opendoccontrols.hxx
+++ b/dbaccess/source/ui/inc/opendoccontrols.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
#ifndef DBACCESS_SOURCE_UI_INC_OPENDOCCONTROLS_HXX
#define DBACCESS_SOURCE_UI_INC_OPENDOCCONTROLS_HXX
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
#include <map>
//........................................................................
@@ -97,3 +92,4 @@ namespace dbaui
#endif // DBACCESS_SOURCE_UI_INC_OPENDOCCONTROLS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/paramdialog.hxx b/dbaccess/source/ui/inc/paramdialog.hxx
index 8cb8c2c093aa..73d9107b6176 100644
--- a/dbaccess/source/ui/inc/paramdialog.hxx
+++ b/dbaccess/source/ui/inc/paramdialog.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,50 +29,22 @@
#ifndef _DBAUI_PARAMDIALOG_HXX_
#define _DBAUI_PARAMDIALOG_HXX_
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
-#ifndef _DIALOG_HXX
#include <vcl/dialog.hxx>
-#endif
-#ifndef _BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _EDIT_HXX
#include <vcl/edit.hxx>
-#endif
-#ifndef _SV_GROUP_HXX
#include <vcl/group.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef CONNECTIVITY_PREDICATEINPUT_HXX
#include <connectivity/predicateinput.hxx>
-#endif
-#ifndef SVX_QUERYDESIGNCONTEXT_HXX
#include "svx/ParseContext.hxx"
-#endif
namespace connectivity
{
@@ -150,3 +123,4 @@ namespace dbaui
#endif // _DBAUI_PARAMDIALOG_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/propertysetitem.hxx b/dbaccess/source/ui/inc/propertysetitem.hxx
index 9e1cd676a545..fa678989c06f 100644
--- a/dbaccess/source/ui/inc/propertysetitem.hxx
+++ b/dbaccess/source/ui/inc/propertysetitem.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef _DBAUI_PROPERTYSETITEM_HXX_
#define _DBAUI_PROPERTYSETITEM_HXX_
-#ifndef _SFXPOOLITEM_HXX
#include <svl/poolitem.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
//.........................................................................
namespace dbaui
@@ -69,3 +66,4 @@ namespace dbaui
#endif // _DBAUI_PROPERTYSETITEM_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/propertystorage.hxx b/dbaccess/source/ui/inc/propertystorage.hxx
index f60ab70d2c78..689e7998f6cf 100644
--- a/dbaccess/source/ui/inc/propertystorage.hxx
+++ b/dbaccess/source/ui/inc/propertystorage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -92,3 +93,5 @@ namespace dbaui
//........................................................................
#endif // PROPERTYSTORAGE_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/querycontainerwindow.hxx b/dbaccess/source/ui/inc/querycontainerwindow.hxx
index f2ecf7728a69..7146b8306cfb 100644
--- a/dbaccess/source/ui/inc/querycontainerwindow.hxx
+++ b/dbaccess/source/ui/inc/querycontainerwindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
#ifndef DBAUI_QUERYCONTAINERWINDOW_HXX
#define DBAUI_QUERYCONTAINERWINDOW_HXX
-#ifndef _SV_WINDOW_HXX
#include <vcl/window.hxx>
-#endif
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XFRAME_HPP_
#include <com/sun/star/frame/XFrame.hpp>
-#endif
-#ifndef DBAUI_QUERYVIEWSWITCH_HXX
#include "QueryViewSwitch.hxx"
-#endif
-#ifndef _SV_DOCKWIN_HXX
#include <vcl/dockwin.hxx>
-#endif
class FixedLine;
//.........................................................................
@@ -134,3 +123,4 @@ namespace dbaui
#endif // DBAUI_QUERYCONTAINERWINDOW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/querycontroller.hxx b/dbaccess/source/ui/inc/querycontroller.hxx
index 0e6f98e8304e..363c5517050e 100644
--- a/dbaccess/source/ui/inc/querycontroller.hxx
+++ b/dbaccess/source/ui/inc/querycontroller.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -257,3 +258,4 @@ namespace dbaui
}
#endif // DBAUI_QUERYCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/queryfilter.hxx b/dbaccess/source/ui/inc/queryfilter.hxx
index 944524ee6eba..2e4dd3c9e662 100644
--- a/dbaccess/source/ui/inc/queryfilter.hxx
+++ b/dbaccess/source/ui/inc/queryfilter.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,35 +29,19 @@
#ifndef DBAUI_QUERYFILTER_HXX
#define DBAUI_QUERYFILTER_HXX
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _EDIT_HXX //autogen
#include <vcl/edit.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _CONNECTIVITY_PARSE_SQLITERATOR_HXX_
#include <connectivity/sqliterator.hxx>
-#endif
-#ifndef CONNECTIVITY_PREDICATEINPUT_HXX
#include <connectivity/predicateinput.hxx>
-#endif
-#ifndef SVX_QUERYDESIGNCONTEXT_HXX
#include "svx/ParseContext.hxx"
-#endif
namespace rtl
{
@@ -161,3 +146,4 @@ namespace dbaui
#endif // DBAUI_QUERYFILTER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/queryorder.hxx b/dbaccess/source/ui/inc/queryorder.hxx
index 7bdd4733ebc6..86dc874197d8 100644
--- a/dbaccess/source/ui/inc/queryorder.hxx
+++ b/dbaccess/source/ui/inc/queryorder.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,25 +28,15 @@
#ifndef DBAUI_QUERYORDER_HXX
#define DBAUI_QUERYORDER_HXX
-#ifndef _DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _LSTBOX_HXX //autogen
#include <vcl/lstbox.hxx>
-#endif
-#ifndef _EDIT_HXX //autogen
#include <vcl/edit.hxx>
-#endif
-#ifndef _FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
#define DOG_ROWS 3
@@ -136,3 +127,4 @@ namespace dbaui
#endif // DBAUI_QUERYORDER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/queryview.hxx b/dbaccess/source/ui/inc/queryview.hxx
index 94ee49befe91..b1ead2c6c031 100644
--- a/dbaccess/source/ui/inc/queryview.hxx
+++ b/dbaccess/source/ui/inc/queryview.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_QUERYVIEW_HXX
#define DBAUI_QUERYVIEW_HXX
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
namespace dbaui
{
@@ -57,3 +56,5 @@ namespace dbaui
};
}
#endif // DBAUI_QUERYVIEW_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/sbagrid.hrc b/dbaccess/source/ui/inc/sbagrid.hrc
index c1478122dbf5..f10de1b90b68 100644
--- a/dbaccess/source/ui/inc/sbagrid.hrc
+++ b/dbaccess/source/ui/inc/sbagrid.hrc
@@ -29,24 +29,6 @@
#define DBACCESS_SBA_GRID_HRC
//----------------Menueitems-------------------------------------------------
-//#define SID_SBA_BRW_DELETEROWS (SID_SBA_START + 34) // Zeilen loeschen
-//#define SID_SBA_BRW_HIDECOL (SID_SBA_START + 35) // Spalten verstecken
-//#define SID_SBA_BRW_SHOWCOL (SID_SBA_START + 36) // Spalten wieder zeigen
-//#define SID_SBA_BRW_SHOWALLCOLS (SID_SBA_START + 37) // Alle Spalten wieder zeigen
-//#define SID_SBA_BRW_INSERTROWS (SID_SBA_START + 38) // Zeilen einfuegen
-//#define SID_SBA_BRW_DELETEROW (SID_SBA_START + 39) // Zeilen loeschen
-//#define SID_SBA_TABED_PRIMARYKEY (SID_SBA_START + 40) // Primary key vergeben
-//#define SID_QRY_FUNCTION (SID_SBA_START + 41) // Funktionen anzeigen
-//#define SID_QRY_TABLENAME (SID_SBA_START + 42) // Tabellennamen anzeigen
-//#define SID_QRY_ALIASNAME (SID_SBA_START + 43) // Aliasnamen anzeigen
-//#define SID_QRY_DISTINCT (SID_SBA_START + 44) // Distinct anzeigen
-//#define SID_TBL_SORT_ASC (SID_SBA_START + 45) // Aufsteigen Sortieren
-//#define SID_TBL_SORT_DESC (SID_SBA_START + 46) // Absteigen Sortieren
-
-//#define SID_DBSTATE_ACTUALIZE (SID_SBA_START + 48) // actualize dbstate
-//#define SID_DBSTATE_SHUTDOWN (SID_SBA_START + 49) // shutdown db
-//#define SID_DBSTATE_RESTART (SID_SBA_START + 50) // restart db
-
// Tabelle
#define SBA_WHICHID_START 100
// Zeilenhoehe
diff --git a/dbaccess/source/ui/inc/sbagrid.hxx b/dbaccess/source/ui/inc/sbagrid.hxx
index 04cbd9afbf8b..0d3dc746fa2b 100644
--- a/dbaccess/source/ui/inc/sbagrid.hxx
+++ b/dbaccess/source/ui/inc/sbagrid.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,37 +29,17 @@
#ifndef _SBA_GRID_HXX
#define _SBA_GRID_HXX
-// #include <sdb/tools.hxx>
-
-#ifndef _SVX_FMGRIDCL_HXX
#include <svx/fmgridcl.hxx>
-#endif
-#ifndef _SVX_FMGRIDIF_HXX
#include <svx/fmgridif.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSQLQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSQLQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCH_HPP_
#include <com/sun/star/frame/XDispatch.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_URL_HPP_
#include <com/sun/star/util/URL.hpp>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _SBA_MULTIPLEX_HXX
#include "sbamultiplex.hxx"
-#endif
-#ifndef _SVX_DATACCESSDESCRIPTOR_HXX_
#include <svx/dataaccessdescriptor.hxx>
-#endif
#include <queue>
class SvNumberFormatter;
@@ -361,3 +342,4 @@ namespace dbaui
}
#endif // _SBA_GRID_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/sbamultiplex.hxx b/dbaccess/source/ui/inc/sbamultiplex.hxx
index f003dfaae5ef..0fe8ba96aae6 100644
--- a/dbaccess/source/ui/inc/sbamultiplex.hxx
+++ b/dbaccess/source/ui/inc/sbamultiplex.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,82 +29,30 @@
#ifndef _SBA_MULTIPLEX_HXX
#define _SBA_MULTIPLEX_HXX
-//#ifndef _SDB_TOOLS_HXX
-//#include <sdb/tools.hxx>
-//#endif
-
-#ifndef _COM_SUN_STAR_BEANS_XVETOABLECHANGELISTENER_HPP_
#include <com/sun/star/beans/XVetoableChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XUPDATELISTENER_HPP_
#include <com/sun/star/form/XUpdateListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XERRORLISTENER_HPP_
#include <com/sun/star/form/XErrorListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XRESTORELISTENER_HPP_
#include <com/sun/star/form/XRestoreListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XINSERTLISTENER_HPP_
#include <com/sun/star/form/XInsertListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XDELETELISTENER_HPP_
#include <com/sun/star/form/XDeleteListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XPOSITIONINGLISTENER_HPP_
#include <com/sun/star/form/XPositioningListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XDATABASEPARAMETERLISTENER_HPP_
#include <com/sun/star/form/XDatabaseParameterListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XLOADLISTENER_HPP_
#include <com/sun/star/form/XLoadListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSTATECHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertyStateChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTIESCHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertiesChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYCHANGELISTENER_HPP_
#include <com/sun/star/beans/XPropertyChangeListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XSUBMITLISTENER_HPP_
#include <com/sun/star/form/XSubmitListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FORM_XRESETLISTENER_HPP_
#include <com/sun/star/form/XResetListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XREFRESHLISTENER_HPP_
#include <com/sun/star/util/XRefreshListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XSQLERRORLISTENER_HPP_
#include <com/sun/star/sdb/XSQLErrorListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XROWSETAPPROVELISTENER_HPP_
#include <com/sun/star/sdb/XRowSetApproveListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWSETLISTENER_HPP_
#include <com/sun/star/sdbc/XRowSetListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XSTATUSLISTENER_HPP_
#include <com/sun/star/frame/XStatusListener.hpp>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_
#include <cppuhelper/interfacecontainer.hxx>
-#endif
-#ifndef _CPPUHELPER_QUERYINTERFACE_HXX_
#include <cppuhelper/queryinterface.hxx>
-#endif
-#ifndef _CPPUHELPER_WEAK_HXX_
#include <cppuhelper/weak.hxx>
-#endif
namespace dbaui
{
@@ -486,3 +435,4 @@ namespace dbaui
#endif // _SBA_MULTIPLEXER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/singledoccontroller.hxx b/dbaccess/source/ui/inc/singledoccontroller.hxx
index c738bd94e81c..c738bd94e81c 100755..100644
--- a/dbaccess/source/ui/inc/singledoccontroller.hxx
+++ b/dbaccess/source/ui/inc/singledoccontroller.hxx
diff --git a/dbaccess/source/ui/inc/sqledit.hxx b/dbaccess/source/ui/inc/sqledit.hxx
index fb4f64c52c4f..2e98ce3ac3c6 100644
--- a/dbaccess/source/ui/inc/sqledit.hxx
+++ b/dbaccess/source/ui/inc/sqledit.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -87,3 +88,4 @@ namespace dbaui
#endif // DBAUI_SQLEDIT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/sqlmessage.hxx b/dbaccess/source/ui/inc/sqlmessage.hxx
index 2c8565191544..554310078fb2 100644
--- a/dbaccess/source/ui/inc/sqlmessage.hxx
+++ b/dbaccess/source/ui/inc/sqlmessage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,19 +29,11 @@
#ifndef _DBAUI_SQLMESSAGE_HXX_
#define _DBAUI_SQLMESSAGE_HXX_
-#ifndef _BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef _FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_BTNDLG_HXX
#include <vcl/btndlg.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
#include <memory>
@@ -141,3 +134,4 @@ public:
#endif // _DBAUI_SQLMESSAGE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/statusbarontroller.hxx b/dbaccess/source/ui/inc/statusbarontroller.hxx
index 7ae4212ad821..57d82d317605 100644
--- a/dbaccess/source/ui/inc/statusbarontroller.hxx
+++ b/dbaccess/source/ui/inc/statusbarontroller.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
#ifndef DBAUI_STATUSBARCONTROLLER_HXX
#define DBAUI_STATUSBARCONTROLLER_HXX
-#ifndef _SVTOOLS_STATUSBARCONTROLLER_HXX
#include <svtools/statusbarcontroller.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
namespace dbaui
{
@@ -60,3 +51,4 @@ namespace dbaui
}
#endif // DBAUI_STATUSBARCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/stringlistitem.hxx b/dbaccess/source/ui/inc/stringlistitem.hxx
index 5bdb2f78da5d..713026625d6f 100644
--- a/dbaccess/source/ui/inc/stringlistitem.hxx
+++ b/dbaccess/source/ui/inc/stringlistitem.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,16 +29,10 @@
#ifndef _DBAUI_STRINGLISTITEM_HXX_
#define _DBAUI_STRINGLISTITEM_HXX_
-#ifndef _SFXPOOLITEM_HXX
#include <svl/poolitem.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UNO_SEQUENCE_HXX_
#include <com/sun/star/uno/Sequence.hxx>
-#endif
-#ifndef _RTL_USTRING_HXX_
#include <rtl/ustring.hxx>
-#endif
//.........................................................................
namespace dbaui
@@ -70,3 +65,4 @@ public:
#endif // _DBAUI_STRINGLISTITEM_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/tabletree.hxx b/dbaccess/source/ui/inc/tabletree.hxx
index c23a128ddfdd..3b70a0324d46 100644
--- a/dbaccess/source/ui/inc/tabletree.hxx
+++ b/dbaccess/source/ui/inc/tabletree.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,28 +29,14 @@
#ifndef _DBAUI_TABLETREE_HXX_
#define _DBAUI_TABLETREE_HXX_
-#ifndef _DBAUI_MARKTREE_HXX_
#include "marktree.hxx"
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDRIVER_HPP_
#include <com/sun/star/sdbc/XDriver.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_NAMEDDATABASEOBJECT_HPP_
#include <com/sun/star/sdb/application/NamedDatabaseObject.hpp>
-#endif
#include <memory>
@@ -210,3 +197,4 @@ protected:
#endif // _DBAUI_TABLETREE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/textconnectionsettings.hxx b/dbaccess/source/ui/inc/textconnectionsettings.hxx
index a5c6b4ff95f0..dcda4a3acdb3 100644
--- a/dbaccess/source/ui/inc/textconnectionsettings.hxx
+++ b/dbaccess/source/ui/inc/textconnectionsettings.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -77,3 +78,5 @@ namespace dbaui
//........................................................................
#endif // TEXTCONNECTIONSETTINGS_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/toolboxcontroller.hxx b/dbaccess/source/ui/inc/toolboxcontroller.hxx
index d2bd25dc49fa..96ab7e3175d6 100644
--- a/dbaccess/source/ui/inc/toolboxcontroller.hxx
+++ b/dbaccess/source/ui/inc/toolboxcontroller.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
#ifndef DBACCESS_TOOLBOXCONTROLLER_HXX
#define DBACCESS_TOOLBOXCONTROLLER_HXX
-#ifndef _SVTOOLS_TOOLBOXCONTROLLER_HXX
#include <svtools/toolboxcontroller.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE1_HXX_
#include <cppuhelper/implbase1.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
#include <memory>
class PopupMenu;
@@ -83,3 +72,4 @@ namespace dbaui
//..........................................................................
#endif //DBACCESS_TOOLBOXCONTROLLER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/undosqledit.hxx b/dbaccess/source/ui/inc/undosqledit.hxx
index b81ff997ae8d..0bcbcdabe095 100644
--- a/dbaccess/source/ui/inc/undosqledit.hxx
+++ b/dbaccess/source/ui/inc/undosqledit.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_UNDOSQLEDIT_HXX
#define DBAUI_UNDOSQLEDIT_HXX
-#ifndef DBAUI_GENERALUNDO_HXX
#include "GeneralUndo.hxx"
-#endif
-#ifndef _DBU_CONTROL_HRC_
#include "dbu_control.hrc"
-#endif
namespace dbaui
{
@@ -59,3 +56,4 @@ namespace dbaui
#endif // DBAUI_UNDOSQLEDIT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/unoadmin.hxx b/dbaccess/source/ui/inc/unoadmin.hxx
index 2cedaa577d34..3ad794e9c52e 100644
--- a/dbaccess/source/ui/inc/unoadmin.hxx
+++ b/dbaccess/source/ui/inc/unoadmin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
#ifndef _DBAUI_UNOADMIN_
#define _DBAUI_UNOADMIN_
-#ifndef _SVT_GENERICUNODIALOG_HXX_
#include <svtools/genericunodialog.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _DBAUI_DSNTYPES_HXX_
#include "dsntypes.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
class SfxItemSet;
class SfxItemPool;
@@ -85,3 +78,4 @@ protected:
#endif // _DBAUI_UNOADMIN_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/unodatbr.hxx b/dbaccess/source/ui/inc/unodatbr.hxx
index bc4d99f6eda0..ad026e81c9f2 100644
--- a/dbaccess/source/ui/inc/unodatbr.hxx
+++ b/dbaccess/source/ui/inc/unodatbr.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,72 +29,28 @@
#ifndef _SBA_UNODATBR_HXX_
#define _SBA_UNODATBR_HXX_
-#ifndef _SBA_BWRCTRLR_HXX
#include "brwctrlr.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XSTATUSLISTENER_HPP_
#include <com/sun/star/frame/XStatusListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCH_HPP_
#include <com/sun/star/frame/XDispatch.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINERLISTENER_HPP_
#include <com/sun/star/container/XContainerListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_I18N_XCOLLATOR_HPP_
#include <com/sun/star/i18n/XCollator.hpp>
-#endif
-#ifndef _COM_SUN_STAR_VIEW_XSELECTIONSUPPLIER_HPP_
#include <com/sun/star/view/XSelectionSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_XWINDOW_HPP_
#include <com/sun/star/awt/XWindow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XSCRIPTINVOCATIONCONTEXT_HPP_
#include <com/sun/star/document/XScriptInvocationContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_XCONTEXTMENUINTERCEPTION_HPP_
#include <com/sun/star/ui/XContextMenuInterception.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_DATABASEOBJECT_HPP_
#include <com/sun/star/sdb/application/DatabaseObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_DATABASEOBJECTCONTAINER_HPP_
#include <com/sun/star/sdb/application/DatabaseObjectContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_DATABASEOBJECTCONTAINER_HPP_
#include <com/sun/star/sdb/XDatabaseRegistrationsListener.hpp>
-#endif
-#ifndef _CPPUHELPER_IMPLBASE5_HXX_
#include <cppuhelper/implbase5.hxx>
-#endif
-#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#include "callbacks.hxx"
-#endif
-#ifndef _SV_TIMER_HXX
#include <vcl/timer.hxx>
-#endif
-#ifndef _TRANSFER_HXX
#include <svtools/transfer.hxx>
-#endif
-#ifndef _SVX_DATACCESSDESCRIPTOR_HXX_
#include <svx/dataaccessdescriptor.hxx>
-#endif
-#ifndef _SOT_STORAGE_HXX
#include <sot/storage.hxx>
-#endif
-#ifndef DBUI_TABLECOPYHELPER_HXX
#include "TableCopyHelper.hxx"
-#endif
-#ifndef _DBAUI_COMMON_TYPES_HXX_
#include "commontypes.hxx"
-#endif
// =========================================================================
class SvLBoxEntry;
@@ -494,7 +451,7 @@ namespace dbaui
void* _pTreeListUserData // in rela a DBTreeListUserData*, but we do not know this class here ....
);
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
// checks whether the given tree entry denotes a data source
bool impl_isDataSourceEntry( SvLBoxEntry* _pEntry ) const;
#endif
@@ -514,9 +471,6 @@ namespace dbaui
// remove all grid columns and dispose them
void clearGridColumns(const ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameContainer >& _xColContainer);
- sal_Bool isHiContrast() const;
-
-
/** checks if the currently displayed entry changed
@param _sName
Name of the changed entry
@@ -543,3 +497,4 @@ namespace dbaui
#endif // _SBA_UNODATBR_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/inc/unosqlmessage.hxx b/dbaccess/source/ui/inc/unosqlmessage.hxx
index 49c1174f9cc9..0022ab64af77 100644
--- a/dbaccess/source/ui/inc/unosqlmessage.hxx
+++ b/dbaccess/source/ui/inc/unosqlmessage.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
#ifndef _DBAUI_UNOSQLMESSAGE_HXX_
#define _DBAUI_UNOSQLMESSAGE_HXX_
-#ifndef _SVT_GENERICUNODIALOG_HXX_
#include <svtools/genericunodialog.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
//.........................................................................
namespace dbaui
{
@@ -90,3 +87,4 @@ protected:
#endif // _DBAUI_UNOSQLMESSAGE_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/DExport.cxx b/dbaccess/source/ui/misc/DExport.cxx
index 9c2ae8256863..258c6c27e10f 100644
--- a/dbaccess/source/ui/misc/DExport.cxx
+++ b/dbaccess/source/ui/misc/DExport.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -55,6 +56,7 @@
#include "UITools.hxx"
#include <unotools/configmgr.hxx>
#include <memory>
+#include <o3tl/compat_functional.hxx>
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
#include <i18npool/mslangid.hxx>
@@ -289,7 +291,7 @@ ODatabaseExport::ODatabaseExport(const SharedConnection& _rxConnection,
break;
}
}
- } // if(xSet.is())
+ }
if ( !m_pTypeInfo )
m_pTypeInfo = TOTypeInfoSP(new OTypeInfo());
SetColumnTypes(pList,_pInfoMap);
@@ -325,20 +327,17 @@ void ODatabaseExport::insertValueIntoColumn()
sal_Int32 nPos = m_vColumns[nNewPos].first;
if ( nPos != COLUMN_POSITION_NOT_FOUND )
{
- // if(m_nDefToken != LANGUAGE_DONTKNOW) // falls Sprache anders als Systemsprache
- // m_pNF->ChangeIntl((LanguageType)m_nDefToken);
-
if ( !m_sTextToken.Len() && pField->IsNullable() )
m_pUpdateHelper->updateNull(nPos,pField->GetType());
else
{
- sal_Int32 nNumberFormat = 0;
- double fOutNumber = 0.0;
OSL_ENSURE((nNewPos) < static_cast<sal_Int32>(m_vColumnTypes.size()),"Illegal index for vector");
if (m_vColumnTypes[nNewPos] != DataType::VARCHAR && m_vColumnTypes[nNewPos] != DataType::CHAR && m_vColumnTypes[nNewPos] != DataType::LONGVARCHAR )
{
RTL_LOGFILE_CONTEXT_TRACE( aLogger, "ODatabaseExport::insertValueIntoColumn != DataType::VARCHAR" );
ensureFormatter();
+ sal_Int32 nNumberFormat = 0;
+ double fOutNumber = 0.0;
bool bNumberFormatError = false;
if ( m_pFormatter && m_sNumToken.Len() )
{
@@ -364,7 +363,7 @@ void ODatabaseExport::insertValueIntoColumn()
,NumberFormat::NUMBER
,NumberFormat::LOGICAL
};
- for (size_t i = 0; i < sizeof(nFormats)/sizeof(nFormats[0]); ++i)
+ for (size_t i = 0; i < SAL_N_ELEMENTS(nFormats); ++i)
{
try
{
@@ -562,7 +561,7 @@ sal_Int16 ODatabaseExport::CheckString(const String& aCheckToken, sal_Int16 _nOl
}
break;
default:
- OSL_ENSURE(0,"ODatabaseExport: Unbekanntes Format");
+ OSL_FAIL("ODatabaseExport: Unbekanntes Format");
}
}
}
@@ -790,7 +789,7 @@ void ODatabaseExport::showErrorDialog(const ::com::sun::star::sdbc::SQLException
m_bDontAskAgain = sal_True;
else
m_bError = sal_True;
- } // if(!m_bDontAskAgain)
+ }
}
// -----------------------------------------------------------------------------
void ODatabaseExport::adjustFormat()
@@ -872,7 +871,7 @@ Reference< XPreparedStatement > ODatabaseExport::createPreparedStatment( const R
for(sal_uInt32 j=0; j < aInsertList.size() ;++i,++j)
{
ODatabaseExport::TPositions::const_iterator aFind = ::std::find_if(_rvColumns.begin(),_rvColumns.end(),
- ::std::compose1(::std::bind2nd(::std::equal_to<sal_Int32>(),i+1),::std::select2nd<ODatabaseExport::TPositions::value_type>()));
+ ::o3tl::compose1(::std::bind2nd(::std::equal_to<sal_Int32>(),i+1),::o3tl::select2nd<ODatabaseExport::TPositions::value_type>()));
if ( _rvColumns.end() != aFind && aFind->second != sal::static_int_cast< long >(CONTAINER_ENTRY_NOTFOUND) && aFind->first != sal::static_int_cast< long >(CONTAINER_ENTRY_NOTFOUND) )
{
OSL_ENSURE((aFind->first) < static_cast<sal_Int32>(aInsertList.size()),"aInsertList: Illegal index for vector");
@@ -903,3 +902,4 @@ Reference< XPreparedStatement > ODatabaseExport::createPreparedStatment( const R
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/HtmlReader.cxx b/dbaccess/source/ui/misc/HtmlReader.cxx
index 320d94c8917d..d71460d1cb87 100644
--- a/dbaccess/source/ui/misc/HtmlReader.cxx
+++ b/dbaccess/source/ui/misc/HtmlReader.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -35,7 +36,7 @@
#include "dbu_misc.hrc"
#include "dbustrings.hrc"
#include <sfx2/sfxhtml.hxx>
-#include <tools/debug.hxx>
+#include <osl/diagnose.h>
#include <tools/tenccvt.hxx>
#include "moduledbu.hxx"
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
@@ -185,7 +186,7 @@ void OHTMLReader::NextToken( int nToken )
case HTML_THEAD_ON:
case HTML_TBODY_ON:
{
- sal_uInt32 nTell = rInput.Tell(); // verändert vielleicht die Position des Streams
+ sal_uInt32 nTell = rInput.Tell(); // ver�ndert vielleicht die Position des Streams
if ( !m_xTable.is() )
{// erste Zeile als Header verwenden
m_bError = !CreateTable(nToken);
@@ -336,7 +337,6 @@ void OHTMLReader::fetchOptions()
case HTML_O_SDVAL:
{
m_sValToken = pOption->GetString();
- //m_sTextToken = pOption->GetString();
m_bSDNum = sal_True;
}
break;
@@ -347,11 +347,10 @@ void OHTMLReader::fetchOptions()
}
}
//---------------------------------------------------------------------------------
-void OHTMLReader::TableDataOn(SvxCellHorJustify& eVal,int nToken)
+void OHTMLReader::TableDataOn(SvxCellHorJustify& eVal)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "misc", "Ocke.Janssen@sun.com", "OHTMLReader::TableDataOn" );
DBG_CHKTHIS(OHTMLReader,NULL);
- sal_Bool bHorJustifyCenterTH = (nToken == HTML_TABLEHEADER_ON);
const HTMLOptions* pHtmlOptions = GetOptions();
sal_Int16 nArrLen = pHtmlOptions->Count();
for ( sal_Int16 i = 0; i < nArrLen; i++ )
@@ -361,7 +360,6 @@ void OHTMLReader::TableDataOn(SvxCellHorJustify& eVal,int nToken)
{
case HTML_O_ALIGN:
{
- bHorJustifyCenterTH = sal_False;
const String& rOptVal = pOption->GetString();
if (rOptVal.EqualsIgnoreCaseAscii( OOO_STRING_SVTOOLS_HTML_AL_right ))
eVal = SVX_HOR_JUSTIFY_RIGHT;
@@ -438,14 +436,14 @@ sal_Int16 OHTMLReader::GetWidthPixel( const HTMLOption* pOption )
const String& rOptVal = pOption->GetString();
if ( rOptVal.Search('%') != STRING_NOTFOUND )
{ // Prozent
- DBG_ASSERT( m_nColumnWidth, "WIDTH Option: m_nColumnWidth==0 und Width%" );
+ OSL_ENSURE( m_nColumnWidth, "WIDTH Option: m_nColumnWidth==0 und Width%" );
return (sal_Int16)((pOption->GetNumber() * m_nColumnWidth) / 100);
}
else
{
if ( rOptVal.Search('*') != STRING_NOTFOUND )
{ // relativ zu was?!?
-//2do: ColArray aller relativen Werte sammeln und dann MakeCol
+//TODO: ColArray aller relativen Werte sammeln und dann MakeCol
return 0;
}
else
@@ -488,15 +486,11 @@ sal_Bool OHTMLReader::CreateTable(int nToken)
m_sTextToken.Erase();
break;
case HTML_TABLEDATA_ON:
- // m_bAppendFirstLine = true;
- // run through
case HTML_TABLEHEADER_ON:
- TableDataOn(eVal,nTmpToken2);
+ TableDataOn(eVal);
bTableHeader = sal_True;
break;
case HTML_TABLEDATA_OFF:
- // m_bAppendFirstLine = true;
- // run through
case HTML_TABLEHEADER_OFF:
{
aColumnName.EraseLeadingChars();
@@ -596,3 +590,4 @@ TypeSelectionPageFactory OHTMLReader::getTypeSelectionPageFactory()
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/ModuleHelper.cxx b/dbaccess/source/ui/misc/ModuleHelper.cxx
index aa0f11256f59..7a38e3df08eb 100644
--- a/dbaccess/source/ui/misc/ModuleHelper.cxx
+++ b/dbaccess/source/ui/misc/ModuleHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -25,9 +26,7 @@
*
************************************************************************/
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -42,3 +41,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/RowSetDrop.cxx b/dbaccess/source/ui/misc/RowSetDrop.cxx
index 4ad561f20d06..5342b59b27d6 100644
--- a/dbaccess/source/ui/misc/RowSetDrop.cxx
+++ b/dbaccess/source/ui/misc/RowSetDrop.cxx
@@ -1,3 +1,5 @@
+
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -47,7 +49,6 @@ using namespace ::com::sun::star::util;
using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::lang;
-// using namespace ::com::sun::star::sdbcx;
// export data
ORowSetImportExport::ORowSetImportExport( Window* _pParent,
@@ -83,7 +84,7 @@ void ORowSetImportExport::initialize()
m_aColumnTypes.reserve(nCount);
for (sal_Int32 i = 1;i <= nCount; ++i)
{
- sal_Int32 nPos = -1; // -1 means column is autoincrement or doesn't exists
+ sal_Int32 nPos = -1; // -1 means column is autoincrement or doesn't exist
if(!m_xTargetResultSetMetaData->isAutoIncrement(i))
{
try
@@ -94,7 +95,7 @@ void ORowSetImportExport::initialize()
catch(const SQLException&)
{
if(m_xTargetResultSetMetaData->isNullable(i))
- nPos = 0; // column doesn't exists but we could set it to null
+ nPos = 0; // column doesn't exist but we could set it to null
}
}
@@ -119,8 +120,6 @@ sal_Bool ORowSetImportExport::Read()
if(::std::find_if(m_aColumnMapping.begin(),m_aColumnMapping.end(),
::std::bind2nd(::std::greater<sal_Int32>(),0)) == m_aColumnMapping.end())
return sal_False;
- sal_Int32 nCurrentRow = 0;
- sal_Int32 nRowFilterIndex = 0;
sal_Bool bContinue = sal_True;
if(m_aSelection.getLength())
{
@@ -130,7 +129,7 @@ sal_Bool ORowSetImportExport::Read()
{
sal_Int32 nPos = -1;
*pBegin >>= nPos;
- OSL_ENSURE(nPos != -1,"Invalid posiotion!");
+ OSL_ENSURE(nPos != -1,"Invalid position!");
bContinue = (m_xResultSet.is() && m_xResultSet->absolute(nPos) && insertNewRow());
}
}
@@ -138,6 +137,8 @@ sal_Bool ORowSetImportExport::Read()
{
Reference<XPropertySet> xProp(m_xResultSet,UNO_QUERY);
sal_Int32 nRowCount = 0;
+ sal_Int32 nCurrentRow = 0;
+ sal_Int32 nRowFilterIndex = 0;
if ( xProp.is() && xProp->getPropertySetInfo()->hasPropertyByName(PROPERTY_ISROWCOUNTFINAL) )
{
sal_Bool bFinal = sal_False;
@@ -241,7 +242,7 @@ sal_Bool ORowSetImportExport::insertNewRow()
aValue <<= m_xRow->getClob(*aIter);
break;
default:
- OSL_ENSURE(0,"Unknown type");
+ OSL_FAIL("Unknown type");
}
if(m_xRow->wasNull())
m_xTargetRowUpdate->updateNull(i);
@@ -257,7 +258,7 @@ sal_Bool ORowSetImportExport::insertNewRow()
{
if(!m_bAlreadyAsked)
{
- String sAskIfContinue = String(ModuleRes(STR_ERROR_OCCURED_WHILE_COPYING));
+ String sAskIfContinue = String(ModuleRes(STR_ERROR_OCCURRED_WHILE_COPYING));
OSQLWarningBox aDlg( m_pParent, sAskIfContinue, WB_YES_NO | WB_DEF_YES );
if(aDlg.Execute() == RET_YES)
m_bAlreadyAsked = sal_True;
@@ -271,3 +272,4 @@ sal_Bool ORowSetImportExport::insertNewRow()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/RtfReader.cxx b/dbaccess/source/ui/misc/RtfReader.cxx
index 6ce430ecbc67..feae9fa58f26 100644
--- a/dbaccess/source/ui/misc/RtfReader.cxx
+++ b/dbaccess/source/ui/misc/RtfReader.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -129,7 +130,6 @@ void ORTFReader::NextToken( int nToken )
{
int nTmpToken2 = GetNextToken();
- sal_Bool bNext = sal_True;
do
{
Color aColor;
@@ -140,8 +140,7 @@ void ORTFReader::NextToken( int nToken )
case RTF_RED: aColor.SetRed((sal_uInt8)nTokenValue); break;
case RTF_BLUE: aColor.SetBlue((sal_uInt8)nTokenValue); break;
case RTF_GREEN: aColor.SetGreen((sal_uInt8)nTokenValue); break;
- default:
- bNext = sal_False;
+ default: break;
}
nTmpToken2 = GetNextToken();
}
@@ -163,7 +162,7 @@ void ORTFReader::NextToken( int nToken )
bool bInsertRow = true;
if ( !m_xTable.is() ) // erste Zeile als Header verwenden
{
- sal_uInt32 nTell = rInput.Tell(); // verändert vielleicht die Position des Streams
+ sal_uInt32 nTell = rInput.Tell(); // ver�ndert vielleicht die Position des Streams
m_bError = !CreateTable(nToken);
bInsertRow = m_bAppendFirstLine;
@@ -216,7 +215,7 @@ void ORTFReader::NextToken( int nToken )
}
break;
case RTF_ROW:
- // es kann vorkommen, daß die letzte Celle nicht mit \cell abgeschlossen ist
+ // es kann vorkommen, da� die letzte Celle nicht mit \cell abgeschlossen ist
try
{
insertValueIntoColumn();
@@ -314,8 +313,6 @@ sal_Bool ORTFReader::CreateTable(int nToken)
}
break;
case RTF_CF:
- // if(nTokenValue < m_vecColor.size())
- // m_xTable->setPropertyValue(PROPERTY_TEXTCOLOR,makeAny(m_vecColor[nTokenValue]));
break;
case RTF_B:
aFont.Weight = ::com::sun::star::awt::FontWeight::BOLD;
@@ -375,3 +372,4 @@ TypeSelectionPageFactory ORTFReader::getTypeSelectionPageFactory()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/TableCopyHelper.cxx b/dbaccess/source/ui/misc/TableCopyHelper.cxx
index b95dab6f4596..6b095f371a6b 100644
--- a/dbaccess/source/ui/misc/TableCopyHelper.cxx
+++ b/dbaccess/source/ui/misc/TableCopyHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,116 +28,44 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBUI_TABLECOPYHELPER_HXX
#include "TableCopyHelper.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBAUI_WIZ_COPYTABLEDIALOG_HXX
#include "WCopyTable.hxx"
-#endif
-#ifndef DBAUI_GENERICCONTROLLER_HXX
#include "genericcontroller.hxx"
-#endif
-#ifndef DBAUI_WIZARD_CPAGE_HXX
#include "WCPage.hxx"
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_COPYTABLEOPERATION_HPP_
#include <com/sun/star/sdb/application/CopyTableOperation.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_COPYTABLEWIZARD_HPP_
#include <com/sun/star/sdb/application/CopyTableWizard.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_DATAACCESSDESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdb/DataAccessDescriptorFactory.hpp>
-#endif
-#ifndef DBAUI_RTFREADER_HXX
#include "RtfReader.hxx"
-#endif
-#ifndef DBAUI_HTMLREADER_HXX
#include "HtmlReader.hxx"
-#endif
-#ifndef DBAUI_TOKENWRITER_HXX
#include "TokenWriter.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_DATAVIEW_HXX
#include "dataview.hxx"
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
-#ifndef _UNOTOOLS_UCBHELPER_HXX
#include <unotools/ucbhelper.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef COMPHELPER_COMPONENTCONTEXT_HXX
#include <comphelper/componentcontext.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XQUERYDEFINITIONSSUPPLIER_HPP_
#include <com/sun/star/sdb/XQueryDefinitionsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XPARAMETERS_HPP_
#include <com/sun/star/sdbc/XParameters.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XQUERIESSUPPLIER_HPP_
#include <com/sun/star/sdb/XQueriesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCOLUMNLOCATE_HPP_
#include <com/sun/star/sdbc/XColumnLocate.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XROWLOCATE_HPP_
#include <com/sun/star/sdbcx/XRowLocate.hpp>
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSQLQUERYCOMPOSERFACTORY_HPP_
#include <com/sun/star/sdb/XSQLQueryComposerFactory.hpp>
-#endif
-#ifndef _UNOTOOLS_TEMPFILE_HXX
#include <unotools/tempfile.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
-#ifndef DBAUI_DBEXCHANGE_HXX
#include "dbexchange.hxx"
-#endif
#include <rtl/logfile.hxx>
//........................................................................
namespace dbaui
@@ -170,7 +99,7 @@ void OTableCopyHelper::insertTable( const ::rtl::OUString& i_rSourceDataSource,
{
if ( CommandType::QUERY != i_nCommandType && CommandType::TABLE != i_nCommandType )
{
- DBG_ERROR( "OTableCopyHelper::insertTable: invalid call (no supported format found)!" );
+ OSL_FAIL( "OTableCopyHelper::insertTable: invalid call (no supported format found)!" );
return;
}
@@ -182,7 +111,7 @@ void OTableCopyHelper::insertTable( const ::rtl::OUString& i_rSourceDataSource,
if ( !xSrcConnection.is() || !i_rDestConnection.is() )
{
- OSL_ENSURE( false, "OTableCopyHelper::insertTable: no connection/s!" );
+ OSL_FAIL( "OTableCopyHelper::insertTable: no connection/s!" );
return;
}
@@ -294,7 +223,7 @@ void OTableCopyHelper::pasteTable( SotFormatStringId _nFormatId
aTrans.bHtml = SOT_FORMATSTR_ID_HTML == _nFormatId;
aTrans.sDefaultTableName = GetTableNameForAppend();
if ( !copyTagTable(aTrans,sal_False,_xConnection) )
- m_pController->showError(SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*m_pController,::rtl::OUString::createFromAscii("S1000") ,0,Any()));
+ m_pController->showError(SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*m_pController,::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("S1000")),0,Any()));
}
catch(const SQLException&)
{
@@ -306,7 +235,7 @@ void OTableCopyHelper::pasteTable( SotFormatStringId _nFormatId
}
}
else
- m_pController->showError(SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*m_pController,::rtl::OUString::createFromAscii("S1000") ,0,Any()));
+ m_pController->showError(SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*m_pController,::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("S1000")),0,Any()));
}
// -----------------------------------------------------------------------------
@@ -337,10 +266,9 @@ sal_Bool OTableCopyHelper::copyTagTable(OTableCopyHelper::DropDescriptor& _rDesc
if ( _bCheck )
pImport->enableCheckOnly();
- //dyf add 20070601
//set the selected tablename
pImport->setSTableName(_rDesc.sDefaultTableName);
- //dyf add end
+
pImport->setStream(pStream);
return pImport->Read();
}
@@ -406,10 +334,11 @@ void OTableCopyHelper::asyncCopyTagTable( DropDescriptor& _rDesc
else if ( !_rDesc.bError )
pasteTable(_rDesc.aDroppedData,i_rDestDataSource,_xConnection);
else
- m_pController->showError(SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*m_pController,::rtl::OUString::createFromAscii("S1000") ,0,Any()));
+ m_pController->showError(SQLException(String(ModuleRes(STR_NO_TABLE_FORMAT_INSIDE)),*m_pController,::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("S1000")),0,Any()));
}
// -----------------------------------------------------------------------------
//........................................................................
} // namespace dbaui
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/TokenWriter.cxx b/dbaccess/source/ui/misc/TokenWriter.cxx
index 1b92edb2355d..d5f4b47c8976 100644
--- a/dbaccess/source/ui/misc/TokenWriter.cxx
+++ b/dbaccess/source/ui/misc/TokenWriter.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -30,6 +31,7 @@
#include "TokenWriter.hxx"
#include <tools/debug.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include "RtfReader.hxx"
#include "HtmlReader.hxx"
#include "dbustrings.hrc"
@@ -81,15 +83,15 @@ using namespace ::com::sun::star::util;
using ::com::sun::star::frame::XModel;
#if defined(UNX)
-const char __FAR_DATA ODatabaseImportExport::sNewLine = '\012';
+const char ODatabaseImportExport::sNewLine = '\012';
#else
-const char __FAR_DATA ODatabaseImportExport::sNewLine[] = "\015\012";
+const char ODatabaseImportExport::sNewLine[] = "\015\012";
#endif
-const static char __FAR_DATA sMyBegComment[] = "<!-- ";
-const static char __FAR_DATA sMyEndComment[] = " -->";
-const static char __FAR_DATA sFontFamily[] = "font-family: ";
-const static char __FAR_DATA sFontSize[] = "font-size: ";
+const static char sMyBegComment[] = "<!-- ";
+const static char sMyEndComment[] = " -->";
+const static char sFontFamily[] = "font-family: ";
+const static char sFontSize[] = "font-size: ";
#define SBA_FORMAT_SELECTION_COUNT 4
#define CELL_X 1437
@@ -200,8 +202,6 @@ void SAL_CALL ODatabaseImportExport::disposing( const EventObject& Source ) thro
m_xConnection.clear();
dispose();
m_bNeedToReInitialize = true;
- //if(!m_bInInitialize)
- // initialize();
}
}
// -----------------------------------------------------------------------------
@@ -248,7 +248,7 @@ void ODatabaseImportExport::impl_initFromDescriptor( const ODataAccessDescriptor
{
if ( !m_xResultSet.is() )
{
- OSL_ENSURE( false, "ODatabaseImportExport::impl_initFromDescriptor: selection without result set is nonsense!" );
+ OSL_FAIL( "ODatabaseImportExport::impl_initFromDescriptor: selection without result set is nonsense!" );
m_aSelection.realloc( 0 );
}
}
@@ -257,7 +257,7 @@ void ODatabaseImportExport::impl_initFromDescriptor( const ODataAccessDescriptor
{
if ( m_bBookmarkSelection && !m_xRowLocate.is() )
{
- OSL_ENSURE( false, "ODatabaseImportExport::impl_initFromDescriptor: no XRowLocate -> no bookmars!" );
+ OSL_FAIL( "ODatabaseImportExport::impl_initFromDescriptor: no XRowLocate -> no bookmars!" );
m_aSelection.realloc( 0 );
}
}
@@ -331,7 +331,7 @@ void ODatabaseImportExport::initialize()
// the result set may be already set with the datadescriptor
if ( !m_xResultSet.is() )
{
- m_xResultSet.set( m_xFactory->createInstance( ::rtl::OUString::createFromAscii( "com.sun.star.sdb.RowSet" ) ), UNO_QUERY );
+ m_xResultSet.set( m_xFactory->createInstance( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.RowSet")) ), UNO_QUERY );
Reference< XPropertySet > xProp( m_xResultSet, UNO_QUERY_THROW );
xProp->setPropertyValue( PROPERTY_ACTIVE_CONNECTION, makeAny( m_xConnection.getTyped() ) );
xProp->setPropertyValue( PROPERTY_COMMAND_TYPE, makeAny( m_nCommandType ) );
@@ -368,7 +368,7 @@ sal_Bool ODatabaseImportExport::Write()
{
if ( !m_bInInitialize )
initialize();
- } // if ( m_bNeedToReInitialize )
+ }
return sal_True;
}
// -----------------------------------------------------------------------------
@@ -378,7 +378,7 @@ sal_Bool ODatabaseImportExport::Read()
{
if ( !m_bInInitialize )
initialize();
- } // if ( m_bNeedToReInitialize )
+ }
return sal_True;
}
// -----------------------------------------------------------------------------
@@ -403,54 +403,6 @@ sal_Bool ORTFImportExport::Write()
(*m_pStream) << OOO_STRING_SVTOOLS_RTF_ANSI << ODatabaseImportExport::sNewLine;
rtl_TextEncoding eDestEnc = RTL_TEXTENCODING_MS_1252;
- /*
- // Access RTF Export Beispiel
- {\rtf1\ansi
- {\colortbl\red0\green0\blue0;\red255\green255\blue255;\red192\green192\blue192;}
- {\fonttbl\f0\fcharset0\fnil MS Sans Serif;\f1\fcharset0\fnil Arial;\f2\fcharset0\fnil Arial;}
- \trowd\trgaph40
- \clbrdrl\brdrs\brdrcf0\clbrdrt\brdrs\brdrcf0\clbrdrb\brdrs\brdrcf0\clbrdrr\brdrs\brdrcf0\clshdng10000\clcfpat2\cellx1437
- \clbrdrl\brdrs\brdrcf0\clbrdrt\brdrs\brdrcf0\clbrdrb\brdrs\brdrcf0\clbrdrr\brdrs\brdrcf0\clshdng10000\clcfpat2\cellx2874
- {
- \trrh-270\pard\intbl
- {\qc\fs20\b\f1\cf0\cb2 text\cell}
- \pard\intbl
- {\qc\fs20\b\f1\cf0\cb2 datum\cell}
- \pard\intbl\row
- }
- \trowd\trgaph40\clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx1437\clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx2874
- {\trrh-270\pard\intbl
- {\ql\fs20\f2\cf0\cb1 heute\cell}
- \pard\intbl
- {\qr\fs20\f2\cf0\cb1 10.11.98\cell}
- \pard\intbl\row
- }
- \trowd\trgaph40\clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx1437\clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx2874
- {\trrh-270\pard\intbl
- {\ql\fs20\f2\cf0\cb1 morgen\cell}
- \pard\intbl
- {\qr\fs20\f2\cf0\cb1 11.11.98\cell}
- \pard\intbl\row
- }
- \trowd\trgaph40\clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx1437\clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx2874
- {\trrh-270\pard\intbl
- {\ql\fs20\f2\cf0\cb1 bruder\cell}
- \pard\intbl
- {\qr\fs20\f2\cf0\cb1 21.04.98\cell}
- \pard\intbl\row
- }
- \trowd\trgaph40
- \clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx
- \clbrdrl\brdrs\brdrcf2\clbrdrt\brdrs\brdrcf2\clbrdrb\brdrs\brdrcf2\clbrdrr\brdrs\brdrcf2\clshdng10000\clcfpat1\cellx2874
- {\trrh-270\pard\intbl
- {\ql\fs20\f2\cf0\cb1 vater\cell}
- \pard\intbl
- {\qr\fs20\f2\cf0\cb1 28.06.98\cell}
- \pard\intbl\row
- }
- }
- */
-
sal_Bool bBold = ( ::com::sun::star::awt::FontWeight::BOLD == m_aFont.Weight );
sal_Bool bItalic = ( ::com::sun::star::awt::FontSlant_ITALIC == m_aFont.Slant );
sal_Bool bUnderline = ( ::com::sun::star::awt::FontUnderline::NONE != m_aFont.Underline );
@@ -472,10 +424,10 @@ sal_Bool ORTFImportExport::Write()
(*m_pStream) << "{\\fonttbl";
xub_StrLen nTokenCount = aFonts.GetTokenCount();
- for(xub_StrLen j=0;j<nTokenCount;++j)
+ for(sal_uInt32 j=0;j<nTokenCount;++j)
{
(*m_pStream) << "\\f";
- m_pStream->WriteNumber(j);
+ m_pStream->WriteNumber(static_cast<sal_Int32>(j));
(*m_pStream) << aFormat;
(*m_pStream) << aFonts.GetToken(j).GetBuffer();
(*m_pStream) << ';';
@@ -484,11 +436,11 @@ sal_Bool ORTFImportExport::Write()
(*m_pStream) << ODatabaseImportExport::sNewLine;
// write the rtf color table
(*m_pStream) << '{' << OOO_STRING_SVTOOLS_RTF_COLORTBL << OOO_STRING_SVTOOLS_RTF_RED;
- m_pStream->WriteNumber(aColor.GetRed());
+ m_pStream->WriteNumber(static_cast<sal_uInt32>(aColor.GetRed()));
(*m_pStream) << OOO_STRING_SVTOOLS_RTF_GREEN;
- m_pStream->WriteNumber(aColor.GetGreen());
+ m_pStream->WriteNumber(static_cast<sal_uInt32>(aColor.GetGreen()));
(*m_pStream) << OOO_STRING_SVTOOLS_RTF_BLUE;
- m_pStream->WriteNumber(aColor.GetBlue());
+ m_pStream->WriteNumber(static_cast<sal_uInt32>(aColor.GetBlue()));
(*m_pStream) << ";\\red255\\green255\\blue255;\\red192\\green192\\blue192;}"
<< ODatabaseImportExport::sNewLine;
@@ -498,7 +450,7 @@ sal_Bool ORTFImportExport::Write()
::rtl::OString aCell1("\\clbrdrl\\brdrs\\brdrcf0\\clbrdrt\\brdrs\\brdrcf0\\clbrdrb\\brdrs\\brdrcf0\\clbrdrr\\brdrs\\brdrcf0\\clshdng10000\\clcfpat2\\cellx");
(*m_pStream) << OOO_STRING_SVTOOLS_RTF_TROWD << OOO_STRING_SVTOOLS_RTF_TRGAPH;
- m_pStream->WriteNumber(40);
+ m_pStream->WriteNumber(static_cast<sal_Int32>(40));
(*m_pStream) << ODatabaseImportExport::sNewLine;
if(m_xObject.is())
@@ -628,7 +580,7 @@ void ORTFImportExport::appendRow(::rtl::OString* pHorzChar,sal_Int32 _nColumnCou
{
++kk;
(*m_pStream) << OOO_STRING_SVTOOLS_RTF_TROWD << OOO_STRING_SVTOOLS_RTF_TRGAPH;
- m_pStream->WriteNumber(40);
+ m_pStream->WriteNumber(static_cast<sal_Int32>(40));
(*m_pStream) << ODatabaseImportExport::sNewLine;
static const ::rtl::OString aCell2("\\clbrdrl\\brdrs\\brdrcf2\\clbrdrt\\brdrs\\brdrcf2\\clbrdrb\\brdrs\\brdrcf2\\clbrdrr\\brdrs\\brdrcf2\\clshdng10000\\clcfpat1\\cellx");
@@ -670,14 +622,12 @@ void ORTFImportExport::appendRow(::rtl::OString* pHorzChar,sal_Int32 _nColumnCou
Reference<XPropertySet> xColumn(m_xRowSetColumns->getByIndex(i-1),UNO_QUERY_THROW);
dbtools::FormattedColumnValue aFormatedValue(aContext,xRowSet,xColumn);
::rtl::OUString sValue = aFormatedValue.getFormattedValue();
- // m_xRow->getString(i);
- //if (!m_xRow->wasNull())
if ( sValue.getLength() )
RTFOutFuncs::Out_String(*m_pStream,sValue,m_eDestEnc);
}
catch (Exception&)
{
- OSL_ENSURE(0,"RTF WRITE!");
+ OSL_FAIL("RTF WRITE!");
}
(*m_pStream) << OOO_STRING_SVTOOLS_RTF_CELL;
@@ -711,7 +661,7 @@ sal_Bool ORTFImportExport::Read()
}
//-------------------------------------------------------------------
//===================================================================
-const sal_Int16 __FAR_DATA OHTMLImportExport::nDefaultFontSize[SBA_HTML_FONTSIZES] =
+const sal_Int16 OHTMLImportExport::nDefaultFontSize[SBA_HTML_FONTSIZES] =
{
HTMLFONTSZ1_DFLT, HTMLFONTSZ2_DFLT, HTMLFONTSZ3_DFLT, HTMLFONTSZ4_DFLT,
HTMLFONTSZ5_DFLT, HTMLFONTSZ6_DFLT, HTMLFONTSZ7_DFLT
@@ -720,10 +670,10 @@ const sal_Int16 __FAR_DATA OHTMLImportExport::nDefaultFontSize[SBA_HTML_FONTSIZE
sal_Int16 OHTMLImportExport::nFontSize[SBA_HTML_FONTSIZES] = { 0 };
const sal_Int16 OHTMLImportExport::nCellSpacing = 0;
-const char __FAR_DATA OHTMLImportExport::sIndentSource[nIndentMax+1] = "\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t";
+const char OHTMLImportExport::sIndentSource[nIndentMax+1] = "\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t";
//========================================================================
-// Makros fuer HTML-Export
+// Macros for HTML-Export
//========================================================================
#define OUT_PROLOGUE() ((*m_pStream) << sHTML30_Prologue << ODatabaseImportExport::sNewLine << ODatabaseImportExport::sNewLine)
#define TAG_ON( tag ) HTMLOutFuncs::Out_AsciiTag( (*m_pStream), tag )
@@ -744,14 +694,14 @@ OHTMLImportExport::OHTMLImportExport(const ::svx::ODataAccessDescriptor& _aDataD
const String& rExchange)
: ODatabaseImportExport(_aDataDescriptor,_rM,_rxNumberF,rExchange)
,m_nIndent(0)
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
,m_bCheckFont(sal_False)
#endif
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "misc", "Ocke.Janssen@sun.com", "OHTMLImportExport::OHTMLImportExport" );
// set HTML configuration
- SvxHtmlOptions* pHtmlOptions = SvxHtmlOptions::Get();
- m_eDestEnc = pHtmlOptions->GetTextEncoding();
+ SvxHtmlOptions& rHtmlOptions = SvxHtmlOptions::Get();
+ m_eDestEnc = rHtmlOptions.GetTextEncoding();
strncpy( sIndent, sIndentSource ,std::min(sizeof(sIndent),sizeof(sIndentSource)));
sIndent[0] = 0;
}
@@ -786,9 +736,7 @@ sal_Bool OHTMLImportExport::Read()
((OHTMLReader*)m_pReader)->AddRef();
if ( isCheckEnabled() )
m_pReader->enableCheckOnly();
- //dyf add 20070601
m_pReader->SetTableName(m_sDefaultTableName);
- //dyf add end
eState = ((OHTMLReader*)m_pReader)->CallParser();
m_pReader->release();
m_pReader = NULL;
@@ -801,8 +749,8 @@ void OHTMLImportExport::WriteHeader()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "misc", "Ocke.Janssen@sun.com", "OHTMLImportExport::WriteHeader" );
uno::Reference<document::XDocumentProperties> xDocProps(
- m_xFactory->createInstance(::rtl::OUString::createFromAscii(
- "com.sun.star.document.DocumentProperties")),
+ m_xFactory->createInstance(::rtl::OUString(
+ RTL_CONSTASCII_USTRINGPARAM("com.sun.star.document.DocumentProperties"))),
uno::UNO_QUERY);
if (xDocProps.is()) {
xDocProps->setTitle(m_sName);
@@ -826,7 +774,7 @@ void OHTMLImportExport::WriteBody()
(*m_pStream) << OOO_STRING_SVTOOLS_HTML_body << " { " << sFontFamily << '\"' << ::rtl::OString(m_aFont.Name,m_aFont.Name.getLength(), gsl_getSystemTextEncoding()) << '\"';
// TODO : think about the encoding of the font name
(*m_pStream) << "; " << sFontSize;
- m_pStream->WriteNumber(m_aFont.Height);
+ m_pStream->WriteNumber(static_cast<sal_Int32>(m_aFont.Height));
(*m_pStream) << '}';
OUT_LF();
@@ -834,7 +782,7 @@ void OHTMLImportExport::WriteBody()
IncIndent(-1); OUT_LF(); TAG_OFF_LF( OOO_STRING_SVTOOLS_HTML_style );
OUT_LF();
- // default Textfarbe schwarz
+ // default Textcolour black
(*m_pStream) << '<' << OOO_STRING_SVTOOLS_HTML_body << ' ' << OOO_STRING_SVTOOLS_HTML_O_text << '=';
sal_Int32 nColor = 0;
if(m_xObject.is())
@@ -1056,13 +1004,13 @@ void OHTMLImportExport::WriteCell( sal_Int32 nFormat,sal_Int32 nWidthPixel,sal_I
aStrTD = aStrTD + "=";
aStrTD = aStrTD + pChar;
- double fVal = 0.0;
-
Reference< ::com::sun::star::util::XNumberFormatsSupplier > xSupplier = m_xFormatter->getNumberFormatsSupplier();
SvNumberFormatsSupplierObj* pSupplierImpl = SvNumberFormatsSupplierObj::getImplementation( xSupplier );
SvNumberFormatter* pFormatter = pSupplierImpl ? pSupplierImpl->GetNumberFormatter() : NULL;
if(pFormatter)
{
+ double fVal = 0.0;
+
try
{
fVal = m_xFormatter->convertStringToNumber(nFormat,rValue);
@@ -1091,7 +1039,7 @@ void OHTMLImportExport::WriteCell( sal_Int32 nFormat,sal_Int32 nWidthPixel,sal_I
if ( bStrikeout ) TAG_ON( OOO_STRING_SVTOOLS_HTML_strike );
if ( !rValue.Len() )
- TAG_ON( OOO_STRING_SVTOOLS_HTML_linebreak ); // #42573# keine komplett leere Zelle
+ TAG_ON( OOO_STRING_SVTOOLS_HTML_linebreak ); // keine komplett leere Zelle
else
HTMLOutFuncs::Out_String( (*m_pStream), rValue ,m_eDestEnc);
@@ -1109,7 +1057,7 @@ void OHTMLImportExport::WriteCell( sal_Int32 nFormat,sal_Int32 nWidthPixel,sal_I
void OHTMLImportExport::FontOn()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "misc", "Ocke.Janssen@sun.com", "OHTMLImportExport::FontOn" );
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
m_bCheckFont = sal_True;
#endif
@@ -1140,9 +1088,9 @@ void OHTMLImportExport::FontOn()
inline void OHTMLImportExport::FontOff()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "misc", "Ocke.Janssen@sun.com", "OHTMLImportExport::FontOff" );
- DBG_ASSERT(m_bCheckFont,"Kein FontOn() gerufen");
+ OSL_ENSURE(m_bCheckFont,"Kein FontOn() gerufen");
TAG_OFF( OOO_STRING_SVTOOLS_HTML_font );
-#ifdef DBG_UTIL
+#if OSL_DEBUG_LEVEL > 0
m_bCheckFont = sal_False;
#endif
}
@@ -1159,3 +1107,5 @@ void OHTMLImportExport::IncIndent( sal_Int16 nVal )
sIndent[m_nIndent] = 0;
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/ToolBoxHelper.cxx b/dbaccess/source/ui/misc/ToolBoxHelper.cxx
index 0b51fc431d95..91466e9c9560 100644
--- a/dbaccess/source/ui/misc/ToolBoxHelper.cxx
+++ b/dbaccess/source/ui/misc/ToolBoxHelper.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,20 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TOOLBOXHELPER_HXX
#include "ToolBoxHelper.hxx"
-#endif
-#ifndef _SV_TOOLBOX_HXX
#include <vcl/toolbox.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_MISCOPT_HXX
#include <svtools/miscopt.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _SVTOOLS_IMGDEF_HXX
#include <svtools/imgdef.hxx>
-#endif
#include <vcl/event.hxx>
namespace dbaui
{
DBG_NAME(OToolBoxHelper)
OToolBoxHelper::OToolBoxHelper()
- : m_bIsHiContrast(sal_False)
- ,m_nSymbolsSize(-1 )
- ,m_pToolBox(NULL)
+ : m_nSymbolsSize(-1 )
+ , m_pToolBox(NULL)
{
DBG_CTOR(OToolBoxHelper,NULL);
@@ -75,14 +63,11 @@ namespace dbaui
if ( m_pToolBox )
{
sal_Int16 nCurSymbolsSize = SvtMiscOptions().GetCurrentSymbolsSize();
- if ( nCurSymbolsSize != m_nSymbolsSize ||
- m_bIsHiContrast != m_pToolBox->GetSettings().GetStyleSettings().GetHighContrastMode() )
+ if ( nCurSymbolsSize != m_nSymbolsSize )
{
m_nSymbolsSize = nCurSymbolsSize;
- m_bIsHiContrast = m_pToolBox->GetSettings().GetStyleSettings().GetHighContrastMode();
-
- m_pToolBox->SetImageList( getImageList(m_nSymbolsSize,m_bIsHiContrast) );
+ m_pToolBox->SetImageList( getImageList(m_nSymbolsSize) );
Size aTbOldSize = m_pToolBox->GetSizePixel();
adjustToolBoxSize(m_pToolBox);
Size aTbNewSize = m_pToolBox->GetSizePixel();
@@ -128,7 +113,6 @@ namespace dbaui
m_pToolBox = _pTB;
if ( m_pToolBox )
{
- // m_bIsHiContrast = m_pToolBox->GetSettings().GetStyleSettings().GetHighContrastMode();
ConfigOptionsChanged(NULL);
if ( bFirstTime )
adjustToolBoxSize(m_pToolBox);
@@ -138,3 +122,4 @@ namespace dbaui
} // namespace
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/UITools.cxx b/dbaccess/source/ui/misc/UITools.cxx
index bf0126b85a46..bbf93b96a13d 100644
--- a/dbaccess/source/ui/misc/UITools.cxx
+++ b/dbaccess/source/ui/misc/UITools.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,272 +29,103 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _SFX_DOCFILT_HACK_HXX
#include <sfx2/docfilt.hxx>
-#endif
-#ifndef _DBACCESS_UI_CALLBACKS_HXX_
#include "callbacks.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBU_RESOURCE_HRC_
#include "dbu_resource.hrc"
-#endif
-#ifndef DBAUI_DLGSAVE_HXX
#include "dlgsave.hxx"
-#endif
-#ifndef DBAUI_DBTREELISTBOX_HXX
#include "dbtreelistbox.hxx"
-#endif
-#ifndef DBACCESS_SOURCE_UI_INC_DEFAULTOBJECTNAMECHECK_HXX
#include "defaultobjectnamecheck.hxx"
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYANALYZER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryAnalyzer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XCOMPLETEDCONNECTION_HPP_
#include <com/sun/star/sdb/XCompletedConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XKEYSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATASUPPLIER_HPP_
#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSETMETADATA_HPP_
#include <com/sun/star/sdbc/XResultSetMetaData.hpp>
-#endif
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCONTENT_HPP_
#include <com/sun/star/ucb/XContent.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XEXECUTABLEDIALOG_HPP_
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_INTERACTIVEIOEXCEPTION_HPP_
#include <com/sun/star/ucb/InteractiveIOException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XDOCUMENTDATASOURCE_HPP_
#include <com/sun/star/sdb/XDocumentDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_IOERRORCODE_HPP_
#include <com/sun/star/ucb/IOErrorCode.hpp>
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef _TOOLKIT_AWT_VCLXWINDOW_HXX_
#include <toolkit/awt/vclxwindow.hxx>
-#endif
-#ifndef _VCL_STDTEXT_HXX
#include <vcl/stdtext.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSETINFO_HPP_
#include <com/sun/star/beans/XPropertySetInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCONTAINER_HPP_
#include <com/sun/star/container/XContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMECONTAINER_HPP_
#include <com/sun/star/container/XHierarchicalNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_TEXTALIGN_HPP_
#include <com/sun/star/awt/TextAlign.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTDESCRIPTOR_HPP_
#include <com/sun/star/awt/FontDescriptor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTWEIGHT_HPP_
#include <com/sun/star/awt/FontWeight.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTRELIEF_HPP_
#include <com/sun/star/awt/FontRelief.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTWIDTH_HPP_
#include <com/sun/star/awt/FontWidth.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XMODEL_HPP_
#include <com/sun/star/frame/XModel.hpp>
-#endif
-#ifndef DBAUI_SBATTRDLG_HRC
#include "dlgattr.hrc"
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef COMPHELPER_COMPONENTCONTEXT_HXX
#include <comphelper/componentcontext.hxx>
-#endif
-#ifndef _SVX_SVXIDS_HRC
#include <svx/svxids.hrc>
-#endif
#define ITEMID_HORJUSTIFY SID_ATTR_ALIGN_HOR_JUSTIFY
#define ITEMID_VERJUSTIFY SID_ATTR_ALIGN_VER_JUSTIFY
-//#define ITEMID_ORIENTATION SID_ATTR_ALIGN_ORIENTATION
#define ITEMID_LINEBREAK SID_ATTR_ALIGN_LINEBREAK
#define ITEMID_MARGIN SID_ATTR_ALIGN_MARGIN
#define ITEMID_NUMBERINFO SID_ATTR_NUMBERFORMAT_INFO
-#ifndef _SFXITEMPOOL_HXX
#include <svl/itempool.hxx>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _SFXITEMSET_HXX //autogen wg. SfxItemSet
#include <svl/itemset.hxx>
-#endif
-#ifndef DBACCESS_SBA_GRID_HRC
#include "sbagrid.hrc"
-#endif
-#ifndef _SFXRNGITEM_HXX
#include <svl/rngitem.hxx>
-#endif
-#ifndef _SFXINTITEM_HXX
#include <svl/intitem.hxx>
-#endif
-#ifndef _SVX_ALGITEM_HXX
#include <svx/algitem.hxx>
-#endif
-#ifndef _SVX_NUMINF_HXX
#include <svx/numinf.hxx>
-#endif
#define _ZFORLIST_DECLARE_TABLE
-#ifndef _SVX_NUMINF_HXX
#include <svx/numinf.hxx>
-#endif
-#ifndef _ZFORLIST_HXX
#include <svl/zforlist.hxx>
-#endif
-#ifndef DBAUI_SBATTRDLG_HXX
#include "dlgattr.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATSSUPPLIER_HPP_
#include <com/sun/star/util/XNumberFormatsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UTIL_NUMBERFORMAT_HPP_
#include <com/sun/star/util/NumberFormat.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_URL_HPP_
#include <com/sun/star/util/URL.hpp>
-#endif
-#ifndef _SV_TOOLBOX_HXX
#include <vcl/toolbox.hxx>
-#endif
-#ifndef _DBAUI_DLGSIZE_HXX
#include "dlgsize.hxx"
-#endif
-#ifndef _SVTOOLS_EDITBROWSEBOX_HXX_
#include <svtools/editbrowsebox.hxx>
-#endif
-#ifndef _UTL_CONFIGMGR_HXX_
#include <unotools/configmgr.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_HELPOPT_HXX
#include <svtools/helpopt.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _URLOBJ_HXX
#include <tools/urlobj.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _NUMUNO_HXX
#include <svl/numuno.hxx>
-#endif
-#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
#include <unotools/pathoptions.hxx>
-#endif
-#ifndef SVTOOLS_FILENOTATION_HXX_
#include <svl/filenotation.hxx>
-#endif
-#ifndef _SVT_FILEVIEW_HXX
#include <svtools/fileview.hxx>
-#endif
-#ifndef _CONNECTIVITY_FILE_VALUE_HXX_
#include <connectivity/FValue.hxx>
-#endif
+
+#include <editeng/justifyitem.hxx>
// .........................................................................
namespace dbaui
@@ -330,7 +162,7 @@ SQLExceptionInfo createConnection( const ::rtl::OUString& _rsDataSourceName,
{
xProp.set(_xDatabaseContext->getByName(_rsDataSourceName),UNO_QUERY);
}
- catch(Exception&)
+ catch(const Exception&)
{
}
SQLExceptionInfo aInfo;
@@ -346,7 +178,7 @@ SQLExceptionInfo createConnection( const Reference< ::com::sun::star::beans::XP
SQLExceptionInfo aInfo;
if ( !_xDataSource.is() )
{
- OSL_ENSURE(0,"createConnection: coult not retrieve the data source!");
+ OSL_FAIL("createConnection: coult not retrieve the data source!");
return aInfo;
}
@@ -358,9 +190,9 @@ SQLExceptionInfo createConnection( const Reference< ::com::sun::star::beans::XP
bPwdReq = ::cppu::any2bool(_xDataSource->getPropertyValue(PROPERTY_ISPASSWORDREQUIRED));
_xDataSource->getPropertyValue(PROPERTY_USER) >>= sUser;
}
- catch(Exception&)
+ catch(const Exception&)
{
- OSL_ENSURE(0,"createConnection: error while retrieving data source properties!");
+ OSL_FAIL("createConnection: error while retrieving data source properties!");
}
@@ -371,15 +203,14 @@ SQLExceptionInfo createConnection( const Reference< ::com::sun::star::beans::XP
Reference<XCompletedConnection> xConnectionCompletion(_xDataSource, UNO_QUERY);
if (!xConnectionCompletion.is())
{
- OSL_ENSURE(0,"createConnection: missing an interface ... need an error message here!");
+ OSL_FAIL("createConnection: missing an interface ... need an error message here!");
}
else
{ // instantiate the default SDB interaction handler
Reference< XInteractionHandler > xHandler(_rMF->createInstance(SERVICE_TASK_INTERACTION_HANDLER), UNO_QUERY);
if (!xHandler.is())
{
- OSL_ENSURE(sal_False, "createConnection: could not instantiate an interaction handler!");
- // ShowServiceNotAvailableError(NULL, String(SERVICE_TASK_INTERACTION_HANDLER), sal_True);
+ OSL_FAIL("createConnection: could not instantiate an interaction handler!");
// TODO: a real parent!
}
else
@@ -396,12 +227,10 @@ SQLExceptionInfo createConnection( const Reference< ::com::sun::star::beans::XP
if (xComponent.is() && _rEvtLst.is())
xComponent->addEventListener(_rEvtLst);
}
- catch(SQLContext& e) { aInfo = SQLExceptionInfo(e); }
- catch(SQLWarning& e) { aInfo = SQLExceptionInfo(e); }
- catch(SQLException& e) { aInfo = SQLExceptionInfo(e); }
- catch(Exception&) { OSL_ENSURE(0,"SbaTableQueryBrowser::OnExpandEntry: could not connect - unknown exception!"); }
-
- // showError(aInfo);
+ catch(const SQLContext& e) { aInfo = SQLExceptionInfo(e); }
+ catch(const SQLWarning& e) { aInfo = SQLExceptionInfo(e); }
+ catch(const SQLException& e) { aInfo = SQLExceptionInfo(e); }
+ catch(const Exception&) { OSL_FAIL("SbaTableQueryBrowser::OnExpandEntry: could not connect - unknown exception!"); }
return aInfo;
}
@@ -571,8 +400,7 @@ TOTypeInfoSP getTypeInfoFromType(const OTypeInfoMap& _rTypeInfo,
&& ( (_bAutoIncrement && aIter->second->bAutoIncrement) || !_bAutoIncrement )
)
{
- OSL_ENSURE(sal_False,
- ( ::rtl::OString("getTypeInfoFromType: assuming column type ")
+ OSL_FAIL(( ::rtl::OString("getTypeInfoFromType: assuming column type ")
+= ::rtl::OString(aIter->second->aTypeName.getStr(), aIter->second->aTypeName.getLength(), gsl_getSystemTextEncoding())
+= ::rtl::OString("\" (expected type name ")
+= ::rtl::OString(_sTypeName.getStr(), _sTypeName.getLength(), gsl_getSystemTextEncoding())
@@ -587,11 +415,6 @@ TOTypeInfoSP getTypeInfoFromType(const OTypeInfoMap& _rTypeInfo,
// -> drop the precision and the scale restriction, accept any type with the property
// type id (nType)
- //OSL_ENSURE(sal_False,
- // ( ::rtl::OString("getTypeInfoFromType: did not find a matching type")
- // += ::rtl::OString(" (expected type name: ")
- // += ::rtl::OString(_sTypeName.getStr(), _sTypeName.getLength(), gsl_getSystemTextEncoding())
- // += ::rtl::OString(")! Defaulting to the first matching type.")).getStr());
for(aIter = aPair.first; aIter != aPair.second; ++aIter)
{
// search the best matching type (now comparing the local names)
@@ -679,8 +502,8 @@ void fillTypeInfo( const Reference< ::com::sun::star::sdbc::XConnection>& _rxCo
// Information for a single SQL type
if(xRs.is())
{
- static const ::rtl::OUString aB1 = ::rtl::OUString::createFromAscii(" [ ");
- static const ::rtl::OUString aB2 = ::rtl::OUString::createFromAscii(" ]");
+ static const ::rtl::OUString aB1(RTL_CONSTASCII_USTRINGPARAM(" [ "));
+ static const ::rtl::OUString aB2(RTL_CONSTASCII_USTRINGPARAM(" ]"));
Reference<XResultSetMetaData> xResultSetMetaData = Reference<XResultSetMetaDataSupplier>(xRs,UNO_QUERY)->getMetaData();
::connectivity::ORowSetValue aValue;
::std::vector<sal_Int32> aTypes;
@@ -954,7 +777,7 @@ sal_Bool checkDataSourceAvailable(const ::rtl::OUString& _sDataSourceName,const
{
bRet = xDataBaseContext->getByName(_sDataSourceName).hasValue();
}
- catch(Exception)
+ catch(const Exception&)
{
}
}
@@ -972,7 +795,7 @@ sal_Int32 mapTextAllign(const SvxCellHorJustify& _eAlignment)
case SVX_HOR_JUSTIFY_CENTER: nAlignment = ::com::sun::star::awt::TextAlign::CENTER; break;
case SVX_HOR_JUSTIFY_RIGHT: nAlignment = ::com::sun::star::awt::TextAlign::RIGHT; break;
default:
- OSL_ENSURE(0,"Invalid TextAlign!");
+ OSL_FAIL("Invalid TextAlign!");
}
return nAlignment;
}
@@ -986,7 +809,7 @@ SvxCellHorJustify mapTextJustify(const sal_Int32& _nAlignment)
case ::com::sun::star::awt::TextAlign::CENTER : eJustify = SVX_HOR_JUSTIFY_CENTER; break;
case ::com::sun::star::awt::TextAlign::RIGHT : eJustify = SVX_HOR_JUSTIFY_RIGHT; break;
default:
- OSL_ENSURE(0,"Invalid TextAlign!");
+ OSL_FAIL("Invalid TextAlign!");
}
return eJustify;
}
@@ -1014,7 +837,7 @@ float ConvertFontWeight( ::FontWeight eWeight )
else if( eWeight == WEIGHT_BLACK )
return ::com::sun::star::awt::FontWeight::BLACK;
- OSL_ENSURE(0, "Unknown FontWeigth" );
+ OSL_FAIL("Unknown FontWeigth" );
return ::com::sun::star::awt::FontWeight::DONTKNOW;
}
// -----------------------------------------------------------------------------
@@ -1041,7 +864,7 @@ float ConvertFontWidth( ::FontWidth eWidth )
else if( eWidth == WIDTH_ULTRA_EXPANDED )
return ::com::sun::star::awt::FontWidth::ULTRAEXPANDED;
- OSL_ENSURE(0, "Unknown FontWidth" );
+ OSL_FAIL("Unknown FontWidth" );
return ::com::sun::star::awt::FontWidth::DONTKNOW;
}
// -----------------------------------------------------------------------------
@@ -1115,7 +938,7 @@ sal_Bool callColumnFormatDialog(Window* _pParent,
sal_Bool _bHasFormat)
{
sal_Bool bRet = sal_False;
- // the allowed format changes depend of the type of the field ...
+ // the allowed format changes depending on the type of the field ...
_nFlags = TP_ATTR_ALIGN;
if (_bHasFormat)
@@ -1220,7 +1043,7 @@ sal_Bool callColumnFormatDialog(Window* _pParent,
delete pFormatDescriptor;
SfxItemPool::Free(pPool);
- for (sal_uInt16 i=0; i<sizeof(pDefaults)/sizeof(pDefaults[0]); ++i)
+ for (sal_uInt16 i=0; i < SAL_N_ELEMENTS(pDefaults); ++i)
delete pDefaults[i];
return bRet;
@@ -1253,7 +1076,7 @@ sal_Bool appendToFilter(const Reference<XConnection>& _xConnection,
xProp->getPropertyValue(PROPERTY_TABLEFILTER) >>= aFilter;
// first check if we have something like SCHEMA.%
sal_Bool bHasToInsert = sal_True;
- static ::rtl::OUString sPattern = ::rtl::OUString::createFromAscii("%");
+ static ::rtl::OUString sPattern(RTL_CONSTASCII_USTRINGPARAM("%"));
const ::rtl::OUString* pBegin = aFilter.getConstArray();
const ::rtl::OUString* pEnd = pBegin + aFilter.getLength();
for (;pBegin != pEnd; ++pBegin)
@@ -1318,22 +1141,6 @@ void adjustToolBoxSize(ToolBox* _pToolBox)
}
}
// -----------------------------------------------------------------------------
-sal_Bool isHiContrast(Window* _pWindow)
-{
- OSL_ENSURE(_pWindow,"Window must be not null!");
- Window* pIter = _pWindow;
- // while( pIter && pIter->GetBackground().GetColor().GetColor() == COL_TRANSPARENT )
- while( pIter )
- {
- if ( pIter->GetBackground().GetColor().GetColor() == COL_TRANSPARENT )
- pIter = pIter->GetParent();
- else
- break;
- }
- return pIter && pIter->GetSettings().GetStyleSettings().GetHighContrastMode();
-}
-
-// -----------------------------------------------------------------------------
void adjustBrowseBoxColumnWidth( ::svt::EditBrowseBox* _pBox, sal_uInt16 _nColId )
{
sal_Int32 nColSize = -1;
@@ -1399,7 +1206,7 @@ void fillAutoIncrementValue(const Reference<XPropertySet>& _xDatasource,
pValue->Value >>= _rsAutoIncrementValue;
pValue =::std::find_if(aInfo.getConstArray(),
aInfo.getConstArray() + aInfo.getLength(),
- ::std::bind2nd(TPropertyValueEqualFunctor(),::rtl::OUString::createFromAscii("IsAutoRetrievingEnabled") ));
+ ::std::bind2nd(TPropertyValueEqualFunctor(),::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsAutoRetrievingEnabled")) ));
if ( pValue && pValue != (aInfo.getConstArray() + aInfo.getLength()) )
pValue->Value >>= _rAutoIncrementValueEnabled;
}
@@ -1437,29 +1244,29 @@ void fillAutoIncrementValue(const Reference<XConnection>& _xConnection,
return sName;
}
// -----------------------------------------------------------------------------
- void AppendConfigToken( ::rtl::OUString& _rURL, sal_Bool _bQuestionMark )
- {
- Any aLocale =
- ::utl::ConfigManager::GetConfigManager()->GetDirectConfigProperty( ::utl::ConfigManager::LOCALE );
- ::rtl::OUString sLocaleStr;
- if ( !( aLocale >>= sLocaleStr ) )
- // fallback is english
- sLocaleStr = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("en"));
-
- // query part exists?
- if ( _bQuestionMark )
- // no, so start with '?'
- _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("?"));
- else
- // yes, so only append with '&'
- _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("&"));
-
- // set parameters
- _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Language="));
- _rURL += sLocaleStr;
- _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("&System="));
- _rURL += SvtHelpOptions().GetSystem();
- }
+void AppendConfigToken( ::rtl::OUString& _rURL, sal_Bool _bQuestionMark )
+{
+ Any aLocale =
+ ::utl::ConfigManager::GetConfigManager().GetDirectConfigProperty( ::utl::ConfigManager::LOCALE );
+ ::rtl::OUString sLocaleStr;
+ if ( !( aLocale >>= sLocaleStr ) )
+ // fallback is english
+ sLocaleStr = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("en"));
+
+ // query part exists?
+ if ( _bQuestionMark )
+ // no, so start with '?'
+ _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("?"));
+ else
+ // yes, so only append with '&'
+ _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("&"));
+
+ // set parameters
+ _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Language="));
+ _rURL += sLocaleStr;
+ _rURL += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("&System="));
+ _rURL += SvtHelpOptions().GetSystem();
+}
namespace
{
@@ -1474,7 +1281,7 @@ namespace
{
::ucbhelper::Content aCnt( INetURLObject( _rURL ).GetMainURL( INetURLObject::NO_DECODE ),
Reference< ::com::sun::star::ucb::XCommandEnvironment > () );
- if ( ( aCnt.getPropertyValue( ::rtl::OUString::createFromAscii( "AnchorName" ) ) >>= sAnchor ) )
+ if ( ( aCnt.getPropertyValue( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AnchorName")) ) >>= sAnchor ) )
{
if ( sAnchor.getLength() > 0 )
@@ -1632,20 +1439,20 @@ TOTypeInfoSP queryTypeInfoByType(sal_Int32 _nDataType,const OTypeInfoMap& _rType
break;
default:
;
- } // switch(_nDataType)
+ }
if ( !pTypeInfo )
{
::rtl::OUString sCreate(RTL_CONSTASCII_USTRINGPARAM("x")),sTypeName;
sal_Bool bForce = sal_True;
pTypeInfo = ::dbaui::getTypeInfoFromType(_rTypeInfo,DataType::VARCHAR,sTypeName,sCreate,50,0,sal_False,bForce);
- } // if ( !pTypeInfo )
+ }
OSL_ENSURE(pTypeInfo,"Wrong DataType supplied!");
return pTypeInfo;
}
// -----------------------------------------------------------------------------
sal_Int32 askForUserAction(Window* _pParent,sal_uInt16 _nTitle,sal_uInt16 _nText,sal_Bool _bAll,const ::rtl::OUString& _sName)
{
- vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
String aMsg = String(ModuleRes(_nText));
aMsg.SearchAndReplace(String::CreateFromAscii("%1"),String(_sName));
OSQLMessageBox aAsk(_pParent,String(ModuleRes(_nTitle )),aMsg,WB_YES_NO | WB_DEF_YES,OSQLMessageBox::Query);
@@ -1886,3 +1693,5 @@ Reference< XNumberFormatter > getNumberFormatter(const Reference< XConnection >&
// .........................................................................
} // dbaui
// .........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/UpdateHelperImpl.hxx b/dbaccess/source/ui/misc/UpdateHelperImpl.hxx
index ab48101d672a..cff3c9f11a72 100644
--- a/dbaccess/source/ui/misc/UpdateHelperImpl.hxx
+++ b/dbaccess/source/ui/misc/UpdateHelperImpl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -147,3 +148,4 @@ namespace dbaui
#endif // DBAUI_UPDATEHELPERIMPL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/WCPage.cxx b/dbaccess/source/ui/misc/WCPage.cxx
index 8190678056fa..91ab2b13fc26 100644
--- a/dbaccess/source/ui/misc/WCPage.cxx
+++ b/dbaccess/source/ui/misc/WCPage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -31,57 +32,23 @@
#include "WCPage.hxx"
#include "WCopyTable.hxx"
-#ifndef DBACCESS_SOURCE_UI_MISC_DEFAULTOBJECTNAMECHECK_HXX
#include "defaultobjectnamecheck.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
-#ifndef DBAUI_WIZARD_PAGES_HRC
#include "WizardPages.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XRESULTSET_HPP_
#include <com/sun/star/sdbc/XResultSet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XVIEWSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XViewsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_COPYTABLEOPERATION_HPP_
#include <com/sun/star/sdb/application/CopyTableOperation.hpp>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
using namespace ::dbaui;
using namespace ::dbtools;
@@ -167,7 +134,7 @@ IMPL_LINK( OCopyTable, AppendDataClickHdl, Button*, /*pButton*/ )
SetAppendDataRadio();
return 0;
}
-//--------dyf ADD
+
void OCopyTable::SetAppendDataRadio()
{
m_pParent->EnableButton(OCopyTableWizard::WIZARD_NEXT,sal_True);
@@ -177,7 +144,6 @@ void OCopyTable::SetAppendDataRadio()
m_pParent->setOperation(CopyTableOperation::AppendData);
}
-//--------add end
//------------------------------------------------------------------------
IMPL_LINK( OCopyTable, RadioChangeHdl, Button*, pButton )
{
@@ -338,7 +304,6 @@ sal_Bool OCopyTable::checkAppendData()
xTables->getByName( m_edTableName.GetText() ) >>= xTable;
ObjectCopySource aTableCopySource( m_pParent->m_xDestConnection, xTable );
m_pParent->loadData( aTableCopySource, m_pParent->m_vDestColumns, m_pParent->m_aDestVec );
- // #90027#
const ODatabaseExport::TColumnVector* pDestColumns = m_pParent->getDestVector();
ODatabaseExport::TColumnVector::const_iterator aDestIter = pDestColumns->begin();
ODatabaseExport::TColumnVector::const_iterator aDestEnd = pDestColumns->end();
@@ -384,7 +349,6 @@ void OCopyTable::setCreatePrimaryKey( bool _bDoCreate, const ::rtl::OUString& _r
}
// -----------------------------------------------------------------------------
-//---dyf add 2006/7/10
void OCopyTable::setCreateStyleAction()
{
// reselect the last action before
@@ -415,4 +379,5 @@ void OCopyTable::setCreateStyleAction()
}
}
}
-//---add end
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/WColumnSelect.cxx b/dbaccess/source/ui/misc/WColumnSelect.cxx
index 0aa995fc8fae..38bf77652f06 100644
--- a/dbaccess/source/ui/misc/WColumnSelect.cxx
+++ b/dbaccess/source/ui/misc/WColumnSelect.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,46 +29,21 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_WIZ_COLUMNSELECT_HXX
#include "WColumnSelect.hxx"
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_WIZARD_PAGES_HRC
+#include <osl/diagnose.h>
#include "WizardPages.hrc"
-#endif
-#ifndef DBAUI_WIZ_COPYTABLEDIALOG_HXX
#include "WCopyTable.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNVALUE_HPP_
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_APPLICATION_COPYTABLEOPERATION_HPP_
#include <com/sun/star/sdb/application/CopyTableOperation.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
#include <functional>
+#include <o3tl/compat_functional.hxx>
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
@@ -150,8 +126,6 @@ void OWizColumnSelect::Reset()
m_lbOrgColumnNames.SetEntryData(nPos,(*aIter)->second);
}
- // m_pParent->clearDestColumns();
-
if(m_lbOrgColumnNames.GetEntryCount())
m_lbOrgColumnNames.SelectEntryPos(0);
@@ -186,7 +160,6 @@ sal_Bool OWizColumnSelect::LeavePage()
{
DBG_CHKTHIS(OWizColumnSelect,NULL);
- // m_pParent->getColumns()->clear();
m_pParent->clearDestColumns();
for(sal_uInt16 i=0 ; i< m_lbNewColumnNames.GetEntryCount();++i)
@@ -364,12 +337,12 @@ void OWizColumnSelect::moveColumn( ListBox* _pRight,
{
// find the new column in the dest name mapping to obtain the old column
OCopyTableWizard::TNameMapping::iterator aIter = ::std::find_if(m_pParent->m_mNameMapping.begin(),m_pParent->m_mNameMapping.end(),
- ::std::compose1(
+ ::o3tl::compose1(
::std::bind2nd(_aCase, _sColumnName),
- ::std::select2nd<OCopyTableWizard::TNameMapping::value_type>())
+ ::o3tl::select2nd<OCopyTableWizard::TNameMapping::value_type>())
);
- DBG_ASSERT(aIter != m_pParent->m_mNameMapping.end(),"Column must be defined");
+ OSL_ENSURE(aIter != m_pParent->m_mNameMapping.end(),"Column must be defined");
if ( aIter == m_pParent->m_mNameMapping.end() )
return; // do nothing
const ODatabaseExport::TColumns* pSrcColumns = m_pParent->getSourceColumns();
@@ -414,12 +387,12 @@ sal_uInt16 OWizColumnSelect::adjustColumnPosition( ListBox* _pLeft,
{
// find the new column in the dest name mapping to obtain the old column
OCopyTableWizard::TNameMapping::iterator aIter = ::std::find_if(m_pParent->m_mNameMapping.begin(),m_pParent->m_mNameMapping.end(),
- ::std::compose1(
+ ::o3tl::compose1(
::std::bind2nd(_aCase, sColumnString),
- ::std::select2nd<OCopyTableWizard::TNameMapping::value_type>())
+ ::o3tl::select2nd<OCopyTableWizard::TNameMapping::value_type>())
);
- DBG_ASSERT(aIter != m_pParent->m_mNameMapping.end(),"Column must be defined");
+ OSL_ENSURE(aIter != m_pParent->m_mNameMapping.end(),"Column must be defined");
const ODatabaseExport::TColumns* pSrcColumns = m_pParent->getSourceColumns();
ODatabaseExport::TColumns::const_iterator aSrcIter = pSrcColumns->find((*aIter).first);
if ( aSrcIter != pSrcColumns->end() )
@@ -450,3 +423,4 @@ void OWizColumnSelect::enableButtons()
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/WCopyTable.cxx b/dbaccess/source/ui/misc/WCopyTable.cxx
index 10b8aae1c28f..7fff204f8404 100644
--- a/dbaccess/source/ui/misc/WCopyTable.cxx
+++ b/dbaccess/source/ui/misc/WCopyTable.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -74,6 +75,7 @@
#include <vcl/waitobj.hxx>
#include <functional>
+#include <o3tl/compat_functional.hxx>
using namespace ::dbaui;
using namespace ::com::sun::star::uno;
@@ -151,7 +153,7 @@ bool ObjectCopySource::isView() const
{
::rtl::OUString sObjectType;
OSL_VERIFY( m_xObject->getPropertyValue( PROPERTY_TYPE ) >>= sObjectType );
- bIsView = sObjectType.equalsAscii( "VIEW" );
+ bIsView = sObjectType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "VIEW" ) );
}
}
catch( const Exception& )
@@ -167,7 +169,7 @@ void ObjectCopySource::copyUISettingsTo( const Reference< XPropertySet >& _rxObj
const ::rtl::OUString aCopyProperties[] = {
PROPERTY_FONT, PROPERTY_ROW_HEIGHT, PROPERTY_TEXTCOLOR,PROPERTY_TEXTLINECOLOR,PROPERTY_TEXTEMPHASIS,PROPERTY_TEXTRELIEF
};
- for ( size_t i=0; i < sizeof( aCopyProperties ) / sizeof( aCopyProperties[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aCopyProperties ); ++i )
{
if ( m_xObjectPSI->hasPropertyByName( aCopyProperties[i] ) )
_rxObject->setPropertyValue( aCopyProperties[i], m_xObject->getPropertyValue( aCopyProperties[i] ) );
@@ -194,7 +196,7 @@ void ObjectCopySource::copyFilterAndSortingTo( const Reference< XConnection >& _
sStatement += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" WHERE 0=1"));
- for ( i=0; i < sizeof( aProperties ) / sizeof( aProperties[0] ); ++i )
+ for ( i=0; i < SAL_N_ELEMENTS( aProperties ); ++i )
{
if ( m_xObjectPSI->hasPropertyByName( aProperties[i].first ) )
{
@@ -329,7 +331,7 @@ bool NamedTableCopySource::isView() const
{
DBG_UNHANDLED_EXCEPTION();
}
- return sTableType.equalsAscii( "VIEW" );
+ return sTableType.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "VIEW" ) );
}
//------------------------------------------------------------------------
@@ -478,14 +480,14 @@ const DummyCopySource& DummyCopySource::Instance()
//------------------------------------------------------------------------
::rtl::OUString DummyCopySource::getQualifiedObjectName() const
{
- OSL_ENSURE( false, "DummyCopySource::getQualifiedObjectName: not to be called!" );
+ OSL_FAIL( "DummyCopySource::getQualifiedObjectName: not to be called!" );
return ::rtl::OUString();
}
//------------------------------------------------------------------------
bool DummyCopySource::isView() const
{
- OSL_ENSURE( false, "DummyCopySource::isView: not to be called!" );
+ OSL_FAIL( "DummyCopySource::isView: not to be called!" );
return false;
}
@@ -507,27 +509,27 @@ Sequence< ::rtl::OUString > DummyCopySource::getColumnNames() const
//------------------------------------------------------------------------
Sequence< ::rtl::OUString > DummyCopySource::getPrimaryKeyColumnNames() const
{
- OSL_ENSURE( false, "DummyCopySource::getPrimaryKeyColumnNames: not to be called!" );
+ OSL_FAIL( "DummyCopySource::getPrimaryKeyColumnNames: not to be called!" );
return Sequence< ::rtl::OUString >();
}
//------------------------------------------------------------------------
OFieldDescription* DummyCopySource::createFieldDescription( const ::rtl::OUString& /*_rColumnName*/ ) const
{
- OSL_ENSURE( false, "DummyCopySource::createFieldDescription: not to be called!" );
+ OSL_FAIL( "DummyCopySource::createFieldDescription: not to be called!" );
return NULL;
}
//------------------------------------------------------------------------
::rtl::OUString DummyCopySource::getSelectStatement() const
{
- OSL_ENSURE( false, "DummyCopySource::getSelectStatement: not to be called!" );
+ OSL_FAIL( "DummyCopySource::getSelectStatement: not to be called!" );
return ::rtl::OUString();
}
//------------------------------------------------------------------------
::utl::SharedUNOComponent< XPreparedStatement > DummyCopySource::getPreparedSelectStatement() const
{
- OSL_ENSURE( false, "DummyCopySource::getPreparedSelectStatement: not to be called!" );
+ OSL_FAIL( "DummyCopySource::getPreparedSelectStatement: not to be called!" );
return ::utl::SharedUNOComponent< XPreparedStatement >();
}
@@ -615,8 +617,7 @@ OCopyTableWizard::OCopyTableWizard( Window * pParent, const ::rtl::OUString& _rD
impl_loadSourceData();
bool bAllowViews = true;
- // if the source is a, don't allow creating views #100644# (oj)
- // (fs: Hmm? A SELECT * FROM <view> would be created, where #100644# claims this is nonsense. Why?
+ // if the source is a, don't allow creating views
if ( m_rSourceObject.isView() )
bAllowViews = false;
// no views if the target connection does not support creating them
@@ -930,7 +931,7 @@ IMPL_LINK( OCopyTableWizard, ImplOKHdl, OKButton*, EMPTYARG )
if ( supportsPrimaryKey() )
{
ODatabaseExport::TColumns::iterator aFind = ::std::find_if(m_vDestColumns.begin(),m_vDestColumns.end()
- ,::std::compose1(::std::mem_fun(&OFieldDescription::IsPrimaryKey),::std::select2nd<ODatabaseExport::TColumns::value_type>()));
+ ,::o3tl::compose1(::std::mem_fun(&OFieldDescription::IsPrimaryKey),::o3tl::select2nd<ODatabaseExport::TColumns::value_type>()));
if ( aFind == m_vDestColumns.end() && m_xInteractionHandler.is() )
{
@@ -973,7 +974,7 @@ IMPL_LINK( OCopyTableWizard, ImplOKHdl, OKButton*, EMPTYARG )
break;
default:
{
- OSL_ENSURE(sal_False, "OCopyTableWizard::ImplOKHdl: invalid creation style!");
+ OSL_FAIL("OCopyTableWizard::ImplOKHdl: invalid creation style!");
}
}
@@ -1024,7 +1025,7 @@ IMPL_LINK( OCopyTableWizard, ImplActivateHdl, WizardDialog*, EMPTYARG )
void OCopyTableWizard::CheckButtons()
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "misc", "Ocke.Janssen@sun.com", "OCopyTableWizard::CheckButtons" );
- if(GetCurLevel() == 0) // erste Seite hat kein PrevButton
+ if(GetCurLevel() == 0) // the first page has no back button
{
if(m_nPageCount > 1)
m_pbNext.Enable(sal_True);
@@ -1033,7 +1034,7 @@ void OCopyTableWizard::CheckButtons()
m_pbPrev.Enable(sal_False);
}
- else if(GetCurLevel() == m_nPageCount-1) // letzte Seite hat keinen Next Button
+ else if(GetCurLevel() == m_nPageCount-1) // the last page has no next button
{
m_pbNext.Enable(sal_False);
m_pbPrev.Enable(sal_True);
@@ -1041,14 +1042,13 @@ void OCopyTableWizard::CheckButtons()
else
{
m_pbPrev.Enable(sal_True);
- // next has already his state
+ // next already has its state
}
}
// -----------------------------------------------------------------------
void OCopyTableWizard::EnableButton(Wizard_Button_Style eStyle,sal_Bool bEnable)
{
RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "misc", "Ocke.Janssen@sun.com", "OCopyTableWizard::EnableButton" );
-// CheckButtons();
Button* pButton;
if(eStyle == WIZARD_NEXT)
pButton = &m_pbNext;
@@ -1229,7 +1229,7 @@ void OCopyTableWizard::appendColumns( Reference<XColumnsSupplier>& _rxColSup, co
}
else
{
- OSL_ENSURE(sal_False, "OCopyTableWizard::appendColumns: invalid field name!");
+ OSL_FAIL("OCopyTableWizard::appendColumns: invalid field name!");
}
}
@@ -1376,8 +1376,8 @@ Reference< XPropertySet > OCopyTableWizard::createTable()
ODatabaseExport::TPositions::iterator aPosFind = ::std::find_if(
m_vColumnPos.begin(),
m_vColumnPos.end(),
- ::std::compose1( ::std::bind2nd( ::std::equal_to< sal_Int32 >(), nPos ),
- ::std::select1st< ODatabaseExport::TPositions::value_type >()
+ ::o3tl::compose1( ::std::bind2nd( ::std::equal_to< sal_Int32 >(), nPos ),
+ ::o3tl::select1st< ODatabaseExport::TPositions::value_type >()
)
);
@@ -1690,3 +1690,4 @@ void OCopyTableWizard::showError(const Any& _aError)
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/WExtendPages.cxx b/dbaccess/source/ui/misc/WExtendPages.cxx
index a68e916628b8..7d4a770d184b 100644
--- a/dbaccess/source/ui/misc/WExtendPages.cxx
+++ b/dbaccess/source/ui/misc/WExtendPages.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_WIZ_EXTENDPAGES_HXX
#include "WExtendPages.hxx"
-#endif
-#ifndef DBAUI_RTFREADER_HXX
#include "RtfReader.hxx"
-#endif
-#ifndef DBAUI_HTMLREADER_HXX
#include "HtmlReader.hxx"
-#endif
-#ifndef DBAUI_WIZ_COPYTABLEDIALOG_HXX
#include "WCopyTable.hxx"
-#endif
using namespace dbaui;
//========================================================================
@@ -90,3 +83,4 @@ SvParser* OWizNormalExtend::createReader(sal_Int32 /*_nRows*/)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/WNameMatch.cxx b/dbaccess/source/ui/misc/WNameMatch.cxx
index 29f52c3d7bcc..05c26b389668 100644
--- a/dbaccess/source/ui/misc/WNameMatch.cxx
+++ b/dbaccess/source/ui/misc/WNameMatch.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_WIZ_NAMEMATCHING_HXX
#include "WNameMatch.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
+#include <osl/diagnose.h>
#include "FieldDescriptions.hxx"
-#endif
-#ifndef DBAUI_WIZ_COPYTABLEDIALOG_HXX
#include "WCopyTable.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
-#ifndef DBAUI_WIZARD_PAGES_HRC
#include "WizardPages.hrc"
-#endif
-#ifndef _SV_SCRBAR_HXX
#include <vcl/scrbar.hxx>
-#endif
-#ifndef DBAUI_WIZ_COPYTABLEDIALOG_HXX
#include "WCopyTable.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
using namespace ::dbaui;
//========================================================================
@@ -100,12 +81,6 @@ OWizNameMatching::OWizNameMatching( Window* pParent)
m_sDestText = m_FT_TABLE_RIGHT.GetText();
m_sDestText.AppendAscii("\n");
- // set hiContrast
- m_ibColumn_up.SetModeImage(ModuleRes(IMG_SORTUP_H),BMP_COLOR_HIGHCONTRAST);
- m_ibColumn_down.SetModeImage(ModuleRes(IMG_SORTDOWN_H),BMP_COLOR_HIGHCONTRAST);
- m_ibColumn_up_right.SetModeImage(ModuleRes(IMG_SORTUP_H),BMP_COLOR_HIGHCONTRAST);
- m_ibColumn_down_right.SetModeImage(ModuleRes(IMG_SORTDOWN_H),BMP_COLOR_HIGHCONTRAST);
-
FreeResource();
}
// -----------------------------------------------------------------------
@@ -130,7 +105,6 @@ void OWizNameMatching::Reset()
m_bFirstTime = sal_False;
}
- // m_CTRL_LEFT.Clear();
}
// -----------------------------------------------------------------------
void OWizNameMatching::ActivatePage( )
@@ -181,7 +155,7 @@ sal_Bool OWizNameMatching::LeavePage()
while(pLeftEntry && pRightEntry)
{
OFieldDescription* pSrcField = static_cast<OFieldDescription*>(pLeftEntry->GetUserData());
- DBG_ASSERT(pSrcField,"OWizNameMatching: OColumn can not be null!");
+ OSL_ENSURE(pSrcField,"OWizNameMatching: OColumn can not be null!");
ODatabaseExport::TColumnVector::const_iterator aSrcIter = pSrcColumns->begin();
ODatabaseExport::TColumnVector::const_iterator aSrcEnd = pSrcColumns->end();
@@ -189,11 +163,10 @@ sal_Bool OWizNameMatching::LeavePage()
;
const sal_Int32 nPos = ::std::distance(pSrcColumns->begin(),aSrcIter);
- // sal_Int32 nPos = m_CTRL_LEFT.GetModel()->GetAbsPos(pLeftEntry);
if(m_CTRL_LEFT.GetCheckButtonState(pLeftEntry) == SV_BUTTON_CHECKED)
{
OFieldDescription* pDestField = static_cast<OFieldDescription*>(pRightEntry->GetUserData());
- DBG_ASSERT(pDestField,"OWizNameMatching: OColumn can not be null!");
+ OSL_ENSURE(pDestField,"OWizNameMatching: OColumn can not be null!");
const ODatabaseExport::TColumnVector* pDestColumns = m_pParent->getDestVector();
ODatabaseExport::TColumnVector::const_iterator aDestIter = pDestColumns->begin();
ODatabaseExport::TColumnVector::const_iterator aDestEnd = pDestColumns->end();
@@ -247,7 +220,6 @@ IMPL_LINK( OWizNameMatching, ButtonClickHdl, Button *, pButton )
if(pButton == &m_ibColumn_down && (nThumbPos+nVisibleSize+1) < nPos)
{
m_CTRL_LEFT.GetVScroll()->DoScrollAction(SCROLL_LINEDOWN);
- // m_CTRL_LEFT.MakeVisible(pEntry,sal_True);
}
TableListClickHdl(&m_CTRL_LEFT);
@@ -376,18 +348,7 @@ public:
}
virtual void Paint(const Point& rPos, SvLBox& rDev, sal_uInt16 nFlags, SvLBoxEntry* pEntry);
- //virtual void InitViewData( SvLBox* pView,SvLBoxEntry* pEntry, SvViewDataItem* pViewData);
};
-
-
-
-//------------------------------------------------------------------------
-/*
-void OColumnString::InitViewData( SvLBox* pView,SvLBoxEntry* pEntry, SvViewDataItem* pViewData)
-{
- SvLBoxString::InitViewData(pView,pEntry,pViewData);
-}
-*/
//------------------------------------------------------------------------
void OColumnString::Paint(const Point& rPos, SvLBox& rDev, sal_uInt16 /*nFlags*/, SvLBoxEntry* /*pEntry*/ )
{
@@ -448,3 +409,4 @@ void OColumnTreeBox::FillListBox( const ODatabaseExport::TColumnVector& _rList)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/WTypeSelect.cxx b/dbaccess/source/ui/misc/WTypeSelect.cxx
index ec6ac7b90067..151ed18ffaf5 100644
--- a/dbaccess/source/ui/misc/WTypeSelect.cxx
+++ b/dbaccess/source/ui/misc/WTypeSelect.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,48 +28,20 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_WIZ_TYPESELECT_HXX
#include "WTypeSelect.hxx"
-#endif
-#ifndef DBAUI_WIZARD_PAGES_HRC
#include "WizardPages.hrc"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
+#include <osl/diagnose.h>
#include "FieldDescriptions.hxx"
-#endif
-#ifndef DBAUI_WIZ_COPYTABLEDIALOG_HXX
#include "WCopyTable.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
-#ifndef _STREAM_HXX
#include <tools/stream.hxx>
-#endif
-#ifndef _SVPARSER_HXX
#include <svtools/svparser.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef DBAUI_FIELDCONTROLS_HXX
#include "FieldControls.hxx"
-#endif
#include "dbaccess_slotid.hrc"
@@ -78,7 +51,6 @@ using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::container;
using namespace ::com::sun::star::util;
using namespace ::com::sun::star::sdbc;
-// using namespace ::com::sun::star::sdbcx;
//========================================================================
// OWizTypeSelectControl
@@ -127,7 +99,7 @@ void OWizTypeSelectControl::DeactivateAggregate( EControlType eType )
// -----------------------------------------------------------------------
void OWizTypeSelectControl::CellModified(long nRow, sal_uInt16 nColId )
{
- DBG_ASSERT(nRow == -1,"nRow muss -1 sein!");
+ OSL_ENSURE(nRow == -1,"nRow muss -1 sein!");
(void)nRow;
MultiListBox &aListBox = ((OWizTypeSelect*)GetParent())->m_lbColumnNames;
@@ -275,7 +247,7 @@ OWizTypeSelect::OWizTypeSelect( Window* pParent, SvStream* _pStream )
DBG_CTOR(OWizTypeSelect,NULL);
m_lbColumnNames.SetSelectHdl(LINK(this,OWizTypeSelect,ColumnSelectHdl));
- ModuleRes aModuleRes(isHiContrast(&m_lbColumnNames) ? IMG_JOINS_H : IMG_JOINS);
+ ModuleRes aModuleRes(IMG_JOINS);
ImageList aImageList(aModuleRes);
m_imgPKey = aImageList.GetImage(IMG_PRIMARY_KEY);
@@ -493,7 +465,7 @@ void OWizTypeSelect::fillColumnList(sal_uInt32 nRows)
DBG_CHKTHIS(OWizTypeSelect,NULL);
if(m_pParserStream)
{
- sal_uInt32 nTell = m_pParserStream->Tell(); // verändert vielleicht die Position des Streams
+ sal_uInt32 nTell = m_pParserStream->Tell(); // might change seek position of stream
SvParser *pReader = createReader(nRows);
if(pReader)
@@ -508,3 +480,4 @@ void OWizTypeSelect::fillColumnList(sal_uInt32 nRows)
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/WizardPages.src b/dbaccess/source/ui/misc/WizardPages.src
index d9c9772d2a41..360ab879a102 100644
--- a/dbaccess/source/ui/misc/WizardPages.src
+++ b/dbaccess/source/ui/misc/WizardPages.src
@@ -72,7 +72,6 @@ ModalDialog WIZ_RTFCOPYTABLE
Text [ en-US ] = "Copy RTF Table" ;
-
OutputSize = TRUE ;
SVLook = TRUE ;
Moveable = TRUE ;
@@ -127,11 +126,10 @@ TabPage TAB_WIZ_COLUMN_SELECT
FixedLine FL_COLUMN_SELECT
{
- Pos = MAP_APPFONT ( 6 , 3 ) ;
- Size = MAP_APPFONT ( WINDOW_SIZE_X - 12 , 8 ) ;
- Text [ en-US ] = "Existing columns" ;
+ Pos = MAP_APPFONT ( 6 , 3 ) ;
+ Size = MAP_APPFONT ( WINDOW_SIZE_X - 12 , 8 ) ;
+ Text [ en-US ] = "Existing columns" ;
};
-
MultiListBox LB_ORG_COLUMN_NAMES
{
HelpID = "dbaccess:MultiListBox:TAB_WIZ_COLUMN_SELECT:LB_ORG_COLUMN_NAMES";
@@ -155,7 +153,7 @@ TabPage TAB_WIZ_COLUMN_SELECT
{
ImageBitmap = Bitmap
{
- File = "one_right.bmp" ;
+ File = "one_right.png" ;
};
MaskColor = Color
{
@@ -176,7 +174,7 @@ TabPage TAB_WIZ_COLUMN_SELECT
{
ImageBitmap = Bitmap
{
- File = "all_right.bmp" ;
+ File = "all_right.png" ;
};
MaskColor = Color
{
@@ -196,7 +194,7 @@ TabPage TAB_WIZ_COLUMN_SELECT
{
ImageBitmap = Bitmap
{
- File = "one_left.bmp" ;
+ File = "one_left.png1" ;
};
MaskColor = Color
{
@@ -216,7 +214,7 @@ TabPage TAB_WIZ_COLUMN_SELECT
{
ImageBitmap = Bitmap
{
- File = "all_left.bmp" ;
+ File = "all_left.png" ;
};
MaskColor = Color
{
@@ -328,6 +326,7 @@ Menu RID_SBA_RTF_PKEYPOPUP
};
};
};
+
//==================================================================
// TAB_WIZ_NAME_MATCHING
//==================================================================
@@ -384,7 +383,7 @@ TabPage TAB_WIZ_NAME_MATCHING
{
ImageBitmap = Bitmap
{
- File = "sortup.bmp" ;
+ File = "sortup.png" ;
};
MaskColor = Color
{
@@ -404,7 +403,7 @@ TabPage TAB_WIZ_NAME_MATCHING
{
ImageBitmap = Bitmap
{
- File = "sortdown.bmp" ;
+ File = "sortdown.png" ;
};
MaskColor = Color
{
@@ -425,7 +424,7 @@ TabPage TAB_WIZ_NAME_MATCHING
{
ImageBitmap = Bitmap
{
- File = "sortup.bmp" ;
+ File = "sortup.png" ;
};
MaskColor = Color
{
@@ -445,7 +444,7 @@ TabPage TAB_WIZ_NAME_MATCHING
{
ImageBitmap = Bitmap
{
- File = "sortdown.bmp" ;
+ File = "sortdown.png" ;
};
MaskColor = Color
{
@@ -474,6 +473,7 @@ TabPage TAB_WIZ_NAME_MATCHING
Text [ en-US ] = "Non~e" ;
};
};
+
TabPage TAB_WIZ_COPYTABLE
{
SVLook = TRUE ;
@@ -590,69 +590,3 @@ String STR_INVALID_TABLE_NAME_LENGTH
{
Text [ en-US ] = "Please change the table name. It is too long.";
};
-
-Image IMG_SORTUP_H
-{
- ImageBitmap = Bitmap
- {
- File = "sortup_h.bmp" ;
- };
- MaskColor = Color
- {
- Red = 0xFFFF ;
- Green = 0x0000 ;
- Blue = 0xFFFF ;
- };
-};
-
-Image IMG_SORTDOWN_H
-{
- ImageBitmap = Bitmap
- {
- File = "sortdown_h.bmp" ;
- };
- MaskColor = Color
- {
- Red = 0xFFFF ;
- Green = 0x0000 ;
- Blue = 0xFFFF ;
- };
-};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/misc/asyncmodaldialog.cxx b/dbaccess/source/ui/misc/asyncmodaldialog.cxx
index 07dc633f52b4..8ea2e88fafee 100644
--- a/dbaccess/source/ui/misc/asyncmodaldialog.cxx
+++ b/dbaccess/source/ui/misc/asyncmodaldialog.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,22 +29,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_ASYNCMODALDIALOG_HXX
#include "asyncmodaldialog.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_LANG_ILLEGALARGUMENTEXCEPTION_HPP_
#include <com/sun/star/lang/IllegalArgumentException.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
//........................................................................
namespace dbaui
@@ -119,3 +112,4 @@ namespace dbaui
} // namespace dbaui
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/charsets.cxx b/dbaccess/source/ui/misc/charsets.cxx
index 3f50320b27f4..993630d6599e 100644
--- a/dbaccess/source/ui/misc/charsets.cxx
+++ b/dbaccess/source/ui/misc/charsets.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_CHARSETS_HXX_
#include "charsets.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _DBU_MISC_HRC_
+#include <osl/diagnose.h>
#include "dbu_misc.hrc"
-#endif
-#ifndef _RTL_TENCINFO_H
#include <rtl/tencinfo.h>
-#endif
-#ifndef _TOOLS_RCID_H
#include <tools/rcid.h>
-#endif
-#ifndef _DBAUI_LOCALRESACCESS_HXX_
#include "localresaccess.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -133,7 +122,7 @@ namespace dbaui
:CharsetDisplayDerefHelper_Base(_rBase)
,m_sDisplayName(_rDisplayName)
{
- DBG_ASSERT( m_sDisplayName.getLength(), "CharsetDisplayDerefHelper::CharsetDisplayDerefHelper: invalid display name!" );
+ OSL_ENSURE( m_sDisplayName.getLength(), "CharsetDisplayDerefHelper::CharsetDisplayDerefHelper: invalid display name!" );
}
//=========================================================================
@@ -144,7 +133,7 @@ namespace dbaui
:m_pContainer(_pContainer)
,m_aPosition(_rPosition)
{
- DBG_ASSERT(m_pContainer, "OCharsetDisplay::ExtendedCharsetIterator::ExtendedCharsetIterator : invalid container!");
+ OSL_ENSURE(m_pContainer, "OCharsetDisplay::ExtendedCharsetIterator::ExtendedCharsetIterator : invalid container!");
}
//-------------------------------------------------------------------------
@@ -157,7 +146,7 @@ namespace dbaui
//-------------------------------------------------------------------------
CharsetDisplayDerefHelper OCharsetDisplay::ExtendedCharsetIterator::operator*() const
{
- DBG_ASSERT( m_aPosition != m_pContainer->OCharsetDisplay_Base::end(), "OCharsetDisplay::ExtendedCharsetIterator::operator* : invalid position!");
+ OSL_ENSURE( m_aPosition != m_pContainer->OCharsetDisplay_Base::end(), "OCharsetDisplay::ExtendedCharsetIterator::operator* : invalid position!");
rtl_TextEncoding eEncoding = (*m_aPosition).getEncoding();
return CharsetDisplayDerefHelper(
@@ -169,7 +158,7 @@ namespace dbaui
//-------------------------------------------------------------------------
const OCharsetDisplay::ExtendedCharsetIterator& OCharsetDisplay::ExtendedCharsetIterator::operator++()
{
- DBG_ASSERT( m_aPosition != m_pContainer->OCharsetDisplay_Base::end(), "OCharsetDisplay::ExtendedCharsetIterator::operator++ : invalid position!");
+ OSL_ENSURE( m_aPosition != m_pContainer->OCharsetDisplay_Base::end(), "OCharsetDisplay::ExtendedCharsetIterator::operator++ : invalid position!");
if ( m_aPosition != m_pContainer->OCharsetDisplay_Base::end() )
++m_aPosition;
return *this;
@@ -178,7 +167,7 @@ namespace dbaui
//-------------------------------------------------------------------------
const OCharsetDisplay::ExtendedCharsetIterator& OCharsetDisplay::ExtendedCharsetIterator::operator--()
{
- DBG_ASSERT( m_aPosition != m_pContainer->OCharsetDisplay_Base::begin(), "OCharsetDisplay::ExtendedCharsetIterator::operator-- : invalid position!");
+ OSL_ENSURE( m_aPosition != m_pContainer->OCharsetDisplay_Base::begin(), "OCharsetDisplay::ExtendedCharsetIterator::operator-- : invalid position!");
if ( m_aPosition != m_pContainer->OCharsetDisplay_Base::begin() )
--m_aPosition;
return *this;
@@ -194,3 +183,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/controllerframe.cxx b/dbaccess/source/ui/misc/controllerframe.cxx
index 67f45f31bb4f..8e50d0d00c6b 100644
--- a/dbaccess/source/ui/misc/controllerframe.cxx
+++ b/dbaccess/source/ui/misc/controllerframe.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -238,7 +239,7 @@ namespace dbaui
{
if ( _rData.m_xDocEventBroadcaster.is() )
{
- ::rtl::OUString sEventName( ::rtl::OUString::createFromAscii( _bActive ? "OnFocus" : "OnUnfocus" ) );
+ ::rtl::OUString sEventName = _bActive ? rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OnFocus")) : rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("OnUnfocus"));
Reference< XController2 > xController( _rData.m_rController.getXController(), UNO_QUERY_THROW );
_rData.m_xDocEventBroadcaster->notifyDocumentEvent( sEventName, xController, Any() );
}
@@ -297,11 +298,6 @@ namespace dbaui
const Window* pContainerWindow = VCLUnoHelper::GetWindow( xContainerWindow );
ENSURE_OR_THROW( pContainerWindow, "no Window implementation for the frame's container window!" );
- /*const Window* pContainerParentWindow = pContainerWindow->GetParent();
- if ( pContainerParentWindow && ( pContainerParentWindow->GetType() == WINDOW_BORDERWINDOW ) )
- pContainerParentWindow = pContainerParentWindow->GetParent();
- m_pData->m_bIsTopLevelDocumentWindow = ( pContainerParentWindow == NULL );*/
-
m_pData->m_bIsTopLevelDocumentWindow = ( pContainerWindow->GetExtendedStyle() & WB_EXT_DOCUMENT ) != 0;
}
@@ -444,3 +440,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/databaseobjectview.cxx b/dbaccess/source/ui/misc/databaseobjectview.cxx
index 4eb6e0717546..4850b7e6cf42 100644
--- a/dbaccess/source/ui/misc/databaseobjectview.cxx
+++ b/dbaccess/source/ui/misc/databaseobjectview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -130,16 +131,16 @@ namespace dbaui
// if we have no externally provided frame, create one
if ( !m_xFrameLoader.is() )
{
- Reference< XSingleServiceFactory > xFact(m_xORB->createInstance(::rtl::OUString::createFromAscii("com.sun.star.frame.TaskCreator")), UNO_QUERY_THROW);
+ Reference< XSingleServiceFactory > xFact(m_xORB->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.TaskCreator"))), UNO_QUERY_THROW);
Sequence< Any > lArgs(2);
NamedValue aProp;
sal_Int32 nArg = 0;
- aProp.Name = ::rtl::OUString::createFromAscii("ParentFrame");
+ aProp.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ParentFrame"));
aProp.Value <<= m_xParentFrame;
lArgs[nArg++] <<= aProp;
- aProp.Name = ::rtl::OUString::createFromAscii("TopWindow");
+ aProp.Name = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("TopWindow"));
aProp.Value <<= sal_True;
lArgs[nArg++] <<= aProp;
@@ -339,3 +340,4 @@ namespace dbaui
} // namespace dbaui
// .........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/datasourceconnector.cxx b/dbaccess/source/ui/misc/datasourceconnector.cxx
index 2a468288bc64..dc1dec8830cc 100644
--- a/dbaccess/source/ui/misc/datasourceconnector.cxx
+++ b/dbaccess/source/ui/misc/datasourceconnector.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,72 +29,28 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_DATASOURCECONNECTOR_HXX_
#include "datasourceconnector.hxx"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XWARNINGSSUPPLIER_HPP_
#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XCOMPLETEDCONNECTION_HPP_
#include <com/sun/star/sdb/XCompletedConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONHANDLER_HPP_
#include <com/sun/star/task/XInteractionHandler.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XMODEL_HPP_
#include <com/sun/star/frame/XModel.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLWARNING_HPP_
#include <com/sun/star/sdbc/SQLWarning.hpp>
-#endif
-#ifndef _OSL_THREAD_H_
#include <osl/thread.h>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef COMPHELPER_NAMEDVALUECOLLECTION_HXX
#include <comphelper/namedvaluecollection.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _VCL_STDTEXT_HXX
#include <vcl/stdtext.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX
#include <vcl/button.hxx>
-#endif
-#ifndef SVTOOLS_FILENOTATION_HXX
#include <svl/filenotation.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
#include "moduledbu.hxx"
//.........................................................................
@@ -275,3 +232,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/dbaundomanager.cxx b/dbaccess/source/ui/misc/dbaundomanager.cxx
index f1cde68b8ce7..d369c6905ea8 100755..100644
--- a/dbaccess/source/ui/misc/dbaundomanager.cxx
+++ b/dbaccess/source/ui/misc/dbaundomanager.cxx
@@ -34,7 +34,6 @@
#include <svl/undo.hxx>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
#include <framework/undomanagerhelper.hxx>
//......................................................................................................................
@@ -263,7 +262,7 @@ namespace dbaui
//------------------------------------------------------------------------------------------------------------------
void SAL_CALL UndoManager::undo( ) throw (EmptyUndoStackException, UndoContextNotClosedException, UndoFailedException, RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
// (all our UndoActions work directly on VCL code, usually, so ...)
UndoManagerMethodGuard aGuard( *m_pImpl );
m_pImpl->aUndoHelper.undo( aGuard );
@@ -272,7 +271,7 @@ namespace dbaui
//------------------------------------------------------------------------------------------------------------------
void SAL_CALL UndoManager::redo( ) throw (EmptyUndoStackException, UndoContextNotClosedException, UndoFailedException, RuntimeException)
{
- ::vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
// (all our UndoActions work directly on VCL code, usually, so ...)
UndoManagerMethodGuard aGuard( *m_pImpl );
m_pImpl->aUndoHelper.redo( aGuard );
diff --git a/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx b/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx
index 059c32dfc03d..8d8e15f59ae9 100644
--- a/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx
+++ b/dbaccess/source/ui/misc/dbsubcomponentcontroller.cxx
@@ -308,7 +308,7 @@ namespace dbaui
if(xSupplier.is())
{
m_pImpl->m_xFormatter = Reference< XNumberFormatter >(getORB()
- ->createInstance(::rtl::OUString::createFromAscii("com.sun.star.util.NumberFormatter")), UNO_QUERY);
+ ->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.util.NumberFormatter"))), UNO_QUERY);
m_pImpl->m_xFormatter->attachNumberFormatsSupplier(xSupplier);
}
OSL_ENSURE(m_pImpl->m_xFormatter.is(),"No NumberFormatter!");
diff --git a/dbaccess/source/ui/misc/dbumiscres.src b/dbaccess/source/ui/misc/dbumiscres.src
index 22bc80670cf6..974b36e68005 100644
--- a/dbaccess/source/ui/misc/dbumiscres.src
+++ b/dbaccess/source/ui/misc/dbumiscres.src
@@ -61,7 +61,6 @@ String STR_MISSING_TABLES_XDROP
String STR_BUTTON_TEXT_ALL
{
Text [ en-US ] = "~All";
-
};
String STR_UNDO_COLON
@@ -93,6 +92,7 @@ String STR_NAMED_OBJECT_ALREADY_EXISTS
{
Text [ en-US ] = "The name '$#$' already exists.\nPlease enter another name." ;
};
+
String RID_STR_EXTENSION_NOT_PRESENT
{
// #i96130# use hard coded name
diff --git a/dbaccess/source/ui/misc/defaultobjectnamecheck.cxx b/dbaccess/source/ui/misc/defaultobjectnamecheck.cxx
index afb5d8c4c9fb..6a85b6a9be95 100644
--- a/dbaccess/source/ui/misc/defaultobjectnamecheck.cxx
+++ b/dbaccess/source/ui/misc/defaultobjectnamecheck.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,56 +29,28 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_SOURCE_UI_MISC_DEFAULTOBJECTNAMECHECK_HXX
#include "defaultobjectnamecheck.hxx"
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_LANG_ILLEGALARGUMENTEXCEPTION_HPP_
#include <com/sun/star/lang/IllegalArgumentException.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XQUERIESSUPPLIER_HPP_
#include <com/sun/star/sdb/XQueriesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_COMMANDTYPE_HPP_
#include <com/sun/star/sdb/CommandType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_TOOLS_XCONNECTIONTOOLS_HPP_
#include <com/sun/star/sdb/tools/XConnectionTools.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef CONNECTIVITY_INC_CONNECTIVITY_DBMETADATA_HXX
#include <connectivity/dbmetadata.hxx>
-#endif
-#ifndef _RTL_USTRBUF_HXX_
#include <rtl/ustrbuf.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _CPPUHELPER_EXC_HLP_HXX_
#include <cppuhelper/exc_hlp.hxx>
-#endif
#include <vector>
#include <boost/shared_ptr.hpp>
@@ -230,3 +203,4 @@ namespace dbaui
} // namespace dbaui
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/dsmeta.cxx b/dbaccess/source/ui/misc/dsmeta.cxx
index b5517e1b468f..7c70f65e7a4e 100644
--- a/dbaccess/source/ui/misc/dsmeta.cxx
+++ b/dbaccess/source/ui/misc/dsmeta.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -153,9 +154,9 @@ namespace dbaui
{
::rtl::OUString sAuth;
aMetaData.get("Authentication") >>= sAuth;
- if ( sAuth.equalsAscii("UserPassword") )
+ if ( sAuth.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("UserPassword")) )
aInit = AuthUserPwd;
- else if ( sAuth.equalsAscii("Password") )
+ else if ( sAuth.equalsAsciiL(RTL_CONSTASCII_STRINGPARAM("Password")) )
aInit = AuthPwd;
}
s_aSupport.insert(Supported::value_type(*pIter,aInit));
@@ -214,3 +215,5 @@ namespace dbaui
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/imageprovider.cxx b/dbaccess/source/ui/misc/imageprovider.cxx
index 4be0472a12f2..d46d540cb462 100644
--- a/dbaccess/source/ui/misc/imageprovider.cxx
+++ b/dbaccess/source/ui/misc/imageprovider.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -81,15 +82,12 @@ namespace dbaui
{
//................................................................
static void lcl_getConnectionProvidedTableIcon_nothrow( const ImageProvider_Data& _rData,
- const ::rtl::OUString& _rName, Reference< XGraphic >& _out_rxGraphic, Reference< XGraphic >& _out_rxGraphicHC )
+ const ::rtl::OUString& _rName, Reference< XGraphic >& _out_rxGraphic )
{
try
{
if ( _rData.xTableUI.is() )
- {
_out_rxGraphic = _rData.xTableUI->getTableIcon( _rName, GraphicColorMode::NORMAL );
- _out_rxGraphicHC = _rData.xTableUI->getTableIcon( _rName, GraphicColorMode::HIGH_CONTRAST );
- }
}
catch( const Exception& )
{
@@ -99,21 +97,19 @@ namespace dbaui
//................................................................
static void lcl_getTableImageResourceID_nothrow( const ImageProvider_Data& _rData, const ::rtl::OUString& _rName,
- sal_uInt16& _out_rResourceID, sal_uInt16& _out_rResourceID_HC )
+ sal_uInt16& _out_rResourceID)
{
- _out_rResourceID = _out_rResourceID_HC = 0;
+ _out_rResourceID = 0;
try
{
bool bIsView = _rData.xViews.is() && _rData.xViews->hasByName( _rName );
if ( bIsView )
{
_out_rResourceID = VIEW_TREE_ICON;
- _out_rResourceID_HC = VIEW_TREE_ICON_SCH;
}
else
{
_out_rResourceID = TABLE_TREE_ICON;
- _out_rResourceID_HC = TABLE_TREE_ICON_SCH;
}
}
catch( const Exception& )
@@ -151,95 +147,88 @@ namespace dbaui
}
//--------------------------------------------------------------------
- void ImageProvider::getImages( const String& _rName, const sal_Int32 _nDatabaseObjectType, Image& _out_rImage, Image& _out_rImageHC )
+ void ImageProvider::getImages( const String& _rName, const sal_Int32 _nDatabaseObjectType, Image& _out_rImage )
{
if ( _nDatabaseObjectType != DatabaseObject::TABLE )
{
// for types other than tables, the icon does not depend on the concrete object
- _out_rImage = getDefaultImage( _nDatabaseObjectType, false );
- _out_rImageHC = getDefaultImage( _nDatabaseObjectType, true );
+ _out_rImage = getDefaultImage( _nDatabaseObjectType );
}
else
{
// check whether the connection can give us an icon
Reference< XGraphic > xGraphic;
- Reference< XGraphic > xGraphicHC;
- lcl_getConnectionProvidedTableIcon_nothrow( *m_pData, _rName, xGraphic, xGraphicHC );
+ lcl_getConnectionProvidedTableIcon_nothrow( *m_pData, _rName, xGraphic );
if ( xGraphic.is() )
_out_rImage = Image( xGraphic );
- if ( xGraphicHC.is() )
- _out_rImageHC = Image( xGraphicHC );
- if ( !_out_rImage || !_out_rImageHC )
+ if ( !_out_rImage )
{
// no -> determine by type
sal_uInt16 nImageResourceID = 0;
- sal_uInt16 nImageResourceID_HC = 0;
- lcl_getTableImageResourceID_nothrow( *m_pData, _rName, nImageResourceID, nImageResourceID_HC );
+ lcl_getTableImageResourceID_nothrow( *m_pData, _rName, nImageResourceID );
if ( nImageResourceID && !_out_rImage )
_out_rImage = Image( ModuleRes( nImageResourceID ) );
- if ( nImageResourceID_HC && !_out_rImageHC )
- _out_rImageHC = Image( ModuleRes( nImageResourceID_HC ) );
}
}
}
//--------------------------------------------------------------------
- Image ImageProvider::getDefaultImage( sal_Int32 _nDatabaseObjectType, bool _bHighContrast )
+ Image ImageProvider::getDefaultImage( sal_Int32 _nDatabaseObjectType )
{
Image aObjectImage;
- sal_uInt16 nImageResourceID( getDefaultImageResourceID( _nDatabaseObjectType, _bHighContrast ) );
+ sal_uInt16 nImageResourceID( getDefaultImageResourceID( _nDatabaseObjectType) );
if ( nImageResourceID )
aObjectImage = Image( ModuleRes( nImageResourceID ) );
return aObjectImage;
}
//--------------------------------------------------------------------
- sal_uInt16 ImageProvider::getDefaultImageResourceID( sal_Int32 _nDatabaseObjectType, bool _bHighContrast )
+ sal_uInt16 ImageProvider::getDefaultImageResourceID( sal_Int32 _nDatabaseObjectType)
{
sal_uInt16 nImageResourceID( 0 );
switch ( _nDatabaseObjectType )
{
case DatabaseObject::QUERY:
- nImageResourceID = _bHighContrast ? QUERY_TREE_ICON_SCH : QUERY_TREE_ICON;
+ nImageResourceID = QUERY_TREE_ICON;
break;
case DatabaseObject::FORM:
- nImageResourceID = _bHighContrast ? FORM_TREE_ICON_SCH : FORM_TREE_ICON;
+ nImageResourceID = FORM_TREE_ICON;
break;
case DatabaseObject::REPORT:
- nImageResourceID = _bHighContrast ? REPORT_TREE_ICON_SCH : REPORT_TREE_ICON;
+ nImageResourceID = REPORT_TREE_ICON;
break;
case DatabaseObject::TABLE:
- nImageResourceID = _bHighContrast ? TABLE_TREE_ICON_SCH : TABLE_TREE_ICON;
+ nImageResourceID = TABLE_TREE_ICON;
break;
default:
- OSL_ENSURE( false, "ImageProvider::getDefaultImage: invalid database object type!" );
+ OSL_FAIL( "ImageProvider::getDefaultImage: invalid database object type!" );
break;
}
return nImageResourceID;
}
//--------------------------------------------------------------------
- Image ImageProvider::getFolderImage( sal_Int32 _nDatabaseObjectType, bool _bHighContrast )
+ Image ImageProvider::getFolderImage( sal_Int32 _nDatabaseObjectType )
{
sal_uInt16 nImageResourceID( 0 );
switch ( _nDatabaseObjectType )
{
case DatabaseObject::QUERY:
- nImageResourceID = _bHighContrast ? QUERYFOLDER_TREE_ICON_SCH : QUERYFOLDER_TREE_ICON;
+ nImageResourceID = QUERYFOLDER_TREE_ICON;
break;
case DatabaseObject::FORM:
- nImageResourceID = _bHighContrast ? FORMFOLDER_TREE_ICON_SCH : FORMFOLDER_TREE_ICON;
+ nImageResourceID = FORMFOLDER_TREE_ICON;
break;
case DatabaseObject::REPORT:
- nImageResourceID = _bHighContrast ? REPORTFOLDER_TREE_ICON_SCH : REPORTFOLDER_TREE_ICON;
+ nImageResourceID = REPORTFOLDER_TREE_ICON;
break;
case DatabaseObject::TABLE:
- nImageResourceID = _bHighContrast ? TABLEFOLDER_TREE_ICON_SCH : TABLEFOLDER_TREE_ICON;
+ nImageResourceID = TABLEFOLDER_TREE_ICON;
break;
default:
- OSL_ENSURE( false, "ImageProvider::getDefaultImage: invalid database object type!" );
+ OSL_FAIL( "ImageProvider::getDefaultImage: invalid database object type!" );
break;
}
@@ -250,12 +239,13 @@ namespace dbaui
}
//--------------------------------------------------------------------
- Image ImageProvider::getDatabaseImage( bool _bHighContrast )
+ Image ImageProvider::getDatabaseImage()
{
- return Image( ModuleRes( _bHighContrast ? DATABASE_TREE_ICON_SCH : DATABASE_TREE_ICON ) );
+ return Image( ModuleRes( DATABASE_TREE_ICON ) );
}
//........................................................................
} // namespace dbaui
//........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/indexcollection.cxx b/dbaccess/source/ui/misc/indexcollection.cxx
index 81f8fca678b4..4cb0942ef32e 100644
--- a/dbaccess/source/ui/misc/indexcollection.cxx
+++ b/dbaccess/source/ui/misc/indexcollection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_INDEXCOLLECTION_HXX_
#include "indexcollection.hxx"
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDROP_HPP_
#include <com/sun/star/sdbcx/XDrop.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
//......................................................................
namespace dbaui
@@ -82,12 +65,6 @@ namespace dbaui
}
//------------------------------------------------------------------
-// OIndexCollection::OIndexCollection(const Reference< XNameAccess >& _rxIndexes)
-// {
-// implConstructFrom(_rxIndexes);
-// }
-
- //------------------------------------------------------------------
const OIndexCollection& OIndexCollection::operator=(const OIndexCollection& _rSource)
{
detach();
@@ -180,7 +157,7 @@ namespace dbaui
Reference< XAppend > xAppendIndex(xIndexFactory, UNO_QUERY);
if (!xAppendIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::commitNewIndex: missing an interface of the index container!");
+ OSL_FAIL("OIndexCollection::commitNewIndex: missing an interface of the index container!");
return;
}
@@ -194,14 +171,14 @@ namespace dbaui
Reference< XAppend > xAppendCols(xColumnFactory, UNO_QUERY);
if (!xAppendCols.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::commitNewIndex: invalid index descriptor returned!");
+ OSL_FAIL("OIndexCollection::commitNewIndex: invalid index descriptor returned!");
return;
}
// set the properties
- static const ::rtl::OUString s_sUniquePropertyName = ::rtl::OUString::createFromAscii("IsUnique");
- static const ::rtl::OUString s_sSortPropertyName = ::rtl::OUString::createFromAscii("IsAscending");
- static const ::rtl::OUString s_sNamePropertyName = ::rtl::OUString::createFromAscii("Name");
+ static const ::rtl::OUString s_sUniquePropertyName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsUnique"));
+ static const ::rtl::OUString s_sSortPropertyName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsAscending"));
+ static const ::rtl::OUString s_sNamePropertyName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Name"));
// the index' own props
xIndexDescriptor->setPropertyValue(s_sUniquePropertyName, ::cppu::bool2any(_rPos->bUnique));
xIndexDescriptor->setPropertyValue(s_sNamePropertyName, makeAny(_rPos->sName));
@@ -249,7 +226,7 @@ namespace dbaui
Reference< XDrop > xDropIndex(m_xIndexes, UNO_QUERY);
if (!xDropIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::drop: no XDrop interface!");
+ OSL_FAIL("OIndexCollection::drop: no XDrop interface!");
return sal_False;
}
@@ -296,7 +273,7 @@ namespace dbaui
m_xIndexes->getByName(_rIndex.getOriginalName()) >>= xIndex;
if (!xIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::implFillIndexInfo: got an invalid index object!");
+ OSL_FAIL("OIndexCollection::implFillIndexInfo: got an invalid index object!");
}
else
implFillIndexInfo(_rIndex, xIndex);
@@ -305,10 +282,10 @@ namespace dbaui
//------------------------------------------------------------------
void OIndexCollection::implFillIndexInfo(OIndex& _rIndex, Reference< XPropertySet > _rxDescriptor) SAL_THROW((Exception))
{
- static const ::rtl::OUString s_sPrimaryIndexPropertyName = ::rtl::OUString::createFromAscii("IsPrimaryKeyIndex");
- static const ::rtl::OUString s_sUniquePropertyName = ::rtl::OUString::createFromAscii("IsUnique");
- static const ::rtl::OUString s_sSortPropertyName = ::rtl::OUString::createFromAscii("IsAscending");
- static const ::rtl::OUString s_sCatalogPropertyName = ::rtl::OUString::createFromAscii("Catalog");
+ static const ::rtl::OUString s_sPrimaryIndexPropertyName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsPrimaryKeyIndex"));
+ static const ::rtl::OUString s_sUniquePropertyName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsUnique"));
+ static const ::rtl::OUString s_sSortPropertyName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("IsAscending"));
+ static const ::rtl::OUString s_sCatalogPropertyName = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("Catalog"));
_rIndex.bPrimaryKey = ::cppu::any2bool(_rxDescriptor->getPropertyValue(s_sPrimaryIndexPropertyName));
_rIndex.bUnique = ::cppu::any2bool(_rxDescriptor->getPropertyValue(s_sUniquePropertyName));
@@ -337,7 +314,7 @@ namespace dbaui
xCols->getByName(*pFieldNames) >>= xIndexColumn;
if (!xIndexColumn.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::implFillIndexInfo: invalid index column!");
+ OSL_FAIL("OIndexCollection::implFillIndexInfo: invalid index column!");
--aCopyTo;
continue;
}
@@ -406,7 +383,7 @@ namespace dbaui
m_xIndexes->getByName(*pNames) >>= xIndex;
if (!xIndex.is())
{
- OSL_ENSURE(sal_False, "OIndexCollection::implConstructFrom: got an invalid index object ... ignoring!");
+ OSL_FAIL("OIndexCollection::implConstructFrom: got an invalid index object ... ignoring!");
continue;
}
@@ -422,3 +399,4 @@ namespace dbaui
} // namespace dbaui
//......................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/linkeddocuments.cxx b/dbaccess/source/ui/misc/linkeddocuments.cxx
index 38c8f0c65c05..c8b8e6085d20 100644
--- a/dbaccess/source/ui/misc/linkeddocuments.cxx
+++ b/dbaccess/source/ui/misc/linkeddocuments.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,107 +29,42 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_LINKEDDOCUMENTS_HXX_
#include "linkeddocuments.hxx"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
#include <tools/diagnose_ex.h>
#include <unotools/confignode.hxx>
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
#include <comphelper/classids.hxx>
-#ifndef COMPHELPER_NAMEDVALUECOLLECTION_HXX
#include <comphelper/namedvaluecollection.hxx>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSINGLESERVICEFACTORY_HPP_
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XDISPATCHPROVIDER_HPP_
#include <com/sun/star/frame/XDispatchProvider.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_XCOMPONENTLOADER_HPP_
#include <com/sun/star/frame/XComponentLoader.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_URL_HPP_
#include <com/sun/star/util/URL.hpp>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_XCOMMANDPROCESSOR_HPP_
#include <com/sun/star/ucb/XCommandProcessor.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_OPENCOMMANDARGUMENT_HPP_
#include <com/sun/star/ucb/OpenCommandArgument.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UCB_OPENMODE_HPP_
#include <com/sun/star/ucb/OpenMode.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XJOBEXECUTOR_HPP_
#include <com/sun/star/task/XJobExecutor.hpp>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _UCBHELPER_CONTENT_HXX
#include <ucbhelper/content.hxx>
-#endif
-#ifndef _DBU_MISC_HRC_
#include "dbu_misc.hrc"
-#endif
-#ifndef SVTOOLS_FILENOTATION_HXX_
#include <svl/filenotation.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _SFXNEW_HXX
#include <sfx2/new.hxx>
-#endif
-#ifndef _SVTOOLS_TEMPLDLG_HXX
-#include <svtools/templdlg.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
// -----------------
// for calling basic
-#ifndef _SFXAPP_HXX
#include <sfx2/app.hxx>
-#endif
-#ifndef _SBXCLASS_HXX
#include <basic/sbx.hxx>
-#endif
-#ifndef _SB_SBUNO_HXX
#include <basic/sbuno.hxx>
-#endif
-#ifndef _EHDL_HXX
#include <svtools/ehdl.hxx>
-#endif
-#ifndef _SVX_DATACCESSDESCRIPTOR_HXX_
#include <svx/dataaccessdescriptor.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XHIERARCHICALNAMECONTAINER_HPP_
#include <com/sun/star/container/XHierarchicalNameContainer.hpp>
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _COMPHELPER_MIMECONFIGHELPER_HXX_
#include <comphelper/mimeconfighelper.hxx>
-#endif
#include <cppuhelper/exc_hlp.hxx>
#include <connectivity/dbtools.hxx>
@@ -235,7 +171,7 @@ namespace dbaui
break;
default:
- OSL_ENSURE( false, "OLinkedDocumentsAccess::implOpen: invalid open mode!" );
+ OSL_FAIL( "OLinkedDocumentsAccess::implOpen: invalid open mode!" );
break;
}
aArguments.put( "OpenMode", sOpenMode );
@@ -253,9 +189,8 @@ namespace dbaui
xRet = xComponentLoader->loadComponentFromURL( _rLinkName, ::rtl::OUString(), 0, aArguments.getPropertyValues() );
}
- catch(Exception& e)
+ catch(const Exception&)
{
- (void)e;
throw;
}
@@ -293,7 +228,7 @@ namespace dbaui
xWizard->trigger( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "start" ) ) );
::comphelper::disposeComponent( xWizard );
}
- catch(const Exception& e)
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -351,7 +286,7 @@ namespace dbaui
break;
default:
- OSL_ENSURE( sal_False, "OLinkedDocumentsAccess::newDocument: please use newFormWithPilot!" );
+ OSL_FAIL( "OLinkedDocumentsAccess::newDocument: please use newFormWithPilot!" );
return Reference< XComponent >();
}
@@ -398,7 +333,7 @@ namespace dbaui
xNewDocument.set( xContent->execute( aCommand, xContent->createCommandIdentifier(), NULL ), UNO_QUERY );
}
}
- catch(const Exception& )
+ catch(const Exception&)
{
DBG_UNHANDLED_EXCEPTION();
}
@@ -422,12 +357,11 @@ namespace dbaui
com::sun::star::sdbc::SQLException aSQLException;
aSQLException.Message = sMessage;
- // aSQLException.Context = e.Context;
aInfo = dbtools::SQLExceptionInfo(aSQLException);
}
return xRet;
}
- catch (com::sun::star::io::WrongFormatException e)
+ catch(const com::sun::star::io::WrongFormatException &e)
{
com::sun::star::sdbc::SQLException aSQLException;
aSQLException.Message = e.Message;
@@ -443,7 +377,7 @@ namespace dbaui
sMessage.SearchAndReplaceAscii("$file$",_rLinkName);
aInfo.prepend(sMessage);
}
- catch(Exception& e)
+ catch(const Exception& e)
{
Any aAny = ::cppu::getCaughtException();
com::sun::star::sdbc::SQLException a;
@@ -474,3 +408,4 @@ namespace dbaui
} // namespace dbaui
//......................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/makefile.mk b/dbaccess/source/ui/misc/makefile.mk
deleted file mode 100644
index 534d90e3995c..000000000000
--- a/dbaccess/source/ui/misc/makefile.mk
+++ /dev/null
@@ -1,88 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=../../..
-PRJINC=$(PRJ)/source
-PRJNAME=dbaccess
-TARGET=uimisc
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)/util/makefile.pmk
-
-# --- Files -------------------------------------
-
-# ... resource files ............................
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- dbumiscres.src \
- WizardPages.src
-
-# ... object files ............................
-
-SLOFILES= \
- $(SLO)/asyncmodaldialog.obj \
- $(SLO)/imageprovider.obj \
- $(SLO)/singledoccontroller.obj \
- $(SLO)/dbsubcomponentcontroller.obj \
- $(SLO)/datasourceconnector.obj \
- $(SLO)/linkeddocuments.obj \
- $(SLO)/indexcollection.obj \
- $(SLO)/UITools.obj \
- $(SLO)/WCPage.obj \
- $(SLO)/WCopyTable.obj \
- $(SLO)/WTypeSelect.obj \
- $(SLO)/TokenWriter.obj \
- $(SLO)/HtmlReader.obj \
- $(SLO)/RtfReader.obj \
- $(SLO)/propertysetitem.obj \
- $(SLO)/databaseobjectview.obj \
- $(SLO)/DExport.obj \
- $(SLO)/uiservices.obj \
- $(SLO)/RowSetDrop.obj \
- $(SLO)/TableCopyHelper.obj \
- $(SLO)/moduledbu.obj \
- $(SLO)/WColumnSelect.obj \
- $(SLO)/WExtendPages.obj \
- $(SLO)/WNameMatch.obj \
- $(SLO)/ToolBoxHelper.obj \
- $(SLO)/stringlistitem.obj \
- $(SLO)/charsets.obj \
- $(SLO)/defaultobjectnamecheck.obj \
- $(SLO)/dsmeta.obj \
- $(SLO)/controllerframe.obj \
- $(SLO)/propertystorage.obj \
- $(SLO)/dbaundomanager.obj \
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/source/ui/misc/moduledbu.cxx b/dbaccess/source/ui/misc/moduledbu.cxx
index 2611bac87076..a85c3838a78c 100644
--- a/dbaccess/source/ui/misc/moduledbu.cxx
+++ b/dbaccess/source/ui/misc/moduledbu.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,19 +29,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _TOOLS_RESMGR_HXX
#include <tools/resmgr.hxx>
-#endif
-#ifndef _SOLAR_HRC
#include <svl/solar.hrc>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#define ENTER_MOD_METHOD() \
::osl::MutexGuard aGuard(s_aMutex); \
@@ -144,3 +137,4 @@ void OModule::ensureImpl()
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/propertysetitem.cxx b/dbaccess/source/ui/misc/propertysetitem.cxx
index 99dccb47330d..e39d36f71202 100644
--- a/dbaccess/source/ui/misc/propertysetitem.cxx
+++ b/dbaccess/source/ui/misc/propertysetitem.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_PROPERTYSETITEM_HXX_
#include "propertysetitem.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -84,3 +83,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/propertystorage.cxx b/dbaccess/source/ui/misc/propertystorage.cxx
index cb7def0fedf2..2e9c89680cd5 100644
--- a/dbaccess/source/ui/misc/propertystorage.cxx
+++ b/dbaccess/source/ui/misc/propertystorage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -116,7 +117,7 @@ namespace dbaui
)
return;
- OSL_ENSURE( false, "SetItemPropertyStorage::getPropertyValue: unsupported item type!" );
+ OSL_FAIL( "SetItemPropertyStorage::getPropertyValue: unsupported item type!" );
}
//--------------------------------------------------------------------
@@ -128,9 +129,11 @@ namespace dbaui
)
return;
- OSL_ENSURE( false, "SetItemPropertyStorage::setPropertyValue: unsupported item type!" );
+ OSL_FAIL( "SetItemPropertyStorage::setPropertyValue: unsupported item type!" );
}
//........................................................................
} // namespace dbaui
//........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/singledoccontroller.cxx b/dbaccess/source/ui/misc/singledoccontroller.cxx
index 5a049f65251a..ff6679c55f56 100755..100644
--- a/dbaccess/source/ui/misc/singledoccontroller.cxx
+++ b/dbaccess/source/ui/misc/singledoccontroller.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
@@ -37,6 +38,7 @@
/** === end UNO includes === **/
#include <svl/undo.hxx>
+#include <osl/diagnose.h>
#include <boost/scoped_ptr.hpp>
@@ -198,3 +200,5 @@ namespace dbaui
//......................................................................................................................
} // namespace dbaui
//......................................................................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/stringlistitem.cxx b/dbaccess/source/ui/misc/stringlistitem.cxx
index e1d841d3bb38..20ab3820fc2d 100644
--- a/dbaccess/source/ui/misc/stringlistitem.cxx
+++ b/dbaccess/source/ui/misc/stringlistitem.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_STRINGLISTITEM_HXX_
#include "stringlistitem.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -85,3 +84,4 @@ SfxPoolItem* OStringListItem::Clone(SfxItemPool* /* _pPool */) const
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/misc/uiservices.cxx b/dbaccess/source/ui/misc/uiservices.cxx
index a4aa45443610..dfce75ace0df 100644
--- a/dbaccess/source/ui/misc/uiservices.cxx
+++ b/dbaccess/source/ui/misc/uiservices.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,18 +29,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _CPPUHELPER_FACTORY_HXX_
#include <cppuhelper/factory.hxx>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef INCLUDED_DBACCESSDLLAPI_H
#include "dbaccessdllapi.h"
-#endif
/********************************************************************************************/
@@ -115,7 +108,7 @@ extern "C" void SAL_CALL createRegistryInfo_DBU()
//---------------------------------------------------------------------------------------
-extern "C" DBACCESS_DLLPUBLIC void SAL_CALL component_getImplementationEnvironment(
+extern "C" SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
const sal_Char **ppEnvTypeName,
uno_Environment **
)
@@ -125,7 +118,7 @@ extern "C" DBACCESS_DLLPUBLIC void SAL_CALL component_getImplementationEnvironme
}
//---------------------------------------------------------------------------------------
-extern "C" DBACCESS_DLLPUBLIC void* SAL_CALL component_getFactory(
+extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName,
void* pServiceManager,
void* /*pRegistryKey*/)
@@ -142,3 +135,5 @@ extern "C" DBACCESS_DLLPUBLIC void* SAL_CALL component_getFactory(
xRet->acquire();
return xRet.get();
};
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/ConnectionData.hxx b/dbaccess/source/ui/querydesign/ConnectionData.hxx
deleted file mode 100644
index 97cecf44ff8a..000000000000
--- a/dbaccess/source/ui/querydesign/ConnectionData.hxx
+++ /dev/null
@@ -1,63 +0,0 @@
-/*************************************************************************
- *
- * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
- *
- * Copyright 2000, 2010 Oracle and/or its affiliates.
- *
- * OpenOffice.org - a multi-platform office productivity suite
- *
- * This file is part of OpenOffice.org.
- *
- * OpenOffice.org is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Lesser General Public License version 3
- * only, as published by the Free Software Foundation.
- *
- * OpenOffice.org is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Lesser General Public License version 3 for more details
- * (a copy is included in the LICENSE file that accompanied this code).
- *
- * You should have received a copy of the GNU Lesser General Public License
- * version 3 along with OpenOffice.org. If not, see
- * <http://www.openoffice.org/license.html>
- * for a copy of the LGPLv3 License.
- *
- ************************************************************************/
-#ifndef DBAUI_CONNECTIONDATA_HXX
-#define DBAUI_CONNECTIONDATA_HXX
-
-namespace dbaui
-{
-
- //==================================================================
- // ConnData ---------->* ConnLineData
- // ^1 ^1
- // | |
- // Conn ---------->* ConnLine
- //==================================================================
-
-
-}
-#endif // DBAUI_CONNECTIONDATA_HXX
-
-DECLARE_LIST( OConnectionLineDataList, OConnectionLineData* );
-
-//==================================================================
-class SbaJoinTabConn;
-
-
-
-DECLARE_LIST( OConnectionLineList, OConnectionLine* );
-
-DECLARE_LIST( OTableConnectionDataList, OTableConnectionData* );
-
-//==================================================================
-const sal_uInt16 MAX_CONN_COUNT = 2;
-
-class SbaJoinTabWin;
-class SbaJoinTabWinCont;
-
-
-
-DECLARE_LIST( SbaJoinTabConnList, SbaJoinTabConn* );
diff --git a/dbaccess/source/ui/querydesign/ConnectionLine.cxx b/dbaccess/source/ui/querydesign/ConnectionLine.cxx
index 11c17cca7582..36c7853e9733 100644
--- a/dbaccess/source/ui/querydesign/ConnectionLine.cxx
+++ b/dbaccess/source/ui/querydesign/ConnectionLine.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
#ifndef _INC_MATH
#include <math.h>
#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
+#include <osl/diagnose.h>
#include <vcl/lineinfo.hxx>
@@ -77,7 +64,7 @@ namespace
Rectangle GetTextPos(const OTableWindow* _pWin, const Point& _aConnPos,const Point& _aDescrLinePos)
{
OTableWindowListBox* pListBox = _pWin ? _pWin->GetListBox() : NULL;
- DBG_ASSERT(_pWin && pListBox, "OConnectionLine::GetSourceTextPos : invalid call !");
+ OSL_ENSURE(_pWin && pListBox, "OConnectionLine::GetSourceTextPos : invalid call !");
Rectangle aReturn;
if ( pListBox )
@@ -339,7 +326,7 @@ void OConnectionLine::Draw( OutputDevice* pOutDev )
// -----------------------------------------------------------------------------
sal_Bool OConnectionLine::IsValid() const
{
- return m_pData.isValid();
+ return m_pData.is();
}
//------------------------------------------------------------------------
double dist_Euklid(const Point &p1, const Point& p2,const Point& pM, Point& q)
@@ -395,3 +382,4 @@ Point OConnectionLine::getMidPoint() const
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/ConnectionLineAccess.cxx b/dbaccess/source/ui/querydesign/ConnectionLineAccess.cxx
index 0b6490ad878e..084a8893bd5b 100644
--- a/dbaccess/source/ui/querydesign/ConnectionLineAccess.cxx
+++ b/dbaccess/source/ui/querydesign/ConnectionLineAccess.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,39 +28,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_CONNECTIONLINEACCESS_HXX
#include "ConnectionLineAccess.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLEROLE_HPP_
#include <com/sun/star/accessibility/AccessibleRole.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLERELATIONTYPE_HPP_
#include <com/sun/star/accessibility/AccessibleRelationType.hpp>
-#endif
-#ifndef _TOOLKIT_AWT_VCLXWINDOW_HXX_
#include <toolkit/awt/vclxwindow.hxx>
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
namespace dbaui
{
@@ -67,7 +46,6 @@ namespace dbaui
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::lang;
- // using namespace ::com::sun::star::awt;
using namespace ::com::sun::star;
OConnectionLineAccess::OConnectionLineAccess(OTableConnection* _pLine)
@@ -102,7 +80,7 @@ namespace dbaui
// -----------------------------------------------------------------------------
::rtl::OUString OConnectionLineAccess::getImplementationName_Static(void) throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.ConnectionLineAccessibility");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.ConnectionLineAccessibility"));
}
// -----------------------------------------------------------------------------
// XAccessibleContext
@@ -270,3 +248,4 @@ namespace dbaui
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/ConnectionLineData.cxx b/dbaccess/source/ui/querydesign/ConnectionLineData.cxx
index 9c51a34019b0..adbdf5edab3a 100644
--- a/dbaccess/source/ui/querydesign/ConnectionLineData.cxx
+++ b/dbaccess/source/ui/querydesign/ConnectionLineData.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace dbaui;
@@ -56,7 +53,7 @@ OConnectionLineData::OConnectionLineData( const ::rtl::OUString& rSourceFieldNam
//------------------------------------------------------------------------
OConnectionLineData::OConnectionLineData( const OConnectionLineData& rConnLineData )
- : ::vos::OReference()
+ : ::salhelper::SimpleReferenceObject()
{
DBG_CTOR(OConnectionLineData,NULL);
*this = rConnLineData;
@@ -104,3 +101,4 @@ bool operator==(const OConnectionLineData& lhs, const OConnectionLineData& rhs)
}
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/JAccess.cxx b/dbaccess/source/ui/querydesign/JAccess.cxx
index 70a52e1b0404..4a0e3888a1ea 100644
--- a/dbaccess/source/ui/querydesign/JAccess.cxx
+++ b/dbaccess/source/ui/querydesign/JAccess.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_JACCESS_HXX
#include "JAccess.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLEROLE_HPP_
#include <com/sun/star/accessibility/AccessibleRole.hpp>
-#endif
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
namespace dbaui
{
@@ -72,7 +57,7 @@ namespace dbaui
// -----------------------------------------------------------------------------
::rtl::OUString OJoinDesignViewAccess::getImplementationName_Static(void) throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.JoinViewAccessibility");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.JoinViewAccessibility"));
}
// -----------------------------------------------------------------------------
void OJoinDesignViewAccess::clearTableView()
@@ -143,3 +128,4 @@ namespace dbaui
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/JoinController.cxx b/dbaccess/source/ui/querydesign/JoinController.cxx
index fe6d65fd0040..7ccf4db07cf9 100644
--- a/dbaccess/source/ui/querydesign/JoinController.cxx
+++ b/dbaccess/source/ui/querydesign/JoinController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,120 +28,45 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _SFXSIDS_HRC
#include <sfx2/sfxsids.hrc>
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COM_SUN_STAR_FRAME_FRAMESEARCHFLAG_HPP_
#include <com/sun/star/frame/FrameSearchFlag.hpp>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XCHILD_HPP_
#include <com/sun/star/container/XChild.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMECONTAINER_HPP_
#include <com/sun/star/container/XNameContainer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDATADESCRIPTORFACTORY_HPP_
#include <com/sun/star/sdbcx/XDataDescriptorFactory.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_KEYTYPE_HPP_
#include <com/sun/star/sdbcx/KeyType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDROP_HPP_
#include <com/sun/star/sdbcx/XDrop.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XALTERTABLE_HPP_
#include <com/sun/star/sdbcx/XAlterTable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_SQLCONTEXT_HPP_
#include <com/sun/star/sdb/SQLContext.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_SQLWARNING_HPP_
#include <com/sun/star/sdbc/SQLWarning.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNVALUE_HPP_
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROW_HPP_
#include <com/sun/star/sdbc/XRow.hpp>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _COM_SUN_STAR_UI_DIALOGS_XEXECUTABLEDIALOG_HPP_
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
-#endif
-#ifndef _COMPHELPER_STREAMSECTION_HXX_
#include <comphelper/streamsection.hxx>
-#endif
-#ifndef _COMPHELPER_BASIC_IO_HXX_
#include <comphelper/basicio.hxx>
-#endif
-#ifndef _COMPHELPER_SEQSTREAM_HXX
#include <comphelper/seqstream.hxx>
-#endif
-#ifndef _COM_SUN_STAR_IO_XACTIVEDATASOURCE_HPP_
#include <com/sun/star/io/XActiveDataSource.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XACTIVEDATASINK_HPP_
#include <com/sun/star/io/XActiveDataSink.hpp>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBAUI_TABLEWINDOWDATA_HXX
#include "TableWindowData.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef DBAUI_QYDLGTAB_HXX
#include "adtabdlg.hxx"
-#endif
-#ifndef _SV_WAITOBJ_HXX
#include <vcl/waitobj.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
+#include <osl/mutex.hxx>
#include "UITools.hxx"
-#endif
+#include <osl/diagnose.h>
#include <boost/optional.hpp>
@@ -409,7 +335,7 @@ void OJoinController::SaveTabWinsPosSize( OJoinTableView::OTableWindowMap* pTabW
// Wenn die TabWins ein SetData haetten, koennte ich mir das sparen ... haben sie aber nicht, ausserdem muesste ich dann immer
// noch Informationen, die sich eigentlich nicht geaendert haben, auch neu setzen.
// Also loesche ich die TabWinDatas nicht, sondern aktualisiere sie nur.
- DBG_ASSERT(m_vTableData.size() == pTabWinList->size(),
+ OSL_ENSURE(m_vTableData.size() == pTabWinList->size(),
"OJoinController::SaveTabWinsPosSize : inkonsistenter Zustand : sollte genausviel TabWinDatas haben wie TabWins !");
OJoinTableView::OTableWindowMap::iterator aIter = pTabWinList->begin();
@@ -438,7 +364,7 @@ sal_Bool SAL_CALL OJoinController::suspend(sal_Bool _bSuspend) throw( RuntimeExc
if ( getBroadcastHelper().bInDispose || getBroadcastHelper().bDisposed )
return sal_True;
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( getView() && getView()->IsInModalMode() )
return sal_False;
@@ -538,10 +464,12 @@ TTableWindowData::value_type OJoinController::createTableWindowData(const ::rtl:
OJoinDesignView* pView = getJoinView();
if( pView )
return pView->getTableView()->createTableWindowData(_sComposedName,_sTableName,_sWindowName);
- OSL_ENSURE(0,"We should never ever reach this point!");
+ OSL_FAIL("We should never ever reach this point!");
return TTableWindowData::value_type();
}
// .............................................................................
} // namespace dbaui
// .............................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/JoinDesignView.cxx b/dbaccess/source/ui/querydesign/JoinDesignView.cxx
index f0b4e27a9276..ba1ddc2b5c59 100644
--- a/dbaccess/source/ui/querydesign/JoinDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/JoinDesignView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,70 +28,27 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef _UNDO_HXX
#include <svl/undo.hxx>
-#endif
-#ifndef DBAUI_QYDLGTAB_HXX
#include "adtabdlg.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-// #include <com/sun/star/util/URL.hdl>
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::lang;
@@ -136,7 +94,6 @@ void OJoinDesignView::Construct()
// -----------------------------------------------------------------------------
void OJoinDesignView::initialize()
{
- // getAddTableDialog()->Update();
}
// -------------------------------------------------------------------------
void OJoinDesignView::resizeDocumentView(Rectangle& _rPlayground)
@@ -168,3 +125,4 @@ void OJoinDesignView::KeyInput( const KeyEvent& rEvt )
} // namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/JoinExchange.cxx b/dbaccess/source/ui/querydesign/JoinExchange.cxx
index b78d62cc4660..2ec6ccea0257 100644
--- a/dbaccess/source/ui/querydesign/JoinExchange.cxx
+++ b/dbaccess/source/ui/querydesign/JoinExchange.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_JOINEXCHANGE_HXX
#include "JoinExchange.hxx"
-#endif
-#ifndef _SOT_FORMATS_HXX
#include <sot/formats.hxx>
-#endif
-#ifndef _SVX_DBEXCH_HRC
#include <svx/dbexch.hrc>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _SOT_FORMATS_HXX
#include <sot/formats.hxx>
-#endif
namespace dbaui
{
@@ -184,3 +175,5 @@ namespace dbaui
} // namespace dbaui
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/JoinTableView.cxx b/dbaccess/source/ui/querydesign/JoinTableView.cxx
index 8223baa173f2..112411be0a2f 100644
--- a/dbaccess/source/ui/querydesign/JoinTableView.cxx
+++ b/dbaccess/source/ui/querydesign/JoinTableView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,76 +28,29 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
+#include <osl/diagnose.h>
#include "querycontroller.hxx"
-#endif
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-//#ifndef DBAUI_QUERY_TABLEWINDOWDATA_HXX
-//#include "QTableWindowData.hxx"
-//#endif
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _URLBMK_HXX
#include <svl/urlbmk.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef DBAUI_OQUERYMOVETABWINUNDOACT_HXX
#include "QueryMoveTabWinUndoAct.hxx"
-#endif
-#ifndef DBAUI_QUERYSIZETABWINUNDOACT_HXX
#include "QuerySizeTabWinUndoAct.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef DBAUI_TABLEWINDOWDATA_HXX
#include "TableWindowData.hxx"
-#endif
-#ifndef DBACCESS_JACCESS_HXX
#include "JAccess.hxx"
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_XACCESSIBLE_HPP_
#include <com/sun/star/accessibility/XAccessible.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLEROLE_HPP_
#include <com/sun/star/accessibility/AccessibleRole.hpp>
-#endif
#include <com/sun/star/accessibility/AccessibleEventId.hpp>
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
#include <cppuhelper/exc_hlp.hxx>
#include <tools/diagnose_ex.h>
#include <boost/bind.hpp>
@@ -217,8 +171,6 @@ void OScrollWindowHelper::Resize()
// class OJoinTableView
//==================================================================
-//const long WINDOW_WIDTH = 1000;
-//const long WINDOW_HEIGHT = 1000;
DBG_NAME(OJoinTableView);
//------------------------------------------------------------------------------
OJoinTableView::OJoinTableView( Window* pParent, OJoinDesignView* pView )
@@ -480,7 +432,6 @@ namespace
// -----------------------------------------------------------------------------
sal_Bool isScrollAllowed( OJoinTableView* _pView,long nDelta, sal_Bool bHoriz)
{
- sal_Bool bRet = sal_True;
//////////////////////////////////////////////////////////////////////
// adjust ScrollBar-Positions
ScrollBar* pBar = _pView->GetVScrollBar();
@@ -490,9 +441,9 @@ namespace
long nOldThumbPos = pBar->GetThumbPos();
long nNewThumbPos = nOldThumbPos + nDelta;
if( nNewThumbPos < 0 )
- nNewThumbPos = 0;// bRet = sal_False;
+ nNewThumbPos = 0;
else if( nNewThumbPos > pBar->GetRangeMax() )
- nNewThumbPos = pBar->GetRangeMax();// bRet = sal_False;
+ nNewThumbPos = pBar->GetRangeMax();
if ( bHoriz )
{
@@ -502,7 +453,7 @@ namespace
else if ( nNewThumbPos == _pView->GetScrollOffset().Y() )
return sal_False;
- return bRet;
+ return sal_True;
}
// -----------------------------------------------------------------------------
sal_Bool getMovementImpl(OJoinTableView* _pView,const Point& _rPoint,const Size& _rSize,long& _nScrollX,long& _nScrollY)
@@ -512,7 +463,6 @@ namespace
Point aUpperLeft = _rPoint;
// normalize with respect to visibility
aUpperLeft -= _pView->GetScrollOffset();
- // aUpperLeft.Y() -= _pView->GetScrollOffset().Y();
Point aLowerRight(aUpperLeft.X() + _rSize.Width(), aUpperLeft.Y() + _rSize.Height());
// data about ourself
@@ -523,7 +473,6 @@ namespace
sal_Bool bFitsVert= (aUpperLeft.Y() >= 0) && (aLowerRight.Y() <= aSize.Height());
if (!bFitsHor || !bFitsVert)
{
- // #100386# OJ
if (!bFitsHor)
{
// ensure the visibility of the right border
@@ -531,7 +480,6 @@ namespace
_nScrollX = aLowerRight.X() - aSize.Width() + TABWIN_SPACING_X;
// ensure the visibility of the left border (higher priority)
- // if ( (aUpperLeft.X() - _nScrollX) < 0 )
if ( aUpperLeft.X() < 0 )
_nScrollX = aUpperLeft.X() - TABWIN_SPACING_X;
}
@@ -542,7 +490,6 @@ namespace
if ( aLowerRight.Y() > aSize.Height() )
_nScrollY = aLowerRight.Y() - aSize.Height() + TABWIN_SPACING_Y;
// upper border
- // if ( (aUpperLeft.Y() - _nScrollY) < 0 )
if ( aUpperLeft.Y() < 0 )
_nScrollY = aUpperLeft.Y() - TABWIN_SPACING_Y;
}
@@ -580,7 +527,6 @@ void OJoinTableView::EnsureVisible(const OTableWindow* _pWin)
{
// data about the tab win
TTableWindowData::value_type pData = _pWin->GetData();
- // Point aUpperLeft = pData->GetPosition();
EnsureVisible( pData->GetPosition() , pData->GetSize());
Invalidate(INVALIDATE_NOCHILDREN);
}
@@ -628,7 +574,7 @@ void OJoinTableView::SetDefaultTabWinPosSize( OTableWindow* pTabWin )
//////////////////////////////////////////////////////////////////
// Belegte Bereiche dieser Zeile pruefen
- OTableWindow* pOtherTabWin;// = GetTabWinMap()->First();
+ OTableWindow* pOtherTabWin;
OTableWindowMapIterator aIter = m_aTableMap.begin();
OTableWindowMapIterator aEnd = m_aTableMap.end();
for(;aIter != aEnd;++aIter)
@@ -1142,7 +1088,7 @@ void OJoinTableView::ClearAll()
sal_Bool OJoinTableView::ScrollWhileDragging()
{
DBG_CHKTHIS(OJoinTableView,NULL);
- DBG_ASSERT(m_pDragWin != NULL, "OJoinTableView::ScrollWhileDragging darf nur waehrend Dragging eines Fensters aufgerufen werden !");
+ OSL_ENSURE(m_pDragWin != NULL, "OJoinTableView::ScrollWhileDragging darf nur waehrend Dragging eines Fensters aufgerufen werden !");
// den Timer schon mal killen
if (m_aDragScrollTimer.IsActive())
@@ -1274,10 +1220,6 @@ sal_Bool OJoinTableView::IsAddAllowed()
return sal_False;
}
- // nicht wenn keine Joins moeglich
-// if (!GetDatabase()->IsCapable(SDB_CAP_JOIN) && nMax <= GetTabWinCount())
-// return sal_False;
-
return sal_True;
}
// -----------------------------------------------------------------------------
@@ -1349,7 +1291,7 @@ void OJoinTableView::Command(const CommandEvent& rEvt)
OTableConnection* OJoinTableView::GetTabConn(const OTableWindow* pLhs,const OTableWindow* pRhs,bool _bSupressCrossOrNaturalJoin,const OTableConnection* _rpFirstAfter) const
{
OTableConnection* pConn = NULL;
- DBG_ASSERT(pRhs || pLhs, "OJoinTableView::GetTabConn : invalid args !");
+ OSL_ENSURE(pRhs || pLhs, "OJoinTableView::GetTabConn : invalid args !");
// only one NULL-arg allowed
if ((!pLhs || pLhs->ExistsAConn()) && (!pRhs || pRhs->ExistsAConn()))
@@ -1763,7 +1705,7 @@ bool OJoinTableView::allowQueries() const
// -----------------------------------------------------------------------------
void OJoinTableView::onNoColumns_throw()
{
- OSL_ENSURE( false, "OTableWindow::onNoColumns_throw: cannot really handle this!" );
+ OSL_FAIL( "OTableWindow::onNoColumns_throw: cannot really handle this!" );
throw SQLException();
}
//------------------------------------------------------------------------------
@@ -1771,3 +1713,5 @@ bool OJoinTableView::supressCrossNaturalJoin(const TTableConnectionData::value_t
{
return false;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableConnection.cxx b/dbaccess/source/ui/querydesign/QTableConnection.cxx
index 6244ec1a77d4..d8d98679d18b 100644
--- a/dbaccess/source/ui/querydesign/QTableConnection.cxx
+++ b/dbaccess/source/ui/querydesign/QTableConnection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYTABLECONNECTION_HXX
#include "QTableConnection.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
+#include <osl/diagnose.h>
#include "QueryTableView.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
using namespace dbaui;
//========================================================================
// class OQueryTableConnection
@@ -53,7 +46,6 @@ OQueryTableConnection::OQueryTableConnection(OQueryTableView* pContainer, const
DBG_CTOR(OQueryTableConnection,NULL);
}
-
//------------------------------------------------------------------------
OQueryTableConnection::OQueryTableConnection(const OQueryTableConnection& rConn)
:OTableConnection( rConn )
@@ -81,7 +73,7 @@ OQueryTableConnection& OQueryTableConnection::operator=(const OQueryTableConnect
//------------------------------------------------------------------------
sal_Bool OQueryTableConnection::operator==(const OQueryTableConnection& rCompare)
{
- DBG_ASSERT(GetData() && rCompare.GetData(), "OQueryTableConnection::operator== : einer der beiden Teilnehmer hat keine Daten !");
+ OSL_ENSURE(GetData() && rCompare.GetData(), "OQueryTableConnection::operator== : einer der beiden Teilnehmer hat keine Daten !");
// allzuviel brauche ich nicht vergleichen (schon gar nicht alle Member) : lediglich die Fenster, an denen wir haengen, und
// die Indizies in der entsprechenden Tabelle muessen uebereinstimmen
@@ -104,8 +96,4 @@ sal_Bool OQueryTableConnection::operator==(const OQueryTableConnection& rCompare
}
// -----------------------------------------------------------------------------
-
-
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableConnection.hxx b/dbaccess/source/ui/querydesign/QTableConnection.hxx
index bfab4fe88c10..a2402acab43b 100644
--- a/dbaccess/source/ui/querydesign/QTableConnection.hxx
+++ b/dbaccess/source/ui/querydesign/QTableConnection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_QUERYTABLECONNECTION_HXX
#define DBAUI_QUERYTABLECONNECTION_HXX
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_QTABLECONNECTIONDATA_HXX
#include "QTableConnectionData.hxx"
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
namespace dbaui
{
@@ -60,3 +55,5 @@ namespace dbaui
};
}
#endif // DBAUI_QUERYTABLECONNECTION_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableConnectionData.cxx b/dbaccess/source/ui/querydesign/QTableConnectionData.cxx
index 8f02ceac42a6..5a10614f89e7 100644
--- a/dbaccess/source/ui/querydesign/QTableConnectionData.cxx
+++ b/dbaccess/source/ui/querydesign/QTableConnectionData.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QTABLECONNECTIONDATA_HXX
#include "QTableConnectionData.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_QTABLECONNECTIONDATA_HXX
#include "QTableConnectionData.hxx"
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOWDATA_HXX
#include "QTableWindow.hxx"
-#endif
using namespace dbaui;
@@ -173,6 +166,4 @@ sal_Bool OQueryTableConnectionData::Update()
}
// -----------------------------------------------------------------------------
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableConnectionData.hxx b/dbaccess/source/ui/querydesign/QTableConnectionData.hxx
index 2767b97b50ef..0b4c78d394a5 100644
--- a/dbaccess/source/ui/querydesign/QTableConnectionData.hxx
+++ b/dbaccess/source/ui/querydesign/QTableConnectionData.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,10 @@
#ifndef DBAUI_QTABLECONNECTIONDATA_HXX
#define DBAUI_QTABLECONNECTIONDATA_HXX
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDDESC_HXX
#include "TableFieldDescription.hxx"
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _RTTI_HXX
#include <tools/rtti.hxx>
-#endif
-//#ifndef DBAUI_QUERYCONTROLLER_HXX
-//#include "querycontroller.hxx"
-//#endif
namespace dbaui
{
@@ -97,3 +87,5 @@ namespace dbaui
}
#endif // DBAUI_QTABLECONNECTIONDATA_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableWindow.cxx b/dbaccess/source/ui/querydesign/QTableWindow.cxx
index 88514b57ac8f..48f9237bda97 100644
--- a/dbaccess/source/ui/querydesign/QTableWindow.cxx
+++ b/dbaccess/source/ui/querydesign/QTableWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,70 +28,28 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERY_TABLEWINDOWDATA_HXX
#include "QTableWindow.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
+#include <osl/diagnose.h>
#include "dbaccess_helpid.hrc"
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef _SV_IMAGE_HXX
#include <vcl/image.hxx>
-#endif
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBAUI_QUERY_HRC
#include "Query.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XKEYSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_KEYTYPE_HPP_
#include <com/sun/star/sdbcx/KeyType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef DBAUI_TABLEFIELDINFO_HXX
#include "TableFieldInfo.hxx"
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
using namespace ::com::sun::star::sdbc;
@@ -161,14 +120,13 @@ sal_Bool OQueryTableWindow::Init()
sAliasName = String(sAliasName).EraseAllChars('"');
SetAliasName(sAliasName);
// SetAliasName reicht das als WinName weiter, dadurch benutzt es die Basisklasse
- // reset the titel
+ // reset the title
m_aTitle.SetText( pWinData->GetWinName() );
m_aTitle.Show();
- // sal_Bool bSuccess(sal_True);
if (!bSuccess)
{ // es soll nur ein Dummy-Window aufgemacht werden ...
- DBG_ASSERT(GetAliasName().getLength(), "OQueryTableWindow::Init : kein Alias- UND kein Tabellenname geht nicht !");
+ OSL_ENSURE(GetAliasName().getLength(), "OQueryTableWindow::Init : kein Alias- UND kein Tabellenname geht nicht !");
// .. aber das braucht wenigstens einen Alias
// ::com::sun::star::form::ListBox anlegen
@@ -205,14 +163,14 @@ void OQueryTableWindow::deleteUserData(void*& _pUserData)
//------------------------------------------------------------------------------
void OQueryTableWindow::OnEntryDoubleClicked(SvLBoxEntry* pEntry)
{
- DBG_ASSERT(pEntry != NULL, "OQueryTableWindow::OnEntryDoubleClicked : pEntry darf nicht NULL sein !");
+ 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
if (getTableView()->getDesignView()->getController().isReadOnly())
return;
OTableFieldInfo* pInf = static_cast<OTableFieldInfo*>(pEntry->GetUserData());
- DBG_ASSERT(pInf != NULL, "OQueryTableWindow::OnEntryDoubleClicked : Feld hat keine FieldInfo !");
+ OSL_ENSURE(pInf != NULL, "OQueryTableWindow::OnEntryDoubleClicked : Feld hat keine FieldInfo !");
// eine DragInfo aufbauen
OTableFieldDescRef aInfo = new OTableFieldDesc(GetTableName(),m_pListBox->GetEntryText(pEntry));
@@ -228,8 +186,8 @@ void OQueryTableWindow::OnEntryDoubleClicked(SvLBoxEntry* pEntry)
//------------------------------------------------------------------------------
sal_Bool OQueryTableWindow::ExistsField(const ::rtl::OUString& strFieldName, OTableFieldDescRef& rInfo)
{
- DBG_ASSERT(m_pListBox != NULL, "OQueryTableWindow::ExistsField : habe keine ::com::sun::star::form::ListBox !");
- OSL_ENSURE(rInfo.isValid(),"OQueryTableWindow::ExistsField: invlid argument for OTableFieldDescRef!");
+ OSL_ENSURE(m_pListBox != NULL, "OQueryTableWindow::ExistsField : habe keine ::com::sun::star::form::ListBox !");
+ OSL_ENSURE(rInfo.is(),"OQueryTableWindow::ExistsField: invlid argument for OTableFieldDescRef!");
Reference< XConnection> xConnection = getTableView()->getDesignView()->getController().getConnection();
sal_Bool bExists = sal_False;
if(xConnection.is())
@@ -245,7 +203,7 @@ sal_Bool OQueryTableWindow::ExistsField(const ::rtl::OUString& strFieldName, OTa
if (bCase(strFieldName,::rtl::OUString(m_pListBox->GetEntryText(pEntry))))
{
OTableFieldInfo* pInf = static_cast<OTableFieldInfo*>(pEntry->GetUserData());
- DBG_ASSERT(pInf != NULL, "OQueryTableWindow::ExistsField : Feld hat keine FieldInfo !");
+ OSL_ENSURE(pInf != NULL, "OQueryTableWindow::ExistsField : Feld hat keine FieldInfo !");
rInfo->SetTabWindow(this);
rInfo->SetField(strFieldName);
@@ -280,5 +238,4 @@ void OQueryTableWindow::KeyInput( const KeyEvent& rEvt )
}
// -----------------------------------------------------------------------------
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableWindow.hxx b/dbaccess/source/ui/querydesign/QTableWindow.hxx
index 9eba590a89f6..16b5097ca6d0 100644
--- a/dbaccess/source/ui/querydesign/QTableWindow.hxx
+++ b/dbaccess/source/ui/querydesign/QTableWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
#ifndef DBAUI_QUERY_TABLEWINDOW_HXX
#define DBAUI_QUERY_TABLEWINDOW_HXX
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOWDATA_HXX
#include "QTableWindowData.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDDESC_HXX
#include "TableFieldDescription.hxx"
-#endif
-#ifndef _RTTI_HXX
#include <tools/rtti.hxx>
-#endif
namespace dbaui
{
@@ -98,3 +91,4 @@ namespace dbaui
#endif // DBAUI_QUERY_TABLEWINDOW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableWindowData.cxx b/dbaccess/source/ui/querydesign/QTableWindowData.cxx
index 8a1a87704d53..1da1c2f30d63 100644
--- a/dbaccess/source/ui/querydesign/QTableWindowData.cxx
+++ b/dbaccess/source/ui/querydesign/QTableWindowData.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERY_TABLEWINDOWDATA_HXX
#include "QTableWindowData.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace dbaui;
@@ -60,3 +57,4 @@ OQueryTableWindowData::~OQueryTableWindowData()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QTableWindowData.hxx b/dbaccess/source/ui/querydesign/QTableWindowData.hxx
index 21f69b37fd9c..9a54e738a764 100644
--- a/dbaccess/source/ui/querydesign/QTableWindowData.hxx
+++ b/dbaccess/source/ui/querydesign/QTableWindowData.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,19 +28,13 @@
#ifndef DBAUI_QUERY_TABLEWINDOWDATA_HXX
#define DBAUI_QUERY_TABLEWINDOWDATA_HXX
-#ifndef DBAUI_TABLEWINDOWDATA_HXX
#include "TableWindowData.hxx"
-#endif
#ifndef INCLUDED_VECTOR
#define INCLUDED_VECTOR
#include <vector>
#endif
-#ifndef _COM_SUN_STAR_IO_XOBJECTOUTPUTSTREAM_HPP_
#include <com/sun/star/io/XObjectOutputStream.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XOBJECTINPUTSTREAM_HPP_
#include <com/sun/star/io/XObjectInputStream.hpp>
-#endif
namespace dbaui
@@ -57,3 +52,4 @@ namespace dbaui
#endif // DBAUI_QUERY_TABLEWINDOWDATA_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryAddTabConnUndoAction.hxx b/dbaccess/source/ui/querydesign/QueryAddTabConnUndoAction.hxx
index 17f02964be73..c0ef7d5ef1ef 100644
--- a/dbaccess/source/ui/querydesign/QueryAddTabConnUndoAction.hxx
+++ b/dbaccess/source/ui/querydesign/QueryAddTabConnUndoAction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_QUERYADDTABCONNUNDOACTION_HXX
#define DBAUI_QUERYADDTABCONNUNDOACTION_HXX
-#ifndef DBAUI_QUERYTABCONNUNDOACTION_HXX
#include "QueryTabConnUndoAction.hxx"
-#endif
namespace dbaui
{
@@ -61,3 +60,4 @@ namespace dbaui
#endif // DBAUI_QUERYADDTABCONNUNDOACTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryDesignFieldUndoAct.hxx b/dbaccess/source/ui/querydesign/QueryDesignFieldUndoAct.hxx
index 51491c29f98a..92a79f257efd 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignFieldUndoAct.hxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignFieldUndoAct.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_QUERYDESIGNFIELDUNDOACT_HXX
#define DBAUI_QUERYDESIGNFIELDUNDOACT_HXX
-#ifndef DBAUI_GENERALUNDO_HXX
#include "GeneralUndo.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBAUI_QUERYDESIGN_OSELECTIONBROWSEBOX_HXX
#include "SelectionBrowseBox.hxx"
-#endif
namespace dbaui
@@ -163,3 +158,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryDesignUndoAction.hxx b/dbaccess/source/ui/querydesign/QueryDesignUndoAction.hxx
index 1aa1ef821181..f0f862cf3611 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignUndoAction.hxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignUndoAction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_QUERYDESIGNUNDOACTION_HXX
#define DBAUI_QUERYDESIGNUNDOACTION_HXX
-#ifndef DBAUI_GENERALUNDO_HXX
#include "GeneralUndo.hxx"
-#endif
namespace dbaui
{
@@ -48,3 +47,4 @@ namespace dbaui
}
#endif // DBAUI_QUERYDESIGNUNDOACTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index 7d88bc7c8840..a05bf39d5432 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,111 +28,42 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOW_HXX
#include "QTableWindow.hxx"
-#endif
-#ifndef _SV_TOOLBOX_HXX
#include <vcl/toolbox.hxx>
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
-#ifndef _UNDO_HXX
#include <svl/undo.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBAUI_QYDLGTAB_HXX
+#include <osl/diagnose.h>
#include "adtabdlg.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_COMBOBOX_HXX
#include <vcl/combobox.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGN_OSELECTIONBROWSEBOX_HXX
#include "SelectionBrowseBox.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef _UTL_CONFIGMGR_HXX_
#include <unotools/configmgr.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _COM_SUN_STAR_I18N_XLOCALEDATA_HPP_
#include <com/sun/star/i18n/XLocaleData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNVALUE_HPP_
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#endif
-#ifndef _CONNECTIVITY_PCOLUMN_HXX_
#include <connectivity/PColumn.hxx>
-#endif
-#ifndef DBAUI_QUERYTABLECONNECTION_HXX
#include "QTableConnection.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
-#ifndef DBAUI_QTABLECONNECTIONDATA_HXX
#include "QTableConnectionData.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTAINERWINDOW_HXX
#include "querycontainerwindow.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef INCLUDED_SVTOOLS_SYSLOCALE_HXX
#include <unotools/syslocale.hxx>
-#endif
using namespace ::dbaui;
using namespace ::utl;
@@ -152,8 +84,8 @@ using namespace ::com::sun::star::container;
// please look at the book LargeScale C++ to know why
namespace
{
- static const ::rtl::OUString C_AND = ::rtl::OUString::createFromAscii(" AND ");
- static const ::rtl::OUString C_OR = ::rtl::OUString::createFromAscii(" OR ");
+ static const ::rtl::OUString C_AND(RTL_CONSTASCII_USTRINGPARAM(" AND "));
+ static const ::rtl::OUString C_OR(RTL_CONSTASCII_USTRINGPARAM(" OR "));
// forward declarations
sal_Bool InsertJoin( const OQueryDesignView* _pView,
@@ -316,7 +248,7 @@ namespace
bError = sal_True;
}
}
- // check if error occured
+ // check if error occurred
if ( bError )
eErrorCode = eIllegalJoin;
@@ -401,7 +333,7 @@ namespace
}
catch(SQLException&)
{
- OSL_ASSERT(!"Failure while building Join criteria!");
+ OSL_FAIL("Failure while building Join criteria!");
}
}
@@ -444,7 +376,6 @@ namespace
{
::rtl::OUString aDBName(pEntryTab->GetComposedName());
- // Reference< XConnection> xConnection = static_cast<OQueryController&>(_pView->getController()).getConnection();
if( _xConnection.is() )
{
try
@@ -458,9 +389,9 @@ namespace
::rtl::OUString aQuote = xMetaData->getIdentifierQuoteString();
if ( _bForce || isAppendTableAliasEnabled( _xConnection ) || pEntryTab->GetAliasName() != aDBName )
{
- aTableListStr += ::rtl::OUString::createFromAscii(" ");
+ aTableListStr += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" "));
if ( generateAsBeforeTableAlias( _xConnection ) )
- aTableListStr += ::rtl::OUString::createFromAscii("AS ");
+ aTableListStr += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("AS "));
aTableListStr += ::dbtools::quoteName( aQuote, pEntryTab->GetAliasName() );
}
aDBName = aTableListStr;
@@ -550,8 +481,6 @@ namespace
if ( pEntryConnData->GetJoinType() == INNER_JOIN && !pEntryConnData->isNatural() )
return;
- // Reference< XConnection> xConnection = static_cast<OQueryController&>(_pView->getController()).getConnection();
-
if(!aJoin.getLength())
{
OQueryTableWindow* pEntryTabFrom = static_cast<OQueryTableWindow*>(pEntryConn->GetSourceWin());
@@ -621,7 +550,7 @@ namespace
else if (SQL_ISRULEOR2(pNode,search_condition,boolean_term) && // AND/OR-Verknuepfung:
pNode->count() == 3)
{
- // nur AND Verknüpfung zulassen
+ // nur AND Verkn�pfung zulassen
if (!SQL_ISTOKEN(pNode->getChild(1),AND))
eErrorCode = eIllegalJoinCondition;
else if ( eOk == (eErrorCode = InsertJoinConnection(_pView,pNode->getChild(0), _eJoinType,pLeftTable,pRightTable)) )
@@ -630,7 +559,7 @@ namespace
else if (SQL_ISRULE(pNode,comparison_predicate))
{
// only the comparison of columns is allowed
- DBG_ASSERT(pNode->count() == 3,"OQueryDesignView::InsertJoinConnection: Fehler im Parse Tree");
+ OSL_ENSURE(pNode->count() == 3,"OQueryDesignView::InsertJoinConnection: Fehler im Parse Tree");
if (!(SQL_ISRULE(pNode->getChild(0),column_ref) &&
SQL_ISRULE(pNode->getChild(2),column_ref) &&
pNode->getChild(1)->getNodeType() == SQL_NODE_EQUAL))
@@ -649,7 +578,6 @@ namespace
if ( pLeftTable )
{
OQueryTableWindow* pLeftWindow = static_cast<OQueryTableView*>(_pView->getTableView())->FindTable( getTableRange(_pView,pLeftTable->getByRule(OSQLParseNode::table_ref) ));
- // OQueryTableWindow* pRightWindow = static_cast<OQueryTableView*>(_pView->getTableView())->FindTable( getTableRange(_pView,pRightTable->getByRule(OSQLParseNode::table_ref) ));
if ( pLeftWindow == aDragLeft->GetTabWindow() )
insertConnection(_pView,_eJoinType,aDragLeft,aDragRight);
else
@@ -750,7 +678,7 @@ namespace
if ( pEntryField->isAggreateFunction() )
{
- DBG_ASSERT(pEntryField->GetFunction().getLength(),"Functionname darf hier nicht leer sein! ;-(");
+ OSL_ENSURE(pEntryField->GetFunction().getLength(),"Functionname darf hier nicht leer sein! ;-(");
::rtl::OUStringBuffer aTmpStr2( pEntryField->GetFunction());
aTmpStr2.appendAscii("(");
aTmpStr2.append(aTmpStr.makeStringAndClear());
@@ -775,7 +703,7 @@ namespace
}
catch(SQLException&)
{
- OSL_ASSERT(!"Failure while building select list!");
+ OSL_FAIL("Failure while building select list!");
}
return aFieldListStr.makeStringAndClear();
}
@@ -913,7 +841,7 @@ namespace
}
}
}
- // nur einmal für jedes Feld
+ // nur einmal f�r jedes Feld
else if ( !i && pEntryField->isCondition() )
{
if (!aWhereStr.getLength()) // noch keine Kriterien
@@ -950,7 +878,7 @@ namespace
}
catch(SQLException&)
{
- OSL_ASSERT(!"Failure while building where clause!");
+ OSL_FAIL("Failure while building where clause!");
}
return sal_True;
}
@@ -1003,7 +931,7 @@ namespace
}
else if ( pEntryField->isNumericOrAggreateFunction() )
{
- DBG_ASSERT(pEntryField->GetFunction().getLength(),"Functionname darf hier nicht leer sein! ;-(");
+ OSL_ENSURE(pEntryField->GetFunction().getLength(),"Functionname darf hier nicht leer sein! ;-(");
aWorkStr += pEntryField->GetFunction();
aWorkStr += ::rtl::OUString('(');
aWorkStr += quoteTableAlias(bMulti,pEntryField->GetAlias(),aQuote);
@@ -1044,14 +972,14 @@ namespace
eErrorCode = eStatementTooLong;
else
{
- _rsRet = ::rtl::OUString::createFromAscii(" ORDER BY ");
+ _rsRet = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" ORDER BY "));
_rsRet += aWorkStr;
}
}
}
catch(SQLException&)
{
- OSL_ASSERT(!"Failure while building group by!");
+ OSL_FAIL("Failure while building group by!");
}
return eErrorCode;
@@ -1241,7 +1169,7 @@ namespace
OTableFieldDescRef pEntryField = *aIter;
if ( pEntryField->IsGroupBy() )
{
- DBG_ASSERT(pEntryField->GetField().getLength(),"Kein FieldName vorhanden!;-(");
+ OSL_ENSURE(pEntryField->GetField().getLength(),"Kein FieldName vorhanden!;-(");
::rtl::OUString sGroupByPart = quoteTableAlias(bMulti,pEntryField->GetAlias(),aQuote);
// only quote the field name when it isn't calculated
@@ -1279,14 +1207,14 @@ namespace
if ( aGroupByStr.getLength() )
{
aGroupByStr = aGroupByStr.replaceAt(aGroupByStr.getLength()-1,1, ::rtl::OUString(' ') );
- ::rtl::OUString aGroupByStr2 = ::rtl::OUString::createFromAscii(" GROUP BY ");
+ ::rtl::OUString aGroupByStr2(RTL_CONSTASCII_USTRINGPARAM(" GROUP BY "));
aGroupByStr2 += aGroupByStr;
aGroupByStr = aGroupByStr2;
}
}
catch(SQLException&)
{
- OSL_ASSERT(!"Failure while building group by!");
+ OSL_FAIL("Failure while building group by!");
}
return aGroupByStr;
}
@@ -1574,7 +1502,7 @@ namespace
aDragLeft->SetField(aCondition);
aDragLeft->SetFunctionType(FKT_CONDITION);
- eErrorCode = _pSelectionBrw->InsertField(aDragLeft,BROWSER_INVALIDID,sal_False,sal_True).isValid() ? eOk : eTooManyColumns;
+ eErrorCode = _pSelectionBrw->InsertField(aDragLeft,BROWSER_INVALIDID,sal_False,sal_True).is() ? eOk : eTooManyColumns;
}
else //! TODO not supported yet
eErrorCode = eStatementTooComplex;
@@ -1618,13 +1546,6 @@ namespace
&rController.getParser().getContext(),
sal_True,
sal_True); // quote is to true because we need quoted elements inside the function
- // i75557
- //pFunction->parseNodeToPredicateStr(aColumnName,
- // xConnection,
- // rController.getNumberFormatter(),
- // _pView->getLocale(),
- // static_cast<sal_Char>(_pView->getDecimalSeparator().toChar()),
- // &rController.getParser().getContext());
// don't display the column name
aCondition = aCondition.copy(aColumnName.getLength());
aCondition = aCondition.trim();
@@ -1644,7 +1565,7 @@ namespace
for(;aIter != aTabEnd;++aIter)
{
OQueryTableWindow* pTabWin = static_cast<OQueryTableWindow*>(aIter->second);
- if (pTabWin->ExistsField( ::rtl::OUString::createFromAscii("*"), aDragLeft ))
+ if (pTabWin->ExistsField( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("*")), aDragLeft ))
{
aDragLeft->SetAlias(String());
aDragLeft->SetTable(String());
@@ -1693,7 +1614,7 @@ namespace
SqlParseError eErrorCode = eOk;
OQueryController& rController = static_cast<OQueryController&>(_pView->getController());
- DBG_ASSERT(SQL_ISRULE( pCondition, comparison_predicate),"ComparisonPredicate: pCondition ist kein ComparisonPredicate");
+ OSL_ENSURE(SQL_ISRULE( pCondition, comparison_predicate),"ComparisonPredicate: pCondition ist kein ComparisonPredicate");
if ( SQL_ISRULE(pCondition->getChild(0), column_ref )
|| SQL_ISRULE(pCondition->getChild(pCondition->count()-1), column_ref) )
{
@@ -1758,22 +1679,22 @@ namespace
case SQL_NODE_LESS:
// take the opposite as we change the order
i--;
- aCondition = aCondition + ::rtl::OUString::createFromAscii(">");
+ aCondition = aCondition + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(">"));
break;
case SQL_NODE_LESSEQ:
// take the opposite as we change the order
i--;
- aCondition = aCondition + ::rtl::OUString::createFromAscii(">=");
+ aCondition = aCondition + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(">="));
break;
case SQL_NODE_GREAT:
// take the opposite as we change the order
i--;
- aCondition = aCondition + ::rtl::OUString::createFromAscii("<");
+ aCondition = aCondition + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("<"));
break;
case SQL_NODE_GREATEQ:
// take the opposite as we change the order
i--;
- aCondition = aCondition + ::rtl::OUString::createFromAscii("<=");
+ aCondition = aCondition + ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("<="));
break;
default:
break;
@@ -1877,7 +1798,7 @@ namespace
rParseIter.getColumnRange( pColumnRef, aColumnName, aTableRange );
sal_Bool bFound(sal_False);
- DBG_ASSERT(aColumnName.getLength(),"Columnname darf nicht leer sein");
+ OSL_ENSURE(aColumnName.getLength(),"Columnname darf nicht leer sein");
if (!aTableRange.getLength())
{
// SELECT column, ...
@@ -1930,7 +1851,7 @@ namespace
sal_Bool InsertJoin(const OQueryDesignView* _pView,
const ::connectivity::OSQLParseNode *pNode)
{
- DBG_ASSERT( SQL_ISRULE( pNode, qualified_join ) || SQL_ISRULE( pNode, joined_table ) || SQL_ISRULE( pNode, cross_union ),
+ OSL_ENSURE( SQL_ISRULE( pNode, qualified_join ) || SQL_ISRULE( pNode, joined_table ) || SQL_ISRULE( pNode, cross_union ),
"OQueryDesignView::InsertJoin: Fehler im Parse Tree");
if (SQL_ISRULE(pNode,joined_table))
@@ -1944,7 +1865,7 @@ namespace
if ( !checkJoinConditions(_pView,pNode->getChild(0)) || !checkJoinConditions(_pView,pRightTableRef))
return sal_False;
- // named column join wird später vieleicht noch implementiert
+ // named column join wird sp�ter vieleicht noch implementiert
// SQL_ISRULE(pNode->getChild(4),named_columns_join)
EJoinType eJoinType = INNER_JOIN;
bool bNatural = false;
@@ -2020,7 +1941,7 @@ namespace
OTableFields& rUnUsedFields = rController.getUnUsedFields();
OTableFields::iterator aEnd = rUnUsedFields.end();
for(OTableFields::iterator aIter = rUnUsedFields.begin();aIter != aEnd;++aIter)
- if(_pSelectionBrw->InsertField(*aIter,BROWSER_INVALIDID,sal_False,sal_False).isValid())
+ if(_pSelectionBrw->InsertField(*aIter,BROWSER_INVALIDID,sal_False,sal_False).is())
(*aIter) = NULL;
OTableFields().swap( rUnUsedFields );
}
@@ -2071,7 +1992,7 @@ namespace
Reference< XConnection> xConnection = rController.getConnection();
if ( !xConnection.is() )
{
- DBG_ERROR( "InitFromParseNodeImpl: no connection? no connection!" );
+ OSL_FAIL( "InitFromParseNodeImpl: no connection? no connection!" );
break;
}
@@ -2178,7 +2099,7 @@ namespace
}
catch(SQLException&)
{
- OSL_ASSERT(!"getMaxTablesInSelect!");
+ OSL_FAIL("getMaxTablesInSelect!");
}
}
while ( false );
@@ -2223,7 +2144,7 @@ namespace
return eNoSelectStatement;
::connectivity::OSQLParseNode* pParseTree = pNode->getChild(2); // selection
- sal_Bool bFirstField = sal_True; // bei der Initialisierung muß auf alle Faelle das erste Feld neu aktiviert werden
+ sal_Bool bFirstField = sal_True; // bei der Initialisierung mu� auf alle Faelle das erste Feld neu aktiviert werden
SqlParseError eErrorCode = eOk;
@@ -2281,11 +2202,6 @@ namespace
_pView->getLocale(),
static_cast<sal_Char>(_pView->getDecimalSeparator().toChar()),
&rController.getParser().getContext());
- //pColumnRef->parseNodeToStr( aColumns,
- // xConnection,
- // &rController.getParser().getContext(),
- // sal_True,
- // sal_True); // quote is to true because we need quoted elements inside the function
sal_Int32 nFunctionType = FKT_NONE;
::connectivity::OSQLParseNode* pParamRef = NULL;
@@ -2308,7 +2224,7 @@ namespace
for(;aIter != aEnd;++aIter)
{
OQueryTableWindow* pTabWin = static_cast<OQueryTableWindow*>(aIter->second);
- if (pTabWin->ExistsField( ::rtl::OUString::createFromAscii("*"), aInfo ))
+ if (pTabWin->ExistsField( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("*")), aInfo ))
{
aInfo->SetAlias(String());
aInfo->SetTable(String());
@@ -2355,7 +2271,7 @@ namespace
eErrorCode = _pView->InsertField(aInfo, sal_True, bFirstField);
bFirstField = sal_False;
}
- else //if(SQL_ISRULE(pColumnRef,num_value_exp) || SQL_ISRULE(pColumnRef,term))
+ else
{
::rtl::OUString aColumns;
pColumnRef->parseNodeToStr( aColumns,
@@ -2388,7 +2304,7 @@ namespace
break;
}
- DBG_ERROR( "InstallFields: don't know how to interpret this parse node!" );
+ OSL_FAIL( "InstallFields: don't know how to interpret this parse node!" );
} while ( false );
}
@@ -2438,7 +2354,7 @@ namespace
for(;aIter != aEnd;++aIter)
{
OTableFieldDescRef pEntry = *aIter;
- if(pEntry.isValid() && pEntry->GetFieldAlias() == aColumnName)
+ if(pEntry.is() && pEntry->GetFieldAlias() == aColumnName)
pEntry->SetOrderDir( eOrderDir );
}
}
@@ -2834,7 +2750,7 @@ bool OQueryDesignView::HasFieldByAliasName(const ::rtl::OUString& rFieldName, OT
// -----------------------------------------------------------------------------
SqlParseError OQueryDesignView::InsertField( const OTableFieldDescRef& rInfo, sal_Bool bVis, sal_Bool bActivate)
{
- return m_pSelectionBox->InsertField( rInfo, BROWSER_INVALIDID,bVis, bActivate ).isValid() ? eOk : eTooManyColumns;
+ return m_pSelectionBox->InsertField( rInfo, BROWSER_INVALIDID,bVis, bActivate ).is() ? eOk : eTooManyColumns;
}
// -----------------------------------------------------------------------------
sal_Int32 OQueryDesignView::getColWidth(sal_uInt16 _nColPos) const
@@ -2848,7 +2764,7 @@ sal_Int32 OQueryDesignView::getColWidth(sal_uInt16 _nColPos) const
//------------------------------------------------------------------------------
void OQueryDesignView::fillValidFields(const ::rtl::OUString& sAliasName, ComboBox* pFieldList)
{
- DBG_ASSERT(pFieldList != NULL, "OQueryDesignView::FillValidFields : What the hell do you think I can do with a NULL-ptr ? This will crash !");
+ OSL_ENSURE(pFieldList != NULL, "OQueryDesignView::FillValidFields : What the hell do you think I can do with a NULL-ptr ? This will crash !");
pFieldList->Clear();
sal_Bool bAllTables = sAliasName.getLength() == 0;
@@ -2916,7 +2832,7 @@ sal_Bool OQueryDesignView::checkStatement()
{
sal_Bool bRet = sal_True;
if ( m_pSelectionBox )
- bRet = m_pSelectionBox->Save(); // a error occured so we return no
+ bRet = m_pSelectionBox->Save(); // an error occurred so we return no
return bRet;
}
//-------------------------------------------------------------------------------
@@ -2967,7 +2883,7 @@ sal_Bool OQueryDesignView::checkStatement()
const ::std::vector<OTableConnection*>* pConnList = m_pTableView->getTableConnections();
Reference< XConnection> xConnection = rController.getConnection();
::rtl::OUString aTableListStr(GenerateFromClause(xConnection,pTabList,pConnList));
- DBG_ASSERT(aTableListStr.getLength(), "OQueryDesignView::getStatement() : unerwartet : habe Felder, aber keine Tabellen !");
+ OSL_ENSURE(aTableListStr.getLength(), "OQueryDesignView::getStatement() : unerwartet : habe Felder, aber keine Tabellen !");
// wenn es Felder gibt, koennen die nur durch Einfuegen aus einer schon existenten Tabelle entstanden sein; wenn andererseits
// eine Tabelle geloescht wird, verschwinden auch die zugehoerigen Felder -> ergo KANN es das nicht geben, dass Felder
// existieren, aber keine Tabellen (und aFieldListStr hat schon eine Laenge, das stelle ich oben sicher)
@@ -2980,9 +2896,9 @@ sal_Bool OQueryDesignView::checkStatement()
GenerateInnerJoinCriterias(xConnection,aJoinCrit,pConnList);
if(aJoinCrit.getLength())
{
- ::rtl::OUString aTmp = ::rtl::OUString::createFromAscii("( ");
+ ::rtl::OUString aTmp(RTL_CONSTASCII_USTRINGPARAM("( "));
aTmp += aJoinCrit;
- aTmp += ::rtl::OUString::createFromAscii(" )");
+ aTmp += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" )"));
if(aCriteriaListStr.getLength())
{
aTmp += C_AND;
@@ -2991,16 +2907,16 @@ sal_Bool OQueryDesignView::checkStatement()
aCriteriaListStr = aTmp;
}
// ----------------- Statement aufbauen ----------------------
- ::rtl::OUStringBuffer aSqlCmd(::rtl::OUString::createFromAscii("SELECT "));
+ ::rtl::OUStringBuffer aSqlCmd(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SELECT ")));
if(static_cast<OQueryController&>(getController()).isDistinct())
- aSqlCmd.append(::rtl::OUString::createFromAscii(" DISTINCT "));
+ aSqlCmd.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" DISTINCT ")));
aSqlCmd.append(aFieldListStr);
- aSqlCmd.append(::rtl::OUString::createFromAscii(" FROM "));
+ aSqlCmd.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" FROM ")));
aSqlCmd.append(aTableListStr);
if (aCriteriaListStr.getLength())
{
- aSqlCmd.append(::rtl::OUString::createFromAscii(" WHERE "));
+ aSqlCmd.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" WHERE ")));
aSqlCmd.append(aCriteriaListStr.makeStringAndClear());
}
// ----------------- GroupBy aufbauen und Anh"angen ------------
@@ -3015,7 +2931,7 @@ sal_Bool OQueryDesignView::checkStatement()
// ----------------- having Anh"angen ------------
if(aHavingStr.getLength())
{
- aSqlCmd.append(::rtl::OUString::createFromAscii(" HAVING "));
+ aSqlCmd.append(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" HAVING ")));
aSqlCmd.append(aHavingStr.makeStringAndClear());
}
// ----------------- Sortierung aufbauen und Anh"angen ------------
@@ -3106,7 +3022,6 @@ void OQueryDesignView::SaveUIConfig()
{
OQueryController& rCtrl = static_cast<OQueryController&>(getController());
rCtrl.SaveTabWinsPosSize( m_pTableView->GetTabWinMap(), m_pScrollWindow->GetHScrollBar()->GetThumbPos(), m_pScrollWindow->GetVScrollBar()->GetThumbPos() );
- // rCtrl.SaveTabFieldsWidth( m_pSelectionBox );
rCtrl.setVisibleRows( m_pSelectionBox->GetNoneVisibleRows() );
if ( m_aSplitter.GetSplitPosPixel() != 0 )
rCtrl.setSplitPos( m_aSplitter.GetSplitPosPixel() );
@@ -3117,8 +3032,8 @@ OSQLParseNode* OQueryDesignView::getPredicateTreeFromEntry(OTableFieldDescRef pE
::rtl::OUString& _rsErrorMessage,
Reference<XPropertySet>& _rxColumn) const
{
- OSL_ENSURE(pEntry.isValid(),"Entry is null!");
- if(!pEntry.isValid())
+ OSL_ENSURE(pEntry.is(),"Entry is null!");
+ if(!pEntry.is())
return NULL;
Reference< XConnection> xConnection = static_cast<OQueryController&>(getController()).getConnection();
if(!xConnection.is())
@@ -3237,7 +3152,7 @@ void OQueryDesignView::initByFieldDescriptions( const Sequence< PropertyValue >&
++field
)
{
- ::vos::ORef< OTableFieldDesc > pField( new OTableFieldDesc() );
+ ::rtl::Reference< OTableFieldDesc > pField( new OTableFieldDesc() );
pField->Load( *field, true );
InsertField( pField, sal_True, sal_False );
}
@@ -3306,3 +3221,5 @@ void OQueryDesignView::fillFunctionInfo( const ::connectivity::OSQLParseNode* p
aInfo->SetTabWindow(NULL);
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.cxx b/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.cxx
index eb15150a5449..73d056e6cd5d 100644
--- a/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.cxx
+++ b/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_OQUERYMOVETABWINUNDOACT_HXX
#include "QueryMoveTabWinUndoAct.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOW_HXX
#include "QTableWindow.hxx"
-#endif
using namespace dbaui;
//------------------------------------------------------------------------------
void OJoinMoveTabWinUndoAct::TogglePosition()
@@ -54,3 +49,4 @@ void OJoinMoveTabWinUndoAct::TogglePosition()
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.hxx b/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.hxx
index 4e52665a6dd9..692bd3946fda 100644
--- a/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.hxx
+++ b/dbaccess/source/ui/querydesign/QueryMoveTabWinUndoAct.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_OQUERYMOVETABWINUNDOACT_HXX
#define DBAUI_OQUERYMOVETABWINUNDOACT_HXX
-#ifndef DBAUI_QUERYDESIGNUNDOACTION_HXX
#include "QueryDesignUndoAction.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef _SV_GEN_HXX
#include <tools/gen.hxx>
-#endif
namespace dbaui
{
@@ -70,3 +65,4 @@ namespace dbaui
#endif // DBAUI_OQUERYMOVETABWINUNDOACT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QuerySizeTabWinUndoAct.hxx b/dbaccess/source/ui/querydesign/QuerySizeTabWinUndoAct.hxx
index 5b790c0506d0..11a2fc0412de 100644
--- a/dbaccess/source/ui/querydesign/QuerySizeTabWinUndoAct.hxx
+++ b/dbaccess/source/ui/querydesign/QuerySizeTabWinUndoAct.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_QUERYSIZETABWINUNDOACT_HXX
#define DBAUI_QUERYSIZETABWINUNDOACT_HXX
-#ifndef DBAUI_QUERYDESIGNUNDOACTION_HXX
#include "QueryDesignUndoAction.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
namespace dbaui
{
@@ -86,3 +83,4 @@ namespace dbaui
#endif //DBAUI_QUERYSIZETABWINUNDOACT_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.cxx b/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.cxx
index 661ba69f68aa..daa6c840c1f3 100644
--- a/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.cxx
+++ b/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,27 +28,13 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYTABCONNUNDOACTION_HXX
#include "QueryTabConnUndoAction.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLECONNECTION_HXX
#include "QTableConnection.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBAUI_QUERYADDTABCONNUNDOACTION_HXX
#include "QueryAddTabConnUndoAction.hxx"
-#endif
-#ifndef DBAUI_QUERYTABWINSHOWUNDOACT_HXX
#include "QueryTabWinShowUndoAct.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
using namespace dbaui;
@@ -148,3 +135,5 @@ void OQueryTabWinDelUndoAct::Redo()
SetOwnership(sal_True);
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.hxx b/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.hxx
index 7803df303bb5..186c522279d5 100644
--- a/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.hxx
+++ b/dbaccess/source/ui/querydesign/QueryTabConnUndoAction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_QUERYTABCONNUNDOACTION_HXX
#define DBAUI_QUERYTABCONNUNDOACTION_HXX
-#ifndef DBAUI_QUERYDESIGNUNDOACTION_HXX
#include "QueryDesignUndoAction.hxx"
-#endif
namespace dbaui
{
@@ -57,3 +56,4 @@ namespace dbaui
#endif // DBAUI_QUERYTABCONNUNDOACTION_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryTabWinShowUndoAct.hxx b/dbaccess/source/ui/querydesign/QueryTabWinShowUndoAct.hxx
index 897d86e028a6..f5988bd65786 100644
--- a/dbaccess/source/ui/querydesign/QueryTabWinShowUndoAct.hxx
+++ b/dbaccess/source/ui/querydesign/QueryTabWinShowUndoAct.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef DBAUI_QUERYTABWINSHOWUNDOACT_HXX
#define DBAUI_QUERYTABWINSHOWUNDOACT_HXX
-#ifndef DBAUI_QUERYTABWINUNDOACT_HXX
#include "QueryTabWinUndoAct.hxx"
-#endif
namespace dbaui
{
@@ -64,3 +63,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.cxx b/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.cxx
index 864313775ab4..09ce9cd87d4c 100644
--- a/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.cxx
+++ b/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_OQueryTabWinUndoAct_HXX
#include "QueryTabWinUndoAct.hxx"
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOW_HXX
#include "QTableWindow.hxx"
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOWDATA_HXX
#include "QTableWindowData.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGNFIELDUNDOACT_HXX
#include "QueryDesignFieldUndoAct.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
using namespace dbaui;
@@ -149,7 +134,4 @@ void OTabFieldMovedUndoAct::Undo()
}
// -----------------------------------------------------------------------------
-
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.hxx b/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.hxx
index 4d32f23a6350..7afb6811e810 100644
--- a/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.hxx
+++ b/dbaccess/source/ui/querydesign/QueryTabWinUndoAct.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_QUERYTABWINUNDOACT_HXX
#define DBAUI_QUERYTABWINUNDOACT_HXX
-#ifndef DBAUI_QUERYDESIGNUNDOACTION_HXX
#include "QueryDesignUndoAction.hxx"
-#endif
#ifndef INCLUDED_VECTOR
#define INCLUDED_VECTOR
#include <vector>
@@ -85,3 +84,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryTableView.cxx b/dbaccess/source/ui/querydesign/QueryTableView.cxx
index 2d38373ed1ab..4fe07e5331e8 100644
--- a/dbaccess/source/ui/querydesign/QueryTableView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryTableView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,100 +29,38 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDINFO_HXX
#include "TableFieldInfo.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDDESC_HXX
#include "TableFieldDescription.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
+#include <osl/diagnose.h>
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOW_HXX
#include "QTableWindow.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLECONNECTION_HXX
#include "QTableConnection.hxx"
-#endif
-#ifndef DBAUI_QTABLECONNECTIONDATA_HXX
#include "QTableConnectionData.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef DBAUI_QUERYADDTABCONNUNDOACTION_HXX
#include "QueryAddTabConnUndoAction.hxx"
-#endif
-#ifndef DBAUI_QUERYTABWINSHOWUNDOACT_HXX
#include "QueryTabWinShowUndoAct.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XTABLESSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XKEYSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
#include <com/sun/star/accessibility/AccessibleEventId.hpp>
-#ifndef DBACCESS_JACCESS_HXX
#include "JAccess.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_KEYTYPE_HPP_
#include <com/sun/star/sdbcx/KeyType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XINDEXACCESS_HPP_
#include <com/sun/star/container/XIndexAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef DBAUI_QUERYDLG_HXX
#include "querydlg.hxx"
-#endif
-#ifndef DBAUI_JOINEXCHANGE_HXX
#include "JoinExchange.hxx"
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
using namespace dbaui;
using namespace ::com::sun::star::uno;
@@ -259,7 +198,7 @@ namespace
Reference<XPropertySet> xColumn;
if ( !( _rxSourceForeignKeyColumns->getByName(*pIter) >>= xColumn ) )
{
- OSL_ENSURE( false, "addConnections: invalid foreign key column!" );
+ OSL_FAIL( "addConnections: invalid foreign key column!" );
continue;
}
@@ -273,7 +212,7 @@ namespace
if(aFind.getLength())
pNewConnData->SetFieldIndex(JTCS_FROM,aFind[0]+1);
else
- OSL_ENSURE(0,"Column not found!");
+ OSL_FAIL("Column not found!");
}
// get the position inside the tabe
Reference<XNameAccess> xRefColumns = _rDest.GetOriginalColumns();
@@ -283,7 +222,7 @@ namespace
if(aFind.getLength())
pNewConnData->SetFieldIndex(JTCS_TO,aFind[0]+1);
else
- OSL_ENSURE(0,"Column not found!");
+ OSL_FAIL("Column not found!");
}
pNewConnData->AppendConnLine(*pIter,sRelatedColumn);
@@ -297,7 +236,6 @@ namespace
// automatically remove all connections adjacent to the win.
// (Because of this automatism we would have an ownerhsip ambiguity for
// the connection data if we would insert the conn-Undo-Action)
- // FS - 21.10.99 - 69183
}
}
}
@@ -345,7 +283,7 @@ void OQueryTableView::ReSync()
{
DBG_CHKTHIS(OQueryTableView,NULL);
TTableWindowData* pTabWinDataList = m_pView->getController().getTableWindowData();
- DBG_ASSERT((getTableConnections()->size()==0) && (GetTabWinMap()->size()==0),
+ OSL_ENSURE((getTableConnections()->size()==0) && (GetTabWinMap()->size()==0),
"vor OQueryTableView::ReSync() bitte ClearAll aufrufen !");
// ich brauche eine Sammlung aller Fensternamen, deren Anlegen schief geht, damit ich die entsprechenden Connections
@@ -501,7 +439,7 @@ void OQueryTableView::AddTabWin(const ::rtl::OUString& _rTableName, const ::rtl:
}
catch(SQLException&)
{
- OSL_ASSERT(!"qualifiedNameComponents");
+ OSL_FAIL("qualifiedNameComponents");
}
}
// -----------------------------------------------------------------------------
@@ -538,7 +476,7 @@ Reference<XPropertySet> getKeyReferencedTo(const Reference<XIndexAccess>& _rxKey
void OQueryTableView::AddTabWin(const ::rtl::OUString& _rComposedName, const ::rtl::OUString& _rTableName, const ::rtl::OUString& strAlias, sal_Bool bNewTable)
{
DBG_CHKTHIS(OQueryTableView,NULL);
- DBG_ASSERT(_rTableName.getLength() || strAlias.getLength(), "OQueryTableView::AddTabWin : kein Tabellen- und kein Aliasname !");
+ OSL_ENSURE(_rTableName.getLength() || strAlias.getLength(), "OQueryTableView::AddTabWin : kein Tabellen- und kein Aliasname !");
// wenn der Tabellenname nicht gesetzt ist, steht das fuer ein Dummy-Fenster, das braucht aber wenigstens einen Alias-Namen
// neue Datenstruktur erzeugen
@@ -814,7 +752,7 @@ void OQueryTableView::KeyInput( const KeyEvent& rEvt )
OQueryTableWindow* OQueryTableView::FindTable(const String& rAliasName)
{
DBG_CHKTHIS(OQueryTableView,NULL);
- DBG_ASSERT(rAliasName.Len(), "OQueryTableView::FindTable : der AliasName sollte nicht leer sein !");
+ OSL_ENSURE(rAliasName.Len(), "OQueryTableView::FindTable : der AliasName sollte nicht leer sein !");
// (nicht dass es schadet, aber es ist sinnlos und weist vielleicht auf Fehler beim Aufrufer hin)
OTableWindowMap::const_iterator aIter = GetTabWinMap()->find(rAliasName);
if(aIter != GetTabWinMap()->end())
@@ -842,7 +780,7 @@ sal_Bool OQueryTableView::FindTableFromField(const String& rFieldName, OTableFie
void OQueryTableView::RemoveTabWin(OTableWindow* pTabWin)
{
DBG_CHKTHIS(OQueryTableView,NULL);
- DBG_ASSERT(pTabWin != NULL, "OQueryTableView::RemoveTabWin : Fenster sollte ungleich NULL sein !");
+ OSL_ENSURE(pTabWin != NULL, "OQueryTableView::RemoveTabWin : Fenster sollte ungleich NULL sein !");
// mein Parent brauche ich, da es vom Loeschen erfahren soll
OQueryDesignView* pParent = static_cast<OQueryDesignView*>(getDesignView());
@@ -893,8 +831,6 @@ void OQueryTableView::GetConnection(OQueryTableConnection* pConn)
// bei mir und dem Dokument einfuegen
addConnection( pConn );
- // invalidieren (damit es neu gezeichnet wird)
- // pConn->Invalidate();
}
//------------------------------------------------------------------------
@@ -911,7 +847,7 @@ void OQueryTableView::HideTabWin( OQueryTableWindow* pTabWin, OQueryTabWinUndoAc
{
DBG_CHKTHIS(OQueryTableView,NULL);
OTableWindowMap* pTabWins = GetTabWinMap();
- DBG_ASSERT(pTabWins != NULL, "OQueryTableView::HideTabWin : habe keine TabWins !");
+ OSL_ENSURE(pTabWins != NULL, "OQueryTableView::HideTabWin : habe keine TabWins !");
if (pTabWin)
{
@@ -992,7 +928,7 @@ sal_Bool OQueryTableView::ShowTabWin( OQueryTableWindow* pTabWin, OQueryTabWinUn
if (pTabWin->Init())
{
TTableWindowData::value_type pData = pTabWin->GetData();
- DBG_ASSERT(pData != NULL, "OQueryTableView::ShowTabWin : TabWin hat keine Daten !");
+ OSL_ENSURE(pData != NULL, "OQueryTableView::ShowTabWin : TabWin hat keine Daten !");
// Wenn die Daten schon PosSize haben, diese benutzen
if (pData->HasPosition() && pData->HasSize())
{
@@ -1024,9 +960,6 @@ sal_Bool OQueryTableView::ShowTabWin( OQueryTableWindow* pTabWin, OQueryTabWinUn
for(;aIter != aEnd;++aIter)
addConnection(*aIter); // add all connections from the undo action
- // each connection should invalidated inside addConnection so we don't need this here any longer
-// if ( !pOwnList->empty() )
-// InvalidateConnections();
pTableCon->clear();
// und die Daten des Fensters ebenfalls in Liste (des Docs)
@@ -1062,7 +995,7 @@ sal_Bool OQueryTableView::ShowTabWin( OQueryTableWindow* pTabWin, OQueryTabWinUn
void OQueryTableView::InsertField(const OTableFieldDescRef& rInfo)
{
DBG_CHKTHIS(OQueryTableView,NULL);
- DBG_ASSERT(getDesignView() != NULL, "OQueryTableView::InsertField : habe kein Parent !");
+ OSL_ENSURE(getDesignView() != NULL, "OQueryTableView::InsertField : habe kein Parent !");
static_cast<OQueryDesignView*>(getDesignView())->InsertField(rInfo);
}
//------------------------------------------------------------------------------
@@ -1098,3 +1031,5 @@ bool OQueryTableView::supressCrossNaturalJoin(const TTableConnectionData::value_
return pQueryData && (pQueryData->GetJoinType() == CROSS_JOIN);
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryTextView.cxx b/dbaccess/source/ui/querydesign/QueryTextView.cxx
index 690316c35087..47d076163d27 100644
--- a/dbaccess/source/ui/querydesign/QueryTextView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryTextView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,48 +28,20 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYVIEW_TEXT_HXX
#include "QueryTextView.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTAINERWINDOW_HXX
#include "querycontainerwindow.hxx"
-#endif
-#ifndef DBAUI_QUERYVIEWSWITCH_HXX
#include "QueryViewSwitch.hxx"
-#endif
-#ifndef DBAUI_SQLEDIT_HXX
#include "sqledit.hxx"
-#endif
-#ifndef DBAUI_UNDOSQLEDIT_HXX
#include "undosqledit.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/unohlp.hxx>
-#endif
-#ifndef _SV_SPLIT_HXX
#include <vcl/split.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
using namespace dbaui;
using namespace ::com::sun::star::uno;
@@ -89,7 +62,6 @@ OQueryTextView::OQueryTextView(OQueryContainerWindow* _pParent)
m_pEdit->SaveValue();
m_pEdit->SetPosPixel( Point( 0, 0 ) );
m_pEdit->Show();
- // m_pEdit->GrabFocus();
}
// -----------------------------------------------------------------------------
OQueryTextView::~OQueryTextView()
@@ -177,3 +149,5 @@ void OQueryTextView::paste()
getContainerWindow()->getDesignView()->getController().setModified(sal_True);
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/QueryViewSwitch.cxx b/dbaccess/source/ui/querydesign/QueryViewSwitch.cxx
index 19e6933a37d3..845e63b0a052 100644
--- a/dbaccess/source/ui/querydesign/QueryViewSwitch.cxx
+++ b/dbaccess/source/ui/querydesign/QueryViewSwitch.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYVIEWSWITCH_HXX
#include "QueryViewSwitch.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBAUI_QUERYVIEW_TEXT_HXX
#include "QueryTextView.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTAINERWINDOW_HXX
#include "querycontainerwindow.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef DBAUI_QYDLGTAB_HXX
#include "adtabdlg.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef DBAUI_SQLEDIT_HXX
#include "sqledit.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTAINERWINDOW_HXX
#include "querycontainerwindow.hxx"
-#endif
using namespace dbaui;
using namespace ::com::sun::star::uno;
@@ -359,3 +340,5 @@ void OQueryViewSwitch::setNoneVisbleRow(sal_Int32 _nRows)
m_pDesignView->setNoneVisbleRow(_nRows);
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
index 66c7dd6cedff..b361a9ff5f2c 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,75 +28,29 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYDESIGN_OSELECTIONBROWSEBOX_HXX
#include "SelectionBrowseBox.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef DBAUI_TABLEFIELDINFO_HXX
#include "TableFieldInfo.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef DBAUI_QUERY_TABLEWINDOW_HXX
#include "QTableWindow.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBAUI_QUERYDESIGNFIELDUNDOACT_HXX
#include "QueryDesignFieldUndoAct.hxx"
-#endif
-#ifndef _SVX_DBEXCH_HRC
#include <svx/dbexch.hrc>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
+#include <osl/diagnose.h>
using namespace ::svt;
using namespace ::dbaui;
@@ -181,7 +136,6 @@ OSelectionBrowseBox::OSelectionBrowseBox( Window* pParent )
| BROWSER_HEADERBAR_NEW ;
m_pTextCell = new Edit(&GetDataWindow(), 0);
- // m_pTextCell->EnableSpecialCheck(sal_False);
m_pVisibleCell = new CheckBoxControl(&GetDataWindow());
m_pTableCell = new ListBoxControl(&GetDataWindow()); m_pTableCell->SetDropDownLineCount( 20 );
m_pFieldCell = new ComboBoxControl(&GetDataWindow()); m_pFieldCell->SetDropDownLineCount( 20 );
@@ -198,9 +152,6 @@ OSelectionBrowseBox::OSelectionBrowseBox( Window* pParent )
// TriState der ::com::sun::star::form::CheckBox abschalten
m_pVisibleCell->GetBox().EnableTriState( sal_False );
-// m_pEmptyEntry = new OTableFieldDesc();
-// m_pEmptyEntry->SetColWidth(DEFAULT_SIZE);
-
Font aTitleFont = OutputDevice::GetDefaultFont( DEFAULTFONT_SANS_UNICODE,Window::GetSettings().GetLanguage(),DEFAULTFONT_FLAGS_ONLYONE);
aTitleFont.SetSize(Size(0, 6));
SetTitleFont(aTitleFont);
@@ -257,16 +208,16 @@ void OSelectionBrowseBox::initialize()
String sGroup = m_aFunctionStrings.GetToken(m_aFunctionStrings.GetTokenCount() - 1);
m_aFunctionStrings = m_aFunctionStrings.GetToken(0);
- for (size_t i = 0; i < sizeof(eFunctions)/sizeof(eFunctions[0]) ; ++i)
+ for (size_t i = 0; i < SAL_N_ELEMENTS(eFunctions); ++i)
{
m_aFunctionStrings += String(RTL_CONSTASCII_USTRINGPARAM(";"));
m_aFunctionStrings += String(ByteString(rContext.getIntlKeywordAscii(eFunctions[i])),RTL_TEXTENCODING_UTF8);
- } // for (sal_Int32 i = 0; i < sizeof(eFunctions)/sizeof(eFunctions[0]) ; ++i)
+ }
m_aFunctionStrings += String(RTL_CONSTASCII_USTRINGPARAM(";"));
m_aFunctionStrings += sGroup;
- // Diese Funktionen stehen nur unter CORE zur Verfügung
+ // Diese Funktionen stehen nur unter CORE zur Verf�gung
if ( lcl_SupportsCoreSQLGrammar(xConnection) )
{
xub_StrLen nCount = m_aFunctionStrings.GetTokenCount();
@@ -381,11 +332,11 @@ void OSelectionBrowseBox::ColumnMoved( sal_uInt16 nColId,sal_Bool _bCreateUndo )
pUndoAct->SetTabFieldDescr(pOldEntry);
getDesignView()->getController().addUndoActionAndInvalidate(pUndoAct);
- } // if ( !m_bInUndoMode && _bCreateUndo )
+ }
}
}
else
- OSL_ENSURE(0,"Invalid column id!");
+ OSL_FAIL("Invalid column id!");
}
//------------------------------------------------------------------------------
void OSelectionBrowseBox::Init()
@@ -407,12 +358,12 @@ void OSelectionBrowseBox::Init()
Size aHeight;
const Control* pControls[] = { m_pTextCell,m_pVisibleCell,m_pTableCell,m_pFieldCell };
- for(sal_Size i= 0; i < sizeof(pControls)/sizeof(pControls[0]);++i)
+ for(sal_Size i= 0; i < SAL_N_ELEMENTS(pControls);++i)
{
const Size aTemp( pControls[i]->GetOptimalSize(WINDOWSIZE_PREFERRED) );
if ( aTemp.Height() > aHeight.Height() )
aHeight.Height() = aTemp.Height();
- } // for(int i= 0; i < sizeof(pControls)/sizeof(pControls[0]);++i
+ }
SetDataRowHeight(aHeight.Height());
SetTitleLines(1);
// Anzahl der sichtbaren Zeilen ermitteln
@@ -436,7 +387,7 @@ void OSelectionBrowseBox::Init()
}
catch(const SQLException&)
{
- OSL_ENSURE(0,"Catched Exception when asking for database metadata options!");
+ OSL_FAIL("Catched Exception when asking for database metadata options!");
m_nMaxColumns = 0;
}
}
@@ -500,9 +451,9 @@ CellController* OSelectionBrowseBox::GetController(long nRow, sal_uInt16 nColId)
if ( nColId > getFields().size() )
return NULL;
OTableFieldDescRef pEntry = getFields()[nColId-1];
- DBG_ASSERT(pEntry.isValid(), "OSelectionBrowseBox::GetController : keine FieldDescription !");
+ OSL_ENSURE(pEntry.is(), "OSelectionBrowseBox::GetController : keine FieldDescription !");
- if (!pEntry.isValid())
+ if (!pEntry.is())
return NULL;
if (static_cast<OQueryController&>(getDesignView()->getController()).isReadOnly())
@@ -537,7 +488,7 @@ void OSelectionBrowseBox::InitController(CellControllerRef& /*rController*/, lon
if ( nPos == 0 || nPos == BROWSER_INVALIDID || nPos > getFields().size() )
return;
OTableFieldDescRef pEntry = getFields()[nPos-1];
- DBG_ASSERT(pEntry.isValid(), "OSelectionBrowseBox::InitController : keine FieldDescription !");
+ OSL_ENSURE(pEntry.is(), "OSelectionBrowseBox::InitController : keine FieldDescription !");
long nCellIndex = GetRealRow(nRow);
switch (nCellIndex)
@@ -689,7 +640,7 @@ sal_Bool OSelectionBrowseBox::fillColumnRef(const ::rtl::OUString& _sColumnName,
if ( pTabWinList )
{
sal_uInt16 nTabCount = 0;
- if ( !static_cast<OQueryTableView*>(getDesignView()->getTableView())->FindTableFromField(_sColumnName,_pEntry,nTabCount) ) // error occured: column not in table window
+ if ( !static_cast<OQueryTableView*>(getDesignView()->getTableView())->FindTableFromField(_sColumnName,_pEntry,nTabCount) ) // error occurred: column not in table window
{
String sErrorMsg(ModuleRes(RID_STR_FIELD_DOESNT_EXIST));
sErrorMsg.SearchAndReplaceAscii("$name$",_sColumnName);
@@ -761,7 +712,7 @@ sal_Bool OSelectionBrowseBox::saveField(const String& _sFieldName,OTableFieldDes
if ( _pEntry->isAggreateFunction() )
{
- DBG_ASSERT(_pEntry->GetFunction().getLength(),"Functionname darf hier nicht leer sein! ;-(");
+ OSL_ENSURE(_pEntry->GetFunction().getLength(),"Functionname darf hier nicht leer sein! ;-(");
::rtl::OUStringBuffer aTmpStr2( _pEntry->GetFunction());
aTmpStr2.appendAscii("(");
aTmpStr2.append(sSql);
@@ -812,7 +763,7 @@ sal_Bool OSelectionBrowseBox::saveField(const String& _sFieldName,OTableFieldDes
{
sal_uInt16 nColumnPostion;
aSelEntry = FindFirstFreeCol(nColumnPostion);
- if ( !aSelEntry.isValid() )
+ if ( !aSelEntry.is() )
{
AppendNewCol(1);
aSelEntry = FindFirstFreeCol(nColumnPostion);
@@ -895,7 +846,7 @@ sal_Bool OSelectionBrowseBox::saveField(const String& _sFieldName,OTableFieldDes
notifyFunctionFieldChanged(sOldLocalizedFunctionName,sLocalizedFunctionName,_bListAction, nColumnId);
}
else
- OSL_ENSURE(0,"Unsupported function inserted!");
+ OSL_FAIL("Unsupported function inserted!");
}
else
@@ -949,7 +900,7 @@ sal_Bool OSelectionBrowseBox::saveField(const String& _sFieldName,OTableFieldDes
}
}
- if ( i > 0 && InsertField(aSelEntry,BROWSER_INVALIDID,sal_True,sal_False).isEmpty() ) // may we have to append more than one field
+ if ( i > 0 && !InsertField(aSelEntry,BROWSER_INVALIDID,sal_True,sal_False).is() ) // may we have to append more than one field
{ // the field could not be isnerted
String sErrorMessage( ModuleRes( RID_STR_FIELD_DOESNT_EXIST ) );
sErrorMessage.SearchAndReplaceAscii("$name$",aSelEntry->GetField());
@@ -972,11 +923,11 @@ sal_Bool OSelectionBrowseBox::SaveModified()
if(getFields().size() > static_cast<sal_uInt16>(nCurrentColumnPos - 1))
pEntry = getEntry(nCurrentColumnPos - 1);
- sal_Bool bWasEmpty = pEntry.isValid() ? pEntry->IsEmpty() : sal_False;
+ sal_Bool bWasEmpty = pEntry.is() ? pEntry->IsEmpty() : sal_False;
sal_Bool bError = sal_False;
sal_Bool bListAction = sal_False;
- if (pEntry.isValid() && Controller().Is() && Controller()->IsModified())
+ if (pEntry.is() && Controller().Is() && Controller()->IsModified())
{
// fuer die Undo-Action
String strOldCellContents,sNewValue;
@@ -1117,7 +1068,7 @@ sal_Bool OSelectionBrowseBox::SaveModified()
{
strOldCellContents = pEntry->GetFunction();
sal_uInt16 nPos = m_pFunctionCell->GetSelectEntryPos();
- // Diese Funktionen stehen nur unter CORE zur Verfügung
+ // Diese Funktionen stehen nur unter CORE zur Verf�gung
String sFunctionName = m_pFunctionCell->GetEntry(nPos);
String sGroupFunctionName = m_aFunctionStrings.GetToken(m_aFunctionStrings.GetTokenCount()-1);
sal_Bool bGroupBy = sal_False;
@@ -1239,7 +1190,6 @@ sal_Bool OSelectionBrowseBox::SaveModified()
bError = sal_True;
}
}
- // }
}
strOldCellContents = pEntry->GetCriteria(nIdx);
pEntry->SetCriteria(nIdx, aCrit);
@@ -1269,7 +1219,7 @@ sal_Bool OSelectionBrowseBox::SaveModified()
}
// habe ich Daten in einer FieldDescription gespeichert, die vorher leer war und es nach den Aenderungen nicht mehr ist ?
- if ( pEntry.isValid() && bWasEmpty && !pEntry->IsEmpty() && !bError )
+ if ( pEntry.is() && bWasEmpty && !pEntry->IsEmpty() && !bError )
{
// Default auf sichtbar
pEntry->SetVisible(sal_True);
@@ -1311,7 +1261,7 @@ void OSelectionBrowseBox::PaintCell(OutputDevice& rDev, const Rectangle& rRect,
if(getFields().size() > sal_uInt16(nPos - 1))
pEntry = getFields()[nPos - 1];
- if (!pEntry.isValid())
+ if (!pEntry.is())
return;
long nRow = GetRealRow(m_nSeekRow);
@@ -1346,7 +1296,7 @@ void OSelectionBrowseBox::RemoveColumn(sal_uInt16 _nColumnId)
sal_uInt16 nPos = GetColumnPos(_nColumnId);
// das Control sollte immer genau eine Spalte mehr haben, naemlich die HandleColumn
- DBG_ASSERT((nPos == 0) || (nPos <= getFields().size()), "OSelectionBrowseBox::RemoveColumn : invalid parameter nColId");
+ OSL_ENSURE((nPos == 0) || (nPos <= getFields().size()), "OSelectionBrowseBox::RemoveColumn : invalid parameter nColId");
// ColId ist bei mir gleichbedeutend mit Position, und da sollte die Bedingung natuerlich zutreffen
sal_uInt16 nCurCol = GetCurColumnId();
@@ -1402,7 +1352,7 @@ void OSelectionBrowseBox::RemoveField(sal_uInt16 nColumnId )
//------------------------------------------------------------------------------
void OSelectionBrowseBox::adjustSelectionMode( sal_Bool _bClickedOntoHeader, sal_Bool _bClickedOntoHandleCol )
{
- // wenn ein Header selectiert wird, muß die selection angezeigt werden, sonst nicht)
+ // wenn ein Header selectiert wird, mu� die selection angezeigt werden, sonst nicht)
if ( _bClickedOntoHeader )
{
if (0 == GetSelectColumnCount() )
@@ -1476,7 +1426,7 @@ sal_Int8 OSelectionBrowseBox::AcceptDrop( const BrowserAcceptDropEvent& rEvt )
{
if ( IsEditing() )
{
- // #100271# OJ allow the asterix again
+ // allow the asterix again
m_bDisableErrorBox = sal_True;
SaveModified();
m_bDisableErrorBox = sal_False;
@@ -1498,7 +1448,7 @@ sal_Int8 OSelectionBrowseBox::ExecuteDrop( const BrowserExecuteDropEvent& _rEvt
TransferableDataHelper aDropped(_rEvt.maDropEvent.Transferable);
if (!OJoinExchObj::isFormatAvailable(aDropped.GetDataFlavorExVector()))
{
- DBG_ERROR("OSelectionBrowseBox::ExecuteDrop: this should never have passed AcceptDrop!");
+ OSL_FAIL("OSelectionBrowseBox::ExecuteDrop: this should never have passed AcceptDrop!");
return DND_ACTION_NONE;
}
@@ -1573,7 +1523,7 @@ void OSelectionBrowseBox::SetColWidth(sal_uInt16 nColId, long nNewWidth)
// der FieldDescription Bescheid sagen
OTableFieldDescRef pEntry = getEntry(GetColumnPos(nColId) - 1);
- if (pEntry.isValid())
+ if (pEntry.is())
pEntry->SetColWidth(sal_uInt16(GetColumnWidth(nColId)));
if (bWasEditing)
@@ -1601,7 +1551,7 @@ void OSelectionBrowseBox::InsertColumn(OTableFieldDescRef pEntry, sal_uInt16& _n
{
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
// das Control sollte immer genau eine Spalte mehr haben, naemlich die HandleColumn
- DBG_ASSERT(_nColumnPostion == BROWSER_INVALIDID || (_nColumnPostion <= (long)getFields().size()), "OSelectionBrowseBox::InsertColumn : invalid parameter nColId.");
+ OSL_ENSURE(_nColumnPostion == BROWSER_INVALIDID || (_nColumnPostion <= (long)getFields().size()), "OSelectionBrowseBox::InsertColumn : invalid parameter nColId.");
// -1 heisst ganz hinten, Count heisst ganz hinten, der Rest bezeichnet eine richtige Position
sal_uInt16 nCurCol = GetCurColumnId();
@@ -1638,7 +1588,7 @@ void OSelectionBrowseBox::InsertColumn(OTableFieldDescRef pEntry, sal_uInt16& _n
getFields()[nOldPosition - 1] = pEntry;
ColumnMoved(pEntry->GetColumnId(),sal_False);
- } // if ( pEntry->GetColumnId() != nColumnId )
+ }
if ( pEntry->GetFunctionType() & (FKT_AGGREGATE) )
{
@@ -1724,7 +1674,7 @@ sal_uInt16 OSelectionBrowseBox::FieldsCount()
while (aIter != getFields().end())
{
- if ((*aIter).isValid() && !(*aIter)->IsEmpty())
+ if ((*aIter).is() && !(*aIter)->IsEmpty())
++nCount;
++aIter;
}
@@ -1745,7 +1695,7 @@ OTableFieldDescRef OSelectionBrowseBox::FindFirstFreeCol(sal_uInt16& _rColumnPos
{
++_rColumnPosition;
OTableFieldDescRef pEntry = (*aIter);
- if ( pEntry.isValid() && pEntry->IsEmpty() )
+ if ( pEntry.is() && pEntry->IsEmpty() )
return pEntry;
++aIter;
}
@@ -1761,7 +1711,7 @@ void OSelectionBrowseBox::CheckFreeColumns(sal_uInt16& _rColumnPosition)
{
// es ist voll, also einen Packen Spalten anhaengen
AppendNewCol(DEFAULT_QUERY_COLS);
- OSL_VERIFY(FindFirstFreeCol(_rColumnPosition).isValid());
+ OSL_VERIFY(FindFirstFreeCol(_rColumnPosition).is());
}
}
//------------------------------------------------------------------------------
@@ -1771,7 +1721,7 @@ void OSelectionBrowseBox::AddGroupBy( const OTableFieldDescRef& rInfo , sal_uInt
if(!xConnection.is())
return;
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
- DBG_ASSERT(!rInfo->IsEmpty(),"AddGroupBy:: OTableFieldDescRef sollte nicht Empty sein!");
+ OSL_ENSURE(!rInfo->IsEmpty(),"AddGroupBy:: OTableFieldDescRef sollte nicht Empty sein!");
OTableFieldDescRef pEntry;
const Reference<XDatabaseMetaData> xMeta = xConnection->getMetaData();
const ::comphelper::UStringMixEqual bCase(xMeta.is() && xMeta->supportsMixedCaseQuotedIdentifiers());
@@ -1783,7 +1733,7 @@ void OSelectionBrowseBox::AddGroupBy( const OTableFieldDescRef& rInfo , sal_uInt
for(;aIter != aEnd;++aIter)
{
pEntry = *aIter;
- OSL_ENSURE(pEntry.isValid(),"OTableFieldDescRef was null!");
+ OSL_ENSURE(pEntry.is(),"OTableFieldDescRef was null!");
const ::rtl::OUString aField = pEntry->GetField();
const ::rtl::OUString aAlias = pEntry->GetAlias();
@@ -1843,8 +1793,8 @@ void OSelectionBrowseBox::DuplicateConditionLevel( const sal_uInt16 nLevel)
++m_nVisibleCount;
}
m_bVisibleRow[BROW_CRIT1_ROW + nNewLevel] = sal_True;
- } // if (!pEntry->GetCriteria(nLevel).getLength() )
- } // for(;aIter != getFields().end();++aIter)
+ }
+ }
}
//------------------------------------------------------------------------------
void OSelectionBrowseBox::AddCondition( const OTableFieldDescRef& rInfo, const String& rValue, const sal_uInt16 nLevel,bool _bAddOrOnOneLine )
@@ -1853,7 +1803,7 @@ void OSelectionBrowseBox::AddCondition( const OTableFieldDescRef& rInfo, const S
if(!xConnection.is())
return;
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
- DBG_ASSERT(rInfo.isValid() && !rInfo->IsEmpty(),"AddCondition:: OTableFieldDescRef sollte nicht Empty sein!");
+ OSL_ENSURE(rInfo.is() && !rInfo->IsEmpty(),"AddCondition:: OTableFieldDescRef sollte nicht Empty sein!");
OTableFieldDescRef pLastEntry;
Reference<XDatabaseMetaData> xMeta = xConnection->getMetaData();
@@ -1878,7 +1828,6 @@ void OSelectionBrowseBox::AddCondition( const OTableFieldDescRef& rInfo, const S
pEntry->SetGroupBy(sal_False);
else
{
-// pEntry->SetGroupBy(rInfo->IsGroupBy());
if(!m_bGroupByUnRelated && pEntry->IsGroupBy())
pEntry->SetVisible(sal_True);
}
@@ -1893,14 +1842,14 @@ void OSelectionBrowseBox::AddCondition( const OTableFieldDescRef& rInfo, const S
}
m_bVisibleRow[BROW_CRIT1_ROW + nLevel] = sal_True;
break;
- } // if (!pEntry->GetCriteria(nLevel).getLength() )
+ }
if ( _bAddOrOnOneLine )
{
pLastEntry = pEntry;
}
}
- } // for(;aIter != getFields().end();++aIter)
- if ( pLastEntry.isValid() )
+ }
+ if ( pLastEntry.is() )
{
String sCriteria = rValue;
String sOldCriteria = pLastEntry->GetCriteria( nLevel );
@@ -1927,7 +1876,7 @@ void OSelectionBrowseBox::AddCondition( const OTableFieldDescRef& rInfo, const S
OTableFieldDescRef pTmp = InsertField(rInfo, BROWSER_INVALIDID, sal_False, sal_False );
if ( pTmp->isNumericOrAggreateFunction() && rInfo->IsGroupBy() ) // das GroupBy wird bereits von rInfo "ubernommen
pTmp->SetGroupBy(sal_False);
- if ( pTmp.isValid() )
+ if ( pTmp.is() )
{
pTmp->SetCriteria( nLevel, rValue);
if(nLevel == (m_nVisibleCount-BROW_CRIT1_ROW-1))
@@ -1947,7 +1896,7 @@ void OSelectionBrowseBox::AddOrder( const OTableFieldDescRef& rInfo, const EOrde
if(!xConnection.is())
return;
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
- DBG_ASSERT(!rInfo->IsEmpty(),"AddOrder:: OTableFieldDescRef sollte nicht Empty sein!");
+ OSL_ENSURE(!rInfo->IsEmpty(),"AddOrder:: OTableFieldDescRef sollte nicht Empty sein!");
OTableFieldDescRef pEntry;
Reference<XDatabaseMetaData> xMeta = xConnection->getMetaData();
::comphelper::UStringMixEqual bCase(xMeta.is() && xMeta->supportsMixedCaseQuotedIdentifiers());
@@ -1982,7 +1931,7 @@ void OSelectionBrowseBox::AddOrder( const OTableFieldDescRef& rInfo, const EOrde
if (aIter == rFields.end())
{
OTableFieldDescRef pTmp = InsertField(rInfo, BROWSER_INVALIDID, sal_False, sal_False );
- if(pTmp.isValid())
+ if(pTmp.is())
{
if ( !m_bOrderByUnRelated && !bAppend )
pTmp->SetVisible(sal_True);
@@ -2040,7 +1989,7 @@ void OSelectionBrowseBox::CellModified()
void OSelectionBrowseBox::Fill()
{
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
- DBG_ASSERT(ColCount() >= 1, "OSelectionBrowseBox::Fill : please call only after inserting the handle column !");
+ OSL_ENSURE(ColCount() >= 1, "OSelectionBrowseBox::Fill : please call only after inserting the handle column !");
sal_uInt16 nColCount = ColCount() - 1;
if (nColCount < DEFAULT_QUERY_COLS)
@@ -2160,7 +2109,7 @@ void OSelectionBrowseBox::Command(const CommandEvent& rEvt)
//------------------------------------------------------------------------------
sal_Bool OSelectionBrowseBox::IsRowVisible(sal_uInt16 _nWhich) const
{
- DBG_ASSERT(_nWhich<(m_bVisibleRow.size()), "OSelectionBrowseBox::IsRowVisible : invalid parameter !");
+ OSL_ENSURE(_nWhich<(m_bVisibleRow.size()), "OSelectionBrowseBox::IsRowVisible : invalid parameter !");
return m_bVisibleRow[_nWhich];
}
@@ -2168,7 +2117,7 @@ sal_Bool OSelectionBrowseBox::IsRowVisible(sal_uInt16 _nWhich) const
void OSelectionBrowseBox::SetRowVisible(sal_uInt16 _nWhich, sal_Bool _bVis)
{
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
- DBG_ASSERT(_nWhich<m_bVisibleRow.size(), "OSelectionBrowseBox::SetRowVisible : invalid parameter !");
+ OSL_ENSURE(_nWhich<m_bVisibleRow.size(), "OSelectionBrowseBox::SetRowVisible : invalid parameter !");
sal_Bool bWasEditing = IsEditing();
if (bWasEditing)
@@ -2218,7 +2167,7 @@ long OSelectionBrowseBox::GetRealRow(long nRowId) const
break;
}
}
- DBG_ASSERT(nErg <= long(m_bVisibleRow.size()),"nErg kann nicht groesser als BROW_ROW_CNT sein!");
+ OSL_ENSURE(nErg <= long(m_bVisibleRow.size()),"nErg kann nicht groesser als BROW_ROW_CNT sein!");
return i;
}
static long nVisibleRowMask[] =
@@ -2241,7 +2190,7 @@ sal_Int32 OSelectionBrowseBox::GetNoneVisibleRows() const
{
sal_Int32 nErg(0);
// only the first 11 row are interesting
- sal_Int32 nSize = sizeof(nVisibleRowMask) / sizeof(nVisibleRowMask[0]);
+ sal_Int32 nSize = SAL_N_ELEMENTS(nVisibleRowMask);
for(sal_Int32 i=0;i<nSize;i++)
{
if(!m_bVisibleRow[i])
@@ -2253,7 +2202,7 @@ sal_Int32 OSelectionBrowseBox::GetNoneVisibleRows() const
void OSelectionBrowseBox::SetNoneVisbleRow(long nRows)
{
// only the first 11 row are interesting
- sal_Int32 nSize = sizeof(nVisibleRowMask) / sizeof(nVisibleRowMask[0]);
+ sal_Int32 nSize = SAL_N_ELEMENTS(nVisibleRowMask);
for(sal_Int32 i=0;i< nSize;i++)
m_bVisibleRow[i] = !(nRows & nVisibleRowMask[i]);
}
@@ -2265,7 +2214,7 @@ String OSelectionBrowseBox::GetCellText(long nRow, sal_uInt16 nColId) const
sal_uInt16 nPos = GetColumnPos(nColId);
OTableFieldDescRef pEntry = getFields()[nPos-1];
- DBG_ASSERT(pEntry != NULL, "OSelectionBrowseBox::GetCellText : invalid column id, prepare for GPF ... ");
+ OSL_ENSURE(pEntry != NULL, "OSelectionBrowseBox::GetCellText : invalid column id, prepare for GPF ... ");
if ( pEntry->IsEmpty() )
return String();
@@ -2384,13 +2333,12 @@ sal_Bool OSelectionBrowseBox::GetFunctionName(sal_uInt32 _nFunctionTokenId,Strin
String OSelectionBrowseBox::GetCellContents(sal_Int32 nCellIndex, sal_uInt16 nColId)
{
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
- // DBG_ASSERT(nCellIndex < (GetRowCount()-1),"CellIndex ist zu gross");
if ( GetCurColumnId() == nColId && !m_bInUndoMode )
SaveModified();
sal_uInt16 nPos = GetColumnPos(nColId);
OTableFieldDescRef pEntry = getFields()[nPos - 1];
- DBG_ASSERT(pEntry != NULL, "OSelectionBrowseBox::GetCellContents : invalid column id, prepare for GPF ... ");
+ OSL_ENSURE(pEntry != NULL, "OSelectionBrowseBox::GetCellContents : invalid column id, prepare for GPF ... ");
switch (nCellIndex)
{
@@ -2418,7 +2366,7 @@ void OSelectionBrowseBox::SetCellContents(sal_Int32 nRow, sal_uInt16 nColId, con
sal_uInt16 nPos = GetColumnPos(nColId);
OTableFieldDescRef pEntry = getEntry(nPos - 1);
- DBG_ASSERT(pEntry != NULL, "OSelectionBrowseBox::SetCellContents : invalid column id, prepare for GPF ... ");
+ OSL_ENSURE(pEntry != NULL, "OSelectionBrowseBox::SetCellContents : invalid column id, prepare for GPF ... ");
switch (nRow)
@@ -2501,13 +2449,13 @@ void OSelectionBrowseBox::ColumnResized(sal_uInt16 nColId)
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
sal_uInt16 nPos = GetColumnPos(nColId);
- DBG_ASSERT(nPos <= getFields().size(),"ColumnResized:: nColId sollte nicht groesser als List::count sein!");
+ OSL_ENSURE(nPos <= getFields().size(),"ColumnResized:: nColId sollte nicht groesser als List::count sein!");
OTableFieldDescRef pEntry = getEntry(nPos-1);
- DBG_ASSERT(pEntry.isValid(), "OSelectionBrowseBox::ColumnResized : keine FieldDescription !");
+ OSL_ENSURE(pEntry.is(), "OSelectionBrowseBox::ColumnResized : keine FieldDescription !");
static_cast<OQueryController&>(getDesignView()->getController()).setModified( sal_True );
EditBrowseBox::ColumnResized(nColId);
- if ( pEntry.isValid())
+ if ( pEntry.is())
{
if ( !m_bInUndoMode )
{
@@ -2526,10 +2474,10 @@ sal_uInt32 OSelectionBrowseBox::GetTotalCellWidth(long nRowId, sal_uInt16 nColId
{
DBG_CHKTHIS(OSelectionBrowseBox,NULL);
sal_uInt16 nPos = GetColumnPos(nColId);
- DBG_ASSERT((nPos == 0) || (nPos <= getFields().size()), "OSelectionBrowseBox::GetTotalCellWidth : invalid parameter nColId");
+ OSL_ENSURE((nPos == 0) || (nPos <= getFields().size()), "OSelectionBrowseBox::GetTotalCellWidth : invalid parameter nColId");
OTableFieldDescRef pEntry = getFields()[nPos-1];
- DBG_ASSERT(pEntry.isValid(), "OSelectionBrowseBox::GetTotalCellWidth : invalid FieldDescription !");
+ OSL_ENSURE(pEntry.is(), "OSelectionBrowseBox::GetTotalCellWidth : invalid FieldDescription !");
long nRow = GetRealRow(nRowId);
String strText(GetCellText(nRow, nColId));
@@ -2730,8 +2678,8 @@ OTableFieldDescRef OSelectionBrowseBox::getEntry(OTableFields::size_type _nPos)
OSL_ENSURE(aFields.size() > _nPos,"ColID is to great!");
OTableFieldDescRef pEntry = aFields[_nPos];
- OSL_ENSURE(pEntry.isValid(),"Invalid entry!");
- if ( !pEntry.isValid() )
+ OSL_ENSURE(pEntry.is(),"Invalid entry!");
+ if ( !pEntry.is() )
{
pEntry = new OTableFieldDesc();
pEntry->SetColumnId(
@@ -2806,7 +2754,7 @@ void OSelectionBrowseBox::setFunctionCell(OTableFieldDescRef& _pEntry)
Reference< XConnection> xConnection = static_cast<OQueryController&>(getDesignView()->getController()).getConnection();
if ( xConnection.is() )
{
- // Diese Funktionen stehen nur unter CORE zur Verfügung
+ // Diese Funktionen stehen nur unter CORE zur Verf�gung
if ( lcl_SupportsCoreSQLGrammar(xConnection) )
{
// if we have an asterix, no other function than count is allowed
@@ -2859,7 +2807,7 @@ Reference< XAccessible > OSelectionBrowseBox::CreateAccessibleCell( sal_Int32 _n
if(getFields().size() > sal_uInt16(_nColumnPos - 1))
pEntry = getFields()[_nColumnPos - 1];
- if ( _nRow == BROW_VIS_ROW && pEntry.isValid() )
+ if ( _nRow == BROW_VIS_ROW && pEntry.is() )
return EditBrowseBox::CreateAccessibleCheckBoxCell( _nRow, _nColumnPos,pEntry->IsVisible() ? STATE_CHECK : STATE_NOCHECK );
return EditBrowseBox::CreateAccessibleCell( _nRow, _nColumnPos );
@@ -2875,7 +2823,7 @@ bool OSelectionBrowseBox::HasFieldByAliasName(const ::rtl::OUString& rFieldName,
{
if ( (*aIter)->GetFieldAlias() == rFieldName )
{
- rInfo.getBody() = (*aIter).getBody();
+ *rInfo = *(*aIter);
break;
}
}
@@ -2883,3 +2831,4 @@ bool OSelectionBrowseBox::HasFieldByAliasName(const ::rtl::OUString& rFieldName,
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx b/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
index 79aaf49c56e4..fc361d5fc16f 100644
--- a/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
+++ b/dbaccess/source/ui/querydesign/SelectionBrowseBox.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,30 +28,13 @@
#ifndef DBAUI_QUERYDESIGN_OSELECTIONBROWSEBOX_HXX
#define DBAUI_QUERYDESIGN_OSELECTIONBROWSEBOX_HXX
-#ifndef _SVTOOLS_EDITBROWSEBOX_HXX_
#include <svtools/editbrowsebox.hxx>
-#endif
-//#ifndef DBAUI_QUERYCONTROLLER_HXX
-//#include "querycontroller.hxx"
-//#endif
-#ifndef DBAUI_TABLEFIELDDESC_HXX
#include "TableFieldDescription.hxx"
-#endif
-#ifndef DBAUI_JOINEXCHANGE_HXX
#include "JoinExchange.hxx"
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTER_HPP_
#include <com/sun/star/util/XNumberFormatter.hpp>
-#endif
-#ifndef _STRING_HXX
#include <tools/string.hxx>
-#endif
-#ifndef _TRANSFER_HXX
#include <svtools/transfer.hxx>
-#endif
namespace connectivity
{
@@ -275,7 +259,7 @@ namespace dbaui
@param _bListAction
Will be set to <TRUE/> when we are in a list action otherwise <FALSE/>
@return
- <TRUE/> if an error occured otherwise <FALSE/>
+ <TRUE/> if an error occurred otherwise <FALSE/>
*/
sal_Bool saveField(const String& _sFieldName,OTableFieldDescRef& _pEntry,sal_Bool& _bListAction);
@@ -299,7 +283,7 @@ namespace dbaui
@param _bListAction
Will be set to <TRUE/> when we are in a list action otherwise <FALSE/>
@return
- <TRUE/> if an error occured otherwise <FALSE/>
+ <TRUE/> if an error occurred otherwise <FALSE/>
*/
sal_Bool fillColumnRef( const ::connectivity::OSQLParseNode* _pColumnRef,
const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XConnection >& _rxConnection,
@@ -360,3 +344,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableConnection.cxx b/dbaccess/source/ui/querydesign/TableConnection.cxx
index ce168efda15e..0edc45d81868 100644
--- a/dbaccess/source/ui/querydesign/TableConnection.cxx
+++ b/dbaccess/source/ui/querydesign/TableConnection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
#include <comphelper/stl_types.hxx>
-#endif
-#ifndef DBACCESS_CONNECTIONLINEACCESS_HXX
#include "ConnectionLineAccess.hxx"
-#endif
#include <algorithm>
@@ -254,3 +243,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableConnectionData.cxx b/dbaccess/source/ui/querydesign/TableConnectionData.cxx
index 93c0d8652cbf..2c5737159884 100644
--- a/dbaccess/source/ui/querydesign/TableConnectionData.cxx
+++ b/dbaccess/source/ui/querydesign/TableConnectionData.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLECONNECTIONDATA_HXX
#include "TableConnectionData.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COMPHELPER_STLTYPES_HXX_
+#include <osl/diagnose.h>
#include <comphelper/stl_types.hxx>
-#endif
using namespace dbaui;
using namespace comphelper;
@@ -65,7 +61,7 @@ void OTableConnectionData::Init()
{
//////////////////////////////////////////////////////////////////////
// LineDataList mit Defaults initialisieren
- DBG_ASSERT(m_vConnLineData.size() == 0, "OTableConnectionData::Init() : nur mit leere Linienliste aufzurufen !");
+ OSL_ENSURE(m_vConnLineData.size() == 0, "OTableConnectionData::Init() : nur mit leere Linienliste aufzurufen !");
ResetConnLines(sal_True);
// das legt Defaults an
}
@@ -88,7 +84,6 @@ OTableConnectionData::~OTableConnectionData()
DBG_DTOR(OTableConnectionData,NULL);
// LineDataList loeschen
OConnectionLineDataVec().swap(m_vConnLineData);
- //ResetConnLines(sal_False);
}
//------------------------------------------------------------------------
@@ -126,7 +121,7 @@ sal_Bool OTableConnectionData::SetConnLine( sal_uInt16 nIndex, const String& rSo
return AppendConnLine(rSourceFieldName, rDestFieldName);
OConnectionLineDataRef pConnLineData = m_vConnLineData[nIndex];
- DBG_ASSERT(pConnLineData != NULL, "OTableConnectionData::SetConnLine : habe ungueltiges LineData-Objekt");
+ OSL_ENSURE(pConnLineData != NULL, "OTableConnectionData::SetConnLine : habe ungueltiges LineData-Objekt");
pConnLineData->SetSourceFieldName( rSourceFieldName );
pConnLineData->SetDestFieldName( rDestFieldName );
@@ -147,7 +142,7 @@ sal_Bool OTableConnectionData::AppendConnLine( const ::rtl::OUString& rSourceFie
if(aIter == aEnd)
{
OConnectionLineDataRef pNew = new OConnectionLineData(rSourceFieldName, rDestFieldName);
- if (!pNew.isValid())
+ if (!pNew.is())
return sal_False;
m_vConnLineData.push_back(pNew);
@@ -200,3 +195,4 @@ void OTableConnectionData::normalizeLines()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableFieldDescription.cxx b/dbaccess/source/ui/querydesign/TableFieldDescription.cxx
index 8ea775f8dd2c..ef607a73da96 100644
--- a/dbaccess/source/ui/querydesign/TableFieldDescription.cxx
+++ b/dbaccess/source/ui/querydesign/TableFieldDescription.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEFIELDDESC_HXX
#include "TableFieldDescription.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
#include <comphelper/namedvaluecollection.hxx>
#include <functional>
@@ -65,7 +60,7 @@ OTableFieldDesc::OTableFieldDesc()
}
//------------------------------------------------------------------------------
OTableFieldDesc::OTableFieldDesc(const OTableFieldDesc& rRS)
- : ::vos::OReference()
+ : ::salhelper::SimpleReferenceObject()
{
DBG_CTOR(OTableFieldDesc,NULL);
@@ -244,3 +239,4 @@ void OTableFieldDesc::Save( ::comphelper::NamedValueCollection& o_rSettings, con
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableFieldInfo.cxx b/dbaccess/source/ui/querydesign/TableFieldInfo.cxx
index 71b800e6fe5f..bb990295e60b 100644
--- a/dbaccess/source/ui/querydesign/TableFieldInfo.cxx
+++ b/dbaccess/source/ui/querydesign/TableFieldInfo.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,12 +29,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEFIELDINFO_HXX
#include "TableFieldInfo.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace dbaui;
//==================================================================
@@ -57,3 +54,4 @@ OTableFieldInfo::~OTableFieldInfo()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableFieldInfo.hxx b/dbaccess/source/ui/querydesign/TableFieldInfo.hxx
index d8cced2f0005..090d71735665 100644
--- a/dbaccess/source/ui/querydesign/TableFieldInfo.hxx
+++ b/dbaccess/source/ui/querydesign/TableFieldInfo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_TABLEFIELDINFO_HXX
#define DBAUI_TABLEFIELDINFO_HXX
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef _SAL_TYPES_H_
#include <sal/types.h>
-#endif
namespace dbaui
{
@@ -55,3 +52,4 @@ namespace dbaui
#endif // DBAUI_TABLEFIELDINFO_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableWindow.cxx b/dbaccess/source/ui/querydesign/TableWindow.cxx
index 665c614a4d61..44e226852802 100644
--- a/dbaccess/source/ui/querydesign/TableWindow.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOWDATA_HXX
#include "TableWindowData.hxx"
-#endif
-#ifndef DBACCESS_IMAGEPROVIDER_HXX
#include "imageprovider.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _SV_SVAPP_HXX
+#include <osl/diagnose.h>
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_WALL_HXX
#include <vcl/wall.hxx>
-#endif
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
#include <com/sun/star/container/XNameAccess.hpp>
@@ -140,7 +121,7 @@ OTableWindow::~OTableWindow()
OSL_ENSURE(m_pListBox->GetEntryCount()==0,"Forgot to call EmptyListbox()!");
::std::auto_ptr<Window> aTemp(m_pListBox);
m_pListBox = NULL;
- } // if (m_pListBox)
+ }
if ( m_pContainerListener.is() )
m_pContainerListener->dispose();
@@ -207,13 +188,13 @@ sal_Bool OTableWindow::FillListBox()
m_pContainerListener = new ::comphelper::OContainerListenerAdapter(this,xContainer);
}
// mark all primary keys with special image
- ModuleRes TmpRes(isHiContrast(m_pListBox) ? IMG_JOINS_H : IMG_JOINS);
+ ModuleRes TmpRes(IMG_JOINS);
ImageList aImageList(TmpRes);
Image aPrimKeyImage = aImageList.GetImage(IMG_PRIMARY_KEY);
if (GetData()->IsShowAll())
{
- SvLBoxEntry* pEntry = m_pListBox->InsertEntry( ::rtl::OUString::createFromAscii("*") );
+ SvLBoxEntry* pEntry = m_pListBox->InsertEntry( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("*")) );
pEntry->SetUserData( createUserData(NULL,false) );
}
@@ -224,7 +205,7 @@ sal_Bool OTableWindow::FillListBox()
}
catch(Exception&)
{
- OSL_ENSURE(0,"Exception occured!");
+ OSL_FAIL("Exception occurred!");
}
try
{
@@ -253,7 +234,7 @@ sal_Bool OTableWindow::FillListBox()
}
catch(Exception&)
{
- OSL_ENSURE(0,"Exception occured!");
+ OSL_FAIL("Exception occurred!");
}
return sal_True;
@@ -292,17 +273,16 @@ void OTableWindow::impl_updateImage()
{
ImageProvider aImageProvider( getDesignView()->getController().getConnection() );
- Image aImage, aImageHC;
- aImageProvider.getImages( GetComposedName(), m_pData->isQuery() ? DatabaseObject::QUERY : DatabaseObject::TABLE, aImage, aImageHC );
+ Image aImage;
+ aImageProvider.getImages( GetComposedName(), m_pData->isQuery() ? DatabaseObject::QUERY : DatabaseObject::TABLE, aImage );
- if ( !aImage || !aImageHC )
+ if ( !aImage )
{
- OSL_ENSURE( false, "OTableWindow::impl_updateImage: no images!" );
+ OSL_FAIL( "OTableWindow::impl_updateImage: no images!" );
return;
}
- m_aTypeImage.SetModeImage( aImage, BMP_COLOR_NORMAL );
- m_aTypeImage.SetModeImage( aImageHC, BMP_COLOR_HIGHCONTRAST );
+ m_aTypeImage.SetModeImage( aImage );
m_aTypeImage.Show();
}
@@ -313,7 +293,7 @@ sal_Bool OTableWindow::Init()
if ( !m_pListBox )
{
m_pListBox = CreateListBox();
- DBG_ASSERT( m_pListBox != NULL, "OTableWindow::Init() : CreateListBox hat NULL geliefert !" );
+ OSL_ENSURE( m_pListBox != NULL, "OTableWindow::Init() : CreateListBox hat NULL geliefert !" );
m_pListBox->SetSelectionMode( MULTIPLE_SELECTION );
}
@@ -820,3 +800,4 @@ void OTableWindow::_elementReplaced( const container::ContainerEvent& /*_rEvent*
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableWindowAccess.cxx b/dbaccess/source/ui/querydesign/TableWindowAccess.cxx
index a9c4840b8e35..4d316871efd8 100644
--- a/dbaccess/source/ui/querydesign/TableWindowAccess.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindowAccess.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,45 +28,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_TABLEWINDOWACCESS_HXX
#include "TableWindowAccess.hxx"
-#endif
-#ifndef DBACCESS_JACCESS_HXX
#include "JAccess.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef DBAUI_JOINDESIGNVIEW_HXX
#include "JoinDesignView.hxx"
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLEROLE_HPP_
#include <com/sun/star/accessibility/AccessibleRole.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLERELATIONTYPE_HPP_
#include <com/sun/star/accessibility/AccessibleRelationType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLESTATETYPE_HPP_
#include <com/sun/star/accessibility/AccessibleStateType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLEEVENTID_HPP_
#include <com/sun/star/accessibility/AccessibleEventId.hpp>
-#endif
-#ifndef _COMPHELPER_SEQUENCE_HXX_
#include <comphelper/sequence.hxx>
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
namespace dbaui
@@ -74,7 +49,6 @@ namespace dbaui
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::lang;
- // using namespace ::com::sun::star::awt;
using namespace ::com::sun::star;
OTableWindowAccess::OTableWindowAccess(OTableWindow* _pTable)
@@ -125,14 +99,14 @@ namespace dbaui
Sequence< ::rtl::OUString > OTableWindowAccess::getSupportedServiceNames_Static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString > aSupported(2);
- aSupported[0] = ::rtl::OUString::createFromAscii("com.sun.star.accessibility.Accessible");
- aSupported[1] = ::rtl::OUString::createFromAscii("com.sun.star.accessibility.AccessibleContext");
+ aSupported[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.accessibility.Accessible"));
+ aSupported[1] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.accessibility.AccessibleContext"));
return aSupported;
}
// -----------------------------------------------------------------------------
::rtl::OUString OTableWindowAccess::getImplementationName_Static(void) throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.TableWindowAccessibility");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.TableWindowAccessibility"));
}
// -----------------------------------------------------------------------------
// XAccessibleContext
@@ -317,3 +291,4 @@ namespace dbaui
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableWindowData.cxx b/dbaccess/source/ui/querydesign/TableWindowData.cxx
index 08bff33149df..708a12906d22 100644
--- a/dbaccess/source/ui/querydesign/TableWindowData.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindowData.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEWINDOWDATA_HXX
#include "TableWindowData.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
#include <com/sun/star/sdb/XQueriesSupplier.hpp>
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
@@ -155,3 +152,5 @@ void OTableWindowData::listen()
}
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableWindowListBox.cxx b/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
index 9f44e1956474..4df65db90916 100644
--- a/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef DBAUI_JOINEXCHANGE_HXX
#include "JoinExchange.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
+#include <osl/diagnose.h>
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _SVX_DBEXCH_HRC
#include <svx/dbexch.hrc>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
using namespace dbaui;
using namespace ::com::sun::star::sdbc;
@@ -96,7 +77,7 @@ OTableWindowListBox::OTableWindowListBox( OTableWindow* pParent )
void OTableWindowListBox::dragFinished( )
{
// first show the error msg when existing
- m_pTabWin->getDesignView()->getController().showError(m_pTabWin->getDesignView()->getController().clearOccuredError());
+ m_pTabWin->getDesignView()->getController().showError(m_pTabWin->getDesignView()->getController().clearOccurredError());
// second look for ui activities which should happen after d&d
if (m_nUiEvent)
Application::RemoveUserEvent(m_nUiEvent);
@@ -185,7 +166,6 @@ long OTableWindowListBox::PreNotify(NotifyEvent& rNEvt)
if(m_pTabWin)
{
bHandled = m_pTabWin->HandleKeyInput(*pKeyEvent);
- // bHandled = sal_True;
}
break;
}
@@ -215,7 +195,6 @@ IMPL_LINK( OTableWindowListBox, ScrollUpHdl, SvTreeListBox*, /*pBox*/ )
ScrollOutputArea( -1 );
pEntry = GetEntry( m_aMousePos );
Select( pEntry, sal_True );
-// m_aScrollTimer.Start();
}
return 0;
@@ -233,7 +212,6 @@ IMPL_LINK( OTableWindowListBox, ScrollDownHdl, SvTreeListBox*, /*pBox*/ )
ScrollOutputArea( 1 );
pEntry = GetEntry( m_aMousePos );
Select( pEntry, sal_True );
-// m_aScrollTimer.Start();
}
return 0;
@@ -245,7 +223,7 @@ void OTableWindowListBox::StartDrag( sal_Int8 /*nAction*/, const Point& /*rPosPi
OJoinTableView* pCont = m_pTabWin->getTableView();
if (!pCont->getDesignView()->getController().isReadOnly() && pCont->getDesignView()->getController().isConnected())
{
- // #100271# OJ asterix was not allowed to be copied to selection browsebox
+ // asterix was not allowed to be copied to selection browsebox
sal_Bool bFirstNotAllowed = FirstSelected() == First() && m_pTabWin->GetData()->IsShowAll();
EndSelection();
// create a description of the source
@@ -266,7 +244,6 @@ sal_Int8 OTableWindowListBox::AcceptDrop( const AcceptDropEvent& _rEvt )
&& OJoinExchObj::isFormatAvailable(GetDataFlavorExVector(),SOT_FORMATSTR_ID_SBA_JOIN) )
{ // don't drop into the window if it's the drag source itself
-
// remove the selection if the dragging operation is leaving the window
if (_rEvt.mbLeaving)
SelectAll(sal_False);
@@ -345,7 +322,7 @@ IMPL_LINK( OTableWindowListBox, DropHdl, void *, /*EMPTY_ARG*/)
catch(const SQLException& e)
{
// remember the exception so that we can show them later when d&d is finished
- m_pTabWin->getDesignView()->getController().setErrorOccured(::dbtools::SQLExceptionInfo(e));
+ m_pTabWin->getDesignView()->getController().setErrorOccurred(::dbtools::SQLExceptionInfo(e));
}
return 0L;
}
@@ -400,7 +377,7 @@ IMPL_LINK( OTableWindowListBox, OnDoubleClick, SvTreeListBox *, /*pBox*/ )
{
// meinem Elter Bescheid sagen
Window* pParent = Window::GetParent();
- DBG_ASSERT(pParent != NULL, "OTableWindowListBox::OnDoubleClick : habe kein Parent !");
+ OSL_ENSURE(pParent != NULL, "OTableWindowListBox::OnDoubleClick : habe kein Parent !");
static_cast<OTableWindow*>(pParent)->OnEntryDoubleClicked(GetHdlEntry());
@@ -421,3 +398,5 @@ void OTableWindowListBox::Command(const CommandEvent& rEvt)
}
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/TableWindowTitle.cxx b/dbaccess/source/ui/querydesign/TableWindowTitle.cxx
index 37e22b92d0e0..e09b3dc4d3c1 100644
--- a/dbaccess/source/ui/querydesign/TableWindowTitle.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindowTitle.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,48 +28,20 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEWINDOWTITLE_HXX
#include "TableWindowTitle.hxx"
-#endif
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_HELP_HXX
#include <vcl/help.hxx>
-#endif
-#ifndef _SV_MENU_HXX
#include <vcl/menu.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _CNTIDS_HRC
#include <sfx2/cntids.hrc>
-#endif
-#ifndef DBAUI_TABLEWINDOWLISTBOX_HXX
#include "TableWindowListBox.hxx"
-#endif
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
#include <algorithm>
@@ -156,15 +129,6 @@ void OTableWindowTitle::Command( const CommandEvent& rEvt )
}
//------------------------------------------------------------------------------
-//void OTableWindowTitle::Paint( const Rectangle& rRect )
-//{
-// //////////////////////////////////////////////////////////////////////
-// // Ausgabe des Textes in der Titelzeile
-// Rectangle aWinRect( Point(0,0), GetSizePixel() );
-// DrawText( aWinRect, GetText(), TEXT_DRAW_CENTER|TEXT_DRAW_VCENTER|TEXT_DRAW_ENDELLIPSIS );
-//}
-
-//------------------------------------------------------------------------------
void OTableWindowTitle::KeyInput( const KeyEvent& rEvt )
{
if ( m_pTabWin )
@@ -243,6 +207,4 @@ void OTableWindowTitle::StateChanged( StateChangedType nType )
}
}
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/makefile.mk b/dbaccess/source/ui/querydesign/makefile.mk
deleted file mode 100644
index 36e36c960023..000000000000
--- a/dbaccess/source/ui/querydesign/makefile.mk
+++ /dev/null
@@ -1,89 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=querydesign
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-EXCEPTIONSFILES =\
- $(SLO)$/ConnectionLineAccess.obj \
- $(SLO)$/TableWindowAccess.obj \
- $(SLO)$/JAccess.obj \
- $(SLO)$/JoinDesignView.obj \
- $(SLO)$/JoinController.obj \
- $(SLO)$/QueryDesignView.obj \
- $(SLO)$/SelectionBrowseBox.obj \
- $(SLO)$/querydlg.obj \
- $(SLO)$/QueryTabWinUndoAct.obj \
- $(SLO)$/QueryMoveTabWinUndoAct.obj \
- $(SLO)$/QueryTabConnUndoAction.obj \
- $(SLO)$/TableFieldDescription.obj \
- $(SLO)$/JoinTableView.obj \
- $(SLO)$/QueryViewSwitch.obj \
- $(SLO)$/QueryTableView.obj \
- $(SLO)$/TableWindowData.obj \
- $(SLO)$/QTableWindow.obj \
- $(SLO)$/TableWindow.obj \
- $(SLO)$/JoinExchange.obj \
- $(SLO)$/TableWindowListBox.obj \
- $(SLO)$/TableWindowTitle.obj \
- $(SLO)$/QueryTextView.obj \
- $(SLO)$/QTableConnection.obj \
- $(SLO)$/querycontroller.obj \
- $(SLO)$/querycontainerwindow.obj \
- $(SLO)$/queryview.obj \
- $(SLO)$/TableConnection.obj \
- $(SLO)$/TableConnectionData.obj
-
-SLOFILES =\
- $(EXCEPTIONSFILES) \
- $(SLO)$/TableFieldInfo.obj \
- $(SLO)$/QTableConnectionData.obj \
- $(SLO)$/QTableWindowData.obj \
- $(SLO)$/ConnectionLine.obj \
- $(SLO)$/ConnectionLineData.obj
-
-SRS1NAME=$(TARGET)
-SRC1FILES = query.src \
- querydlg.src \
-
-# --- Targets -------------------------------------------------------
-
-
-.INCLUDE : target.mk
-
-$(SRS)$/$(TARGET).srs: $(SOLARINCDIR)$/svx$/globlmn.hrc
-
-
diff --git a/dbaccess/source/ui/querydesign/query.src b/dbaccess/source/ui/querydesign/query.src
index 01e4182e72ff..e5d4b4d964e7 100644
--- a/dbaccess/source/ui/querydesign/query.src
+++ b/dbaccess/source/ui/querydesign/query.src
@@ -97,27 +97,11 @@ Menu RID_QUERYCOLPOPUPMENU
};
};
};
+
ImageList IMG_JOINS
{
Prefix = "jo";
- MaskColor = Color {
- Red = 0xffff;
- Green = 0x0000;
- Blue = 0xffff;
- };
- IdList = {
- IMG_PRIMARY_KEY; IMG_FOREIGN_KEY;
- };
- IdCount = { 2; };
-};
-ImageList IMG_JOINS_H
-{
- Prefix = "joh";
- MaskColor = Color {
- Red = 0xffff;
- Green = 0x0000;
- Blue = 0xffff;
- };
+ MaskColor = Color { Red = 0xffff; Green = 0x0000; Blue = 0xffff; };
IdList = {
IMG_PRIMARY_KEY; IMG_FOREIGN_KEY;
};
@@ -161,6 +145,7 @@ String STR_QUERY_UNDO_TABFIELDCREATE
{
Text [ en-US ] = "Add Column" ;
};
+
String RID_STR_TABLE_DOESNT_EXIST
{
Text [ en-US ] = "Invalid expression, table '$name$' does not exist.";
@@ -170,6 +155,7 @@ String RID_STR_FIELD_DOESNT_EXIST
{
Text [ en-US ] = "Invalid expression, field name '$name$' does not exist.";
};
+
String RID_STR_TOMUCHTABLES
{
Text [ en-US ] = "The query covers #num# tables. The selected database type, however, can only process a maximum of #maxnum# table(s) per statement.";
@@ -184,10 +170,12 @@ String STR_QUERY_UNDO_MODIFY_CELL
{
Text [ en-US ] = "Edit Column Description";
};
+
String STR_QUERY_UNDO_SIZE_COLUMN
{
Text [ en-US ] = "Adjust column width";
};
+
String STR_QUERY_SORTTEXT
{
Text [ en-US ] = "(not sorted);ascending;descending" ;
@@ -197,14 +185,17 @@ String STR_QUERY_FUNCTIONS
{
Text [ en-US ] = "(no function);Group";
};
+
String STR_QUERY_NOTABLE
{
Text [ en-US ] = "(no table)";
};
+
String STR_QRY_ORDERBY_UNRELATED
{
Text [ en-US ] = "The database only supports sorting for visible fields.";
};
+
Menu RID_QUERYFUNCTION_POPUPMENU
{
ItemList =
@@ -243,6 +234,7 @@ Menu RID_QUERYFUNCTION_POPUPMENU
};
};
};
+
String STR_QUERY_HANDLETEXT
{
Text [ en-US ] = "Field;Alias;Table;Sort;Visible;Function;Criterion;Or;Or";
@@ -257,30 +249,39 @@ ErrorBox ERR_QRY_CRITERIA_ON_ASTERISK
{
Message [ en-US ] = "A condition cannot be applied to field [*]" ;
};
+
String STR_QRY_TOO_LONG_STATEMENT
{
Text [ en-US ] = "The SQL statement created is too long.";
};
+
String STR_QRY_TOOCOMPLEX
{
Text [ en-US ] = "Query is too complex" ;
};
+
String STR_QRY_NOSELECT
{
Text [ en-US ] = "Nothing has been selected." ;
};
+
String STR_QRY_TOOMANYCOND
{
Text [ en-US ] = "Too many search criteria" ;
};
+
String STR_QRY_SYNTAX
{
Text [ en-US ] = "SQL syntax error" ;
};
+
ErrorBox ERR_QRY_ORDERBY_ON_ASTERISK
{
Message [ en-US ] = "[*] cannot be used as a sort criterion.";
};
+
+
+
String STR_QRY_TOO_MANY_TABLES
{
Text [ en-US ] = "There are too many tables.";
@@ -290,10 +291,12 @@ String STR_QRY_NATIVE
{
Text [ en-US ] = "The statement will not be applied when querying in the SQL dialect of the database." ;
};
+
ErrorBox ERR_QRY_AMB_FIELD
{
Message [ en-US ] = "Field name not found or not unique" ;
};
+
String STR_QRY_ILLEGAL_JOIN
{
Text [ en-US ] = "Join could not be processed" ;
diff --git a/dbaccess/source/ui/querydesign/querycontainerwindow.cxx b/dbaccess/source/ui/querydesign/querycontainerwindow.cxx
index b288ff197f26..76a4d30ed845 100644
--- a/dbaccess/source/ui/querydesign/querycontainerwindow.cxx
+++ b/dbaccess/source/ui/querydesign/querycontainerwindow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,42 +29,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYCONTAINERWINDOW_HXX
#include "querycontainerwindow.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef DBAUI_JOINCONTROLLER_HXX
#include "JoinController.hxx"
-#endif
-#ifndef _TOOLKIT_HELPER_VCLUNOHELPER_HXX_
#include <toolkit/unohlp.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _SFXSIDS_HRC
#include <sfx2/sfxsids.hrc>
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XCLOSEABLE_HPP_
#include <com/sun/star/util/XCloseable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
//.........................................................................
namespace dbaui
@@ -109,12 +86,11 @@ namespace dbaui
m_xBeamer = NULL;
if(xCloseable.is())
xCloseable->close(sal_False); // false - holds the owner ship of this frame
- // m_xBeamer->setComponent(NULL,NULL);
- }
- {
- ::std::auto_ptr<Window> aTemp(m_pSplitter);
- m_pSplitter = NULL;
}
+
+ ::std::auto_ptr<Window> aTemp(m_pSplitter);
+ m_pSplitter = NULL;
+
}
// -----------------------------------------------------------------------------
bool OQueryContainerWindow::switchView( ::dbtools::SQLExceptionInfo* _pErrorInfo )
@@ -230,7 +206,7 @@ namespace dbaui
::dbaui::notifySystemWindow(this,m_pBeamer,::comphelper::mem_fun(&TaskPaneList::AddWindow));
- Reference < XFrame > xBeamerFrame( m_pViewSwitch->getORB()->createInstance(::rtl::OUString::createFromAscii("com.sun.star.frame.Frame")),UNO_QUERY );
+ Reference < XFrame > xBeamerFrame( m_pViewSwitch->getORB()->createInstance(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.frame.Frame"))),UNO_QUERY );
m_xBeamer.set( xBeamerFrame );
OSL_ENSURE(m_xBeamer.is(),"No frame created!");
m_xBeamer->initialize( VCLUnoHelper::GetInterface ( m_pBeamer ) );
@@ -286,3 +262,4 @@ namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/querycontroller.cxx b/dbaccess/source/ui/querydesign/querycontroller.cxx
index 276899efbf0b..3df54e243b5a 100644
--- a/dbaccess/source/ui/querydesign/querycontroller.cxx
+++ b/dbaccess/source/ui/querydesign/querycontroller.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -89,9 +90,10 @@
#include <svtools/localresaccess.hxx>
#include <toolkit/helper/vclunohelper.hxx>
#include <tools/diagnose_ex.h>
+#include <osl/diagnose.h>
#include <vcl/msgbox.hxx>
#include <vcl/svapp.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
extern "C" void SAL_CALL createRegistryInfo_OQueryControl()
{
@@ -123,12 +125,12 @@ namespace dbaui
// need by registration
static ::rtl::OUString getImplementationName_Static() throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.OViewDesign");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.OViewDesign"));
}
static Sequence< ::rtl::OUString > getSupportedServiceNames_Static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString> aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.ViewDesign");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ViewDesign"));
return aSupported;
}
static Reference< XInterface > SAL_CALL Create(const Reference< XMultiServiceFactory >& _rM)
@@ -155,11 +157,11 @@ namespace dbaui
if (!_pNode->isToken())
{
// Regelnamen als rule: ...
- rString = ::rtl::OUString::createFromAscii("RULE_ID: ");
+ rString = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("RULE_ID: "));
rString += ::rtl::OUString::valueOf( (sal_Int32)_pNode->getRuleID());
- rString+= ::rtl::OUString::createFromAscii("(");
+ rString+= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("("));
rString += OSQLParser::RuleIDToStr(_pNode->getRuleID());
- rString+= ::rtl::OUString::createFromAscii(")");
+ rString+= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(")"));
_pParent = _pBox->InsertEntry(rString,_pParent);
@@ -180,53 +182,58 @@ namespace dbaui
case SQL_NODE_KEYWORD:
{
- rString+= ::rtl::OUString::createFromAscii("SQL_KEYWORD:");
+ rString+= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_KEYWORD:"));
::rtl::OString sT = OSQLParser::TokenIDToStr(_pNode->getTokenID());
rString += ::rtl::OUString(sT,sT.getLength(),RTL_TEXTENCODING_UTF8);
break;}
case SQL_NODE_COMPARISON:
- {rString+= ::rtl::OUString::createFromAscii("SQL_COMPARISON:");
- rString += _pNode->getTokenValue(); // haenge Nodevalue an
+ {
+ rString+= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_COMPARISON:"));
+ rString += _pNode->getTokenValue(); // haenge Nodevalue an
// und beginne neu Zeile
- break;}
+ break;}
case SQL_NODE_NAME:
- {rString+= ::rtl::OUString::createFromAscii("SQL_NAME:");
- rString+= ::rtl::OUString::createFromAscii("\"");
- rString += _pNode->getTokenValue();
- rString+= ::rtl::OUString::createFromAscii("\"");
-
- break;}
+ {
+ rString+= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_NAME:"));
+ rString+= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("\""));
+ rString += _pNode->getTokenValue();
+ rString+= ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("\""));
+ break;}
case SQL_NODE_STRING:
- {rString += ::rtl::OUString::createFromAscii("SQL_STRING:'");
- rString += _pNode->getTokenValue();
- break;}
+ {
+ rString += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_STRING:'"));
+ rString += _pNode->getTokenValue();
+ break;}
case SQL_NODE_INTNUM:
- {rString += ::rtl::OUString::createFromAscii("SQL_INTNUM:");
- rString += _pNode->getTokenValue();
- break;}
+ {
+ rString += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_INTNUM:"));
+ rString += _pNode->getTokenValue();
+ break;}
case SQL_NODE_APPROXNUM:
- {rString += ::rtl::OUString::createFromAscii("SQL_APPROXNUM:");
- rString += _pNode->getTokenValue();
- break;}
+ {
+ rString += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_APPROXNUM:"));
+ rString += _pNode->getTokenValue();
+ break;}
case SQL_NODE_PUNCTUATION:
- {rString += ::rtl::OUString::createFromAscii("SQL_PUNCTUATION:");
- rString += _pNode->getTokenValue(); // haenge Nodevalue an
- break;}
+ {
+ rString += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_PUNCTUATION:"));
+ rString += _pNode->getTokenValue(); // haenge Nodevalue an
+ break;}
case SQL_NODE_AMMSC:
- {rString += ::rtl::OUString::createFromAscii("SQL_AMMSC:");
- rString += _pNode->getTokenValue(); // haenge Nodevalue an
-
- break;}
+ {
+ rString += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("SQL_AMMSC:"));
+ rString += _pNode->getTokenValue(); // haenge Nodevalue an
+ break;}
default:
- OSL_ASSERT("OSQLParser::ShowParseTree: unzulaessiger NodeType");
+ OSL_FAIL("OSQLParser::ShowParseTree: unzulaessiger NodeType");
rString += _pNode->getTokenValue();
}
_pBox->InsertEntry(rString,_pParent);
@@ -302,13 +309,13 @@ namespace
//------------------------------------------------------------------------------
::rtl::OUString OQueryController::getImplementationName_Static() throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.OQueryDesign");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.OQueryDesign"));
}
//------------------------------------------------------------------------------
Sequence< ::rtl::OUString> OQueryController::getSupportedServiceNames_Static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString> aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.QueryDesign");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.QueryDesign"));
return aSupported;
}
//-------------------------------------------------------------------------
@@ -354,7 +361,7 @@ OQueryController::~OQueryController()
DBG_DTOR(OQueryController,NULL);
if ( !getBroadcastHelper().bDisposed && !getBroadcastHelper().bInDispose )
{
- OSL_ENSURE(0,"Please check who doesn't dispose this component!");
+ OSL_FAIL("Please check who doesn't dispose this component!");
// increment ref count to prevent double call of Dtor
osl_incrementInterlockedCount( &m_refCount );
dispose();
@@ -664,7 +671,7 @@ void OQueryController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >&
}
}
}
- catch(const SQLException& e)
+ catch(const SQLException&)
{
aError = ::cppu::getCaughtException();
}
@@ -693,7 +700,6 @@ void OQueryController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >&
if(m_bGraphicalDesign)
InvalidateFeature(ID_BROWSER_ADDTABLE);
}
- // InvalidateFeature(ID_BROWSER_QUERY_EXECUTE);
break;
case SID_QUERY_VIEW_FUNCTIONS:
case SID_QUERY_VIEW_TABLES:
@@ -719,29 +725,24 @@ void OQueryController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >&
{
xCloseFrame->close( sal_True );
}
- catch( const Exception& )
+ catch(const Exception&)
{
- OSL_ENSURE( sal_False, "OQueryController::Execute(SID_DB_QUERY_PREVIEW): *nobody* is expected to veto closing the preview frame!" );
+ OSL_FAIL( "OQueryController::Execute(SID_DB_QUERY_PREVIEW): *nobody* is expected to veto closing the preview frame!" );
}
}
else
Execute(ID_BROWSER_QUERY_EXECUTE,Sequence< PropertyValue >());
}
- catch(Exception&)
+ catch(const Exception&)
{
}
break;
case ID_QUERY_ZOOM_IN:
{
-// m_aZoom *= Fraction(1,10);
-// static_cast<OQueryViewSwitch*>(getView())->zoomTableView(m_aZoom);
}
break;
case ID_QUERY_ZOOM_OUT:
{
-// if(m_aZoom != Fraction(1,1))
-// m_aZoom /= Fraction(1,10);
-// static_cast<OQueryViewSwitch*>(getView())->zoomTableView(m_aZoom);
}
break;
#if OSL_DEBUG_LEVEL > 1
@@ -778,11 +779,10 @@ void OQueryController::Execute(sal_uInt16 _nId, const Sequence< PropertyValue >&
pNodeTmp = pTemp->getChild(1);
OSQLParseNode::compress(pNodeTmp);
pNodeTmp = pTemp->getChild(1);
- } // if ( pCondition ) // no where clause
+ }
::rtl::OUString sTemp;
pNode->parseNodeToStr(sTemp,getConnection());
getContainer()->setStatement(sTemp);
-
}
}
@@ -863,7 +863,7 @@ void OQueryController::impl_initialize()
::rtl::OUString sIndependentSQLCommand;
if ( rArguments.get_ensureType( "IndependentSQLCommand", sIndependentSQLCommand ) )
{
- OSL_ENSURE( false, "OQueryController::impl_initialize: IndependentSQLCommand is regognized for compatibility only!" );
+ OSL_FAIL( "OQueryController::impl_initialize: IndependentSQLCommand is regognized for compatibility only!" );
sCommand = sIndependentSQLCommand;
m_nCommandType = CommandType::COMMAND;
}
@@ -871,7 +871,7 @@ void OQueryController::impl_initialize()
::rtl::OUString sCurrentQuery;
if ( rArguments.get_ensureType( "CurrentQuery", sCurrentQuery ) )
{
- OSL_ENSURE( false, "OQueryController::impl_initialize: CurrentQuery is regognized for compatibility only!" );
+ OSL_FAIL( "OQueryController::impl_initialize: CurrentQuery is regognized for compatibility only!" );
sCommand = sCurrentQuery;
m_nCommandType = CommandType::QUERY;
}
@@ -879,7 +879,7 @@ void OQueryController::impl_initialize()
sal_Bool bCreateView( sal_False );
if ( rArguments.get_ensureType( "CreateView", bCreateView ) && bCreateView )
{
- OSL_ENSURE( false, "OQueryController::impl_initialize: CurrentQuery is regognized for compatibility only!" );
+ OSL_FAIL( "OQueryController::impl_initialize: CurrentQuery is regognized for compatibility only!" );
m_nCommandType = CommandType::TABLE;
}
@@ -903,7 +903,7 @@ void OQueryController::impl_initialize()
m_sName = ::rtl::OUString();
break;
default:
- OSL_ENSURE( false, "OQueryController::impl_initialize: logic error in code!" );
+ OSL_FAIL( "OQueryController::impl_initialize: logic error in code!" );
throw RuntimeException();
}
@@ -911,7 +911,7 @@ void OQueryController::impl_initialize()
sal_Bool bGraphicalDesign( sal_True );
if ( rArguments.get_ensureType( (::rtl::OUString)PROPERTY_QUERYDESIGNVIEW, bGraphicalDesign ) )
{
- OSL_ENSURE( false, "OQueryController::impl_initialize: QueryDesignView is regognized for compatibility only!" );
+ OSL_FAIL( "OQueryController::impl_initialize: QueryDesignView is regognized for compatibility only!" );
m_bGraphicalDesign = bGraphicalDesign;
}
@@ -1050,7 +1050,7 @@ void OQueryController::impl_initialize()
setModified(sal_False);
}
- catch(SQLException& e)
+ catch(const SQLException& e)
{
DBG_UNHANDLED_EXCEPTION();
// we caught an exception so we switch to text only mode
@@ -1078,7 +1078,7 @@ void OQueryController::onLoadedMenu(const Reference< ::com::sun::star::frame::XL
{
if ( !editingCommand() )
{
- ::vos::OGuard aSolarGuard(Application::GetSolarMutex());
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
String aDefaultName = String( ModuleRes( editingView() ? STR_VIEW_TITLE : STR_QRY_TITLE ) );
sName = aDefaultName.GetToken(0,' ');
@@ -1101,7 +1101,7 @@ void OQueryController::setQueryComposer()
m_xComposer = xFactory->createQueryComposer();
getContainer()->setStatement(m_sStatement);
}
- catch (Exception&)
+ catch(const Exception&)
{
m_xComposer = NULL;
}
@@ -1159,12 +1159,12 @@ void OQueryController::impl_onModifyChanged()
// -----------------------------------------------------------------------------
void SAL_CALL OQueryController::disposing( const EventObject& Source ) throw(RuntimeException)
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
if ( getContainer() && Source.Source.is() )
{
if ( Source.Source == m_aCurrentFrame.getFrame() )
- { // our frame is beeing disposed -> close the preview window (if we have one)
+ { // our frame is being disposed -> close the preview window (if we have one)
Reference< XFrame > xPreviewFrame( getContainer()->getPreviewFrame() );
::comphelper::disposeComponent( xPreviewFrame );
}
@@ -1289,7 +1289,7 @@ void OQueryController::executeQuery()
InvalidateFeature(SID_DB_QUERY_PREVIEW);
URL aWantToDispatch;
- aWantToDispatch.Complete = ::rtl::OUString::createFromAscii(".component:DB/DataSourceBrowser");
+ aWantToDispatch.Complete = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".component:DB/DataSourceBrowser"));
::rtl::OUString sFrameName( FRAME_NAME_QUERY_PREVIEW );
sal_Int32 nSearchFlags = FrameSearchFlag::CHILDREN;
@@ -1350,12 +1350,12 @@ void OQueryController::executeQuery()
}
else
{
- OSL_ENSURE(0,"Couldn't create a beamer window!");
+ OSL_FAIL("Couldn't create a beamer window!");
}
}
catch(const Exception&)
{
- OSL_ENSURE(0,"Couldn't create a beamer window!");
+ OSL_FAIL("Couldn't create a beamer window!");
}
}
}
@@ -1381,7 +1381,6 @@ sal_Bool OQueryController::askForNewName(const Reference<XNameAccess>& _xElement
{
String sName = String( ModuleRes( editingView() ? STR_VIEW_TITLE : STR_QRY_TITLE ) );
aDefaultName = sName.GetToken(0,' ');
- //aDefaultName = getPrivateTitle( );
aDefaultName = ::dbtools::createUniqueName(_xElements,aDefaultName);
}
@@ -1547,7 +1546,7 @@ bool OQueryController::doSaveAsDoc(sal_Bool _bSaveAs)
// now check if our datasource has set a tablefilter and if so, append the new table name to it
::dbaui::appendToFilter( getConnection(), m_sName, getORB(), getView() );
- } // if ( editingView() )
+ }
Reference< XTitleChangeListener> xEventListener(impl_getTitleHelper_throw(),UNO_QUERY);
if ( xEventListener.is() )
{
@@ -1561,13 +1560,13 @@ bool OQueryController::doSaveAsDoc(sal_Bool _bSaveAs)
bSuccess = true;
}
- catch( const SQLException& )
+ catch(const SQLException&)
{
if ( !bNew )
m_sName = sOriginalName;
aInfo = SQLExceptionInfo( ::cppu::getCaughtException() );
}
- catch(Exception&)
+ catch(const Exception&)
{
if ( !bNew )
m_sName = sOriginalName;
@@ -1612,11 +1611,11 @@ bool OQueryController::doSaveAsDoc(sal_Bool _bSaveAs)
m_xComposer->setQuery(sTranslatedStmt);
sTranslatedStmt = m_xComposer->getComposedQuery();
}
- catch(SQLException& e)
+ catch(const SQLException& e)
{
::dbtools::SQLExceptionInfo aInfo(e);
showError(aInfo);
- // an error occured so we clear the statement
+ // an error occurred so we clear the statement
sTranslatedStmt = ::rtl::OUString();
}
}
@@ -1635,7 +1634,7 @@ bool OQueryController::doSaveAsDoc(sal_Bool _bSaveAs)
// -----------------------------------------------------------------------------
short OQueryController::saveModified()
{
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
short nRet = RET_YES;
if ( !isConnected() || !isModified() )
@@ -1698,7 +1697,7 @@ void OQueryController::impl_reset( const bool i_bForceCurrentControllerSettings
}
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "OQueryController::impl_reset: could not retrieve the layout information from the query!" );
+ OSL_FAIL( "OQueryController::impl_reset: could not retrieve the layout information from the query!" );
}
}
}
@@ -1834,7 +1833,7 @@ bool OQueryController::allowViews() const
// -----------------------------------------------------------------------------
bool OQueryController::allowQueries() const
{
- DBG_ASSERT( getSdbMetaData().isConnected(), "OQueryController::allowQueries: illegal call!" );
+ OSL_ENSURE( getSdbMetaData().isConnected(), "OQueryController::allowQueries: illegal call!" );
if ( !getSdbMetaData().supportsSubqueriesInFrom() )
return false;
@@ -1866,3 +1865,4 @@ void SAL_CALL OQueryController::restoreViewData(const Any& /*Data*/) throw( Runt
} // namespace dbaui
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/querydlg.cxx b/dbaccess/source/ui/querydesign/querydlg.cxx
index 012eec40b83e..1b932edbb16d 100644
--- a/dbaccess/source/ui/querydesign/querydlg.cxx
+++ b/dbaccess/source/ui/querydesign/querydlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,42 +28,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYDLG_HXX
#include "querydlg.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBAUI_QUERYDLG_HRC
#include "querydlg.hrc"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef DBAUI_QTABLECONNECTIONDATA_HXX
#include "QTableConnectionData.hxx"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
-#ifndef DBAUI_QUERYTABLEVIEW_HXX
#include "QueryTableView.hxx"
-#endif
-#ifndef DBAUI_QUERYDESIGNVIEW_HXX
#include "QueryDesignView.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef DBAUI_RELATIONCONTROL_HXX
#include "RelationControl.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
using namespace dbaui;
using namespace ::com::sun::star::uno;
@@ -278,12 +255,12 @@ IMPL_LINK( DlgQryJoin, LBChangeHdl, ListBox*, /*pListBox*/ )
String sHelpText = String( ModuleRes( nResId ) );
if( nPos )
{
- sHelpText.SearchAndReplace( String( RTL_CONSTASCII_STRINGPARAM( "%1" ) ), sFirstWinName );
- sHelpText.SearchAndReplace( String( RTL_CONSTASCII_STRINGPARAM( "%2" ) ), sSecondWinName );
+ sHelpText.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "%1" ) ), sFirstWinName );
+ sHelpText.SearchAndReplace( String( RTL_CONSTASCII_USTRINGPARAM( "%2" ) ), sSecondWinName );
}
if ( bAddHint )
{
- sHelpText += String( RTL_CONSTASCII_STRINGPARAM( "\n" ) );
+ sHelpText += String( RTL_CONSTASCII_USTRINGPARAM( "\n" ) );
sHelpText += String( ModuleRes( STR_JOIN_TYPE_HINT ) );
}
@@ -343,8 +320,6 @@ TTableConnectionData::value_type DlgQryJoin::getConnectionData() const
// -----------------------------------------------------------------------------
void DlgQryJoin::setValid(sal_Bool _bValid)
{
- //LBChangeHdl(&aLB_JoinType);
-
aPB_OK.Enable(_bValid || eJoinType == CROSS_JOIN );
}
// -----------------------------------------------------------------------------
@@ -397,3 +372,4 @@ void DlgQryJoin::setJoinType(EJoinType _eNewJoinType)
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/querydlg.hxx b/dbaccess/source/ui/querydesign/querydlg.hxx
index 1456ce70dbb7..21f4aea129ef 100644
--- a/dbaccess/source/ui/querydesign/querydlg.hxx
+++ b/dbaccess/source/ui/querydesign/querydlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -26,31 +27,17 @@
************************************************************************/
#ifndef DBAUI_QUERYDLG_HXX
#define DBAUI_QUERYDLG_HXX
-#ifndef _SV_DIALOG_HXX //autogen
#include <vcl/dialog.hxx>
-#endif
-#ifndef _SV_BUTTON_HXX //autogen
#include <vcl/button.hxx>
-#endif
-#ifndef _SV_FIXED_HXX //autogen
#include <vcl/fixed.hxx>
-#endif
-#ifndef _SV_LSTBOX_HXX
#include <vcl/lstbox.hxx>
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef DBAUI_RELCONTROLIFACE_HXX
#include "RelControliFace.hxx"
-#endif
-#ifndef DBAUI_JOINTABLEVIEW_HXX
#include "JoinTableView.hxx"
-#endif
namespace dbaui
@@ -118,3 +105,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/querydesign/querydlg.src b/dbaccess/source/ui/querydesign/querydlg.src
index 730cbb4ed780..e0aec2c49d84 100644
--- a/dbaccess/source/ui/querydesign/querydlg.src
+++ b/dbaccess/source/ui/querydesign/querydlg.src
@@ -183,13 +183,13 @@ String STR_QUERY_FULL_JOIN
{
Text [ en-US ] = "Contains ALL records from '%1' and from '%2'.";
};
+
String STR_QUERY_CROSS_JOIN
{
Text [ en-US ] = "Contains the cartesian product of ALL records from '%1' and from '%2'.";
};
+
String STR_QUERY_NATURAL_JOIN
{
Text [ en-US ] = "Contains only one column for each pair of equally-named columns from '%1' and from '%2'.";
};
-
-
diff --git a/dbaccess/source/ui/querydesign/queryview.cxx b/dbaccess/source/ui/querydesign/queryview.cxx
index 60effc75d178..ff68e029b311 100644
--- a/dbaccess/source/ui/querydesign/queryview.cxx
+++ b/dbaccess/source/ui/querydesign/queryview.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_QUERYVIEW_HXX
#include "queryview.hxx"
-#endif
-#ifndef _DBU_QRY_HRC_
#include "dbu_qry.hrc"
-#endif
-#ifndef DBAUI_QUERYCONTROLLER_HXX
#include "querycontroller.hxx"
-#endif
using namespace dbaui;
@@ -60,3 +55,4 @@ OQueryView::~OQueryView()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/RTableConnection.cxx b/dbaccess/source/ui/relationdesign/RTableConnection.cxx
index d023475b6323..a90653596855 100644
--- a/dbaccess/source/ui/relationdesign/RTableConnection.cxx
+++ b/dbaccess/source/ui/relationdesign/RTableConnection.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_RTABLECONNECTION_HXX
#include "RTableConnection.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_RELATION_TABLEVIEW_HXX
#include "RelationTableView.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
using namespace dbaui;
//========================================================================
@@ -155,3 +146,5 @@ void ORelationTableConnection::Draw( const Rectangle& rRect )
GetParent()->DrawText( aDestPos, aDestText, TEXT_DRAW_CLIP | TEXT_DRAW_CENTER | TEXT_DRAW_BOTTOM);
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/RTableConnection.hxx b/dbaccess/source/ui/relationdesign/RTableConnection.hxx
index a96b559596be..c9be2d46cc9e 100644
--- a/dbaccess/source/ui/relationdesign/RTableConnection.hxx
+++ b/dbaccess/source/ui/relationdesign/RTableConnection.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_RTABLECONNECTION_HXX
#define DBAUI_RTABLECONNECTION_HXX
-#ifndef DBAUI_TABLECONNECTION_HXX
#include "TableConnection.hxx"
-#endif
-#ifndef DBAUI_RTABLECONNECTIONDATA_HXX
#include "RTableConnectionData.hxx"
-#endif
namespace dbaui
{
@@ -57,3 +54,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx b/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx
index 1a035517932b..2d5562406a9e 100644
--- a/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx
+++ b/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -415,7 +416,7 @@ xKey.clear();
}
}
xKey.clear();
- } // for(sal_Int32 i=0;i<xKeys->getCount();++i)
+ }
if ( bDropRelation )
{
DropRelation();
@@ -423,8 +424,6 @@ xKey.clear();
::dbtools::throwGenericSQLException(sError,NULL);
}
-// OSL_ENSURE(xKey.is(),"No key found have insertion!");
-
// The fields the relation marks may not be the same as our LineDatas mark after the relation has been updated
if ( xColSup.is() )
{
@@ -453,8 +452,8 @@ xKey.clear();
m_vConnLineData.push_back(pNewData);
}
}
- } // if ( xColSup.is() )
- // NOTE : the caller is resposible for updating any other objects referencing the old LineDatas (for instance a ConnLine)
+ }
+ // NOTE : the caller is responsible for updating any other objects referencing the old LineDatas (for instance a ConnLine)
////////////////////////////////////////////////////////////
// Kardinalitaet bestimmen
@@ -464,3 +463,4 @@ xKey.clear();
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/RTableWindow.hxx b/dbaccess/source/ui/relationdesign/RTableWindow.hxx
index 2300fa346892..12c7b51e5b42 100644
--- a/dbaccess/source/ui/relationdesign/RTableWindow.hxx
+++ b/dbaccess/source/ui/relationdesign/RTableWindow.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_RELTABLEWINDOW_HXX
#define DBAUI_RELTABLEWINDOW_HXX
-#ifndef DBAUI_TABLEWINDOW_HXX
#include "TableWindow.hxx"
-#endif
namespace dbaui
{
@@ -49,3 +48,4 @@ namespace dbaui
#endif //DBAUI_RELTABLEWINDOW_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/RelationController.cxx b/dbaccess/source/ui/relationdesign/RelationController.cxx
index 730abe6859e3..6ab4bd3c96f4 100644
--- a/dbaccess/source/ui/relationdesign/RelationController.cxx
+++ b/dbaccess/source/ui/relationdesign/RelationController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -72,7 +73,7 @@
#include <tools/diagnose_ex.h>
#include <vcl/waitobj.hxx>
#include <osl/thread.hxx>
-#include <vos/mutex.hxx>
+#include <osl/mutex.hxx>
#define MAX_THREADS 10
@@ -95,8 +96,6 @@ using namespace ::com::sun::star::sdbc;
using namespace ::com::sun::star::sdb;
using namespace ::com::sun::star::ui::dialogs;
using namespace ::com::sun::star::util;
-// using namespace ::com::sun::star::sdbcx;
-// using namespace ::connectivity;
using namespace ::dbtools;
using namespace ::dbaui;
using namespace ::comphelper;
@@ -111,13 +110,13 @@ using namespace ::osl;
//------------------------------------------------------------------------------
::rtl::OUString ORelationController::getImplementationName_Static() throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.ORelationDesign");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.ORelationDesign"));
}
//------------------------------------------------------------------------------
Sequence< ::rtl::OUString> ORelationController::getSupportedServiceNames_Static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString> aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.RelationDesign");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.RelationDesign"));
return aSupported;
}
//-------------------------------------------------------------------------
@@ -347,7 +346,7 @@ namespace
{
::comphelper::disposeComponent(xResult);
loadTableData(m_xTables->getByName(*pIter));
- } // if ( xResult.is() && xResult->next() )
+ }
}
catch( const Exception& )
{
@@ -366,12 +365,10 @@ namespace
Reference<XPropertySet> xTableProp(_aTable,UNO_QUERY);
const ::rtl::OUString sSourceName = ::dbtools::composeTableName( m_xMetaData, xTableProp, ::dbtools::eInTableDefinitions, false, false, false );
TTableDataHelper::iterator aFind = m_aTableData.find(sSourceName);
- bool bNotFound = true, bAdded = false;
if ( aFind == m_aTableData.end() )
{
aFind = m_aTableData.insert(TTableDataHelper::value_type(sSourceName,::boost::shared_ptr<OTableWindowData>(new OTableWindowData(xTableProp,sSourceName, sSourceName)))).first;
aFind->second->ShowAll(sal_False);
- bAdded = true;
}
TTableWindowData::value_type pReferencingTable = aFind->second;
Reference<XIndexAccess> xKeys = pReferencingTable->getKeys();
@@ -393,7 +390,6 @@ namespace
xKey->getPropertyValue(PROPERTY_TYPE) >>= nKeyType;
if ( KeyType::FOREIGN == nKeyType )
{
- bNotFound = false;
::rtl::OUString sReferencedTable;
xKey->getPropertyValue(PROPERTY_REFERENCEDTABLE) >>= sReferencedTable;
//////////////////////////////////////////////////////////////////////
@@ -409,7 +405,7 @@ namespace
}
else
continue; // table name could not be found so we do not show this table releation
- } // if ( aFind == m_aTableData.end() )
+ }
TTableWindowData::value_type pReferencedTable = aRefFind->second;
::rtl::OUString sKeyName;
@@ -453,7 +449,7 @@ namespace
pTabConnData->SetCardinality();
}
}
- } // if ( xKeys.is() )
+ }
}
}
@@ -477,7 +473,7 @@ void ORelationController::mergeData(const TTableConnectionData& _aConnectionData
{
m_vTableData.push_back((*aConnDataIter)->getReferencedTable());
}
- } // for(;aConnDataIter != aConnDataEnd;++aConnDataIter)
+ }
if ( m_nThreadEvent )
{
--m_nThreadEvent;
@@ -488,7 +484,7 @@ void ORelationController::mergeData(const TTableConnectionData& _aConnectionData
// -----------------------------------------------------------------------------
IMPL_LINK( ORelationController, OnThreadFinished, void*, /*NOTINTERESTEDIN*/ )
{
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ ::SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
try
{
@@ -534,8 +530,8 @@ void ORelationController::loadData()
nStart = nEnd;
nEnd += nMaxElements;
nEnd = ::std::min(nEnd,nCount);
- } // for(;pIter != pEnd;++pIter)
- } // if ( aMeta.supportsThreads() )
+ }
+ }
else
{
RelationLoader* pThread = new RelationLoader(this,xMetaData,m_xTables,aNames,0,nCount);
@@ -613,3 +609,4 @@ bool ORelationController::allowQueries() const
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/RelationDesignView.cxx b/dbaccess/source/ui/relationdesign/RelationDesignView.cxx
index 64206933385e..e0dc240cc9ec 100644
--- a/dbaccess/source/ui/relationdesign/RelationDesignView.cxx
+++ b/dbaccess/source/ui/relationdesign/RelationDesignView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,66 +28,26 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_RELATIONDESIGNVIEW_HXX
#include "RelationDesignView.hxx"
-#endif
-#ifndef DBAUI_RELATION_TABLEVIEW_HXX
#include "RelationTableView.hxx"
-#endif
-#ifndef DBAUI_RELATIONCONTROLLER_HXX
#include "RelationController.hxx"
-#endif
-#ifndef _UNDO_HXX
#include <svl/undo.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _DBU_REL_HRC_
#include "dbu_rel.hrc"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_DATATYPE_HPP_
#include <com/sun/star/sdbc/DataType.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef DBAUI_RTABLECONNECTION_HXX
#include "RTableConnection.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINE_HXX
#include "ConnectionLine.hxx"
-#endif
-#ifndef DBAUI_CONNECTIONLINEDATA_HXX
#include "ConnectionLineData.hxx"
-#endif
-#ifndef DBAUI_RTABLECONNECTIONDATA_HXX
#include "RTableConnectionData.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace ::dbaui;
using namespace ::com::sun::star::uno;
@@ -151,3 +112,4 @@ void ORelationDesignView::GetFocus()
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/RelationTableView.cxx b/dbaccess/source/ui/relationdesign/RelationTableView.cxx
index 766a75cc6127..d78bc74cc6b2 100644
--- a/dbaccess/source/ui/relationdesign/RelationTableView.cxx
+++ b/dbaccess/source/ui/relationdesign/RelationTableView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-
#include "RelationTableView.hxx"
-
-
#include "JoinExchange.hxx"
-
-
#include <comphelper/extract.hxx>
-
-
#include "browserids.hxx"
-
-
#include <com/sun/star/sdbcx/XTablesSupplier.hpp>
-
-
#include <com/sun/star/sdbc/XConnection.hpp>
-
-
#include <com/sun/star/sdbcx/XKeysSupplier.hpp>
-
-
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-
-
#include <com/sun/star/sdbcx/KeyType.hpp>
-
#include <com/sun/star/container/XIndexAccess.hpp>
#include <com/sun/star/container/XNameAccess.hpp>
#include <com/sun/star/beans/XPropertySet.hpp>
@@ -179,7 +162,7 @@ void ORelationTableView::ReSync()
pTabConnDataList->erase( ::std::remove(pTabConnDataList->begin(),pTabConnDataList->end(),*aConIter),pTabConnDataList->end() );
continue;
}
- } // if ( !arrInvalidTables.empty() )
+ }
addConnection( new ORelationTableConnection(this, *aConIter), sal_False ); // don't add the data again
}
@@ -251,7 +234,7 @@ void ORelationTableView::AddConnection(const OJoinExchangeData& jxdSource, const
}
catch(const Exception&)
{
- OSL_ENSURE(0,"ORelationTableView::AddConnection: Exception oocured!");
+ OSL_FAIL("ORelationTableView::AddConnection: Exception oocured!");
}
}
}
@@ -318,7 +301,7 @@ bool ORelationTableView::RemoveConnection( OTableConnection* pConn ,sal_Bool /*_
}
catch(Exception&)
{
- OSL_ENSURE(0,"ORelationTableView::RemoveConnection: Something other than SQLException occured!");
+ OSL_FAIL("ORelationTableView::RemoveConnection: Something other than SQLException occurred!");
}
return false;
}
@@ -384,7 +367,6 @@ void ORelationTableView::RemoveTabWin( OTableWindow* pTabWin )
}
}
-// -----------------------------------------------------------------------------
void ORelationTableView::lookForUiActivities()
{
if(m_pExistingConnection)
@@ -453,7 +435,7 @@ void ORelationTableView::_elementRemoved( const container::ContainerEvent& _rEve
m_pView->getController().InvalidateFeature(ID_BROWSER_UNDO);
m_pView->getController().InvalidateFeature(ID_BROWSER_REDO);
}
- } // if ( _rEvent.Accessor >>= sName )
+ }
m_bInRemove = false;
}
// -----------------------------------------------------------------------------
@@ -461,3 +443,4 @@ void ORelationTableView::_elementReplaced( const container::ContainerEvent& /*_r
{
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/relationdesign/makefile.mk b/dbaccess/source/ui/relationdesign/makefile.mk
deleted file mode 100644
index cdaaa8722013..000000000000
--- a/dbaccess/source/ui/relationdesign/makefile.mk
+++ /dev/null
@@ -1,58 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=relationdesign
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES =\
- $(SLO)$/RTableConnection.obj \
- $(SLO)$/RTableConnectionData.obj \
- $(SLO)$/RelationTableView.obj \
- $(SLO)$/RelationDesignView.obj \
- $(SLO)$/RelationController.obj
-
-SRS1NAME=$(TARGET)
-SRC1FILES = relation.src
-
-# --- Targets -------------------------------------------------------
-
-.INCLUDE : target.mk
-
-$(SRS)$/$(TARGET).srs: $(SOLARINCDIR)$/svx$/globlmn.hrc
-
-
diff --git a/dbaccess/source/ui/relationdesign/relation.src b/dbaccess/source/ui/relationdesign/relation.src
index e3c555debd79..4420ade06100 100644
--- a/dbaccess/source/ui/relationdesign/relation.src
+++ b/dbaccess/source/ui/relationdesign/relation.src
@@ -44,22 +44,27 @@ String STR_QUERY_REL_EDIT_RELATION
{
Text [ en-US ] = "This relation already exists. Do you want to edit it or create a new one?" ;
};
+
String STR_QUERY_REL_EDIT
{
Text [ en-US ] = "Edit..." ;
};
+
String STR_QUERY_REL_CREATE
{
Text [ en-US ] = "Create..." ;
};
+
String STR_RELATIONDESIGN
{
Text [ en-US ] = " - %PRODUCTNAME Base: Relation design" ;
};
+
String STR_RELATIONDESIGN_NOT_AVAILABLE
{
Text [ en-US ] = "The database does not support relations." ;
};
+
QueryBox RELATION_DESIGN_SAVEMODIFIED
{
Buttons = WB_YES_NO_CANCEL ;
@@ -76,55 +81,3 @@ String STR_QUERY_REL_COULD_NOT_CREATE
{
Text [ en-US ] = "The database could not create the relation. May be foreign keys for this kind of table aren't supported.\nPlease check your documentation of the database.";
};
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx b/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx
index 9a016f1b8249..fd2e38f4d571 100644
--- a/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx
+++ b/dbaccess/source/ui/tabledesign/FieldDescGenWin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,27 +28,13 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEFIELDDESCGENPAGE_HXX
#include "FieldDescGenWin.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
+#include <osl/diagnose.h>
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef DBAUI_TABLEDESIGNHELPBAR_HXX
#include "TableDesignHelpBar.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDCONTROL_HXX
#include "TableFieldControl.hxx"
-#endif
-#ifndef DBAUI_TABLEDESIGNVIEW_HXX
#include "TableDesignView.hxx"
-#endif
-#ifndef DBAUI_TABLEEDITORCONTROL_HXX
#include "TEditControl.hxx"
-#endif
using namespace dbaui;
//==================================================================
@@ -75,7 +62,7 @@ OFieldDescGenWin::~OFieldDescGenWin()
//------------------------------------------------------------------------------
void OFieldDescGenWin::Init()
{
- DBG_ASSERT(GetEditorCtrl() != NULL, "OFieldDescGenWin::Init : have no editor control !");
+ OSL_ENSURE(GetEditorCtrl() != NULL, "OFieldDescGenWin::Init : have no editor control !");
m_pFieldControl->Init();
}
@@ -123,11 +110,6 @@ OTableEditorCtrl* OFieldDescGenWin::GetEditorCtrl()
}
#endif
//------------------------------------------------------------------------------
-//short OFieldDescGenWin::GetFormatCategory(OFieldDescription* pFieldDescr)
-//{
-// return m_pFieldControl->GetFormatCategory(pFieldDescr);
-//}
-//------------------------------------------------------------------------------
void OFieldDescGenWin::SaveData( OFieldDescription* pFieldDescr )
{
DBG_CHKTHIS(OFieldDescGenWin,NULL);
@@ -197,7 +179,4 @@ void OFieldDescGenWin::paste()
}
// -----------------------------------------------------------------------------
-
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/FieldDescGenWin.hxx b/dbaccess/source/ui/tabledesign/FieldDescGenWin.hxx
index 73a3ca0f3122..d95ddefbebf6 100644
--- a/dbaccess/source/ui/tabledesign/FieldDescGenWin.hxx
+++ b/dbaccess/source/ui/tabledesign/FieldDescGenWin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_TABLEFIELDDESCGENPAGE_HXX
#define DBAUI_TABLEFIELDDESCGENPAGE_HXX
-#ifndef _SV_TABPAGE_HXX
#include <vcl/tabpage.hxx>
-#endif
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
namespace dbaui
{
@@ -86,3 +83,4 @@ namespace dbaui
}
#endif // DBAUI_TABLEFIELDDESCGENPAGE_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx b/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx
index b37bacc9536a..93ff76bcbcb3 100644
--- a/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx
+++ b/dbaccess/source/ui/tabledesign/FieldDescriptions.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,38 +28,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _DBU_TBL_HRC_
#include "dbu_tbl.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_COLUMNVALUE_HPP_
#include <com/sun/star/sdbc/ColumnValue.hpp>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UTIL_NUMBERFORMAT_HPP_
#include <com/sun/star/util/NumberFormat.hpp>
-#endif
-#define DEFAULT_VARCHAR_PRECSION 50
+#define DEFAULT_VARCHAR_PRECSION 100
#define DEFAULT_OTHER_PRECSION 16
#define DEFAULT_NUMERIC_PRECSION 5
#define DEFAULT_NUMERIC_SCALE 0
@@ -580,7 +561,7 @@ sal_Int32 OFieldDescription::GetPrecision() const
if ( !nPrec )
nPrec = pTypeInfo->nPrecision;
break;
- } // switch ( pTypeInfo->nType )
+ }
}
return nPrec;
@@ -698,3 +679,5 @@ void OFieldDescription::copyColumnSettingsTo(const Reference< XPropertySet >& _r
}
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TEditControl.cxx b/dbaccess/source/ui/tabledesign/TEditControl.cxx
index bb24298b98a1..ed295372e990 100644
--- a/dbaccess/source/ui/tabledesign/TEditControl.cxx
+++ b/dbaccess/source/ui/tabledesign/TEditControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,84 +28,32 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEEDITORCONTROL_HXX
#include "TEditControl.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XALTERTABLE_HPP_
#include <com/sun/star/sdbcx/XAlterTable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XDROP_HPP_
#include <com/sun/star/sdbcx/XDrop.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XAPPEND_HPP_
#include <com/sun/star/sdbcx/XAppend.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XNUMBERFORMATTYPES_HPP_
#include <com/sun/star/util/XNumberFormatTypes.hpp>
-#endif
-#ifndef _DBU_TBL_HRC_
#include "dbu_tbl.hrc"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONCONTROL_HXX
#include "FieldDescControl.hxx"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
-#ifndef DBAUI_TABLEUNDO_HXX
#include "TableUndo.hxx"
-#endif
-#ifndef DBUI_TABLECONTROLLER_HXX
#include "TableController.hxx"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef DBAUI_SQLNAMEEDIT_HXX
#include "SqlNameEdit.hxx"
-#endif
-#ifndef DBAUI_TABLEROW_EXCHANGE_HXX
#include "TableRowExchange.hxx"
-#endif
-#ifndef _SOT_STORAGE_HXX
#include <sot/storage.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONCONTROL_HXX
#include "FieldDescControl.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDCONTROL_HXX
#include "TableFieldControl.hxx"
-#endif
#include "dsntypes.hxx"
#include "dbaccess_slotid.hrc"
@@ -294,11 +243,6 @@ void OTableEditorCtrl::SetReadOnly( sal_Bool bRead )
DeactivateCell();
//////////////////////////////////////////////////////////////////////
- // ::com::sun::star::beans::Property Controls disablen
-// if (pDescrWin)
-// pDescrWin->SetReadOnly(bReadOnly || !SetDataPtr(nRow) || GetActRow()->IsReadOnly());
-
- //////////////////////////////////////////////////////////////////////
// Cursor des Browsers anpassen
BrowserMode nMode(BROWSER_COLUMNSELECTION | BROWSER_MULTISELECTION | BROWSER_KEEPSELECTION |
BROWSER_HLINESFULL | BROWSER_VLINESFULL|BROWSER_AUTOSIZE_LASTCOL);
@@ -333,7 +277,7 @@ void OTableEditorCtrl::InitCellController()
}
catch(SQLException&)
{
- OSL_ASSERT(!"getMaxColumnNameLength");
+ OSL_FAIL("getMaxColumnNameLength");
}
pNameCell = new OSQLNameEdit( &GetDataWindow(), sExtraNameChars,WB_LEFT );
@@ -361,12 +305,12 @@ void OTableEditorCtrl::InitCellController()
Size aHeight;
const Control* pControls[] = { pTypeCell,pDescrCell,pNameCell,pHelpTextCell};
- for(sal_Size i= 0; i < sizeof(pControls)/sizeof(pControls[0]);++i)
+ for(sal_Size i= 0; i < SAL_N_ELEMENTS(pControls);++i)
{
const Size aTemp( pControls[i]->GetOptimalSize(WINDOWSIZE_PREFERRED) );
if ( aTemp.Height() > aHeight.Height() )
aHeight.Height() = aTemp.Height();
- } // for(int i= 0; i < sizeof(pControls)/sizeof(pControls[0]);++i
+ }
SetDataRowHeight(aHeight.Height());
ClearModified();
@@ -462,7 +406,7 @@ CellController* OTableEditorCtrl::GetController(long nRow, sal_uInt16 nColumnId)
Reference<XPropertySet> xTable = GetView()->getController().getTable();
if (IsReadOnly() || ( xTable.is() &&
xTable->getPropertySetInfo()->hasPropertyByName(PROPERTY_TYPE) &&
- ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString::createFromAscii("VIEW")))
+ ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VIEW"))))
return NULL;
//////////////////////////////////////////////////////////////////////
@@ -758,15 +702,6 @@ sal_Bool OTableEditorCtrl::SaveModified()
switch( nColId )
{
//////////////////////////////////////////////////////////////
- // NameCell
- case FIELD_NAME:
- {
- // removed the former duplicate-check. this is done in OTableDocShell::CheckDefConsistency now.
- // FS - 07.12.99 - 69575
-
- } break;
-
- //////////////////////////////////////////////////////////////
// TypeCell
case FIELD_TYPE:
{
@@ -1183,7 +1118,7 @@ void OTableEditorCtrl::SetCellData( long nRow, sal_uInt16 nColId, const TOTypeIn
SwitchType( _pTypeInfo );
break;
default:
- OSL_ENSURE(sal_False, "OTableEditorCtrl::SetCellData: invalid column!");
+ OSL_FAIL("OTableEditorCtrl::SetCellData: invalid column!");
}
SetControlText(nRow,nColId,_pTypeInfo.get() ? _pTypeInfo->aUIName : ::rtl::OUString());
}
@@ -1210,7 +1145,7 @@ void OTableEditorCtrl::SetCellData( long nRow, sal_uInt16 nColId, const ::com::s
break;
case FIELD_TYPE:
- OSL_ENSURE(sal_False, "OTableEditorCtrl::SetCellData: invalid column!");
+ OSL_FAIL("OTableEditorCtrl::SetCellData: invalid column!");
break;
case COLUMN_DESCRIPTION:
@@ -1238,8 +1173,7 @@ void OTableEditorCtrl::SetCellData( long nRow, sal_uInt16 nColId, const ::com::s
break;
case FIELD_PROPERTY_NUMTYPE:
- // pFieldDescr->SetNumType( _rNewData );
- OSL_ENSURE(sal_False, "OTableEditorCtrl::SetCellData: invalid column!");
+ OSL_FAIL("OTableEditorCtrl::SetCellData: invalid column!");
break;
case FIELD_PROPERTY_AUTOINC:
@@ -1322,8 +1256,8 @@ Any OTableEditorCtrl::GetCellData( long nRow, sal_uInt16 nColId )
break;
case FIELD_PROPERTY_NUMTYPE:
- OSL_ENSURE(sal_False, "OTableEditorCtrl::GetCellData: invalid column!");
- // return pFieldDescr->GetNumType();
+ OSL_FAIL("OTableEditorCtrl::GetCellData: invalid column!");
+ break;
case FIELD_PROPERTY_AUTOINC:
sValue = pFieldDescr->IsAutoIncrement() ? strYes : strNo;
@@ -1369,7 +1303,7 @@ OFieldDescription* OTableEditorCtrl::GetFieldDescr( long nRow )
m_pRowList->size());
if( (nRow<0) || (sal::static_int_cast< unsigned long >(nRow)>=nListCount) )
{
- OSL_ENSURE(0,"(nRow<0) || (nRow>=nListCount)");
+ OSL_FAIL("(nRow<0) || (nRow>=nListCount)");
return NULL;
}
::boost::shared_ptr<OTableRow> pRow = (*m_pRowList)[ nRow ];
@@ -1407,11 +1341,6 @@ sal_Bool OTableEditorCtrl::IsCutAllowed( long nRow )
}
}
-// Reference<XPropertySet> xTable = GetView()->getController().getTable();
-// if( !IsCopyAllowed(nRow) || (xTable.is() && ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString::createFromAscii("VIEW")))
-// return sal_False;
-
- // return bCutAllowed && IsDeleteAllowed( nRow );
return bIsCutAllowed;
}
@@ -1429,7 +1358,7 @@ sal_Bool OTableEditorCtrl::IsCopyAllowed( long /*nRow*/ )
else if(m_eChildFocus == ROW)
{
Reference<XPropertySet> xTable = GetView()->getController().getTable();
- if( !GetSelectRowCount() || (xTable.is() && ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString::createFromAscii("VIEW")))
+ if( !GetSelectRowCount() || (xTable.is() && ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VIEW"))))
return sal_False;
//////////////////////////////////////////////////////////////////////
@@ -1596,9 +1525,9 @@ sal_Bool OTableEditorCtrl::IsPrimaryKeyAllowed( long /*nRow*/ )
Reference<XPropertySet> xTable = rController.getTable();
//////////////////////////////////////////////////////////////
// Key darf nicht veraendert werden
- // Dies gilt jedoch nur, wenn die Tabelle nicht neu ist und keine ::com::sun::star::sdbcx::View. Ansonsten wird kein DROP ausgeführt
+ // Dies gilt jedoch nur, wenn die Tabelle nicht neu ist und keine ::com::sun::star::sdbcx::View. Ansonsten wird kein DROP ausgef�hrt
- if(xTable.is() && ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString::createFromAscii("VIEW"))
+ if(xTable.is() && ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VIEW")))
return sal_False;
//////////////////////////////////////////////////////////////
// Wenn leeres Feld, kein PrimKey
@@ -1618,7 +1547,7 @@ sal_Bool OTableEditorCtrl::IsPrimaryKeyAllowed( long /*nRow*/ )
{
//////////////////////////////////////////////////////////////
// Wenn Feldtyp Memo oder Image, kein PrimKey
- // oder wenn Spalten nicht gedroped werden können und das Required Flag ist nicht gesetzt
+ // oder wenn Spalten nicht gedroped werden k�nnen und das Required Flag ist nicht gesetzt
// oder wenn eine ::com::sun::star::sdbcx::View vorhanden ist und das Required Flag nicht gesetzt ist
TOTypeInfoSP pTypeInfo = pFieldDescr->getTypeInfo();
if( pTypeInfo->nSearchType == ColumnSearch::NONE
@@ -1826,7 +1755,7 @@ void OTableEditorCtrl::AdjustFieldDescription(OFieldDescription* _pFieldDesc,
{
_pFieldDesc->SetIsNullable(ColumnValue::NO_NULLS);
_pFieldDesc->SetControlDefault(Any());
- } // if(!_bSet && _pFieldDesc->getTypeInfo()->bNullable)
+ }
if ( _pFieldDesc->IsAutoIncrement() && !_bPrimaryKey )
{
OTableController& rController = GetView()->getController();
@@ -1850,7 +1779,6 @@ void OTableEditorCtrl::SetPrimaryKey( sal_Bool bSet )
// Evtl. vorhandene Primary Keys loeschen
MultiSelection aDeletedPrimKeys;
aDeletedPrimKeys.SetTotalRange( Range(0,GetRowCount()) );
- long nIndex = 0;
::std::vector< ::boost::shared_ptr<OTableRow> >::const_iterator aIter = m_pRowList->begin();
::std::vector< ::boost::shared_ptr<OTableRow> >::const_iterator aEnd = m_pRowList->end();
@@ -1869,7 +1797,7 @@ void OTableEditorCtrl::SetPrimaryKey( sal_Bool bSet )
aInsertedPrimKeys.SetTotalRange( Range(0,GetRowCount()) );
if( bSet )
{
- nIndex = FirstSelectedRow();
+ long nIndex = FirstSelectedRow();
while( nIndex >= 0 && nIndex < static_cast<long>(m_pRowList->size()) )
{
//////////////////////////////////////////////////////////////////////
@@ -2009,3 +1937,4 @@ long OTableEditorCtrl::PreNotify( NotifyEvent& rNEvt )
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TEditControl.hxx b/dbaccess/source/ui/tabledesign/TEditControl.hxx
index 90e7558d8aca..3128d979b681 100644
--- a/dbaccess/source/ui/tabledesign/TEditControl.hxx
+++ b/dbaccess/source/ui/tabledesign/TEditControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
#ifndef DBAUI_TABLEEDITORCONTROL_HXX
#define DBAUI_TABLEEDITORCONTROL_HXX
-#ifndef DBAUI_TABLEDESIGNCONTROL_HXX
#include "TableDesignControl.hxx"
-#endif
-#ifndef DBAUI_TABLEDESIGNVIEW_HXX
#include "TableDesignView.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDDESCRIPTION_HXX
#include "TableFieldDescWin.hxx"
-#endif
-#ifndef DBAUI_TABLEROW_HXX
#include "TableRow.hxx"
-#endif
-#ifndef DBAUI_ENUMTYPES_HXX
#include "QEnumTypes.hxx"
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
class Edit;
class SfxUndoManager;
@@ -230,3 +219,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableController.cxx b/dbaccess/source/ui/tabledesign/TableController.cxx
index ba0e94b31dc7..2f90611cf2ba 100644
--- a/dbaccess/source/ui/tabledesign/TableController.cxx
+++ b/dbaccess/source/ui/tabledesign/TableController.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -144,13 +145,13 @@ namespace
//------------------------------------------------------------------------------
::rtl::OUString OTableController::getImplementationName_Static() throw( RuntimeException )
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.OTableDesign");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.OTableDesign"));
}
//------------------------------------------------------------------------------
Sequence< ::rtl::OUString> OTableController::getSupportedServiceNames_Static(void) throw( RuntimeException )
{
Sequence< ::rtl::OUString> aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.TableDesign");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.TableDesign"));
return aSupported;
}
//-------------------------------------------------------------------------
@@ -348,7 +349,6 @@ sal_Bool OTableController::doSaveDoc(sal_Bool _bSaveAs)
{
String aName = String(ModuleRes(STR_TBL_TITLE));
aDefaultName = aName.GetToken(0,' ');
- //aDefaultName = getPrivateTitle();
aDefaultName = ::dbtools::createUniqueName(xTables,aDefaultName);
}
@@ -368,7 +368,7 @@ sal_Bool OTableController::doSaveDoc(sal_Bool _bSaveAs)
}
catch(Exception&)
{
- OSL_ENSURE(sal_False, "OTableController::doSaveDoc: nothing is expected to happen here!");
+ OSL_FAIL("OTableController::doSaveDoc: nothing is expected to happen here!");
}
sal_Bool bAlter = sal_False;
@@ -379,7 +379,6 @@ sal_Bool OTableController::doSaveDoc(sal_Bool _bSaveAs)
// check the columns for double names
if(!checkColumns(bNew || !xTables->hasByName(m_sName)))
{
- // #105323# OJ
return sal_False;
}
@@ -474,7 +473,6 @@ sal_Bool OTableController::doSaveDoc(sal_Bool _bSaveAs)
stopTableListening();
m_xTable = NULL;
}
- // reload(); // a error occured so we have to reload
}
return ! (aInfo.isValid() || bError);
}
@@ -507,7 +505,7 @@ void OTableController::doEditIndexes()
OSL_ENSURE(xIndexes.is(), "OTableController::doEditIndexes: no keys got from the indexes supplier!");
}
else
- OSL_ENSURE(sal_False, "OTableController::doEditIndexes: should never have reached this (no indexes supplier)!");
+ OSL_FAIL("OTableController::doEditIndexes: should never have reached this (no indexes supplier)!");
// get the field names
Reference< XColumnsSupplier > xColSupp(m_xTable, UNO_QUERY);
@@ -581,8 +579,6 @@ sal_Bool OTableController::Construct(Window* pParent)
{
setView( * new OTableDesignView( pParent, getORB(), *this ) );
OTableController_BASE::Construct(pParent);
-// m_pView->Construct();
-// m_pView->Show();
return sal_True;
}
// -----------------------------------------------------------------------------
@@ -591,7 +587,7 @@ sal_Bool SAL_CALL OTableController::suspend(sal_Bool /*_bSuspend*/) throw( Runti
if ( getBroadcastHelper().bInDispose || getBroadcastHelper().bDisposed )
return sal_True;
- vos::OGuard aSolarGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aSolarGuard;
::osl::MutexGuard aGuard( getMutex() );
if ( getView() && getView()->IsInModalMode() )
return sal_False;
@@ -633,7 +629,7 @@ sal_Bool SAL_CALL OTableController::suspend(sal_Bool /*_bSuspend*/) throw( Runti
}
catch(const Exception&)
{
- OSL_ENSURE(sal_False, "OTableController::suspend: nothing is expected to happen here!");
+ OSL_FAIL("OTableController::suspend: nothing is expected to happen here!");
}
}
@@ -645,10 +641,7 @@ sal_Bool SAL_CALL OTableController::suspend(sal_Bool /*_bSuspend*/) throw( Runti
}
}
}
-/*
- if ( bCheck )
- OSingleDocumentController::suspend(_bSuspend);
-*/
+
return bCheck;
}
// -----------------------------------------------------------------------------
@@ -770,7 +763,7 @@ void OTableController::appendColumns(Reference<XColumnsSupplier>& _rxColSup,sal_
}
else
{
- OSL_ENSURE(sal_False, "OTableController::appendColumns: invalid field name!");
+ OSL_FAIL("OTableController::appendColumns: invalid field name!");
}
}
@@ -906,7 +899,6 @@ void OTableController::loadData()
{
pActFieldDescr->SetName(sName);
pActFieldDescr->SetFormatKey(nFormatKey);
- // pActFieldDescr->SetPrimaryKey(pPrimary->GetValue());
pActFieldDescr->SetDescription(sDescription);
pActFieldDescr->SetHelpText(sHelpText);
pActFieldDescr->SetAutoIncrement(bIsAutoIncrement);
@@ -1018,10 +1010,10 @@ sal_Bool OTableController::checkColumns(sal_Bool _bNew) throw(::com::sun::star::
pNewRow->SetFieldType( pTypeInfo );
OFieldDescription* pActFieldDescr = pNewRow->GetActFieldDescr();
- pActFieldDescr->SetAutoIncrement(sal_False); // #95927# pTypeInfo->bAutoIncrement
+ pActFieldDescr->SetAutoIncrement(sal_False);
pActFieldDescr->SetIsNullable(ColumnValue::NO_NULLS);
- pActFieldDescr->SetName( createUniqueName(::rtl::OUString::createFromAscii("ID") ));
+ pActFieldDescr->SetName( createUniqueName(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ID")) ));
pActFieldDescr->SetPrimaryKey( sal_True );
m_vRowList.insert(m_vRowList.begin(),pNewRow);
@@ -1097,14 +1089,13 @@ void OTableController::alterColumns()
try { xColumn->getPropertyValue(PROPERTY_TYPENAME) >>= sTypeName; }
catch( const Exception& )
{
- OSL_ENSURE( sal_False, "no TypeName property?!" );
+ OSL_FAIL( "no TypeName property?!" );
// since this is a last minute fix for #i41785#, I want to be on the safe side,
// and catch errors here as early as possible (instead of the whole process of altering
// the columns failing)
// Normally, sdbcx::Column objects are expected to have a TypeName property
}
- // xColumn->getPropertyValue(PROPERTY_ISCURRENCY,::cppu::bool2any(pField->IsCurrency()));
// check if something changed
if((nType != pField->GetType() ||
sTypeName != pField->GetTypeName() ||
@@ -1150,7 +1141,7 @@ void OTableController::alterColumns()
xAppend->appendByDescriptor(xNewColumn);
}
catch(const SQLException&)
- { // an error occured so we try to reactivate the old one
+ { // an error occurred so we try to reactivate the old one
xAppend->appendByDescriptor(xColumn);
throw;
}
@@ -1181,7 +1172,7 @@ void OTableController::alterColumns()
}
else
{
- OSL_ENSURE(sal_False, "OTableController::alterColumns: invalid column (2)!");
+ OSL_FAIL("OTableController::alterColumns: invalid column (2)!");
}
}
catch(const SQLException&)
@@ -1208,7 +1199,7 @@ void OTableController::alterColumns()
}
else
bReload = sal_True;
- } // for(sal_Int32 nPos = 0;aIter != aEnd;++aIter,++nPos)
+ }
// alter column settings
aIter = m_vRowList.begin();
@@ -1239,7 +1230,7 @@ void OTableController::alterColumns()
xColumn->setPropertyValue(PROPERTY_FORMATKEY,makeAny(pField->GetFormatKey()));
if(xInfo->hasPropertyByName(PROPERTY_ALIGN))
xColumn->setPropertyValue(PROPERTY_ALIGN,makeAny(dbaui::mapTextAllign(pField->GetHorJustify())));
- } // if ( xColumns->hasByName(pField->GetName()) )
+ }
}
// second drop all columns which could be found by name
Reference<XNameAccess> xKeyColumns = getKeyColumns();
@@ -1281,7 +1272,7 @@ void OTableController::alterColumns()
SQLException aNewException;
aNewException.Message = sError;
- aNewException.SQLState = ::rtl::OUString::createFromAscii( "S1000" );
+ aNewException.SQLState = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("S1000"));
aNewException.NextException = ::cppu::getCaughtException();
throw aNewException;
@@ -1317,7 +1308,7 @@ void OTableController::alterColumns()
}
else
{
- OSL_ENSURE(sal_False, "OTableController::alterColumns: invalid column!");
+ OSL_FAIL("OTableController::alterColumns: invalid column!");
}
}
}
@@ -1452,7 +1443,6 @@ void OTableController::assignTable()
}
}
}
- //updateTitle();
}
// -----------------------------------------------------------------------------
sal_Bool OTableController::isAddAllowed() const
@@ -1606,3 +1596,5 @@ bool OTableController::isAutoIncrementPrimaryKey() const
return getSdbMetaData().isAutoIncrementPrimaryKey();
}
// -----------------------------------------------------------------------------
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableDesignControl.cxx b/dbaccess/source/ui/tabledesign/TableDesignControl.cxx
index 387d87d3fab6..e83ebe3cbace 100644
--- a/dbaccess/source/ui/tabledesign/TableDesignControl.cxx
+++ b/dbaccess/source/ui/tabledesign/TableDesignControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,30 +29,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEDESIGNCONTROL_HXX
#include "TableDesignControl.hxx"
-#endif
-#ifndef _DBU_TBL_HRC_
#include "dbu_tbl.hrc"
-#endif
-#ifndef DBAUI_TABLEDESIGNVIEW_HXX
#include "TableDesignView.hxx"
-#endif
-#ifndef DBUI_TABLECONTROLLER_HXX
#include "TableController.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef _COM_SUN_STAR_UTIL_URL_HPP_
#include <com/sun/star/util/URL.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYVALUE_HPP_
#include <com/sun/star/beans/PropertyValue.hpp>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
using namespace ::dbaui;
using namespace ::svt;
@@ -90,9 +75,6 @@ void OTableRowView::Init()
{
EditBrowseBox::Init();
-// SetMapMode( MapMode(MAP_TWIP) );
-// GetDataWindow().SetMapMode( GetMapMode() );
-
Font aFont( GetDataWindow().GetFont() );
aFont.SetWeight( WEIGHT_NORMAL );
GetDataWindow().SetFont( aFont );
@@ -128,7 +110,7 @@ void OTableRowView::KeyInput( const KeyEvent& rEvt )
if( rEvt.GetKeyCode().GetCode() == KEY_F2 )
{
::com::sun::star::util::URL aUrl;
- aUrl.Complete =::rtl::OUString::createFromAscii(".uno:DSBEditDoc");
+ aUrl.Complete =::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(".uno:DSBEditDoc"));
GetView()->getController().dispatch( aUrl,Sequence< PropertyValue >() );
}
}
@@ -219,7 +201,7 @@ void OTableRowView::copy()
//------------------------------------------------------------------------------
void OTableRowView::paste()
{
- OSL_ENSURE(0,"OTableRowView::Paste : (pseudo-) abstract method called !");
+ OSL_FAIL("OTableRowView::Paste : (pseudo-) abstract method called !");
}
//------------------------------------------------------------------------------
@@ -239,3 +221,4 @@ EditBrowseBox::RowStatus OTableRowView::GetRowStatus(long nRow) const
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx b/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
index 1cd16ca3ef82..4df1b65432c7 100644
--- a/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
+++ b/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEDESIGNHELPBAR_HXX
#include "TableDesignHelpBar.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef _SVEDIT_HXX
#include <svtools/svmedit.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
#include <memory>
using namespace dbaui;
#define STANDARD_MARGIN 6
@@ -128,3 +121,5 @@ void OTableDesignHelpBar::copy()
void OTableDesignHelpBar::paste()
{
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableDesignView.cxx b/dbaccess/source/ui/tabledesign/TableDesignView.cxx
index 722d41c51fc0..74dced06eb96 100644
--- a/dbaccess/source/ui/tabledesign/TableDesignView.cxx
+++ b/dbaccess/source/ui/tabledesign/TableDesignView.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,45 +28,19 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEDESIGNVIEW_HXX
#include "TableDesignView.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBUI_TABLECONTROLLER_HXX
#include "TableController.hxx"
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
-#ifndef DBAUI_TABLEEDITORCONTROL_HXX
#include "TEditControl.hxx"
-#endif
-#ifndef DBAUI_TABLEFIELDDESCRIPTION_HXX
#include "TableFieldDescWin.hxx"
-#endif
-#ifndef DBAUI_TABLEROW_HXX
#include "TableRow.hxx"
-#endif
-#ifndef _UTL_CONFIGMGR_HXX_
#include <unotools/configmgr.hxx>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef _COM_SUN_STAR_DATATRANSFER_CLIPBOARD_XCLIPBOARD_HPP_
#include <com/sun/star/datatransfer/clipboard/XClipboard.hpp>
-#endif
-#ifndef INCLUDED_SVTOOLS_SYSLOCALE_HXX
#include <unotools/syslocale.hxx>
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
using namespace ::dbaui;
@@ -173,7 +148,6 @@ void OTableBorderWindow::ImplInitSettings( sal_Bool bFont, sal_Bool bForeground,
if ( IsControlFont() )
aFont.Merge( GetControlFont() );
SetPointFont( aFont );
-// Set/*Zoomed*/PointFont( aFont );
}
if ( bFont || bForeground )
@@ -398,3 +372,4 @@ void OTableDesignView::GetFocus()
}
// -----------------------------------------------------------------------------
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableFieldControl.cxx b/dbaccess/source/ui/tabledesign/TableFieldControl.cxx
index b3cfe55d8455..83951491b232 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldControl.cxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,36 +28,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEFIELDCONTROL_HXX
#include "TableFieldControl.hxx"
-#endif
-#ifndef DBUI_TABLECONTROLLER_HXX
#include "TableController.hxx"
-#endif
-#ifndef DBAUI_TABLEDESIGNVIEW_HXX
#include "TableDesignView.hxx"
-#endif
-#ifndef DBAUI_TABLEEDITORCONTROL_HXX
#include "TEditControl.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATABASEMETADATA_HPP_
#include <com/sun/star/sdbc/XDatabaseMetaData.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _COMPHELPER_TYPES_HXX_
#include <comphelper/types.hxx>
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
@@ -85,9 +66,9 @@ sal_Bool OTableFieldControl::IsReadOnly()
sal_Bool bRead(GetCtrl()->IsReadOnly());
if( !bRead )
{
- // Die Spalten einer ::com::sun::star::sdbcx::View können nicht verändert werden
+ // Die Spalten einer ::com::sun::star::sdbcx::View k�nnen nicht ver�ndert werden
Reference<XPropertySet> xTable = GetCtrl()->GetView()->getController().getTable();
- if(xTable.is() && ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString::createFromAscii("VIEW"))
+ if(xTable.is() && ::comphelper::getString(xTable->getPropertyValue(PROPERTY_TYPE)) == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VIEW")))
bRead = sal_True;
else
{
@@ -172,6 +153,4 @@ sal_Bool OTableFieldControl::isAutoIncrementValueEnabled() const
}
// -----------------------------------------------------------------------------
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableFieldControl.hxx b/dbaccess/source/ui/tabledesign/TableFieldControl.hxx
index 0ba24704b11c..22a77811b51c 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldControl.hxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,9 +28,7 @@
#ifndef DBAUI_TABLEFIELDCONTROL_HXX
#define DBAUI_TABLEFIELDCONTROL_HXX
-#ifndef DBAUI_FIELDDESCRIPTIONCONTROL_HXX
#include "FieldDescControl.hxx"
-#endif
namespace dbaui
{
@@ -70,3 +69,4 @@ namespace dbaui
#endif // DBAUI_TABLEFIELDCONTROL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
index 5699a1d818e2..4add6de25fe7 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,33 +29,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEFIELDDESCRIPTION_HXX
#include "TableFieldDescWin.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
+#include <osl/diagnose.h>
#include "FieldDescriptions.hxx"
-#endif
-#ifndef _DBU_TBL_HRC_
#include "dbu_tbl.hrc"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
-#ifndef DBAUI_TABLEDESIGNHELPBAR_HXX
#include "TableDesignHelpBar.hxx"
-#endif
-#ifndef _SV_FIXED_HXX
#include <vcl/fixed.hxx>
-#endif
-#ifndef _DBA_DBACCESS_HELPID_HRC_
#include "dbaccess_helpid.hrc"
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
#include <memory>
#define STANDARD_MARGIN 6
@@ -128,7 +111,7 @@ OTableFieldDescWin::~OTableFieldDescWin()
//------------------------------------------------------------------------------
void OTableFieldDescWin::Init()
{
- DBG_ASSERT(getGenPage() != NULL, "OTableFieldDescWin::Init : ups ... no GenericPage ... this will crash ...");
+ OSL_ENSURE(getGenPage() != NULL, "OTableFieldDescWin::Init : ups ... no GenericPage ... this will crash ...");
getGenPage()->Init();
}
@@ -334,4 +317,4 @@ long OTableFieldDescWin::PreNotify( NotifyEvent& rNEvt )
return bHandled ? 1L : TabPage::PreNotify(rNEvt);
}
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx b/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx
index 038d42ce93ce..5bfb03283cfc 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldDescWin.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
#ifndef DBAUI_TABLEFIELDDESCRIPTION_HXX
#define DBAUI_TABLEFIELDDESCRIPTION_HXX
-#ifndef _SV_TABPAGE_HXX
#include <vcl/tabpage.hxx>
-#endif
-#ifndef DBAUI_TABLEFIELDDESCGENPAGE_HXX
#include "FieldDescGenWin.hxx"
-#endif
-#ifndef DBACCESS_TABLEDESIGN_ICLIPBOARDTEST_HXX
#include "IClipBoardTest.hxx"
-#endif
class FixedText;
namespace dbaui
@@ -45,7 +40,7 @@ namespace dbaui
class OFieldDescription;
//==================================================================
// Ableitung von TabPage ist ein Trick von TH,
- // um Aenderungen der Systemfarben zu bemerken (Bug #53905)
+ // um Aenderungen der Systemfarben zu bemerken
class OTableFieldDescWin : public TabPage
,public IClipboardTest
{
@@ -113,3 +108,4 @@ namespace dbaui
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableRow.cxx b/dbaccess/source/ui/tabledesign/TableRow.cxx
index f98916dfa9b7..fb43d295ef25 100644
--- a/dbaccess/source/ui/tabledesign/TableRow.cxx
+++ b/dbaccess/source/ui/tabledesign/TableRow.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,15 +28,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEROW_HXX
#include "TableRow.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
#include <algorithm>
#include <comphelper/types.hxx>
@@ -161,7 +156,7 @@ namespace dbaui
_rStr << sal_Int32(pFieldDesc->IsAutoIncrement() ? 1 : 0);
_rStr << sal_Int32(pFieldDesc->IsPrimaryKey() ? 1 : 0);
_rStr << sal_Int32(pFieldDesc->IsCurrency() ? 1 : 0);
- } // if(pFieldDesc)
+ }
else
_rStr << (sal_Int32)0;
return _rStr;
@@ -231,5 +226,4 @@ namespace dbaui
// -----------------------------------------------------------------------------
}
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableRowExchange.cxx b/dbaccess/source/ui/tabledesign/TableRowExchange.cxx
index 2779dd5fda7d..cb7d983b9f88 100644
--- a/dbaccess/source/ui/tabledesign/TableRowExchange.cxx
+++ b/dbaccess/source/ui/tabledesign/TableRowExchange.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEROW_EXCHANGE_HXX
#include "TableRowExchange.hxx"
-#endif
-#ifndef _SOT_FORMATS_HXX
#include <sot/formats.hxx>
-#endif
-#ifndef _SOT_STORAGE_HXX
#include <sot/storage.hxx>
-#endif
-#ifndef DBAUI_TABLEROW_HXX
#include "TableRow.hxx"
-#endif
namespace dbaui
{
@@ -88,10 +81,4 @@ namespace dbaui
// -----------------------------------------------------------------------------
}
-
-
-
-
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableUndo.cxx b/dbaccess/source/ui/tabledesign/TableUndo.cxx
index 73bc8cf0c1a3..0a6a299058b8 100644
--- a/dbaccess/source/ui/tabledesign/TableUndo.cxx
+++ b/dbaccess/source/ui/tabledesign/TableUndo.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,33 +28,15 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_TABLEUNDO_HXX
#include "TableUndo.hxx"
-#endif
-#ifndef _DBU_TBL_HRC_
#include "dbu_tbl.hrc"
-#endif
-#ifndef DBAUI_TABLEEDITORCONTROL_HXX
#include "TEditControl.hxx"
-#endif
-#ifndef DBAUI_TABLEROW_HXX
#include "TableRow.hxx"
-#endif
-#ifndef DBACCESS_UI_BROWSER_ID_HXX
#include "browserids.hxx"
-#endif
-#ifndef DBUI_TABLECONTROLLER_HXX
#include "TableController.hxx"
-#endif
-#ifndef DBAUI_TABLEDESIGNVIEW_HXX
#include "TableDesignView.hxx"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
#include <tools/debug.hxx>
-#endif
using namespace dbaui;
using namespace ::svt;
@@ -490,6 +473,4 @@ void OPrimKeyUndoAct::Redo()
OTableEditorUndoAct::Redo();
}
-
-
-
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/TableUndo.hxx b/dbaccess/source/ui/tabledesign/TableUndo.hxx
index 742e377077aa..23ecf12b8e61 100644
--- a/dbaccess/source/ui/tabledesign/TableUndo.hxx
+++ b/dbaccess/source/ui/tabledesign/TableUndo.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,13 @@
#ifndef DBAUI_TABLEUNDO_HXX
#define DBAUI_TABLEUNDO_HXX
-#ifndef DBAUI_GENERALUNDO_HXX
#include "GeneralUndo.hxx"
-#endif
-#ifndef _SV_MULTISEL_HXX
#include <tools/multisel.hxx>
-#endif
#include <vector>
-#ifndef _COM_SUN_STAR_UNO_ANY_H_
#include <com/sun/star/uno/Any.h>
-#endif
-#ifndef DBAUI_TYPEINFO_HXX
#include "TypeInfo.hxx"
-#endif
namespace dbaui
{
@@ -176,3 +169,4 @@ namespace dbaui
#endif // DBAUI_TABLEUNDO_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/tabledesign/makefile.mk b/dbaccess/source/ui/tabledesign/makefile.mk
deleted file mode 100644
index 5e52041ecd29..000000000000
--- a/dbaccess/source/ui/tabledesign/makefile.mk
+++ /dev/null
@@ -1,65 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=tabledesign
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files --------------------------------------------------------
-
-SLOFILES =\
- $(SLO)$/TableDesignControl.obj \
- $(SLO)$/TableFieldDescWin.obj \
- $(SLO)$/TableController.obj \
- $(SLO)$/TableDesignView.obj \
- $(SLO)$/TEditControl.obj \
- $(SLO)$/TableFieldControl.obj \
- $(SLO)$/TableDesignHelpBar.obj \
- $(SLO)$/FieldDescGenWin.obj \
- $(SLO)$/FieldDescriptions.obj \
- $(SLO)$/TableRow.obj \
- $(SLO)$/TableRowExchange.obj \
- $(SLO)$/TableUndo.obj
-
-
-SRS1NAME=$(TARGET)
-SRC1FILES = table.src
-
-# --- Targets -------------------------------------------------------
-
-
-.INCLUDE : target.mk
-
-$(SRS)$/$(TARGET).srs: $(SOLARINCDIR)$/svx$/globlmn.hrc
diff --git a/dbaccess/source/ui/tabledesign/table.src b/dbaccess/source/ui/tabledesign/table.src
index 0f1168f97c8f..8ae961bcbb80 100644
--- a/dbaccess/source/ui/tabledesign/table.src
+++ b/dbaccess/source/ui/tabledesign/table.src
@@ -65,18 +65,22 @@ String STR_VALUE_YES
{
Text [ en-US ] = "Yes" ;
};
+
String STR_VALUE_NO
{
Text [ en-US ] = "No" ;
};
+
String STR_VALUE_ASC
{
Text [ en-US ] = "Ascending" ;
};
+
String STR_VALUE_DESC
{
Text [ en-US ] = "Descending" ;
};
+
String STR_VALUE_NONE
{
// Bemerkung : sollte auch in anderen Sprachen irgendwie zum Wort 'Wert' passen : Wert - keiner ....
@@ -87,46 +91,57 @@ String STR_TAB_FIELD_NAME
{
Text [ en-US ] = "Field name" ;
};
+
String STR_TAB_FIELD_COLUMN_NAME
{
Text [ en-US ] = "Field Name" ;
};
+
String STR_TAB_FIELD_DATATYPE
{
Text [ en-US ] = "Field ~type" ;
};
+
String STR_TAB_FIELD_COLUMN_DATATYPE
{
Text [ en-US ] = "Field Type" ;
};
+
String STR_TAB_FIELD_LENGTH
{
Text [ en-US ] = "Field length" ;
};
+
String STR_TAB_HELP_TEXT
{
Text [ en-US ] = "Description" ;
};
+
String STR_COLUMN_DESCRIPTION
{
Text [ en-US ] = "Column Description" ;
};
+
String STR_TAB_FIELD_NULLABLE
{
Text [ en-US ] = "Input required" ;
};
+
String STR_FIELD_AUTOINCREMENT
{
Text [ en-US ] = "~AutoValue";
};
+
String STR_TAB_PROPERTIES
{
Text [ en-US ] = "Field Properties" ;
};
+
String STR_TABPAGE_GENERAL
{
Text [ en-US ] = "General" ;
};
+
String STR_TAB_TABLE_DESCRIPTION
{
Text [ en-US ] = "Description:";
@@ -156,61 +171,67 @@ Menu RID_TABLEDESIGNROWPOPUPMENU
{
ItemList =
{
- MenuItem
- {
- ITEM_EDIT_CUT
- };
- MenuItem
- {
- ITEM_EDIT_COPY
- };
- MenuItem
- {
- ITEM_EDIT_PASTE
- };
- MenuItem
- {
- ITEM_EDIT_DELETE
- };
- MenuItem
- {
- Identifier = SID_TABLEDESIGN_INSERTROWS ;
- HelpID = HID_TABLEDESIGN_INSERTROWS ;
- Text [ en-US ] = "Insert Rows" ;
+ MenuItem
+ {
+ ITEM_EDIT_CUT
};
- MenuItem
- {
- Separator = TRUE ;
- };
- MenuItem
- {
- Identifier = SID_TABLEDESIGN_TABED_PRIMARYKEY ;
- HelpID = HID_TABLEDESIGN_TABED_PRIMARYKEY ;
- Checkable = TRUE ;
- Text [ en-US ] = "Primary Key" ;
+ MenuItem
+ {
+ ITEM_EDIT_COPY
+ };
+ MenuItem
+ {
+ ITEM_EDIT_PASTE
+ };
+ MenuItem
+ {
+ ITEM_EDIT_DELETE
+ };
+ MenuItem
+ {
+ Identifier = SID_TABLEDESIGN_INSERTROWS ;
+ HelpID = HID_TABLEDESIGN_INSERTROWS ;
+ Text [ en-US ] = "Insert Rows" ;
+ };
+ MenuItem
+ {
+ Separator = TRUE ;
+ };
+ MenuItem
+ {
+ Identifier = SID_TABLEDESIGN_TABED_PRIMARYKEY ;
+ HelpID = HID_TABLEDESIGN_TABED_PRIMARYKEY ;
+ Checkable = TRUE ;
+ Text [ en-US ] = "Primary Key" ;
};
};
};
+
String STR_TABED_UNDO_CELLMODIFIED
{
Text [ en-US ] = "Modify cell" ;
};
+
String STR_TABED_UNDO_ROWDELETED
{
Text [ en-US ] = "Delete row" ;
};
+
String STR_TABED_UNDO_TYPE_CHANGED
{
Text [ en-US ] = "Modify field type";
};
+
String STR_TABED_UNDO_ROWINSERTED
{
Text [ en-US ] = "Insert row" ;
};
+
String STR_TABED_UNDO_NEWROWINSERTED
{
Text [ en-US ] = "Insert new row" ;
};
+
String STR_TABED_UNDO_PRIMKEY
{
Text [ en-US ] = "Insert/remove primary key" ;
@@ -220,114 +241,141 @@ String STR_DEFAULT_VALUE
{
Text [ en-US ] = "~Default value" ;
};
+
String STR_FIELD_REQUIRED
{
Text [ en-US ] = "~Entry required" ;
};
+
String STR_TEXT_LENGTH
{
Text [ en-US ] = "~Length" ;
};
+
String STR_NUMERIC_TYPE
{
Text [ en-US ] = "~Type" ;
};
+
String STR_LENGTH
{
Text [ en-US ] = "~Length" ;
};
+
String STR_SCALE
{
Text [ en-US ] = "Decimal ~places" ;
};
+
String STR_FORMAT
{
Text [ en-US ] = "Format example";
};
+
String STR_HELP_BOOL_DEFAULT
{
Text [ en-US ] = "Select a value that is to appear in all new records as default.\nIf the field is not to have a default value, select the empty string.";
};
+
String STR_HELP_DEFAULT_VALUE
{
Text [ en-US ] = "Enter a default value for this field.\n\nWhen you later enter data in the table, this string will be used in each new record for the field selected. It should, therefore, correspond to the cell format that needs to be entered below." ;
};
+
String STR_HELP_FIELD_REQUIRED
{
Text [ en-US ] = "Activate this option if this field cannot contain NULL values, i.e. the user must always enter data." ;
};
+
String STR_HELP_TEXT_LENGTH
{
Text [ en-US ] = "Enter the maximum text length permitted." ;
};
+
String STR_HELP_NUMERIC_TYPE
{
Text [ en-US ] = "Enter the number format." ;
};
+
String STR_HELP_LENGTH
{
Text [ en-US ] = "Determine the length data can have in this field.\n\nIf decimal fields, then the maximum length of the number to be entered, if binary fields, then the length of the data block.\nThe value will be corrected accordingly when it exceeds the maximum for this database." ;
};
+
String STR_HELP_SCALE
{
Text [ en-US ] = "Specify the number of decimal places permitted in this field." ;
};
+
String STR_HELP_FORMAT_CODE
{
Text [ en-US ] = "This is where you see how the data would be displayed in the current format (use the button on the right to modify the format).";
};
+
String STR_HELP_FORMAT_BUTTON
{
Text [ en-US ] = "This is where you determine the output format of the data.";
};
+
String STR_HELP_AUTOINCREMENT
{
Text [ en-US ] = "Choose if this field should contain AutoIncrement values.\n\nYou can not enter data in fields of this type. An intrinsic value will be assigned to each new record automatically (resulting from the increment of the previous record)." ;
};
+
PushButton PB_FORMAT
{
TabStop = TRUE ;
Text [ en-US ] = "~...";
};
+
String STR_TABLEDESIGN_DUPLICATE_NAME
{
Text [ en-US ] = "The table cannot be saved because column name \"$column$\" was assigned twice.";
};
+
String STR_TBL_COLUMN_IS_KEYCOLUMN
{
Text [ en-US ] = "The column \"$column$\" belongs to the primary key. If the column is deleted, the primary key will also be deleted. Do you really want to continue?";
};
+
String STR_TBL_COLUMN_IS_KEYCOLUMN_TITLE
{
Text [ en-US ] = "Primary Key Affected";
};
+
String STR_COLUMN_NAME
{
Text [ en-US ] = "Column";
};
+
String STR_QRY_CONTINUE
{
Text [ en-US ] = "Continue anyway?" ;
};
+
String STR_STAT_WARNING
{
Text [ en-US ] = "Warning!" ;
};
+
QueryBox TABLE_DESIGN_SAVEMODIFIED
{
Buttons = WB_YES_NO_CANCEL ;
DefButton = WB_DEF_YES ;
Message [ en-US ] = "The table has been changed.\nDo you want to save the changes?" ;
};
+
QueryBox TABLE_QUERY_CONNECTION_LOST
{
Buttons = WB_YES_NO ;
Message [ en-US ] = "The connection to the database was lost! The table design can only be used with limited functionality without a connection.\nReconnect?" ;
};
+
String STR_TABLEDESIGN_CONNECTION_MISSING
{
Text [ en-US ] = "The table could not be saved due to problems connecting to the database.";
};
+
String STR_TABLEDESIGN_DATASOURCE_DELETED
{
Text [ en-US ] = "The table filter could not be adjusted because the data source has been deleted.";
@@ -339,14 +387,18 @@ QueryBox QUERY_SAVE_TABLE_EDIT_INDEXES
Buttons = WB_YES_NO ;
};
+
String STR_TABLEDESIGN_NO_PRIM_KEY_HEAD
{
Text [ en-US ] = "No primary key" ;
};
+
String STR_TABLEDESIGN_NO_PRIM_KEY
{
Text [ en-US ] = "A unique index or primary key is required for data record identification in this database.\nYou can only enter data into this table when one of these two structural conditions has been met.\n\nShould a primary key be created now?" ;
};
+
+
String STR_TABLEDESIGN_TITLE
{
Text [ en-US ] = " - %PRODUCTNAME Base: Table Design";
@@ -382,6 +434,7 @@ String STR_AUTOINCREMENT_VALUE
{
Text [ en-US ] = "A~uto-increment statement";
};
+
String STR_HELP_AUTOINCREMENT_VALUE
{
Text [ en-US ] = "Enter an SQL statement for the auto-increment field.\n\nThis statement will be directly transferred to the database when the table is created.";
diff --git a/dbaccess/source/ui/uno/AdabasSettingsDlg.cxx b/dbaccess/source/ui/uno/AdabasSettingsDlg.cxx
index 47a7b1a302e5..299c483d147d 100644
--- a/dbaccess/source/ui/uno/AdabasSettingsDlg.cxx
+++ b/dbaccess/source/ui/uno/AdabasSettingsDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _DBAUI_ADABASSETTINGSDLG_HXX
#include "AdabasSettingsDlg.hxx"
-#endif
-#ifndef DBAUI_ADABASSTATDLG_HXX
#include "AdabasStatDlg.hxx"
-#endif
using namespace dbaui;
@@ -131,3 +126,4 @@ Dialog* OAdabasSettingsDialog::createDialog(Window* _pParent)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/AdabasSettingsDlg.hxx b/dbaccess/source/ui/uno/AdabasSettingsDlg.hxx
index 4ccd46f4c45a..f102ba02c39d 100644
--- a/dbaccess/source/ui/uno/AdabasSettingsDlg.hxx
+++ b/dbaccess/source/ui/uno/AdabasSettingsDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,4 @@ protected:
#endif // _DBAUI_ADABASSETTINGSDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx b/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx
index d17e8e234e2f..bba4feed5ccb 100644
--- a/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx
+++ b/dbaccess/source/ui/uno/AdvancedSettingsDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -157,3 +158,5 @@ extern "C" void SAL_CALL createRegistryInfo_OAdvancedSettingsDialog()
{
static ::dbaui::OMultiInstanceAutoRegistration< ::dbaui::OAdvancedSettingsDialog > aAutoRegistration;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/ColumnControl.cxx b/dbaccess/source/ui/uno/ColumnControl.cxx
index 658f348f49f6..785080224b32 100644
--- a/dbaccess/source/ui/uno/ColumnControl.cxx
+++ b/dbaccess/source/ui/uno/ColumnControl.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,24 +28,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_COLUMNCONTROL_HXX
#include "ColumnControl.hxx"
-#endif
-#ifndef DBAUI_COLUMNPEER_HXX
#include "ColumnPeer.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_AWT_POSSIZE_HPP_
#include <com/sun/star/awt/PosSize.hpp>
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
extern "C" void SAL_CALL createRegistryInfo_OColumnControl()
{
@@ -149,3 +138,5 @@ void SAL_CALL OColumnControl::createPeer(const Reference< XToolkit >& /*rToolkit
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/ColumnControl.hxx b/dbaccess/source/ui/uno/ColumnControl.hxx
index 4d2a7de9829d..7971357106d3 100644
--- a/dbaccess/source/ui/uno/ColumnControl.hxx
+++ b/dbaccess/source/ui/uno/ColumnControl.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,12 +28,8 @@
#ifndef DBAUI_COLUMNCONTROL_HXX
#define DBAUI_COLUMNCONTROL_HXX
-#ifndef _TOOLKIT_CONTROLS_UNOCONTROL_HXX_
#include <toolkit/controls/unocontrol.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
namespace dbaui
{
@@ -55,3 +52,5 @@ namespace dbaui
//.........................................................................
#endif // DBAUI_COLUMNCONTROL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/ColumnModel.cxx b/dbaccess/source/ui/uno/ColumnModel.cxx
index 198e1bb5cb74..440ae3ae8fd3 100644
--- a/dbaccess/source/ui/uno/ColumnModel.cxx
+++ b/dbaccess/source/ui/uno/ColumnModel.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,37 +29,17 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_COLUMNMODEL_HXX
#include "ColumnModel.hxx"
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTRELIEF_HPP_
#include <com/sun/star/awt/FontRelief.hpp>
-#endif
-#ifndef _COM_SUN_STAR_AWT_FONTEMPHASISMARK_HPP_
#include <com/sun/star/awt/FontEmphasisMark.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
#include <com/sun/star/beans/PropertyAttribute.hpp>
-#endif
-#ifndef _CPPUHELPER_QUERYINTERFACE_HXX_
#include <cppuhelper/queryinterface.hxx>
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _TOOLKIT_UNOHLP_HXX
#include <toolkit/helper/vclunohelper.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
extern "C" void SAL_CALL createRegistryInfo_OColumnControlModel()
{
@@ -124,8 +105,6 @@ void OColumnControlModel::registerProperties()
&m_xConnection, ::getCppuType( &m_xConnection ) );
Any a;
a <<= m_xColumn;
-// registerMayBeVoidProperty( PROPERTY_COLUMN, PROPERTY_ID_COLUMN, PropertyAttribute::TRANSIENT | PropertyAttribute::BOUND| PropertyAttribute::MAYBEVOID,
-// &a, ::getCppuType( &m_xColumn ) );
registerProperty( PROPERTY_COLUMN, PROPERTY_ID_COLUMN, PropertyAttribute::TRANSIENT | PropertyAttribute::BOUND,
&m_xColumn, ::getCppuType( &m_xColumn ) );
@@ -186,3 +165,4 @@ void OColumnControlModel::read(const Reference<XObjectInputStream>& /*_rxInStrea
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/ColumnModel.hxx b/dbaccess/source/ui/uno/ColumnModel.hxx
index 363898c89111..734933a35dc0 100644
--- a/dbaccess/source/ui/uno/ColumnModel.hxx
+++ b/dbaccess/source/ui/uno/ColumnModel.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,39 +28,17 @@
#ifndef DBAUI_COLUMNMODEL_HXX
#define DBAUI_COLUMNMODEL_HXX
-#ifndef _COM_SUN_STAR_AWT_XCONTROLMODEL_HPP_
#include <com/sun/star/awt/XControlModel.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_
#include <com/sun/star/lang/XServiceInfo.hpp>
-#endif
-#ifndef _COM_SUN_STAR_UTIL_XCLONEABLE_HPP_
#include <com/sun/star/util/XCloneable.hpp>
-#endif
-#ifndef _COM_SUN_STAR_IO_XPERSISTOBJECT_HPP_
#include <com/sun/star/io/XPersistObject.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COMPHELPER_PROPERTY_ARRAY_HELPER_HXX_
#include <comphelper/proparrhlp.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTYCONTAINER_HXX_
#include <comphelper/propertycontainer.hxx>
-#endif
-#ifndef _COMPHELPER_BROADCASTHELPER_HXX_
#include <comphelper/broadcasthelper.hxx>
-#endif
-#ifndef _COMPHELPER_UNO3_HXX_
#include <comphelper/uno3.hxx>
-#endif
-#ifndef _CPPUHELPER_COMPBASE4_HXX_
#include <cppuhelper/compbase4.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -132,3 +111,5 @@ public:
} // namespace dbaui
//.........................................................................
#endif // DBAUI_COLUMNMODEL_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/ColumnPeer.cxx b/dbaccess/source/ui/uno/ColumnPeer.cxx
index a1270a01ff39..bdf364eeef54 100644
--- a/dbaccess/source/ui/uno/ColumnPeer.cxx
+++ b/dbaccess/source/ui/uno/ColumnPeer.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,21 +28,11 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_COLUMNPEER_HXX
#include "ColumnPeer.hxx"
-#endif
-#ifndef DBAUI_COLUMNCONTROLWINDOW_HXX
#include "ColumnControlWindow.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef DBAUI_FIELDDESCRIPTIONS_HXX
#include "FieldDescriptions.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -68,7 +59,7 @@ OColumnPeer::OColumnPeer(Window* _pParent,const Reference<XMultiServiceFactory>&
// -----------------------------------------------------------------------------
void OColumnPeer::setEditWidth(sal_Int32 _nWidth)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
OColumnControlWindow* pFieldControl = static_cast<OColumnControlWindow*>( GetWindow() );
if ( pFieldControl )
@@ -79,7 +70,7 @@ void OColumnPeer::setEditWidth(sal_Int32 _nWidth)
// -----------------------------------------------------------------------------
void OColumnPeer::setColumn(const Reference< XPropertySet>& _xColumn)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
OColumnControlWindow* pFieldControl = static_cast<OColumnControlWindow*>( GetWindow() );
if ( pFieldControl )
@@ -106,7 +97,7 @@ void OColumnPeer::setColumn(const Reference< XPropertySet>& _xColumn)
_xColumn->getPropertyValue(PROPERTY_PRECISION) >>= nPrecision;
_xColumn->getPropertyValue(PROPERTY_ISAUTOINCREMENT) >>= bAutoIncrement;
}
- catch(Exception)
+ catch(const Exception&)
{
}
@@ -127,7 +118,7 @@ void OColumnPeer::setColumn(const Reference< XPropertySet>& _xColumn)
// -----------------------------------------------------------------------------
void OColumnPeer::setConnection(const Reference< XConnection>& _xCon)
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
OColumnControlWindow* pFieldControl = static_cast<OColumnControlWindow*>( GetWindow() );
if ( pFieldControl )
pFieldControl->setConnection(_xCon);
@@ -135,7 +126,7 @@ void OColumnPeer::setConnection(const Reference< XConnection>& _xCon)
//------------------------------------------------------------------------------
void OColumnPeer::setProperty( const ::rtl::OUString& _rPropertyName, const Any& Value) throw( RuntimeException )
{
- ::vos::OGuard aGuard( Application::GetSolarMutex() );
+ SolarMutexGuard aGuard;
if ( 0 == _rPropertyName.compareToAscii( PROPERTY_COLUMN ) )
{
@@ -170,3 +161,5 @@ Any OColumnPeer::getProperty( const ::rtl::OUString& _rPropertyName ) throw( Run
//.........................................................................
} // namespace dbaui
//.........................................................................
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/ColumnPeer.hxx b/dbaccess/source/ui/uno/ColumnPeer.hxx
index e00459a67c10..e469e4997083 100644
--- a/dbaccess/source/ui/uno/ColumnPeer.hxx
+++ b/dbaccess/source/ui/uno/ColumnPeer.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -27,18 +28,10 @@
#ifndef DBAUI_COLUMNPEER_HXX
#define DBAUI_COLUMNPEER_HXX
-#ifndef _TOOLKIT_AWT_VCLXWINDOW_HXX_
#include <toolkit/awt/vclxwindow.hxx>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_LANG_XMULTISERVICEFACTORY_HPP_
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
-#endif
//.........................................................................
namespace dbaui
@@ -68,3 +61,4 @@ namespace dbaui
#endif //DBAUI_COLUMNPEER_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlg.cxx b/dbaccess/source/ui/uno/DBTypeWizDlg.cxx
index e0b8fe1c77e2..20fba85b948e 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlg.cxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef DBAUI_DBTYPEWIZDLG_HXX
#include "DBTypeWizDlg.hxx"
-#endif
-#ifndef DBAUI_DBWIZ_HXX
#include "dbwiz.hxx"
-#endif
using namespace dbaui;
@@ -130,3 +125,4 @@ Dialog* ODBTypeWizDialog::createDialog(Window* _pParent)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlg.hxx b/dbaccess/source/ui/uno/DBTypeWizDlg.hxx
index 4fee89192679..d34ed1b61c9b 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlg.hxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,4 @@ protected:
#endif // DBAUI_DBTYPEWIZDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
index 26005b12553a..1fc9f9f6b4eb 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,30 +29,14 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _COM_SUN_STAR_DOCUMENT_XEVENTLISTENER_HPP_
#include <com/sun/star/document/XEventListener.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XSET_HPP_
#include <com/sun/star/container/XSet.hpp>
-#endif
-#ifndef DBAUI_DBTYPEWIZDLGSETUP_HXX
#include "DBTypeWizDlgSetup.hxx"
-#endif
-#ifndef DBAUI_DBWIZSETUP_HXX
#include "dbwizsetup.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDB_XOFFICEDATABASEDOCUMENT_HPP_
#include <com/sun/star/sdb/XOfficeDatabaseDocument.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XDATASOURCE_HPP_
#include <com/sun/star/sdbc/XDataSource.hpp>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
using namespace dbaui;
namespace css = ::com::sun::star;
@@ -164,3 +149,4 @@ void ODBTypeWizDialogSetup::executedDialog(sal_Int16 _nExecutionResult)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx
index 1c85d1599c9b..2b91f9566992 100644
--- a/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx
+++ b/dbaccess/source/ui/uno/DBTypeWizDlgSetup.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -82,3 +83,4 @@ protected:
#endif // DBAUI_DBTYPEWIZDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/TableFilterDlg.cxx b/dbaccess/source/ui/uno/TableFilterDlg.cxx
index ed6ccfff3292..f52d693bc496 100644
--- a/dbaccess/source/ui/uno/TableFilterDlg.cxx
+++ b/dbaccess/source/ui/uno/TableFilterDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _DBAUI_TABLEFILTERDLG_HXX
#include "TableFilterDlg.hxx"
-#endif
-#ifndef _DBAUI_TABLESSINGLEDLG_HXX_
#include "TablesSingleDlg.hxx"
-#endif
using namespace dbaui;
@@ -131,3 +126,4 @@ Dialog* OTableFilterDialog::createDialog(Window* _pParent)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/TableFilterDlg.hxx b/dbaccess/source/ui/uno/TableFilterDlg.hxx
index 32aba9e4be82..3168c4d98751 100644
--- a/dbaccess/source/ui/uno/TableFilterDlg.hxx
+++ b/dbaccess/source/ui/uno/TableFilterDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,4 @@ protected:
#endif // _DBAUI_TABLEFILTERDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/UserSettingsDlg.cxx b/dbaccess/source/ui/uno/UserSettingsDlg.cxx
index 80ac97da6932..4d8b80aa5a85 100644
--- a/dbaccess/source/ui/uno/UserSettingsDlg.cxx
+++ b/dbaccess/source/ui/uno/UserSettingsDlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _DBAUI_USERSETTINGSDLG_HXX
#include "UserSettingsDlg.hxx"
-#endif
-#ifndef DBAUI_USERADMINDLG_HXX
#include "UserAdminDlg.hxx"
-#endif
using namespace dbaui;
@@ -131,3 +126,4 @@ Dialog* OUserSettingsDialog::createDialog(Window* _pParent)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/UserSettingsDlg.hxx b/dbaccess/source/ui/uno/UserSettingsDlg.hxx
index b2f603d09628..e46d1505ac6c 100644
--- a/dbaccess/source/ui/uno/UserSettingsDlg.hxx
+++ b/dbaccess/source/ui/uno/UserSettingsDlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,4 @@ protected:
#endif // _DBAUI_USERSETTINGSDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/admindlg.cxx b/dbaccess/source/ui/uno/admindlg.cxx
index 9a4714899653..3794c34cfefe 100644
--- a/dbaccess/source/ui/uno/admindlg.cxx
+++ b/dbaccess/source/ui/uno/admindlg.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,15 +29,9 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _DBAUI_ADMINDLG_HXX
#include "admindlg.hxx"
-#endif
-#ifndef _DBAUI_DBADMIN_HXX_
#include "dbadmin.hxx"
-#endif
using namespace dbaui;
@@ -137,3 +132,4 @@ Dialog* ODataSourcePropertyDialog::createDialog(Window* _pParent)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/admindlg.hxx b/dbaccess/source/ui/uno/admindlg.hxx
index 81af43fd92f0..3b0fc5d8c367 100644
--- a/dbaccess/source/ui/uno/admindlg.hxx
+++ b/dbaccess/source/ui/uno/admindlg.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -78,3 +79,4 @@ protected:
#endif // _DBAUI_ADMINDLG_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/composerdialogs.cxx b/dbaccess/source/ui/uno/composerdialogs.cxx
index 002a96c56420..c90c1d4b9ec1 100644
--- a/dbaccess/source/ui/uno/composerdialogs.cxx
+++ b/dbaccess/source/ui/uno/composerdialogs.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,36 +29,18 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_SOURCE_UI_UNO_COMPOSERDIALOGS_HXX
#include "composerdialogs.hxx"
-#endif
/** === begin UNO includes === **/
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef DBAUI_QUERYFILTER_HXX
#include "queryfilter.hxx"
-#endif
-#ifndef DBAUI_QUERYORDER_HXX
#include "queryorder.hxx"
-#endif
-#ifndef _CONNECTIVITY_DBTOOLS_HXX_
#include <connectivity/dbtools.hxx>
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
+#include <osl/diagnose.h>
extern "C" void SAL_CALL createRegistryInfo_ComposerDialogs()
{
@@ -141,13 +124,13 @@ namespace dbaui
if ( !xColumns.is() || !xColumns->hasElements() )
{ // perhaps the composer can supply us with columns? This is necessary for cases
// where the dialog is invoked for a rowset which is not yet loaded
- // #i22878# - 2003-12-16 - fs@openoffice.org
+ // #i22878#
xSuppColumns = xSuppColumns.query( m_xComposer );
if ( xSuppColumns.is() )
xColumns = xSuppColumns->getColumns();
}
- DBG_ASSERT( xColumns.is() && xColumns->hasElements(), "ComposerDialog::createDialog: not much fun without any columns!" );
+ OSL_ENSURE( xColumns.is() && xColumns->hasElements(), "ComposerDialog::createDialog: not much fun without any columns!" );
}
catch( const Exception& )
{
@@ -225,3 +208,4 @@ namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/composerdialogs.hxx b/dbaccess/source/ui/uno/composerdialogs.hxx
index 3a38880819b4..acc82ae93cf2 100644
--- a/dbaccess/source/ui/uno/composerdialogs.hxx
+++ b/dbaccess/source/ui/uno/composerdialogs.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -29,32 +30,16 @@
#define DBACCESS_SOURCE_UI_UNO_COMPOSERDIALOGS_HXX
/** === begin UNO includes === **/
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSINGLESELECTQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSingleSelectQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWSET_HPP_
#include <com/sun/star/sdbc/XRowSet.hpp>
-#endif
/** === end UNO includes === **/
-#ifndef _SVT_GENERICUNODIALOG_HXX_
#include <svtools/genericunodialog.hxx>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
//.........................................................................
namespace dbaui
@@ -158,3 +143,4 @@ namespace dbaui
#endif // DBACCESS_SOURCE_UI_UNO_COMPOSERDIALOGS_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/copytablewizard.cxx b/dbaccess/source/ui/uno/copytablewizard.cxx
index a78d3e802b4e..8fc61a268c30 100644
--- a/dbaccess/source/ui/uno/copytablewizard.cxx
+++ b/dbaccess/source/ui/uno/copytablewizard.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -329,7 +330,7 @@ namespace dbaui
const Reference< XPropertySet >& _rxDestTable
);
- /** processes an error which occured during copying
+ /** processes an error which occurred during copying
First, all listeners are ask. If a listener tells to cancel or continue copying, this is reported to the
method's caller. If a listener tells to ask the user, this is done, and the user's decision is
@@ -748,7 +749,7 @@ void CopyTableWizard::impl_checkForUnsupportedSettings_throw( const Reference< X
const ::rtl::OUString aSettings[] = {
PROPERTY_FILTER, PROPERTY_ORDER, PROPERTY_HAVING_CLAUSE, PROPERTY_GROUP_BY
};
- for ( size_t i=0; i < sizeof( aSettings ) / sizeof( aSettings[0] ); ++i )
+ for ( size_t i=0; i < SAL_N_ELEMENTS( aSettings ); ++i )
{
if ( lcl_hasNonEmptyStringValue_throw( _rxSourceDescriptor, xPSI, aSettings[i] ) )
{
@@ -1096,7 +1097,7 @@ bool CopyTableWizard::impl_processCopyError_nothrow( const CopyTableRowEvent& _r
case CopyTableContinuation::AskUser: break; // stop asking the listeners, ask the user
default:
- OSL_ENSURE( false, "CopyTableWizard::impl_processCopyError_nothrow: invalid listener response!" );
+ OSL_FAIL( "CopyTableWizard::impl_processCopyError_nothrow: invalid listener response!" );
// ask next listener
continue;
}
@@ -1113,7 +1114,7 @@ bool CopyTableWizard::impl_processCopyError_nothrow( const CopyTableRowEvent& _r
{
SQLContext aError;
aError.Context = *this;
- aError.Message = String( ModuleRes( STR_ERROR_OCCURED_WHILE_COPYING ) );
+ aError.Message = String( ModuleRes( STR_ERROR_OCCURRED_WHILE_COPYING ) );
::dbtools::SQLExceptionInfo aInfo( _rEvent.Error );
if ( aInfo.isValid() )
@@ -1398,7 +1399,7 @@ void CopyTableWizard::impl_doCopy_nothrow()
if( !xTable.is() )
{
- OSL_ENSURE( false, "CopyTableWizard::impl_doCopy_nothrow: createTable should throw here, shouldn't it?" );
+ OSL_FAIL( "CopyTableWizard::impl_doCopy_nothrow: createTable should throw here, shouldn't it?" );
break;
}
@@ -1415,7 +1416,7 @@ void CopyTableWizard::impl_doCopy_nothrow()
xTable = rWizard.createTable();
if ( !xTable.is() )
{
- OSL_ENSURE( false, "CopyTableWizard::impl_doCopy_nothrow: createTable should throw here, shouldn't it?" );
+ OSL_FAIL( "CopyTableWizard::impl_doCopy_nothrow: createTable should throw here, shouldn't it?" );
break;
}
}
@@ -1463,7 +1464,7 @@ void CopyTableWizard::impl_doCopy_nothrow()
break;
default:
- OSL_ENSURE( false, "CopyTableWizard::impl_doCopy_nothrow: What operation, please?" );
+ OSL_FAIL( "CopyTableWizard::impl_doCopy_nothrow: What operation, please?" );
break;
}
}
@@ -1516,7 +1517,7 @@ void CopyTableWizard::impl_doCopy_nothrow()
sColumns.append(aDestColumnNames[aPosIter->second - 1]);
sColumns.append(sQuote);
}
- } // for ( ; aPosIter != aColumnMapping.end() ; ++aPosIter )
+ }
::rtl::OUStringBuffer sSql;
sSql.appendAscii("INSERT INTO ");
const ::rtl::OUString sComposedTableName = ::dbtools::composeTableName( xDestMetaData, _xTable, ::dbtools::eInDataManipulation, false, false, true );
@@ -1640,3 +1641,5 @@ extern "C" void SAL_CALL createRegistryInfo_CopyTableWizard()
{
static ::dbaui::OMultiInstanceAutoRegistration< ::dbaui::CopyTableWizard > aAutoRegistration;
}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/copytablewizard.src b/dbaccess/source/ui/uno/copytablewizard.src
index fc6d00804607..a0dd16eabf4e 100644
--- a/dbaccess/source/ui/uno/copytablewizard.src
+++ b/dbaccess/source/ui/uno/copytablewizard.src
@@ -66,14 +66,17 @@ String STR_CTW_ERROR_DURING_INITIALIZATION
{
Text [ en-US ] = "An error occurred during initialization.";
};
+
String STR_CTW_ERROR_UNSUPPORTED_SETTING
{
Text [ en-US ] = "Unsupported setting in the copy source descriptor: $name$.";
};
+
String STR_CTW_ERROR_NO_QUERY
{
Text [ en-US ] = "To copy a query, your connection must be able to provide queries.";
};
+
String STR_CTW_ERROR_INVALID_INTERACTIONHANDLER
{
Text [ en-US ] = "The given interaction handler is invalid.";
diff --git a/dbaccess/source/ui/uno/dbinteraction.cxx b/dbaccess/source/ui/uno/dbinteraction.cxx
index 48d838eac7f6..fa9e913e6556 100755..100644
--- a/dbaccess/source/ui/uno/dbinteraction.cxx
+++ b/dbaccess/source/ui/uno/dbinteraction.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,66 +29,26 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_INTERACTION_HXX_
#include "dbinteraction.hxx"
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _TOOLS_DEBUG_HXX
-#include <tools/debug.hxx>
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
-#ifndef _SV_MSGBOX_HXX
+#include <osl/diagnose.h>
#include <vcl/msgbox.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONAPPROVE_HPP_
#include <com/sun/star/task/XInteractionApprove.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONDISAPPROVE_HPP_
#include <com/sun/star/task/XInteractionDisapprove.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONRETRY_HPP_
#include <com/sun/star/task/XInteractionRetry.hpp>
-#endif
-#ifndef _COM_SUN_STAR_TASK_XINTERACTIONABORT_HPP_
#include <com/sun/star/task/XInteractionAbort.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XINTERACTIONSUPPLYPARAMETERS_HPP_
#include <com/sun/star/sdb/XInteractionSupplyParameters.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDB_XINTERACTIONDOCUMENTSAVE_HPP_
#include <com/sun/star/sdb/XInteractionDocumentSave.hpp>
-#endif
-#ifndef SFX_QUERYSAVEDOCUMENT_HXX
#include <sfx2/QuerySaveDocument.hxx>
-#endif
-#ifndef _DBU_UNO_HRC_
#include "dbu_uno.hrc"
-#endif
-#ifndef _DBAUI_PARAMDIALOG_HXX_
#include "paramdialog.hxx"
-#endif
-#ifndef _SV_SVAPP_HXX
#include <vcl/svapp.hxx>
-#endif
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
-#ifndef DBAUI_COLLECTIONVIEW_HXX
+#include <osl/mutex.hxx>
#include "CollectionView.hxx"
-#endif
-#ifndef DBAUI_TOOLS_HXX
#include "UITools.hxx"
-#endif
//==========================================================================
@@ -138,7 +99,7 @@ namespace dbaui
sal_Bool BasicInteractionHandler::impl_handle_throw( const Reference< XInteractionRequest >& i_Request )
{
Any aRequest( i_Request->getRequest() );
- DBG_ASSERT(aRequest.hasValue(), "BasicInteractionHandler::handle: invalid request!");
+ OSL_ENSURE(aRequest.hasValue(), "BasicInteractionHandler::handle: invalid request!");
if ( !aRequest.hasValue() )
// no request -> no handling
return sal_False;
@@ -176,7 +137,7 @@ namespace dbaui
//-------------------------------------------------------------------------
void BasicInteractionHandler::implHandle(const ParametersRequest& _rParamRequest, const Sequence< Reference< XInteractionContinuation > >& _rContinuations)
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// want to open a dialog ....
sal_Int32 nAbortPos = getContinuation(ABORT, _rContinuations);
@@ -185,12 +146,7 @@ namespace dbaui
Reference< XInteractionSupplyParameters > xParamCallback;
if (-1 != nParamPos)
xParamCallback = Reference< XInteractionSupplyParameters >(_rContinuations[nParamPos], UNO_QUERY);
- DBG_ASSERT(xParamCallback.is(), "BasicInteractionHandler::implHandle(ParametersRequest): can't set the parameters without an appropriate interaction handler!s");
-
- // determine the style of the dialog, dependent on the present continuation types
- WinBits nDialogStyle = WB_OK | WB_DEF_OK;
- if (-1 != nAbortPos)
- nDialogStyle = WB_OK_CANCEL;
+ 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);
sal_Int16 nResult = aDlg.Execute();
@@ -220,7 +176,7 @@ namespace dbaui
//-------------------------------------------------------------------------
void BasicInteractionHandler::implHandle(const SQLExceptionInfo& _rSqlInfo, const Sequence< Reference< XInteractionContinuation > >& _rContinuations)
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// want to open a dialog ....
sal_Int32 nApprovePos = getContinuation(APPROVE, _rContinuations);
@@ -247,7 +203,7 @@ namespace dbaui
nDialogStyle = WB_RETRY_CANCEL | WB_DEF_RETRY;
}
- // excute the dialog
+ // execute the dialog
OSQLMessageBox aDialog(NULL, _rSqlInfo, nDialogStyle);
// TODO: need a way to specify the parent window
sal_Int16 nResult = aDialog.Execute();
@@ -267,7 +223,7 @@ namespace dbaui
if ( nDisapprovePos != -1 )
_rContinuations[ nDisapprovePos ]->select();
else
- OSL_ENSURE( false, "BasicInteractionHandler::implHandle: no handler for NO!" );
+ OSL_FAIL( "BasicInteractionHandler::implHandle: no handler for NO!" );
break;
case RET_CANCEL:
@@ -276,13 +232,13 @@ namespace dbaui
else if ( nDisapprovePos != -1 )
_rContinuations[ nDisapprovePos ]->select();
else
- OSL_ENSURE( false, "BasicInteractionHandler::implHandle: no handler for CANCEL!" );
+ OSL_FAIL( "BasicInteractionHandler::implHandle: no handler for CANCEL!" );
break;
case RET_RETRY:
if ( nRetryPos != -1 )
_rContinuations[ nRetryPos ]->select();
else
- OSL_ENSURE( false, "BasicInteractionHandler::implHandle: where does the RETRY come from?" );
+ OSL_FAIL( "BasicInteractionHandler::implHandle: where does the RETRY come from?" );
break;
}
}
@@ -294,7 +250,7 @@ namespace dbaui
//-------------------------------------------------------------------------
void BasicInteractionHandler::implHandle(const DocumentSaveRequest& _rDocuRequest, const Sequence< Reference< XInteractionContinuation > >& _rContinuations)
{
- ::vos::OGuard aGuard(Application::GetSolarMutex());
+ SolarMutexGuard aGuard;
// want to open a dialog ....
sal_Int32 nApprovePos = getContinuation(APPROVE, _rContinuations);
@@ -321,12 +277,7 @@ namespace dbaui
if (-1 != nDocuPos)
{
Reference< XInteractionDocumentSave > xCallback(_rContinuations[nDocuPos], UNO_QUERY);
- DBG_ASSERT(xCallback.is(), "BasicInteractionHandler::implHandle(DocumentSaveRequest): can't save document without an appropriate interaction handler!s");
-
- // determine the style of the dialog, dependent on the present continuation types
- WinBits nDialogStyle = WB_OK | WB_DEF_OK;
- if (-1 != nAbortPos)
- nDialogStyle = WB_OK_CANCEL;
+ OSL_ENSURE(xCallback.is(), "BasicInteractionHandler::implHandle(DocumentSaveRequest): can't save document without an appropriate interaction handler!s");
OCollectionView aDlg(NULL,_rDocuRequest.Content,_rDocuRequest.Name,m_xORB);
sal_Int16 nResult = aDlg.Execute();
@@ -425,3 +376,4 @@ namespace dbaui
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/dbinteraction.hxx b/dbaccess/source/ui/uno/dbinteraction.hxx
index f9a84ef935bc..90beac1b797e 100644
--- a/dbaccess/source/ui/uno/dbinteraction.hxx
+++ b/dbaccess/source/ui/uno/dbinteraction.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,9 +29,7 @@
#ifndef _DBAUI_INTERACTION_HXX_
#define _DBAUI_INTERACTION_HXX_
-#ifndef _CPPUHELPER_IMPLBASE2_HXX_
#include <cppuhelper/implbase2.hxx>
-#endif
#include "moduledbu.hxx"
#include "apitools.hxx"
@@ -125,7 +124,7 @@ namespace dbaui
SUPPLY_DOCUMENTSAVE
};
/** check if a given continuation sequence contains a given continuation type<p/>
- @return the index within <arg>_rContinuations</arg> of the first occurence of a continuation
+ @return the index within <arg>_rContinuations</arg> of the first occurrence of a continuation
of the requested type, -1 of no such continuation exists
*/
sal_Int32 getContinuation(
@@ -186,3 +185,4 @@ namespace dbaui
#endif // _DBAUI_INTERACTION_HXX_
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/makefile.mk b/dbaccess/source/ui/uno/makefile.mk
deleted file mode 100644
index 987e67241d43..000000000000
--- a/dbaccess/source/ui/uno/makefile.mk
+++ /dev/null
@@ -1,76 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#************************************************************************
-
-PRJ=..$/..$/..
-PRJINC=$(PRJ)$/source
-PRJNAME=dbaccess
-TARGET=uiuno
-
-ENABLE_EXCEPTIONS=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-.INCLUDE : $(PRJ)$/util$/makefile.pmk
-
-# --- Files -------------------------------------
-
-# ... resource files ............................
-
-SRS1NAME=$(TARGET)
-SRC1FILES = \
- dbinteraction.src \
- copytablewizard.src
-
-# ... object files ............................
-# workaround for issue http://qa.openoffice.org/issues/show_bug.cgi?id=102305 Linux specific
-.IF "$(COM)" == "GCC"
-NOOPTFILES=\
- $(SLO)$/copytablewizard.obj
-.ENDIF
-
-SLOFILES= \
- $(SLO)$/copytablewizard.obj \
- $(SLO)$/composerdialogs.obj \
- $(SLO)$/unosqlmessage.obj \
- $(SLO)$/unoadmin.obj \
- $(SLO)$/admindlg.obj \
- $(SLO)$/TableFilterDlg.obj \
- $(SLO)$/AdvancedSettingsDlg.obj \
- $(SLO)$/unoDirectSql.obj \
- $(SLO)$/DBTypeWizDlg.obj \
- $(SLO)$/DBTypeWizDlgSetup.obj \
- $(SLO)$/UserSettingsDlg.obj \
- $(SLO)$/ColumnModel.obj \
- $(SLO)$/ColumnControl.obj \
- $(SLO)$/ColumnPeer.obj \
- $(SLO)$/dbinteraction.obj \
- $(SLO)$/textconnectionsettings_uno.obj
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
diff --git a/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx b/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx
index 037a17f76497..b2be6d475acf 100644
--- a/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx
+++ b/dbaccess/source/ui/uno/textconnectionsettings_uno.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -261,3 +262,4 @@ extern "C" void SAL_CALL createRegistryInfo_OTextConnectionSettingsDialog()
static ::dbaui::OMultiInstanceAutoRegistration< ::dbaui::OTextConnectionSettingsDialog > aAutoRegistration;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/unoDirectSql.cxx b/dbaccess/source/ui/uno/unoDirectSql.cxx
index 309880cba24a..310705974590 100644
--- a/dbaccess/source/ui/uno/unoDirectSql.cxx
+++ b/dbaccess/source/ui/uno/unoDirectSql.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,36 +29,16 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBAUI_UNODIRECTSQL_HXX
#include "unoDirectSql.hxx"
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBCX_XCOLUMNSSUPPLIER_HPP_
#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMEACCESS_HPP_
#include <com/sun/star/container/XNameAccess.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONNECTION_XCONNECTION_HPP_
#include <com/sun/star/connection/XConnection.hpp>
-#endif
-#ifndef _COM_SUN_STAR_CONTAINER_XNAMED_HPP_
#include <com/sun/star/container/XNamed.hpp>
-#endif
-#ifndef _DBACCESS_UI_DIRECTSQL_HXX_
#include "directsql.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _DBAUI_DATASOURCECONNECTOR_HXX_
#include "datasourceconnector.hxx"
-#endif
-#ifndef TOOLS_DIAGNOSE_EX_H
#include <tools/diagnose_ex.h>
-#endif
extern "C" void SAL_CALL createRegistryInfo_ODirectSQLDialog()
@@ -154,3 +135,4 @@ DBG_NAME(ODirectSQLDialog)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/unoDirectSql.hxx b/dbaccess/source/ui/uno/unoDirectSql.hxx
index e8837de3aca8..1f7dde873282 100644
--- a/dbaccess/source/ui/uno/unoDirectSql.hxx
+++ b/dbaccess/source/ui/uno/unoDirectSql.hxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,27 +29,13 @@
#ifndef DBAUI_UNODIRECTSQL_HXX
#define DBAUI_UNODIRECTSQL_HXX
-#ifndef _SVT_GENERICUNODIALOG_HXX_
#include <svtools/genericunodialog.hxx>
-#endif
-#ifndef _DBASHARED_APITOOLS_HXX_
#include "apitools.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDB_XSQLQUERYCOMPOSER_HPP_
#include <com/sun/star/sdb/XSQLQueryComposer.hpp>
-#endif
-#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSET_HPP_
#include <com/sun/star/beans/XPropertySet.hpp>
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XROWSET_HPP_
#include <com/sun/star/sdbc/XRowSet.hpp>
-#endif
-#ifndef _DBAUI_MODULE_DBU_HXX_
#include "moduledbu.hxx"
-#endif
-#ifndef _COM_SUN_STAR_SDBC_XCONNECTION_HPP_
#include <com/sun/star/sdbc/XConnection.hpp>
-#endif
//.........................................................................
namespace dbaui
@@ -92,3 +79,4 @@ namespace dbaui
#endif // DBAUI_UNODIRECTSQL_HXX
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/unoadmin.cxx b/dbaccess/source/ui/uno/unoadmin.cxx
index 1c1290977409..64cb5f671f03 100644
--- a/dbaccess/source/ui/uno/unoadmin.cxx
+++ b/dbaccess/source/ui/uno/unoadmin.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,44 +29,22 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _TOOLKIT_AWT_VCLXWINDOW_HXX_
#include <toolkit/awt/vclxwindow.hxx>
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
#ifndef _DBAUI_UNOADMIN_
#include "unoadmin.hxx"
#endif
-#ifndef _DBAUI_DBADMIN_HXX_
#include "dbadmin.hxx"
-#endif
-#ifndef _COMPHELPER_EXTRACT_HXX_
#include <comphelper/extract.hxx>
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _COMPHELPER_PROPERTY_HXX_
#include <comphelper/property.hxx>
-#endif
-#ifndef _OSL_DIAGNOSE_H_
#include <osl/diagnose.h>
-#endif
-#ifndef _SV_MSGBOX_HXX
#include <vcl/msgbox.hxx>
-#endif
// --- needed because of the solar mutex
-#ifndef _VOS_MUTEX_HXX_
-#include <vos/mutex.hxx>
-#endif
-#ifndef _SV_SVAPP_HXX
+#include <osl/mutex.hxx>
#include <vcl/svapp.hxx>
-#endif
// ---
#define THISREF() static_cast< XServiceInfo* >(this)
@@ -143,3 +122,4 @@ void ODatabaseAdministrationDialog::implInitialize(const Any& _rValue)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/source/ui/uno/unosqlmessage.cxx b/dbaccess/source/ui/uno/unosqlmessage.cxx
index 6626749a5aa6..5166debafdf5 100644
--- a/dbaccess/source/ui/uno/unosqlmessage.cxx
+++ b/dbaccess/source/ui/uno/unosqlmessage.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -28,24 +29,12 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_dbui.hxx"
-#ifndef _DBAUI_SQLMESSAGE_HXX_
#include "sqlmessage.hxx"
-#endif
-#ifndef _DBAUI_UNOSQLMESSAGE_HXX_
#include "unosqlmessage.hxx"
-#endif
-#ifndef _DBU_REGHELPER_HXX_
#include "dbu_reghelper.hxx"
-#endif
-#ifndef DBACCESS_SHARED_DBUSTRINGS_HRC
#include "dbustrings.hrc"
-#endif
-#ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
#include <cppuhelper/typeprovider.hxx>
-#endif
-#ifndef _DBHELPER_DBEXCEPTION_HXX_
#include <connectivity/dbexception.hxx>
-#endif
using namespace dbaui;
using namespace dbtools;
@@ -100,7 +89,7 @@ Reference< XInterface > SAL_CALL OSQLMessageDialog::Create(const Reference< XMul
//-------------------------------------------------------------------------
::rtl::OUString OSQLMessageDialog::getImplementationName_Static() throw(RuntimeException)
{
- return ::rtl::OUString::createFromAscii("org.openoffice.comp.dbu.OSQLMessageDialog");
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.comp.dbu.OSQLMessageDialog"));
}
//-------------------------------------------------------------------------
@@ -113,7 +102,7 @@ Reference< XInterface > SAL_CALL OSQLMessageDialog::Create(const Reference< XMul
::comphelper::StringSequence OSQLMessageDialog::getSupportedServiceNames_Static() throw(RuntimeException)
{
::comphelper::StringSequence aSupported(1);
- aSupported.getArray()[0] = ::rtl::OUString::createFromAscii("com.sun.star.sdb.ErrorMessageDialog");
+ aSupported.getArray()[0] = ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.sdb.ErrorMessageDialog"));
return aSupported;
}
@@ -166,7 +155,7 @@ Dialog* OSQLMessageDialog::createDialog(Window* _pParent)
if ( m_aException.hasValue() )
return new OSQLMessageBox( _pParent, SQLExceptionInfo( m_aException ), WB_OK | WB_DEF_OK, m_sHelpURL );
- OSL_ENSURE(sal_False, "OSQLMessageDialog::createDialog : You should use the SQLException property to specify the error to display!");
+ OSL_FAIL("OSQLMessageDialog::createDialog : You should use the SQLException property to specify the error to display!");
return new OSQLMessageBox(_pParent, SQLException());
}
@@ -174,3 +163,4 @@ Dialog* OSQLMessageDialog::createDialog(Window* _pParent)
} // namespace dbaui
//.........................................................................
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/dbaccess/uiconfig/dbapp/menubar/menubar.xml b/dbaccess/uiconfig/dbapp/menubar/menubar.xml
index baafddcae8ad..a76fda58c575 100644
--- a/dbaccess/uiconfig/dbapp/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbapp/menubar/menubar.xml
@@ -133,9 +133,9 @@
<menu:menuitem menu:id=".uno:HelpIndex"/>
<menu:menuitem menu:id=".uno:ExtendedHelp"/>
<menu:menuseparator/>
- <menu:menuitem menu:id=".uno:HelpSupport"/>
- <menu:menuitem menu:id=".uno:OnlineRegistrationDlg"/>
+ <menu:menuitem menu:id=".uno:ShowLicense"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ShowCredits"/>
<menu:menuitem menu:id=".uno:About"/>
</menu:menupopup>
</menu:menu>
diff --git a/dbaccess/uiconfig/dbquery/menubar/menubar.xml b/dbaccess/uiconfig/dbquery/menubar/menubar.xml
index a3a965290fd6..2d6ec8d05abc 100644
--- a/dbaccess/uiconfig/dbquery/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbquery/menubar/menubar.xml
@@ -74,9 +74,9 @@
<menu:menuitem menu:id=".uno:HelpIndex"/>
<menu:menuitem menu:id=".uno:ExtendedHelp"/>
<menu:menuseparator/>
- <menu:menuitem menu:id=".uno:HelpSupport"/>
- <menu:menuitem menu:id=".uno:OnlineRegistrationDlg"/>
+ <menu:menuitem menu:id=".uno:ShowLicense"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ShowCredits"/>
<menu:menuitem menu:id=".uno:About"/>
</menu:menupopup>
</menu:menu>
diff --git a/dbaccess/uiconfig/dbrelation/menubar/menubar.xml b/dbaccess/uiconfig/dbrelation/menubar/menubar.xml
index 542395e58e9a..b7460a447e54 100644
--- a/dbaccess/uiconfig/dbrelation/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbrelation/menubar/menubar.xml
@@ -57,9 +57,9 @@
<menu:menuitem menu:id=".uno:HelpIndex"/>
<menu:menuitem menu:id=".uno:ExtendedHelp"/>
<menu:menuseparator/>
- <menu:menuitem menu:id=".uno:HelpSupport"/>
- <menu:menuitem menu:id=".uno:OnlineRegistrationDlg"/>
+ <menu:menuitem menu:id=".uno:ShowLicense"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ShowCredits"/>
<menu:menuitem menu:id=".uno:About"/>
</menu:menupopup>
</menu:menu>
diff --git a/dbaccess/uiconfig/dbtable/menubar/menubar.xml b/dbaccess/uiconfig/dbtable/menubar/menubar.xml
index 18bdde9ec991..ede5eed2c224 100644
--- a/dbaccess/uiconfig/dbtable/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbtable/menubar/menubar.xml
@@ -58,9 +58,9 @@
<menu:menuitem menu:id=".uno:HelpIndex"/>
<menu:menuitem menu:id=".uno:ExtendedHelp"/>
<menu:menuseparator/>
- <menu:menuitem menu:id=".uno:HelpSupport"/>
- <menu:menuitem menu:id=".uno:OnlineRegistrationDlg"/>
+ <menu:menuitem menu:id=".uno:ShowLicense"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ShowCredits"/>
<menu:menuitem menu:id=".uno:About"/>
</menu:menupopup>
</menu:menu>
diff --git a/dbaccess/uiconfig/dbtdata/menubar/menubar.xml b/dbaccess/uiconfig/dbtdata/menubar/menubar.xml
index 6b261670f854..79fe68a2d7d8 100644
--- a/dbaccess/uiconfig/dbtdata/menubar/menubar.xml
+++ b/dbaccess/uiconfig/dbtdata/menubar/menubar.xml
@@ -66,9 +66,9 @@
<menu:menuitem menu:id=".uno:HelpIndex"/>
<menu:menuitem menu:id=".uno:ExtendedHelp"/>
<menu:menuseparator/>
- <menu:menuitem menu:id=".uno:HelpSupport"/>
- <menu:menuitem menu:id=".uno:OnlineRegistrationDlg"/>
+ <menu:menuitem menu:id=".uno:ShowLicense"/>
<menu:menuseparator/>
+ <menu:menuitem menu:id=".uno:ShowCredits"/>
<menu:menuitem menu:id=".uno:About"/>
</menu:menupopup>
</menu:menu>
diff --git a/dbaccess/util/makefile.mk b/dbaccess/util/makefile.mk
deleted file mode 100644
index d59855961c79..000000000000
--- a/dbaccess/util/makefile.mk
+++ /dev/null
@@ -1,261 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..
-PRJNAME=dbaccess
-TARGET=dba
-TARGET2=dbu
-TARGET3=sdbt
-USE_DEFFILE=TRUE
-GEN_HID=TRUE
-GEN_HID_OTHER=TRUE
-
-# --- Settings ----------------------------------
-
-.INCLUDE : settings.mk
-
-LDUMP=ldump2.exe
-
-# --- database core (dba) -----------------------------------
-.IF "$(L10N_framework)"==""
-LIB1TARGET=$(SLB)$/$(TARGET).lib
-LIB1FILES=\
- $(SLB)$/api.lib \
- $(SLB)$/dataaccess.lib \
- $(SLB)$/recovery.lib \
- $(SLB)$/misc.lib \
- $(SLB)$/core_resource.lib
-
-SHL1TARGET=$(TARGET)$(DLLPOSTFIX)
-
-SHL1STDLIBS= \
- $(SVTOOLLIB) \
- $(VCLLIB) \
- $(UNOTOOLSLIB) \
- $(TOOLSLIB) \
- $(I18NISOLANGLIB) \
- $(DBTOOLSLIB) \
- $(COMPHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(UCBHELPERLIB) \
- $(SVLLIB) \
- $(CPPULIB) \
- $(SALLIB) \
- $(SFXLIB) \
- $(BASICLIB) \
- $(FWELIB) \
- $(SALHELPERLIB) \
- $(XMLOFFLIB)
-
-SHL1DEPN=
-SHL1IMPLIB=i$(TARGET)
-SHL1LIBS=$(LIB1TARGET)
-SHL1DEF=$(MISC)$/$(SHL1TARGET).def
-DEF1NAME=$(SHL1TARGET)
-DEFLIB1NAME=$(TARGET)
-DEF1DEPN= $(MISC)$/$(SHL1TARGET).flt \
- $(SLB)$/$(TARGET).lib
-SHL1USE_EXPORTS=name
-
-.ENDIF
-# --- .res file ----------------------------------------------------------
-
-RES1FILELIST=\
- $(SRS)$/core_strings.srs
-
-RESLIB1NAME=$(TARGET)
-RESLIB1IMAGES=$(PRJ)$/res
-RESLIB1SRSFILES=$(RES1FILELIST)
-
-# --- database ui (dbu) -----------------------------------
-.IF "$(L10N_framework)"==""
-
-LIB2TARGET=$(SLB)$/$(TARGET2).lib
-LIB2FILES=\
- $(SLB)$/relationdesign.lib \
- $(SLB)$/tabledesign.lib \
- $(SLB)$/querydesign.lib \
- $(SLB)$/uimisc.lib \
- $(SLB)$/uidlg.lib \
- $(SLB)$/dbushared.lib \
- $(SLB)$/browser.lib \
- $(SLB)$/uiuno.lib \
- $(SLB)$/app.lib \
- $(SLB)$/uicontrols.lib
-
-SHL2TARGET=$(TARGET2)$(DLLPOSTFIX)
-
-SHL2STDLIBS= \
- $(SVXCORELIB) \
- $(SVXLIB) \
- $(SFXLIB) \
- $(SVTOOLLIB) \
- $(FWELIB) \
- $(TKLIB) \
- $(VCLLIB) \
- $(SVLLIB) \
- $(SOTLIB) \
- $(UNOTOOLSLIB) \
- $(TOOLSLIB) \
- $(UCBHELPERLIB) \
- $(DBTOOLSLIB) \
- $(COMPHELPERLIB) \
- $(CPPUHELPERLIB) \
- $(CPPULIB) \
- $(SO2LIB) \
- $(VOSLIB) \
- $(SALLIB)
-
-.IF "$(GUI)"=="OS2"
-SHL2STDLIBS+= $(LB)$/i$(TARGET).lib
-SHL2DEPN=$(LB)$/i$(TARGET).lib
-.ELIF "$(GUI)"!="WNT" || "$(COM)"=="GCC"
-SHL2STDLIBS+= \
- -l$(TARGET)$(DLLPOSTFIX)
-SHL2DEPN=$(SHL1TARGETN)
-.ELSE
-SHL2STDLIBS+= \
- $(LB)$/i$(TARGET).lib
-SHL2DEPN=$(LB)$/i$(TARGET).lib
-.ENDIF
-
-SHL2IMPLIB=i$(TARGET2)
-SHL2LIBS=$(LIB2TARGET)
-SHL2DEF=$(MISC)$/$(SHL2TARGET).def
-DEF2NAME=$(SHL2TARGET)
-DEFLIB2NAME=$(TARGET2)
-DEF2DEPN= $(MISC)$/$(SHL2TARGET).flt \
- $(SLB)$/$(TARGET2).lib
-SHL2USE_EXPORTS=name
-
-ALL: \
- $(LIB1TARGET) \
- $(LIB2TARGET) \
- ALLTAR
-
-.ENDIF
-# --- .res file ----------------------------------------------------------
-
-RES2FILELIST=\
- $(SRS)$/uidlg.srs \
- $(SRS)$/app.srs \
- $(SRS)$/uicontrols.srs \
- $(SRS)$/browser.srs \
- $(SRS)$/uiuno.srs \
- $(SRS)$/querydesign.srs \
- $(SRS)$/tabledesign.srs \
- $(SRS)$/relationdesign.srs \
- $(SRS)$/uiimglst.srs \
- $(SRS)$/uimisc.srs
-
-.IF "$(GUI)"=="WNT"
-#needed by $(SLO)$/adodatalinks.obj
-SHL2STDLIBS+= $(OLE32LIB) \
- $(OLEAUT32LIB) \
- $(UUIDLIB)
-.ENDIF
-
-RESLIB2NAME=$(TARGET2)
-RESLIB2IMAGES=$(PRJ)$/res
-RESLIB2SRSFILES=$(RES2FILELIST)
-
-# --- database tools (sdbt) -----------------------------------
-.IF "$(L10N_framework)"==""
-LIB3TARGET=$(SLB)$/$(TARGET3).lib
-LIB3FILES=\
- $(SLB)$/conntools.lib \
- $(SLB)$/sdbtmisc.lib \
- $(SLB)$/sdbtshared.lib
-
-SHL3TARGET=$(TARGET3)$(DLLPOSTFIX)
-
-SHL3STDLIBS= \
- $(CPPULIB) \
- $(CPPUHELPERLIB) \
- $(UNOTOOLSLIB) \
- $(COMPHELPERLIB) \
- $(TOOLSLIB) \
- $(DBTOOLSLIB) \
- $(SALLIB)
-
-SHL3LIBS=$(LIB3TARGET)
-SHL3DEF=$(MISC)$/$(SHL3TARGET).def
-DEF3NAME=$(SHL3TARGET)
-SHL3VERSIONMAP=$(SOLARENV)/src/component.map
-
-.END
-
-# --- .res file ----------------------------------------------------------
-
-RES3FILELIST=\
- $(SRS)$/sdbt_strings.srs
-
-RESLIB3NAME=$(TARGET3)
-RESLIB3IMAGES=$(PRJ)$/res
-RESLIB3SRSFILES=$(RES3FILELIST)
-
-# --- Targets ----------------------------------
-
-.INCLUDE : target.mk
-.IF "$(depend)"==""
-
-.IF "$(L10N_framework)"==""
-
-$(MISC)$/$(SHL2TARGET).flt: makefile.mk
- @echo ------------------------------
- @echo CLEAR_THE_FILE > $@
- @echo _TI >>$@
- @echo _real >>$@
-
-$(MISC)$/$(SHL1TARGET).flt: makefile.mk
- @echo ------------------------------
- @echo CLEAR_THE_FILE > $@
- @echo _TI >>$@
- @echo _real >>$@
-.ENDIF
-
-.ENDIF
-
-ALLTAR : $(MISC)/dba.component $(MISC)/dbu.component $(MISC)/sdbt.component
-
-$(MISC)/dba.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- dba.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt dba.component
-
-$(MISC)/dbu.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- dbu.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL2TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt dbu.component
-
-$(MISC)/sdbt.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
- sdbt.component
- $(XSLTPROC) --nonet --stringparam uri \
- '$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL3TARGETN:f)' -o $@ \
- $(SOLARENV)/bin/createcomponent.xslt sdbt.component
diff --git a/dbaccess/win32/source/odbcconfig/makefile.mk b/dbaccess/win32/source/odbcconfig/makefile.mk
deleted file mode 100644
index 72d81e39541f..000000000000
--- a/dbaccess/win32/source/odbcconfig/makefile.mk
+++ /dev/null
@@ -1,54 +0,0 @@
-#*************************************************************************
-#
-# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
-# Copyright 2000, 2010 Oracle and/or its affiliates.
-#
-# OpenOffice.org - a multi-platform office productivity suite
-#
-# This file is part of OpenOffice.org.
-#
-# OpenOffice.org is free software: you can redistribute it and/or modify
-# it under the terms of the GNU Lesser General Public License version 3
-# only, as published by the Free Software Foundation.
-#
-# OpenOffice.org is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU Lesser General Public License version 3 for more details
-# (a copy is included in the LICENSE file that accompanied this code).
-#
-# You should have received a copy of the GNU Lesser General Public License
-# version 3 along with OpenOffice.org. If not, see
-# <http://www.openoffice.org/license.html>
-# for a copy of the LGPLv3 License.
-#
-#*************************************************************************
-
-PRJ=..$/..$/..
-
-PRJNAME=dbaccess
-TARGET=odbcconfig
-LIBTARGET=NO
-TARGETTYPE=GUI
-
-# --- Settings -----------------------------------------------------
-
-.INCLUDE : settings.mk
-
-# --- Files --------------------------------------------------------
-
-OBJFILES= \
- $(OBJ)$/odbcconfig.obj
-
-# SQLManageDataSources wrapper
-APP1TARGET=$(TARGET)
-APP1NOSAL=TRUE
-APP1OBJS = \
- $(OBJ)$/odbcconfig.obj
-
-# --- Targets ------------------------------------------------------
-
-
-.INCLUDE : target.mk
-
diff --git a/dbaccess/win32/source/odbcconfig/odbcconfig.cxx b/dbaccess/win32/source/odbcconfig/odbcconfig.cxx
index 6cfabce13a7d..64360c2a72b0 100644
--- a/dbaccess/win32/source/odbcconfig/odbcconfig.cxx
+++ b/dbaccess/win32/source/odbcconfig/odbcconfig.cxx
@@ -1,3 +1,4 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
/*************************************************************************
*
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
@@ -157,3 +158,4 @@ extern "C" int APIENTRY _tWinMain( HINSTANCE _hAppInstance, HINSTANCE, LPTSTR, i
return 0;
}
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */