├── .gitignore
├── README.md
├── im_flutter_sdk
├── .gitignore
├── .metadata
├── CHANGELOG.md
├── LICENSE
├── README.md
├── analysis_options.yaml
├── example
│ ├── .gitignore
│ ├── .metadata
│ ├── README.md
│ ├── analysis_options.yaml
│ ├── android
│ │ ├── .gitignore
│ │ ├── app
│ │ │ ├── build.gradle.kts
│ │ │ └── src
│ │ │ │ ├── debug
│ │ │ │ └── AndroidManifest.xml
│ │ │ │ ├── main
│ │ │ │ ├── AndroidManifest.xml
│ │ │ │ ├── kotlin
│ │ │ │ │ └── com
│ │ │ │ │ │ └── example
│ │ │ │ │ │ └── example
│ │ │ │ │ │ └── MainActivity.kt
│ │ │ │ └── res
│ │ │ │ │ ├── drawable-v21
│ │ │ │ │ └── launch_background.xml
│ │ │ │ │ ├── drawable
│ │ │ │ │ └── launch_background.xml
│ │ │ │ │ ├── mipmap-hdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ │ ├── mipmap-mdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ │ ├── mipmap-xhdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ │ ├── mipmap-xxhdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ │ ├── mipmap-xxxhdpi
│ │ │ │ │ └── ic_launcher.png
│ │ │ │ │ ├── values-night
│ │ │ │ │ └── styles.xml
│ │ │ │ │ └── values
│ │ │ │ │ └── styles.xml
│ │ │ │ └── profile
│ │ │ │ └── AndroidManifest.xml
│ │ ├── build.gradle.kts
│ │ ├── gradle.properties
│ │ ├── gradle
│ │ │ └── wrapper
│ │ │ │ └── gradle-wrapper.properties
│ │ └── settings.gradle.kts
│ ├── ios
│ │ ├── .gitignore
│ │ ├── Flutter
│ │ │ ├── AppFrameworkInfo.plist
│ │ │ ├── Debug.xcconfig
│ │ │ └── Release.xcconfig
│ │ ├── Podfile
│ │ ├── Podfile.lock
│ │ ├── Runner.xcodeproj
│ │ │ ├── project.pbxproj
│ │ │ ├── project.xcworkspace
│ │ │ │ ├── contents.xcworkspacedata
│ │ │ │ └── xcshareddata
│ │ │ │ │ ├── IDEWorkspaceChecks.plist
│ │ │ │ │ └── WorkspaceSettings.xcsettings
│ │ │ └── xcshareddata
│ │ │ │ └── xcschemes
│ │ │ │ └── Runner.xcscheme
│ │ ├── Runner.xcworkspace
│ │ │ ├── contents.xcworkspacedata
│ │ │ └── xcshareddata
│ │ │ │ ├── IDEWorkspaceChecks.plist
│ │ │ │ └── WorkspaceSettings.xcsettings
│ │ ├── Runner
│ │ │ ├── AppDelegate.swift
│ │ │ ├── Assets.xcassets
│ │ │ │ ├── AppIcon.appiconset
│ │ │ │ │ ├── Contents.json
│ │ │ │ │ ├── Icon-App-1024x1024@1x.png
│ │ │ │ │ ├── Icon-App-20x20@1x.png
│ │ │ │ │ ├── Icon-App-20x20@2x.png
│ │ │ │ │ ├── Icon-App-20x20@3x.png
│ │ │ │ │ ├── Icon-App-29x29@1x.png
│ │ │ │ │ ├── Icon-App-29x29@2x.png
│ │ │ │ │ ├── Icon-App-29x29@3x.png
│ │ │ │ │ ├── Icon-App-40x40@1x.png
│ │ │ │ │ ├── Icon-App-40x40@2x.png
│ │ │ │ │ ├── Icon-App-40x40@3x.png
│ │ │ │ │ ├── Icon-App-60x60@2x.png
│ │ │ │ │ ├── Icon-App-60x60@3x.png
│ │ │ │ │ ├── Icon-App-76x76@1x.png
│ │ │ │ │ ├── Icon-App-76x76@2x.png
│ │ │ │ │ └── Icon-App-83.5x83.5@2x.png
│ │ │ │ └── LaunchImage.imageset
│ │ │ │ │ ├── Contents.json
│ │ │ │ │ ├── LaunchImage.png
│ │ │ │ │ ├── LaunchImage@2x.png
│ │ │ │ │ ├── LaunchImage@3x.png
│ │ │ │ │ └── README.md
│ │ │ ├── Base.lproj
│ │ │ │ ├── LaunchScreen.storyboard
│ │ │ │ └── Main.storyboard
│ │ │ ├── Info.plist
│ │ │ └── Runner-Bridging-Header.h
│ │ └── RunnerTests
│ │ │ └── RunnerTests.swift
│ ├── lib
│ │ └── main.dart
│ ├── pubspec.lock
│ └── pubspec.yaml
├── lib
│ ├── im_flutter_sdk.dart
│ └── src
│ │ ├── chat_manager.dart
│ │ ├── chat_room_manager.dart
│ │ ├── chat_thread_manager.dart
│ │ ├── client.dart
│ │ ├── contact_manager.dart
│ │ ├── group_manager.dart
│ │ ├── presence_manager.dart
│ │ ├── push_manager.dart
│ │ └── user_info_manager.dart
└── pubspec.yaml
├── im_flutter_sdk_android
├── .gitignore
├── .metadata
├── CHANGELOG.md
├── LICENSE
├── README.md
├── analysis_options.yaml
├── android
│ ├── .gitignore
│ ├── build.gradle
│ ├── gradle.properties
│ ├── gradle
│ │ └── wrapper
│ │ │ ├── gradle-wrapper.jar
│ │ │ └── gradle-wrapper.properties
│ ├── gradlew
│ ├── gradlew.bat
│ ├── settings.gradle
│ └── src
│ │ └── main
│ │ ├── AndroidManifest.xml
│ │ └── java
│ │ └── com
│ │ └── easemob
│ │ └── im_flutter_sdk
│ │ ├── ChatManagerWrapper.java
│ │ ├── ChatRoomManagerWrapper.java
│ │ ├── ChatThreadManagerWrapper.java
│ │ ├── ClientWrapper.java
│ │ ├── CommonUtil.java
│ │ ├── ContactManagerWrapper.java
│ │ ├── ConversationWrapper.java
│ │ ├── EMHelper.java
│ │ ├── EnumTools.java
│ │ ├── GroupManagerWrapper.java
│ │ ├── HelpTool.java
│ │ ├── ImFlutterSdkPlugin.java
│ │ ├── ListenerHandle.java
│ │ ├── MessageWrapper.java
│ │ ├── MethodKey.java
│ │ ├── PresenceManagerWrapper.java
│ │ ├── ProgressManager.java
│ │ ├── PushManagerWrapper.java
│ │ ├── UserInfoManagerWrapper.java
│ │ └── Wrapper.java
├── lib
│ ├── im_flutter_sdk_android.dart
│ └── src
│ │ ├── chat_manager_android.dart
│ │ ├── chat_room_manager_android.dart
│ │ ├── chat_thread_manager_android.dart
│ │ ├── client_android.dart
│ │ ├── contact_manager_android.dart
│ │ ├── group_manager_android.dart
│ │ ├── presence_manager_android.dart
│ │ ├── push_manager_android.dart
│ │ └── user_info_manager_android.dart
└── pubspec.yaml
├── im_flutter_sdk_interface
├── .gitignore
├── .metadata
├── CHANGELOG.md
├── LICENSE
├── README.md
├── analysis_options.yaml
├── lib
│ ├── im_flutter_sdk_interface.dart
│ ├── interface
│ │ ├── manager_mixin.dart
│ │ ├── method_channel
│ │ │ └── default_channels.dart
│ │ └── platform_interface
│ │ │ ├── chat_manager.dart
│ │ │ ├── chat_room_manager.dart
│ │ │ ├── chat_thread_manager.dart
│ │ │ ├── client.dart
│ │ │ ├── contact_manager.dart
│ │ │ ├── group_manager.dart
│ │ │ ├── presence_manager.dart
│ │ │ ├── progress_manager.dart
│ │ │ ├── push_manager.dart
│ │ │ └── user_info_manager.dart
│ └── src
│ │ ├── event_handler
│ │ └── manager_event_handler.dart
│ │ ├── internal
│ │ ├── chat_method_keys.dart
│ │ ├── em_channel_manager.dart
│ │ ├── em_event_keys.dart
│ │ ├── em_push_config.dart
│ │ ├── em_transform_tools.dart
│ │ └── inner_headers.dart
│ │ ├── models
│ │ ├── chat_silent_mode.dart
│ │ ├── conversation_fetch_options.dart
│ │ ├── em_chat_enums.dart
│ │ ├── em_chat_room.dart
│ │ ├── em_chat_thread.dart
│ │ ├── em_contact.dart
│ │ ├── em_conversation.dart
│ │ ├── em_cursor_result.dart
│ │ ├── em_device_info.dart
│ │ ├── em_download_callback.dart
│ │ ├── em_error.dart
│ │ ├── em_group.dart
│ │ ├── em_group_message_ack.dart
│ │ ├── em_group_options.dart
│ │ ├── em_group_shared_file.dart
│ │ ├── em_message.dart
│ │ ├── em_message_reaction.dart
│ │ ├── em_options.dart
│ │ ├── em_page_result.dart
│ │ ├── em_presence.dart
│ │ ├── em_push_configs.dart
│ │ ├── em_translate_language.dart
│ │ ├── em_user_info.dart
│ │ ├── fetch_message_options.dart
│ │ ├── login_extension_info.dart
│ │ ├── message_pin_info.dart
│ │ ├── message_search_options.dart
│ │ ├── reaction_operation.dart
│ │ └── recall_message_info.dart
│ │ └── tools
│ │ ├── chat_area_code.dart
│ │ ├── em_extension.dart
│ │ ├── em_log.dart
│ │ └── em_tools.dart
└── pubspec.yaml
└── im_flutter_sdk_ios
├── .gitignore
├── .metadata
├── CHANGELOG.md
├── LICENSE
├── README.md
├── analysis_options.yaml
├── ios
├── .gitignore
├── Assets
│ └── .gitkeep
├── Classes
│ ├── ChatHeaders.h
│ ├── ChatManagerWrapper.h
│ ├── ChatManagerWrapper.m
│ ├── ChatroomHelper.h
│ ├── ChatroomHelper.m
│ ├── ChatroomManagerWrapper.h
│ ├── ChatroomManagerWrapper.m
│ ├── ClientWrapper.h
│ ├── ClientWrapper.m
│ ├── ContactHelper.h
│ ├── ContactHelper.m
│ ├── ContactManagerWrapper.h
│ ├── ContactManagerWrapper.m
│ ├── ConversationFilterHelper.h
│ ├── ConversationFilterHelper.m
│ ├── ConversationHelper.h
│ ├── ConversationHelper.m
│ ├── ConversationWrapper.h
│ ├── ConversationWrapper.m
│ ├── CursorResultHelper.h
│ ├── CursorResultHelper.m
│ ├── DeviceConfigHelper.h
│ ├── DeviceConfigHelper.m
│ ├── EnumTools.h
│ ├── EnumTools.m
│ ├── ErrorHelper.h
│ ├── ErrorHelper.m
│ ├── FetchServerMessagesOptionHelper.h
│ ├── FetchServerMessagesOptionHelper.m
│ ├── GroupHelper.h
│ ├── GroupHelper.m
│ ├── GroupManagerWrapper.h
│ ├── GroupManagerWrapper.m
│ ├── GroupMessageAckHelper.h
│ ├── GroupMessageAckHelper.m
│ ├── Header.h
│ ├── Helper.h
│ ├── Helper.m
│ ├── ImFlutterSdkPlugin.h
│ ├── ImFlutterSdkPlugin.m
│ ├── ListenerHandle.h
│ ├── ListenerHandle.m
│ ├── LoginExtensionInfoHelper.h
│ ├── LoginExtensionInfoHelper.m
│ ├── MessageHelper.h
│ ├── MessageHelper.m
│ ├── MessagePinInfoHelper.h
│ ├── MessagePinInfoHelper.m
│ ├── MessageReactionChangeHelper.h
│ ├── MessageReactionChangeHelper.m
│ ├── MessageReactionHelper.h
│ ├── MessageReactionHelper.m
│ ├── MessageReactionOperationHelper.h
│ ├── MessageReactionOperationHelper.m
│ ├── MessageWrapper.h
│ ├── MessageWrapper.m
│ ├── MethodKeys.h
│ ├── ModeToJson.h
│ ├── NSArray+Helper.h
│ ├── NSArray+Helper.m
│ ├── OptionsHelper.h
│ ├── OptionsHelper.m
│ ├── PageResultHelper.h
│ ├── PageResultHelper.m
│ ├── PresenceHelper.h
│ ├── PresenceHelper.m
│ ├── PresenceManagerWrapper.h
│ ├── PresenceManagerWrapper.m
│ ├── ProgressManager.h
│ ├── ProgressManager.m
│ ├── PushManagerWrapper.h
│ ├── PushManagerWrapper.m
│ ├── PushOptionsHelper.h
│ ├── PushOptionsHelper.m
│ ├── RecallInfoHelper.h
│ ├── RecallInfoHelper.m
│ ├── SilentModeParamHelper.h
│ ├── SilentModeParamHelper.m
│ ├── SilentModeResultHelper.h
│ ├── SilentModeResultHelper.m
│ ├── SilentModeTimeHelper.h
│ ├── SilentModeTimeHelper.m
│ ├── ThreadEventHelper.h
│ ├── ThreadEventHelper.m
│ ├── ThreadHelper.h
│ ├── ThreadHelper.m
│ ├── ThreadManagerWrapper.h
│ ├── ThreadManagerWrapper.m
│ ├── TranslateLanguageHelper.h
│ ├── TranslateLanguageHelper.m
│ ├── UserInfoHelper.h
│ ├── UserInfoHelper.m
│ ├── UserInfoManagerWrapper.h
│ ├── UserInfoManagerWrapper.m
│ ├── Wrapper.h
│ └── Wrapper.m
└── im_flutter_sdk_ios.podspec
├── lib
├── im_flutter_sdk_ios.dart
└── src
│ ├── chat_manager_ios.dart
│ ├── chat_room_manager_ios.dart
│ ├── chat_thread_manager_ios.dart
│ ├── client_ios.dart
│ ├── contact_manager_ios.dart
│ ├── group_manager_ios.dart
│ ├── presence_manager_ios.dart
│ ├── push_manager_ios.dart
│ └── user_info_manager_ios.dart
└── pubspec.yaml
/.gitignore:
--------------------------------------------------------------------------------
1 | # Miscellaneous
2 | *.class
3 | *.log
4 | *.pyc
5 | *.swp
6 | .DS_Store
7 | .atom/
8 | .buildlog/
9 | .history
10 | .svn/
11 | migrate_working_dir/
12 |
13 | # IntelliJ related
14 | *.iml
15 | *.ipr
16 | *.iws
17 | .idea/
18 |
19 | # The .vscode folder contains launch configuration and tasks you configure in
20 | # VS Code which you may wish to be included in version control, so this line
21 | # is commented out by default.
22 | .vscode
23 |
24 | # Flutter/Dart/Pub related
25 | **/doc/api/
26 | **/ios/Flutter/.last_build_id
27 | .dart_tool/
28 | .flutter-plugins
29 | .flutter-plugins-dependencies
30 | .packages
31 | .pub-cache/
32 | .pub/
33 | /build/
34 |
35 | # Symbolication related
36 | app.*.symbols
37 |
38 | # Obfuscation related
39 | app.*.map.json
40 |
41 | # Android Studio will place build artifacts here
42 | /android/app/debug
43 | /android/app/profile
44 | /android/app/release
45 |
46 | # FVM Version Cache
47 | .fvm/
48 | .fvmrc
49 | /scripts/shengwang_chat_sdk
50 | /scripts/agora_chat_sdk
51 | /scripts/im_flutter_sdk
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # 环信 im flutter sdk 项目介绍
2 |
3 | 1. 使用联合插件的方式开发,支持安卓,iOS,鸿蒙 三个平台;
4 | 2. sdk readme 在 [README](/im_flutter_sdk/README.md);
5 |
6 |
7 |
8 | ## 如何添加鸿蒙支持
9 |
10 |
11 | 1. 使用鸿蒙版 flutter `https://gitee.com/harmonycommando_flutter/flutter`
12 |
13 | 2. 在项目 pubspec.yaml 中添加:
14 | ```dart
15 | im_flutter_sdk: ^4.13.0
16 | im_flutter_sdk_ohos:
17 | git:
18 | url: "https://github.com/easemob/im_flutter_sdk_oh.git"
19 | ref: 1.5.3
20 | ```
21 | 其中具体的 `ref` 可以去 `https://github.com/easemob/im_flutter_sdk_oh/releases` 查看最新版本号;
22 |
23 | 1. 执行 `flutter pub get`;
--------------------------------------------------------------------------------
/im_flutter_sdk/.gitignore:
--------------------------------------------------------------------------------
1 | # Miscellaneous
2 | *.class
3 | *.log
4 | *.pyc
5 | *.swp
6 | .DS_Store
7 | .atom/
8 | .buildlog/
9 | .history
10 | .svn/
11 | migrate_working_dir/
12 |
13 | # IntelliJ related
14 | *.iml
15 | *.ipr
16 | *.iws
17 | .idea/
18 |
19 | # The .vscode folder contains launch configuration and tasks you configure in
20 | # VS Code which you may wish to be included in version control, so this line
21 | # is commented out by default.
22 | #.vscode/
23 |
24 | # Flutter/Dart/Pub related
25 | # Libraries should not include pubspec.lock, per https://dart.dev/guides/libraries/private-files#pubspeclock.
26 | /pubspec.lock
27 | **/doc/api/
28 | .dart_tool/
29 | build/
30 |
--------------------------------------------------------------------------------
/im_flutter_sdk/.metadata:
--------------------------------------------------------------------------------
1 | # This file tracks properties of this Flutter project.
2 | # Used by Flutter tool to assess capabilities and perform upgrades etc.
3 | #
4 | # This file should be version controlled and should not be manually edited.
5 |
6 | version:
7 | revision: "dec2ee5c1f98f8e84a7d5380c05eb8a3d0a81668"
8 | channel: "stable"
9 |
10 | project_type: plugin
11 |
12 | # Tracks metadata for the flutter migrate command
13 | migration:
14 | platforms:
15 | - platform: root
16 | create_revision: dec2ee5c1f98f8e84a7d5380c05eb8a3d0a81668
17 | base_revision: dec2ee5c1f98f8e84a7d5380c05eb8a3d0a81668
18 | - platform: android
19 | create_revision: dec2ee5c1f98f8e84a7d5380c05eb8a3d0a81668
20 | base_revision: dec2ee5c1f98f8e84a7d5380c05eb8a3d0a81668
21 | - platform: ios
22 | create_revision: dec2ee5c1f98f8e84a7d5380c05eb8a3d0a81668
23 | base_revision: dec2ee5c1f98f8e84a7d5380c05eb8a3d0a81668
24 |
25 | # User provided section
26 |
27 | # List of Local paths (relative to this file) that should be
28 | # ignored by the migrate tool.
29 | #
30 | # Files that are not part of the templates will be ignored by default.
31 | unmanaged_files:
32 | - 'lib/main.dart'
33 | - 'ios/Runner.xcodeproj/project.pbxproj'
34 |
--------------------------------------------------------------------------------
/im_flutter_sdk/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is
8 | furnished to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in all
11 | copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19 | SOFTWARE.
--------------------------------------------------------------------------------
/im_flutter_sdk/analysis_options.yaml:
--------------------------------------------------------------------------------
1 | include: package:flutter_lints/flutter.yaml
2 |
3 | # Additional information about this file can be found at
4 | # https://dart.dev/guides/language/analysis-options
5 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/.gitignore:
--------------------------------------------------------------------------------
1 | # Miscellaneous
2 | *.class
3 | *.log
4 | *.pyc
5 | *.swp
6 | .DS_Store
7 | .atom/
8 | .build/
9 | .buildlog/
10 | .history
11 | .svn/
12 | .swiftpm/
13 | migrate_working_dir/
14 |
15 | # IntelliJ related
16 | *.iml
17 | *.ipr
18 | *.iws
19 | .idea/
20 |
21 | # The .vscode folder contains launch configuration and tasks you configure in
22 | # VS Code which you may wish to be included in version control, so this line
23 | # is commented out by default.
24 | #.vscode/
25 |
26 | # Flutter/Dart/Pub related
27 | **/doc/api/
28 | **/ios/Flutter/.last_build_id
29 | .dart_tool/
30 | .flutter-plugins
31 | .flutter-plugins-dependencies
32 | .pub-cache/
33 | .pub/
34 | /build/
35 |
36 | # Symbolication related
37 | app.*.symbols
38 |
39 | # Obfuscation related
40 | app.*.map.json
41 |
42 | # Android Studio will place build artifacts here
43 | /android/app/debug
44 | /android/app/profile
45 | /android/app/release
46 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/.metadata:
--------------------------------------------------------------------------------
1 | # This file tracks properties of this Flutter project.
2 | # Used by Flutter tool to assess capabilities and perform upgrades etc.
3 | #
4 | # This file should be version controlled and should not be manually edited.
5 |
6 | version:
7 | revision: "35c388afb57ef061d06a39b537336c87e0e3d1b1"
8 | channel: "stable"
9 |
10 | project_type: app
11 |
12 | # Tracks metadata for the flutter migrate command
13 | migration:
14 | platforms:
15 | - platform: root
16 | create_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
17 | base_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
18 | - platform: android
19 | create_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
20 | base_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
21 | - platform: ios
22 | create_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
23 | base_revision: 35c388afb57ef061d06a39b537336c87e0e3d1b1
24 |
25 | # User provided section
26 |
27 | # List of Local paths (relative to this file) that should be
28 | # ignored by the migrate tool.
29 | #
30 | # Files that are not part of the templates will be ignored by default.
31 | unmanaged_files:
32 | - 'lib/main.dart'
33 | - 'ios/Runner.xcodeproj/project.pbxproj'
34 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/README.md:
--------------------------------------------------------------------------------
1 | # example
2 |
3 | A new Flutter project.
4 |
5 | ## Getting Started
6 |
7 | This project is a starting point for a Flutter application.
8 |
9 | A few resources to get you started if this is your first Flutter project:
10 |
11 | - [Lab: Write your first Flutter app](https://docs.flutter.dev/get-started/codelab)
12 | - [Cookbook: Useful Flutter samples](https://docs.flutter.dev/cookbook)
13 |
14 | For help getting started with Flutter development, view the
15 | [online documentation](https://docs.flutter.dev/), which offers tutorials,
16 | samples, guidance on mobile development, and a full API reference.
17 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/analysis_options.yaml:
--------------------------------------------------------------------------------
1 | # This file configures the analyzer, which statically analyzes Dart code to
2 | # check for errors, warnings, and lints.
3 | #
4 | # The issues identified by the analyzer are surfaced in the UI of Dart-enabled
5 | # IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
6 | # invoked from the command line by running `flutter analyze`.
7 |
8 | # The following line activates a set of recommended lints for Flutter apps,
9 | # packages, and plugins designed to encourage good coding practices.
10 | include: package:flutter_lints/flutter.yaml
11 |
12 | linter:
13 | # The lint rules applied to this project can be customized in the
14 | # section below to disable rules from the `package:flutter_lints/flutter.yaml`
15 | # included above or to enable additional rules. A list of all available lints
16 | # and their documentation is published at https://dart.dev/lints.
17 | #
18 | # Instead of disabling a lint rule for the entire project in the
19 | # section below, it can also be suppressed for a single line of code
20 | # or a specific dart file by using the `// ignore: name_of_lint` and
21 | # `// ignore_for_file: name_of_lint` syntax on the line or in the file
22 | # producing the lint.
23 | rules:
24 | # avoid_print: false # Uncomment to disable the `avoid_print` rule
25 | # prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
26 |
27 | # Additional information about this file can be found at
28 | # https://dart.dev/guides/language/analysis-options
29 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/.gitignore:
--------------------------------------------------------------------------------
1 | gradle-wrapper.jar
2 | /.gradle
3 | /captures/
4 | /gradlew
5 | /gradlew.bat
6 | /local.properties
7 | GeneratedPluginRegistrant.java
8 | .cxx/
9 |
10 | # Remember to never publicly share your keystore.
11 | # See https://flutter.dev/to/reference-keystore
12 | key.properties
13 | **/*.keystore
14 | **/*.jks
15 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/build.gradle.kts:
--------------------------------------------------------------------------------
1 | plugins {
2 | id("com.android.application")
3 | id("kotlin-android")
4 | // The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
5 | id("dev.flutter.flutter-gradle-plugin")
6 | }
7 |
8 | android {
9 | namespace = "com.example.example"
10 | compileSdk = flutter.compileSdkVersion
11 | ndkVersion = flutter.ndkVersion
12 |
13 | compileOptions {
14 | sourceCompatibility = JavaVersion.VERSION_11
15 | targetCompatibility = JavaVersion.VERSION_11
16 | }
17 |
18 | kotlinOptions {
19 | jvmTarget = JavaVersion.VERSION_11.toString()
20 | }
21 |
22 | defaultConfig {
23 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
24 | applicationId = "com.example.example"
25 | // You can update the following values to match your application needs.
26 | // For more information, see: https://flutter.dev/to/review-gradle-config.
27 | minSdk = flutter.minSdkVersion
28 | targetSdk = flutter.targetSdkVersion
29 | versionCode = flutter.versionCode
30 | versionName = flutter.versionName
31 | }
32 |
33 | buildTypes {
34 | release {
35 | // TODO: Add your own signing config for the release build.
36 | // Signing with the debug keys for now, so `flutter run --release` works.
37 | signingConfig = signingConfigs.getByName("debug")
38 | }
39 | }
40 | }
41 |
42 | flutter {
43 | source = "../.."
44 | }
45 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/debug/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
15 |
19 |
23 |
24 |
25 |
26 |
27 |
28 |
30 |
33 |
34 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/kotlin/com/example/example/MainActivity.kt:
--------------------------------------------------------------------------------
1 | package com.example.example
2 |
3 | import io.flutter.embedding.android.FlutterActivity
4 |
5 | class MainActivity : FlutterActivity()
6 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/drawable-v21/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
12 |
13 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/drawable/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
12 |
13 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/values-night/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
9 |
15 |
18 |
19 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
9 |
15 |
18 |
19 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/app/src/profile/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/build.gradle.kts:
--------------------------------------------------------------------------------
1 | allprojects {
2 | repositories {
3 | google()
4 | mavenCentral()
5 | }
6 | }
7 |
8 | val newBuildDir: Directory = rootProject.layout.buildDirectory.dir("../../build").get()
9 | rootProject.layout.buildDirectory.value(newBuildDir)
10 |
11 | subprojects {
12 | val newSubprojectBuildDir: Directory = newBuildDir.dir(project.name)
13 | project.layout.buildDirectory.value(newSubprojectBuildDir)
14 | }
15 | subprojects {
16 | project.evaluationDependsOn(":app")
17 | }
18 |
19 | tasks.register("clean") {
20 | delete(rootProject.layout.buildDirectory)
21 | }
22 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.jvmargs=-Xmx8G -XX:MaxMetaspaceSize=4G -XX:ReservedCodeCacheSize=512m -XX:+HeapDumpOnOutOfMemoryError
2 | android.useAndroidX=true
3 | android.enableJetifier=true
4 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionBase=GRADLE_USER_HOME
2 | distributionPath=wrapper/dists
3 | zipStoreBase=GRADLE_USER_HOME
4 | zipStorePath=wrapper/dists
5 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.10.2-all.zip
6 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/android/settings.gradle.kts:
--------------------------------------------------------------------------------
1 | pluginManagement {
2 | val flutterSdkPath = run {
3 | val properties = java.util.Properties()
4 | file("local.properties").inputStream().use { properties.load(it) }
5 | val flutterSdkPath = properties.getProperty("flutter.sdk")
6 | require(flutterSdkPath != null) { "flutter.sdk not set in local.properties" }
7 | flutterSdkPath
8 | }
9 |
10 | includeBuild("$flutterSdkPath/packages/flutter_tools/gradle")
11 |
12 | repositories {
13 | google()
14 | mavenCentral()
15 | gradlePluginPortal()
16 | }
17 | }
18 |
19 | plugins {
20 | id("dev.flutter.flutter-plugin-loader") version "1.0.0"
21 | id("com.android.application") version "8.7.0" apply false
22 | id("org.jetbrains.kotlin.android") version "1.8.22" apply false
23 | }
24 |
25 | include(":app")
26 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/.gitignore:
--------------------------------------------------------------------------------
1 | **/dgph
2 | *.mode1v3
3 | *.mode2v3
4 | *.moved-aside
5 | *.pbxuser
6 | *.perspectivev3
7 | **/*sync/
8 | .sconsign.dblite
9 | .tags*
10 | **/.vagrant/
11 | **/DerivedData/
12 | Icon?
13 | **/Pods/
14 | **/.symlinks/
15 | profile
16 | xcuserdata
17 | **/.generated/
18 | Flutter/App.framework
19 | Flutter/Flutter.framework
20 | Flutter/Flutter.podspec
21 | Flutter/Generated.xcconfig
22 | Flutter/ephemeral/
23 | Flutter/app.flx
24 | Flutter/app.zip
25 | Flutter/flutter_assets/
26 | Flutter/flutter_export_environment.sh
27 | ServiceDefinitions.json
28 | Runner/GeneratedPluginRegistrant.*
29 |
30 | # Exceptions to above rules.
31 | !default.mode1v3
32 | !default.mode2v3
33 | !default.pbxuser
34 | !default.perspectivev3
35 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Flutter/AppFrameworkInfo.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | App
9 | CFBundleIdentifier
10 | io.flutter.flutter.app
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | App
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1.0
23 | MinimumOSVersion
24 | 12.0
25 |
26 |
27 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Flutter/Debug.xcconfig:
--------------------------------------------------------------------------------
1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Flutter/Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include? "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Podfile:
--------------------------------------------------------------------------------
1 | # Uncomment this line to define a global platform for your project
2 | # platform :ios, '12.0'
3 |
4 | # CocoaPods analytics sends network stats synchronously affecting flutter build latency.
5 | ENV['COCOAPODS_DISABLE_STATS'] = 'true'
6 |
7 | project 'Runner', {
8 | 'Debug' => :debug,
9 | 'Profile' => :release,
10 | 'Release' => :release,
11 | }
12 |
13 | def flutter_root
14 | generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__)
15 | unless File.exist?(generated_xcode_build_settings_path)
16 | raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first"
17 | end
18 |
19 | File.foreach(generated_xcode_build_settings_path) do |line|
20 | matches = line.match(/FLUTTER_ROOT\=(.*)/)
21 | return matches[1].strip if matches
22 | end
23 | raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get"
24 | end
25 |
26 | require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root)
27 |
28 | flutter_ios_podfile_setup
29 |
30 | target 'Runner' do
31 | use_frameworks!
32 |
33 | flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
34 | target 'RunnerTests' do
35 | inherit! :search_paths
36 | end
37 | end
38 |
39 | post_install do |installer|
40 | installer.pods_project.targets.each do |target|
41 | flutter_additional_ios_build_settings(target)
42 | end
43 | end
44 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Podfile.lock:
--------------------------------------------------------------------------------
1 | PODS:
2 | - AgoraInfra_iOS (1.2.13)
3 | - Flutter (1.0.0)
4 | - HyphenateChat (4.13.0):
5 | - AgoraInfra_iOS (= 1.2.13)
6 | - im_flutter_sdk_ios (0.0.1):
7 | - Flutter
8 | - HyphenateChat (= 4.13.0)
9 |
10 | DEPENDENCIES:
11 | - Flutter (from `Flutter`)
12 | - im_flutter_sdk_ios (from `.symlinks/plugins/im_flutter_sdk_ios/ios`)
13 |
14 | SPEC REPOS:
15 | trunk:
16 | - AgoraInfra_iOS
17 | - HyphenateChat
18 |
19 | EXTERNAL SOURCES:
20 | Flutter:
21 | :path: Flutter
22 | im_flutter_sdk_ios:
23 | :path: ".symlinks/plugins/im_flutter_sdk_ios/ios"
24 |
25 | SPEC CHECKSUMS:
26 | AgoraInfra_iOS: 65e11a2183ab7836258768868d06058c22701b13
27 | Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7
28 | HyphenateChat: c2ecd32ae5328c027d8e270bdbe63c0902cfc828
29 | im_flutter_sdk_ios: 989968246d61b7472044cd19c93ff2bb70194a10
30 |
31 | PODFILE CHECKSUM: 4305caec6b40dde0ae97be1573c53de1882a07e5
32 |
33 | COCOAPODS: 1.15.2
34 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner.xcodeproj/project.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreviewsEnabled
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
30 |
31 |
37 |
38 |
39 |
40 |
43 |
49 |
50 |
51 |
52 |
53 |
64 |
66 |
72 |
73 |
74 |
75 |
81 |
83 |
89 |
90 |
91 |
92 |
94 |
95 |
98 |
99 |
100 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner.xcworkspace/xcshareddata/WorkspaceSettings.xcsettings:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | PreviewsEnabled
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | import Flutter
2 | import UIKit
3 |
4 | @main
5 | @objc class AppDelegate: FlutterAppDelegate {
6 | override func application(
7 | _ application: UIApplication,
8 | didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?
9 | ) -> Bool {
10 | GeneratedPluginRegistrant.register(with: self)
11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions)
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "size" : "20x20",
5 | "idiom" : "iphone",
6 | "filename" : "Icon-App-20x20@2x.png",
7 | "scale" : "2x"
8 | },
9 | {
10 | "size" : "20x20",
11 | "idiom" : "iphone",
12 | "filename" : "Icon-App-20x20@3x.png",
13 | "scale" : "3x"
14 | },
15 | {
16 | "size" : "29x29",
17 | "idiom" : "iphone",
18 | "filename" : "Icon-App-29x29@1x.png",
19 | "scale" : "1x"
20 | },
21 | {
22 | "size" : "29x29",
23 | "idiom" : "iphone",
24 | "filename" : "Icon-App-29x29@2x.png",
25 | "scale" : "2x"
26 | },
27 | {
28 | "size" : "29x29",
29 | "idiom" : "iphone",
30 | "filename" : "Icon-App-29x29@3x.png",
31 | "scale" : "3x"
32 | },
33 | {
34 | "size" : "40x40",
35 | "idiom" : "iphone",
36 | "filename" : "Icon-App-40x40@2x.png",
37 | "scale" : "2x"
38 | },
39 | {
40 | "size" : "40x40",
41 | "idiom" : "iphone",
42 | "filename" : "Icon-App-40x40@3x.png",
43 | "scale" : "3x"
44 | },
45 | {
46 | "size" : "60x60",
47 | "idiom" : "iphone",
48 | "filename" : "Icon-App-60x60@2x.png",
49 | "scale" : "2x"
50 | },
51 | {
52 | "size" : "60x60",
53 | "idiom" : "iphone",
54 | "filename" : "Icon-App-60x60@3x.png",
55 | "scale" : "3x"
56 | },
57 | {
58 | "size" : "20x20",
59 | "idiom" : "ipad",
60 | "filename" : "Icon-App-20x20@1x.png",
61 | "scale" : "1x"
62 | },
63 | {
64 | "size" : "20x20",
65 | "idiom" : "ipad",
66 | "filename" : "Icon-App-20x20@2x.png",
67 | "scale" : "2x"
68 | },
69 | {
70 | "size" : "29x29",
71 | "idiom" : "ipad",
72 | "filename" : "Icon-App-29x29@1x.png",
73 | "scale" : "1x"
74 | },
75 | {
76 | "size" : "29x29",
77 | "idiom" : "ipad",
78 | "filename" : "Icon-App-29x29@2x.png",
79 | "scale" : "2x"
80 | },
81 | {
82 | "size" : "40x40",
83 | "idiom" : "ipad",
84 | "filename" : "Icon-App-40x40@1x.png",
85 | "scale" : "1x"
86 | },
87 | {
88 | "size" : "40x40",
89 | "idiom" : "ipad",
90 | "filename" : "Icon-App-40x40@2x.png",
91 | "scale" : "2x"
92 | },
93 | {
94 | "size" : "76x76",
95 | "idiom" : "ipad",
96 | "filename" : "Icon-App-76x76@1x.png",
97 | "scale" : "1x"
98 | },
99 | {
100 | "size" : "76x76",
101 | "idiom" : "ipad",
102 | "filename" : "Icon-App-76x76@2x.png",
103 | "scale" : "2x"
104 | },
105 | {
106 | "size" : "83.5x83.5",
107 | "idiom" : "ipad",
108 | "filename" : "Icon-App-83.5x83.5@2x.png",
109 | "scale" : "2x"
110 | },
111 | {
112 | "size" : "1024x1024",
113 | "idiom" : "ios-marketing",
114 | "filename" : "Icon-App-1024x1024@1x.png",
115 | "scale" : "1x"
116 | }
117 | ],
118 | "info" : {
119 | "version" : 1,
120 | "author" : "xcode"
121 | }
122 | }
123 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "universal",
5 | "filename" : "LaunchImage.png",
6 | "scale" : "1x"
7 | },
8 | {
9 | "idiom" : "universal",
10 | "filename" : "LaunchImage@2x.png",
11 | "scale" : "2x"
12 | },
13 | {
14 | "idiom" : "universal",
15 | "filename" : "LaunchImage@3x.png",
16 | "scale" : "3x"
17 | }
18 | ],
19 | "info" : {
20 | "version" : 1,
21 | "author" : "xcode"
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Assets.xcassets/LaunchImage.imageset/README.md:
--------------------------------------------------------------------------------
1 | # Launch Screen Assets
2 |
3 | You can customize the launch screen with your own desired assets by replacing the image files in this directory.
4 |
5 | You can also do it by opening your Flutter project's Xcode project with `open ios/Runner.xcworkspace`, selecting `Runner/Assets.xcassets` in the Project Navigator and dropping in the desired images.
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
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 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
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 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleDisplayName
8 | Example
9 | CFBundleExecutable
10 | $(EXECUTABLE_NAME)
11 | CFBundleIdentifier
12 | $(PRODUCT_BUNDLE_IDENTIFIER)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | example
17 | CFBundlePackageType
18 | APPL
19 | CFBundleShortVersionString
20 | $(FLUTTER_BUILD_NAME)
21 | CFBundleSignature
22 | ????
23 | CFBundleVersion
24 | $(FLUTTER_BUILD_NUMBER)
25 | LSRequiresIPhoneOS
26 |
27 | UILaunchStoryboardName
28 | LaunchScreen
29 | UIMainStoryboardFile
30 | Main
31 | UISupportedInterfaceOrientations
32 |
33 | UIInterfaceOrientationPortrait
34 | UIInterfaceOrientationLandscapeLeft
35 | UIInterfaceOrientationLandscapeRight
36 |
37 | UISupportedInterfaceOrientations~ipad
38 |
39 | UIInterfaceOrientationPortrait
40 | UIInterfaceOrientationPortraitUpsideDown
41 | UIInterfaceOrientationLandscapeLeft
42 | UIInterfaceOrientationLandscapeRight
43 |
44 | CADisableMinimumFrameDurationOnPhone
45 |
46 | UIApplicationSupportsIndirectInputEvents
47 |
48 |
49 |
50 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/Runner/Runner-Bridging-Header.h:
--------------------------------------------------------------------------------
1 | #import "GeneratedPluginRegistrant.h"
2 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/ios/RunnerTests/RunnerTests.swift:
--------------------------------------------------------------------------------
1 | import Flutter
2 | import UIKit
3 | import XCTest
4 |
5 | class RunnerTests: XCTestCase {
6 |
7 | func testExample() {
8 | // If you add code to the Runner application, consider adding tests here.
9 | // See https://developer.apple.com/documentation/xctest for more information about using XCTest.
10 | }
11 |
12 | }
13 |
--------------------------------------------------------------------------------
/im_flutter_sdk/example/pubspec.yaml:
--------------------------------------------------------------------------------
1 | name: example
2 | description: "A new Flutter project."
3 | # The following line prevents the package from being accidentally published to
4 | # pub.dev using `flutter pub publish`. This is preferred for private packages.
5 | publish_to: 'none' # Remove this line if you wish to publish to pub.dev
6 |
7 | # The following defines the version and build number for your application.
8 | # A version number is three numbers separated by dots, like 1.2.43
9 | # followed by an optional build number separated by a +.
10 | # Both the version and the builder number may be overridden in flutter
11 | # build by specifying --build-name and --build-number, respectively.
12 | # In Android, build-name is used as versionName while build-number used as versionCode.
13 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning
14 | # In iOS, build-name is used as CFBundleShortVersionString while build-number is used as CFBundleVersion.
15 | # Read more about iOS versioning at
16 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
17 | # In Windows, build-name is used as the major, minor, and patch parts
18 | # of the product and file versions while build-number is used as the build suffix.
19 | version: 1.0.0+1
20 |
21 |
22 |
23 | environment:
24 | sdk: ^3.4.0
25 |
26 | # Dependencies specify other packages that your package needs in order to work.
27 | # To automatically upgrade your package dependencies to the latest versions
28 | # consider running `flutter pub upgrade --major-versions`. Alternatively,
29 | # dependencies can be manually updated by changing the version numbers below to
30 | # the latest version available on pub.dev. To see which dependencies have newer
31 | # versions available, run `flutter pub outdated`.
32 | dependencies:
33 | flutter:
34 | sdk: flutter
35 |
36 | # The following adds the Cupertino Icons font to your application.
37 | # Use with the CupertinoIcons class for iOS style icons.
38 | cupertino_icons: ^1.0.8
39 |
40 | im_flutter_sdk:
41 | path: ../
42 |
43 | dependency_overrides:
44 |
45 | # im_flutter_sdk_interface:
46 | # path: ../../im_flutter_sdk_interface
47 |
48 | # im_flutter_sdk_ios:
49 | # path: ../../im_flutter_sdk_ios
50 |
51 | # im_flutter_sdk_android:
52 | # path: ../../im_flutter_sdk_android
53 |
54 | dev_dependencies:
55 | flutter_test:
56 | sdk: flutter
57 |
58 | # The "flutter_lints" package below contains a set of recommended lints to
59 | # encourage good coding practices. The lint set provided by the package is
60 | # activated in the `analysis_options.yaml` file located at the root of your
61 | # package. See that file for information about deactivating specific lint
62 | # rules and activating additional ones.
63 | flutter_lints: ^4.0.0
64 |
65 | # For information on the generic Dart part of this file, see the
66 | # following page: https://dart.dev/tools/pub/pubspec
67 |
68 | # The following section is specific to Flutter packages.
69 | flutter:
70 |
71 | # The following line ensures that the Material Icons font is
72 | # included with your application, so that you can use the icons in
73 | # the material Icons class.
74 | uses-material-design: true
75 |
76 | # To add assets to your application, add an assets section, like this:
77 | # assets:
78 | # - images/a_dot_burr.jpeg
79 | # - images/a_dot_ham.jpeg
80 |
81 | # An image asset can refer to one or more resolution-specific "variants", see
82 | # https://flutter.dev/to/resolution-aware-images
83 |
84 | # For details regarding adding assets from package dependencies, see
85 | # https://flutter.dev/to/asset-from-package
86 |
87 | # To add custom fonts to your application, add a fonts section here,
88 | # in this "flutter" section. Each entry in this list should have a
89 | # "family" key with the font family name, and a "fonts" key with a
90 | # list giving the asset and other descriptors for the font. For
91 | # example:
92 | # fonts:
93 | # - family: Schyler
94 | # fonts:
95 | # - asset: fonts/Schyler-Regular.ttf
96 | # - asset: fonts/Schyler-Italic.ttf
97 | # style: italic
98 | # - family: Trajan Pro
99 | # fonts:
100 | # - asset: fonts/TrajanPro.ttf
101 | # - asset: fonts/TrajanPro_Bold.ttf
102 | # weight: 700
103 | #
104 | # For details regarding fonts from package dependencies,
105 | # see https://flutter.dev/to/font-from-package
106 |
--------------------------------------------------------------------------------
/im_flutter_sdk/lib/im_flutter_sdk.dart:
--------------------------------------------------------------------------------
1 | export 'package:im_flutter_sdk_interface/im_flutter_sdk_interface.dart'
2 | show
3 | EMConnectionEventHandler,
4 | EMMultiDeviceEventHandler,
5 | EMChatEventHandler,
6 | EMChatRoomEventHandler,
7 | EMChatThreadEventHandler,
8 | EMPresenceEventHandler,
9 | EMContactEventHandler,
10 | EMGroupEventHandler,
11 | ChatSilentModeParam,
12 | ConversationFetchOptions,
13 | ChatMessageEvent,
14 | EMGroupStyle,
15 | EMConversationType,
16 | EMTextMessageBody,
17 | EMImageMessageBody,
18 | EMVoiceMessageBody,
19 | EMVideoMessageBody,
20 | EMLocationMessageBody,
21 | EMFileMessageBody,
22 | EMCustomMessageBody,
23 | EMCmdMessageBody,
24 | EMCombineMessageBody,
25 | EMMessageBody,
26 | ChatType,
27 | MessageDirection,
28 | MessageStatus,
29 | DownloadStatus,
30 | MessageType,
31 | EMGroupPermissionType,
32 | EMChatRoomPermissionType,
33 | EMSearchDirection,
34 | EMMultiDevicesEvent,
35 | EMChatThreadOperation,
36 | DisplayStyle,
37 | ChatSilentModeParamType,
38 | ChatPushRemindType,
39 | ChatRoomMessagePriority,
40 | ReactionOperate,
41 | LeaveReason,
42 | MessagePinOperation,
43 | MessageSearchScope,
44 | ConversationMarkType,
45 | EMChatRoom,
46 | EMChatThread,
47 | EMContact,
48 | EMConversation,
49 | EMCursorResult,
50 | EMDeviceInfo,
51 | EMDownloadCallback,
52 | EMError,
53 | EMGroupMessageAck,
54 | EMGroupOptions,
55 | EMGroupSharedFile,
56 | EMGroup,
57 | EMMessageReaction,
58 | EMMessage,
59 | EMOptions,
60 | ExtSettings,
61 | EMPageResult,
62 | EMPresence,
63 | EMPushConfigs,
64 | EMTranslateLanguage,
65 | EMUserInfo,
66 | FetchMessageOptions,
67 | ReactionOperation,
68 | RecallMessageInfo,
69 | EMMessageReactionEvent,
70 | EMGroupInfo,
71 | ChatSilentModeResult,
72 | EMChatThreadEvent,
73 | ChatSilentModeTime,
74 | MessagePinInfo,
75 | LoginExtensionInfo,
76 | MessageSearchOptions,
77 | ChatAreaCode;
78 |
79 | export 'src/chat_manager.dart';
80 | export 'src/chat_room_manager.dart';
81 | export 'src/chat_thread_manager.dart';
82 | export 'src/client.dart';
83 | export 'src/contact_manager.dart';
84 | export 'src/group_manager.dart';
85 | export 'src/presence_manager.dart';
86 | export 'src/push_manager.dart';
87 | export 'src/user_info_manager.dart';
88 |
--------------------------------------------------------------------------------
/im_flutter_sdk/pubspec.yaml:
--------------------------------------------------------------------------------
1 | name: im_flutter_sdk
2 | description: Integrate the Chat SDK to enjoy the global IM services with high reliability, ultra-low latency, and high concurrency.
3 | version: 4.13.0+1
4 | homepage: https://www.easemob.com
5 |
6 | environment:
7 | sdk: '>=3.3.0 <4.0.0'
8 | flutter: '>=3.3.0'
9 |
10 | dependencies:
11 | flutter:
12 | sdk: flutter
13 |
14 | im_flutter_sdk_interface: ^4.13.0+1
15 |
16 | im_flutter_sdk_ios: ^4.13.0+1
17 |
18 | im_flutter_sdk_android: ^4.13.0+1
19 |
20 |
21 | dev_dependencies:
22 | flutter_lints: ^4.0.0
23 |
24 |
25 | flutter:
26 | plugin:
27 | platforms:
28 | ios:
29 | default_package: im_flutter_sdk_ios
30 | android:
31 | default_package: im_flutter_sdk_android
32 | ohos:
33 | default_package: im_flutter_sdk_ohos
34 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/.gitignore:
--------------------------------------------------------------------------------
1 | # Miscellaneous
2 | *.class
3 | *.log
4 | *.pyc
5 | *.swp
6 | .DS_Store
7 | .atom/
8 | .buildlog/
9 | .history
10 | .svn/
11 | migrate_working_dir/
12 |
13 | # IntelliJ related
14 | *.iml
15 | *.ipr
16 | *.iws
17 | .idea/
18 |
19 | # The .vscode folder contains launch configuration and tasks you configure in
20 | # VS Code which you may wish to be included in version control, so this line
21 | # is commented out by default.
22 | #.vscode/
23 |
24 | # Flutter/Dart/Pub related
25 | # Libraries should not include pubspec.lock, per https://dart.dev/guides/libraries/private-files#pubspeclock.
26 | /pubspec.lock
27 | **/doc/api/
28 | .dart_tool/
29 | build/
30 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/.metadata:
--------------------------------------------------------------------------------
1 | # This file tracks properties of this Flutter project.
2 | # Used by Flutter tool to assess capabilities and perform upgrades etc.
3 | #
4 | # This file should be version controlled and should not be manually edited.
5 |
6 | version:
7 | revision: "7f2ea2ea242b1ae845ad5eaf5b210c2c67da9b78"
8 | channel: "oh-3.22.0"
9 |
10 | project_type: plugin
11 |
12 | # Tracks metadata for the flutter migrate command
13 | migration:
14 | platforms:
15 | - platform: root
16 | create_revision: 7f2ea2ea242b1ae845ad5eaf5b210c2c67da9b78
17 | base_revision: 7f2ea2ea242b1ae845ad5eaf5b210c2c67da9b78
18 | - platform: android
19 | create_revision: 7f2ea2ea242b1ae845ad5eaf5b210c2c67da9b78
20 | base_revision: 7f2ea2ea242b1ae845ad5eaf5b210c2c67da9b78
21 |
22 | # User provided section
23 |
24 | # List of Local paths (relative to this file) that should be
25 | # ignored by the migrate tool.
26 | #
27 | # Files that are not part of the templates will be ignored by default.
28 | unmanaged_files:
29 | - 'lib/main.dart'
30 | - 'ios/Runner.xcodeproj/project.pbxproj'
31 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/CHANGELOG.md:
--------------------------------------------------------------------------------
1 | ## 4.13.0+1
2 |
3 | - 修复收到 `onAnnouncementChangedFromChatRoom` 回调时,`announcement` 为空导致的崩溃问题。
4 | - 修复收到 `onAnnouncementChangedFromGroup` 回调时,`announcement` 为空导致的崩溃问题。
5 |
6 | ## 4.13.0
7 |
8 | * 更新原生sdk为 4.13.0
9 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Permission is hereby granted, free of charge, to any person obtaining a copy
4 | of this software and associated documentation files (the "Software"), to deal
5 | in the Software without restriction, including without limitation the rights
6 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 | copies of the Software, and to permit persons to whom the Software is
8 | furnished to do so, subject to the following conditions:
9 |
10 | The above copyright notice and this permission notice shall be included in all
11 | copies or substantial portions of the Software.
12 |
13 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
19 | SOFTWARE.
--------------------------------------------------------------------------------
/im_flutter_sdk_android/README.md:
--------------------------------------------------------------------------------
1 | # im_flutter_sdk_android
2 |
3 | A new Flutter project.
4 |
5 | ## Getting Started
6 |
7 | This project is a starting point for a Flutter
8 | [plug-in package](https://flutter.dev/developing-packages/),
9 | a specialized package that includes platform-specific implementation code for
10 | Android and/or iOS.
11 |
12 | For help getting started with Flutter development, view the
13 | [online documentation](https://flutter.dev/docs), which offers tutorials,
14 | samples, guidance on mobile development, and a full API reference.
15 |
16 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/analysis_options.yaml:
--------------------------------------------------------------------------------
1 | include: package:flutter_lints/flutter.yaml
2 |
3 | # Additional information about this file can be found at
4 | # https://dart.dev/guides/language/analysis-options
5 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/.gitignore:
--------------------------------------------------------------------------------
1 | *.iml
2 | .gradle
3 | /local.properties
4 | /.idea/workspace.xml
5 | /.idea/libraries
6 | .DS_Store
7 | /build
8 | /captures
9 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/build.gradle:
--------------------------------------------------------------------------------
1 | group 'com.easemob.im_flutter_sdk'
2 | version '1.0-SNAPSHOT'
3 |
4 |
5 | buildscript {
6 | repositories {
7 | google()
8 | mavenCentral()
9 | }
10 |
11 | dependencies {
12 | classpath("com.android.tools.build:gradle:7.3.0")
13 | }
14 | }
15 |
16 | allprojects {
17 | repositories {
18 | google()
19 | mavenCentral()
20 | }
21 | }
22 |
23 | apply plugin: 'com.android.library'
24 |
25 | android {
26 |
27 | if (project.android.hasProperty("namespace")) {
28 | namespace = "com.easemob.im_flutter_sdk"
29 | }
30 |
31 | compileSdk = 34
32 |
33 | compileOptions {
34 | sourceCompatibility = JavaVersion.VERSION_1_8
35 | targetCompatibility = JavaVersion.VERSION_1_8
36 | }
37 |
38 | defaultConfig {
39 | minSdk = 21
40 | }
41 | }
42 |
43 | tasks.withType(JavaCompile){
44 | options.encoding = "UTF-8"
45 | }
46 |
47 | dependencies {
48 | api 'androidx.appcompat:appcompat:1.1.0'
49 | // implementation 'cn.shengwang:chat-sdk:1.3.2'
50 | implementation 'io.hyphenate:hyphenate-chat:4.13.0'
51 | implementation fileTree(dir: 'libs', include: ['*.jar'])
52 | }
53 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.jvmargs=-Xmx1536M
2 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/easemob/im_flutter_sdk/dcf594fac2b9abc6ff1cbd1b11ef765cd34d9c13/im_flutter_sdk_android/android/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Tue Oct 01 18:32:53 CST 2019
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-5.4.1-all.zip
7 | distributionUrl=https\://mirrors.cloud.tencent.com/gradle/gradle-8.5-all.zip
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/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 | set DIRNAME=%~dp0
12 | if "%DIRNAME%" == "" set DIRNAME=.
13 | set APP_BASE_NAME=%~n0
14 | set APP_HOME=%DIRNAME%
15 |
16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
17 | set DEFAULT_JVM_OPTS=
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 Windows variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 |
53 | :win9xME_args
54 | @rem Slurp the command line arguments.
55 | set CMD_LINE_ARGS=
56 | set _SKIP=2
57 |
58 | :win9xME_args_slurp
59 | if "x%~1" == "x" goto execute
60 |
61 | set CMD_LINE_ARGS=%*
62 |
63 | :execute
64 | @rem Setup the command line
65 |
66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
67 |
68 | @rem Execute Gradle
69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
70 |
71 | :end
72 | @rem End local scope for the variables with windows NT shell
73 | if "%ERRORLEVEL%"=="0" goto mainEnd
74 |
75 | :fail
76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
77 | rem the _cmd.exe /c_ return code!
78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
79 | exit /b 1
80 |
81 | :mainEnd
82 | if "%OS%"=="Windows_NT" endlocal
83 |
84 | :omega
85 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/settings.gradle:
--------------------------------------------------------------------------------
1 | rootProject.name = 'im_flutter_sdk'
2 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/src/main/java/com/easemob/im_flutter_sdk/CommonUtil.java:
--------------------------------------------------------------------------------
1 | package com.easemob.im_flutter_sdk;
2 |
3 | import org.json.JSONException;
4 | import org.json.JSONObject;
5 |
6 | import java.util.Map;
7 |
8 | public class CommonUtil {
9 |
10 | static public void putObjectToMap(Map map, String key, Object value) {
11 | if (value != null)
12 | {
13 | map.put(key, value);
14 | }
15 | }
16 |
17 | static Object getValueFromMap(Map map, String key) {
18 | if (map.containsKey(key)) {
19 | return map.get(key);
20 | }
21 | return null;
22 | }
23 |
24 | static Object getValueFromJsonObject(JSONObject jo, String key) {
25 | if (jo.has(key)) {
26 | try {
27 | return jo.get(key);
28 | } catch (JSONException e) {
29 | e.printStackTrace();
30 | }
31 | }
32 | return null;
33 | }
34 |
35 | }
36 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/src/main/java/com/easemob/im_flutter_sdk/HelpTool.java:
--------------------------------------------------------------------------------
1 | package com.easemob.im_flutter_sdk;
2 | import com.hyphenate.chat.EMMessage;
3 | import org.json.JSONArray;
4 | import org.json.JSONException;
5 | import org.json.JSONObject;
6 | import java.util.Map;
7 | public class HelpTool {
8 | public static void mergeMessage(EMMessage msg, EMMessage dbMsg) throws JSONException {
9 | dbMsg.setMsgTime(msg.getMsgTime());
10 | dbMsg.setLocalTime(msg.localTime());
11 | dbMsg.setStatus(msg.status());
12 | dbMsg.setAcked(msg.isAcked());
13 | dbMsg.setIsChatThreadMessage(msg.isChatThreadMessage());
14 | dbMsg.setIsNeedGroupAck(msg.isNeedGroupAck());
15 | dbMsg.setDeliverAcked(msg.isDelivered());
16 | dbMsg.setUnread(msg.isUnread());
17 | dbMsg.setListened(msg.isListened());
18 | dbMsg.setReceiverList(msg.receiverList());
19 | dbMsg.deliverOnlineOnly(msg.isDeliverOnlineOnly());
20 | Map list = msg.getAttributes();
21 | if (!list.isEmpty()) {
22 | JSONObject jsonParams = new JSONObject(list);
23 | for (Map.Entry entry : list.entrySet()) {
24 | String key = entry.getKey();
25 | Object result = entry.getValue();
26 | if (result.getClass().getSimpleName().equals("Integer")) {
27 | dbMsg.setAttribute(key, (Integer)result);
28 | } else if (result.getClass().getSimpleName().equals("Boolean")) {
29 | dbMsg.setAttribute(key, (Boolean)result);
30 | } else if (result.getClass().getSimpleName().equals("Long")) {
31 | dbMsg.setAttribute(key, (Long)result);
32 | } else if (result.getClass().getSimpleName().equals("Double") ||
33 | result.getClass().getSimpleName().equals("Float")) {
34 | dbMsg.setAttribute(key, (Double)result);
35 | } else if (result.getClass().getSimpleName().equals("JSONObject")) {
36 | dbMsg.setAttribute(key, (JSONObject)result);
37 | } else if (result.getClass().getSimpleName().equals("JSONArray")) {
38 | dbMsg.setAttribute(key, (JSONArray)result);
39 | } else {
40 | dbMsg.setAttribute(key, jsonParams.getString(key));
41 | }
42 | }
43 | }
44 | dbMsg.setBody(msg.getBody());
45 | }
46 | }
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/src/main/java/com/easemob/im_flutter_sdk/ListenerHandle.java:
--------------------------------------------------------------------------------
1 | package com.easemob.im_flutter_sdk;
2 |
3 | import java.util.ArrayList;
4 | import java.util.List;
5 |
6 | public class ListenerHandle {
7 |
8 | static private ListenerHandle handle;
9 |
10 | private List emActionHandle;
11 |
12 | private boolean hasReady;
13 |
14 |
15 | public static ListenerHandle getInstance() {
16 | if (handle == null) {
17 | handle = new ListenerHandle();
18 | }
19 | return handle;
20 | }
21 |
22 | private ListenerHandle(){
23 | emActionHandle = new ArrayList<>();
24 | }
25 |
26 | void addHandle(Runnable runnable) {
27 | emActionHandle.add(runnable);
28 | if (hasReady) {
29 | runHandle();
30 | }
31 | }
32 |
33 | void runHandle() {
34 | synchronized (emActionHandle){
35 | List tmp = emActionHandle;
36 | for (Runnable action : tmp) {
37 | action.run();
38 | }
39 | emActionHandle.clear();
40 | }
41 | }
42 |
43 | void startCallback(){
44 | hasReady = true;
45 | runHandle();
46 | }
47 |
48 | void clearHandle(){
49 | hasReady = false;
50 | synchronized (emActionHandle) {
51 | emActionHandle.clear();
52 | }
53 | }
54 | }
55 |
--------------------------------------------------------------------------------
/im_flutter_sdk_android/android/src/main/java/com/easemob/im_flutter_sdk/MessageWrapper.java:
--------------------------------------------------------------------------------
1 | package com.easemob.im_flutter_sdk;
2 |
3 | import com.hyphenate.chat.EMClient;
4 | import com.hyphenate.chat.EMMessage;
5 | import com.hyphenate.chat.EMMessageReaction;
6 |
7 | import org.json.JSONException;
8 | import org.json.JSONObject;
9 |
10 | import java.util.ArrayList;
11 | import java.util.List;
12 | import java.util.Map;
13 |
14 | import io.flutter.embedding.engine.plugins.FlutterPlugin;
15 | import io.flutter.plugin.common.MethodCall;
16 | import io.flutter.plugin.common.MethodChannel;
17 |
18 | public class MessageWrapper extends Wrapper implements MethodChannel.MethodCallHandler {
19 | public MessageWrapper(FlutterPlugin.FlutterPluginBinding flutterPluginBinding, String channelName) {
20 | super(flutterPluginBinding, channelName);
21 | }
22 |
23 |
24 | @Override
25 | public void onMethodCall(MethodCall call, MethodChannel.Result result) {
26 |
27 | JSONObject param = (JSONObject)call.arguments;
28 |
29 | try {
30 | if (MethodKey.getReactionList.equals(call.method)) {
31 | reactionList(param, call.method, result);
32 | }else if (MethodKey.groupAckCount.equals(call.method)){
33 | getAckCount(param, call.method, result);
34 | }else if (MethodKey.getChatThread.equals(call.method)) {
35 | getChatThread(param, call.method, result);
36 | }
37 | // 450
38 | else if (MethodKey.getPinInfo.equals(call.method)) {
39 | getPinInfo(param, call.method, result);
40 | }
41 | else
42 | {
43 | super.onMethodCall(call, result);
44 | }
45 | } catch (JSONException e) {
46 | e.printStackTrace();
47 | }
48 | }
49 |
50 |
51 | private void reactionList(JSONObject params, String channelName, MethodChannel.Result result) throws JSONException {
52 | String msgId = params.getString("msgId");
53 | EMMessage msg = getMessageWithId(msgId);
54 | ArrayList