Closed Bug 2031563 Opened 7 months ago Closed 7 months ago

Replace deprecated InputMethodManager APIs with WindowInsetsController

Categories

(Firefox for Android :: General, task)

All
Android
task

Tracking

()

RESOLVED FIXED
151 Branch
Tracking Status
firefox151 --- fixed

People

(Reporter: RyanVM, Assigned: RyanVM)

References

Details

Attachments

(1 external file)

InputMethodManager.SHOW_IMPLICIT, HIDE_IMPLICIT_ONLY, showSoftInput(), and hideSoftInputFromWindow() were deprecated in API 33 and will become lint errors when we bump compileSdk to 37.

This replaces them with WindowCompat.getInsetsController() / WindowInsetsCompat.Type.ime() in the support-ktx View extensions (showKeyboard/hideKeyboard), and updates Fenix's SearchDialogFragment to use the existing hideKeyboard() helper instead of calling InputMethodManager directly.

Try push: https://treeherder.mozilla.org/jobs?repo=try&revision=bfaa7f3fbf22834c122714639a971c535efd9d5e

InputMethodManager.SHOW_IMPLICIT, HIDE_IMPLICIT_ONLY, showSoftInput(), and
hideSoftInputFromWindow() are now lint errors with compileSdk 37. Replace them
with WindowInsetsController (via WindowCompat.getInsetsController()) in the
support-ktx View extensions, and use the resulting hideKeyboard() helper in
Fenix's SearchDialogFragment. Also fix ActivityManager.RecentTaskInfo.taskInfo
which is now nullable in SDK 37.

The Bugbug bot thinks this bug should belong to the 'Firefox for Android::Tooling' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: General → Tooling
Component: Tooling → General
Status: NEW → RESOLVED
Closed: 7 months ago
Resolution: --- → FIXED
Target Milestone: --- → 151 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: