AndroidKeyboardWatcher icon indicating copy to clipboard operation
AndroidKeyboardWatcher copied to clipboard

the initialValue is always == rootView.get().getHeight()

Open anjiao opened this issue 9 years ago • 2 comments

if (initialValue == 0) { initialValue = rootViewRef.get().getHeight(); } else { if (initialValue > rootViewRef.get().getHeight()) { if (onKeyboardToggleListenerRef.get() != null) { if (!hasSentInitialAction || !isKeyboardShown) { isKeyboardShown = true; onKeyboardToggleListenerRef.get().onKeyboardShown(initialValue - rootViewRef.get().getHeight()); } } } else { if (!hasSentInitialAction || isKeyboardShown) { isKeyboardShown = false; rootViewRef.get().post(new Runnable() { @Override public void run() { if (onKeyboardToggleListenerRef.get() != null) { onKeyboardToggleListenerRef.get().onKeyboardClosed(); } } }); } } hasSentInitialAction = true; }

anjiao avatar Mar 30 '16 02:03 anjiao

I had the same problem. I use this in a fragment, and it didn't work right.

andyxialm avatar Apr 18 '16 07:04 andyxialm

and me

Mahdiazadbar avatar Jan 26 '17 09:01 Mahdiazadbar