com.vanniktech.emoji.listeners.OnEmojiPopupDismissListener Java Examples

The following examples show how to use com.vanniktech.emoji.listeners.OnEmojiPopupDismissListener. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: FragmentEditImage.java    From iGap-Android with GNU Affero General Public License v3.0 5 votes vote down vote up
private void setEmojiColor(View view,String BackgroundColor, String iconColor, String dividerColor) {

        emojiPopup = EmojiPopup.Builder.fromRootView(view.findViewById(R.id.ac_ll_parent))
                .setOnEmojiBackspaceClickListener(new OnEmojiBackspaceClickListener() {

                    @Override
                    public void onEmojiBackspaceClick(View v) {

                    }
                }).setOnEmojiPopupShownListener(new OnEmojiPopupShownListener() {
                    @Override
                    public void onEmojiPopupShown() {
                        changeEmojiButtonImageResource(R.string.md_black_keyboard_with_white_keys);
                        isEmojiSHow = true;
                    }
                }).setOnSoftKeyboardOpenListener(new OnSoftKeyboardOpenListener() {
                    @Override
                    public void onKeyboardOpen(final int keyBoardHeight) {

                    }
                }).setOnEmojiPopupDismissListener(new OnEmojiPopupDismissListener() {
                    @Override
                    public void onEmojiPopupDismiss() {
                        changeEmojiButtonImageResource(R.string.md_emoticon_with_happy_face);
                        isEmojiSHow = false;
                    }
                }).setOnSoftKeyboardCloseListener(new OnSoftKeyboardCloseListener() {
                    @Override
                    public void onKeyboardClose() {
                        emojiPopup.dismiss();
                    }
                })
                .setBackgroundColor(Color.parseColor(BackgroundColor))
                .setIconColor(Color.parseColor(iconColor))
                .setDividerColor(Color.parseColor(dividerColor))
                .build(edtChat);

    }
 
Example #2
Source File: ActivityPopUpNotification.java    From iGap-Android with GNU Affero General Public License v3.0 5 votes vote down vote up
private void setEmojiColor(String BackgroundColor, String iconColor, String dividerColor) {
    emojiPopup = EmojiPopup.Builder.fromRootView(findViewById(R.id.ac_ll_parent_notification)).setOnEmojiBackspaceClickListener(new OnEmojiBackspaceClickListener() {
        @Override
        public void onEmojiBackspaceClick(View v) {

        }
    }).setOnEmojiPopupShownListener(new OnEmojiPopupShownListener() {
        @Override
        public void onEmojiPopupShown() {
            changeEmojiButtonImageResource(R.string.md_black_keyboard_with_white_keys);
        }
    }).setOnSoftKeyboardOpenListener(new OnSoftKeyboardOpenListener() {
        @Override
        public void onKeyboardOpen(final int keyBoardHeight) {

        }
    }).setOnEmojiPopupDismissListener(new OnEmojiPopupDismissListener() {
        @Override
        public void onEmojiPopupDismiss() {
            changeEmojiButtonImageResource(R.string.md_emoticon_with_happy_face);
        }
    }).setOnSoftKeyboardCloseListener(new OnSoftKeyboardCloseListener() {
        @Override
        public void onKeyboardClose() {
            emojiPopup.dismiss();
        }
    })
            .setBackgroundColor(Color.parseColor(BackgroundColor))
            .setIconColor(Color.parseColor(iconColor))
            .setDividerColor(Color.parseColor(dividerColor))
            .build(edtChat);
}
 
Example #3
Source File: ProfileEditActivity.java    From FaceT with Mozilla Public License 2.0 5 votes vote down vote up
private void setUpEmojiPopup() {
    emojiPopup = EmojiPopup.Builder.fromRootView(rootView)
            .setOnEmojiBackspaceClickListener(new OnEmojiBackspaceClickListener() {
                @Override public void onEmojiBackspaceClick(final View v) {
                    Log.d(TAG, "Clicked on Backspace");
                }
            })
            .setOnEmojiClickListener(new OnEmojiClickListener() {
                @Override public void onEmojiClick(@NonNull final EmojiImageView imageView, @NonNull final Emoji emoji) {
                    Log.d(TAG, "Clicked on emoji");
                }
            })
            .setOnEmojiPopupShownListener(new OnEmojiPopupShownListener() {
                @Override
                public void onEmojiPopupShown() {
                    emojiButton.setImageResource(R.drawable.ic_keyboard);
                }
            })
            .setOnSoftKeyboardOpenListener(new OnSoftKeyboardOpenListener() {
                @Override
                public void onKeyboardOpen(final int keyBoardHeight) {
                    Log.d(TAG, "Opened soft keyboard");
                }
            })
            .setOnEmojiPopupDismissListener(new OnEmojiPopupDismissListener() {
                @Override
                public void onEmojiPopupDismiss() {
                    emojiPopup.dismiss();
                    emojiButton.setImageResource(R.drawable.emoji_one_category_people);
                }
            })
            .setOnSoftKeyboardCloseListener(new OnSoftKeyboardCloseListener() {
                @Override
                public void onKeyboardClose() {
                    emojiPopup.dismiss();
                    Log.d(TAG, "Closed soft keyboard");
                }
            })
            .build(aboutMeEdittext);
}
 
Example #4
Source File: ProductDetailActivity.java    From FaceT with Mozilla Public License 2.0 5 votes vote down vote up
private void setUpEmojiPopup() {
    emojiPopup = EmojiPopup.Builder.fromRootView(activity_product_detail_layout)
            .setOnEmojiBackspaceClickListener(new OnEmojiBackspaceClickListener() {
                @Override public void onEmojiBackspaceClick(final View v) {
                    Log.d(TAG, "Clicked on Backspace");
                }
            })
            .setOnEmojiClickListener(new OnEmojiClickListener() {
                @Override public void onEmojiClick(@NonNull final EmojiImageView imageView, @NonNull final Emoji emoji) {
                    Log.d(TAG, "Clicked on emoji");
                }
            })
            .setOnEmojiPopupShownListener(new OnEmojiPopupShownListener() {
                @Override
                public void onEmojiPopupShown() {
                    emojiButton.setBackground(ContextCompat.getDrawable(ProductDetailActivity.this, R.drawable.ic_keyboard));
                }
            })
            .setOnSoftKeyboardOpenListener(new OnSoftKeyboardOpenListener() {
                @Override
                public void onKeyboardOpen(final int keyBoardHeight) {
                    Log.d(TAG, "Opened soft keyboard");
                }
            })
            .setOnEmojiPopupDismissListener(new OnEmojiPopupDismissListener() {
                @Override
                public void onEmojiPopupDismiss() {
                    emojiButton.setBackground(ContextCompat.getDrawable(ProductDetailActivity.this, R.drawable.emoji_one_category_people));
                }
            })
            .setOnSoftKeyboardCloseListener(new OnSoftKeyboardCloseListener() {
                @Override
                public void onKeyboardClose() {
                    emojiPopup.dismiss();
                    Log.d(TAG, "Closed soft keyboard");
                }
            })
            .build(commentEmojiconEditText);
}
 
Example #5
Source File: MessageListActivity.java    From chat21-android-sdk with GNU Affero General Public License v3.0 4 votes vote down vote up
private void setUpEmojiPopup() {
        emojiPopup = EmojiPopup.Builder.fromRootView(rootView)
                .setOnEmojiBackspaceClickListener(new OnEmojiBackspaceClickListener() {
                    @Override
                    public void onEmojiBackspaceClick(final View v) {
                        Log.d(TAG, "Clicked on Backspace");
                    }
                })
                .setOnEmojiClickListener(new OnEmojiClickListener() {
                    @Override
                    public void onEmojiClick(@NonNull final EmojiImageView imageView, @NonNull final Emoji emoji) {
                        Log.d(TAG, "Clicked on emoji");
                    }
                })
                .setOnEmojiPopupShownListener(new OnEmojiPopupShownListener() {
                    @Override
                    public void onEmojiPopupShown() {
                        emojiButton.setImageResource(R.drawable.ic_keyboard_24dp);
                    }
                })
                .setOnSoftKeyboardOpenListener(new OnSoftKeyboardOpenListener() {
                    @Override
                    public void onKeyboardOpen(@Px final int keyBoardHeight) {
                        Log.d(TAG, "Opened soft keyboard");
                    }
                })
//                .setOnEmojiPopupDismissListener(new OnEmojiPopupDismissListener() {
//                    @Override
//                    public void onEmojiPopupDismiss() {
//                        emojiButton.setImageResource(R.drawable.emoji_ios_category_people);
//                    }
//                })

                .setOnEmojiPopupDismissListener(new OnEmojiPopupDismissListener() {
                    @Override
                    public void onEmojiPopupDismiss() {
                        emojiButton.setImageResource(R.drawable.emoji_ios_category_people);
                    }
                })
                .setOnSoftKeyboardCloseListener(new OnSoftKeyboardCloseListener() {
                    @Override
                    public void onKeyboardClose() {
                        Log.d(TAG, "Closed soft keyboard");
                    }
                })
                .build(editText);
    }
 
Example #6
Source File: EmojiPopup.java    From Emoji with Apache License 2.0 4 votes vote down vote up
@CheckResult public Builder setOnEmojiPopupDismissListener(@Nullable final OnEmojiPopupDismissListener listener) {
  onEmojiPopupDismissListener = listener;
  return this;
}
 
Example #7
Source File: EmojiPopup.java    From hipda with GNU General Public License v2.0 4 votes vote down vote up
public Builder setOnEmojiPopupDismissListener(@Nullable final OnEmojiPopupDismissListener listener) {
    this.onEmojiPopupDismissListener = listener;
    return this;
}