I am using the SuperNova-Emoji library. I tried many solutions to resize the Emoji keyboard or hide the virtual keyboard when the emoji keyboard shows, but nothing has worked.
This is the library link in GitHub:
https://github.com/hani-momanii/SuperNova-Emoji
UPDATE 1 :
SendMessageBox = (EmojiconEditText)findViewById(R.id.txtSendMsg);
emojiIcon = (ImageView)findViewById(R.id.btn_icon);
SendMessageButton = (Button)findViewById(R.id.btnSendMsg);
rootView = (RelativeLayout)findViewById(R.id.layoutbackgrounde);
EmojIconActions emojiAction = new EmojIconActions(getApplicationContext(),rootView,emojiIcon,SendMessageBox);
emojiAction.ShowEmojicon();
emojiAction.setKeyboardListener(new EmojIconActions.KeyboardListener() {
@Override
public void onKeyboardOpen() {
Log.e("Keyboard","open");
InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);
imm.hideSoftInputFromWindow(rootView.getWindowToken(), 0);
}
@Override
public void onKeyboardClose() {
Log.e("Keyboard","close");
//maybe re-appear the input keyboard if you have to on emojikeyboardclose
//InputMethodManager imm = (InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE);
//imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, 0);
}
});
You could hide the original keyboard on emojikeyboardopen:
emojIcon.setKeyboardListener(new EmojIconActions.KeyboardListener() {
@Override
public void onKeyboardOpen() {
Log.e("Keyboard","open");
InputMethodManager imm = (InputMethodManager)getSystemService(Context.INPUT_METHOD_SERVICE);
imm.hideSoftInputFromWindow(view.getWindowToken(), 0);
}
@Override
public void onKeyboardClose() {
Log.e("Keyboard","close");
//maybe re-appear the input keyboard if you have to on emojikeyboardclose
//InputMethodManager imm = (InputMethodManager) getSystemService(Context.INPUT_METHOD_SERVICE);
//imm.toggleSoftInput(InputMethodManager.SHOW_FORCED, 0);
}
});
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.