差别
这里会显示出您选择的修订版和当前版本之间的差别。
| 两侧同时换到之前的修订记录 前一修订版 后一修订版 | 前一修订版 | ||
|
f_qudaojieru:d_androidsdk [2016-05-20 17:05] lihuanhuan [Android SDK目录结构说明] |
f_qudaojieru:d_androidsdk [2016-05-20 17:11] (当前版本) lihuanhuan [SDK配置] |
||
|---|---|---|---|
| 行 14: | 行 14: | ||
| ===== Android SDK集成方法 ===== | ===== Android SDK集成方法 ===== | ||
| - | 创建好您的工程后,将RKCustomerServiceSDK(Android-v1.0.1.14)-20160323.zip解压后倒入到您的工程目录下。 | + | 创建好您的工程后,将RKCustomerServiceSDK(Android-v1.1.4.19)-20160520.zip解压后倒入到您的工程目录下。 |
| ==== Android Studio集成方法 ==== | ==== Android Studio集成方法 ==== | ||
| -点击标题栏Project Structure,如下图:\\ {{asdaoru1.png}}\\ | -点击标题栏Project Structure,如下图:\\ {{asdaoru1.png}}\\ | ||
| 行 35: | 行 35: | ||
| 1.配置权限到您的AndroidManifest.xml文件中 | 1.配置权限到您的AndroidManifest.xml文件中 | ||
| <code xml> | <code xml> | ||
| - | <uses-permission android:name="android.permission.INTERNET"/> | + | <uses-permission android:name="android.permission.INTERNET"/> |
| - | <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> | + | <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/> |
| - | <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> | + | <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/> |
| - | <uses-permission android:name="android.permission.WAKE_LOCK"/> | + | <uses-permission android:name="android.permission.WAKE_LOCK"/> |
| - | <uses-permission android:name="android.permission.RECORD_AUDIO"/> | + | <uses-permission android:name="android.permission.RECORD_AUDIO"/> |
| - | <uses-permission android:name="android.permission.VIBRATE"/> | + | <uses-permission android:name="android.permission.VIBRATE"/> |
| - | </code> | + | </code> |
| 2.配置Activity到您的AndroidManifest.xml中 | 2.配置Activity到您的AndroidManifest.xml中 | ||
| <code xml> | <code xml> | ||
| - | <!-- 设置连接service页面--> | + | <!-- 设置连接service页面--> |
| - | <activity android:name="com.rongkecloud.customerservice.ui.RKServiceChatConnectActivity" | + | <activity |
| - | android:screenOrientation="portrait" | + | android:name="com.rongkecloud.customerservice.ui.RKServiceChatConnectActivity" |
| - | android:theme="@android:style/Theme.Translucent"/> | + | android:screenOrientation="portrait" |
| - | <!-- 设置聊天页面--> | + | android:theme="@android:style/Theme.Translucent"/> |
| - | <activity android:name="com.rongkecloud.customerservice.ui.RKServiceChatMsgActivity" | + | <!-- 设置聊天页面--> |
| - | android:launchMode="singleTask" | + | <activity |
| - | android:screenOrientation="portrait" | + | android:name="com.rongkecloud.customerservice.ui.RKServiceChatMsgActivity" |
| - | android:theme="@android:style/Theme.NoTitleBar" | + | android:launchMode="singleTask" |
| - | android:windowSoftInputMode="adjustResize"/> | + | android:screenOrientation="portrait" |
| - | <!-- 设置留言给客服页面--> | + | android:theme="@android:style/Theme.NoTitleBar" |
| - | <activity android:name="com.rongkecloud.customerservice.ui.RKServiceChatLeaveMessageActivity" | + | android:windowSoftInputMode="adjustResize"/> |
| - | android:screenOrientation="portrait" | + | <!-- 设置留言给客服页面--> |
| - | android:theme="@android:style/Theme.NoTitleBar"/> | + | <activity |
| - | <!-- 设置图片滑动页面--> | + | android:name="com.rongkecloud.customerservice.ui.RKServiceChatLeaveMessageActivity" |
| - | <activity android:name="com.rongkecloud.customerservice.ui.RKServiceChatViewImagesActivity" | + | android:screenOrientation="portrait" |
| - | android:screenOrientation="portrait" | + | android:theme="@android:style/Theme.NoTitleBar"/> |
| - | android:theme="@android:style/Theme.NoTitleBar"/> | + | <!-- 设置图片滑动页面--> |
| - | </code> | + | <activity |
| + | android:name="com.rongkecloud.customerservice.ui.RKServiceChatViewImagesActivity" | ||
| + | android:screenOrientation="portrait" | ||
| + | android:theme="@android:style/Theme.NoTitleBar"/> | ||
| + | </code> | ||
| 3.配置receive到您的AndroidManifest.xml中 | 3.配置receive到您的AndroidManifest.xml中 | ||
| <code xml> | <code xml> | ||
| - | <receiver android:name="com.rongkecloud.android.lps.RKServiceBroadcastReceiver" | + | <receiver |
| - | android:enabled="true" | + | android:name="com.rongkecloud.android.lps.RKServiceBroadcastReceiver" |
| - | android:exported="false" > | + | android:enabled="true" |
| - | <intent-filter android:priority="90000" > | + | android:exported="false" > |
| - | <action android:name="android.intent.action.USER_PRESENT" /> | + | <intent-filter |
| - | </intent-filter> | + | android:priority="90000" > |
| - | <intent-filter> | + | <action android:name="android.intent.action.USER_PRESENT" /> |
| - | <action android:name="android.net.conn.CONNECTIVITY_CHANGE" /> | + | </intent-filter> |
| - | <action android:name="android.net.wifi.RSSI_CHANGED" /> | + | <intent-filter> |
| - | <action android:name="android.net.wifi.STATE_CHANGE" /> | + | <action android:name="android.net.conn.CONNECTIVITY_CHANGE" /> |
| - | <action android:name="android.net.wifi.WIFI_STATE_CHANGED" /> | + | <action android:name="android.net.wifi.RSSI_CHANGED" /> |
| - | </intent-filter> | + | <action android:name="android.net.wifi.STATE_CHANGE" /> |
| - | <intent-filter> | + | <action android:name="android.net.wifi.WIFI_STATE_CHANGED" /> |
| - | <action android:name="lps.message.receive" /> | + | </intent-filter> |
| - | <action android:name="action_reconnect" /> | + | <intent-filter> |
| - | <action android:name="action_ping" /> | + | <action android:name="lps.message.receive" /> |
| - | <data android:mimeType="*/*" /> | + | <action android:name="action_reconnect" /> |
| - | </intent-filter> | + | <action android:name="action_ping" /> |
| - | </receiver> | + | <data android:mimeType="*/*" /> |
| + | </intent-filter> | ||
| + | </receiver> | ||
| </code> | </code> | ||
| 4.配置service到您的AndroidManifest.xml中 | 4.配置service到您的AndroidManifest.xml中 | ||
| <code xml> | <code xml> | ||
| - | <service android:name="com.rongkecloud.android.lps.LPSDaemonService" | + | <service |
| - | android:exported="false" | + | android:name="com.rongkecloud.android.lps.LPSDaemonService" |
| - | android:process=":remote"/> | + | android:exported="false" |
| + | android:process=":remote"/> | ||
| </code> | </code> | ||
| ===== 使用SDK ===== | ===== 使用SDK ===== | ||
| 在您的app中做一个触发“连接客服”的事件,在此事件中将您在管理平台生成的配置代码加进去,即可正常使用融智客服客户SDK。 | 在您的app中做一个触发“连接客服”的事件,在此事件中将您在管理平台生成的配置代码加进去,即可正常使用融智客服客户SDK。 | ||