diff options
author | Jan-Marek Glogowski <glogow@fbihome.de> | 2016-09-01 14:32:01 +0200 |
---|---|---|
committer | Jan-Marek Glogowski <glogow@fbihome.de> | 2016-09-23 23:25:48 +0200 |
commit | 06283e7b00f9f7b7ad1a3e30d2dcb85c8d550588 (patch) | |
tree | 94a0d9797f1717a5f6ac18e55882d97decedffe8 /vcl/unx/kde | |
parent | 3bc2b8c5e0c4213b53a974944189bdf7f8155502 (diff) |
tdf#101822 X11 SalDisplay init => AfterAppInit
This fixes all X11 based VCL plugins to move display
initialization into AfterAppInit (gen, TDE, KDE4),
This is done by moving input method and display into
SalXLib, so they are available in AfterAppInit.
Otherwise the configmgr service won't be available in
SalDisplay::BestVisual.
Change-Id: I9380075b9770bceb8f453bbcb7fe31291634ff89
Diffstat (limited to 'vcl/unx/kde')
-rw-r--r-- | vcl/unx/kde/kdedata.cxx | 11 | ||||
-rw-r--r-- | vcl/unx/kde/salnativewidgets-kde.cxx | 6 |
2 files changed, 9 insertions, 8 deletions
diff --git a/vcl/unx/kde/kdedata.cxx b/vcl/unx/kde/kdedata.cxx index f136cc60f293..71955f5a764c 100644 --- a/vcl/unx/kde/kdedata.cxx +++ b/vcl/unx/kde/kdedata.cxx @@ -104,8 +104,8 @@ KDEXLib::~KDEXLib() void KDEXLib::Init() { - SalI18N_InputMethod* pInputMethod = new SalI18N_InputMethod; - pInputMethod->SetLocale(); + m_pInputMethod = new SalI18N_InputMethod; + m_pInputMethod->SetLocale(); XrmInitialize(); KAboutData *kAboutData = new KAboutData( "LibreOffice", @@ -163,12 +163,7 @@ void KDEXLib::Init() m_pApplication = new VCLKDEApplication(); kapp->disableSessionManagement(); - Display* pDisp = QPaintDevice::x11AppDisplay(); - - SalX11Display *pSalDisplay = new SalKDEDisplay( pDisp ); - - pInputMethod->CreateMethod( pDisp ); - pSalDisplay->SetupInput( pInputMethod ); + m_pDisplay = QPaintDevice::x11AppDisplay(); } void KDEXLib::doStartup() diff --git a/vcl/unx/kde/salnativewidgets-kde.cxx b/vcl/unx/kde/salnativewidgets-kde.cxx index 6fd0de51afe7..77fd622d1fa3 100644 --- a/vcl/unx/kde/salnativewidgets-kde.cxx +++ b/vcl/unx/kde/salnativewidgets-kde.cxx @@ -27,6 +27,7 @@ #include <unx/salgdi.h> #include <unx/kde/kdedata.hxx> #include "unx/pixmap.hxx" +#include <unx/i18n_im.hxx> #include <vcl/settings.hxx> #include "unx/fontmanager.hxx" @@ -2106,6 +2107,11 @@ uno::Reference< ui::dialogs::XFilePicker2 > KDESalInstance::createFilePicker( new UnxFilePicker( xMSF ) ); } +SalX11Display* KDESalInstance::CreateDisplay() const +{ + return new SalKDEDisplay( QPaintDevice::x11AppDisplay() ); +} + // KDESalData pieces // Create the widget painter so we have some control over |