< prev index next >

src/java.desktop/share/classes/sun/awt/im/InputContext.java

Print this page

        

@@ -1,7 +1,7 @@
 /*
- * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 1997, 2019, Oracle and/or its affiliates. All rights reserved.
  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
  *
  * This code is free software; you can redistribute it and/or modify it
  * under the terms of the GNU General Public License version 2 only, as
  * published by the Free Software Foundation.  Oracle designates this

@@ -545,10 +545,12 @@
                 endComposition();
                 deactivateInputMethod(false);
                 if (inputMethod instanceof InputMethodAdapter) {
                     ((InputMethodAdapter) inputMethod).setClientComponent(null);
                 }
+                if (null == currentClientComponent.getInputMethodRequests())
+                    wasCompositionEnabledSupported = false;
             }
             savedLocale = inputMethod.getLocale();
 
             // keep the input method instance around for future use
             if (usedInputMethods == null) {

@@ -561,10 +563,11 @@
             perInputMethodState.put(inputMethod,
                                     Boolean.valueOf(clientWindowNotificationEnabled));
             enableClientWindowNotification(inputMethod, false);
             if (this == inputMethodWindowContext) {
                 inputMethod.hideWindows();
+                inputMethod.removeNotify();
                 inputMethodWindowContext = null;
             }
             inputMethodLocator = null;
             inputMethod = null;
             inputMethodCreationFailed = false;
< prev index next >