问题
I have FloatingActionButtons and FloatingActionMenus in CoordinatorLayouts, but I also have some EditTexts in there too, with the adjustPan window mode. But when I go to click the EditTexts, the floating buttons/menus come up along with the keyboard and somewhat block the visible area (such as the row containing the EditText). Can I somehow prevent the floating items from coming up with the keyboard?
回答1:
There is a library which can listen to keyboard visibility, if the keyboard is visbile make the FAB to GONE or INVISIBLE.
https://github.com/yshrsmz/KeyboardVisibilityEvent
来源:https://stackoverflow.com/questions/40274705/how-do-you-hide-floating-action-buttons-from-the-keyboard