Kaydet (Commit) bc7b349e authored tarafından Riccardo Magliocchetti's avatar Riccardo Magliocchetti Kaydeden (comit) Michael Meeks

headless: more work in vcl

Provide HeadlessSalSystem::ShowNativeDialog() instead of having
it if-zeroed.
Then remove LIBO_HEADLESS ifdefery from unx/generic/plugadapt/salplug.cxx
which we are not building anymore.
üst 4cd2af27
...@@ -49,22 +49,20 @@ HeadlessSalInstance::~HeadlessSalInstance() ...@@ -49,22 +49,20 @@ HeadlessSalInstance::~HeadlessSalInstance()
} }
class HeadlessSalSystem : public SvpSalSystem { class HeadlessSalSystem : public SvpSalSystem {
#if 0
public: public:
AndroidSalSystem() : SvpSalSystem() {} HeadlessSalSystem() : SvpSalSystem() {}
virtual ~AndroidSalSystem() {} virtual ~HeadlessSalSystem() {}
virtual int ShowNativeDialog( const rtl::OUString& rTitle, virtual int ShowNativeDialog( const rtl::OUString& rTitle,
const rtl::OUString& rMessage, const rtl::OUString& rMessage,
const std::list< rtl::OUString >& rButtons, const std::list< rtl::OUString >& rButtons,
int nDefButton ) int nDefButton )
{ {
(void)rButtons; (void)nDefButton; (void)rButtons; (void)nDefButton;
__android_log_print(ANDROID_LOG_INFO, "LibreOffice - dialog '%s': '%s'", ::fprintf(stdout, "LibreOffice - dialog '%s': '%s'",
rtl::OUStringToOString(rTitle, RTL_TEXTENCODING_ASCII_US).getStr(), rtl::OUStringToOString(rTitle, RTL_TEXTENCODING_ASCII_US).getStr(),
rtl::OUStringToOString(rMessage, RTL_TEXTENCODING_ASCII_US).getStr()); rtl::OUStringToOString(rMessage, RTL_TEXTENCODING_ASCII_US).getStr());
return 0; return 0;
} }
#endif
}; };
SalSystem *HeadlessSalInstance::CreateSalSystem() SalSystem *HeadlessSalInstance::CreateSalSystem()
......
...@@ -53,7 +53,7 @@ static oslModule pCloseModule = NULL; ...@@ -53,7 +53,7 @@ static oslModule pCloseModule = NULL;
static SalInstance* tryInstance( const OUString& rModuleBase, bool bForce = false ) static SalInstance* tryInstance( const OUString& rModuleBase, bool bForce = false )
{ {
SalInstance* pInst = NULL; SalInstance* pInst = NULL;
#if !defined(ANDROID) || !defined(LIBO_HEADLESS) #if !defined(ANDROID)
// Disable gtk3 plugin load except in experimental mode for now. // Disable gtk3 plugin load except in experimental mode for now.
if( !bForce && if( !bForce &&
rModuleBase.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "gtk3" ) ) && rModuleBase.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM( "gtk3" ) ) &&
...@@ -129,7 +129,7 @@ static SalInstance* tryInstance( const OUString& rModuleBase, bool bForce = fals ...@@ -129,7 +129,7 @@ static SalInstance* tryInstance( const OUString& rModuleBase, bool bForce = fals
return pInst; return pInst;
} }
#if !defined(ANDROID) || !defined(LIBO_HEADLESS) #if !defined(ANDROID)
static DesktopType get_desktop_environment() static DesktopType get_desktop_environment()
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment