[Libreoffice-commits] .: vcl/inc vcl/unx

Caolán McNamara caolan at kemper.freedesktop.org
Mon Sep 5 08:39:29 PDT 2011


 vcl/inc/unx/i18n_cb.hxx             |    1 
 vcl/inc/unx/i18n_ic.hxx             |    2 
 vcl/inc/unx/i18n_im.hxx             |    3 
 vcl/unx/generic/app/i18n_cb.cxx     |  163 +++++++++++++++---------------------
 vcl/unx/generic/app/i18n_ic.cxx     |   34 -------
 vcl/unx/generic/app/i18n_im.cxx     |   83 ------------------
 vcl/unx/generic/app/saldata.cxx     |    1 
 vcl/unx/generic/window/salframe.cxx |    7 -
 vcl/unx/kde/kdedata.cxx             |    1 
 vcl/unx/kde4/KDEXLib.cxx            |    1 
 10 files changed, 71 insertions(+), 225 deletions(-)

New commits:
commit 8b0287543d87659fd4bfde5edb6725ee5da5f80e
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Mon Sep 5 16:36:22 2011 +0100

    These multi-lingual IMs have been always disabled for Linux
    
    Where not-Linux was in practice solaris. We can be pretty sure that the
    ismultlingual path is effectively unused. so following that chain of logic
    quite a bit can go.

diff --git a/vcl/inc/unx/i18n_cb.hxx b/vcl/inc/unx/i18n_cb.hxx
index 43b7661..7b16a7d 100644
--- a/vcl/inc/unx/i18n_cb.hxx
+++ b/vcl/inc/unx/i18n_cb.hxx
@@ -86,7 +86,6 @@ typedef enum {
 
 typedef struct {
     SalFrame*               pFrame;
-    Bool                    bIsMultilingual;
     preedit_status_t        eState;
     preedit_text_t          aText;
     SalExtTextInputEvent    aInputEv;
diff --git a/vcl/inc/unx/i18n_ic.hxx b/vcl/inc/unx/i18n_ic.hxx
index b038d17..3a9c5ab 100644
--- a/vcl/inc/unx/i18n_ic.hxx
+++ b/vcl/inc/unx/i18n_ic.hxx
@@ -38,7 +38,6 @@ class SalI18N_InputContext
 private:
 
     Bool    mbUseable; // system supports current locale ?
-    Bool    mbMultiLingual; // system supports iiimp ?
     XIC     maContext;
 
     XIMStyle mnSupportedStatusStyle;
@@ -66,7 +65,6 @@ private:
 public:
 
     Bool UseContext()       { return mbUseable; }
-    Bool IsMultiLingual()   { return mbMultiLingual; }
     Bool IsPreeditMode()    { return maClientData.eState == ePreeditStatusActive; }
     XIC  GetContext()       { return maContext; }
 
diff --git a/vcl/inc/unx/i18n_im.hxx b/vcl/inc/unx/i18n_im.hxx
index e363a47..39e1cb7 100644
--- a/vcl/inc/unx/i18n_im.hxx
+++ b/vcl/inc/unx/i18n_im.hxx
@@ -39,14 +39,12 @@ class VCLPLUG_GEN_PUBLIC SalI18N_InputMethod
 {
     Bool        mbUseable;  // system supports locale as well as status
                             // and preedit style ?
-    Bool        mbMultiLingual; // system supports iiimp
     XIM         maMethod;
     XIMCallback maDestroyCallback;
     XIMStyles  *mpStyles;
 
 public:
 
-    Bool        IsMultiLingual()        { return mbMultiLingual;    }
     Bool        PosixLocale();
     Bool        UseMethod()             { return mbUseable; }
     XIM         GetMethod()             { return maMethod;  }
@@ -55,7 +53,6 @@ public:
     XIMStyles  *GetSupportedStyles()    { return mpStyles;  }
     Bool        SetLocale( const char* pLocale = "" );
     Bool        FilterEvent( XEvent *pEvent, XLIB_Window window );
-    Bool        AddConnectionWatch (Display *pDisplay, void *pConnectionHandler);
 
     SalI18N_InputMethod();
     ~SalI18N_InputMethod();
diff --git a/vcl/unx/generic/app/i18n_cb.cxx b/vcl/unx/generic/app/i18n_cb.cxx
index d0cf39f..8284931 100644
--- a/vcl/unx/generic/app/i18n_cb.cxx
+++ b/vcl/unx/generic/app/i18n_cb.cxx
@@ -164,100 +164,91 @@ enlarge_buffer ( preedit_text_t *ptext, int nnewlimit )
 //
 
 void
-Preedit_InsertText(preedit_text_t *pText, XIMText *pInsertText, int where,
-           Bool isMultilingual)
+Preedit_InsertText(preedit_text_t *pText, XIMText *pInsertText, int where)
 {
-      sal_Unicode *pInsertTextString;
-      int nInsertTextLength = 0;
-      XIMFeedback *pInsertTextCharStyle = pInsertText->feedback;
+    sal_Unicode *pInsertTextString;
+    int nInsertTextLength = 0;
+    XIMFeedback *pInsertTextCharStyle = pInsertText->feedback;
 
-      nInsertTextLength = pInsertText->length;
+    nInsertTextLength = pInsertText->length;
 
-      if (isMultilingual)
+    //  can't handle wchar_t strings, so convert to multibyte chars first
+    char *pMBString;
+    size_t nMBLength;
+    if (pInsertText->encoding_is_wchar)
     {
-        XIMUnicodeText *pUniText = (XIMUnicodeText*)pInsertText;
-        pInsertTextString = pUniText->string.utf16_char;
-      }
+        wchar_t *pWCString = pInsertText->string.wide_char;
+          size_t nBytes = wcstombs ( NULL, pWCString, 1024 /* dont care */);
+          pMBString = (char*)alloca( nBytes + 1 );
+          nMBLength = wcstombs ( pMBString, pWCString, nBytes + 1);
+    }
     else
     {
-        //  can't handle wchar_t strings, so convert to multibyte chars first
-        char *pMBString;
-        size_t nMBLength;
-        if (pInsertText->encoding_is_wchar)
-        {
-            wchar_t *pWCString = pInsertText->string.wide_char;
-              size_t nBytes = wcstombs ( NULL, pWCString, 1024 /* dont care */);
-              pMBString = (char*)alloca( nBytes + 1 );
-              nMBLength = wcstombs ( pMBString, pWCString, nBytes + 1);
-        }
-        else
-        {
-              pMBString = pInsertText->string.multi_byte;
-              nMBLength = strlen(pMBString); // xxx
-        }
+          pMBString = pInsertText->string.multi_byte;
+          nMBLength = strlen(pMBString); // xxx
+    }
 
-        // convert multibyte chars to unicode
-        rtl_TextEncoding nEncoding = osl_getThreadTextEncoding();
+    // convert multibyte chars to unicode
+    rtl_TextEncoding nEncoding = osl_getThreadTextEncoding();
 
-        if (nEncoding != RTL_TEXTENCODING_UNICODE)
-        {
-              rtl_TextToUnicodeConverter aConverter =
-                    rtl_createTextToUnicodeConverter( nEncoding );
-              rtl_TextToUnicodeContext aContext =
-                    rtl_createTextToUnicodeContext(aConverter);
+    if (nEncoding != RTL_TEXTENCODING_UNICODE)
+    {
+          rtl_TextToUnicodeConverter aConverter =
+                rtl_createTextToUnicodeConverter( nEncoding );
+          rtl_TextToUnicodeContext aContext =
+                rtl_createTextToUnicodeContext(aConverter);
 
-              sal_Size nBufferSize = nInsertTextLength * 2;
+          sal_Size nBufferSize = nInsertTextLength * 2;
 
-              pInsertTextString = (sal_Unicode*)alloca(nBufferSize);
+          pInsertTextString = (sal_Unicode*)alloca(nBufferSize);
 
-              sal_uInt32  nConversionInfo;
-              sal_Size    nConvertedChars;
+          sal_uInt32  nConversionInfo;
+          sal_Size    nConvertedChars;
 
-            rtl_convertTextToUnicode( aConverter, aContext,
-                    pMBString, nMBLength,
-                     pInsertTextString, nBufferSize,
-                      RTL_TEXTTOUNICODE_FLAGS_UNDEFINED_IGNORE
-                    | RTL_TEXTTOUNICODE_FLAGS_INVALID_IGNORE,
-                    &nConversionInfo, &nConvertedChars );
+        rtl_convertTextToUnicode( aConverter, aContext,
+                pMBString, nMBLength,
+                 pInsertTextString, nBufferSize,
+                  RTL_TEXTTOUNICODE_FLAGS_UNDEFINED_IGNORE
+                | RTL_TEXTTOUNICODE_FLAGS_INVALID_IGNORE,
+                &nConversionInfo, &nConvertedChars );
 
-              rtl_destroyTextToUnicodeContext(aConverter, aContext);
-              rtl_destroyTextToUnicodeConverter(aConverter);
+          rtl_destroyTextToUnicodeContext(aConverter, aContext);
+          rtl_destroyTextToUnicodeConverter(aConverter);
 
-        }
-        else
-        {
-              pInsertTextString = (sal_Unicode*)pMBString;
-        }
-      }
+    }
+    else
+    {
+          pInsertTextString = (sal_Unicode*)pMBString;
+    }
 
-      // enlarge target text-buffer if necessary
-      if (pText->nSize <= (pText->nLength + nInsertTextLength))
-        enlarge_buffer(pText, pText->nLength + nInsertTextLength);
+    // enlarge target text-buffer if necessary
+    if (pText->nSize <= (pText->nLength + nInsertTextLength))
+      enlarge_buffer(pText, pText->nLength + nInsertTextLength);
 
-      // insert text: displace old mem and put new bytes in
-      int from    = where;
-      int to      = where + nInsertTextLength;
-      int howmany = pText->nLength - where;
+    // insert text: displace old mem and put new bytes in
+    int from    = where;
+    int to      = where + nInsertTextLength;
+    int howmany = pText->nLength - where;
 
-      memmove((void*)(pText->pUnicodeBuffer + to),
-            (void*)(pText->pUnicodeBuffer + from),
-              howmany * sizeof(sal_Unicode));
-      memmove((void*)(pText->pCharStyle + to),
-              (void*)(pText->pCharStyle + from),
-              howmany * sizeof(XIMFeedback));
+    memmove((void*)(pText->pUnicodeBuffer + to),
+          (void*)(pText->pUnicodeBuffer + from),
+            howmany * sizeof(sal_Unicode));
+    memmove((void*)(pText->pCharStyle + to),
+            (void*)(pText->pCharStyle + from),
+            howmany * sizeof(XIMFeedback));
 
-      to = from;
-      howmany = nInsertTextLength;
+    to = from;
+    howmany = nInsertTextLength;
 
-      memcpy((void*)(pText->pUnicodeBuffer + to), (void*)pInsertTextString,
-             howmany * sizeof(sal_Unicode));
-      memcpy((void*)(pText->pCharStyle + to), (void*)pInsertTextCharStyle,
-              howmany * sizeof(XIMFeedback));
+    memcpy((void*)(pText->pUnicodeBuffer + to), (void*)pInsertTextString,
+           howmany * sizeof(sal_Unicode));
+    memcpy((void*)(pText->pCharStyle + to), (void*)pInsertTextCharStyle,
+            howmany * sizeof(XIMFeedback));
 
-      pText->nLength += howmany;
+    pText->nLength += howmany;
 
-      // NULL-terminate the string
-      pText->pUnicodeBuffer[pText->nLength] = (sal_Unicode)0;
+    // NULL-terminate the string
+    pText->pUnicodeBuffer[pText->nLength] = (sal_Unicode)0;
 }
 
 //
@@ -372,7 +363,7 @@ PreeditDrawCallback(XIC ic, XPointer client_data,
             && (call_data->text->string.wide_char != NULL))
         {
               Preedit_InsertText(&(pPreeditData->aText), call_data->text,
-                     call_data->chg_first, pPreeditData->bIsMultilingual);
+                     call_data->chg_first);
         }
         else
           // handle text replacement by deletion and insertion of text,
@@ -383,7 +374,7 @@ PreeditDrawCallback(XIC ic, XPointer client_data,
             Preedit_DeleteText(&(pPreeditData->aText),
                        call_data->chg_first, call_data->chg_length);
             Preedit_InsertText(&(pPreeditData->aText), call_data->text,
-                       call_data->chg_first, pPreeditData->bIsMultilingual);
+                       call_data->chg_first);
           }
         else
         // not really a text update, only attributes are concerned
@@ -567,27 +558,9 @@ StatusDoneCallback (XIC, XPointer, XPointer)
 }
 
 void
-StatusDrawCallback (XIC ic, XPointer client_data, XIMStatusDrawCallbackStruct *call_data)
+StatusDrawCallback (XIC, XPointer, XIMStatusDrawCallbackStruct *call_data)
 {
-      preedit_data_t* pPreeditData = (preedit_data_t*)client_data;
-    if( pPreeditData->bIsMultilingual )
-    {
-        // IIIMP
-        XIMUnicodeText *cbtext = (XIMUnicodeText *)call_data->data.text;
-        ::vcl::I18NStatus::get().setStatusText( String( cbtext->string.utf16_char, call_data->data.text->length ) );
-        XIMUnicodeCharacterSubset* pSubset = NULL;
-        if( ! XGetICValues( ic,
-                            XNUnicodeCharacterSubset, & pSubset,
-                            NULL )
-            && pSubset )
-        {
-            ::vcl::I18NStatus::get().changeIM( String( ByteString( pSubset->name ), RTL_TEXTENCODING_UTF8 ) );
-#if OSL_DEBUG_LEVEL > 1
-            fprintf( stderr, "got XNUnicodeCharacterSubset\n   %d\n   %d\n   %s\n   %d\n", pSubset->index, pSubset->subset_id, pSubset->name, pSubset->is_active );
-#endif
-        }
-    }
-    else if( call_data->type == XIMTextType )
+    if( call_data->type == XIMTextType )
     {
         String aText;
         if( call_data->data.text )
diff --git a/vcl/unx/generic/app/i18n_ic.cxx b/vcl/unx/generic/app/i18n_ic.cxx
index 8a8b5d6..bb9b92a 100644
--- a/vcl/unx/generic/app/i18n_ic.cxx
+++ b/vcl/unx/generic/app/i18n_ic.cxx
@@ -187,7 +187,6 @@ SalI18N_InputContext::SalI18N_InputContext ( SalFrame *pFrame ) :
 
     SalI18N_InputMethod *pInputMethod;
     pInputMethod = GetX11SalData()->GetDisplay()->GetInputMethod();
-    mbMultiLingual = pInputMethod->IsMultiLingual();
 
     mnSupportedPreeditStyle =   XIMPreeditCallbacks | XIMPreeditPosition
         | XIMPreeditNothing   | XIMPreeditNone;
@@ -200,7 +199,6 @@ SalI18N_InputContext::SalI18N_InputContext ( SalFrame *pFrame ) :
 
         // for status callbacks and commit string callbacks
 #define PREEDIT_BUFSZ 16
-        maClientData.bIsMultilingual        = mbMultiLingual;
         maClientData.eState                 = ePreeditStatusStartPending;
         maClientData.pFrame                 = pFrame;
         maClientData.aText.pUnicodeBuffer   =
@@ -359,7 +357,6 @@ SalI18N_InputContext::SalI18N_InputContext ( SalFrame *pFrame ) :
 #endif
 
         mbUseable = False;
-        mbMultiLingual = False;
 
         if ( mpAttributes != NULL )
             XFree( mpAttributes );
@@ -379,17 +376,6 @@ SalI18N_InputContext::SalI18N_InputContext ( SalFrame *pFrame ) :
         maClientData.aText.pCharStyle     = NULL;
     }
 
-    if ( maContext != NULL && mbMultiLingual )
-    {
-        maCommitStringCallback.callback    = (XIMProc)::CommitStringCallback;
-        maCommitStringCallback.client_data = (XPointer)&maClientData;
-        maSwitchIMCallback.callback        = (XIMProc)::SwitchIMCallback;
-        maSwitchIMCallback.client_data     = (XPointer)&maClientData;
-        XSetICValues( maContext,
-                      XNCommitStringCallback, &maCommitStringCallback,
-                      XNSwitchIMNotifyCallback, &maSwitchIMCallback,
-                      NULL );
-    }
     if ( maContext != NULL)
     {
         maDestroyCallback.callback    = (XIMProc)IC_IMDestroyCallback;
@@ -398,21 +384,6 @@ SalI18N_InputContext::SalI18N_InputContext ( SalFrame *pFrame ) :
                       XNDestroyCallback,      &maDestroyCallback,
                       NULL );
     }
-
-    if( mbMultiLingual )
-    {
-        // set initial IM status
-        XIMUnicodeCharacterSubset* pSubset = NULL;
-        if( ! XGetICValues( maContext,
-                            XNUnicodeCharacterSubset, & pSubset,
-                            NULL )
-            && pSubset )
-        {
-            String aCurrent( ByteString( pSubset->name ), RTL_TEXTENCODING_UTF8 );
-            ::vcl::I18NStatus::get().changeIM( aCurrent );
-            ::vcl::I18NStatus::get().setStatusText( aCurrent );
-        }
-    }
 }
 
 // ---------------------------------------------------------------------------
@@ -454,11 +425,6 @@ SalI18N_InputContext::Map( SalFrame *pFrame )
                 maContext = XCreateIC( pInputMethod->GetMethod(),
                                        XNVaNestedList, mpAttributes,
                                        NULL );
-                if ( maContext != NULL && mbMultiLingual )
-                    XSetICValues( maContext,
-                                  XNCommitStringCallback, &maCommitStringCallback,
-                                  XNSwitchIMNotifyCallback, &maSwitchIMCallback,
-                                  NULL );
             }
             if( maClientData.pFrame != pFrame )
                 SetICFocus( pFrame );
diff --git a/vcl/unx/generic/app/i18n_im.cxx b/vcl/unx/generic/app/i18n_im.cxx
index 5d30d74..76d0c93 100644
--- a/vcl/unx/generic/app/i18n_im.cxx
+++ b/vcl/unx/generic/app/i18n_im.cxx
@@ -268,8 +268,6 @@ SalI18N_InputMethod::SetLocale( const char* pLocale )
 Bool
 SalI18N_InputMethod::PosixLocale()
 {
-    if (mbMultiLingual)
-        return False;
     if (maMethod)
         return IsPosixLocale (XLocaleOfIM (maMethod));
     return False;
@@ -282,7 +280,6 @@ SalI18N_InputMethod::PosixLocale()
 // ------------------------------------------------------------------------
 
 SalI18N_InputMethod::SalI18N_InputMethod( ) : mbUseable( bUseInputMethodDefault ),
-                                              mbMultiLingual( False ),
                                               maMethod( (XIM)NULL ),
                                                 mpStyles( (XIMStyles*)NULL )
 {
@@ -376,58 +373,7 @@ SalI18N_InputMethod::CreateMethod ( Display *pDisplay )
 {
     if ( mbUseable )
     {
-        const bool bTryMultiLingual =
-        #ifdef LINUX
-                        false;
-        #else
-                        true;
-        #endif
-        if ( bTryMultiLingual && getenv("USE_XOPENIM") == NULL )
-        {
-            mbMultiLingual = True; // set ml-input flag to create input-method
-            maMethod = XvaOpenIM(pDisplay, NULL, NULL, NULL,
-                    XNMultiLingualInput, mbMultiLingual, /* dummy */
-                     (void *)0);
-            // get ml-input flag from input-method
-            if ( maMethod == (XIM)NULL )
-                mbMultiLingual = False;
-            else
-            if ( XGetIMValues(maMethod,
-                    XNMultiLingualInput, &mbMultiLingual, NULL ) != NULL )
-                mbMultiLingual = False;
-            if( mbMultiLingual )
-            {
-                XIMUnicodeCharacterSubsets* subsets;
-                if( XGetIMValues( maMethod,
-                                  XNQueryUnicodeCharacterSubset, &subsets, NULL ) == NULL )
-                {
-#if OSL_DEBUG_LEVEL > 1
-                    fprintf( stderr, "IM reports %d subsets: ", subsets->count_subsets );
-#endif
-                    I18NStatus& rStatus( I18NStatus::get() );
-                    rStatus.clearChoices();
-                    for( int i = 0; i < subsets->count_subsets; i++ )
-                    {
-#if OSL_DEBUG_LEVEL > 1
-                        fprintf( stderr,"\"%s\" ", subsets->supported_subsets[i].name );
-#endif
-                        rStatus.addChoice( String( subsets->supported_subsets[i].name, RTL_TEXTENCODING_UTF8 ), &subsets->supported_subsets[i] );
-                    }
-#if OSL_DEBUG_LEVEL > 1
-                    fprintf( stderr, "\n" );
-#endif
-                }
-#if OSL_DEBUG_LEVEL > 1
-                else
-                    fprintf( stderr, "query subsets failed\n" );
-#endif
-            }
-        }
-        else
-        {
-            maMethod = XOpenIM(pDisplay, NULL, NULL, NULL);
-            mbMultiLingual = False;
-        }
+        maMethod = XOpenIM(pDisplay, NULL, NULL, NULL);
 
         if ((maMethod == (XIM)NULL) && (getenv("XMODIFIERS") != NULL))
         {
@@ -435,7 +381,6 @@ SalI18N_InputMethod::CreateMethod ( Display *pDisplay )
                 osl_clearEnvironment(envVar.pData);
                 XSetLocaleModifiers("");
                 maMethod = XOpenIM(pDisplay, NULL, NULL, NULL);
-                mbMultiLingual = False;
         }
 
         if ( maMethod != (XIM)NULL )
@@ -444,8 +389,7 @@ SalI18N_InputMethod::CreateMethod ( Display *pDisplay )
                 != NULL)
                 mbUseable = False;
             #if OSL_DEBUG_LEVEL > 1
-            fprintf(stderr, "Creating %s-Lingual InputMethod\n",
-                mbMultiLingual ? "Multi" : "Mono" );
+            fprintf(stderr, "Creating Mono-Lingual InputMethod\n" );
             PrintInputStyle( mpStyles );
             #endif
         }
@@ -510,7 +454,6 @@ void
 SalI18N_InputMethod::HandleDestroyIM()
 {
     mbUseable       = False;
-    mbMultiLingual  = False;
     maMethod        = NULL;
 }
 
@@ -596,26 +539,4 @@ InputMethod_ConnectionWatchProc (Display *pDisplay, XPointer pClientData,
     }
 }
 
-Bool
-SalI18N_InputMethod::AddConnectionWatch(Display *pDisplay, void *pConnectionHandler)
-{
-    // sanity check
-    if (pDisplay == NULL || pConnectionHandler == NULL)
-        return False;
-
-    // if we are not ml all the extended text input comes on the stock X queue,
-    // so there is no need to monitor additional file descriptors.
-#ifndef SOLARIS
-     if (!mbMultiLingual || !mbUseable)
-         return False;
-#endif
-
-    // pConnectionHandler must be really a pointer to a SalXLib
-    Status nStatus = XAddConnectionWatch (pDisplay, InputMethod_ConnectionWatchProc,
-                                          (XPointer)pConnectionHandler);
-    return (Bool)nStatus;
-}
-
-
-
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/vcl/unx/generic/app/saldata.cxx b/vcl/unx/generic/app/saldata.cxx
index d865bfb..0dc426e 100644
--- a/vcl/unx/generic/app/saldata.cxx
+++ b/vcl/unx/generic/app/saldata.cxx
@@ -464,7 +464,6 @@ void SalXLib::Init()
     SalDisplay *pSalDisplay = new SalX11Display( pDisp );
 
     pInputMethod->CreateMethod( pDisp );
-    pInputMethod->AddConnectionWatch( pDisp, (void*)this );
     pSalDisplay->SetInputMethod( pInputMethod );
 
     PushXErrorLevel( true );
diff --git a/vcl/unx/generic/window/salframe.cxx b/vcl/unx/generic/window/salframe.cxx
index 58760be..f027d50 100644
--- a/vcl/unx/generic/window/salframe.cxx
+++ b/vcl/unx/generic/window/salframe.cxx
@@ -3369,12 +3369,7 @@ long X11SalFrame::HandleKeyEvent( XKeyEvent *pEvent )
     if( aDeleteWatch.isDeleted() )
         return 0;
 
-    rtl_TextEncoding nEncoding;
-
-    if (mpInputContext != NULL && mpInputContext->IsMultiLingual() )
-        nEncoding = RTL_TEXTENCODING_UTF8;
-    else
-        nEncoding = osl_getThreadTextEncoding();
+    rtl_TextEncoding nEncoding = osl_getThreadTextEncoding();
 
     sal_Unicode *pBuffer;
     sal_Unicode *pString;
diff --git a/vcl/unx/kde/kdedata.cxx b/vcl/unx/kde/kdedata.cxx
index c13c023..d1dc388 100644
--- a/vcl/unx/kde/kdedata.cxx
+++ b/vcl/unx/kde/kdedata.cxx
@@ -184,7 +184,6 @@ void KDEXLib::Init()
     SalDisplay *pSalDisplay = new SalKDEDisplay( pDisp );
 
     pInputMethod->CreateMethod( pDisp );
-    pInputMethod->AddConnectionWatch( pDisp, (void*)this );
     pSalDisplay->SetInputMethod( pInputMethod );
 
     PushXErrorLevel( true );
diff --git a/vcl/unx/kde4/KDEXLib.cxx b/vcl/unx/kde4/KDEXLib.cxx
index d8f58fa..39c6e2f 100644
--- a/vcl/unx/kde4/KDEXLib.cxx
+++ b/vcl/unx/kde4/KDEXLib.cxx
@@ -178,7 +178,6 @@ void KDEXLib::Init()
     SalKDEDisplay *pSalDisplay = new SalKDEDisplay(pDisp);
 
     pInputMethod->CreateMethod( pDisp );
-    pInputMethod->AddConnectionWatch( pDisp, (void*)this );
     pSalDisplay->SetInputMethod( pInputMethod );
 
     PushXErrorLevel( true );


More information about the Libreoffice-commits mailing list