├── .gitignore
├── Chatting
├── .gitignore
├── AndroidManifest.xml
├── LICENSE
├── README.md
├── build.gradle
├── libs
│ ├── arm64-v8a
│ │ └── libjpush211.so
│ ├── armeabi-v7a
│ │ └── libjpush211.so
│ ├── armeabi
│ │ └── libjpush211.so
│ ├── eventbus.jar
│ ├── jmessage-android-1.2.1.jar
│ ├── mips
│ │ └── libjpush211.so
│ ├── mips64
│ │ └── libjpush211.so
│ ├── nineoldandroids-2.4.0.jar
│ ├── picasso-2.4.0.jar
│ ├── x86
│ │ └── libjpush211.so
│ └── x86_64
│ │ └── libjpush211.so
├── proguard-rules.pro
├── res
│ ├── anim
│ │ ├── jmui_rotate.xml
│ │ ├── jmui_slide_in_from_left.xml
│ │ ├── jmui_slide_in_from_right.xml
│ │ ├── jmui_slide_out_to_left.xml
│ │ ├── jmui_slide_out_to_right.xml
│ │ ├── jmui_voice_receive.xml
│ │ └── jmui_voice_send.xml
│ ├── drawable-hdpi
│ │ ├── ic_launcher.png
│ │ ├── jmui_loading_1.png
│ │ ├── jmui_loading_10.png
│ │ ├── jmui_loading_11.png
│ │ ├── jmui_loading_12.png
│ │ ├── jmui_loading_13.png
│ │ ├── jmui_loading_14.png
│ │ ├── jmui_loading_2.png
│ │ ├── jmui_loading_3.png
│ │ ├── jmui_loading_4.png
│ │ ├── jmui_loading_5.png
│ │ ├── jmui_loading_6.png
│ │ ├── jmui_loading_7.png
│ │ ├── jmui_loading_8.png
│ │ └── jmui_loading_9.png
│ ├── drawable-mdpi
│ │ └── ic_launcher.png
│ ├── drawable-xhdpi
│ │ ├── ic_launcher.png
│ │ ├── jmui_back_btn.png
│ │ ├── jmui_business_card.png
│ │ ├── jmui_cancel_record.png
│ │ ├── jmui_chat_detail.png
│ │ ├── jmui_expression1.png
│ │ ├── jmui_fetch_failed.png
│ │ ├── jmui_group.png
│ │ ├── jmui_head_icon.png
│ │ ├── jmui_keyboard.png
│ │ ├── jmui_location.png
│ │ ├── jmui_mic_1.png
│ │ ├── jmui_mic_2.png
│ │ ├── jmui_mic_3.png
│ │ ├── jmui_mic_4.png
│ │ ├── jmui_mic_5.png
│ │ ├── jmui_more_menu.png
│ │ ├── jmui_pick_picture.png
│ │ ├── jmui_picture_not_found.png
│ │ ├── jmui_receive_1.png
│ │ ├── jmui_receive_2.png
│ │ ├── jmui_receive_3.png
│ │ ├── jmui_receive_msg.9.png
│ │ ├── jmui_send_1.png
│ │ ├── jmui_send_2.png
│ │ ├── jmui_send_3.png
│ │ ├── jmui_send_error.png
│ │ ├── jmui_send_msg.9.png
│ │ ├── jmui_sending_img.png
│ │ ├── jmui_take_photo.png
│ │ ├── jmui_video.png
│ │ ├── jmui_voice.png
│ │ └── jmui_voice_unread.png
│ ├── drawable-xxhdpi
│ │ └── ic_launcher.png
│ ├── drawable-xxxhdpi
│ │ └── ic_launcher.png
│ ├── drawable
│ │ ├── jmui_back_btn_bg.xml
│ │ ├── jmui_chat_input_bg.xml
│ │ ├── jmui_dialog_bottom_btn_bg.xml
│ │ ├── jmui_dialog_bottom_left_btn.xml
│ │ ├── jmui_dialog_bottom_right_btn.xml
│ │ ├── jmui_dialog_default_bg.xml
│ │ ├── jmui_dialog_top_btn_bg.xml
│ │ ├── jmui_list_item_bg.xml
│ │ ├── jmui_loading.xml
│ │ ├── jmui_msg_receive_bg.xml
│ │ ├── jmui_msg_send_bg.xml
│ │ ├── jmui_register_btn_bg.xml
│ │ ├── jmui_round_background.xml
│ │ ├── jmui_send_picture_btn_bg.xml
│ │ ├── jmui_text_cursor_bg.xml
│ │ ├── jmui_toast_default_bg.xml
│ │ └── jmui_voice_bg.xml
│ ├── layout
│ │ ├── jmui_activity_about.xml
│ │ ├── jmui_activity_chat.xml
│ │ ├── jmui_activity_main.xml
│ │ ├── jmui_chat_item_group_change.xml
│ │ ├── jmui_chat_item_receive_image.xml
│ │ ├── jmui_chat_item_receive_text.xml
│ │ ├── jmui_chat_item_receive_voice.xml
│ │ ├── jmui_chat_item_send_image.xml
│ │ ├── jmui_chat_item_send_text.xml
│ │ ├── jmui_chat_item_send_voice.xml
│ │ ├── jmui_default_toast.xml
│ │ ├── jmui_dialog_base.xml
│ │ ├── jmui_dialog_base_with_button.xml
│ │ ├── jmui_dialog_msg_alert.xml
│ │ ├── jmui_dialog_record_voice.xml
│ │ ├── jmui_drop_down_list_header.xml
│ │ ├── jmui_loading_view.xml
│ │ └── jmui_menu_title_bar.xml
│ ├── menu
│ │ └── menu_main.xml
│ ├── values-v21
│ │ └── styles.xml
│ ├── values-w820dp
│ │ └── dimens.xml
│ └── values
│ │ ├── attrs.xml
│ │ ├── colors.xml
│ │ ├── dimens.xml
│ │ ├── strings.xml
│ │ └── styles.xml
└── src
│ └── cn
│ └── jmessage
│ └── android
│ └── uikit
│ ├── AboutActivity.java
│ ├── DemoActivity.java
│ └── chatting
│ ├── BaseActivity.java
│ ├── BaseImageView.java
│ ├── BubbleImageView.java
│ ├── ChatActivity.java
│ ├── ChatView.java
│ ├── CircleImageView.java
│ ├── DropDownListView.java
│ ├── MsgListAdapter.java
│ ├── RecordVoiceButton.java
│ ├── ShaderImageView.java
│ ├── photoview
│ ├── Compat.java
│ ├── IPhotoView.java
│ ├── PhotoView.java
│ ├── PhotoViewAttacher.java
│ ├── SDK16.java
│ ├── ScrollerProxy.java
│ └── VersionedGestureDetector.java
│ ├── shader
│ ├── BubbleShader.java
│ └── ShaderHelper.java
│ └── utils
│ ├── BitmapLoader.java
│ ├── DialogCreator.java
│ ├── Event.java
│ ├── FileHelper.java
│ ├── HandleResponseCode.java
│ ├── IdHelper.java
│ ├── SharePreferenceManager.java
│ └── TimeFormat.java
├── GroupChatDetail
├── .gitignore
├── AndroidManifest.xml
├── README.md
├── build.gradle
├── libs
│ ├── android-support-v4.jar
│ ├── android-support-v7-appcompat.jar
│ ├── arm64-v8a
│ │ └── libjpush206.so
│ ├── armeabi-v7a
│ │ └── libjpush206.so
│ ├── armeabi
│ │ └── libjpush206.so
│ ├── jmessage-android-debug-1.2.0b777.jar
│ ├── mips
│ │ └── libjpush206.so
│ ├── mips64
│ │ └── libjpush206.so
│ ├── x86
│ │ └── libjpush206.so
│ └── x86_64
│ │ └── libjpush206.so
├── proguard-rules.pro
├── res
│ ├── drawable-hdpi
│ │ ├── ic_launcher.png
│ │ ├── jmui_loading_1.png
│ │ ├── jmui_loading_10.png
│ │ ├── jmui_loading_11.png
│ │ ├── jmui_loading_12.png
│ │ ├── jmui_loading_13.png
│ │ ├── jmui_loading_14.png
│ │ ├── jmui_loading_2.png
│ │ ├── jmui_loading_3.png
│ │ ├── jmui_loading_4.png
│ │ ├── jmui_loading_5.png
│ │ ├── jmui_loading_6.png
│ │ ├── jmui_loading_7.png
│ │ ├── jmui_loading_8.png
│ │ └── jmui_loading_9.png
│ ├── drawable-mdpi
│ │ └── ic_launcher.png
│ ├── drawable-xhdpi
│ │ ├── ic_launcher.png
│ │ ├── jmui_arrow.png
│ │ ├── jmui_back_btn.png
│ │ ├── jmui_chat_detail.png
│ │ ├── jmui_chat_detail_add.png
│ │ ├── jmui_chat_detail_del.png
│ │ ├── jmui_head_icon.png
│ │ └── jmui_search.png
│ ├── drawable-xxhdpi
│ │ └── ic_launcher.png
│ ├── drawable-xxxhdpi
│ │ └── ic_launcher.png
│ ├── drawable
│ │ ├── jmui_back_btn_bg.xml
│ │ ├── jmui_chat_detail_btn_bg.xml
│ │ ├── jmui_default_input_bg.xml
│ │ ├── jmui_dialog_bottom_btn_bg.xml
│ │ ├── jmui_dialog_bottom_left_btn.xml
│ │ ├── jmui_dialog_bottom_right_btn.xml
│ │ ├── jmui_dialog_default_bg.xml
│ │ ├── jmui_edit_text_bg.9.png
│ │ ├── jmui_list_item_bg.xml
│ │ ├── jmui_loading.xml
│ │ ├── jmui_send_picture_btn_bg.xml
│ │ ├── jmui_text_cursor_bg.xml
│ │ └── jmui_toast_default_bg.xml
│ ├── layout
│ │ ├── jmui_activity_all_members.xml
│ │ ├── jmui_activity_group_detail.xml
│ │ ├── jmui_activity_main.xml
│ │ ├── jmui_all_member_item.xml
│ │ ├── jmui_dialog_add_friend_to_conv_list.xml
│ │ ├── jmui_dialog_base.xml
│ │ ├── jmui_dialog_base_with_button.xml
│ │ ├── jmui_dialog_reset_password.xml
│ │ ├── jmui_group_grid_view_item.xml
│ │ ├── jmui_loading_view.xml
│ │ ├── jmui_menu_title_bar.xml
│ │ └── jmui_toast_default_style.xml
│ ├── values-w820dp
│ │ └── dimens.xml
│ └── values
│ │ ├── colors.xml
│ │ ├── dimens.xml
│ │ ├── strings.xml
│ │ └── styles.xml
└── src
│ └── cn
│ └── jmessage
│ └── android
│ └── uikit
│ ├── DemoActivity.java
│ └── groupchatdetail
│ ├── AllMembersAdapter.java
│ ├── BaseActivity.java
│ ├── BaseImageView.java
│ ├── BitmapLoader.java
│ ├── ChatDetailView.java
│ ├── CircleImageView.java
│ ├── DialogCreator.java
│ ├── GroupDetailActivity.java
│ ├── GroupGridView.java
│ ├── GroupMemberGridAdapter.java
│ ├── HandleResponseCode.java
│ ├── HanziToPinyin.java
│ ├── IdHelper.java
│ └── MembersInChatActivity.java
├── LICENSE
├── MultiSelectPhotos
├── .gitignore
├── README.md
├── build.gradle
├── libs
│ ├── android-support-v4.jar
│ ├── android-support-v7-appcompat.jar
│ └── nineoldandroids-2.4.0.jar
├── proguard-rules.pro
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── java
│ └── cn
│ │ └── jmessage
│ │ └── android
│ │ └── uikit
│ │ ├── DemoActivity.java
│ │ └── multiselectphotos
│ │ ├── AlbumListActivity.java
│ │ ├── AlbumListAdapter.java
│ │ ├── AlbumListView.java
│ │ ├── BaseActivity.java
│ │ ├── BitmapLoader.java
│ │ ├── BrowserView.java
│ │ ├── BrowserViewPagerActivity.java
│ │ ├── DialogCreator.java
│ │ ├── ImageBean.java
│ │ ├── ImgBrowserViewPager.java
│ │ ├── MyImageView.java
│ │ ├── NativeImageLoader.java
│ │ ├── PickPictureActivity.java
│ │ ├── PickPictureAdapter.java
│ │ ├── PickPictureView.java
│ │ ├── SortPictureList.java
│ │ └── photoview
│ │ ├── Compat.java
│ │ ├── IPhotoView.java
│ │ ├── PhotoView.java
│ │ ├── PhotoViewAttacher.java
│ │ ├── SDK16.java
│ │ ├── ScrollerProxy.java
│ │ └── VersionedGestureDetector.java
│ └── res
│ ├── drawable
│ ├── jmui_back_btn_bg.xml
│ ├── jmui_default_check_box_style.xml
│ ├── jmui_download_image_btn_bg.xml
│ ├── jmui_loading.xml
│ ├── jmui_pictures_selected_bg.xml
│ ├── jmui_round_check_box_bg.xml
│ └── jmui_send_picture_btn_bg.xml
│ ├── layout
│ ├── jmui_activity_album_list.xml
│ ├── jmui_activity_image_browser.xml
│ ├── jmui_activity_main.xml
│ ├── jmui_activity_pick_picture_detail.xml
│ ├── jmui_album_list_item.xml
│ ├── jmui_loading_view.xml
│ └── jmui_pick_picture_detail_grid_item.xml
│ ├── mipmap-hdpi
│ ├── ic_launcher.png
│ ├── jmui_loading_1.png
│ ├── jmui_loading_10.png
│ ├── jmui_loading_11.png
│ ├── jmui_loading_12.png
│ ├── jmui_loading_13.png
│ ├── jmui_loading_14.png
│ ├── jmui_loading_2.png
│ ├── jmui_loading_3.png
│ ├── jmui_loading_4.png
│ ├── jmui_loading_5.png
│ ├── jmui_loading_6.png
│ ├── jmui_loading_7.png
│ ├── jmui_loading_8.png
│ └── jmui_loading_9.png
│ ├── mipmap-mdpi
│ └── ic_launcher.png
│ ├── mipmap-xhdpi
│ ├── ic_launcher.png
│ ├── jmui_arrow.png
│ ├── jmui_back_btn.png
│ ├── jmui_default_check_box_checked.png
│ ├── jmui_picture_not_found.png
│ ├── jmui_round_check_box_checked.png
│ ├── jmui_round_check_box_normal.png
│ ├── jmui_selected.png
│ └── jmui_unselected.png
│ ├── mipmap-xxhdpi
│ └── ic_launcher.png
│ ├── mipmap-xxxhdpi
│ └── ic_launcher.png
│ ├── values-w820dp
│ └── dimens.xml
│ └── values
│ ├── colors.xml
│ ├── dimens.xml
│ ├── strings.xml
│ └── styles.xml
├── README.md
├── RecordVoice
├── .gitignore
├── README.md
├── build.gradle
├── proguard-rules.pro
└── src
│ └── main
│ ├── AndroidManifest.xml
│ ├── java
│ └── cn
│ │ └── jmessage
│ │ └── android
│ │ └── uikit
│ │ ├── BaseImageView.java
│ │ ├── CircleImageView.java
│ │ ├── DemoActivity.java
│ │ ├── ListAdapter.java
│ │ ├── VoiceMessage.java
│ │ └── recordvoice
│ │ ├── IdHelper.java
│ │ └── RecordVoiceButton.java
│ └── res
│ ├── drawable-hdpi
│ └── ic_launcher.png
│ ├── drawable-mdpi
│ └── ic_launcher.png
│ ├── drawable-xhdpi
│ ├── ic_launcher.png
│ ├── jmui_cancel_record.png
│ ├── jmui_head_icon.png
│ ├── jmui_mic_1.png
│ ├── jmui_mic_2.png
│ ├── jmui_mic_3.png
│ ├── jmui_mic_4.png
│ ├── jmui_mic_5.png
│ ├── jmui_send_1.png
│ ├── jmui_send_2.png
│ ├── jmui_send_3.png
│ └── jmui_send_msg.9.png
│ ├── drawable-xxhdpi
│ └── ic_launcher.png
│ ├── drawable-xxxhdpi
│ └── ic_launcher.png
│ ├── drawable
│ ├── jmui_msg_send_bg.xml
│ ├── jmui_round_background.xml
│ ├── jmui_voice_bg.xml
│ └── jmui_voice_send.xml
│ ├── layout
│ ├── jmui_activity_main.xml
│ ├── jmui_chat_item_send_voice.xml
│ └── jmui_dialog_record_voice.xml
│ ├── values-w820dp
│ └── dimens.xml
│ └── values
│ ├── colors.xml
│ ├── dimens.xml
│ ├── strings.xml
│ └── styles.xml
├── build.gradle
├── gradle.properties
├── gradle
└── wrapper
│ ├── gradle-wrapper.jar
│ └── gradle-wrapper.properties
├── gradlew
├── gradlew.bat
└── settings.gradle
/.gitignore:
--------------------------------------------------------------------------------
1 | # Built application files
2 | *.apk
3 | *.ap_
4 |
5 | # Files for the Dalvik VM
6 | *.dex
7 |
8 | # Java class files
9 | *.class
10 |
11 | # Generated files
12 | bin/
13 | gen/
14 |
15 | # Gradle files
16 | .gradle/
17 | build/
18 | /*/build/
19 |
20 | # Local configuration file (sdk path, etc)
21 | local.properties
22 |
23 | # Proguard folder generated by Eclipse
24 | proguard/
25 |
26 | # Log Files
27 | *.log
28 | *.iml
29 | .gradle
30 | /local.properties
31 | /.idea/workspace.xml
32 | /.idea/libraries
33 | /.idea
34 | .DS_Store
35 | /build
36 | /captures
37 |
--------------------------------------------------------------------------------
/Chatting/.gitignore:
--------------------------------------------------------------------------------
1 | # Built application files
2 | *.apk
3 | *.ap_
4 |
5 | # Files for the Dalvik VM
6 | *.dex
7 |
8 | # Java class files
9 | *.class
10 |
11 | # Generated files
12 | bin/
13 | gen/
14 |
15 | # Gradle files
16 | .gradle/
17 | build/
18 | /*/build/
19 |
20 | # Local configuration file (sdk path, etc)
21 | local.properties
22 |
23 | # Proguard folder generated by Eclipse
24 | proguard/
25 |
26 | # Log Files
27 | *.log
28 |
--------------------------------------------------------------------------------
/Chatting/LICENSE:
--------------------------------------------------------------------------------
1 | The MIT License (MIT)
2 |
3 | Copyright (c) 2015 极光推送 JPush
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
23 |
--------------------------------------------------------------------------------
/Chatting/libs/arm64-v8a/libjpush211.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/arm64-v8a/libjpush211.so
--------------------------------------------------------------------------------
/Chatting/libs/armeabi-v7a/libjpush211.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/armeabi-v7a/libjpush211.so
--------------------------------------------------------------------------------
/Chatting/libs/armeabi/libjpush211.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/armeabi/libjpush211.so
--------------------------------------------------------------------------------
/Chatting/libs/eventbus.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/eventbus.jar
--------------------------------------------------------------------------------
/Chatting/libs/jmessage-android-1.2.1.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/jmessage-android-1.2.1.jar
--------------------------------------------------------------------------------
/Chatting/libs/mips/libjpush211.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/mips/libjpush211.so
--------------------------------------------------------------------------------
/Chatting/libs/mips64/libjpush211.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/mips64/libjpush211.so
--------------------------------------------------------------------------------
/Chatting/libs/nineoldandroids-2.4.0.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/nineoldandroids-2.4.0.jar
--------------------------------------------------------------------------------
/Chatting/libs/picasso-2.4.0.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/picasso-2.4.0.jar
--------------------------------------------------------------------------------
/Chatting/libs/x86/libjpush211.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/x86/libjpush211.so
--------------------------------------------------------------------------------
/Chatting/libs/x86_64/libjpush211.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/libs/x86_64/libjpush211.so
--------------------------------------------------------------------------------
/Chatting/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /Users/huminios/Library/Android/sdk/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/Chatting/res/anim/jmui_rotate.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
12 |
13 |
--------------------------------------------------------------------------------
/Chatting/res/anim/jmui_slide_in_from_left.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
8 |
9 |
--------------------------------------------------------------------------------
/Chatting/res/anim/jmui_slide_in_from_right.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
8 |
9 |
--------------------------------------------------------------------------------
/Chatting/res/anim/jmui_slide_out_to_left.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
8 |
9 |
--------------------------------------------------------------------------------
/Chatting/res/anim/jmui_slide_out_to_right.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
8 |
9 |
--------------------------------------------------------------------------------
/Chatting/res/anim/jmui_voice_receive.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
7 |
10 |
13 |
--------------------------------------------------------------------------------
/Chatting/res/anim/jmui_voice_send.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
7 |
10 |
13 |
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_1.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_10.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_11.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_12.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_13.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_14.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_2.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_3.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_4.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_5.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_6.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_7.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_8.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-hdpi/jmui_loading_9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-hdpi/jmui_loading_9.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_back_btn.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_back_btn.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_business_card.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_business_card.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_cancel_record.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_cancel_record.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_chat_detail.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_chat_detail.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_expression1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_expression1.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_fetch_failed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_fetch_failed.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_group.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_group.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_head_icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_head_icon.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_keyboard.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_keyboard.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_location.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_location.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_mic_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_mic_1.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_mic_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_mic_2.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_mic_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_mic_3.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_mic_4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_mic_4.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_mic_5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_mic_5.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_more_menu.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_more_menu.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_pick_picture.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_pick_picture.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_picture_not_found.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_picture_not_found.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_receive_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_receive_1.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_receive_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_receive_2.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_receive_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_receive_3.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_receive_msg.9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_receive_msg.9.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_send_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_send_1.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_send_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_send_2.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_send_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_send_3.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_send_error.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_send_error.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_send_msg.9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_send_msg.9.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_sending_img.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_sending_img.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_take_photo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_take_photo.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_video.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_video.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_voice.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_voice.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xhdpi/jmui_voice_unread.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xhdpi/jmui_voice_unread.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/Chatting/res/drawable-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/Chatting/res/drawable-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_back_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_chat_input_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 | -
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_dialog_bottom_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
11 | -
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_dialog_bottom_left_btn.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 | -
11 |
12 |
-
13 |
14 |
15 |
16 |
17 |
18 |
19 | -
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_dialog_bottom_right_btn.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
9 | -
10 |
11 |
-
12 |
13 |
14 |
15 |
16 |
17 |
18 | -
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_dialog_default_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
8 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_dialog_top_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
11 | -
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_list_item_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_loading.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_msg_receive_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_msg_send_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_register_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
9 | -
10 |
11 |
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_round_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_send_picture_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_text_cursor_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_toast_default_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/Chatting/res/drawable/jmui_voice_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
9 | -
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_activity_about.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
15 |
16 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
10 |
11 |
20 |
21 |
26 |
27 |
34 |
35 |
36 |
37 |
41 |
42 |
43 |
52 |
53 |
58 |
59 |
66 |
67 |
68 |
69 |
73 |
74 |
75 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_chat_item_group_change.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
14 |
15 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_chat_item_receive_image.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
9 |
10 |
14 |
15 |
18 |
19 |
25 |
26 |
35 |
36 |
37 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_chat_item_receive_text.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
9 |
10 |
11 |
15 |
16 |
19 |
20 |
27 |
28 |
41 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_chat_item_send_image.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
9 |
10 |
14 |
15 |
18 |
19 |
28 |
29 |
37 |
38 |
46 |
47 |
48 |
56 |
57 |
68 |
69 |
70 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_chat_item_send_text.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
9 |
10 |
14 |
15 |
16 |
27 |
28 |
36 |
37 |
48 |
49 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_default_toast.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
14 |
15 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_dialog_base.xml:
--------------------------------------------------------------------------------
1 |
2 |
9 |
10 |
19 |
20 |
21 |
30 |
34 |
35 |
36 |
44 |
45 |
46 |
47 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_dialog_base_with_button.xml:
--------------------------------------------------------------------------------
1 |
2 |
10 |
11 |
12 |
22 |
23 |
24 |
27 |
28 |
37 |
38 |
47 |
48 |
49 |
50 |
51 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_dialog_msg_alert.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
16 |
17 |
21 |
22 |
28 |
29 |
30 |
35 |
36 |
42 |
43 |
48 |
49 |
50 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_dialog_record_voice.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
12 |
13 |
19 |
20 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_drop_down_list_header.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
17 |
18 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_loading_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
14 |
15 |
23 |
24 |
--------------------------------------------------------------------------------
/Chatting/res/layout/jmui_menu_title_bar.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
18 |
19 |
29 |
30 |
41 |
42 |
43 |
44 |
--------------------------------------------------------------------------------
/Chatting/res/menu/menu_main.xml:
--------------------------------------------------------------------------------
1 |
11 |
--------------------------------------------------------------------------------
/Chatting/res/values-v21/styles.xml:
--------------------------------------------------------------------------------
1 | >
2 |
3 |
4 |
--------------------------------------------------------------------------------
/Chatting/res/values-w820dp/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 64dp
6 |
7 |
--------------------------------------------------------------------------------
/Chatting/res/values/attrs.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 |
50 |
51 |
52 |
53 |
54 |
55 |
56 |
57 |
58 |
59 |
60 |
61 |
62 |
--------------------------------------------------------------------------------
/Chatting/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | #373334
5 | #dddddd
6 | #3f80dc
7 | #346fc3
8 | #8db4eb
9 | #d4d4d4
10 | #60000000
11 |
12 | #000000
13 | #808080
14 |
15 |
16 |
17 | #808080
18 |
19 |
20 |
21 |
22 | #008000
23 |
24 |
25 |
26 | #006400
27 |
28 |
29 |
30 | #0000FF
31 |
32 |
33 |
34 | #FFFFFF
35 |
36 | #8CA4FF
37 |
--------------------------------------------------------------------------------
/Chatting/res/values/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | 20sp
6 | 5dp
7 | 28dp
8 | 40dp
9 |
10 |
11 | 18sp
12 | 80dp
13 | 18sp
14 | 70dp
15 |
16 |
17 | 10sp
18 | 12sp
19 | 14sp
20 | 18sp
21 | 22sp
22 | 5dp
23 | 5dp
24 | 15dp
25 | 15dp
26 | 5dp
27 | 50dp
28 | 40dp
29 | 30dp
30 | 16dp
31 | 16dp
32 | 75dp
33 | 12dp
34 | 5dp
35 | 0dp
36 | 36dp
37 | 0dp
38 |
39 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/AboutActivity.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit;
2 |
3 | import android.app.Activity;
4 | import android.os.Bundle;
5 |
6 |
7 | public class AboutActivity extends Activity {
8 |
9 | @Override
10 | protected void onCreate(Bundle savedInstanceState) {
11 | super.onCreate(savedInstanceState);
12 | setContentView(R.layout.jmui_activity_about);
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/BubbleImageView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.chatting;
2 | /**
3 | *The MIT License (MIT)
4 |
5 | Copyright (c) 2015 Siyamed Sinir
6 |
7 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
8 |
9 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
10 |
11 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
12 | */
13 | import android.content.Context;
14 | import android.util.AttributeSet;
15 |
16 | import cn.jmessage.android.uikit.chatting.shader.BubbleShader;
17 | import cn.jmessage.android.uikit.chatting.shader.ShaderHelper;
18 |
19 |
20 | public class BubbleImageView extends ShaderImageView {
21 |
22 | public BubbleImageView(Context context) {
23 | super(context);
24 | }
25 |
26 | public BubbleImageView(Context context, AttributeSet attrs) {
27 | super(context, attrs);
28 | }
29 |
30 | public BubbleImageView(Context context, AttributeSet attrs, int defStyle) {
31 | super(context, attrs, defStyle);
32 | }
33 |
34 | @Override
35 | public ShaderHelper createImageViewHelper() {
36 | return new BubbleShader();
37 | }
38 | }
39 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/CircleImageView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.chatting;
2 |
3 | import android.content.Context;
4 | import android.graphics.Bitmap;
5 | import android.graphics.Canvas;
6 | import android.graphics.Color;
7 | import android.graphics.Paint;
8 | import android.graphics.RectF;
9 | import android.util.AttributeSet;
10 |
11 | public class CircleImageView extends BaseImageView {
12 |
13 | public CircleImageView(Context context) {
14 | super(context);
15 | }
16 |
17 | public CircleImageView(Context context, AttributeSet attrs) {
18 | super(context, attrs);
19 | }
20 |
21 | public CircleImageView(Context context, AttributeSet attrs, int defStyle) {
22 | super(context, attrs, defStyle);
23 | }
24 |
25 | public static Bitmap getBitmap(int width, int height) {
26 | Bitmap bitmap = Bitmap.createBitmap(width, height,
27 | Bitmap.Config.ARGB_8888);
28 | Canvas canvas = new Canvas(bitmap);
29 | Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG);
30 | paint.setColor(Color.BLACK);
31 | canvas.drawOval(new RectF(0.0f, 0.0f, width, height), paint);
32 |
33 | return bitmap;
34 | }
35 |
36 | @Override
37 | public Bitmap getBitmap() {
38 | return getBitmap(getWidth(), getHeight());
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/photoview/Compat.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.chatting.photoview;
2 |
3 | import android.os.Build.VERSION;
4 | import android.view.View;
5 |
6 | public class Compat {
7 |
8 | private static final int SIXTY_FPS_INTERVAL = 1000 / 60;
9 |
10 | public static void postOnAnimation(View view, Runnable runnable) {
11 | if (VERSION.SDK_INT >= 16) {
12 | SDK16.postOnAnimation(view, runnable);
13 | } else {
14 | view.postDelayed(runnable, SIXTY_FPS_INTERVAL);
15 | }
16 | }
17 |
18 | }
19 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/photoview/SDK16.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright 2011, 2012 Chris Banes.
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | *******************************************************************************/
16 | package cn.jmessage.android.uikit.chatting.photoview;
17 |
18 | import android.annotation.TargetApi;
19 | import android.view.View;
20 |
21 | @TargetApi(16)
22 | public class SDK16 {
23 |
24 | public static void postOnAnimation(View view, Runnable r) {
25 | view.postOnAnimation(r);
26 | }
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/utils/BitmapLoader.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.chatting.utils;
2 |
3 | import android.graphics.Bitmap;
4 | import android.graphics.BitmapFactory;
5 |
6 | /**
7 | * Created by Ken on 2015/2/9.
8 | */
9 | public class BitmapLoader {
10 |
11 | public static Bitmap getBitmapFromFile(String path, int width, int height) {
12 | BitmapFactory.Options opts = null;
13 | if (path != null) {
14 | if (width > 0 && height > 0) {
15 | opts = new BitmapFactory.Options();
16 | opts.inJustDecodeBounds = true;
17 | BitmapFactory.decodeFile(path, opts);
18 | final int minSideLength = Math.min(width, height);
19 | opts.inSampleSize = computeSampleSize(opts, minSideLength,
20 | width * height);
21 | opts.inJustDecodeBounds = false;
22 | }
23 | return BitmapFactory.decodeFile(path, opts);
24 | } else return null;
25 | }
26 |
27 | public static int computeSampleSize(BitmapFactory.Options options,
28 | int minSideLength, int maxNumOfPixels) {
29 | int initialSize = computeInitialSampleSize(options, minSideLength,
30 | maxNumOfPixels);
31 |
32 | int roundedSize;
33 | if (initialSize <= 8) {
34 | roundedSize = 1;
35 | while (roundedSize < initialSize) {
36 | roundedSize <<= 1;
37 | }
38 | } else {
39 | roundedSize = (initialSize + 7) / 8 * 8;
40 | }
41 |
42 | return roundedSize;
43 | }
44 |
45 | private static int computeInitialSampleSize(BitmapFactory.Options options,
46 | int minSideLength, int maxNumOfPixels) {
47 | double w = options.outWidth;
48 | double h = options.outHeight;
49 |
50 | int lowerBound = (maxNumOfPixels == -1) ? 1 : (int) Math.ceil(Math
51 | .sqrt(w * h / maxNumOfPixels));
52 | int upperBound = (minSideLength == -1) ? 128 : (int) Math.min(Math
53 | .floor(w / minSideLength), Math.floor(h / minSideLength));
54 |
55 | if (upperBound < lowerBound) {
56 | // return the larger one when there is no overlapping zone.
57 | return lowerBound;
58 | }
59 |
60 | if ((maxNumOfPixels == -1) && (minSideLength == -1)) {
61 | return 1;
62 | } else if (minSideLength == -1) {
63 | return lowerBound;
64 | } else {
65 | return upperBound;
66 | }
67 | }
68 |
69 | }
70 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/utils/Event.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.chatting.utils;
2 |
3 | public class Event {
4 |
5 | /**
6 | * 传递到ConversationListFragment的创建单聊事件
7 | * mTargetId 单聊Id
8 | * mAppKey 可以得到创建单聊者的AppKey
9 | */
10 | public static class StringEvent{
11 | private String mTargetId;
12 | private String mAppKey;
13 |
14 | public StringEvent(String targetId, String appKey) {
15 | this.mTargetId = targetId;
16 | this.mAppKey = appKey;
17 | }
18 |
19 | public String getTargetId(){
20 | return mTargetId;
21 | }
22 |
23 | public String getAppKey() {
24 | return mAppKey;
25 | }
26 | }
27 |
28 | /**
29 | * 传递到ConversationListFragment的创建或删除群聊事件
30 | * mGroupId 群聊Id
31 | * mIsAddEvent 是否为创建群聊的标志
32 | */
33 | public static class LongEvent{
34 | private long mGroupId;
35 | private boolean mIsAddEvent;
36 |
37 | public LongEvent(boolean isAddEvent, long groupId){
38 | this.mIsAddEvent = isAddEvent;
39 | this.mGroupId = groupId;
40 | }
41 |
42 | public long getGroupId(){
43 | return mGroupId;
44 | }
45 |
46 | public boolean getFlag() {
47 | return mIsAddEvent;
48 | }
49 | }
50 |
51 | /**
52 | * 传递到ConversationListFragment的保存为草稿的事件
53 | * mDraft 草稿内容
54 | */
55 | public static class DraftEvent {
56 | private String mTargetId;
57 | private long mGroupId;
58 | private String mTargetAppKey;
59 | private String mDraft;
60 |
61 | public DraftEvent(String targetId, String appKey, String draft) {
62 | this.mTargetId = targetId;
63 | this.mTargetAppKey = appKey;
64 | this.mDraft = draft;
65 | }
66 |
67 | public DraftEvent(long groupId, String draft) {
68 | this.mGroupId = groupId;
69 | this.mDraft = draft;
70 | }
71 |
72 | public String getTargetId() {
73 | return mTargetId;
74 | }
75 |
76 |
77 | public long getGroupId() {
78 | return mGroupId;
79 | }
80 |
81 | public String getTargetAppKey() {
82 | return mTargetAppKey;
83 | }
84 |
85 | public String getDraft() {
86 | return mDraft;
87 | }
88 | }
89 |
90 | }
91 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/utils/FileHelper.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.chatting.utils;
2 |
3 | import android.os.Environment;
4 | import android.text.format.DateFormat;
5 |
6 | import java.io.File;
7 | import java.util.Calendar;
8 | import java.util.Locale;
9 |
10 | /**
11 | * Created by Ken on 2015/11/13.
12 | */
13 | public class FileHelper {
14 |
15 | public static final String PICTURE_DIR = "sdcard/JChatDemo/pictures/";
16 |
17 | private static FileHelper mInstance = new FileHelper();
18 |
19 | public static FileHelper getInstance() {
20 | return mInstance;
21 | }
22 |
23 | public static boolean isSdCardExist() {
24 | return Environment.getExternalStorageState().equals(Environment.MEDIA_MOUNTED);
25 | }
26 |
27 | public static String getUserAvatarPath(String userName) {
28 | return PICTURE_DIR + userName + ".png";
29 | }
30 |
31 | public static String createAvatarPath(String userName) {
32 | String dir = PICTURE_DIR;
33 | File destDir = new File(dir);
34 | if (!destDir.exists()) {
35 | destDir.mkdirs();
36 | }
37 | File file;
38 | if (userName != null) {
39 | file = new File(dir, userName + ".png");
40 | }else {
41 | file = new File(dir, new DateFormat().format("yyyy_MMdd_hhmmss",
42 | Calendar.getInstance(Locale.CHINA)) + ".png");
43 | }
44 | return file.getAbsolutePath();
45 | }
46 | }
47 |
--------------------------------------------------------------------------------
/Chatting/src/cn/jmessage/android/uikit/chatting/utils/IdHelper.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.chatting.utils;
2 |
3 | import android.content.Context;
4 | import java.lang.reflect.Field;
5 |
6 | public class IdHelper {
7 |
8 | public static int getLayout(Context context, String layoutName) {
9 | return context.getResources().getIdentifier(layoutName, "layout",
10 | context.getApplicationContext().getPackageName());
11 | }
12 |
13 | public static int getViewID(Context context, String IDName) {
14 | return context.getResources().getIdentifier(IDName, "id",
15 | context.getApplicationContext().getPackageName());
16 | }
17 |
18 | public static int getDrawable(Context context, String drawableName) {
19 | return context.getResources().getIdentifier(drawableName, "drawable",
20 | context.getApplicationContext().getPackageName());
21 | }
22 |
23 | public static int getAttr(Context context, String attrName) {
24 | return context.getResources().getIdentifier(attrName, "attr",
25 | context.getApplicationContext().getPackageName());
26 | }
27 |
28 | public static int getString(Context context, String stringName) {
29 | return context.getResources().getIdentifier(stringName, "string",
30 | context.getApplicationContext().getPackageName());
31 | }
32 |
33 | public static int getStyle(Context context, String styleName) {
34 | return context.getResources().getIdentifier(styleName, "style",
35 | context.getApplicationContext().getPackageName());
36 | }
37 |
38 | public static int[] getResourceDeclareStyleableIntArray(Context context, String name) {
39 | try {
40 | Field[] fields2 = Class.forName(context.getPackageName() + ".R$styleable").getFields();
41 |
42 | //browse all fields
43 | for (Field f : fields2) {
44 | //pick matching field
45 | if (f.getName().equals(name)) {
46 | //return as int array
47 | return (int[]) f.get(null);
48 | }
49 | }
50 | } catch (Throwable t) {
51 | t.printStackTrace();
52 | }
53 |
54 | return null;
55 | }
56 |
57 | public static int getAnim(Context context, String animName) {
58 | return context.getResources().getIdentifier(animName, "anim",
59 | context.getApplicationContext().getPackageName());
60 | }
61 | }
62 |
--------------------------------------------------------------------------------
/GroupChatDetail/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/GroupChatDetail/README.md:
--------------------------------------------------------------------------------
1 | # jmessage-android-ui-components
2 | IM SDK UI 组件
3 |
4 |
5 | 简单的群聊详情组件, 实现了添加删除群成员功能.
6 |
7 | ###用法:
8 |
9 | - 复制groupchatdetail文件夹下的文件到你的项目.
10 |
11 | - 配置AndroidManifest, 详情参考[JChat的AndroidManifest配置](https://github.com/jpush/jchat-android/blob/master/README.md)
12 |
13 | - 复制资源文件到你的项目, 你可以自定义界面的样式
14 |
15 | - 在XML文件中将引用路径修改为你当前的路径, 如图:
16 | 
17 |
18 | - 配置用户信息, 在MainActivity中设置登录用户和群组id,然后传递到GroupDetailActivity.
19 |
20 | - 关于注册用户和创建群组
21 |
22 | 你可以调用JMessageClient.register(username, password, callback)来注册用户, 也可以使用curl的方式注册用户:
23 |
24 | ```
25 |
26 | curl --insecure -X POST -v https://api.im.jpush.cn/v1/users -H "Content-Type: application/json" -u "your AppKey:your master secret" -d '[{"username":"user003", "password": "1111"}]'
27 |
28 | ```
29 |
30 | 注册群组, 同样可以使用JMessageClient.createGroup("", "", new CreateGroupCallback(){}), 或者使用curl:
31 |
32 | ```
33 |
34 | curl --insecure -X POST -v https://api.im.jpush.cn/v1/groups -H "Content-Type: application/json" -u "your AppKey:your master secret" -d '{"owner_username":"user001", "name": "example group", "members_username":["user002","user003"],"desc":"example"}'
35 |
36 | ```
37 |
38 |
--------------------------------------------------------------------------------
/GroupChatDetail/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 |
3 | android {
4 | compileSdkVersion 23
5 | buildToolsVersion "23.0.2"
6 |
7 | defaultConfig {
8 | applicationId "cn.jmessage.android.uicomponents"
9 | minSdkVersion 9
10 | targetSdkVersion 23
11 | versionCode 1
12 | versionName "1.0"
13 | }
14 |
15 | lintOptions {
16 | abortOnError false
17 | disable 'MissingTranslation'
18 | }
19 |
20 | sourceSets {
21 | main {
22 | manifest.srcFile 'AndroidManifest.xml'
23 | jniLibs.srcDirs = ['libs']
24 | java.srcDirs = ['src']
25 | resources.srcDirs = ['src']
26 | aidl.srcDirs = ['src']
27 | renderscript.srcDirs = ['src']
28 | res.srcDirs = ['res']
29 | assets.srcDirs = ['assets'] }
30 |
31 | }
32 | }
33 |
34 | dependencies {
35 | compile fileTree(dir: 'libs', include: ['*.jar'])
36 | testCompile 'junit:junit:4.12'
37 | }
38 |
39 | task jarMyLib(type: Jar, dependsOn: ['build']) {
40 | archiveName = 'jmessage-uikit-groupchatdetail-1.0.0.jar'
41 | from('build/intermediates/classes/release')
42 | destinationDir = file('build/libs')
43 | exclude('cn/jmessage/android/uikit/DemoActivity.class')
44 | exclude('cn/jmessage/android/uikit/DemoActivity\$*.class')
45 | exclude('cn/jmessage/android/uikit/BuildConfig.class')
46 | exclude('cn/jmessage/android/uikit/BuildConfig\$*.class')
47 | exclude('**/R.class')
48 | exclude('**/R\$*.class')
49 | }
50 |
--------------------------------------------------------------------------------
/GroupChatDetail/libs/android-support-v4.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/android-support-v4.jar
--------------------------------------------------------------------------------
/GroupChatDetail/libs/android-support-v7-appcompat.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/android-support-v7-appcompat.jar
--------------------------------------------------------------------------------
/GroupChatDetail/libs/arm64-v8a/libjpush206.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/arm64-v8a/libjpush206.so
--------------------------------------------------------------------------------
/GroupChatDetail/libs/armeabi-v7a/libjpush206.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/armeabi-v7a/libjpush206.so
--------------------------------------------------------------------------------
/GroupChatDetail/libs/armeabi/libjpush206.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/armeabi/libjpush206.so
--------------------------------------------------------------------------------
/GroupChatDetail/libs/jmessage-android-debug-1.2.0b777.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/jmessage-android-debug-1.2.0b777.jar
--------------------------------------------------------------------------------
/GroupChatDetail/libs/mips/libjpush206.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/mips/libjpush206.so
--------------------------------------------------------------------------------
/GroupChatDetail/libs/mips64/libjpush206.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/mips64/libjpush206.so
--------------------------------------------------------------------------------
/GroupChatDetail/libs/x86/libjpush206.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/x86/libjpush206.so
--------------------------------------------------------------------------------
/GroupChatDetail/libs/x86_64/libjpush206.so:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/libs/x86_64/libjpush206.so
--------------------------------------------------------------------------------
/GroupChatDetail/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /Users/huminios/Library/Android/sdk/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_1.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_10.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_11.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_12.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_13.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_14.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_2.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_3.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_4.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_5.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_6.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_7.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_8.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-hdpi/jmui_loading_9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-hdpi/jmui_loading_9.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/jmui_arrow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/jmui_arrow.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/jmui_back_btn.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/jmui_back_btn.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/jmui_chat_detail.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/jmui_chat_detail.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/jmui_chat_detail_add.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/jmui_chat_detail_add.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/jmui_chat_detail_del.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/jmui_chat_detail_del.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/jmui_head_icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/jmui_head_icon.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xhdpi/jmui_search.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xhdpi/jmui_search.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_back_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_chat_detail_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
11 | -
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_default_input_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
-
7 |
8 |
9 |
10 |
11 | -
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 | -
20 |
21 |
-
22 |
23 |
24 |
25 |
26 | -
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_dialog_bottom_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
11 | -
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_dialog_bottom_left_btn.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 | -
11 |
12 |
-
13 |
14 |
15 |
16 |
17 |
18 |
19 | -
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_dialog_bottom_right_btn.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
9 | -
10 |
11 |
-
12 |
13 |
14 |
15 |
16 |
17 |
18 | -
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_dialog_default_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
8 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_edit_text_bg.9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/GroupChatDetail/res/drawable/jmui_edit_text_bg.9.png
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_list_item_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_loading.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_send_picture_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_text_cursor_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/drawable/jmui_toast_default_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
7 |
8 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
11 |
12 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_all_member_item.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
11 |
12 |
13 |
20 |
21 |
28 |
29 |
38 |
39 |
40 |
41 |
49 |
50 |
51 |
52 |
56 |
57 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_dialog_add_friend_to_conv_list.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
19 |
20 |
26 |
27 |
33 |
34 |
45 |
46 |
51 |
52 |
61 |
62 |
71 |
72 |
73 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_dialog_base.xml:
--------------------------------------------------------------------------------
1 |
2 |
9 |
10 |
20 |
21 |
22 |
31 |
35 |
36 |
37 |
45 |
46 |
47 |
48 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_dialog_base_with_button.xml:
--------------------------------------------------------------------------------
1 |
2 |
10 |
11 |
12 |
21 |
22 |
23 |
26 |
27 |
37 |
38 |
48 |
49 |
50 |
51 |
52 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_dialog_reset_password.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
16 |
17 |
25 |
26 |
27 |
39 |
40 |
41 |
42 |
45 |
46 |
55 |
56 |
65 |
66 |
67 |
68 |
69 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_group_grid_view_item.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
9 |
12 |
13 |
20 |
21 |
22 |
23 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_loading_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
13 |
14 |
22 |
23 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_menu_title_bar.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
15 |
16 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/layout/jmui_toast_default_style.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
14 |
15 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/values-w820dp/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 64dp
6 |
7 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #3F51B5
4 | #303F9F
5 | #FF4081
6 | #dddddd
7 | #3f80dc
8 | #d4d4d4
9 | #3773cb
10 | #8db4eb
11 | #808080
12 | #008000
13 | #FFFFFF
14 |
15 |
--------------------------------------------------------------------------------
/GroupChatDetail/res/values/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 16dp
4 | 16dp
5 |
6 |
--------------------------------------------------------------------------------
/GroupChatDetail/src/cn/jmessage/android/uikit/groupchatdetail/BaseActivity.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.groupchatdetail;
2 |
3 | import android.app.Activity;
4 | import android.app.Dialog;
5 | import android.content.Context;
6 | import android.content.pm.ActivityInfo;
7 | import android.os.Bundle;
8 | import android.os.Handler;
9 | import android.os.Message;
10 | import android.util.DisplayMetrics;
11 | import android.view.View;
12 | import android.view.WindowManager;
13 |
14 | import cn.jpush.im.android.api.JMessageClient;
15 | import cn.jpush.im.android.api.event.UserLogoutEvent;
16 |
17 | /**
18 | * Created by Ken on 2015/3/13.
19 | */
20 |
21 | /**
22 | * 主要用于一些初始化的动作
23 | */
24 | public class BaseActivity extends Activity {
25 | private static final String TAG = "BaseActivity";
26 |
27 | protected BaseHandler mHandler;
28 | protected float mDensity;
29 | protected int mDensityDpi;
30 | protected int mAvatarSize;
31 | protected int mWidth;
32 | protected int mHeight;
33 | private Dialog mDialog;
34 |
35 | @Override
36 | protected void onCreate(Bundle savedInstanceState) {
37 | super.onCreate(savedInstanceState);
38 | setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_PORTRAIT);
39 | //初始化JMessage-sdk
40 | JMessageClient.init(this);
41 | //订阅接收消息 这里主要是添加或删除群成员的event
42 | JMessageClient.registerEventReceiver(this);
43 | DisplayMetrics dm = new DisplayMetrics();
44 | getWindowManager().getDefaultDisplay().getMetrics(dm);
45 | mDensity = dm.density;
46 | mDensityDpi = dm.densityDpi;
47 | mWidth = dm.widthPixels;
48 | mHeight = dm.heightPixels;
49 | mAvatarSize = (int) (50 * mDensity);
50 | }
51 |
52 | @Override
53 | protected void onDestroy() {
54 | JMessageClient.unRegisterEventReceiver(this);
55 | super.onDestroy();
56 | }
57 |
58 | public class BaseHandler extends Handler {
59 |
60 | @Override
61 | public void handleMessage(Message msg) {
62 | handleMsg(msg);
63 | }
64 | }
65 |
66 | public void handleMsg(Message message) {
67 | }
68 |
69 | public void onEventMainThread(UserLogoutEvent event) {
70 | Context context = BaseActivity.this;
71 | String title = context.getString(IdHelper.getString(context, "jmui_user_logout_dialog_title"));
72 | String msg = context.getString(IdHelper.getString(context, "jmui_user_logout_dialog_message"));
73 | mDialog = DialogCreator.createBaseCustomDialog(context, title, msg, onClickListener);
74 | mDialog.getWindow().setLayout((int) (0.8 * mWidth), WindowManager.LayoutParams.WRAP_CONTENT);
75 | mDialog.show();
76 | }
77 |
78 | private View.OnClickListener onClickListener = new View.OnClickListener() {
79 | @Override
80 | public void onClick(View v) {
81 | mDialog.dismiss();
82 | }
83 | };
84 |
85 | }
86 |
--------------------------------------------------------------------------------
/GroupChatDetail/src/cn/jmessage/android/uikit/groupchatdetail/CircleImageView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.groupchatdetail;
2 |
3 | import android.content.Context;
4 | import android.graphics.Bitmap;
5 | import android.graphics.Canvas;
6 | import android.graphics.Color;
7 | import android.graphics.Paint;
8 | import android.graphics.RectF;
9 | import android.util.AttributeSet;
10 |
11 | public class CircleImageView extends BaseImageView {
12 |
13 | public CircleImageView(Context context) {
14 | super(context);
15 | }
16 |
17 | public CircleImageView(Context context, AttributeSet attrs) {
18 | super(context, attrs);
19 | }
20 |
21 | public CircleImageView(Context context, AttributeSet attrs, int defStyle) {
22 | super(context, attrs, defStyle);
23 | }
24 |
25 | public static Bitmap getBitmap(int width, int height) {
26 | Bitmap bitmap = Bitmap.createBitmap(width, height,
27 | Bitmap.Config.ARGB_8888);
28 | Canvas canvas = new Canvas(bitmap);
29 | Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG);
30 | paint.setColor(Color.BLACK);
31 | canvas.drawOval(new RectF(0.0f, 0.0f, width, height), paint);
32 |
33 | return bitmap;
34 | }
35 |
36 | @Override
37 | public Bitmap getBitmap() {
38 | return getBitmap(getWidth(), getHeight());
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/GroupChatDetail/src/cn/jmessage/android/uikit/groupchatdetail/GroupGridView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.groupchatdetail;
2 |
3 | import android.content.Context;
4 | import android.util.AttributeSet;
5 | import android.widget.GridView;
6 |
7 | public class GroupGridView extends GridView {
8 |
9 | public GroupGridView(Context context) {
10 | super(context);
11 | // TODO Auto-generated constructor stub
12 | }
13 |
14 | public GroupGridView(Context context, AttributeSet attrs) {
15 | super(context, attrs);
16 | }
17 |
18 | public GroupGridView(Context context, AttributeSet attrs, int defStyle) {
19 | super(context, attrs, defStyle);
20 | }
21 |
22 | @Override
23 | public void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
24 | int expandSpec = MeasureSpec.makeMeasureSpec(
25 | Integer.MAX_VALUE >> 2, MeasureSpec.AT_MOST);
26 | super.onMeasure(widthMeasureSpec, expandSpec);
27 | }
28 |
29 | }
30 |
--------------------------------------------------------------------------------
/GroupChatDetail/src/cn/jmessage/android/uikit/groupchatdetail/IdHelper.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.groupchatdetail;
2 |
3 | import android.content.Context;
4 |
5 | import java.lang.reflect.Field;
6 |
7 | public class IdHelper {
8 |
9 | public static int getLayout(Context context, String layoutName) {
10 | return context.getResources().getIdentifier(layoutName, "layout",
11 | context.getApplicationContext().getPackageName());
12 | }
13 |
14 | public static int getViewID(Context context, String IDName) {
15 | return context.getResources().getIdentifier(IDName, "id",
16 | context.getApplicationContext().getPackageName());
17 | }
18 |
19 | public static int getDrawable(Context context, String drawableName) {
20 | return context.getResources().getIdentifier(drawableName, "drawable",
21 | context.getApplicationContext().getPackageName());
22 | }
23 |
24 | public static int getAttr(Context context, String attrName) {
25 | return context.getResources().getIdentifier(attrName, "attr",
26 | context.getApplicationContext().getPackageName());
27 | }
28 |
29 | public static int getString(Context context, String stringName) {
30 | return context.getResources().getIdentifier(stringName, "string",
31 | context.getApplicationContext().getPackageName());
32 | }
33 |
34 | public static int getStyle(Context context, String styleName) {
35 | return context.getResources().getIdentifier(styleName, "style",
36 | context.getApplicationContext().getPackageName());
37 | }
38 |
39 | public static int[] getResourceDeclareStyleableIntArray(Context context, String name) {
40 | try {
41 | Field[] fields2 = Class.forName(context.getPackageName() + ".R$styleable").getFields();
42 |
43 | //browse all fields
44 | for (Field f : fields2) {
45 | //pick matching field
46 | if (f.getName().equals(name)) {
47 | //return as int array
48 | return (int[]) f.get(null);
49 | }
50 | }
51 | } catch (Throwable t) {
52 | t.printStackTrace();
53 | }
54 |
55 | return null;
56 | }
57 |
58 | public static int getAnim(Context context, String animName) {
59 | return context.getResources().getIdentifier(animName, "anim",
60 | context.getApplicationContext().getPackageName());
61 | }
62 |
63 | public static int getColor(Context context, String colorName) {
64 | return context.getResources().getIdentifier(colorName, "color", context.getPackageName());
65 | }
66 | }
67 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | The MIT License (MIT)
2 |
3 | Copyright (c) 2015 极光推送/IM JPush/JMesage
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
23 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/README.md:
--------------------------------------------------------------------------------
1 | # jmessage-android-ui-components
2 | IM SDK UI 组件
3 |
4 | 浏览、多选本地图片的组件
5 |
6 | ###用法
7 |
8 | - 拷贝browser文件夹下的文件到你的项目
9 | - 拷贝相关资源文件到你的项目(你也可以自定义样式)
10 | - 在XML中将类似的引用路径
11 | ```
12 |
16 |
17 | ```
18 | 修改为你当前的路径
19 |
20 | - 进入选择图片的AlbumListActivity时通过startActivityForResult()的方式来进入,重写onActivityResult()方法,如:
21 | ```
22 | @Override
23 | protected void onActivityResult(int requestCode, int resultCode, Intent data) {
24 | super.onActivityResult(requestCode, resultCode, data);
25 | //得到从选择图片返回的Intent
26 | if (resultCode == RESULT_CODE_SELECT_PICTURE) {
27 | //得到图片路径
28 | ArrayList pathList = data.getStringArrayListExtra(PICTURE_PATH);
29 | for (String path : pathList) {
30 | Log.d("DemoActivity", "path : " + path);
31 | }
32 | }
33 | }
34 |
35 | ```
36 | 这样就能得到发送图片时所选中的图片路径
37 |
38 | ####使用的开源项目:
39 |
40 | - PhotoView [github地址](https://github.com/chrisbanes/PhotoView) 根据手势缩放图片
41 |
42 | - NativeImageLoader [blog地址](http://blog.csdn.net/xiaanming/article/details/18730223) 扫描手机中的图片
43 |
44 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 |
3 | android {
4 | compileSdkVersion 19
5 | buildToolsVersion "23.0.2"
6 |
7 | defaultConfig {
8 | applicationId "com.sample.browserimagedemo"
9 | minSdkVersion 9
10 | targetSdkVersion 23
11 | versionCode 1
12 | versionName "1.0"
13 | }
14 | buildTypes {
15 | release {
16 | minifyEnabled false
17 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
18 | }
19 | }
20 |
21 | lintOptions {
22 | abortOnError false
23 | disable 'MissingTranslation'
24 | }
25 |
26 | sourceSets {
27 | main {
28 | jniLibs.srcDirs = ['libs']
29 | }
30 |
31 | }
32 | }
33 |
34 | dependencies {
35 | compile fileTree(dir: 'libs', include: ['*.jar'])
36 | testCompile 'junit:junit:4.12'
37 | }
38 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/libs/android-support-v4.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/libs/android-support-v4.jar
--------------------------------------------------------------------------------
/MultiSelectPhotos/libs/android-support-v7-appcompat.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/libs/android-support-v7-appcompat.jar
--------------------------------------------------------------------------------
/MultiSelectPhotos/libs/nineoldandroids-2.4.0.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/libs/nineoldandroids-2.4.0.jar
--------------------------------------------------------------------------------
/MultiSelectPhotos/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /Users/huminios/Library/Android/sdk/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
8 |
9 |
10 |
11 |
12 |
18 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/DemoActivity.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit;
2 |
3 | import android.app.Activity;
4 | import android.content.Intent;
5 | import android.os.Bundle;
6 | import android.util.Log;
7 | import android.view.View;
8 | import android.widget.Button;
9 |
10 | import java.util.ArrayList;
11 | import java.util.List;
12 |
13 | import cn.jmessage.android.uikit.multiselectphotos.AlbumListActivity;
14 | import cn.jmessage.android.uikit.multiselectphotos.PickPictureActivity;
15 |
16 | public class DemoActivity extends Activity implements PickPictureActivity.OnSelectedListener {
17 |
18 | public static final int RESULT_CODE_SELECT_PICTURE = 8;
19 | public static final int REQUEST_CODE_SELECT_ALBUM = 10;
20 | private static final String PICTURE_PATH = "picturePath";
21 |
22 | @Override
23 | protected void onCreate(Bundle savedInstanceState) {
24 | super.onCreate(savedInstanceState);
25 | setContentView(R.layout.jmui_activity_main);
26 |
27 | Button startBtn = (Button) findViewById(R.id.start_btn);
28 | startBtn.setOnClickListener(new View.OnClickListener() {
29 | @Override
30 | public void onClick(View v) {
31 | Intent intent = new Intent();
32 | intent.setClass(DemoActivity.this, AlbumListActivity.class);
33 | startActivityForResult(intent, REQUEST_CODE_SELECT_ALBUM);
34 | }
35 | });
36 | }
37 |
38 | @Override
39 | protected void onActivityResult(int requestCode, int resultCode, Intent data) {
40 | super.onActivityResult(requestCode, resultCode, data);
41 | //得到从选择图片返回的Intent
42 | if (resultCode == RESULT_CODE_SELECT_PICTURE) {
43 | //得到图片路径
44 | ArrayList pathList = data.getStringArrayListExtra(PICTURE_PATH);
45 | for (String path : pathList) {
46 | Log.d("DemoActivity", "path : " + path);
47 | }
48 | }
49 | }
50 |
51 | @Override
52 | public void onSelectedPictures(List list) {
53 | Log.d("DemoActivity", list.toString());
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/AlbumListView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 | import android.content.Context;
4 | import android.util.AttributeSet;
5 | import android.widget.AdapterView;
6 | import android.widget.LinearLayout;
7 | import android.widget.ListView;
8 |
9 | import cn.jmessage.android.uikit.R;
10 |
11 | public class AlbumListView extends LinearLayout {
12 |
13 | private ListView mListView;
14 |
15 | public AlbumListView(Context context, AttributeSet attrs) {
16 | super(context, attrs);
17 | }
18 |
19 |
20 | public void initModule() {
21 | mListView = (ListView) findViewById(R.id.pick_picture_total_list_view);
22 | }
23 |
24 | public void setOnItemClickListener(AdapterView.OnItemClickListener listener) {
25 | mListView.setOnItemClickListener(listener);
26 | }
27 |
28 | public void setAdapter(AlbumListAdapter adapter) {
29 | mListView.setAdapter(adapter);
30 | }
31 |
32 | public ListView getListView() {
33 | return mListView;
34 | }
35 | }
36 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/BaseActivity.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 | import android.app.Activity;
4 | import android.os.Bundle;
5 | import android.util.DisplayMetrics;
6 |
7 | public class BaseActivity extends Activity {
8 |
9 | protected float mDensity;
10 | protected int mWidth;
11 | protected int mHeight;
12 |
13 | @Override
14 | protected void onCreate(Bundle savedInstanceState) {
15 | super.onCreate(savedInstanceState);
16 |
17 | DisplayMetrics dm = new DisplayMetrics();
18 | getWindowManager().getDefaultDisplay().getMetrics(dm);
19 | mDensity = dm.density;
20 | mWidth = dm.widthPixels;
21 | mHeight = dm.heightPixels;
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/DialogCreator.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 | import android.app.Dialog;
4 | import android.content.Context;
5 | import android.graphics.drawable.AnimationDrawable;
6 | import android.view.LayoutInflater;
7 | import android.view.View;
8 | import android.widget.ImageView;
9 | import android.widget.LinearLayout;
10 | import android.widget.RelativeLayout;
11 | import android.widget.TextView;
12 |
13 | import cn.jmessage.android.uikit.R;
14 |
15 |
16 | public class DialogCreator {
17 | public static Dialog createLoadingDialog(Context context, String msg) {
18 | LayoutInflater inflater = LayoutInflater.from(context);
19 | View v = inflater.inflate(R.layout.jmui_loading_view, null);
20 | RelativeLayout layout = (RelativeLayout) v.findViewById(R.id.dialog_view);
21 | ImageView mLoadImg = (ImageView) v.findViewById(R.id.loading_img);
22 | TextView mLoadText = (TextView) v.findViewById(R.id.loading_txt);
23 | AnimationDrawable mDrawable = (AnimationDrawable) mLoadImg.getDrawable();
24 | mDrawable.start();
25 | mLoadText.setText(msg);
26 | final Dialog loadingDialog = new Dialog(context, R.style.LoadingDialog);
27 | loadingDialog.setCancelable(true);
28 | loadingDialog.setContentView(layout, new LinearLayout.LayoutParams(
29 | LinearLayout.LayoutParams.MATCH_PARENT,
30 | LinearLayout.LayoutParams.MATCH_PARENT));
31 | return loadingDialog;
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/ImageBean.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 | /**
4 | * GridView的每个item的数据对象
5 | *
6 | * @author len
7 | *
8 | */
9 | public class ImageBean{
10 | /**
11 | * 文件夹的第一张图片路径
12 | */
13 | private String topImagePath;
14 | /**
15 | * 文件夹名
16 | */
17 | private String folderName;
18 | /**
19 | * 文件夹中的图片数
20 | */
21 | private int imageCounts;
22 |
23 | public String getTopImagePath() {
24 | return topImagePath;
25 | }
26 | public void setTopImagePath(String topImagePath) {
27 | this.topImagePath = topImagePath;
28 | }
29 | public String getFolderName() {
30 | return folderName;
31 | }
32 | public void setFolderName(String folderName) {
33 | this.folderName = folderName;
34 | }
35 | public int getImageCounts() {
36 | return imageCounts;
37 | }
38 | public void setImageCounts(int imageCounts) {
39 | this.imageCounts = imageCounts;
40 | }
41 |
42 | }
43 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/ImgBrowserViewPager.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 |
4 | import android.content.Context;
5 | import android.support.v4.view.ViewPager;
6 | import android.util.AttributeSet;
7 | import android.view.MotionEvent;
8 |
9 | public class ImgBrowserViewPager extends ViewPager {
10 |
11 |
12 | public ImgBrowserViewPager(Context context, AttributeSet attrs) {
13 | super(context, attrs);
14 | }
15 |
16 | @Override
17 | public boolean onInterceptTouchEvent(MotionEvent ev) {
18 | try {
19 | return super.onInterceptTouchEvent(ev);
20 | } catch (IllegalArgumentException e) {
21 | e.printStackTrace();
22 | return false;
23 | }
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/MyImageView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 | import android.content.Context;
4 | import android.util.AttributeSet;
5 | import android.widget.ImageView;
6 |
7 | public class MyImageView extends ImageView {
8 | private OnMeasureListener onMeasureListener;
9 |
10 | public void setOnMeasureListener(OnMeasureListener onMeasureListener) {
11 | this.onMeasureListener = onMeasureListener;
12 | }
13 |
14 | public MyImageView(Context context, AttributeSet attrs) {
15 | super(context, attrs);
16 | }
17 |
18 | public MyImageView(Context context, AttributeSet attrs, int defStyle) {
19 | super(context, attrs, defStyle);
20 | }
21 |
22 | @Override
23 | protected void onMeasure(int widthMeasureSpec, int heightMeasureSpec) {
24 | super.onMeasure(widthMeasureSpec, heightMeasureSpec);
25 |
26 | //将图片测量的大小回调到onMeasureSize()方法中
27 | if (onMeasureListener != null) {
28 | onMeasureListener.onMeasureSize(getMeasuredWidth(), getMeasuredHeight());
29 | }
30 | }
31 |
32 | public interface OnMeasureListener {
33 | public void onMeasureSize(int width, int height);
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/PickPictureView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 | import android.content.Context;
4 | import android.util.AttributeSet;
5 | import android.widget.AdapterView;
6 | import android.widget.Button;
7 | import android.widget.GridView;
8 | import android.widget.ImageButton;
9 | import android.widget.LinearLayout;
10 | import android.widget.TextView;
11 |
12 | import cn.jmessage.android.uikit.R;
13 |
14 | public class PickPictureView extends LinearLayout {
15 |
16 | private Button mSendPictureBtn;
17 | private ImageButton mReturnBtn;
18 | private GridView mGridView;
19 |
20 | public PickPictureView(Context context, AttributeSet attrs) {
21 | super(context, attrs);
22 | }
23 |
24 | public void initModule(String titleTxt) {
25 | TextView title;
26 | mSendPictureBtn = (Button) findViewById(R.id.pick_picture_send_btn);
27 | mReturnBtn = (ImageButton) findViewById(R.id.pick_picture_detail_return_btn);
28 | mGridView = (GridView) findViewById(R.id.child_grid);
29 | title = (TextView) findViewById(R.id.title);
30 | title.setText(titleTxt);
31 | }
32 |
33 | public void setListeners(OnClickListener listener) {
34 | mSendPictureBtn.setOnClickListener(listener);
35 | mReturnBtn.setOnClickListener(listener);
36 | }
37 |
38 | public void setOnItemClickListener(AdapterView.OnItemClickListener listener) {
39 | mGridView.setOnItemClickListener(listener);
40 | }
41 |
42 | public void setAdapter(PickPictureAdapter adapter) {
43 | mGridView.setAdapter(adapter);
44 | }
45 |
46 | public GridView getGridView() {
47 | return mGridView;
48 | }
49 |
50 | public void setSendBtnText(String sendText) {
51 | mSendPictureBtn.setText(sendText);
52 | }
53 | }
54 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/SortPictureList.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos;
2 |
3 | import java.io.File;
4 | import java.util.Comparator;
5 |
6 | public class SortPictureList implements Comparator {
7 | @Override
8 | public int compare(Object o, Object t1) {
9 | String path1 = o.toString();
10 | String path2 = t1.toString();
11 | File file1 = new File(path1);
12 | File file2 = new File(path2);
13 | if(file1.lastModified() < file2.lastModified()){
14 | return 1;
15 | }else return -1;
16 | }
17 | }
18 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/photoview/Compat.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.multiselectphotos.photoview;
2 |
3 | import android.os.Build.VERSION;
4 | import android.view.View;
5 |
6 | public class Compat {
7 |
8 | private static final int SIXTY_FPS_INTERVAL = 1000 / 60;
9 |
10 | public static void postOnAnimation(View view, Runnable runnable) {
11 | if (VERSION.SDK_INT >= 16) {
12 | SDK16.postOnAnimation(view, runnable);
13 | } else {
14 | view.postDelayed(runnable, SIXTY_FPS_INTERVAL);
15 | }
16 | }
17 |
18 | }
19 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/java/cn/jmessage/android/uikit/multiselectphotos/photoview/SDK16.java:
--------------------------------------------------------------------------------
1 | /*******************************************************************************
2 | * Copyright 2011, 2012 Chris Banes.
3 | *
4 | * Licensed under the Apache License, Version 2.0 (the "License");
5 | * you may not use this file except in compliance with the License.
6 | * You may obtain a copy of the License at
7 | *
8 | * http://www.apache.org/licenses/LICENSE-2.0
9 | *
10 | * Unless required by applicable law or agreed to in writing, software
11 | * distributed under the License is distributed on an "AS IS" BASIS,
12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 | * See the License for the specific language governing permissions and
14 | * limitations under the License.
15 | *******************************************************************************/
16 | package cn.jmessage.android.uikit.multiselectphotos.photoview;
17 |
18 | import android.annotation.TargetApi;
19 | import android.view.View;
20 |
21 | @TargetApi(16)
22 | public class SDK16 {
23 |
24 | public static void postOnAnimation(View view, Runnable r) {
25 | view.postOnAnimation(r);
26 | }
27 |
28 | }
29 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/drawable/jmui_back_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/drawable/jmui_default_check_box_style.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/drawable/jmui_download_image_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | -
5 |
6 |
-
7 |
8 |
9 |
10 |
11 |
12 | -
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/drawable/jmui_loading.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/drawable/jmui_pictures_selected_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/drawable/jmui_round_check_box_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/drawable/jmui_send_picture_btn_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/layout/jmui_activity_album_list.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
13 |
14 |
20 |
21 |
22 |
23 |
24 |
25 |
28 |
29 |
34 |
35 |
36 |
37 |
38 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/layout/jmui_activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
13 |
14 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/layout/jmui_activity_pick_picture_detail.xml:
--------------------------------------------------------------------------------
1 |
6 |
7 |
12 |
13 |
19 |
20 |
30 |
31 |
38 |
39 |
40 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/layout/jmui_album_list_item.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
11 |
12 |
19 |
20 |
31 |
32 |
41 |
42 |
49 |
50 |
51 |
52 |
56 |
57 |
58 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/layout/jmui_loading_view.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
13 |
14 |
22 |
23 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/layout/jmui_pick_picture_detail_grid_item.xml:
--------------------------------------------------------------------------------
1 |
2 |
7 |
8 |
14 |
15 |
21 |
22 |
28 |
29 |
30 |
31 |
32 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_1.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_10.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_11.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_12.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_13.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_14.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_2.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_3.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_4.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_5.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_6.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_7.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_8.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_8.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-hdpi/jmui_loading_9.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_arrow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_arrow.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_back_btn.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_back_btn.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_default_check_box_checked.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_default_check_box_checked.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_picture_not_found.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_picture_not_found.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_round_check_box_checked.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_round_check_box_checked.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_round_check_box_normal.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_round_check_box_normal.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_selected.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_selected.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_unselected.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xhdpi/jmui_unselected.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/MultiSelectPhotos/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/values-w820dp/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 64dp
6 |
7 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #3F51B5
4 | #303F9F
5 | #FF4081
6 | #346fc3
7 |
8 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/values/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 16dp
4 | 16dp
5 |
6 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | MultiSelectPhotos
3 | 开始
4 | 加载中
5 | 相册
6 | 我的相册
7 | sd卡尚未准备好
8 | 没找到你想要的图片
9 | 发送
10 | 正在发送
11 | 你最多只能同时发送9张图片
12 | 下载原图
13 | 原图
14 | 选择
15 | (%s)
16 |
17 |
18 |
--------------------------------------------------------------------------------
/MultiSelectPhotos/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
17 |
18 |
22 |
23 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # JMessage Android UI组件
2 |
3 | 本项目为极光IM Android SDK 提供配套的 UI组件。
4 |
5 | 这些组件大多数来自于 [JChat Android](http://github.com/jpush/jchat-android) 项目。可以参考该项目源代码来更完整系统地了解一个基于 JMessage SDK 的 App。
6 |
7 | 本项目包含如何几个部分(组件):
8 |
9 | - [聊天界面组件](Chatting/) 同时包含单聊与群聊,包含聊天气泡,文字、语音、图片等聊天内容的显示。
10 | - [录音按钮组件](RecordVoice/) 按住录音,进行时的麦克风效果,放手完成录音,上滑取消录音。
11 | - [相册多选照片组件](MultiSelectPhotos/) 默认的系统相册里选择图片不支持多选。本组件提供多选功能,并方便发送。
12 | - [群聊详情界面组件](GroupChatDetail/) 群聊详情里需要展示群成员列表,以及其他设置项。
13 |
14 | -----------------
15 |
16 | Three simple demos of component from [JChat Android](https://github.com/jpush/jchat-android). Include functions of single chat, recording voice and browsing local images.
17 |
18 | Download this project and import as a project with Android Studio, then you can custom your applications.
19 |
--------------------------------------------------------------------------------
/RecordVoice/.gitignore:
--------------------------------------------------------------------------------
1 | /build
2 |
--------------------------------------------------------------------------------
/RecordVoice/README.md:
--------------------------------------------------------------------------------
1 | # jmessage-android-ui-components
2 | IM SDK UI 组件
3 |
4 | 一个聊天工具中常用的录音组件
5 |
6 | ###用法
7 |
8 | - 复制RecordVoiceButton,IdHelper到你的项目
9 | - 在XML中加入添加引用,比如:
10 | ```
11 |
23 |
24 | ```
25 | 注意将引用路径修改为你当前的路径
26 |
27 | - 在Activity中要实现RecordVoiceButton的接口:OnRecordVoiceListener,然后初始化RecordVoiceButton,如下所示:
28 | ```
29 | RecordVoiceButton mRecordBtn = (RecordVoiceButton) findViewById(R.id.voice_btn);
30 |
31 | ```
32 |
33 | 之后setListener:
34 | ```
35 | mRecordBtn.setRecordListener(this);
36 |
37 | ```
38 |
39 | 并且设置录音文件的存放位置, 比如:
40 | ```
41 | //设置录音文件存放位置
42 | File rootDir = this.getFilesDir();
43 | String fileDir = rootDir.getAbsolutePath() + "/voice";
44 | mRecordBtn.setFilePath(fileDir);
45 |
46 | ```
47 |
48 | 最后实现onRecordFinished方法:
49 |
50 | ```
51 | /**
52 | * 录音完成时调用
53 | * @param duration 时长
54 | * @param path 录音文件路径
55 | */
56 | @Override
57 | public void onRecordFinished(int duration, String path) {
58 | VoiceMessage voiceMessage = new VoiceMessage(duration, path);
59 | mAdapter.addToMsgList(voiceMessage);
60 | }
61 |
62 | ```
63 |
--------------------------------------------------------------------------------
/RecordVoice/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.application'
2 |
3 | android {
4 | compileSdkVersion 23
5 | buildToolsVersion "23.0.2"
6 |
7 | defaultConfig {
8 | applicationId "sample.myapplication.com.recordvoicedemo"
9 | minSdkVersion 9
10 | targetSdkVersion 23
11 | versionCode 1
12 | versionName "1.0"
13 | }
14 | buildTypes {
15 | release {
16 | minifyEnabled false
17 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
18 | }
19 | }
20 | }
21 |
22 | dependencies {
23 | compile fileTree(dir: 'libs', include: ['*.jar'])
24 | testCompile 'junit:junit:4.12'
25 | compile 'com.android.support:appcompat-v7:23.1.1'
26 | }
27 |
--------------------------------------------------------------------------------
/RecordVoice/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /Users/huminios/Library/Android/sdk/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
8 |
9 |
10 |
11 |
12 |
13 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/java/cn/jmessage/android/uikit/CircleImageView.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit;
2 |
3 | import android.content.Context;
4 | import android.graphics.Bitmap;
5 | import android.graphics.Canvas;
6 | import android.graphics.Color;
7 | import android.graphics.Paint;
8 | import android.graphics.RectF;
9 | import android.util.AttributeSet;
10 |
11 | public class CircleImageView extends BaseImageView {
12 |
13 | public CircleImageView(Context context) {
14 | super(context);
15 | }
16 |
17 | public CircleImageView(Context context, AttributeSet attrs) {
18 | super(context, attrs);
19 | }
20 |
21 | public CircleImageView(Context context, AttributeSet attrs, int defStyle) {
22 | super(context, attrs, defStyle);
23 | }
24 |
25 | public static Bitmap getBitmap(int width, int height) {
26 | Bitmap bitmap = Bitmap.createBitmap(width, height,
27 | Bitmap.Config.ARGB_8888);
28 | Canvas canvas = new Canvas(bitmap);
29 | Paint paint = new Paint(Paint.ANTI_ALIAS_FLAG);
30 | paint.setColor(Color.BLACK);
31 | canvas.drawOval(new RectF(0.0f, 0.0f, width, height), paint);
32 |
33 | return bitmap;
34 | }
35 |
36 | @Override
37 | public Bitmap getBitmap() {
38 | return getBitmap(getWidth(), getHeight());
39 | }
40 | }
41 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/java/cn/jmessage/android/uikit/DemoActivity.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit;
2 |
3 | import android.app.Activity;
4 | import android.content.BroadcastReceiver;
5 | import android.content.Context;
6 | import android.content.Intent;
7 | import android.content.IntentFilter;
8 | import android.os.Bundle;
9 | import android.widget.ListView;
10 |
11 | import java.io.File;
12 |
13 | import cn.jmessage.android.uikit.recordvoice.RecordVoiceButton;
14 |
15 | public class DemoActivity extends Activity implements RecordVoiceButton.OnRecordVoiceListener {
16 |
17 | private ListView mListView;
18 | private RecordVoiceButton mRecordBtn;
19 | private MyReceiver mReceiver;
20 | private ListAdapter mAdapter;
21 |
22 | @Override
23 | protected void onCreate(Bundle savedInstanceState) {
24 | super.onCreate(savedInstanceState);
25 | setContentView(R.layout.jmui_activity_main);
26 |
27 | mListView = (ListView) findViewById(R.id.list_view);
28 | mRecordBtn = (RecordVoiceButton) findViewById(R.id.voice_btn);
29 |
30 | mAdapter = new ListAdapter(this);
31 | mListView.setAdapter(mAdapter);
32 | mRecordBtn.setRecordListener(this);
33 | //设置录音文件存放位置
34 | File rootDir = this.getFilesDir();
35 | String fileDir = rootDir.getAbsolutePath() + "/voice";
36 | mRecordBtn.setFilePath(fileDir);
37 | mAdapter.initMediaPlayer();
38 | initReceiver();
39 | }
40 |
41 | // 监听耳机插入
42 | private void initReceiver() {
43 | mReceiver = new MyReceiver();
44 | IntentFilter filter = new IntentFilter();
45 | filter.addAction(Intent.ACTION_HEADSET_PLUG);
46 | registerReceiver(mReceiver, filter);
47 | }
48 |
49 | /**
50 | * 录音完成时调用
51 | * @param duration 时长
52 | * @param path 录音文件路径
53 | */
54 | @Override
55 | public void onRecordFinished(int duration, String path) {
56 | VoiceMessage voiceMessage = new VoiceMessage(duration, path);
57 | mAdapter.addToMsgList(voiceMessage);
58 | }
59 |
60 | private class MyReceiver extends BroadcastReceiver {
61 |
62 | @Override
63 | public void onReceive(Context context, Intent data) {
64 | if (data != null) {
65 | //插入了耳机
66 | if (data.getAction().equals(Intent.ACTION_HEADSET_PLUG)) {
67 | mAdapter.setAudioPlayByEarPhone(data.getIntExtra("state", 0));
68 | }
69 | }
70 | }
71 |
72 | }
73 |
74 | @Override
75 | protected void onPause() {
76 | RecordVoiceButton.mIsPressed = false;
77 | super.onPause();
78 | }
79 |
80 | @Override
81 | protected void onStop() {
82 | mAdapter.stopMediaPlayer();
83 | super.onStop();
84 | }
85 |
86 | @Override
87 | protected void onDestroy() {
88 | unregisterReceiver(mReceiver);
89 | mAdapter.releaseMediaPlayer();
90 | mRecordBtn.releaseRecorder();
91 | super.onDestroy();
92 | }
93 | }
94 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/java/cn/jmessage/android/uikit/VoiceMessage.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit;
2 |
3 | public class VoiceMessage {
4 |
5 | private int mDuration;
6 | private String mPath;
7 |
8 | public VoiceMessage(int duration, String path) {
9 | this.mDuration = duration;
10 | this.mPath = path;
11 | }
12 |
13 | public int getDuration() {
14 | return mDuration;
15 | }
16 |
17 | public String getPath() {
18 | return mPath;
19 | }
20 |
21 | }
22 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/java/cn/jmessage/android/uikit/recordvoice/IdHelper.java:
--------------------------------------------------------------------------------
1 | package cn.jmessage.android.uikit.recordvoice;
2 |
3 | import android.content.Context;
4 |
5 | import java.lang.reflect.Field;
6 |
7 | public class IdHelper {
8 |
9 | public static int getLayout(Context context, String layoutName) {
10 | return context.getResources().getIdentifier(layoutName, "layout",
11 | context.getApplicationContext().getPackageName());
12 | }
13 |
14 | public static int getViewID(Context context, String IDName) {
15 | return context.getResources().getIdentifier(IDName, "id",
16 | context.getApplicationContext().getPackageName());
17 | }
18 |
19 | public static int getDrawable(Context context, String drawableName) {
20 | return context.getResources().getIdentifier(drawableName, "drawable",
21 | context.getApplicationContext().getPackageName());
22 | }
23 |
24 | public static int getAttr(Context context, String attrName) {
25 | return context.getResources().getIdentifier(attrName, "attr",
26 | context.getApplicationContext().getPackageName());
27 | }
28 |
29 | public static int getString(Context context, String stringName) {
30 | return context.getResources().getIdentifier(stringName, "string",
31 | context.getApplicationContext().getPackageName());
32 | }
33 |
34 | public static int getStyle(Context context, String styleName) {
35 | return context.getResources().getIdentifier(styleName, "style",
36 | context.getApplicationContext().getPackageName());
37 | }
38 |
39 | public static int[] getResourceDeclareStyleableIntArray(Context context, String name) {
40 | try {
41 | Field[] fields2 = Class.forName(context.getPackageName() + ".R$styleable").getFields();
42 |
43 | //browse all fields
44 | for (Field f : fields2) {
45 | //pick matching field
46 | if (f.getName().equals(name)) {
47 | //return as int array
48 | return (int[]) f.get(null);
49 | }
50 | }
51 | } catch (Throwable t) {
52 | t.printStackTrace();
53 | }
54 |
55 | return null;
56 | }
57 |
58 | public static int getAnim(Context context, String animName) {
59 | return context.getResources().getIdentifier(animName, "anim",
60 | context.getApplicationContext().getPackageName());
61 | }
62 | }
63 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_cancel_record.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_cancel_record.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_head_icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_head_icon.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_1.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_2.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_3.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_4.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_mic_5.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_1.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_2.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_3.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_msg.9.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xhdpi/jmui_send_msg.9.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/RecordVoice/src/main/res/drawable-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable/jmui_msg_send_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable/jmui_round_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable/jmui_voice_bg.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | -
4 |
5 |
6 |
7 |
8 |
9 | -
10 |
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/drawable/jmui_voice_send.xml:
--------------------------------------------------------------------------------
1 |
2 |
4 |
5 |
8 |
11 |
12 |
15 |
16 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/layout/jmui_activity_main.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 |
6 |
7 |
13 |
14 |
20 |
21 |
22 |
23 |
24 |
34 |
35 |
44 |
45 |
57 |
58 |
59 |
60 |
61 |
62 |
63 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/layout/jmui_chat_item_send_voice.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
11 |
12 |
15 |
16 |
23 |
24 |
31 |
32 |
39 |
40 |
41 |
52 |
53 |
54 |
55 |
56 |
57 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/layout/jmui_dialog_record_voice.xml:
--------------------------------------------------------------------------------
1 |
2 |
8 |
9 |
12 |
13 |
19 |
20 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/values-w820dp/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
5 | 64dp
6 |
7 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/values/colors.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | #3F51B5
4 | #303F9F
5 | #FF4081
6 |
7 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/values/dimens.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | 16dp
4 | 16dp
5 |
6 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | RecordVoice
3 | 创建文件失败
4 | 按住 说话
5 | 松开手指,取消发送
6 | 松开 结束
7 | 手指上滑,取消发送
8 | 还可以说%s秒
9 | 时间太短!
10 | 文件获取失败
11 | 10"
12 | \"
13 | 请在应用的权限管理中将使用录音选项设置为允许,
14 | 否则将无法使用录音功能
15 | 若要使用语音功能,请选择允许录音
16 | 暂无外部存储,某些本地图片不可预览
17 | 暂无外部存储
18 | 获取语音失败,请重试
19 | 文件丢失
20 |
21 |
--------------------------------------------------------------------------------
/RecordVoice/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
6 |
7 |
8 |
16 |
17 |
25 |
26 |
30 |
31 |
36 |
37 |
38 |
39 |
--------------------------------------------------------------------------------
/build.gradle:
--------------------------------------------------------------------------------
1 | // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 |
3 | buildscript {
4 | repositories {
5 | jcenter()
6 | }
7 | dependencies {
8 | classpath 'com.android.tools.build:gradle:1.5.0'
9 |
10 | // NOTE: Do not place your application dependencies here; they belong
11 | // in the individual module build.gradle files
12 | }
13 | }
14 |
15 | allprojects {
16 | repositories {
17 | jcenter()
18 | }
19 | }
20 |
21 | task clean(type: Delete) {
22 | delete rootProject.buildDir
23 | }
24 |
--------------------------------------------------------------------------------
/gradle.properties:
--------------------------------------------------------------------------------
1 | ## Project-wide Gradle settings.
2 | #
3 | # For more details on how to configure your build environment visit
4 | # http://www.gradle.org/docs/current/userguide/build_environment.html
5 | #
6 | # Specifies the JVM arguments used for the daemon process.
7 | # The setting is particularly useful for tweaking memory settings.
8 | # Default value: -Xmx10248m -XX:MaxPermSize=256m
9 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
10 | #
11 | # When configured, Gradle will run in incubating parallel mode.
12 | # This option should only be used with decoupled projects. More details, visit
13 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
14 | # org.gradle.parallel=true
15 | #Mon Dec 07 13:05:17 CST 2015
16 | systemProp.http.proxyHost=192.168.6.252
17 | systemProp.http.proxyPort=18011
18 |
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/jpush/jmessage-android-uikit/0c9edbf357a9de46d48a84ea96c197419ae75735/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Wed Oct 21 11:34:03 PDT 2015
2 | distributionBase=GRADLE_USER_HOME
3 | distributionPath=wrapper/dists
4 | zipStoreBase=GRADLE_USER_HOME
5 | zipStorePath=wrapper/dists
6 | distributionUrl=https\://services.gradle.org/distributions/gradle-2.8-all.zip
7 |
--------------------------------------------------------------------------------
/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
12 | set DEFAULT_JVM_OPTS=
13 |
14 | set DIRNAME=%~dp0
15 | if "%DIRNAME%" == "" set DIRNAME=.
16 | set APP_BASE_NAME=%~n0
17 | set APP_HOME=%DIRNAME%
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windowz variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 | if "%@eval[2+2]" == "4" goto 4NT_args
53 |
54 | :win9xME_args
55 | @rem Slurp the command line arguments.
56 | set CMD_LINE_ARGS=
57 | set _SKIP=2
58 |
59 | :win9xME_args_slurp
60 | if "x%~1" == "x" goto execute
61 |
62 | set CMD_LINE_ARGS=%*
63 | goto execute
64 |
65 | :4NT_args
66 | @rem Get arguments from the 4NT Shell from JP Software
67 | set CMD_LINE_ARGS=%$
68 |
69 | :execute
70 | @rem Setup the command line
71 |
72 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
73 |
74 | @rem Execute Gradle
75 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
76 |
77 | :end
78 | @rem End local scope for the variables with windows NT shell
79 | if "%ERRORLEVEL%"=="0" goto mainEnd
80 |
81 | :fail
82 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
83 | rem the _cmd.exe /c_ return code!
84 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
85 | exit /b 1
86 |
87 | :mainEnd
88 | if "%OS%"=="Windows_NT" endlocal
89 |
90 | :omega
91 |
--------------------------------------------------------------------------------
/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':Chatting', ':RecordVoice', ':MultiSelectPhotos', ':GroupChatDetail'
--------------------------------------------------------------------------------