mirror of
https://github.com/anomalyco/hex.git
synced 2026-11-28 13:02:21 +01:00
| Filename | Latest commit message | Latest commit date |
|---|---|---|
* Android keyboard: one emoji picker instead of a new one per opening; the Hex menu closes when the app changes the field's type
Emoji panel memory
- openEmoji made a new AndroidX EmojiPickerView every time and removed the old one, which was never
collected: each EmojiView draws into its own ARGB bitmap, so every opening kept about 5 MB of native
heap (and the old views on the Java heap). Over 50 openings, from a fresh process:
API 36: PSS 82 -> 359 MB, native 20 -> 272 MB, Java 17 -> 38 MB
API 31: PSS 63 -> 310 MB, native 15 -> 231 MB, Java 11 -> 37 MB
The meminfo Graphics and GL mtrack rows stayed at 0 throughout: none of it is the emulator's software
graphics, it is the pickers' bitmaps in the app's own heap, as it would be on a phone.
- Now the keys keep one picker for their life, hidden while closed. A new picker was what refreshed the
Recently used row (the picker reads recents as it starts), so each opening hands it the recents again
(setRecentEmojiProvider refreshes the row) and taps its Recently used tab, so it opens at the top as a
new one did. RecentEmoji keeps the recents where AndroidX's own provider does (its preferences file and
key, newest first), because that provider is internal; recents chosen before carry over. The grid is
sized once (again only if the panel's height changes).
- After, same 50 openings: API 36 PSS 82 -> 91 MB, native 20 -> 25 MB; API 31 PSS 63 -> 74 MB, native
15 -> 21 MB.
Hex menu and a field changing type in place
- With the Hex menu open, an app restarting input on the same box with another type (text to password)
left the menu over the new field's keys. HexKeyboard notes the field's inputType and imeOptions; when a
restart changes them, onStartInputView closes the menu without setting typing up (closeMenu(configure =
false)), since configureTyping right after it draws the keys once. The same type restarting (a chat app
clearing its box) leaves the menu open.
Verified (emulator only, Pixel 8, API 36 and 31): the memory figures above; an emoji picked from People,
the panel closed and reopened: it opens at Recently used with that emoji first; menu open, field turned
password: the letter keys with the password note; menu open, same type restarted: menu stays.
* Android keyboard: Auto-capitalisation off adds no capitals; AZERTY's touch geometry from its own rows
From the typing helper's end-to-end check (
|
||
| .. | ||
| main | ||
| release | ||
| test/java/ly/anoma/hex | ||