1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-01-13 06:50:39 -08:00

Resolve disagreements in accounting of tooltip positions on Android

* java/org/gnu/emacs/EmacsService.java (getLocationInWindow):
New function.

* java/org/gnu/emacs/EmacsWindow.java (translateCoordinates):
Derive "root window" position from the origin point of the
containing activity's window rather than that of the screen,
the two of which differ when "freeform mode" is enabled.
This commit is contained in:
Po Lu 2024-04-07 14:39:42 +08:00
parent c7a0e4faa2
commit 8ee1dc8f1f
2 changed files with 21 additions and 3 deletions

View file

@ -387,6 +387,23 @@ public final class EmacsService extends Service
EmacsService.<Void>syncRunnable (task);
}
public void
getLocationInWindow (final EmacsView view, final int[] coordinates)
{
FutureTask<Void> task;
task = new FutureTask<Void> (new Callable<Void> () {
public Void
call ()
{
view.getLocationInWindow (coordinates);
return null;
}
});
EmacsService.<Void>syncRunnable (task);
}
public static void