├── .gitignore
├── .gradle
├── 5.2.1
│ ├── fileChanges
│ │ └── last-build.bin
│ ├── fileHashes
│ │ └── fileHashes.lock
│ └── gc.properties
├── buildOutputCleanup
│ ├── buildOutputCleanup.lock
│ └── cache.properties
└── vcs-1
│ └── gc.properties
├── .metadata
├── README.md
├── README_images
├── gridview_demo.gif
├── voice_play.gif
└── voice_send.gif
├── android
├── app
│ ├── build.gradle
│ └── src
│ │ ├── debug
│ │ └── AndroidManifest.xml
│ │ ├── main
│ │ ├── AndroidManifest.xml
│ │ ├── java
│ │ │ └── flutter
│ │ │ │ └── accs
│ │ │ │ └── com
│ │ │ │ └── flutter_app_demo
│ │ │ │ └── MainActivity.java
│ │ └── res
│ │ │ ├── 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
│ │ │ └── styles.xml
│ │ └── profile
│ │ └── AndroidManifest.xml
├── build.gradle
├── gradle.properties
├── gradle
│ └── wrapper
│ │ └── gradle-wrapper.properties
└── settings.gradle
├── data
└── EntryData.json
├── images
├── WechatIMG1.jpeg
├── camera_ico.png
├── cancel_voice.png
├── chat_room_left_voice.png
├── delete.png
├── emoji
│ ├── collection.png
│ ├── defaultEmoji.png
│ ├── fuck01.png
│ ├── fuck02.png
│ ├── fuck03.png
│ ├── fuck04.png
│ ├── fuck05.png
│ ├── fuck06.png
│ ├── fuck07.png
│ ├── fuck08.png
│ ├── fuck09.png
│ ├── fuck10.png
│ ├── fuck100.png
│ ├── fuck11.png
│ ├── fuck12.png
│ ├── fuck13.png
│ ├── fuck14.png
│ ├── fuck15.png
│ ├── fuck16.png
│ ├── fuck18.png
│ ├── fuck19.png
│ ├── fuck20.png
│ ├── fuck21.png
│ ├── fuck22.png
│ ├── fuck23.png
│ ├── fuck24.png
│ ├── fuck26.png
│ ├── fuck27.png
│ ├── fuck28.png
│ ├── fuck29.png
│ ├── fuck30.png
│ ├── fuck31.png
│ ├── fuck32.png
│ ├── fuck33.png
│ ├── fuck34.png
│ ├── fuck35.png
│ ├── fuck37.png
│ ├── fuck38.png
│ ├── fuck39.png
│ ├── fuck40.png
│ ├── fuck41.png
│ ├── fuck42.png
│ ├── fuck43.png
│ ├── fuck45.png
│ ├── fuck46.png
│ ├── fuck47.png
│ ├── fuck48.png
│ ├── fuck49.png
│ ├── fuck50.png
│ ├── fuck51.png
│ ├── fuck52.png
│ ├── fuck53.png
│ ├── fuck55.png
│ ├── fuck56.png
│ ├── fuck57.png
│ ├── fuck58.png
│ ├── fuck61.png
│ ├── fuck63.png
│ ├── fuck64.png
│ ├── fuck65.png
│ ├── fuck66.png
│ ├── fuck67.png
│ ├── fuck68.png
│ ├── fuck69.png
│ ├── fuck71.png
│ ├── fuck75.png
│ ├── fuck76.png
│ ├── fuck77.png
│ ├── fuck79.png
│ ├── fuck80.png
│ ├── fuck81.png
│ ├── fuck82.png
│ ├── fuck83.png
│ ├── fuck84.png
│ ├── fuck85.png
│ ├── fuck86.png
│ ├── fuck90.png
│ ├── fuck93.png
│ ├── fuck94.png
│ ├── fuck95.png
│ ├── fuck96.png
│ ├── fuck97.png
│ ├── fuck98.png
│ └── fuck99.png
├── file_ico.png
├── group_add_ico.png
├── group_delete_ico.png
├── img.jpg
├── left_voice_1.png
├── left_voice_2.png
├── left_voice_3.png
├── material_ico.png
├── photo_ico.png
├── pwd.png
├── search.png
├── transfer_ico.png
├── voice_left.png
├── voice_too_short_ico.png
├── voice_volume_1.png
├── voice_volume_2.png
├── voice_volume_3.png
├── voice_volume_4.png
├── voice_volume_5.png
├── voice_volume_6.png
└── voice_volume_7.png
├── ios
├── Flutter
│ ├── AppFrameworkInfo.plist
│ ├── Debug.xcconfig
│ └── Release.xcconfig
├── Podfile
├── Runner.xcodeproj
│ ├── project.pbxproj
│ ├── project.xcworkspace
│ │ └── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── xcschemes
│ │ └── Runner.xcscheme
├── Runner.xcworkspace
│ ├── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── IDEWorkspaceChecks.plist
└── 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
├── lib
├── NavigatorUtils.dart
├── animation
│ ├── mainAnimation.dart
│ ├── voice_animation_image.dart
│ ├── voice_view_screen.dart
│ └── wechat_voice_screen.dart
├── bloc
│ ├── BlocBase.dart
│ ├── blocdemo
│ │ ├── bloc
│ │ │ └── LoginBloc.dart
│ │ ├── model
│ │ │ └── UserInfo.dart
│ │ ├── presenter
│ │ │ └── LoginPresenter.dart
│ │ ├── provider
│ │ │ └── LoginApiProvider.dart
│ │ └── ui
│ │ │ └── LoginScreen.dart
│ ├── mainBloc.dart
│ └── mainStream.dart
├── business_ui
│ ├── async_screen.dart
│ └── value_notifier_screen.dart
├── chat
│ └── mainSysytem.dart
├── color.dart
├── customWidget
│ ├── CoustomHomePage.dart
│ ├── CustomCombinedWidget.dart
│ ├── CustomPainterPageState.dart
│ └── my_custom_painter.dart
├── demo
│ ├── BasicAppBarSample.dart
│ ├── MyIcons.dart
│ ├── SlideWidget.dart
│ ├── TimerDemo.dart
│ ├── chat_item_view.dart
│ ├── mainAudio.dart
│ ├── mainDatabse.dart
│ ├── mainDuration.dart
│ ├── mainLoginUi.dart
│ ├── mainMyIons.dart
│ ├── mainSPutil.dart
│ ├── mainSendMessageToChild.dart
│ ├── mainWarp.dart
│ ├── main_audioplayers.dart
│ └── mainvoice.dart
├── eventbus
│ ├── animation_event.dart
│ └── native_event.dart
├── generated
│ └── i18n.dart
├── image
│ ├── dragscale_screen.dart
│ └── image_pick_demo_screen.dart
├── main.dart
├── model
│ ├── chat_room_member.dart
│ ├── reply_model.dart
│ ├── screen_model.dart
│ └── user_info.dart
├── performance.analysis
│ ├── PerformanceAnalysis1Screen.dart
│ └── PerformanceAnalysis2Screen.dart
├── r.dart
├── stream
│ ├── stream_demo_screen.dart
│ └── stream_singleton.dart
├── template.dart
├── utils
│ ├── emoji_util.dart
│ ├── emoticon_widget.dart
│ ├── more_chat_widget.dart
│ ├── route_helper.dart
│ ├── toast.dart
│ └── utils.dart
├── widget
│ ├── custom_popup_window.dart
│ ├── loading
│ │ └── progress_dialog.dart
│ ├── net_loading_dalog.dart
│ ├── popup_window.dart
│ ├── progress_dialog.dart
│ └── search_widget.dart
└── widget_demo
│ ├── my_expansion_panel_list.dart
│ ├── ui
│ ├── FilePickerScreen.dart
│ ├── SplashPage.dart
│ ├── StickNestedScrollViewScreen.dart
│ ├── StickyDemo_screen.dart
│ ├── clip_board_screen.dart
│ ├── container_demo_screen.dart
│ ├── custom_slider_screen.dart
│ ├── custom_slider_screen2.dart
│ ├── dialog_demo_screen.dart
│ ├── emoji_screen.dart
│ ├── expandableListView_screen.dart
│ ├── expansion_panel_list_screen.dart
│ ├── expansion_title_demo_screen.dart
│ ├── grid_view_demo_screen.dart
│ ├── image_demo_screen.dart
│ ├── inheritedwidget_screen.dart
│ ├── listview_demo_screen.dart
│ ├── mergeable_material_item_screen.dart
│ ├── multl_list_widget
│ │ ├── EntryNew.dart
│ │ └── multi_list_widget.dart
│ ├── notification_screen.dart
│ ├── popup_page_screen.dart
│ ├── progress_dialog_demo_screen.dart
│ ├── radio_screen.dart
│ ├── refreshIndicator_demo_screen.dart
│ ├── slider_screen.dart
│ ├── stack_demo_screen.dart
│ ├── tab_bar_view_demo_screen.dart
│ ├── text_edit_demo_screen.dart
│ ├── view_pager_indicator_demo.dart
│ └── webview_demo_screen.dart
│ └── widget_demo_screen.dart
├── pubspec.lock
├── pubspec.yaml
├── res
└── values
│ └── strings_en.arb
└── test
└── widget_test.dart
/.gitignore:
--------------------------------------------------------------------------------
1 | # Miscellaneous
2 | *.class
3 | *.log
4 | *.pyc
5 | *.swp
6 | .DS_Store
7 | .atom/
8 | .buildlog/
9 | .history
10 | .svn/
11 |
12 | # IntelliJ related
13 | *.iml
14 | *.ipr
15 | *.iws
16 | .idea/
17 |
18 | # Visual Studio Code related
19 | .vscode/
20 |
21 | # Flutter/Dart/Pub related
22 | **/doc/api/
23 | .dart_tool/
24 | .flutter-plugins
25 | .packages
26 | .pub-cache/
27 | .pub/
28 | /build/
29 |
30 | # Android related
31 | **/android/**/gradle-wrapper.jar
32 | **/android/.gradle
33 | **/android/captures/
34 | **/android/gradlew
35 | **/android/gradlew.bat
36 | **/android/local.properties
37 | **/android/**/GeneratedPluginRegistrant.java
38 |
39 | # iOS/XCode related
40 | **/ios/**/*.mode1v3
41 | **/ios/**/*.mode2v3
42 | **/ios/**/*.moved-aside
43 | **/ios/**/*.pbxuser
44 | **/ios/**/*.perspectivev3
45 | **/ios/**/*sync/
46 | **/ios/**/.sconsign.dblite
47 | **/ios/**/.tags*
48 | **/ios/**/.vagrant/
49 | **/ios/**/DerivedData/
50 | **/ios/**/Icon?
51 | **/ios/**/Pods/
52 | **/ios/**/.symlinks/
53 | **/ios/**/profile
54 | **/ios/**/xcuserdata
55 | **/ios/.generated/
56 | **/ios/Flutter/App.framework
57 | **/ios/Flutter/Flutter.framework
58 | **/ios/Flutter/Generated.xcconfig
59 | **/ios/Flutter/app.flx
60 | **/ios/Flutter/app.zip
61 | **/ios/Flutter/flutter_assets/
62 | **/ios/ServiceDefinitions.json
63 | **/ios/Runner/GeneratedPluginRegistrant.*
64 |
65 | # Exceptions to above rules.
66 | !**/ios/**/default.mode1v3
67 | !**/ios/**/default.mode2v3
68 | !**/ios/**/default.pbxuser
69 | !**/ios/**/default.perspectivev3
70 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
71 |
--------------------------------------------------------------------------------
/.gradle/5.2.1/fileChanges/last-build.bin:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/.gradle/5.2.1/fileHashes/fileHashes.lock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/.gradle/5.2.1/fileHashes/fileHashes.lock
--------------------------------------------------------------------------------
/.gradle/5.2.1/gc.properties:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/.gradle/5.2.1/gc.properties
--------------------------------------------------------------------------------
/.gradle/buildOutputCleanup/buildOutputCleanup.lock:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/.gradle/buildOutputCleanup/buildOutputCleanup.lock
--------------------------------------------------------------------------------
/.gradle/buildOutputCleanup/cache.properties:
--------------------------------------------------------------------------------
1 | #Thu Apr 02 14:10:43 CST 2020
2 | gradle.version=5.2.1
3 |
--------------------------------------------------------------------------------
/.gradle/vcs-1/gc.properties:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/.gradle/vcs-1/gc.properties
--------------------------------------------------------------------------------
/.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: 8661d8aecd626f7f57ccbcb735553edc05a2e713
8 | channel: stable
9 |
10 | project_type: app
11 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | [TOC]
2 | ## 学习Flutter 相关的总结
3 |
4 |
5 | ## 已经实现的功能
6 |
7 |
8 | 1. 仿微信语音发送动画
9 | 2. GridView仿微信群详情界面
10 | 3. 仿微信语音播放动画
11 |
12 |
13 |
14 |
15 |
16 | ## 实现的Flutter插件
17 |
18 | 1. [Flutter录音插件](https://github.com/yxwandroid/flutter_plugin_record)
19 | 2. [Flutter友盟统计插件](https://github.com/yxwandroid/flutter_plugin_umpush)
20 | 3. [Flutter二维码扫描插件](https://github.com/yxwandroid/flutter_plugin_qrcode)
21 | 4. [Flutter视频播放插件(支持直播 各种格式视频播放)](https://github.com/yxwandroid/flutter_tencentplayer)
22 |
23 |
24 |
25 |
26 |
27 | ###### 关注公众号获取更多内容
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
--------------------------------------------------------------------------------
/README_images/gridview_demo.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/README_images/gridview_demo.gif
--------------------------------------------------------------------------------
/README_images/voice_play.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/README_images/voice_play.gif
--------------------------------------------------------------------------------
/README_images/voice_send.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/README_images/voice_send.gif
--------------------------------------------------------------------------------
/android/app/build.gradle:
--------------------------------------------------------------------------------
1 | def localProperties = new Properties()
2 | def localPropertiesFile = rootProject.file('local.properties')
3 | if (localPropertiesFile.exists()) {
4 | localPropertiesFile.withReader('UTF-8') { reader ->
5 | localProperties.load(reader)
6 | }
7 | }
8 |
9 | def flutterRoot = localProperties.getProperty('flutter.sdk')
10 | if (flutterRoot == null) {
11 | throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.")
12 | }
13 |
14 | def flutterVersionCode = localProperties.getProperty('flutter.versionCode')
15 | if (flutterVersionCode == null) {
16 | flutterVersionCode = '1'
17 | }
18 |
19 | def flutterVersionName = localProperties.getProperty('flutter.versionName')
20 | if (flutterVersionName == null) {
21 | flutterVersionName = '1.0'
22 | }
23 |
24 | apply plugin: 'com.android.application'
25 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
26 |
27 | android {
28 | compileSdkVersion 29
29 |
30 | lintOptions {
31 | disable 'InvalidPackage'
32 | }
33 |
34 | defaultConfig {
35 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
36 | applicationId "flutter.accs.com.flutter_app_demo"
37 | minSdkVersion 16
38 | targetSdkVersion 29
39 | versionCode flutterVersionCode.toInteger()
40 | versionName flutterVersionName
41 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
42 | }
43 |
44 | buildTypes {
45 | release {
46 | // TODO: Add your own signing config for the release build.
47 | // Signing with the debug keys for now, so `flutter run --release` works.
48 | signingConfig signingConfigs.debug
49 | }
50 | }
51 | }
52 |
53 | flutter {
54 | source '../..'
55 | }
56 |
57 | dependencies {
58 | testImplementation 'junit:junit:4.12'
59 | androidTestImplementation 'androidx.test.ext:junit:1.1.1'
60 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.0'
61 | }
62 |
63 |
64 | subprojects {
65 | project.configurations.all {
66 | resolutionStrategy.eachDependency { details ->
67 | if (details.requested.group == 'com.android.support'
68 | && !details.requested.name.contains('multidex') ) {
69 | details.useVersion "27.1.1"
70 | }
71 | }
72 | }
73 | }
--------------------------------------------------------------------------------
/android/app/src/debug/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
4 |
9 |
13 |
20 |
24 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
--------------------------------------------------------------------------------
/android/app/src/main/java/flutter/accs/com/flutter_app_demo/MainActivity.java:
--------------------------------------------------------------------------------
1 | package flutter.accs.com.flutter_app_demo;
2 |
3 | import android.os.Bundle;
4 | import io.flutter.app.FlutterActivity;
5 | import io.flutter.plugin.common.EventChannel;
6 | import io.flutter.plugins.GeneratedPluginRegistrant;
7 |
8 | public class MainActivity extends FlutterActivity {
9 | @Override
10 | protected void onCreate(Bundle savedInstanceState) {
11 | super.onCreate(savedInstanceState);
12 | GeneratedPluginRegistrant.registerWith(this);
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/android/app/src/main/res/drawable/launch_background.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
12 |
13 |
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
8 |
9 |
--------------------------------------------------------------------------------
/android/app/src/profile/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/android/build.gradle:
--------------------------------------------------------------------------------
1 | buildscript {
2 | repositories {
3 | google()
4 | jcenter()
5 | }
6 |
7 | dependencies {
8 | classpath 'com.android.tools.build:gradle:3.5.3'
9 | }
10 | }
11 |
12 | allprojects {
13 | repositories {
14 | google()
15 | jcenter()
16 | }
17 | }
18 |
19 | rootProject.buildDir = '../build'
20 | subprojects {
21 | project.buildDir = "${rootProject.buildDir}/${project.name}"
22 | }
23 | subprojects {
24 | project.evaluationDependsOn(':app')
25 | }
26 |
27 | task clean(type: Delete) {
28 | delete rootProject.buildDir
29 | }
30 |
--------------------------------------------------------------------------------
/android/gradle.properties:
--------------------------------------------------------------------------------
1 | org.gradle.jvmargs=-Xmx1536M
2 | android.enableR8=true
3 | android.useAndroidX=true
4 | android.enableJetifier=true
5 |
--------------------------------------------------------------------------------
/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | #Thu Dec 12 17:36:27 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 |
--------------------------------------------------------------------------------
/android/settings.gradle:
--------------------------------------------------------------------------------
1 | include ':app'
2 |
3 | def flutterProjectRoot = rootProject.projectDir.parentFile.toPath()
4 |
5 | def plugins = new Properties()
6 | def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins')
7 | if (pluginsFile.exists()) {
8 | pluginsFile.withReader('UTF-8') { reader -> plugins.load(reader) }
9 | }
10 |
11 | plugins.each { name, path ->
12 | def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile()
13 | include ":$name"
14 | project(":$name").projectDir = pluginDirectory
15 | }
16 |
--------------------------------------------------------------------------------
/images/WechatIMG1.jpeg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/WechatIMG1.jpeg
--------------------------------------------------------------------------------
/images/camera_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/camera_ico.png
--------------------------------------------------------------------------------
/images/cancel_voice.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/cancel_voice.png
--------------------------------------------------------------------------------
/images/chat_room_left_voice.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/chat_room_left_voice.png
--------------------------------------------------------------------------------
/images/delete.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/delete.png
--------------------------------------------------------------------------------
/images/emoji/collection.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/collection.png
--------------------------------------------------------------------------------
/images/emoji/defaultEmoji.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/defaultEmoji.png
--------------------------------------------------------------------------------
/images/emoji/fuck01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck01.png
--------------------------------------------------------------------------------
/images/emoji/fuck02.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck02.png
--------------------------------------------------------------------------------
/images/emoji/fuck03.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck03.png
--------------------------------------------------------------------------------
/images/emoji/fuck04.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck04.png
--------------------------------------------------------------------------------
/images/emoji/fuck05.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck05.png
--------------------------------------------------------------------------------
/images/emoji/fuck06.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck06.png
--------------------------------------------------------------------------------
/images/emoji/fuck07.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck07.png
--------------------------------------------------------------------------------
/images/emoji/fuck08.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck08.png
--------------------------------------------------------------------------------
/images/emoji/fuck09.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck09.png
--------------------------------------------------------------------------------
/images/emoji/fuck10.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck10.png
--------------------------------------------------------------------------------
/images/emoji/fuck100.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck100.png
--------------------------------------------------------------------------------
/images/emoji/fuck11.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck11.png
--------------------------------------------------------------------------------
/images/emoji/fuck12.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck12.png
--------------------------------------------------------------------------------
/images/emoji/fuck13.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck13.png
--------------------------------------------------------------------------------
/images/emoji/fuck14.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck14.png
--------------------------------------------------------------------------------
/images/emoji/fuck15.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck15.png
--------------------------------------------------------------------------------
/images/emoji/fuck16.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck16.png
--------------------------------------------------------------------------------
/images/emoji/fuck18.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck18.png
--------------------------------------------------------------------------------
/images/emoji/fuck19.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck19.png
--------------------------------------------------------------------------------
/images/emoji/fuck20.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck20.png
--------------------------------------------------------------------------------
/images/emoji/fuck21.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck21.png
--------------------------------------------------------------------------------
/images/emoji/fuck22.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck22.png
--------------------------------------------------------------------------------
/images/emoji/fuck23.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck23.png
--------------------------------------------------------------------------------
/images/emoji/fuck24.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck24.png
--------------------------------------------------------------------------------
/images/emoji/fuck26.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck26.png
--------------------------------------------------------------------------------
/images/emoji/fuck27.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck27.png
--------------------------------------------------------------------------------
/images/emoji/fuck28.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck28.png
--------------------------------------------------------------------------------
/images/emoji/fuck29.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck29.png
--------------------------------------------------------------------------------
/images/emoji/fuck30.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck30.png
--------------------------------------------------------------------------------
/images/emoji/fuck31.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck31.png
--------------------------------------------------------------------------------
/images/emoji/fuck32.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck32.png
--------------------------------------------------------------------------------
/images/emoji/fuck33.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck33.png
--------------------------------------------------------------------------------
/images/emoji/fuck34.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck34.png
--------------------------------------------------------------------------------
/images/emoji/fuck35.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck35.png
--------------------------------------------------------------------------------
/images/emoji/fuck37.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck37.png
--------------------------------------------------------------------------------
/images/emoji/fuck38.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck38.png
--------------------------------------------------------------------------------
/images/emoji/fuck39.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck39.png
--------------------------------------------------------------------------------
/images/emoji/fuck40.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck40.png
--------------------------------------------------------------------------------
/images/emoji/fuck41.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck41.png
--------------------------------------------------------------------------------
/images/emoji/fuck42.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck42.png
--------------------------------------------------------------------------------
/images/emoji/fuck43.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck43.png
--------------------------------------------------------------------------------
/images/emoji/fuck45.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck45.png
--------------------------------------------------------------------------------
/images/emoji/fuck46.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck46.png
--------------------------------------------------------------------------------
/images/emoji/fuck47.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck47.png
--------------------------------------------------------------------------------
/images/emoji/fuck48.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck48.png
--------------------------------------------------------------------------------
/images/emoji/fuck49.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck49.png
--------------------------------------------------------------------------------
/images/emoji/fuck50.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck50.png
--------------------------------------------------------------------------------
/images/emoji/fuck51.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck51.png
--------------------------------------------------------------------------------
/images/emoji/fuck52.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck52.png
--------------------------------------------------------------------------------
/images/emoji/fuck53.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck53.png
--------------------------------------------------------------------------------
/images/emoji/fuck55.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck55.png
--------------------------------------------------------------------------------
/images/emoji/fuck56.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck56.png
--------------------------------------------------------------------------------
/images/emoji/fuck57.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck57.png
--------------------------------------------------------------------------------
/images/emoji/fuck58.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck58.png
--------------------------------------------------------------------------------
/images/emoji/fuck61.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck61.png
--------------------------------------------------------------------------------
/images/emoji/fuck63.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck63.png
--------------------------------------------------------------------------------
/images/emoji/fuck64.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck64.png
--------------------------------------------------------------------------------
/images/emoji/fuck65.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck65.png
--------------------------------------------------------------------------------
/images/emoji/fuck66.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck66.png
--------------------------------------------------------------------------------
/images/emoji/fuck67.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck67.png
--------------------------------------------------------------------------------
/images/emoji/fuck68.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck68.png
--------------------------------------------------------------------------------
/images/emoji/fuck69.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck69.png
--------------------------------------------------------------------------------
/images/emoji/fuck71.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck71.png
--------------------------------------------------------------------------------
/images/emoji/fuck75.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck75.png
--------------------------------------------------------------------------------
/images/emoji/fuck76.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck76.png
--------------------------------------------------------------------------------
/images/emoji/fuck77.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck77.png
--------------------------------------------------------------------------------
/images/emoji/fuck79.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck79.png
--------------------------------------------------------------------------------
/images/emoji/fuck80.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck80.png
--------------------------------------------------------------------------------
/images/emoji/fuck81.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck81.png
--------------------------------------------------------------------------------
/images/emoji/fuck82.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck82.png
--------------------------------------------------------------------------------
/images/emoji/fuck83.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck83.png
--------------------------------------------------------------------------------
/images/emoji/fuck84.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck84.png
--------------------------------------------------------------------------------
/images/emoji/fuck85.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck85.png
--------------------------------------------------------------------------------
/images/emoji/fuck86.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck86.png
--------------------------------------------------------------------------------
/images/emoji/fuck90.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck90.png
--------------------------------------------------------------------------------
/images/emoji/fuck93.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck93.png
--------------------------------------------------------------------------------
/images/emoji/fuck94.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck94.png
--------------------------------------------------------------------------------
/images/emoji/fuck95.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck95.png
--------------------------------------------------------------------------------
/images/emoji/fuck96.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck96.png
--------------------------------------------------------------------------------
/images/emoji/fuck97.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck97.png
--------------------------------------------------------------------------------
/images/emoji/fuck98.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck98.png
--------------------------------------------------------------------------------
/images/emoji/fuck99.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/emoji/fuck99.png
--------------------------------------------------------------------------------
/images/file_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/file_ico.png
--------------------------------------------------------------------------------
/images/group_add_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/group_add_ico.png
--------------------------------------------------------------------------------
/images/group_delete_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/group_delete_ico.png
--------------------------------------------------------------------------------
/images/img.jpg:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/img.jpg
--------------------------------------------------------------------------------
/images/left_voice_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/left_voice_1.png
--------------------------------------------------------------------------------
/images/left_voice_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/left_voice_2.png
--------------------------------------------------------------------------------
/images/left_voice_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/left_voice_3.png
--------------------------------------------------------------------------------
/images/material_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/material_ico.png
--------------------------------------------------------------------------------
/images/photo_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/photo_ico.png
--------------------------------------------------------------------------------
/images/pwd.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/pwd.png
--------------------------------------------------------------------------------
/images/search.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/search.png
--------------------------------------------------------------------------------
/images/transfer_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/transfer_ico.png
--------------------------------------------------------------------------------
/images/voice_left.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_left.png
--------------------------------------------------------------------------------
/images/voice_too_short_ico.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_too_short_ico.png
--------------------------------------------------------------------------------
/images/voice_volume_1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_volume_1.png
--------------------------------------------------------------------------------
/images/voice_volume_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_volume_2.png
--------------------------------------------------------------------------------
/images/voice_volume_3.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_volume_3.png
--------------------------------------------------------------------------------
/images/voice_volume_4.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_volume_4.png
--------------------------------------------------------------------------------
/images/voice_volume_5.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_volume_5.png
--------------------------------------------------------------------------------
/images/voice_volume_6.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_volume_6.png
--------------------------------------------------------------------------------
/images/voice_volume_7.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/images/voice_volume_7.png
--------------------------------------------------------------------------------
/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 | 8.0
25 |
26 |
27 |
--------------------------------------------------------------------------------
/ios/Flutter/Debug.xcconfig:
--------------------------------------------------------------------------------
1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/ios/Flutter/Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"
2 | #include "Generated.xcconfig"
3 |
--------------------------------------------------------------------------------
/ios/Podfile:
--------------------------------------------------------------------------------
1 | # Uncomment this line to define a global platform for your project
2 | # platform :ios, '9.0'
3 | source 'https://github.com/CocoaPods/Specs.git'
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 parse_KV_file(file, separator='=')
14 | file_abs_path = File.expand_path(file)
15 | if !File.exists? file_abs_path
16 | return [];
17 | end
18 | generated_key_values = {}
19 | skip_line_start_symbols = ["#", "/"]
20 | File.foreach(file_abs_path) do |line|
21 | next if skip_line_start_symbols.any? { |symbol| line =~ /^\s*#{symbol}/ }
22 | plugin = line.split(pattern=separator)
23 | if plugin.length == 2
24 | podname = plugin[0].strip()
25 | path = plugin[1].strip()
26 | podpath = File.expand_path("#{path}", file_abs_path)
27 | generated_key_values[podname] = podpath
28 | else
29 | puts "Invalid plugin specification: #{line}"
30 | end
31 | end
32 | generated_key_values
33 | end
34 |
35 | target 'Runner' do
36 | use_frameworks!
37 | use_modular_headers!
38 |
39 | # Flutter Pod
40 |
41 | copied_flutter_dir = File.join(__dir__, 'Flutter')
42 | copied_framework_path = File.join(copied_flutter_dir, 'Flutter.framework')
43 | copied_podspec_path = File.join(copied_flutter_dir, 'Flutter.podspec')
44 | unless File.exist?(copied_framework_path) && File.exist?(copied_podspec_path)
45 | # Copy Flutter.framework and Flutter.podspec to Flutter/ to have something to link against if the xcode backend script has not run yet.
46 | # That script will copy the correct debug/profile/release version of the framework based on the currently selected Xcode configuration.
47 | # CocoaPods will not embed the framework on pod install (before any build phases can generate) if the dylib does not exist.
48 |
49 | generated_xcode_build_settings_path = File.join(copied_flutter_dir, 'Generated.xcconfig')
50 | unless File.exist?(generated_xcode_build_settings_path)
51 | raise "Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first"
52 | end
53 | generated_xcode_build_settings = parse_KV_file(generated_xcode_build_settings_path)
54 | cached_framework_dir = generated_xcode_build_settings['FLUTTER_FRAMEWORK_DIR'];
55 |
56 | unless File.exist?(copied_framework_path)
57 | FileUtils.cp_r(File.join(cached_framework_dir, 'Flutter.framework'), copied_flutter_dir)
58 | end
59 | unless File.exist?(copied_podspec_path)
60 | FileUtils.cp(File.join(cached_framework_dir, 'Flutter.podspec'), copied_flutter_dir)
61 | end
62 | end
63 |
64 | # Keep pod path relative so it can be checked into Podfile.lock.
65 | pod 'Flutter', :path => 'Flutter'
66 |
67 | # Plugin Pods
68 |
69 | # Prepare symlinks folder. We use symlinks to avoid having Podfile.lock
70 | # referring to absolute paths on developers' machines.
71 | system('rm -rf .symlinks')
72 | system('mkdir -p .symlinks/plugins')
73 | plugin_pods = parse_KV_file('../.flutter-plugins')
74 | plugin_pods.each do |name, path|
75 | symlink = File.join('.symlinks', 'plugins', name)
76 | File.symlink(path, symlink)
77 | pod name, :path => File.join(symlink, 'ios')
78 | end
79 | end
80 |
81 | # Prevent Cocoapods from embedding a second Flutter framework and causing an error with the new Xcode build system.
82 | install! 'cocoapods', :disable_input_output_paths => true
83 |
84 | post_install do |installer|
85 | installer.pods_project.targets.each do |target|
86 | target.build_configurations.each do |config|
87 | config.build_settings['ENABLE_BITCODE'] = 'NO'
88 | end
89 | end
90 | end
91 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/xcshareddata/xcschemes/Runner.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
24 |
25 |
31 |
32 |
33 |
34 |
40 |
41 |
42 |
43 |
44 |
45 |
56 |
58 |
64 |
65 |
66 |
67 |
68 |
69 |
75 |
77 |
83 |
84 |
85 |
86 |
88 |
89 |
92 |
93 |
94 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
9 |
10 |
11 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | IDEDidComputeMac32BitWarning
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/ios/Runner/AppDelegate.swift:
--------------------------------------------------------------------------------
1 | import UIKit
2 | import Flutter
3 |
4 | @UIApplicationMain
5 | @objc class AppDelegate: FlutterAppDelegate {
6 | override func application(
7 | _ application: UIApplication,
8 | didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?
9 | ) -> Bool {
10 | GeneratedPluginRegistrant.register(with: self)
11 | return super.application(application, didFinishLaunchingWithOptions: launchOptions)
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/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 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-1024x1024@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-20x20@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-29x29@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-40x40@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-60x60@3x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@1x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-76x76@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png
--------------------------------------------------------------------------------
/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 |
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/yxwandroid/Flutter-Study-Demo/1051f3ae861fdcc861d8185463d36a00fc3effc7/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png
--------------------------------------------------------------------------------
/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.
--------------------------------------------------------------------------------
/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 |
--------------------------------------------------------------------------------
/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 |
--------------------------------------------------------------------------------
/ios/Runner/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 | io.flutter.embedded_views_preview
7 | YES
8 | NSPhotoLibraryUsageDescription
9 | Example usage description
10 | NSCameraUsageDescription
11 | Example usage description
12 | NSCameraUsageDescription
13 | Camera permission is required for barcode scanning.
14 |
15 | NSAppTransportSecurity
16 |
17 | NSAllowsArbitraryLoads
18 |
19 |
20 | CFBundleDevelopmentRegion
21 | en
22 | CFBundleExecutable
23 | $(EXECUTABLE_NAME)
24 | CFBundleIdentifier
25 | $(PRODUCT_BUNDLE_IDENTIFIER)
26 | CFBundleInfoDictionaryVersion
27 | 6.0
28 | CFBundleName
29 | flutter_app_demo
30 | CFBundlePackageType
31 | APPL
32 | CFBundleShortVersionString
33 | $(FLUTTER_BUILD_NAME)
34 | CFBundleSignature
35 | ????
36 | CFBundleVersion
37 | $(FLUTTER_BUILD_NUMBER)
38 | LSRequiresIPhoneOS
39 |
40 | UILaunchStoryboardName
41 | LaunchScreen
42 | UIMainStoryboardFile
43 | Main
44 | UISupportedInterfaceOrientations
45 |
46 | UIInterfaceOrientationPortrait
47 | UIInterfaceOrientationLandscapeLeft
48 | UIInterfaceOrientationLandscapeRight
49 |
50 | UISupportedInterfaceOrientations~ipad
51 |
52 | UIInterfaceOrientationPortrait
53 | UIInterfaceOrientationPortraitUpsideDown
54 | UIInterfaceOrientationLandscapeLeft
55 | UIInterfaceOrientationLandscapeRight
56 |
57 | UIViewControllerBasedStatusBarAppearance
58 |
59 |
60 |
61 |
--------------------------------------------------------------------------------
/ios/Runner/Runner-Bridging-Header.h:
--------------------------------------------------------------------------------
1 | #import "GeneratedPluginRegistrant.h"
--------------------------------------------------------------------------------
/lib/NavigatorUtils.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/cupertino.dart';
2 |
3 | /// 路由的监听者
4 | class NavigatorUtils extends NavigatorObserver {
5 | static NavigatorUtils navigatorUtils;
6 | static NavigatorUtils getInstance() {
7 | if (navigatorUtils == null) {
8 | navigatorUtils = new NavigatorUtils();
9 | }
10 |
11 | return navigatorUtils;
12 | }
13 |
14 |
15 | @override
16 | void didPush(Route route, Route previousRoute) {
17 | print("didPush----"+route.settings.name);
18 | super.didPush(route, previousRoute);
19 | }
20 |
21 |
22 | @override
23 | void didRemove(Route route, Route previousRoute) {
24 | print("didRemove----"+route.settings.name);
25 | super.didRemove(route, previousRoute);
26 | }
27 | @override
28 | void didReplace({Route newRoute, Route oldRoute}) {
29 | print("didReplace----"+newRoute.settings.name);
30 | // super.didReplace(newRoute, oldRoute);
31 | }
32 | }
--------------------------------------------------------------------------------
/lib/animation/mainAnimation.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 |
4 |
5 | class MyFadeTest extends StatefulWidget {
6 | MyFadeTest({Key key}) : super(key: key);
7 |
8 | @override
9 | State createState() => new _MyFadeTest();
10 | }
11 |
12 | class _MyFadeTest extends State with TickerProviderStateMixin {
13 | AnimationController controller;//动画控制器
14 | CurvedAnimation curved;//曲线动画,动画插值,
15 | bool forward = true;
16 |
17 | @override
18 | void initState() {//初始化,当当前widget被插入到树中时调用
19 | super.initState();
20 | controller = new AnimationController(value: 2, duration: const Duration(seconds: 3));
21 | curved = new CurvedAnimation(parent: controller, curve: Curves.bounceOut);//模仿小球自由落体运动轨迹
22 | // controller.forward();//放在这里开启动画 ,打开页面就播放动画
23 | }
24 |
25 | @override
26 | Widget build(BuildContext context) {
27 | return new Scaffold(
28 | appBar: new AppBar(
29 | title: new Text('FadeTest'),
30 | ),
31 | body: new Center(
32 | child: new FadeTransition(//透明度动画
33 | opacity: curved,//将动画传入不同的动画widget
34 | child: new FlutterLogo(//创建一个小部件,用于绘制Flutter徽标
35 | size: 200.0,
36 | ),
37 | ),
38 | // child: new RotationTransition(//旋转动画
39 | // turns: curved,
40 | // child: new FlutterLogo(
41 | // size: 200.0,
42 | // ),
43 | //
44 | // ),
45 |
46 | ),
47 | floatingActionButton: new FloatingActionButton(
48 | onPressed: () {
49 | if (forward)
50 | controller.forward();//向前播放动画
51 | else
52 | controller.reverse();//向后播放动画
53 | forward = !forward;
54 | },
55 | tooltip: 'fade',
56 | child: new Icon(Icons.track_changes),
57 | ),
58 | );
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/lib/animation/voice_animation_image.dart:
--------------------------------------------------------------------------------
1 | // 帧动画Image
2 | import 'package:flutter/material.dart';
3 |
4 | class VoiceAnimationImage extends StatefulWidget {
5 | final List _assetList;
6 | final double width;
7 | final double height;
8 | int interval = 200;
9 | bool isStop= false;
10 | var callStart;
11 | VoiceAnimationImageState voiceAnimationImageState;
12 |
13 |
14 | VoiceAnimationImage(this._assetList,
15 | {this.width, this.height, this.isStop,this.interval});
16 |
17 | @override
18 | State createState() {
19 | voiceAnimationImageState = VoiceAnimationImageState();
20 | return voiceAnimationImageState;
21 | }
22 |
23 |
24 | start(){
25 | voiceAnimationImageState.start();
26 | }
27 |
28 | stop(){
29 | voiceAnimationImageState.stop();
30 | }
31 |
32 |
33 | }
34 |
35 | class VoiceAnimationImageState extends State
36 | with SingleTickerProviderStateMixin {
37 | // 动画控制
38 | Animation _animation;
39 | AnimationController _controller;
40 | int interval = 200;
41 |
42 | @override
43 | void initState() {
44 | super.initState();
45 |
46 | if (widget.interval != null) {
47 | interval = widget.interval;
48 | }
49 | final int imageCount = widget._assetList.length;
50 | final int maxTime = interval * imageCount;
51 |
52 |
53 | // 启动动画controller
54 | _controller = new AnimationController(duration: Duration(milliseconds: maxTime));
55 | _controller.addStatusListener((AnimationStatus status) {
56 | if (status == AnimationStatus.completed) {
57 | _controller.forward(from: 0.0); // 完成后重新开始
58 | }
59 | });
60 |
61 | _animation = new Tween(begin: 0, end: imageCount.toDouble())
62 | .animate(_controller)
63 | ..addListener(() {
64 | setState(() {
65 | });
66 | });
67 | }
68 |
69 | @override
70 | void dispose() {
71 | _controller.dispose();
72 | super.dispose();
73 | }
74 |
75 | stop() {
76 | _controller.stop();
77 | }
78 |
79 | start() {
80 | _controller.forward();
81 | }
82 |
83 | @override
84 | Widget build(BuildContext context) {
85 |
86 | if(widget.isStop){
87 | start();
88 | }else{
89 | stop();
90 | }
91 | int ix = _animation.value.floor() % widget._assetList.length;
92 | List images = [];
93 | // 把所有图片都加载进内容,否则每一帧加载时会卡顿
94 | for (int i = 0; i < widget._assetList.length; ++i) {
95 | if (i != ix) {
96 | images.add(Image.asset(
97 | widget._assetList[i],
98 | width: 0,
99 | height: 0,
100 | ));
101 | }
102 | }
103 | images.add(Image.asset(
104 | widget._assetList[ix],
105 | width: widget.width,
106 | height: widget.height,
107 | ));
108 | return Stack(alignment: AlignmentDirectional.center, children: images);
109 | }
110 | }
111 |
--------------------------------------------------------------------------------
/lib/animation/voice_view_screen.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 |
4 | /// 仿微信录制语音动画
5 | class VoiceViewScreen extends StatefulWidget {
6 | VoiceViewScreen({Key key}) : super(key: key);
7 |
8 |
9 | @override
10 | _VoiceViewScreenState createState() => _VoiceViewScreenState();
11 | }
12 |
13 | class _VoiceViewScreenState extends State {
14 | double start = 0.0;
15 | double offset = 0.0;
16 | bool isUp = false;
17 | String textShow = "按住说话";
18 | String toastShow = "手指上滑,取消发送";
19 | ///默认隐藏状态
20 | bool isVoiceState = true;
21 |
22 | @override
23 | void initState() {
24 | super.initState();
25 | }
26 |
27 | showVoiceView() {
28 | setState(() {
29 | textShow = "松开结束";
30 | isVoiceState = false;
31 | });
32 | }
33 |
34 | hideVoiceView() {
35 | setState(() {
36 | textShow = "按住说话";
37 | isVoiceState = true;
38 | });
39 |
40 | if(isUp){
41 | print("取消发送");
42 | }else{
43 | print("进行发送");
44 | }
45 | }
46 |
47 | moveVoiceView(){
48 | // print(offset - start);
49 | setState(() {
50 | isUp = start - offset > 100 ? true : false;
51 | if (isUp) {
52 | textShow = "松开手指,取消发送";
53 | toastShow = textShow;
54 | } else {
55 | textShow = "松开结束";
56 | toastShow = "手指上滑,取消发送";
57 | }
58 | });
59 | }
60 |
61 | @override
62 | Widget build(BuildContext context) {
63 | return Scaffold(
64 | appBar: AppBar(
65 | title: Text("仿微信录制语音动画"),
66 | ),
67 | body: Container(
68 | width: double.infinity,
69 | height: double.infinity,
70 | color: Colors.white,
71 | child: Column(
72 | children: [
73 | Expanded(
74 | child: Offstage(
75 | offstage: isVoiceState,
76 | child: Center(
77 | child: Opacity(
78 | opacity: 0.5,
79 | child: Container(
80 | width: 160,
81 | height: 160,
82 | decoration: BoxDecoration(
83 | color: Color(0xff77797A),
84 | borderRadius: BorderRadius.all(Radius.circular(20.0)),
85 | ),
86 | child: Column(
87 | children: [
88 | Container(
89 | margin: EdgeInsets.only(top: 10),
90 | child: new Image.asset(
91 | "images/voice_volume_7.png",
92 | width: 100,
93 | height: 100,
94 | ),
95 | ),
96 | Container(
97 | padding:
98 | EdgeInsets.only(right: 20, left: 20, top: 0),
99 | child: Text(
100 | toastShow,
101 | style: TextStyle(color: Colors.white),
102 | ),
103 | )
104 | ],
105 | ),
106 | ),
107 | ),
108 | ),
109 | ),
110 | ),
111 | GestureDetector(
112 | onVerticalDragStart: (details) {
113 | start = details.globalPosition.dy;
114 | showVoiceView();
115 | },
116 | onVerticalDragEnd: (details) {
117 | hideVoiceView();
118 | },
119 | onVerticalDragUpdate: (details) {
120 | offset = details.globalPosition.dy;
121 | moveVoiceView();
122 | },
123 | child: Container(
124 | height: 60,
125 | color: Colors.blue,
126 | margin: EdgeInsets.fromLTRB(50, 0, 50, 20),
127 | child: Center(
128 | child: Text(
129 | textShow,
130 | ),
131 | ),
132 | ),
133 | ),
134 | ],
135 | ),
136 | ),
137 | );
138 | }
139 | }
140 |
--------------------------------------------------------------------------------
/lib/animation/wechat_voice_screen.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import 'package:flutter_app_demo/animation/voice_animation_image.dart';
3 |
4 | ///类似微信语音播放动画
5 | class WeChatVoiceScreen extends StatefulWidget {
6 | WeChatVoiceScreen({Key key}) : super(key: key);
7 |
8 | @override
9 | _WeChatVoiceScreenState createState() => _WeChatVoiceScreenState();
10 | }
11 |
12 | class _WeChatVoiceScreenState extends State {
13 | List _assetList = new List();
14 | bool isStop = true;
15 |
16 | @override
17 | void initState() {
18 | super.initState();
19 |
20 | _assetList.add("images/left_voice_1.png");
21 | _assetList.add("images/left_voice_2.png");
22 | _assetList.add("images/left_voice_3.png");
23 | }
24 |
25 | @override
26 | Widget build(BuildContext context) {
27 | return Scaffold(
28 | appBar: AppBar(
29 | title: Text("微信语音播放动画"),
30 | ),
31 | body: Column(
32 | children: [
33 | VoiceAnimationImage(
34 | _assetList,
35 | width: 100,
36 | height: 100,
37 | isStop: isStop,
38 | ),
39 | FlatButton(
40 | child: new Text("开始动画"),
41 | onPressed: () {
42 | setState(() {
43 | isStop = true;
44 | });
45 | },
46 | ),
47 | FlatButton(
48 | child: new Text("停止动画"),
49 | onPressed: () {
50 | setState(() {
51 | isStop = false;
52 | });
53 | },
54 | ),
55 | ],
56 | ),
57 | );
58 | }
59 |
60 | callBackO(bool stop) {
61 | print(stop);
62 | }
63 | }
64 |
--------------------------------------------------------------------------------
/lib/bloc/BlocBase.dart:
--------------------------------------------------------------------------------
1 | // Generic Interface for all BLoCs
2 | import 'package:flutter/cupertino.dart';
3 |
4 | abstract class BlocBase {
5 | void dispose();
6 | }
7 |
8 | // Generic BLoC provider
9 | class BlocProvider extends StatefulWidget {
10 | BlocProvider({
11 | Key key,
12 | @required this.child,
13 | @required this.bloc,
14 | }): super(key: key);
15 |
16 | final T bloc;
17 | final Widget child;
18 |
19 | @override
20 | _BlocProviderState createState() => _BlocProviderState();
21 |
22 | static T of(BuildContext context){
23 | final type = _typeOf>();
24 | BlocProvider provider = context.ancestorWidgetOfExactType(type);
25 | return provider.bloc;
26 | }
27 |
28 | static Type _typeOf() => T;
29 | }
30 |
31 | class _BlocProviderState extends State>{
32 | @override
33 | void dispose(){
34 |
35 | widget.bloc.dispose();
36 |
37 | super.dispose();
38 | }
39 |
40 | @override
41 | Widget build(BuildContext context){
42 | return widget.child;
43 | }
44 | }
--------------------------------------------------------------------------------
/lib/bloc/blocdemo/bloc/LoginBloc.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter_app_demo/bloc/blocdemo/model/UserInfo.dart';
2 | import 'package:flutter_app_demo/bloc/blocdemo/presenter/LoginPresenter.dart';
3 | import 'package:rxdart/rxdart.dart';
4 | ///
5 | /// bloc控制模块
6 | ///
7 | class LoginBloc {
8 |
9 |
10 | final loginPresenter = LoginPresenter();
11 |
12 | final _loginFetcher = PublishSubject();
13 |
14 | Observable get getUserInfo=>_loginFetcher.stream;
15 |
16 |
17 | login() async{
18 | UserInfo userInfo = await loginPresenter.login();
19 | _loginFetcher.sink.add(userInfo);
20 |
21 | }
22 |
23 |
24 |
25 | dispose(){
26 | _loginFetcher.close();
27 | }
28 |
29 | }
30 |
31 |
32 | final loginBloc = LoginBloc();
33 |
--------------------------------------------------------------------------------
/lib/bloc/blocdemo/model/UserInfo.dart:
--------------------------------------------------------------------------------
1 | class UserInfo {
2 | String userName;
3 | String age;
4 |
5 | UserInfo(this.userName, this.age);
6 | }
7 |
--------------------------------------------------------------------------------
/lib/bloc/blocdemo/presenter/LoginPresenter.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter_app_demo/bloc/blocdemo/model/UserInfo.dart';
2 | import 'package:flutter_app_demo/bloc/blocdemo/provider/LoginApiProvider.dart';
3 |
4 | ///
5 | ///登录模块的控制类
6 | ///
7 | class LoginPresenter {
8 | final loginApiProvider = new LoginApiProvider();
9 |
10 | Future login() => loginApiProvider.login();
11 | }
12 |
--------------------------------------------------------------------------------
/lib/bloc/blocdemo/provider/LoginApiProvider.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter_app_demo/bloc/blocdemo/model/UserInfo.dart';
2 |
3 | ///
4 | /// 访问APi的接口类
5 | ///
6 | class LoginApiProvider {
7 |
8 |
9 |
10 | ///访问登录接口
11 | Future login() async {
12 | return UserInfo("wilson", "20");
13 | }
14 | }
15 |
--------------------------------------------------------------------------------
/lib/bloc/blocdemo/ui/LoginScreen.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import 'package:flutter_app_demo/bloc/blocdemo/bloc/LoginBloc.dart';
3 | import 'package:flutter_app_demo/bloc/blocdemo/model/UserInfo.dart';
4 |
5 | class LoginScreen extends StatefulWidget {
6 | LoginScreen({Key key}) : super(key: key);
7 |
8 | @override
9 | _LoginScreenState createState() {
10 | return _LoginScreenState();
11 | }
12 | }
13 |
14 | class _LoginScreenState extends State {
15 | @override
16 | void initState() {
17 | super.initState();
18 | loginBloc.login();
19 | }
20 |
21 | @override
22 | void dispose() {
23 | super.dispose();
24 | loginBloc.dispose();
25 | }
26 |
27 | @override
28 | Widget build(BuildContext context) {
29 | return Scaffold(
30 | appBar: AppBar(
31 | title: Text("login"),
32 | ),
33 | body: Container(
34 | child: FlatButton(
35 | onPressed: () {},
36 | child: StreamBuilder(
37 | stream: loginBloc.getUserInfo,
38 | builder: (context, AsyncSnapshot snapshot) {
39 | if (snapshot.hasData) {
40 | return Text(snapshot.data.userName);
41 | } else {
42 | return Text("获取数据");
43 | }
44 | },
45 | ),
46 | ),
47 | ),
48 | );
49 | }
50 | }
51 |
--------------------------------------------------------------------------------
/lib/bloc/mainBloc.dart:
--------------------------------------------------------------------------------
1 | import 'dart:async';
2 |
3 | import 'package:flutter/material.dart';
4 |
5 | import 'BlocBase.dart';
6 |
7 |
8 | void main() => runApp(new MyApp());
9 |
10 | class MyApp extends StatelessWidget {
11 | @override
12 | Widget build(BuildContext context) {
13 | return new MaterialApp(
14 | title: 'Streams Demo',
15 | theme: new ThemeData(
16 | primarySwatch: Colors.blue,
17 | ),
18 | home: BlocProvider(
19 | bloc: IncrementBloc(),
20 | child: CounterPage(),
21 | ),
22 | );
23 | }
24 | }
25 |
26 | class CounterPage extends StatelessWidget {
27 | @override
28 | Widget build(BuildContext context) {
29 | final IncrementBloc bloc = BlocProvider.of(context);
30 |
31 | return Scaffold(
32 | appBar: AppBar(title: Text('Stream version of the Counter App')),
33 | body: Center(
34 | child: StreamBuilder(
35 | stream: bloc.outCounter,
36 | initialData: 0,
37 | builder: (BuildContext context, AsyncSnapshot snapshot){
38 | return Text('You hit me: ${snapshot.data} times');
39 | }
40 | ),
41 | ),
42 | floatingActionButton: FloatingActionButton(
43 | child: const Icon(Icons.add),
44 | onPressed: (){
45 | bloc.incrementCounter.add(null);
46 | },
47 | ),
48 | );
49 | }
50 | }
51 |
52 | class IncrementBloc implements BlocBase {
53 | int _counter;
54 |
55 | //
56 | // Stream to handle the counter
57 | //
58 | StreamController _counterController = StreamController();
59 | StreamSink get _inAdd => _counterController.sink;
60 | Stream get outCounter => _counterController.stream;
61 |
62 | //
63 | // Stream to handle the action on the counter
64 | //
65 | StreamController _actionController = StreamController();
66 | StreamSink get incrementCounter => _actionController.sink;
67 |
68 | //
69 | // Constructor
70 | //
71 | IncrementBloc(){
72 | _counter = 0;
73 | _actionController.stream
74 | .listen(_handleLogic);
75 | }
76 |
77 | void dispose(){
78 | _actionController.close();
79 | _counterController.close();
80 | }
81 |
82 | void _handleLogic(data){
83 | _counter = _counter + 1;
84 | _inAdd.add(_counter);
85 | }
86 | }
87 |
--------------------------------------------------------------------------------
/lib/bloc/mainStream.dart:
--------------------------------------------------------------------------------
1 | import 'dart:async';
2 |
3 | import 'package:flutter/material.dart';
4 |
5 | void main() => runApp(MyApp());
6 |
7 | class MyApp extends StatelessWidget {
8 |
9 | @override
10 | Widget build(BuildContext context) {
11 | return MaterialApp(
12 | title: 'Flutter Demo',
13 | theme: ThemeData(
14 | primarySwatch: Colors.blue,
15 | ),
16 | home: CounterPage(),
17 | );
18 | }
19 |
20 | }
21 |
22 | class CounterPage extends StatefulWidget {
23 | @override
24 | _CounterPageState createState() => _CounterPageState();
25 | }
26 |
27 | class _CounterPageState extends State {
28 | int _counter = 0;
29 | final StreamController _streamController = StreamController();
30 |
31 | @override
32 | void dispose(){
33 | _streamController.close();
34 | super.dispose();
35 | }
36 |
37 | @override
38 | Widget build(BuildContext context) {
39 | return Scaffold(
40 | appBar: AppBar(title: Text('Stream version of the Counter App')),
41 | body: Center(
42 | child: StreamBuilder(
43 | stream: _streamController.stream,
44 | initialData: _counter,
45 | builder: (BuildContext context, AsyncSnapshot snapshot){
46 | return Text('You hit me: ${snapshot.data} times');
47 | }
48 | ),
49 | ),
50 | floatingActionButton: FloatingActionButton(
51 | child: const Icon(Icons.add),
52 | onPressed: (){
53 | _streamController.sink.add(++_counter);
54 | },
55 | ),
56 | );
57 | }
58 | }
--------------------------------------------------------------------------------
/lib/business_ui/async_screen.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 | //http://flutter.link/2018/04/12/Dart%E4%B8%AD%E7%9A%84%E5%BC%82%E6%AD%A5%E6%93%8D%E4%BD%9C/
4 | class AsyncScreen extends StatefulWidget {
5 | @override
6 | _AsyncScreenState createState() => _AsyncScreenState();
7 | }
8 |
9 | class _AsyncScreenState extends State {
10 | @override
11 | void initState() {
12 | super.initState();
13 | }
14 |
15 | String enterRestaurant() {
16 | return "和朋友进入了一家餐馆";
17 | }
18 |
19 | String waitForDinner() {
20 | return "我们的菜来了,我要开始吃饭了";
21 | }
22 |
23 | String startChat() {
24 | return "我们朋友聊起家常";
25 | }
26 |
27 | String playPhone() {
28 | return "等了好好久了,我还是玩会手机吧";
29 | }
30 |
31 | @override
32 | Widget build(BuildContext context) {
33 | //
34 | // print(enterRestaurant());
35 | // print(waitForDinner());
36 | // print(startChat());
37 | // print(playPhone());
38 |
39 | // print(enterRestaurant());
40 | // Future waitDinnerFuture = new Future(waitForDinner);
41 | // waitDinnerFuture.then((str) {
42 | // print(str);
43 | // });
44 | // print(startChat());
45 | // print(playPhone());
46 |
47 | return Scaffold(
48 | appBar: AppBar(
49 | title: Text("Flutter异步使用"),
50 | ),
51 | body: Container(
52 | child: Text("详细内容看代码"),
53 | ),
54 | floatingActionButton: FloatingActionButton(
55 | onPressed: () {},
56 | tooltip: 'Increment',
57 | child: Icon(Icons.add),
58 | ),
59 | );
60 | }
61 | }
62 |
--------------------------------------------------------------------------------
/lib/business_ui/value_notifier_screen.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | class ComplicatedObject {
3 | int number;
4 | String title;
5 |
6 | ComplicatedObject({this.number, this.title});
7 | }
8 | class ComplicatedObjectNotifier extends ValueNotifier {
9 |
10 | ComplicatedObjectNotifier(ComplicatedObject object): super(object);
11 |
12 | void setTitle(String newTitle) {
13 | value.title = newTitle;
14 | //这句是关键 一定要写。
15 | notifyListeners();
16 | }
17 |
18 | }
19 |
20 | ///参考
21 | ///http://www.muliba.net/flutter/2019/06/14/flutter%E6%95%B0%E6%8D%AE%E7%9B%91%E5%90%AC%E5%99%A8.html
22 | class ValueNotifierScreen extends StatefulWidget {
23 | @override
24 | _ValueNotifierScreenState createState() => _ValueNotifierScreenState();
25 | }
26 |
27 |
28 | class _ValueNotifierScreenState extends State {
29 | final ComplicatedObjectNotifier _notifier = ComplicatedObjectNotifier(ComplicatedObject(number: 0, title: '标题'));
30 | //中间不变的内容
31 | Widget _content;
32 |
33 | void _incrementCounter() {
34 | _notifier.setTitle('又是新标题');
35 | }
36 |
37 | @override
38 | void initState() {
39 | _content = Center(
40 | child: Text(
41 | '这里是内容。。。。。。。。。。。。。',
42 | ));
43 | super.initState();
44 | }
45 |
46 | @override
47 | Widget build(BuildContext context) {
48 | return Scaffold(
49 | appBar: AppBar(
50 | title: Text("value Notifier使用"),
51 | ),
52 | body: ValueListenableBuilder(
53 | valueListenable: _notifier,
54 | builder: (BuildContext context, ComplicatedObject value, Widget child) {
55 | return Column(
56 | children: [
57 | Container(
58 | height: 48,
59 | child: Text('${value.title}',
60 | style: Theme.of(context).textTheme.display1),
61 | ),
62 | Expanded(
63 | child: child,
64 | flex: 1,
65 | ),
66 | Container(
67 | height: 48,
68 | child: Text('${value.number}',
69 | style: Theme.of(context).textTheme.caption),
70 | ),
71 | ],
72 | );
73 | },
74 | child: _content,//这里是传入上面生成好的不变的Widget
75 | ),
76 |
77 | floatingActionButton: FloatingActionButton(
78 | onPressed: _incrementCounter,
79 | tooltip: 'Increment',
80 | child: Icon(Icons.add),
81 | ),
82 | );
83 | }
84 | }
--------------------------------------------------------------------------------
/lib/chat/mainSysytem.dart:
--------------------------------------------------------------------------------
1 | import 'dart:convert';
2 |
3 | import 'package:flutter/material.dart';
4 | import 'package:flutter_app_demo/utils/utils.dart';
5 |
6 |
7 |
8 | class MyChat extends StatefulWidget {
9 | MyChat({Key key, this.title}) : super(key: key);
10 |
11 | final String title;
12 |
13 | @override
14 | _MyChatState createState() => _MyChatState();
15 | }
16 |
17 | class _MyChatState extends State {
18 | static String avatar;
19 | @override
20 | void initState() {
21 | super.initState();
22 | avatar =
23 | "https://kefures.oss-cn-shenzhen.aliyuncs.com/avatar/8D2B68A578A8463381640F8E4CB62554/fb91beb7b653530bd00069aa4550af22.png";
24 | //
25 | // String jsonStr = "{\"durationMs\":3084,\"url\":\"https://kefures.oss-cn-shenzhen.aliyuncs.com/weremote/chat-logs/8D2B68A578A8463381640F8E4CB62554/34/msg_22100206041956194873fe7100.mp3\"}";
26 | // Map jsonObject = json.decode(jsonStr);
27 | // print(jsonObject["url"]);
28 |
29 | //
30 | // String content = "wxid_8mpz7k4zi1di12:\nhttps://kefures.oss-cn-shenzhen.aliyuncs.com/weremote/chat-logs/8D2B68A578A8463381640F8E4CB62554/34/msg_3915280604193004b7ef80b106.mp3";
31 | // String temp = content.replaceAll("\n", "");
32 | // List contents = temp.split(':');
33 | // String wechatId = contents[0];
34 | // String msg = contents[1]+":"+contents[2];
35 | // print(msg);
36 | }
37 |
38 | @override
39 | Widget build(BuildContext context) {
40 | return Scaffold(
41 | appBar: AppBar(
42 | title: Text(widget.title),
43 | ),
44 | body: buildChatLeftVoice(),
45 | );
46 | }
47 |
48 | static Widget buildMemberChange() {
49 | return Container(
50 | margin: const EdgeInsets.symmetric(horizontal: 8.0),
51 | child: Center(
52 | child: Container(
53 | width: 300,
54 | padding: EdgeInsets.fromLTRB(15, 5, 15, 5),
55 | decoration: BoxDecoration(
56 | color: Colors.yellow,
57 | borderRadius: BorderRadius.all(
58 | Radius.circular(5.0),
59 | ),
60 | ),
61 | child: new Text(
62 | "337373337373373733373733373733373337373337373373733373733373733373733373733373733373733373733373733373733373733373733337373337373337373337373733373733373733373733373733373733373733373733373733337373337373337373337373",
63 | textAlign: TextAlign.center,
64 | )),
65 | ),
66 | );
67 | }
68 |
69 | ///聊天左侧语音界面
70 | static Widget buildChatLeftVoice() {
71 | return Container(
72 | color: Colors.black,
73 | margin: const EdgeInsets.only(left: 5.0, right: 10.0),
74 | padding: const EdgeInsets.symmetric(vertical: 10.0),
75 | child: Row(
76 | crossAxisAlignment: CrossAxisAlignment.start, //对齐方式,左上对齐
77 | children: [
78 | CircleAvatar(
79 | backgroundImage: NetworkImage(avatar),
80 | radius: 20.0,
81 | ),
82 | Container(
83 | margin: const EdgeInsets.only(left: 5.0, right: 0, top: 0),
84 | child: Container(
85 | width: 80,
86 | height: 50,
87 | decoration: BoxDecoration(
88 | //设置背景
89 | color: Colors.yellow,
90 | borderRadius: BorderRadius.all(
91 | Radius.circular(5.0),
92 | ),
93 | ),
94 | child: Row(
95 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
96 | crossAxisAlignment: CrossAxisAlignment.center,
97 | //对齐方式,左上对齐
98 | children: [
99 | Container(
100 | color: Colors.black,
101 | margin: EdgeInsets.fromLTRB(5, 0, 0, 0),
102 | child: new Text("60\"")),
103 | Container(
104 | margin: EdgeInsets.fromLTRB(0, 0, 5, 0),
105 | child: new Image.asset(
106 | Utils.getImgPath("chat_room_left_voice"))),
107 | ],
108 | ),
109 | ),
110 | )
111 | ],
112 | ),
113 | );
114 | }
115 | }
116 |
--------------------------------------------------------------------------------
/lib/color.dart:
--------------------------------------------------------------------------------
1 | class AppColor {
2 |
3 | static final int groupTextColor = 0xff7F8389;
4 | }
--------------------------------------------------------------------------------
/lib/customWidget/CoustomHomePage.dart:
--------------------------------------------------------------------------------
1 | //首先导入自定义Widget所在文件
2 | import 'package:flutter/material.dart';
3 |
4 | import 'CustomCombinedWidget.dart';
5 |
6 | //在页面Widget中使用
7 |
8 |
9 | class CoustomHomePage extends StatefulWidget{
10 | @override
11 | _HomePageState createState() => new _HomePageState();
12 |
13 | }
14 |
15 | class _HomePageState extends State {
16 | String tips = '这里是提示';
17 |
18 | @override
19 | Widget build(BuildContext context) {
20 | // TODO: implement build
21 | return Scaffold(
22 | appBar: AppBar(
23 | title: Text('自定义组合Widget'),
24 | ),
25 | body: Container(
26 | child: buildCombinedWidget(),
27 | ),
28 | );
29 | }
30 |
31 | Widget buildCombinedWidget() {
32 | return Center(
33 | child: Column(
34 | children: [
35 | Row(
36 | mainAxisAlignment: MainAxisAlignment.spaceAround,
37 | children: [
38 | CustomCombinedWidget( //使用自定义Widget
39 | iconData: Icons.home,
40 | title: '首页',
41 | onTap: () {
42 | setState(() {
43 | this.tips = '点击了首页';
44 | });
45 | },
46 | ),
47 | CustomCombinedWidget(
48 | iconData: Icons.list,
49 | title: '产品',
50 | onTap: () {
51 | setState(() {
52 | this.tips = '点击了产品';
53 | });
54 | },
55 | ),
56 | CustomCombinedWidget(
57 | iconData: Icons.more_horiz,
58 | title: '更多',
59 | onTap: () {
60 | setState(() {
61 | this.tips = '点击了更多';
62 | });
63 | },
64 | ),
65 | ],
66 | ),
67 | Padding(
68 | padding: EdgeInsets.only(top: 50),
69 | child: Text(
70 | this.tips,
71 | style: TextStyle(fontSize: 20, color: Colors.blue),
72 | ),
73 | ),
74 | ],
75 | ),
76 | );
77 | }
78 | }
79 |
--------------------------------------------------------------------------------
/lib/customWidget/CustomCombinedWidget.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/cupertino.dart';
2 | import 'package:flutter/material.dart';
3 |
4 | class CustomCombinedWidget extends StatefulWidget {
5 |
6 | final IconData iconData;
7 | final String title;
8 | final GestureTapCallback onTap;
9 |
10 | const CustomCombinedWidget({Key key, this.iconData, this.title, this.onTap}): super(key: key);
11 |
12 | @override
13 | State createState() {
14 | // TODO: implement createState
15 | return CustomCombinedWidgetState();
16 | }
17 |
18 | }
19 |
20 | class CustomCombinedWidgetState extends State {
21 |
22 | @override
23 | Widget build(BuildContext context) {
24 | // TODO: implement build
25 | return GestureDetector(
26 | onTap: this.widget.onTap,
27 | child: Column(
28 | children: [
29 | Icon(this.widget.iconData, size: 45.0,),
30 | Text(this.widget.title == null ? "" : this.widget.title, style: TextStyle(fontSize: 14.0, color: Colors.black),),
31 | ],
32 | ),
33 | );
34 | }
35 |
36 | }
37 |
38 |
--------------------------------------------------------------------------------
/lib/customWidget/CustomPainterPageState.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 | import 'my_custom_painter.dart';
4 |
5 | class CustomPainterPage extends StatefulWidget {
6 | @override
7 | CustomPainterPageState createState() => new CustomPainterPageState();
8 | }
9 |
10 | class CustomPainterPageState extends State {
11 | List data = List();
12 |
13 | @override
14 | Widget build(BuildContext context) {
15 | // TODO: implement build
16 | return Scaffold(
17 | appBar: AppBar(
18 | title: Text('自定义绘制Widget'),
19 | ),
20 | body: Container(
21 | child: buildDemoPaintWidget(),
22 | ),
23 | );
24 | }
25 |
26 | Widget buildDemoPaintWidget() {
27 | return Column(
28 | crossAxisAlignment: CrossAxisAlignment.start,
29 | children: [
30 | Container(
31 | height: 350,
32 | child: buildPaintWidget(),
33 | ),
34 | Container(
35 | child: Row(
36 | mainAxisAlignment: MainAxisAlignment.spaceAround,
37 | children: [
38 | MaterialButton(
39 | onPressed: () {
40 | BaseData book1 = BaseData(name: '书籍A', num: 5000);
41 | BaseData book2 = BaseData(name: '书籍B', num: 2000);
42 | BaseData book3 = BaseData(name: '书籍C', num: 3000);
43 | List dataList = List();
44 | dataList.add(book1);
45 | dataList.add(book2);
46 | dataList.add(book3);
47 | setState(() {
48 | this.data = dataList;
49 | });
50 | },
51 | child: Text('三本书'),
52 | ),
53 | MaterialButton(
54 | onPressed: () {
55 | BaseData book4 = BaseData(name: '书籍D', num: 4500);
56 | setState(() {
57 | this.data.add(book4);
58 | });
59 | },
60 | child: Text('四本书'),
61 | ),
62 | MaterialButton(
63 | onPressed: () {
64 | BaseData book5 = BaseData(name: '书籍E', num: 2500);
65 | setState(() {
66 | this.data.add(book5);
67 | });
68 | },
69 | child: Text('五本书'),
70 | ),
71 | ],
72 | ),
73 | ),
74 | ],
75 | );
76 | }
77 |
78 | //构建自定义绘制的Widget
79 | Widget buildPaintWidget() {
80 | return CustomPaint(
81 | painter: MyCustomPainter(data),
82 | );
83 | }
84 | }
85 |
--------------------------------------------------------------------------------
/lib/customWidget/my_custom_painter.dart:
--------------------------------------------------------------------------------
1 | import 'dart:ui';
2 | import 'dart:ui' as ui show TextStyle;
3 |
4 | import 'package:flutter/material.dart';
5 |
6 | class BaseData {
7 | String name;
8 | int num;
9 |
10 | BaseData({this.name, this.num});
11 | }
12 |
13 | class MyCustomPainter extends CustomPainter {
14 | //绘制区域宽度
15 | final int width = 300;
16 |
17 | //绘制区域高度
18 | final int height = 350;
19 |
20 | //坐标原点
21 | final Offset origin = const Offset(50.0, 280.0);
22 |
23 | //纵坐标顶点
24 | final Offset vertexVer = const Offset(50.0, 20.0);
25 |
26 | //横坐标顶点
27 | final Offset vertexHor = const Offset(300.0, 280.0);
28 |
29 | //纵坐标刻度间隔
30 | final int scaleInterval = 1000;
31 |
32 | const MyCustomPainter(this.data);
33 |
34 | final List data;
35 |
36 | //根据文本内容和字体大小等构建一段文本
37 | Paragraph buildParagraph(String text, double textSize, double constWidth) {
38 | ParagraphBuilder builder = ParagraphBuilder(
39 | ParagraphStyle(
40 | textAlign: TextAlign.right,
41 | fontSize: textSize,
42 | fontWeight: FontWeight.normal,
43 | ),
44 | );
45 | builder.pushStyle(ui.TextStyle(color: Colors.black));
46 | builder.addText(text);
47 | ParagraphConstraints constraints = ParagraphConstraints(width: constWidth);
48 | return builder.build()..layout(constraints);
49 | }
50 |
51 | @override
52 | void paint(Canvas canvas, Size size) {
53 | // TODO: implement paint
54 | var paint = Paint()
55 | ..color = Colors.black
56 | ..strokeWidth = 2.0
57 | ..strokeCap = StrokeCap.square;
58 |
59 | //绘制纵坐标轴线
60 | canvas.drawLine(origin, vertexVer, paint);
61 | canvas.drawLine(
62 | vertexVer, Offset(vertexVer.dx - 5, vertexVer.dy + 10), paint);
63 | canvas.drawLine(
64 | vertexVer, Offset(vertexVer.dx + 5, vertexVer.dy + 10), paint);
65 | canvas.drawParagraph(
66 | buildParagraph('印刷量', 14, origin.dx - 5), Offset(0, vertexVer.dy - 8));
67 |
68 | //绘制横坐标轴线
69 | canvas.drawLine(origin, vertexHor, paint);
70 | canvas.drawLine(
71 | vertexHor, Offset(vertexHor.dx - 10, vertexHor.dy - 5), paint);
72 | canvas.drawLine(
73 | vertexHor, Offset(vertexHor.dx - 10, vertexHor.dy + 5), paint);
74 | canvas.drawParagraph(buildParagraph('书籍名', 14, origin.dx - 5),
75 | Offset(vertexHor.dx, origin.dy + 8));
76 |
77 | //绘制纵坐标刻度
78 | //实际最大值
79 | double realMaxY = origin.dy - vertexVer.dy - 20;
80 | //刻度间隔实际值
81 | double scaleInte = realMaxY / 5;
82 | for (int i = 0; i < 5; i++) {
83 | canvas.drawLine(Offset(origin.dx, origin.dy - (i + 1) * scaleInte),
84 | Offset(origin.dx + 5, origin.dy - (i + 1) * scaleInte), paint);
85 | canvas.drawParagraph(
86 | buildParagraph(
87 | ((i + 1) * scaleInterval).toString(), 12, origin.dx - 5),
88 | Offset(0, origin.dy - (i + 1) * scaleInte - 8.0));
89 | }
90 |
91 | if (data == null || data.length == 0) {
92 | return;
93 | }
94 | //计算纵坐标上的刻度
95 | int size = data.length;
96 | //柱状图间隔值
97 | double horiScalInte = (vertexHor.dx - origin.dx - 20) / size;
98 | //柱状图宽
99 | double chartWidth = 5;
100 | for (int i = 0; i < size; i++) {
101 | BaseData curData = data[i];
102 | double valueY = curData.num * scaleInte / scaleInterval;
103 | canvas.drawRect(
104 | Rect.fromLTWH(origin.dx + (i + 1) * horiScalInte, origin.dy - valueY,
105 | chartWidth, valueY),
106 | paint);
107 | canvas.drawParagraph(buildParagraph(curData.name, 12, origin.dx - 5),
108 | Offset(origin.dx + (i + 1) * horiScalInte - 25, origin.dy + 8));
109 | }
110 | }
111 |
112 | @override
113 | bool shouldRepaint(MyCustomPainter oldDelegate) {
114 | // TODO: implement shouldRepaint
115 | return oldDelegate.data != data;
116 | }
117 | }
118 |
--------------------------------------------------------------------------------
/lib/demo/BasicAppBarSample.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 |
3 | // This app is a stateful, it tracks the user's current choice.
4 | class BasicAppBarSample extends StatefulWidget {
5 | @override
6 | _BasicAppBarSampleState createState() => _BasicAppBarSampleState();
7 | }
8 |
9 | class _BasicAppBarSampleState extends State {
10 | Choice _selectedChoice = choices[0]; // The app's "state".
11 |
12 | void _select(Choice choice) {
13 | setState(() { // Causes the app to rebuild with the new _selectedChoice.
14 | _selectedChoice = choice;
15 | });
16 | }
17 |
18 | @override
19 | Widget build(BuildContext context) {
20 | return MaterialApp(
21 | home: Scaffold(
22 | appBar: AppBar(
23 | title: const Text('Basic AppBar'),
24 | actions: [
25 | IconButton( // action button
26 | icon: Icon(choices[0].icon),
27 | onPressed: () { _select(choices[0]); },
28 | ),
29 | IconButton( // action button
30 | icon: Icon(choices[1].icon),
31 | onPressed: () { _select(choices[1]); },
32 | ),
33 | PopupMenuButton( // overflow menu
34 | onSelected: _select,
35 | itemBuilder: (BuildContext context) {
36 | return choices.skip(2).map>((Choice choice) {
37 | return PopupMenuItem(
38 | value: choice,
39 | child: Text(choice.title),
40 | );
41 | }).toList();
42 | },
43 | ),
44 | ],
45 | ),
46 | body: Padding(
47 | padding: const EdgeInsets.all(16.0),
48 | child: ChoiceCard(choice: _selectedChoice),
49 | ),
50 | ),
51 | );
52 | }
53 | }
54 |
55 | class Choice {
56 | const Choice({ this.title, this.icon });
57 | final String title;
58 | final IconData icon;
59 | }
60 |
61 | const List choices = [
62 | Choice(title: 'Car', icon: Icons.directions_car),
63 | Choice(title: 'Bicycle', icon: Icons.directions_bike),
64 | Choice(title: 'Boat', icon: Icons.directions_boat),
65 | Choice(title: 'Bus', icon: Icons.directions_bus),
66 | Choice(title: 'Train', icon: Icons.directions_railway),
67 | Choice(title: 'Walk', icon: Icons.directions_walk),
68 | ];
69 |
70 | class ChoiceCard extends StatelessWidget {
71 | const ChoiceCard({ Key key, this.choice }) : super(key: key);
72 |
73 | final Choice choice;
74 |
75 | @override
76 | Widget build(BuildContext context) {
77 | final TextStyle textStyle = Theme.of(context).textTheme.display1;
78 | return Card(
79 | color: Colors.white,
80 | child: Center(
81 | child: Column(
82 | mainAxisSize: MainAxisSize.min,
83 | crossAxisAlignment: CrossAxisAlignment.center,
84 | children: [
85 | Icon(choice.icon, size: 128.0, color: textStyle.color),
86 | Text(choice.title, style: textStyle),
87 | ],
88 | ),
89 | ),
90 | );
91 | }
92 | }
93 |
--------------------------------------------------------------------------------
/lib/demo/MyIcons.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/widgets.dart';
2 |
3 | class MyIcons {
4 | //
5 |
6 |
7 | static const IconData addac = const IconData(0xe800, fontFamily:'myIcon', matchTextDirection: true);
8 |
9 | // book 图标
10 | static const IconData bowok = const IconData(0xe604, fontFamily: 'myIcon', matchTextDirection: true);
11 |
12 | // book 图标
13 | static const IconData book =
14 | const IconData(0xe614, fontFamily: 'myIcon', matchTextDirection: true);
15 |
16 | // 微信图标
17 | static const IconData wechat =
18 | const IconData(0xec7d, fontFamily: 'myIcon', matchTextDirection: true);
19 | }
20 |
--------------------------------------------------------------------------------
/lib/demo/TimerDemo.dart:
--------------------------------------------------------------------------------
1 | import 'dart:async';
2 |
3 | import 'package:flutter/material.dart';
4 |
5 | void main() => runApp(MyApp());
6 |
7 | class MyApp extends StatelessWidget {
8 | @override
9 | Widget build(BuildContext context) {
10 | return MaterialApp(
11 | title: 'Flutter Demo',
12 | theme: ThemeData(
13 | primarySwatch: Colors.blue,
14 | ),
15 | home: MyHomePage(title: 'Flutter Demo Home Page'),
16 | );
17 | }
18 | }
19 |
20 | class MyHomePage extends StatefulWidget {
21 | MyHomePage({Key key, this.title}) : super(key: key);
22 |
23 | final String title;
24 |
25 | @override
26 | _MyHomePageState createState() => _MyHomePageState();
27 | }
28 |
29 | class _MyHomePageState extends State {
30 | Timer mTimer ;
31 | @override
32 | void initState() {
33 |
34 | // 方法二
35 | Timer.periodic( Duration( milliseconds: 1000 ), ( timer ) {
36 | print('一秒钟后输出');
37 | // 每隔 1 秒钟会调用一次,如果要结束调用
38 | // timer.cancel();
39 |
40 | mTimer= timer;
41 | } );
42 | super.initState();
43 | }
44 | @override
45 | Widget build(BuildContext context) {
46 | return Scaffold(
47 | appBar: AppBar(
48 | title: Text(widget.title),
49 | ),
50 | body: Center(
51 | child: Column(
52 | mainAxisAlignment: MainAxisAlignment.center,
53 | children: [
54 | FlatButton(
55 | onPressed: (){
56 | mTimer.cancel();
57 | },
58 | child: Text("ee"),
59 | ),
60 | Text(
61 | 'You have pushed the button: en ',
62 | ),
63 | ],
64 | ),
65 | ),
66 | );
67 | }
68 |
69 |
70 | @override
71 | void dispose() {
72 | if(mTimer!=null){
73 | mTimer.cancel();
74 | }
75 | super.dispose();
76 | }
77 | }
78 |
--------------------------------------------------------------------------------
/lib/demo/mainAudio.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import 'package:audioplayer/audioplayer.dart';
3 | void main() => runApp(MyApp());
4 |
5 | class MyApp extends StatelessWidget {
6 | @override
7 | Widget build(BuildContext context) {
8 | return MaterialApp(
9 | title: 'Flutter Demo',
10 | theme: ThemeData(
11 | primarySwatch: Colors.blue,
12 | ),
13 | home: MyHomePage(title: 'Flutter Demo Home Page'),
14 | );
15 | }
16 | }
17 |
18 | class MyHomePage extends StatefulWidget {
19 | MyHomePage({Key key, this.title}) : super(key: key);
20 |
21 | final String title;
22 |
23 | @override
24 | _MyHomePageState createState() => _MyHomePageState();
25 | }
26 |
27 | //const kUrl = 'http://m10.music.126.net/20190606154312/8e4f4ae65f9a682002f482e5c5632a6c/ymusic/d60e/d53a/a031/1578f4093912b3c1f41a0bfd6c10115d.mp3';
28 | const kUrl = 'http://kefures.oss-cn-shenzhen.aliyuncs.com/weremote/chat-logs/8D2B68A578A8463381640F8E4CB62554/93/1aa5d13c-db47-49c9-808a-fe6b63dd7448/wav-20190619045224.wav';
29 |
30 | class _MyHomePageState extends State {
31 |
32 |
33 | bool isPlay = false;
34 | AudioPlayer audioPlayer;
35 | @override
36 | void initState() {
37 | // TODO: implement initState
38 | super.initState();
39 | audioPlayer = new AudioPlayer();
40 | }
41 |
42 | Future play() async {
43 | await audioPlayer.play(kUrl);
44 | isPlay = true;
45 | }
46 |
47 | Future stop() async {
48 | await audioPlayer.stop();
49 | isPlay = false;
50 |
51 | }
52 |
53 |
54 |
55 | @override
56 | Widget build(BuildContext context) {
57 | return Scaffold(
58 | appBar: AppBar(
59 | title: Text(widget.title),
60 | ),
61 | body: Center(
62 | child: Column(
63 | mainAxisAlignment: MainAxisAlignment.center,
64 | children: [
65 | RaisedButton(
66 | onPressed: (){
67 |
68 | if(isPlay){
69 | stop();
70 | }else{
71 | play();
72 | }
73 |
74 | },
75 | child: new Text("play"),
76 | ),
77 | ],
78 | ),
79 | ),
80 | );
81 | }
82 | }
83 |
--------------------------------------------------------------------------------
/lib/demo/mainDatabse.dart:
--------------------------------------------------------------------------------
1 | import 'package:collection/collection.dart';
2 | import 'package:flutter/material.dart';
3 | import 'package:path/path.dart';
4 | import 'package:sqflite/sqflite.dart';
5 | void main() => runApp(MyApp());
6 |
7 | class MyApp extends StatelessWidget {
8 | @override
9 | Widget build(BuildContext context) {
10 | return MaterialApp(
11 | title: 'Flutter Demo',
12 | theme: ThemeData(
13 | primarySwatch: Colors.blue,
14 | ),
15 | home: MyHomePage(title: 'Flutter Demo Home Page'),
16 | );
17 | }
18 | }
19 |
20 | class MyHomePage extends StatefulWidget {
21 | MyHomePage({Key key, this.title}) : super(key: key);
22 |
23 | final String title;
24 |
25 | @override
26 | _MyHomePageState createState() => _MyHomePageState();
27 | }
28 |
29 | class _MyHomePageState extends State {
30 |
31 |
32 |
33 |
34 |
35 | @override
36 | void initState() {
37 | super.initState();
38 | initDataBase();
39 |
40 |
41 | }
42 |
43 |
44 |
45 | initDataBase() async {
46 | // Get a location using getDatabasesPath
47 | var databasesPath = await getDatabasesPath();
48 | String path = join(databasesPath, 'demo.db');
49 |
50 |
51 | print(path);
52 | // open the database
53 | Database database = await openDatabase(path, version: 1,
54 | onCreate: (Database db, int version) async {
55 | // When creating the db, create the table
56 | await db.execute(
57 | 'CREATE TABLE Test (id INTEGER PRIMARY KEY, name TEXT, value INTEGER, num REAL)');
58 | });
59 |
60 |
61 | // Insert some records in a transaction
62 | await database.transaction((txn) async {
63 | int id1 = await txn.rawInsert(
64 | 'INSERT INTO Test(name, value, num) VALUES("some name", 1234, 456.789)');
65 | print('inserted1: $id1');
66 | int id2 = await txn.rawInsert(
67 | 'INSERT INTO Test(name, value, num) VALUES(?, ?, ?)',
68 | ['another name', 12345678, 3.1416]);
69 | print('inserted2: $id2');
70 | });
71 |
72 | // Update some record
73 | int count = await database.rawUpdate(
74 | 'UPDATE Test SET name = ?, VALUE = ? WHERE name = ?',
75 | ['updated name', '9876', 'some name']);
76 | print('updated: $count');
77 |
78 | // Get the records
79 | List