showEmojiPickerWith method

  1. @override
void showEmojiPickerWith(
  1. String? initialEmoji,
  2. void onNewEmoji(
    1. String
    )
)
override

Takes optional initialEmoji or defaults to "😎" onNewEmoji callback returns the result of the call

Implementation

@override
void showEmojiPickerWith(
  String? initialEmoji,
  void Function(String) onNewEmoji,
) {
  methodChannel.invokeMethod<String>("show_emoji_picker_vc", initialEmoji);
  methodChannel.setMethodCallHandler((call) {
    if (call.method == "show_emoji_picker_vc") {
      onNewEmoji.call(call.arguments.toString());
    }

    return Future.value(-1);
  });
}