[Libreoffice-commits] .: cli_ure/source

Libreoffice Gerrit user logerrit at kemper.freedesktop.org
Mon Oct 8 04:30:15 PDT 2012


 cli_ure/source/uno_bridge/cli_bridge.cxx |    4 ++--
 cli_ure/source/uno_bridge/cli_data.cxx   |   10 +++++-----
 cli_ure/source/uno_bridge/cli_proxy.cxx  |    8 ++++----
 cli_ure/source/uno_bridge/cli_uno.cxx    |    2 +-
 4 files changed, 12 insertions(+), 12 deletions(-)

New commits:
commit 1b66ced2367353ad42a14bfc76ca1853c4935d6a
Author: Tor Lillqvist <tlillqvist at suse.com>
Date:   Mon Oct 8 14:27:13 2012 +0300

    Managed C++ to C++/CLI conversion also for the debug code
    
    Change-Id: Ibb4f5e386644a67905421d2f9c33336a119fca88

diff --git a/cli_ure/source/uno_bridge/cli_bridge.cxx b/cli_ure/source/uno_bridge/cli_bridge.cxx
index 12b432e..6da6cdf 100644
--- a/cli_ure/source/uno_bridge/cli_bridge.cxx
+++ b/cli_ure/source/uno_bridge/cli_bridge.cxx
@@ -276,8 +276,8 @@ SAL_DLLPUBLIC_EXPORT void SAL_CALL uno_initEnvironment( uno_Environment * uno_cl
     uno_cli_env->pExtEnv = 0;
     //Set the console to print Trace messages
 #if OSL_DEBUG_LEVEL >= 1
-    System::Diagnostics::Trace::get_Listeners()->
-            Add( new System::Diagnostics::TextWriterTraceListener(System::Console::get_Out()));
+    System::Diagnostics::Trace::Listeners->
+            Add( gcnew System::Diagnostics::TextWriterTraceListener(System::Console::Out));
 #endif
     OSL_ASSERT( 0 == uno_cli_env->pContext );
 
diff --git a/cli_ure/source/uno_bridge/cli_data.cxx b/cli_ure/source/uno_bridge/cli_data.cxx
index 3a0eb80..935a90b 100644
--- a/cli_ure/source/uno_bridge/cli_data.cxx
+++ b/cli_ure/source/uno_bridge/cli_data.cxx
@@ -1584,7 +1584,7 @@ void Bridge::map_to_cli(
      {
          if (info != nullptr)
          {
-             OSL_ASSERT(info->get_IsByRef());
+             OSL_ASSERT(info->IsByRef);
              info= info->GetElementType();
              *cli_data= System::Enum::ToObject(info, *(System::Int32*) uno_data);
          }
@@ -1661,10 +1661,10 @@ void Bridge::map_to_cli(
                     ctorInfo = arCtorInfo[i];
                     break;
                 }
-                OSL_ASSERT(arParamInfo[0]->get_ParameterType()->Equals(__typeof(System::String))
-                    && arParamInfo[1]->get_ParameterType()->Equals(__typeof(System::Object))
-                    && arParamInfo[0]->get_Position() == 0
-                    && arParamInfo[1]->get_Position() == 1);
+                OSL_ASSERT(arParamInfo[0]->ParameterType->Equals(System::String::typeid)
+                    && arParamInfo[1]->ParameterType->Equals(System::Object::typeid)
+                    && arParamInfo[0]->Position == 0
+                    && arParamInfo[1]->Position == 1);
                 //Prepare parameters for constructor
                 int numArgs = arParamInfo->Length;
                 array<System::Object^>^ args = gcnew array<System::Object^>(numArgs);
diff --git a/cli_ure/source/uno_bridge/cli_proxy.cxx b/cli_ure/source/uno_bridge/cli_proxy.cxx
index 1e6ede2..808e5fe 100644
--- a/cli_ure/source/uno_bridge/cli_proxy.cxx
+++ b/cli_ure/source/uno_bridge/cli_proxy.cxx
@@ -285,10 +285,10 @@ bool UnoInterfaceProxy::CanCastTo(System::Type^ fromType,
                 UnoInterfaceProxy ^ proxy =
                     static_cast< UnoInterfaceProxy ^ >(
                         srr::RemotingServices::GetRealProxy( obj ) );
-                OSL_ASSERT( 0 != proxy->findInfo( fromType ) );
+                OSL_ASSERT( nullptr != proxy->findInfo( fromType ) );
                 m_listAdditionalProxies->Add( proxy );
                 m_nlistAdditionalProxies = m_listAdditionalProxies->Count;
-                OSL_ASSERT( 0 != findInfo( fromType ) );
+                OSL_ASSERT( nullptr != findInfo( fromType ) );
                 return true;
             }
         }
@@ -337,7 +337,7 @@ srrm::IMessage^ UnoInterfaceProxy::invokeObject(
     if (m_Equals_String->Equals(sMethod))
     {
         // Object.Equals
-        OSL_ASSERT(args->get_Length() == 1);
+        OSL_ASSERT(args->Length == 1);
         srrp::RealProxy^ rProxy = srr::RemotingServices::GetRealProxy(args[0]);
         bool bDone = false;
         if (rProxy)
@@ -433,7 +433,7 @@ srrm::IMessage^ UnoInterfaceProxy::Invoke(srrm::IMessage^ callmsg)
 
         System::Type^ typeBeingCalled = loadCliType(sTypeName);
         UnoInterfaceInfo^ info = findInfo( typeBeingCalled );
-        OSL_ASSERT( 0 != info );
+        OSL_ASSERT( nullptr != info );
 
         // ToDo do without string conversion, a OUString is not needed here
         // get the type description of the call
diff --git a/cli_ure/source/uno_bridge/cli_uno.cxx b/cli_ure/source/uno_bridge/cli_uno.cxx
index 0ada41d..e72b865 100644
--- a/cli_ure/source/uno_bridge/cli_uno.cxx
+++ b/cli_ure/source/uno_bridge/cli_uno.cxx
@@ -78,7 +78,7 @@ System::Object^ Bridge::call_uno(uno_Interface * pUnoI,
         uno_ret = (mem + (nParams * sizeof (void *)));
     largest * uno_args_mem = (largest *)(mem + (nParams * sizeof (void *)) + return_size);
 
-    OSL_ASSERT( (0 == nParams) || (nParams == args->get_Length()) );
+    OSL_ASSERT( (0 == nParams) || (nParams == args->Length) );
     for ( sal_Int32 nPos = 0; nPos < nParams; ++nPos )
     {
         typelib_MethodParameter const & param = pParams[ nPos ];


More information about the Libreoffice-commits mailing list