diff --git a/widget/src/gtk2/nsWindow.cpp b/widget/src/gtk2/nsWindow.cpp --- a/widget/src/gtk2/nsWindow.cpp +++ b/widget/src/gtk2/nsWindow.cpp @@ -32,16 +32,21 @@ * under the terms of either the GPL or the LGPL, and not to allow others to * use your version of this file under the terms of the MPL, indicate your * decision by deleting the provisions above and replace them with the notice * and other provisions required by the GPL or the LGPL. If you do not delete * the provisions above, a recipient may use your version of this file under * the terms of any one of the MPL, the GPL or the LGPL. * * ***** END LICENSE BLOCK ***** */ + +#ifdef NS_HILDON +#define MAEMO_CHANGES +#include +#endif #include "prlink.h" #include "nsWindow.h" #include "nsGTKToolkit.h" #include "nsIDeviceContext.h" #include "nsIRenderingContext.h" #include "nsIRegion.h" @@ -6109,16 +6114,23 @@ nsWindow::SetIMEEnabled(PRUint32 aState) focusedWin->IMELoseFocus(); } mIMEData->mEnabled = aState; // Even when aState is not PR_TRUE, we need to set IME focus. // Because some IMs are updating the status bar of them in this time. focusedWin->IMESetFocus(); +#ifdef NS_HILDON + if (mIMEData->mEnabled) + hildon_gtk_im_context_show (focusedIm); + else + hildon_gtk_im_context_hide (focusedIm); +#endif + } else { if (IsIMEEditableState(mIMEData->mEnabled)) ResetInputState(); mIMEData->mEnabled = aState; } return NS_OK; }