📅  最后修改于: 2022-03-11 14:57:35.396000             🧑  作者: Mango
bool isKeyboardVisible = false;
@override
void initState() {
super.initState();
KeyboardVisibilityNotification().addNewListener(
onChange: (bool visible) {
isKeyboardVisible = visible;
},
);
}