diff options
author | Arnaud VERSINI <arnaud.versini@libreoffice.org> | 2022-07-31 17:42:53 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2022-08-13 09:11:58 +0200 |
commit | 642017c88a303cf10d291d94836564edea9df0d8 (patch) | |
tree | 07bc44c4f00253808c31452979bee2a770a4fa4b /bridges | |
parent | 1c4675580855a638877c90e70489bfae88143f4f (diff) |
bridges/jni : remove useless using and use css instead of com::sun::star
Change-Id: I1b73d68b007ba0dfa54f99ff8f8fea55e94a1ed2
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/137651
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'bridges')
-rw-r--r-- | bridges/source/jni_uno/jni_bridge.cxx | 1 | ||||
-rw-r--r-- | bridges/source/jni_uno/jni_info.cxx | 5 | ||||
-rw-r--r-- | bridges/source/jni_uno/jni_java2uno.cxx | 2 | ||||
-rw-r--r-- | bridges/source/jni_uno/jni_uno2java.cxx | 24 |
4 files changed, 14 insertions, 18 deletions
diff --git a/bridges/source/jni_uno/jni_bridge.cxx b/bridges/source/jni_uno/jni_bridge.cxx index 341c466aa90c..be2e3d37ec12 100644 --- a/bridges/source/jni_uno/jni_bridge.cxx +++ b/bridges/source/jni_uno/jni_bridge.cxx @@ -31,7 +31,6 @@ #include <rtl/strbuf.hxx> #include <uno/lbnames.h> -using namespace ::osl; using namespace ::jni_uno; namespace diff --git a/bridges/source/jni_uno/jni_info.cxx b/bridges/source/jni_uno/jni_info.cxx index 434322f3003c..4fd935987463 100644 --- a/bridges/source/jni_uno/jni_info.cxx +++ b/bridges/source/jni_uno/jni_info.cxx @@ -33,9 +33,6 @@ #include <uno/lbnames.h> -using namespace ::std; -using namespace ::osl; - namespace jni_uno { @@ -942,7 +939,7 @@ JNI_info const * JNI_info::get_jni_info( jni_env, static_cast< jobject >(uno_vm->getClassLoader()), jo_class, jo_forName ); - ClearableMutexGuard g( Mutex::getGlobalMutex() ); + osl::ClearableMutexGuard g( osl::Mutex::getGlobalMutex() ); jni_info = reinterpret_cast< JNI_info const * >( jni->GetStaticLongField( diff --git a/bridges/source/jni_uno/jni_java2uno.cxx b/bridges/source/jni_uno/jni_java2uno.cxx index b6c4c6ea9b35..5edb2b7b3453 100644 --- a/bridges/source/jni_uno/jni_java2uno.cxx +++ b/bridges/source/jni_uno/jni_java2uno.cxx @@ -94,7 +94,7 @@ void Bridge::handle_uno_exc( JNI_context const & jni, uno_Any * uno_exc ) const { #if OSL_DEBUG_LEVEL > 0 // append java stack trace to Message member - static_cast< ::com::sun::star::uno::Exception * >( + static_cast< css::uno::Exception * >( uno_exc->pData )->Message += jni.get_stack_trace(); #endif SAL_INFO( diff --git a/bridges/source/jni_uno/jni_uno2java.cxx b/bridges/source/jni_uno/jni_uno2java.cxx index 8fd38ec31b15..bc908fc5db98 100644 --- a/bridges/source/jni_uno/jni_uno2java.cxx +++ b/bridges/source/jni_uno/jni_uno2java.cxx @@ -84,7 +84,7 @@ void Bridge::handle_java_exc( OUString exc_name( jstring_to_oustring( jni, static_cast<jstring>(jo_class_name.get()) ) ); - ::com::sun::star::uno::TypeDescription td( exc_name.pData ); + css::uno::TypeDescription td( exc_name.pData ); if (!td.is() || (td.get()->eTypeClass != typelib_TypeClass_EXCEPTION)) { // call toString() @@ -107,7 +107,7 @@ void Bridge::handle_java_exc( #if OSL_DEBUG_LEVEL > 0 // patch Message, append stack trace - reinterpret_cast< ::com::sun::star::uno::Exception * >( + reinterpret_cast< css::uno::Exception * >( uno_data.get() )->Message += jni.get_stack_trace( jo_exc.get() ); #endif @@ -137,9 +137,9 @@ void Bridge::call_java( static_cast<JniUnoEnvironmentData *>(m_java_env->pContext)->machine); // assure fully initialized iface_td: - ::com::sun::star::uno::TypeDescription iface_holder; + css::uno::TypeDescription iface_holder; if (! iface_td->aBase.bComplete) { - iface_holder = ::com::sun::star::uno::TypeDescription( + iface_holder = css::uno::TypeDescription( reinterpret_cast<typelib_TypeDescription *>(iface_td) ); iface_holder.makeComplete(); if (! iface_holder.get()->bComplete) { @@ -778,22 +778,22 @@ void UNO_proxy_dispatch( buf.append( ": " ); buf.append( err.m_message ); // binary identical struct - ::com::sun::star::uno::RuntimeException exc( + css::uno::RuntimeException exc( buf.makeStringAndClear(), - ::com::sun::star::uno::Reference< - ::com::sun::star::uno::XInterface >() ); - ::com::sun::star::uno::Type const & exc_type = cppu::UnoType<decltype(exc)>::get(); + css::uno::Reference< + css::uno::XInterface >() ); + css::uno::Type const & exc_type = cppu::UnoType<decltype(exc)>::get(); uno_type_any_construct( *uno_exc, &exc, exc_type.getTypeLibType(), nullptr ); SAL_INFO("bridges", exc.Message); } catch (::jvmaccess::VirtualMachine::AttachGuard::CreationException &) { // binary identical struct - ::com::sun::star::uno::RuntimeException exc( + css::uno::RuntimeException exc( "[jni_uno bridge error] attaching current thread to java failed!", - ::com::sun::star::uno::Reference< - ::com::sun::star::uno::XInterface >() ); - ::com::sun::star::uno::Type const & exc_type = cppu::UnoType<decltype(exc)>::get(); + css::uno::Reference< + css::uno::XInterface >() ); + css::uno::Type const & exc_type = cppu::UnoType<decltype(exc)>::get(); uno_type_any_construct( *uno_exc, &exc, exc_type.getTypeLibType(), nullptr ); SAL_WARN("bridges", exc.Message); } |