From ecee01859e3cfb4e01d11d39f9ce13925a133c44 Mon Sep 17 00:00:00 2001 From: DumperTag Date: Wed, 4 Sep 2024 14:38:53 +0530 Subject: [PATCH] fix emojiPaletteHolder is open as open whenever new keyboard is called --- .../com/simplemobiletools/keyboard/views/MyKeyboardView.kt | 3 +++ .../main/java/androidx/emoji2/emojipicker/EmojiPickerView.kt | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/app/src/main/kotlin/com/simplemobiletools/keyboard/views/MyKeyboardView.kt b/app/src/main/kotlin/com/simplemobiletools/keyboard/views/MyKeyboardView.kt index 40cb463..d090de2 100644 --- a/app/src/main/kotlin/com/simplemobiletools/keyboard/views/MyKeyboardView.kt +++ b/app/src/main/kotlin/com/simplemobiletools/keyboard/views/MyKeyboardView.kt @@ -279,6 +279,7 @@ class MyKeyboardView @JvmOverloads constructor(context: Context, attrs: Attribut showPreview(NOT_A_KEY) } + keyboardViewBinding?.emojiPaletteHolder?.beGone() closeClipboardManager() removeMessages() mKeyboard = keyboard @@ -1583,10 +1584,12 @@ class MyKeyboardView @JvmOverloads constructor(context: Context, attrs: Attribut if(emojiPaletteHolder.isVisible){ + Log.i("thisISsRUNN","YESS") emojiPaletteHolder.beGone() emojiSearchToolbar.beGone() mainToolbarKeyboardHolder.beVisible() }else{ + Log.i("thisISsRUNN","YESS2") emojiSearchView.clearFocus() emojiSearchView.text.clear() emojiPaletteHolder.beVisible() diff --git a/emojipicker/src/main/java/androidx/emoji2/emojipicker/EmojiPickerView.kt b/emojipicker/src/main/java/androidx/emoji2/emojipicker/EmojiPickerView.kt index 157886e..230e07d 100644 --- a/emojipicker/src/main/java/androidx/emoji2/emojipicker/EmojiPickerView.kt +++ b/emojipicker/src/main/java/androidx/emoji2/emojipicker/EmojiPickerView.kt @@ -167,7 +167,7 @@ constructor(context: Context, attrs: AttributeSet? = null, defStyleAttr: Int = 0 /*here is emoji is get from the bundle and send to recycler view*/ fun buildEmojiPickerItems(onlyRecentEmojies: Boolean = false, description: String?=null ) :EmojiPickerItems{ - + //used in search result usualy assign in the xml file when created a emojiPicker view if(!usedInSearchResult){ return EmojiPickerItems( buildList {