foldable devices and Chrome OS) throughout old and new platform versions. WindowManager helps you to improve your workflow by remembering and restoring the position and size of your programs and windows. If what you need is to get the size of the Window, the new Jetpack WindowManager library provides a common API surface for new Window Manager features (e.g. New code: val defaultDisplay = getSystemService()?.getDisplay(Display.DEFAULT_DISPLAY) If you only need to retrieve the default display, instead of using different methods for different API levels as other answers suggest, you can you DisplayManager.getDisplay(Display.DEFAULT_DISPLAY) method (supported since API 17) to achieve the same result.ĭeprecated code: val defaultDisplay = getSystemService()?.defaultDisplay Window flag: this window can never receive touch events. Window flag: this window won't ever get key input focus, so the user can not send key or other button events to it. Window flag: allow window to extend outside of the screen. New: quitting WindowManager no longer switches back to Virtual Desktop number 1 New: timeout for waiting for virtual desktop service Fix: various small changes, improvements and bug fixes Version 10.2.4 (02.09.22) Fix: maintenance update with small fixes and changes Version 10.2.3 (13.08. WindowManager.getDefaultDisplay() was deprecated in API level 30 in favour of Context.getDisplay() method which requires minimum API level 30.Īt the moment, doesn't seem to offer any backwards compatible getDisplay() method. Window flag: a special option only for use in combination with FLAGLAYOUTINSCREEN.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |