融雲輸入區域自定義

2021-08-18 03:05:09 字數 1539 閱讀 5423

鍵盤+號裡面的內容自定義

這裡需要新增乙個自定的內容

一、布局檔案:

部分布局檔案如下,您可以通過修改對應的布局檔案來調整介面布局,修改背景,更改字型等。

1、rc_ext_extension_bar.xml 輸入框布局檔案。它是整個輸入框的容器,內部有對各部分元件功能描述。

2、rc_ext_input_edit_text.xml edittext 布局檔案。如果想要替換背景,直接修改即可。

3、rc_ext_voice_input.xml 語音輸入布局檔案。

4、輸入框模式自定義。

另外,在會介面中可以設定輸入框的模式。針對聊天會話的語音/文字切換功能、內容輸入功能、擴充套件功能,融雲目前提供了 5 種排列組合模式:

使用者可以通過更改rc_fr_conversation.xml裡 

,更改預設輸入顯示形式。

二、「+」號擴充套件區域自定義

sdk 裡預設定義了如下 plugin,各 plugin 的功能說明如下:

名稱功能

locationplugin

位置資訊元件,需要使用者自己整合第三方地圖實現定位

realtimelocationplugin

實時位置共享元件,內建了高德地圖的介面,可直接使用

defaultlocationplugin

位置資訊元件,已經內建了高德地圖,實現了定位功能,可直接使用

combinelocationplugin

上面 defaultlocationplugin + realtimelocationplugin 的綜合元件

fileplugin

檔案元件

imageplugin

元件自定義 plugin

1、自定義 plugin 並實現 ipluginmodule。 如:

自定義 plugin

1、自定義 plugin 並實現 ipluginmodule。 如:

public class myplugin implements ipluginmodule
2、自定義乙個 extensionmodule 繼承自 defaultextensionmodule,複寫其中的 getpluginmodules() 方法,返回需要展示的 plugin 列表。如:

public class myextensionmodule extends defaultextensionmodule 

}

3.需要註冊自定義資訊:

rongextensionmanager.getinstance().registerextensionmodule(new 自定義module());
這時輸入框下面就會出現定義的module了。

融雲 IMKit 自定義會話介面

在會話介面使用 getintent getdata getqueryparameter targetid 獲取id getintent getdata getqueryparameter title 獲取訊息title在會介面中可以設定輸入框的模式。針對聊天會話的語音 文字切換功能 內容輸入功能 擴...

融雲2 8 0之後自定義輸入法擴充套件欄

很久以前自定義過,當時是的api是這樣的 inputprovider.extendprovider provider rongim.resetinputextensionprovider conversation.conversationtype.private,provider 隨著融雲的迭代,2...

區域聯動自定義

因專案需要,區域需要實現效果中的結果,select的option無法自定義,故通過自定義的div來實現該區域框。具體 如下 html 當前單位 選擇單位 請選擇 請選擇 確定 js var loginuser json.parse sessionstorage.loginuser if common...