[Libreoffice-commits] core.git: dbaccess/source include/cppu

Stefan Weiberg stefan.weiberg at germandev.org
Tue Sep 2 02:07:23 PDT 2014


 dbaccess/source/ui/app/AppDetailPageHelper.cxx |    4 +--
 dbaccess/source/ui/app/AppDetailView.cxx       |    2 -
 dbaccess/source/ui/browser/dsEntriesNoExp.cxx  |    6 ++---
 dbaccess/source/ui/browser/unodatbr.cxx        |    4 +--
 dbaccess/source/ui/dlg/adtabdlg.cxx            |    2 -
 dbaccess/source/ui/inc/imageprovider.hxx       |    4 ---
 dbaccess/source/ui/misc/imageprovider.cxx      |    3 +-
 dbaccess/source/ui/querydesign/TableWindow.cxx |    2 +
 include/cppu/EnvGuards.hxx                     |   13 ++++--------
 include/cppu/Map.hxx                           |   26 +++++++++++--------------
 10 files changed, 30 insertions(+), 36 deletions(-)

New commits:
commit a4b9bfb993e9d724431befd1295b107f7758c8fd
Author: Stefan Weiberg <stefan.weiberg at germandev.org>
Date:   Mon Sep 1 09:20:45 2014 +0000

    Related fdo#82088: removing and shortening aliases
    
    Change-Id: Iebd9124daffe98b1e38dfa71d8b11f2452e3ddaa
    Reviewed-on: https://gerrit.libreoffice.org/11226
    Reviewed-by: Thomas Arnhold <thomas at arnhold.org>
    Tested-by: Thomas Arnhold <thomas at arnhold.org>

diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.cxx b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
index c0cffcf..d5b5838 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.cxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
@@ -85,8 +85,8 @@ using ::com::sun::star::awt::XTabController;
 
 namespace dbaui
 {
-    namespace DatabaseObject = ::com::sun::star::sdb::application::DatabaseObject;
-    namespace DatabaseObjectContainer = ::com::sun::star::sdb::application::DatabaseObjectContainer;
+    namespace DatabaseObject = css::sdb::application::DatabaseObject;
+    namespace DatabaseObjectContainer = css::sdb::application::DatabaseObjectContainer;
 }
 
 namespace
diff --git a/dbaccess/source/ui/app/AppDetailView.cxx b/dbaccess/source/ui/app/AppDetailView.cxx
index 477c0f3..8f3a8d8 100644
--- a/dbaccess/source/ui/app/AppDetailView.cxx
+++ b/dbaccess/source/ui/app/AppDetailView.cxx
@@ -355,7 +355,7 @@ OTasksWindow::OTasksWindow(Window* _pParent,OApplicationDetailView* _pDetailView
     m_aDescription.SetText(ModuleRes(STR_DESCRIPTION));
 
     ImageProvider aImageProvider;
-    Image aFolderImage = aImageProvider.getFolderImage( DatabaseObject::FORM );
+    Image aFolderImage = aImageProvider.getFolderImage( css::sdb::application::DatabaseObject::FORM );
     m_aCreation.SetDefaultCollapsedEntryBmp( aFolderImage );
     m_aCreation.SetDefaultExpandedEntryBmp( aFolderImage );
 
diff --git a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
index a73f5ed..3994390 100644
--- a/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
+++ b/dbaccess/source/ui/browser/dsEntriesNoExp.cxx
@@ -176,15 +176,15 @@ sal_Int32 SbaTableQueryBrowser::getDatabaseObjectType( EntryType _eType )
     {
     case etQuery:
     case etQueryContainer:
-        return DatabaseObject::QUERY;
+        return css::sdb::application::DatabaseObject::QUERY;
     case etTableOrView:
     case etTableContainer:
-        return DatabaseObject::TABLE;
+        return css::sdb::application::DatabaseObject::TABLE;
     default:
         break;
     }
     OSL_FAIL( "SbaTableQueryBrowser::getDatabaseObjectType: folder types and 'Unknown' not allowed here!" );
-    return DatabaseObject::TABLE;
+    return css::sdb::application::DatabaseObject::TABLE;
 }
 
 void SbaTableQueryBrowser::notifyHiContrastChanged()
diff --git a/dbaccess/source/ui/browser/unodatbr.cxx b/dbaccess/source/ui/browser/unodatbr.cxx
index a2d1ea4..1076acc 100644
--- a/dbaccess/source/ui/browser/unodatbr.cxx
+++ b/dbaccess/source/ui/browser/unodatbr.cxx
@@ -163,8 +163,8 @@ extern "C" void SAL_CALL createRegistryInfo_OBrowser()
 namespace dbaui
 {
 
-namespace DatabaseObject = ::com::sun::star::sdb::application::DatabaseObject;
-namespace DatabaseObjectContainer = ::com::sun::star::sdb::application::DatabaseObjectContainer;
+namespace DatabaseObject = css::sdb::application::DatabaseObject;
+namespace DatabaseObjectContainer = css::sdb::application::DatabaseObjectContainer;
 
 void SafeAddPropertyListener(const Reference< XPropertySet > & xSet, const OUString& rPropName, XPropertyChangeListener* pListener)
 {
diff --git a/dbaccess/source/ui/dlg/adtabdlg.cxx b/dbaccess/source/ui/dlg/adtabdlg.cxx
index df32b01..e5721ab 100644
--- a/dbaccess/source/ui/dlg/adtabdlg.cxx
+++ b/dbaccess/source/ui/dlg/adtabdlg.cxx
@@ -274,7 +274,7 @@ void QueryListFacade::updateTableObjectList( bool /*_bAllowViews*/ )
     try
     {
         ImageProvider aImageProvider( m_xConnection );
-        Image aQueryImage( aImageProvider.getDefaultImage( DatabaseObject::QUERY ) );
+        Image aQueryImage( aImageProvider.getDefaultImage( css::sdb::application::DatabaseObject::QUERY ) );
 
         m_rQueryList.SetDefaultExpandedEntryBmp( aQueryImage );
         m_rQueryList.SetDefaultCollapsedEntryBmp( aQueryImage );
diff --git a/dbaccess/source/ui/inc/imageprovider.hxx b/dbaccess/source/ui/inc/imageprovider.hxx
index 0893859..ac73bf7 100644
--- a/dbaccess/source/ui/inc/imageprovider.hxx
+++ b/dbaccess/source/ui/inc/imageprovider.hxx
@@ -29,10 +29,6 @@
 
 namespace dbaui
 {
-
-    // for convenience of our clients
-    namespace DatabaseObject = ::com::sun::star::sdb::application::DatabaseObject;
-
     // ImageProvider
     struct ImageProvider_Data;
     /** provides images for database objects such as tables, queries, forms, reports ...
diff --git a/dbaccess/source/ui/misc/imageprovider.cxx b/dbaccess/source/ui/misc/imageprovider.cxx
index 4529f0e..f0562cc 100644
--- a/dbaccess/source/ui/misc/imageprovider.cxx
+++ b/dbaccess/source/ui/misc/imageprovider.cxx
@@ -45,7 +45,8 @@ namespace dbaui
     using ::com::sun::star::sdbcx::XViewsSupplier;
     using ::com::sun::star::uno::UNO_SET_THROW;
 
-    namespace GraphicColorMode = ::com::sun::star::graphic::GraphicColorMode;
+    namespace GraphicColorMode = css::graphic::GraphicColorMode;
+    namespace DatabaseObject = css::sdb::application::DatabaseObject;
 
     // ImageProvider_Data
     struct ImageProvider_Data
diff --git a/dbaccess/source/ui/querydesign/TableWindow.cxx b/dbaccess/source/ui/querydesign/TableWindow.cxx
index fcbb884..31f354c 100644
--- a/dbaccess/source/ui/querydesign/TableWindow.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindow.cxx
@@ -59,6 +59,8 @@ using namespace ::com::sun::star::container;
 using namespace ::com::sun::star::lang;
 using namespace ::com::sun::star::accessibility;
 
+namespace DatabaseObject = css::sdb::application::DatabaseObject;
+
 #define TABWIN_SIZING_AREA      4
 #define TABWIN_WIDTH_MIN    90
 #define TABWIN_HEIGHT_MIN   80
diff --git a/include/cppu/EnvGuards.hxx b/include/cppu/EnvGuards.hxx
index 3997c46..a64807a 100644
--- a/include/cppu/EnvGuards.hxx
+++ b/include/cppu/EnvGuards.hxx
@@ -24,9 +24,6 @@
 #include <uno/mapping.hxx>
 
 
-namespace cssuno = com::sun::star::uno;
-
-
 namespace cppu
 {
     /** Environment Guard
@@ -38,14 +35,14 @@ namespace cppu
     */
     class EnvGuard
     {
-        cssuno::Environment m_env;
+        css::uno::Environment m_env;
 
     public:
-        explicit EnvGuard(cssuno::Environment const & env)
+        explicit EnvGuard(css::uno::Environment const & env)
         {
             if (env.is())
             {
-                m_env = cssuno::Environment::getCurrent();
+                m_env = css::uno::Environment::getCurrent();
                 env.enter();
             }
         }
@@ -86,11 +83,11 @@ namespace cppu
     */
     class AntiEnvGuard
     {
-        cssuno::Environment m_env;
+        css::uno::Environment m_env;
 
     public:
         explicit AntiEnvGuard()
-            : m_env(cssuno::Environment::getCurrent())
+            : m_env(css::uno::Environment::getCurrent())
         {
             uno_Environment_enter(NULL);
         }
diff --git a/include/cppu/Map.hxx b/include/cppu/Map.hxx
index 2274c9e..2b63979 100644
--- a/include/cppu/Map.hxx
+++ b/include/cppu/Map.hxx
@@ -23,8 +23,6 @@
 #include <uno/mapping.hxx>
 
 
-namespace cssu = com::sun::star::uno;
-
 namespace cppu
 {
     /** Helpers for mapping objects relative to the current environment.
@@ -38,11 +36,11 @@ namespace cppu
         @return           the mapped object
         @since UDK 3.2.7
      */
-    template<class T> inline T * mapOut(T * pT, cssu::Environment const & outerEnv)
+    template<class T> inline T * mapOut(T * pT, css::uno::Environment const & outerEnv)
     {
-        cssu::Mapping curr2outer(cssu::Environment::getCurrent(), outerEnv);
+        css::uno::Mapping curr2outer(css::uno::Environment::getCurrent(), outerEnv);
 
-        return reinterpret_cast<T *>(curr2outer.mapInterface(pT, getCppuType((cssu::Reference<T> *)NULL)));
+        return reinterpret_cast<T *>(curr2outer.mapInterface(pT, getCppuType((css::uno::Reference<T> *)NULL)));
     }
 
 
@@ -53,11 +51,11 @@ namespace cppu
         @return           the mapped object
         @since UDK 3.2.7
      */
-    template<class T> inline T * mapIn(T * pT, cssu::Environment const & outerEnv)
+    template<class T> inline T * mapIn(T * pT, css::uno::Environment const & outerEnv)
     {
-        cssu::Mapping outer2curr(outerEnv, cssu::Environment::getCurrent());
+        css::uno::Mapping outer2curr(outerEnv, css::uno::Environment::getCurrent());
 
-        return reinterpret_cast<T *>(outer2curr.mapInterface(pT, getCppuType((cssu::Reference<T> *)NULL)));
+        return reinterpret_cast<T *>(outer2curr.mapInterface(pT, getCppuType((css::uno::Reference<T> *)NULL)));
     }
 
 
@@ -69,11 +67,11 @@ namespace cppu
         @since UDK 3.2.7
      */
     // Problem: any gets assigned to something, acquire/releases may be called in wrong env.
-    inline void mapOutAny(cssu::Any const & any, cssu::Any * res, cssu::Environment const & outerEnv)
+    inline void mapOutAny(css::uno::Any const & any, css::uno::Any * res, css::uno::Environment const & outerEnv)
     {
-        cssu::Mapping curr2outer(cssu::Environment::getCurrent(), outerEnv);
+        css::uno::Mapping curr2outer(css::uno::Environment::getCurrent(), outerEnv);
 
-        uno_any_destruct(res, (uno_ReleaseFunc)cssu::cpp_release);
+        uno_any_destruct(res, (uno_ReleaseFunc)css::uno::cpp_release);
         uno_type_any_constructAndConvert(
             res,
             const_cast<void *>(any.getValue()),
@@ -89,11 +87,11 @@ namespace cppu
         @param  outerEnv  the source environment
         @since UDK 3.2.7
      */
-    inline void mapInAny(cssu::Any const & any, cssu::Any * res, cssu::Environment const & outerEnv)
+    inline void mapInAny(css::uno::Any const & any, css::uno::Any * res, css::uno::Environment const & outerEnv)
     {
-        cssu::Mapping outer2curr(outerEnv, cssu::Environment::getCurrent());
+        css::uno::Mapping outer2curr(outerEnv, css::uno::Environment::getCurrent());
 
-        uno_any_destruct(res, (uno_ReleaseFunc)cssu::cpp_release);
+        uno_any_destruct(res, (uno_ReleaseFunc)css::uno::cpp_release);
         uno_type_any_constructAndConvert(
             res,
             const_cast<void *>(any.getValue()),


More information about the Libreoffice-commits mailing list