1
我正在通過使用WindowManager
直接添加視圖到窗口來進行重疊。但是,我似乎無法找到執行chathead所需的標誌,這是在軟鍵盤上覆蓋。彈出時,我的疊加層始終被鍵盤覆蓋。什麼WindowManager標誌是Facebook Messenger使用的聊天頭
這是我使用我的看法PARAMS被添加到窗口
private WindowManager.LayoutParams touchableParams = new WindowManager.LayoutParams(
ViewGroup.LayoutParams.MATCH_PARENT,
ViewGroup.LayoutParams.MATCH_PARENT,
WindowManager.LayoutParams.TYPE_PHONE,
WindowManager.LayoutParams.FLAG_HARDWARE_ACCELERATED
| WindowManager.LayoutParams.FLAG_LAYOUT_IN_SCREEN,
PixelFormat.TRANSLUCENT);
你見過? http://stackoverflow.com/questions/15975988/what-apis-in-android-is-facebook-using-to-create-chat-heads –
是的,我試過'TYPE_SYSTEM_ALERT',但它沒有通過軟鍵盤。 AFAIK,'TYPE_PHONE'和'TYPE_SYSTEM_ALERT'唯一的區別在於前者適用於所有用戶,後者適用於擁有用戶 –