Jun 14, 2022
In Android 11, when you open up a contact in freeform window, the top tool bar (with a star, a pen and 3 vertical dots) hides behind the decoration of the freeform window (the title bar with "maximize/restore" & "close" buttons). When you move the window or minimize/maximize again, it shows correctly (see pics).

It is fixed in Android 12, but I would like to make this right on Android 11 for my purpose. Where exactly should I fix that problem in the Android's source code? Thanks in advance!!


  • bugged.PNG
    201.8 KB · Views: 134
  • refreshed.PNG
    197.8 KB · Views: 92
I also have the same situation! Did you find the answer?
Yes, after digging into the AOSP, I found a fix. I don't think there's anything related to this topic online so I will post here for anyone who has the same issue.

The cause is the "" does not set a default "isOverlayWithDecorCaptionEnabled" on creation. It should be set to false by calling "setOverlayWithDecorCaptionEnabled(false)" in onCreate, so that the decorcaption, i.e. the title bar on top of the window, pushes the content of down instead of overlaying on the content. After adding this one line, the problem was fixed for me.

I am working on a particular device in our company, but I imagine this could apply to all android 11 devices.
  • Like
Reactions: codesplice