diff options
author | Michael Meeks <michael.meeks@suse.com> | 2012-01-20 09:44:26 +0000 |
---|---|---|
committer | Michael Meeks <michael.meeks@suse.com> | 2012-01-20 10:20:13 +0000 |
commit | d45b38c9e332b184d3e61b38403c0e867ab6653b (patch) | |
tree | ac1b9ce2d223a4ba9601661345fcb55d03f48f4e | |
parent | a0ce2a2f7a8533fd2ea6cd4a05e250a32f609ed7 (diff) |
android: add missing VCL init symbol goodness
-rw-r--r-- | vcl/Library_vcl.mk | 17 | ||||
-rw-r--r-- | vcl/android/androidinst.cxx | 55 |
2 files changed, 70 insertions, 2 deletions
diff --git a/vcl/Library_vcl.mk b/vcl/Library_vcl.mk index 647bb2edb2c8..39836080935b 100644 --- a/vcl/Library_vcl.mk +++ b/vcl/Library_vcl.mk @@ -458,11 +458,26 @@ $(eval $(call gb_Library_add_exception_objects,vcl,\ vcl/generic/fontmanager/fontmanager \ vcl/generic/fontmanager/helper \ vcl/generic/fontmanager/parseAFM \ - vcl/android/androidinst \ vcl/unx/generic/printer/jobdata \ vcl/unx/generic/printer/ppdparser \ vcl/null/printerinfomanager \ + vcl/android/androidinst \ + vcl/headless/svpbmp \ + vcl/headless/svpdummies \ + vcl/headless/svpelement \ + vcl/headless/svpframe \ + vcl/headless/svpgdi \ + vcl/headless/svpinst \ + vcl/headless/svpdata \ + vcl/headless/svpprn \ + vcl/headless/svptext \ + vcl/headless/svpvd \ +)) + +$(eval $(call gb_Library_add_linked_libs,vcl,\ + basebmp \ )) + $(eval $(call gb_Library_use_externals,vcl,\ fontconfig \ freetype \ diff --git a/vcl/android/androidinst.cxx b/vcl/android/androidinst.cxx index 3ce5d5b8c6d0..6a1bbcd7a7a5 100644 --- a/vcl/android/androidinst.cxx +++ b/vcl/android/androidinst.cxx @@ -52,9 +52,14 @@ public: int nDefButton ) { (void)rButtons; (void)nDefButton; +#if 0 __android_log_print(ANDROID_LOG_INFO, "LibreOffice - dialog '%s': '%s'", rtl::OUStringToOString(rTitle, RTL_TEXTENCODING_ASCII_US).getStr(), rtl::OUStringToOString(rMessage, RTL_TEXTENCODING_ASCII_US).getStr()); +#endif + fprintf (stderr, "LibreOffice - dialog '%s': '%s'", + rtl::OUStringToOString(rTitle, RTL_TEXTENCODING_ASCII_US).getStr(), + rtl::OUStringToOString(rMessage, RTL_TEXTENCODING_ASCII_US).getStr()); return 0; } }; @@ -74,9 +79,57 @@ public: SalInstance *CreateSalInstance() { - SvpSalInstance* pInstance = new SvpSalInstance( new SalYieldMutex() ); + AndroidSalInstance* pInstance = new AndroidSalInstance( new SalYieldMutex() ); new AndroidSalData( pInstance ); return pInstance; } +void DestroySalInstance( SalInstance *pInst ) +{ + pInst->ReleaseYieldMutex(); + delete pInst; +} + +// All the interesting stuff is slaved from the AndroidSalInstance +void InitSalData() {} +void DeInitSalData() {} +void InitSalMain() {} +void DeInitSalMain() {} + +void SalAbort( const rtl::OUString& rErrorText, bool bDumpCore ) +{ + rtl::OUString aError( rErrorText ); + if( aError.isEmpty() ) + aError = rtl::OUString::createFromAscii("Unknown application error"); + ::fprintf( stderr, "%s\n", rtl::OUStringToOString(rErrorText, osl_getThreadTextEncoding()).getStr() ); + +#if 0 + __android_log_print(ANDROID_LOG_INFO, "SalAbort: '%s'", + rtl::OUStringToOString(aError, RTL_TEXTENCODING_ASCII_US).getStr()); +#endif + fprintf( stderr, "SalAbort: '%s'", + rtl::OUStringToOString(aError, RTL_TEXTENCODING_ASCII_US).getStr() ); + if( bDumpCore ) + abort(); + else + _exit(1); +} + +const OUString& SalGetDesktopEnvironment() +{ + static rtl::OUString aEnv( RTL_CONSTASCII_USTRINGPARAM( "android" ) ); + return aEnv; +} + +SalData::SalData() : + m_pInstance( 0 ), + m_pPlugin( 0 ), + m_pPIManager(0 ) +{ +} + +SalData::~SalData() +{ +} + /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ |