Properly move existing tooltips on Android
authorPo Lu <luangruo@yahoo.com>
Wed, 19 Feb 2025 07:34:51 +0000 (15:34 +0800)
committerPo Lu <luangruo@yahoo.com>
Wed, 19 Feb 2025 07:34:51 +0000 (15:34 +0800)
* java/org/gnu/emacs/EmacsWindow.java (requestViewLayout): If an
override redirect window, additionally notify the window manager
of layout changes.

java/org/gnu/emacs/EmacsWindow.java

index fec955268358789b02eea241d19062de5cbf161d..2f4e378fb78c68adc3555b6066b7dc44e9e02686 100644 (file)
@@ -365,8 +365,17 @@ public final class EmacsWindow extends EmacsHandleObject
        run ()
        {
          if (overrideRedirect)
-           /* Set the layout parameters again.  */
-           view.setLayoutParams (getWindowLayoutParams ());
+           {
+             WindowManager.LayoutParams params;
+
+             /* Set the layout parameters again.  */
+             params = getWindowLayoutParams ();
+             view.setLayoutParams (params);
+
+             /* Announce this update to the window server.  */
+             if (windowManager != null)
+               windowManager.updateViewLayout (view, params);
+           }
 
          view.mustReportLayout = true;
          view.requestLayout ();