├── .gitignore
├── .metadata
├── README.md
├── android
├── .gitignore
├── app
│ ├── build.gradle
│ └── src
│ │ ├── debug
│ │ └── AndroidManifest.xml
│ │ ├── main
│ │ ├── AndroidManifest.xml
│ │ ├── kotlin
│ │ │ └── com
│ │ │ │ └── example
│ │ │ │ └── flutter_dialog
│ │ │ │ └── MainActivity.kt
│ │ └── 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
├── ios
├── .gitignore
├── Flutter
│ ├── AppFrameworkInfo.plist
│ ├── Debug.xcconfig
│ └── Release.xcconfig
├── Runner.xcodeproj
│ ├── project.pbxproj
│ ├── project.xcworkspace
│ │ └── contents.xcworkspacedata
│ └── xcshareddata
│ │ └── xcschemes
│ │ └── Runner.xcscheme
├── Runner.xcworkspace
│ └── contents.xcworkspacedata
└── Runner
│ ├── AppDelegate.h
│ ├── AppDelegate.m
│ ├── 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
│ └── main.m
├── lib
├── alert_dialog.dart
├── const.dart
├── cupertino_dialog.dart
├── func.dart
├── home.dart
├── main.dart
└── sheet_dialog.dart
├── pubspec.lock
├── pubspec.yaml
├── resource
├── Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 16.43.22.png
├── Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 16.45.54.png
├── Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 17.10.40.png
└── Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 17.12.54.png
└── 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 | # The .vscode folder contains launch configuration and tasks you configure in
19 | # VS Code which you may wish to be included in version control, so this line
20 | # is commented out by default.
21 | #.vscode/
22 |
23 | # Flutter/Dart/Pub related
24 | **/doc/api/
25 | .dart_tool/
26 | .flutter-plugins
27 | .flutter-plugins-dependencies
28 | .packages
29 | .pub-cache/
30 | .pub/
31 | /build/
32 |
33 | # Web related
34 | lib/generated_plugin_registrant.dart
35 |
36 | # Exceptions to above rules.
37 | !/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
38 |
--------------------------------------------------------------------------------
/.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: 0b8abb4724aa590dd0f429683339b1e045a1594d
8 | channel: stable
9 |
10 | project_type: app
11 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | 在flutter中弹窗从底部弹窗用showModalBottomSheet 从中间弹窗用showDialog,下面通过这两个弹窗自定义了一下常用样式
2 |
5 |
6 | ### 显示底部弹窗
7 | ```
8 | static void bottomSheetDialog(BuildContext context, Widget widget) {
9 | showModalBottomSheet(
10 | context: context,
11 | isScrollControlled: true,
12 | builder: (ctx) {
13 | return widget;
14 | },
15 | );
16 | }
17 | ```
18 | 如果isScrollControlled=false,弹窗部分最大高度只能我屏幕宽度的一半,如果为true,则没有这个限制
19 | 1、底部弹窗样式一:通用sheet样式弹窗,这种弹窗在苹果系统中是有的
20 | 具体代码
21 | ```
22 | import 'package:flutter/material.dart';
23 | import 'package:tudou_app/utils/const.dart';
24 | import 'package:tudou_app/utils/func.dart';
25 | import 'package:tudou_app/utils/scale.dart';
26 |
27 | class ShowSheetDialog extends StatefulWidget {
28 | //按钮title
29 | List items = [];
30 | //点击事件回调 0开始
31 | Function onTap;
32 | //标题 可选
33 | String title;
34 |
35 | ShowSheetDialog({
36 | @required this.items,
37 | this.onTap,
38 | this.title,
39 | });
40 |
41 | @override
42 | _ShowSheetDialogState createState() => _ShowSheetDialogState();
43 | }
44 |
45 | class _ShowSheetDialogState extends State {
46 | @override
47 | Widget build(BuildContext context) {
48 | return Container(
49 | color: ColorConst.Color_BG,
50 | child: Column(
51 | mainAxisSize: MainAxisSize.min,
52 | crossAxisAlignment: CrossAxisAlignment.center,
53 | children: [
54 | //有标题的情况下
55 | (widget.title != null && widget.title.length > 0)
56 | ? Container(
57 | alignment: Alignment.center,
58 | width: MediaQuery.of(context).size.width,
59 | height: 60,
60 | child: Text(
61 | widget.title,
62 | style: TextStyle(
63 | color: ColorConst.Color_Font_LightGray,
64 | fontSize: FONT_SCALE(14)),
65 | ),
66 | decoration: BoxDecoration(
67 | color: ColorConst.Color_Font_White,
68 | border: Border(
69 | bottom: BorderSide(
70 | color: ColorConst.Color_Split_Line, width: 1),
71 | ),
72 | ),
73 | )
74 | : Container(),
75 | Column(
76 | mainAxisSize: MainAxisSize.min,
77 | children: widget.items.map((title) {
78 | int index = widget.items.indexOf(title);
79 | return GestureDetector(
80 | onTap: () {
81 | FunctionUtil.pop(context);
82 | widget.onTap(index);
83 | },
84 | child: _itemCreat(title),
85 | );
86 | }).toList(),
87 | ),
88 | GestureDetector(
89 | child: Padding(
90 | padding: EdgeInsets.only(top: 10),
91 | child: _itemCreat('取消'),
92 | ),
93 | onTap: () {
94 | Navigator.pop(context);
95 | },
96 | )
97 | ],
98 | ),
99 | );
100 | }
101 |
102 | Widget _itemCreat(String title) {
103 | return Container(
104 | height: 50,
105 | width: MediaQuery.of(context).size.width,
106 | child: Center(
107 | child: Text(
108 | title,
109 | style: TextStyle(fontSize: 16, color: Colors.black),
110 | textAlign: TextAlign.center,
111 | ),
112 | ),
113 | decoration: BoxDecoration(
114 | color: Colors.white,
115 | border: Border(
116 | bottom: BorderSide(color: ColorConst.Color_Split_Line, width: 1)),
117 | ),
118 | );
119 | }
120 | }
121 |
122 | ```
123 | 2、底部弹窗样式二:Cupertino样式弹窗
124 |
125 | 具体代码
126 | ```
127 | import 'package:flutter/cupertino.dart';
128 | import 'package:flutter/material.dart';
129 |
130 | //用来显示底部弹出 可滚动视图的
131 | class ShowCupertinoDialog extends StatefulWidget {
132 | //内容
133 | List items;
134 | //选中回调 (int,String) 对应的下标和对应的值
135 | Function onTap;
136 |
137 | ShowCupertinoDialog({
138 | @required this.items,
139 | this.onTap,
140 | });
141 | @override
142 | _ShowCupertinoDialogState createState() => _ShowCupertinoDialogState();
143 | }
144 |
145 | class _ShowCupertinoDialogState extends State {
146 |
147 |
148 | @override
149 | Widget build(BuildContext context) {
150 | var selectIndex;
151 | return Container(
152 | height: 280,
153 | color: Colors.white,
154 | child: Column(
155 | children: [
156 | Row(
157 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
158 | children: [
159 | FlatButton(
160 | child: Text('取消'),
161 | onPressed: () {
162 | Navigator.pop(context);
163 | },
164 | ),
165 | FlatButton(
166 | child: Text('确定'),
167 | splashColor: Colors.grey,
168 | highlightColor: Colors.white,
169 | onPressed: () {
170 | Navigator.pop(context);
171 | if(selectIndex == null && widget.items.length > 0){
172 | selectIndex = 0;
173 | }
174 | if (widget.onTap != null) {
175 | widget.onTap(selectIndex, widget.items[selectIndex]);
176 | }
177 | },
178 | ),
179 | ],
180 | ),
181 | Expanded(
182 | child: CupertinoPicker(
183 | children: widget.items.map((item) {
184 | return Text(item);
185 | }).toList(),
186 | onSelectedItemChanged: (index) {
187 | print('$index');
188 | selectIndex = index;
189 | },
190 | itemExtent: 36,
191 | ),
192 | ),
193 | ],
194 | ),
195 | );
196 | }
197 | }
198 | ```
199 |
200 | ### 中间弹窗
201 | ```
202 | static void popDialog(BuildContext context, Widget widget) {
203 | showDialog(
204 | context: context,
205 | barrierDismissible: true,
206 | builder: (ctx) {
207 | return widget;
208 | });
209 | }
210 | ```
211 | 具体代码
212 | ```
213 | import 'package:flutter/material.dart';
214 | import 'package:tudou_app/utils/const.dart';
215 | import 'package:tudou_app/utils/func.dart';
216 | import 'package:tudou_app/utils/scale.dart';
217 |
218 | class ShowAlertDialog extends StatefulWidget {
219 | // 内容区域布局
220 | TextAlign contentAlign;
221 |
222 | String title;
223 |
224 | String content;
225 | // 点击返回index 0 1
226 | Function onTap;
227 | //按钮
228 | List items;
229 |
230 | ShowAlertDialog({
231 | this.contentAlign = TextAlign.left,
232 | this.onTap,
233 | @required this.items,
234 | this.content,
235 | this.title,
236 | });
237 |
238 | @override
239 | _ShowAlertDialogState createState() => _ShowAlertDialogState();
240 | }
241 |
242 | class _ShowAlertDialogState extends State {
243 | @override
244 | Widget build(BuildContext context) {
245 | return Material(
246 | color: ColorConst.Color_Clear,
247 | child: Center(
248 | // ClipRRect 创建圆角矩形 要不然发现下边button不是圆角
249 | child: ClipRRect(
250 | borderRadius: BorderRadius.circular(10.0),
251 | child: Container(
252 | color: ColorConst.Color_Font_White,
253 | width: SIZE_SCALE(260),
254 | child: Column(
255 | mainAxisSize: MainAxisSize.min,
256 | children: [
257 | SizedBox(height: 20),
258 | Text(
259 | widget.title,
260 | style: TextStyle(
261 | color: ColorConst.Color_Font_Black,
262 | fontWeight: FontWeight.bold,
263 | fontSize: FONT_SCALE(17)),
264 | ),
265 | SizedBox(height: 10),
266 | Container(
267 | margin: EdgeInsets.only(left: 15, right: 15),
268 | child: Text(
269 | widget.content,
270 | style: TextStyle(
271 | color: ColorConst.Color_Font_Black,
272 | fontSize: FONT_SCALE(14),
273 | ),
274 | ),
275 | ),
276 | SizedBox(height: 20),
277 | Container(
278 | decoration: BoxDecoration(
279 | border: Border(
280 | bottom: BorderSide(
281 | color: ColorConst.Color_Split_Line,
282 | width: 1,
283 | ),
284 | ),
285 | ),
286 | ),
287 | _itemCreat(),
288 | ],
289 | ),
290 | ),
291 | ),
292 | ),
293 | );
294 | }
295 |
296 | Widget _itemCreat() {
297 | return Container(
298 | child: Row(
299 | children: widget.items.map((res) {
300 | int index = widget.items.indexOf(res);
301 | return Expanded(
302 | flex: 1,
303 | child: GestureDetector(
304 | onTap: () {
305 | FunctionUtil.pop(context);
306 | widget.onTap(index);
307 | },
308 | child: Container(
309 | height: 44,
310 | alignment: Alignment.center,
311 | child: Text(
312 | res,
313 | style: TextStyle(
314 | color: ColorConst.Color_Font_Black,
315 | fontSize: FONT_SCALE(15)),
316 | ),
317 | decoration: BoxDecoration(
318 | border: Border(
319 | right: BorderSide(
320 | color: ColorConst.Color_Split_Line,
321 | width: 1,
322 | ),
323 | ),
324 | ),
325 | ),
326 | ),
327 | );
328 | }).toList(),
329 | ),
330 | );
331 | }
332 | }
333 |
334 | ```
335 | 这里提供的集中dialog都是项目中用到的,如果你的项目中有其他样式需求,可以自行修改源代码
336 |
337 | 转载请标注来源:https://www.cnblogs.com/qqcc1388/p/12487760.html
--------------------------------------------------------------------------------
/android/.gitignore:
--------------------------------------------------------------------------------
1 | gradle-wrapper.jar
2 | /.gradle
3 | /captures/
4 | /gradlew
5 | /gradlew.bat
6 | /local.properties
7 | GeneratedPluginRegistrant.java
8 |
--------------------------------------------------------------------------------
/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 plugin: 'kotlin-android'
26 | apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle"
27 |
28 | android {
29 | compileSdkVersion 28
30 |
31 | sourceSets {
32 | main.java.srcDirs += 'src/main/kotlin'
33 | }
34 |
35 | lintOptions {
36 | disable 'InvalidPackage'
37 | }
38 |
39 | defaultConfig {
40 | // TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
41 | applicationId "com.example.flutter_dialog"
42 | minSdkVersion 16
43 | targetSdkVersion 28
44 | versionCode flutterVersionCode.toInteger()
45 | versionName flutterVersionName
46 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
47 | }
48 |
49 | buildTypes {
50 | release {
51 | // TODO: Add your own signing config for the release build.
52 | // Signing with the debug keys for now, so `flutter run --release` works.
53 | signingConfig signingConfigs.debug
54 | }
55 | }
56 | }
57 |
58 | flutter {
59 | source '../..'
60 | }
61 |
62 | dependencies {
63 | implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version"
64 | testImplementation 'junit:junit:4.12'
65 | androidTestImplementation 'androidx.test:runner:1.1.1'
66 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.1.1'
67 | }
68 |
--------------------------------------------------------------------------------
/android/app/src/debug/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
8 |
12 |
19 |
20 |
21 |
22 |
23 |
24 |
26 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/android/app/src/main/kotlin/com/example/flutter_dialog/MainActivity.kt:
--------------------------------------------------------------------------------
1 | package com.example.flutter_dialog
2 |
3 | import androidx.annotation.NonNull;
4 | import io.flutter.embedding.android.FlutterActivity
5 | import io.flutter.embedding.engine.FlutterEngine
6 | import io.flutter.plugins.GeneratedPluginRegistrant
7 |
8 | class MainActivity: FlutterActivity() {
9 | override fun configureFlutterEngine(@NonNull flutterEngine: FlutterEngine) {
10 | GeneratedPluginRegistrant.registerWith(flutterEngine);
11 | }
12 | }
13 |
--------------------------------------------------------------------------------
/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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 | ext.kotlin_version = '1.3.50'
3 | repositories {
4 | google()
5 | jcenter()
6 | }
7 |
8 | dependencies {
9 | classpath 'com.android.tools.build:gradle:3.5.0'
10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
11 | }
12 | }
13 |
14 | allprojects {
15 | repositories {
16 | google()
17 | jcenter()
18 | }
19 | }
20 |
21 | rootProject.buildDir = '../build'
22 | subprojects {
23 | project.buildDir = "${rootProject.buildDir}/${project.name}"
24 | }
25 | subprojects {
26 | project.evaluationDependsOn(':app')
27 | }
28 |
29 | task clean(type: Delete) {
30 | delete rootProject.buildDir
31 | }
32 |
--------------------------------------------------------------------------------
/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 | #Fri Jun 23 08:50:38 CEST 2017
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.6.2-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 |
--------------------------------------------------------------------------------
/ios/.gitignore:
--------------------------------------------------------------------------------
1 | *.mode1v3
2 | *.mode2v3
3 | *.moved-aside
4 | *.pbxuser
5 | *.perspectivev3
6 | **/*sync/
7 | .sconsign.dblite
8 | .tags*
9 | **/.vagrant/
10 | **/DerivedData/
11 | Icon?
12 | **/Pods/
13 | **/.symlinks/
14 | profile
15 | xcuserdata
16 | **/.generated/
17 | Flutter/App.framework
18 | Flutter/Flutter.framework
19 | Flutter/Flutter.podspec
20 | Flutter/Generated.xcconfig
21 | Flutter/app.flx
22 | Flutter/app.zip
23 | Flutter/flutter_assets/
24 | Flutter/flutter_export_environment.sh
25 | ServiceDefinitions.json
26 | Runner/GeneratedPluginRegistrant.*
27 |
28 | # Exceptions to above rules.
29 | !default.mode1v3
30 | !default.mode2v3
31 | !default.pbxuser
32 | !default.perspectivev3
33 |
--------------------------------------------------------------------------------
/ios/Flutter/AppFrameworkInfo.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
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 "Generated.xcconfig"
2 |
--------------------------------------------------------------------------------
/ios/Flutter/Release.xcconfig:
--------------------------------------------------------------------------------
1 | #include "Generated.xcconfig"
2 |
--------------------------------------------------------------------------------
/ios/Runner.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */; };
11 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; };
12 | 3B80C3941E831B6300D905FE /* App.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; };
13 | 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 3B80C3931E831B6300D905FE /* App.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
14 | 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; };
15 | 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */ = {isa = PBXBuildFile; fileRef = 9740EEBA1CF902C7004384FC /* Flutter.framework */; settings = {ATTRIBUTES = (CodeSignOnCopy, RemoveHeadersOnCopy, ); }; };
16 | 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */; };
17 | 97C146F31CF9000F007C117D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 97C146F21CF9000F007C117D /* main.m */; };
18 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; };
19 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FD1CF9000F007C117D /* Assets.xcassets */; };
20 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; };
21 | /* End PBXBuildFile section */
22 |
23 | /* Begin PBXCopyFilesBuildPhase section */
24 | 9705A1C41CF9048500538489 /* Embed Frameworks */ = {
25 | isa = PBXCopyFilesBuildPhase;
26 | buildActionMask = 2147483647;
27 | dstPath = "";
28 | dstSubfolderSpec = 10;
29 | files = (
30 | 3B80C3951E831B6300D905FE /* App.framework in Embed Frameworks */,
31 | 9705A1C71CF904A300538489 /* Flutter.framework in Embed Frameworks */,
32 | );
33 | name = "Embed Frameworks";
34 | runOnlyForDeploymentPostprocessing = 0;
35 | };
36 | /* End PBXCopyFilesBuildPhase section */
37 |
38 | /* Begin PBXFileReference section */
39 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = ""; };
40 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = ""; };
41 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = ""; };
42 | 3B80C3931E831B6300D905FE /* App.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = App.framework; path = Flutter/App.framework; sourceTree = ""; };
43 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = ""; };
44 | 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; };
45 | 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; };
46 | 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = ""; };
47 | 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = ""; };
48 | 9740EEBA1CF902C7004384FC /* Flutter.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = Flutter.framework; path = Flutter/Flutter.framework; sourceTree = ""; };
49 | 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; };
50 | 97C146F21CF9000F007C117D /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; };
51 | 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
52 | 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
53 | 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
54 | 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
55 | /* End PBXFileReference section */
56 |
57 | /* Begin PBXFrameworksBuildPhase section */
58 | 97C146EB1CF9000F007C117D /* Frameworks */ = {
59 | isa = PBXFrameworksBuildPhase;
60 | buildActionMask = 2147483647;
61 | files = (
62 | 9705A1C61CF904A100538489 /* Flutter.framework in Frameworks */,
63 | 3B80C3941E831B6300D905FE /* App.framework in Frameworks */,
64 | );
65 | runOnlyForDeploymentPostprocessing = 0;
66 | };
67 | /* End PBXFrameworksBuildPhase section */
68 |
69 | /* Begin PBXGroup section */
70 | 9740EEB11CF90186004384FC /* Flutter */ = {
71 | isa = PBXGroup;
72 | children = (
73 | 3B80C3931E831B6300D905FE /* App.framework */,
74 | 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */,
75 | 9740EEBA1CF902C7004384FC /* Flutter.framework */,
76 | 9740EEB21CF90195004384FC /* Debug.xcconfig */,
77 | 7AFA3C8E1D35360C0083082E /* Release.xcconfig */,
78 | 9740EEB31CF90195004384FC /* Generated.xcconfig */,
79 | );
80 | name = Flutter;
81 | sourceTree = "";
82 | };
83 | 97C146E51CF9000F007C117D = {
84 | isa = PBXGroup;
85 | children = (
86 | 9740EEB11CF90186004384FC /* Flutter */,
87 | 97C146F01CF9000F007C117D /* Runner */,
88 | 97C146EF1CF9000F007C117D /* Products */,
89 | CF3B75C9A7D2FA2A4C99F110 /* Frameworks */,
90 | );
91 | sourceTree = "";
92 | };
93 | 97C146EF1CF9000F007C117D /* Products */ = {
94 | isa = PBXGroup;
95 | children = (
96 | 97C146EE1CF9000F007C117D /* Runner.app */,
97 | );
98 | name = Products;
99 | sourceTree = "";
100 | };
101 | 97C146F01CF9000F007C117D /* Runner */ = {
102 | isa = PBXGroup;
103 | children = (
104 | 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */,
105 | 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */,
106 | 97C146FA1CF9000F007C117D /* Main.storyboard */,
107 | 97C146FD1CF9000F007C117D /* Assets.xcassets */,
108 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */,
109 | 97C147021CF9000F007C117D /* Info.plist */,
110 | 97C146F11CF9000F007C117D /* Supporting Files */,
111 | 1498D2321E8E86230040F4C2 /* GeneratedPluginRegistrant.h */,
112 | 1498D2331E8E89220040F4C2 /* GeneratedPluginRegistrant.m */,
113 | );
114 | path = Runner;
115 | sourceTree = "";
116 | };
117 | 97C146F11CF9000F007C117D /* Supporting Files */ = {
118 | isa = PBXGroup;
119 | children = (
120 | 97C146F21CF9000F007C117D /* main.m */,
121 | );
122 | name = "Supporting Files";
123 | sourceTree = "";
124 | };
125 | /* End PBXGroup section */
126 |
127 | /* Begin PBXNativeTarget section */
128 | 97C146ED1CF9000F007C117D /* Runner */ = {
129 | isa = PBXNativeTarget;
130 | buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */;
131 | buildPhases = (
132 | 9740EEB61CF901F6004384FC /* Run Script */,
133 | 97C146EA1CF9000F007C117D /* Sources */,
134 | 97C146EB1CF9000F007C117D /* Frameworks */,
135 | 97C146EC1CF9000F007C117D /* Resources */,
136 | 9705A1C41CF9048500538489 /* Embed Frameworks */,
137 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */,
138 | );
139 | buildRules = (
140 | );
141 | dependencies = (
142 | );
143 | name = Runner;
144 | productName = Runner;
145 | productReference = 97C146EE1CF9000F007C117D /* Runner.app */;
146 | productType = "com.apple.product-type.application";
147 | };
148 | /* End PBXNativeTarget section */
149 |
150 | /* Begin PBXProject section */
151 | 97C146E61CF9000F007C117D /* Project object */ = {
152 | isa = PBXProject;
153 | attributes = {
154 | LastUpgradeCheck = 1020;
155 | ORGANIZATIONNAME = "The Chromium Authors";
156 | TargetAttributes = {
157 | 97C146ED1CF9000F007C117D = {
158 | CreatedOnToolsVersion = 7.3.1;
159 | };
160 | };
161 | };
162 | buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */;
163 | compatibilityVersion = "Xcode 3.2";
164 | developmentRegion = en;
165 | hasScannedForEncodings = 0;
166 | knownRegions = (
167 | en,
168 | Base,
169 | );
170 | mainGroup = 97C146E51CF9000F007C117D;
171 | productRefGroup = 97C146EF1CF9000F007C117D /* Products */;
172 | projectDirPath = "";
173 | projectRoot = "";
174 | targets = (
175 | 97C146ED1CF9000F007C117D /* Runner */,
176 | );
177 | };
178 | /* End PBXProject section */
179 |
180 | /* Begin PBXResourcesBuildPhase section */
181 | 97C146EC1CF9000F007C117D /* Resources */ = {
182 | isa = PBXResourcesBuildPhase;
183 | buildActionMask = 2147483647;
184 | files = (
185 | 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */,
186 | 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */,
187 | 97C146FE1CF9000F007C117D /* Assets.xcassets in Resources */,
188 | 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */,
189 | );
190 | runOnlyForDeploymentPostprocessing = 0;
191 | };
192 | /* End PBXResourcesBuildPhase section */
193 |
194 | /* Begin PBXShellScriptBuildPhase section */
195 | 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = {
196 | isa = PBXShellScriptBuildPhase;
197 | buildActionMask = 2147483647;
198 | files = (
199 | );
200 | inputPaths = (
201 | );
202 | name = "Thin Binary";
203 | outputPaths = (
204 | );
205 | runOnlyForDeploymentPostprocessing = 0;
206 | shellPath = /bin/sh;
207 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" thin";
208 | };
209 | 9740EEB61CF901F6004384FC /* Run Script */ = {
210 | isa = PBXShellScriptBuildPhase;
211 | buildActionMask = 2147483647;
212 | files = (
213 | );
214 | inputPaths = (
215 | );
216 | name = "Run Script";
217 | outputPaths = (
218 | );
219 | runOnlyForDeploymentPostprocessing = 0;
220 | shellPath = /bin/sh;
221 | shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build";
222 | };
223 | /* End PBXShellScriptBuildPhase section */
224 |
225 | /* Begin PBXSourcesBuildPhase section */
226 | 97C146EA1CF9000F007C117D /* Sources */ = {
227 | isa = PBXSourcesBuildPhase;
228 | buildActionMask = 2147483647;
229 | files = (
230 | 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */,
231 | 97C146F31CF9000F007C117D /* main.m in Sources */,
232 | 1498D2341E8E89220040F4C2 /* GeneratedPluginRegistrant.m in Sources */,
233 | );
234 | runOnlyForDeploymentPostprocessing = 0;
235 | };
236 | /* End PBXSourcesBuildPhase section */
237 |
238 | /* Begin PBXVariantGroup section */
239 | 97C146FA1CF9000F007C117D /* Main.storyboard */ = {
240 | isa = PBXVariantGroup;
241 | children = (
242 | 97C146FB1CF9000F007C117D /* Base */,
243 | );
244 | name = Main.storyboard;
245 | sourceTree = "";
246 | };
247 | 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = {
248 | isa = PBXVariantGroup;
249 | children = (
250 | 97C147001CF9000F007C117D /* Base */,
251 | );
252 | name = LaunchScreen.storyboard;
253 | sourceTree = "";
254 | };
255 | /* End PBXVariantGroup section */
256 |
257 | /* Begin XCBuildConfiguration section */
258 | 249021D3217E4FDB00AE95B9 /* Profile */ = {
259 | isa = XCBuildConfiguration;
260 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
261 | buildSettings = {
262 | ALWAYS_SEARCH_USER_PATHS = NO;
263 | CLANG_ANALYZER_NONNULL = YES;
264 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
265 | CLANG_CXX_LIBRARY = "libc++";
266 | CLANG_ENABLE_MODULES = YES;
267 | CLANG_ENABLE_OBJC_ARC = YES;
268 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
269 | CLANG_WARN_BOOL_CONVERSION = YES;
270 | CLANG_WARN_COMMA = YES;
271 | CLANG_WARN_CONSTANT_CONVERSION = YES;
272 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
273 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
274 | CLANG_WARN_EMPTY_BODY = YES;
275 | CLANG_WARN_ENUM_CONVERSION = YES;
276 | CLANG_WARN_INFINITE_RECURSION = YES;
277 | CLANG_WARN_INT_CONVERSION = YES;
278 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
279 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
280 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
281 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
282 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
283 | CLANG_WARN_STRICT_PROTOTYPES = YES;
284 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
285 | CLANG_WARN_UNREACHABLE_CODE = YES;
286 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
287 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
288 | COPY_PHASE_STRIP = NO;
289 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
290 | ENABLE_NS_ASSERTIONS = NO;
291 | ENABLE_STRICT_OBJC_MSGSEND = YES;
292 | GCC_C_LANGUAGE_STANDARD = gnu99;
293 | GCC_NO_COMMON_BLOCKS = YES;
294 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
295 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
296 | GCC_WARN_UNDECLARED_SELECTOR = YES;
297 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
298 | GCC_WARN_UNUSED_FUNCTION = YES;
299 | GCC_WARN_UNUSED_VARIABLE = YES;
300 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
301 | MTL_ENABLE_DEBUG_INFO = NO;
302 | SDKROOT = iphoneos;
303 | SUPPORTED_PLATFORMS = iphoneos;
304 | TARGETED_DEVICE_FAMILY = "1,2";
305 | VALIDATE_PRODUCT = YES;
306 | };
307 | name = Profile;
308 | };
309 | 249021D4217E4FDB00AE95B9 /* Profile */ = {
310 | isa = XCBuildConfiguration;
311 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
312 | buildSettings = {
313 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
314 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
315 | ENABLE_BITCODE = NO;
316 | FRAMEWORK_SEARCH_PATHS = (
317 | "$(inherited)",
318 | "$(PROJECT_DIR)/Flutter",
319 | );
320 | INFOPLIST_FILE = Runner/Info.plist;
321 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
322 | LIBRARY_SEARCH_PATHS = (
323 | "$(inherited)",
324 | "$(PROJECT_DIR)/Flutter",
325 | );
326 | PRODUCT_BUNDLE_IDENTIFIER = com.example.flutterDialog;
327 | PRODUCT_NAME = "$(TARGET_NAME)";
328 | VERSIONING_SYSTEM = "apple-generic";
329 | };
330 | name = Profile;
331 | };
332 | 97C147031CF9000F007C117D /* Debug */ = {
333 | isa = XCBuildConfiguration;
334 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
335 | buildSettings = {
336 | ALWAYS_SEARCH_USER_PATHS = NO;
337 | CLANG_ANALYZER_NONNULL = YES;
338 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
339 | CLANG_CXX_LIBRARY = "libc++";
340 | CLANG_ENABLE_MODULES = YES;
341 | CLANG_ENABLE_OBJC_ARC = YES;
342 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
343 | CLANG_WARN_BOOL_CONVERSION = YES;
344 | CLANG_WARN_COMMA = YES;
345 | CLANG_WARN_CONSTANT_CONVERSION = YES;
346 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
347 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
348 | CLANG_WARN_EMPTY_BODY = YES;
349 | CLANG_WARN_ENUM_CONVERSION = YES;
350 | CLANG_WARN_INFINITE_RECURSION = YES;
351 | CLANG_WARN_INT_CONVERSION = YES;
352 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
353 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
354 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
355 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
356 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
357 | CLANG_WARN_STRICT_PROTOTYPES = YES;
358 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
359 | CLANG_WARN_UNREACHABLE_CODE = YES;
360 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
361 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
362 | COPY_PHASE_STRIP = NO;
363 | DEBUG_INFORMATION_FORMAT = dwarf;
364 | ENABLE_STRICT_OBJC_MSGSEND = YES;
365 | ENABLE_TESTABILITY = YES;
366 | GCC_C_LANGUAGE_STANDARD = gnu99;
367 | GCC_DYNAMIC_NO_PIC = NO;
368 | GCC_NO_COMMON_BLOCKS = YES;
369 | GCC_OPTIMIZATION_LEVEL = 0;
370 | GCC_PREPROCESSOR_DEFINITIONS = (
371 | "DEBUG=1",
372 | "$(inherited)",
373 | );
374 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
375 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
376 | GCC_WARN_UNDECLARED_SELECTOR = YES;
377 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
378 | GCC_WARN_UNUSED_FUNCTION = YES;
379 | GCC_WARN_UNUSED_VARIABLE = YES;
380 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
381 | MTL_ENABLE_DEBUG_INFO = YES;
382 | ONLY_ACTIVE_ARCH = YES;
383 | SDKROOT = iphoneos;
384 | TARGETED_DEVICE_FAMILY = "1,2";
385 | };
386 | name = Debug;
387 | };
388 | 97C147041CF9000F007C117D /* Release */ = {
389 | isa = XCBuildConfiguration;
390 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
391 | buildSettings = {
392 | ALWAYS_SEARCH_USER_PATHS = NO;
393 | CLANG_ANALYZER_NONNULL = YES;
394 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
395 | CLANG_CXX_LIBRARY = "libc++";
396 | CLANG_ENABLE_MODULES = YES;
397 | CLANG_ENABLE_OBJC_ARC = YES;
398 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
399 | CLANG_WARN_BOOL_CONVERSION = YES;
400 | CLANG_WARN_COMMA = YES;
401 | CLANG_WARN_CONSTANT_CONVERSION = YES;
402 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
403 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
404 | CLANG_WARN_EMPTY_BODY = YES;
405 | CLANG_WARN_ENUM_CONVERSION = YES;
406 | CLANG_WARN_INFINITE_RECURSION = YES;
407 | CLANG_WARN_INT_CONVERSION = YES;
408 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
409 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
410 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
411 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
412 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
413 | CLANG_WARN_STRICT_PROTOTYPES = YES;
414 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
415 | CLANG_WARN_UNREACHABLE_CODE = YES;
416 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
417 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
418 | COPY_PHASE_STRIP = NO;
419 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
420 | ENABLE_NS_ASSERTIONS = NO;
421 | ENABLE_STRICT_OBJC_MSGSEND = YES;
422 | GCC_C_LANGUAGE_STANDARD = gnu99;
423 | GCC_NO_COMMON_BLOCKS = YES;
424 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
425 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
426 | GCC_WARN_UNDECLARED_SELECTOR = YES;
427 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
428 | GCC_WARN_UNUSED_FUNCTION = YES;
429 | GCC_WARN_UNUSED_VARIABLE = YES;
430 | IPHONEOS_DEPLOYMENT_TARGET = 8.0;
431 | MTL_ENABLE_DEBUG_INFO = NO;
432 | SDKROOT = iphoneos;
433 | SUPPORTED_PLATFORMS = iphoneos;
434 | TARGETED_DEVICE_FAMILY = "1,2";
435 | VALIDATE_PRODUCT = YES;
436 | };
437 | name = Release;
438 | };
439 | 97C147061CF9000F007C117D /* Debug */ = {
440 | isa = XCBuildConfiguration;
441 | baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */;
442 | buildSettings = {
443 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
444 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
445 | ENABLE_BITCODE = NO;
446 | FRAMEWORK_SEARCH_PATHS = (
447 | "$(inherited)",
448 | "$(PROJECT_DIR)/Flutter",
449 | );
450 | INFOPLIST_FILE = Runner/Info.plist;
451 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
452 | LIBRARY_SEARCH_PATHS = (
453 | "$(inherited)",
454 | "$(PROJECT_DIR)/Flutter",
455 | );
456 | PRODUCT_BUNDLE_IDENTIFIER = com.example.flutterDialog;
457 | PRODUCT_NAME = "$(TARGET_NAME)";
458 | VERSIONING_SYSTEM = "apple-generic";
459 | };
460 | name = Debug;
461 | };
462 | 97C147071CF9000F007C117D /* Release */ = {
463 | isa = XCBuildConfiguration;
464 | baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */;
465 | buildSettings = {
466 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
467 | CURRENT_PROJECT_VERSION = "$(FLUTTER_BUILD_NUMBER)";
468 | ENABLE_BITCODE = NO;
469 | FRAMEWORK_SEARCH_PATHS = (
470 | "$(inherited)",
471 | "$(PROJECT_DIR)/Flutter",
472 | );
473 | INFOPLIST_FILE = Runner/Info.plist;
474 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
475 | LIBRARY_SEARCH_PATHS = (
476 | "$(inherited)",
477 | "$(PROJECT_DIR)/Flutter",
478 | );
479 | PRODUCT_BUNDLE_IDENTIFIER = com.example.flutterDialog;
480 | PRODUCT_NAME = "$(TARGET_NAME)";
481 | VERSIONING_SYSTEM = "apple-generic";
482 | };
483 | name = Release;
484 | };
485 | /* End XCBuildConfiguration section */
486 |
487 | /* Begin XCConfigurationList section */
488 | 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = {
489 | isa = XCConfigurationList;
490 | buildConfigurations = (
491 | 97C147031CF9000F007C117D /* Debug */,
492 | 97C147041CF9000F007C117D /* Release */,
493 | 249021D3217E4FDB00AE95B9 /* Profile */,
494 | );
495 | defaultConfigurationIsVisible = 0;
496 | defaultConfigurationName = Release;
497 | };
498 | 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = {
499 | isa = XCConfigurationList;
500 | buildConfigurations = (
501 | 97C147061CF9000F007C117D /* Debug */,
502 | 97C147071CF9000F007C117D /* Release */,
503 | 249021D4217E4FDB00AE95B9 /* Profile */,
504 | );
505 | defaultConfigurationIsVisible = 0;
506 | defaultConfigurationName = Release;
507 | };
508 | /* End XCConfigurationList section */
509 | };
510 | rootObject = 97C146E61CF9000F007C117D /* Project object */;
511 | }
512 |
--------------------------------------------------------------------------------
/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 |
30 |
31 |
32 |
33 |
39 |
40 |
41 |
42 |
43 |
44 |
54 |
56 |
62 |
63 |
64 |
65 |
66 |
67 |
73 |
75 |
81 |
82 |
83 |
84 |
86 |
87 |
90 |
91 |
92 |
--------------------------------------------------------------------------------
/ios/Runner.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ios/Runner/AppDelegate.h:
--------------------------------------------------------------------------------
1 | #import
2 | #import
3 |
4 | @interface AppDelegate : FlutterAppDelegate
5 |
6 | @end
7 |
--------------------------------------------------------------------------------
/ios/Runner/AppDelegate.m:
--------------------------------------------------------------------------------
1 | #import "AppDelegate.h"
2 | #import "GeneratedPluginRegistrant.h"
3 |
4 | @implementation AppDelegate
5 |
6 | - (BOOL)application:(UIApplication *)application
7 | didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
8 | [GeneratedPluginRegistrant registerWithRegistry:self];
9 | // Override point for customization after application launch.
10 | return [super application:application didFinishLaunchingWithOptions:launchOptions];
11 | }
12 |
13 | @end
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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@2x.png
--------------------------------------------------------------------------------
/ios/Runner/Assets.xcassets/LaunchImage.imageset/LaunchImage@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/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 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | flutter_dialog
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | $(FLUTTER_BUILD_NAME)
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | $(FLUTTER_BUILD_NUMBER)
23 | LSRequiresIPhoneOS
24 |
25 | UILaunchStoryboardName
26 | LaunchScreen
27 | UIMainStoryboardFile
28 | Main
29 | UISupportedInterfaceOrientations
30 |
31 | UIInterfaceOrientationPortrait
32 | UIInterfaceOrientationLandscapeLeft
33 | UIInterfaceOrientationLandscapeRight
34 |
35 | UISupportedInterfaceOrientations~ipad
36 |
37 | UIInterfaceOrientationPortrait
38 | UIInterfaceOrientationPortraitUpsideDown
39 | UIInterfaceOrientationLandscapeLeft
40 | UIInterfaceOrientationLandscapeRight
41 |
42 | UIViewControllerBasedStatusBarAppearance
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/ios/Runner/main.m:
--------------------------------------------------------------------------------
1 | #import
2 | #import
3 | #import "AppDelegate.h"
4 |
5 | int main(int argc, char* argv[]) {
6 | @autoreleasepool {
7 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
8 | }
9 | }
10 |
--------------------------------------------------------------------------------
/lib/alert_dialog.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import 'func.dart';
3 | import 'const.dart';
4 |
5 | class ShowAlertDialog extends StatefulWidget {
6 | // 内容区域布局
7 | TextAlign contentAlign;
8 | // 标题
9 | String title;
10 | //内容
11 | String content;
12 | // 点击返回index 0 1
13 | Function onTap;
14 | //按钮
15 | List items;
16 |
17 | ShowAlertDialog({
18 | this.contentAlign = TextAlign.left,
19 | this.onTap,
20 | @required this.items,
21 | this.content,
22 | this.title,
23 | });
24 |
25 | @override
26 | _ShowAlertDialogState createState() => _ShowAlertDialogState();
27 | }
28 |
29 | class _ShowAlertDialogState extends State {
30 | @override
31 | Widget build(BuildContext context) {
32 | return Material(
33 | color: ColorConst.Color_Clear,
34 | child: Center(
35 | // ClipRRect 创建圆角矩形 要不然发现下边button不是圆角
36 | child: ClipRRect(
37 | borderRadius: BorderRadius.circular(10.0),
38 | child: Container(
39 | color: ColorConst.Color_Font_White,
40 | width: (260),
41 | child: Column(
42 | mainAxisSize: MainAxisSize.min,
43 | children: [
44 | SizedBox(height: 20),
45 | (widget.title == null || widget.title.length == 0) ? Container() : Container(
46 | child: Text(
47 | widget.title,
48 | style: TextStyle(
49 | color: ColorConst.Color_Font_Black,
50 | fontWeight: FontWeight.bold,
51 | fontSize: (17)),
52 | ),
53 | ),
54 | SizedBox(height: 10),
55 | Container(
56 | margin: EdgeInsets.only(left: 15, right: 15),
57 | child: Text(
58 | widget.content,
59 | style: TextStyle(
60 | color: ColorConst.Color_Font_Black,
61 | fontSize: (14),
62 | ),
63 | ),
64 | ),
65 | SizedBox(height: 20),
66 | Container(
67 | decoration: BoxDecoration(
68 | border: Border(
69 | bottom: BorderSide(
70 | color: ColorConst.Color_Split_Line,
71 | width: 1,
72 | ),
73 | ),
74 | ),
75 | ),
76 | _itemCreat(),
77 | ],
78 | ),
79 | ),
80 | ),
81 | ),
82 | );
83 | }
84 |
85 | Widget _itemCreat() {
86 | return Container(
87 | child: Row(
88 | children: widget.items.map((res) {
89 | int index = widget.items.indexOf(res);
90 | return Expanded(
91 | flex: 1,
92 | child: GestureDetector(
93 | onTap: () {
94 | FunctionUtil.pop(context);
95 | if(widget.onTap != null){
96 | widget.onTap(index);
97 | }
98 | },
99 | child: Container(
100 | height: 44,
101 | alignment: Alignment.center,
102 | child: Text(
103 | res,
104 | style: TextStyle(
105 | color: ColorConst.Color_Font_Black,
106 | fontSize: (15)),
107 | ),
108 | decoration: BoxDecoration(
109 | border: Border(
110 | right: BorderSide(
111 | color: ColorConst.Color_Split_Line,
112 | width: 1,
113 | ),
114 | ),
115 | ),
116 | ),
117 | ),
118 | );
119 | }).toList(),
120 | ),
121 | );
122 | }
123 | }
124 |
--------------------------------------------------------------------------------
/lib/const.dart:
--------------------------------------------------------------------------------
1 | import 'dart:math';
2 | import 'package:flutter/material.dart';
3 |
4 | class ColorConst{
5 | //颜色
6 | static const Color_Font_Black = Color(0xFF222222);
7 | static const Color_Font_Gray = Color(0xFF999999);
8 | static const Color_Font_LightGray = Color(0xFF666666);
9 | static const Color_Font_White = Color(0xFFFFFFFF);
10 | static const Color_Font_Purple = Color(0xFF4768F3);
11 | static const Color_Split_Line = Color(0xFFE7E8ED);
12 | static const Color_BG = Color(0xFFEDEDED);
13 | static const Color_Font_Orange = Color(0xFFFF6600);
14 | static const Color_Clear = Colors.transparent;
15 | static const Color_Font_Red = Color(0xFFCD513E);
16 |
17 | //随机颜色
18 | static Color colorRandom() {
19 | return Color.fromRGBO(Random.secure().nextInt(255),
20 | Random.secure().nextInt(255), Random.secure().nextInt(255), 1);
21 | }
22 | }
--------------------------------------------------------------------------------
/lib/cupertino_dialog.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/cupertino.dart';
2 | import 'package:flutter/material.dart';
3 |
4 | //用来显示底部弹出 可滚动视图的
5 | class ShowCupertinoDialog extends StatefulWidget {
6 | //内容
7 | List items;
8 | //选中回调 (int,String) 对应的下标和对应的值
9 | Function onTap;
10 |
11 | ShowCupertinoDialog({
12 | @required this.items,
13 | this.onTap,
14 | });
15 | @override
16 | _ShowCupertinoDialogState createState() => _ShowCupertinoDialogState();
17 | }
18 |
19 | class _ShowCupertinoDialogState extends State {
20 | @override
21 | Widget build(BuildContext context) {
22 | var selectIndex;
23 | return Container(
24 | height: 280,
25 | color: Colors.white,
26 | child: Column(
27 | children: [
28 | Row(
29 | mainAxisAlignment: MainAxisAlignment.spaceBetween,
30 | children: [
31 | FlatButton(
32 | child: Text('取消'),
33 | onPressed: () {
34 | Navigator.pop(context);
35 | },
36 | ),
37 | FlatButton(
38 | child: Text('确定'),
39 | splashColor: Colors.grey,
40 | highlightColor: Colors.white,
41 | onPressed: () {
42 | Navigator.pop(context);
43 | if (selectIndex == null && widget.items.length > 0) {
44 | selectIndex = 0;
45 | }
46 | if (widget.onTap != null) {
47 | widget.onTap(selectIndex, widget.items[selectIndex]);
48 | }
49 | },
50 | ),
51 | ],
52 | ),
53 | Expanded(
54 | child: CupertinoPicker(
55 | children: widget.items.map((item) {
56 | return Text(item);
57 | }).toList(),
58 | onSelectedItemChanged: (index) {
59 | selectIndex = index;
60 | },
61 | itemExtent: 36,
62 | ),
63 | ),
64 | ],
65 | ),
66 | );
67 | }
68 | }
69 |
--------------------------------------------------------------------------------
/lib/func.dart:
--------------------------------------------------------------------------------
1 |
2 | import 'package:flutter/material.dart';
3 |
4 | class FunctionUtil{
5 |
6 | //显示中间弹窗
7 | static void popDialog(BuildContext context, Widget widget) {
8 | showDialog(
9 | context: context,
10 | barrierDismissible: false,
11 | builder: (ctx) {
12 | return widget;
13 | });
14 | }
15 |
16 | //显示底部弹窗
17 | static void bottomSheetDialog(BuildContext context, Widget widget) {
18 | showModalBottomSheet(
19 | context: context,
20 | isScrollControlled: true,
21 | builder: (ctx) {
22 | return widget;
23 | },
24 | );
25 | }
26 |
27 | //返回上一级
28 | static void pop(BuildContext context) {
29 | Navigator.pop(context);
30 | }
31 |
32 | //push到下一级
33 | static Future push(BuildContext context, Widget widget) {
34 | return Navigator.push(
35 | context,
36 | MaterialPageRoute(
37 | builder: (context) => widget,
38 | ),
39 | );
40 | }
41 | }
--------------------------------------------------------------------------------
/lib/home.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import 'package:flutter_dialog/alert_dialog.dart';
3 | import 'package:flutter_dialog/const.dart';
4 | import 'package:flutter_dialog/cupertino_dialog.dart';
5 | import 'package:flutter_dialog/func.dart';
6 | import 'package:flutter_dialog/sheet_dialog.dart';
7 |
8 | class HomePage extends StatefulWidget {
9 | @override
10 | _HomePageState createState() => _HomePageState();
11 | }
12 |
13 | class _HomePageState extends State {
14 | @override
15 | Widget build(BuildContext context) {
16 | return Scaffold(
17 | appBar: AppBar(
18 | title: Text('自定义Dialog'),
19 | ),
20 | body: Center(
21 | child: Row(
22 | children: [
23 | Expanded(
24 | flex: 1,
25 | child: Container(
26 | color: ColorConst.Color_Font_Orange,
27 | child: FlatButton(
28 | onPressed: () {
29 | FunctionUtil.bottomSheetDialog(
30 | context,
31 | ShowSheetDialog(
32 | items: ['相册', '相机'],
33 | title: '请选择图片来源',
34 | onTap: (index) {
35 | print('object$index');
36 | },
37 | ),
38 | );
39 | },
40 | child: Text(
41 | 'actionSheet\npop',
42 | textAlign: TextAlign.center,
43 | ),
44 | ),
45 | ),
46 | ),
47 | Expanded(
48 | flex: 1,
49 | child: Container(
50 | color: ColorConst.Color_Font_Red,
51 | child: FlatButton(
52 | onPressed: () {
53 | FunctionUtil.bottomSheetDialog(
54 | context,
55 | ShowCupertinoDialog(
56 | items: ['北京', '上海', '天津', '深圳', '武汉', '广州', '杭州'],
57 | onTap: (int index, String res) {
58 | print('object$index + $res');
59 | },
60 | ),
61 | );
62 | },
63 | child: Text(
64 | 'cupertino\npop',
65 | textAlign: TextAlign.center,
66 | ),
67 | ),
68 | ),
69 | ),
70 | Expanded(
71 | flex: 1,
72 | child: Container(
73 | color: ColorConst.Color_Font_Gray,
74 | child: FlatButton(
75 | onPressed: () {
76 | FunctionUtil.popDialog(
77 | context,
78 | ShowAlertDialog(
79 | items: ['取消', '确认'],
80 | title: '提示',
81 | content: '确认要退出登录吗?',
82 | onTap: (index) {
83 | print('object$index');
84 | },
85 | ),
86 | );
87 | },
88 | child: Text(
89 | 'alert\npop',
90 | textAlign: TextAlign.center,
91 | ),
92 | ),
93 | ),
94 | ),
95 | ],
96 | ),
97 | ),
98 | );
99 | }
100 | }
101 |
--------------------------------------------------------------------------------
/lib/main.dart:
--------------------------------------------------------------------------------
1 |
2 | import 'package:flutter/material.dart';
3 | import 'package:flutter_dialog/home.dart';
4 |
5 | // void mian() => runApp(MyApp());
6 | void main() => runApp(MyApp());
7 |
8 | class MyApp extends StatefulWidget {
9 | @override
10 | _MyAppState createState() => _MyAppState();
11 | }
12 |
13 | class _MyAppState extends State {
14 | @override
15 | Widget build(BuildContext context) {
16 | return MaterialApp(
17 | title: '',
18 | home: HomePage(),
19 | );
20 | }
21 | }
22 |
23 | // class MyApp extends StatefulWidget {
24 | // @override
25 | // _MyAppState createState() => _MyAppState();
26 | // }
27 |
28 | // class _MyAppState extends State {
29 | // @override
30 | // Widget build(BuildContext context) {
31 | // return MaterialApp(
32 | // title: '',
33 | // home: HomePage(),
34 | // );
35 | // }
36 | // }
37 |
--------------------------------------------------------------------------------
/lib/sheet_dialog.dart:
--------------------------------------------------------------------------------
1 | import 'package:flutter/material.dart';
2 | import 'func.dart';
3 | import 'const.dart';
4 |
5 | class ShowSheetDialog extends StatefulWidget {
6 | //按钮title
7 | List items = [];
8 | //点击事件回调 0开始
9 | Function onTap;
10 | //标题 可选
11 | String title;
12 |
13 | ShowSheetDialog({
14 | @required this.items,
15 | this.onTap,
16 | this.title,
17 | });
18 |
19 | @override
20 | _ShowSheetDialogState createState() => _ShowSheetDialogState();
21 | }
22 |
23 | class _ShowSheetDialogState extends State {
24 | @override
25 | Widget build(BuildContext context) {
26 | return Container(
27 | color: ColorConst.Color_BG,
28 | child: Column(
29 | mainAxisSize: MainAxisSize.min,
30 | crossAxisAlignment: CrossAxisAlignment.center,
31 | children: [
32 | //有标题的情况下
33 | (widget.title != null && widget.title.length > 0)
34 | ? Container(
35 | alignment: Alignment.center,
36 | width: MediaQuery.of(context).size.width,
37 | height: 60,
38 | child: Text(
39 | widget.title,
40 | style: TextStyle(
41 | color: ColorConst.Color_Font_LightGray,
42 | fontSize: (14)),
43 | ),
44 | decoration: BoxDecoration(
45 | color: ColorConst.Color_Font_White,
46 | border: Border(
47 | bottom: BorderSide(
48 | color: ColorConst.Color_Split_Line, width: 1),
49 | ),
50 | ),
51 | )
52 | : Container(),
53 | Column(
54 | mainAxisSize: MainAxisSize.min,
55 | children: widget.items.map((title) {
56 | int index = widget.items.indexOf(title);
57 | return GestureDetector(
58 | onTap: () {
59 | Navigator.pop(context);
60 | if(widget.onTap != null){
61 | widget.onTap(index);
62 | }
63 | },
64 | child: _itemCreat(title),
65 | );
66 | }).toList(),
67 | ),
68 | GestureDetector(
69 | child: Padding(
70 | padding: EdgeInsets.only(top: 10),
71 | child: _itemCreat('取消'),
72 | ),
73 | onTap: () {
74 | Navigator.pop(context);
75 | },
76 | )
77 | ],
78 | ),
79 | );
80 | }
81 |
82 | Widget _itemCreat(String title) {
83 | return Container(
84 | height: 50,
85 | width: MediaQuery.of(context).size.width,
86 | child: Center(
87 | child: Text(
88 | title,
89 | style: TextStyle(fontSize: 16, color: Colors.black),
90 | textAlign: TextAlign.center,
91 | ),
92 | ),
93 | decoration: BoxDecoration(
94 | color: Colors.white,
95 | border: Border(
96 | bottom: BorderSide(color: ColorConst.Color_Split_Line, width: 1)),
97 | ),
98 | );
99 | }
100 | }
101 |
--------------------------------------------------------------------------------
/pubspec.lock:
--------------------------------------------------------------------------------
1 | # Generated by pub
2 | # See https://dart.dev/tools/pub/glossary#lockfile
3 | packages:
4 | archive:
5 | dependency: transitive
6 | description:
7 | name: archive
8 | url: "https://pub.flutter-io.cn"
9 | source: hosted
10 | version: "2.0.11"
11 | args:
12 | dependency: transitive
13 | description:
14 | name: args
15 | url: "https://pub.flutter-io.cn"
16 | source: hosted
17 | version: "1.5.2"
18 | async:
19 | dependency: transitive
20 | description:
21 | name: async
22 | url: "https://pub.flutter-io.cn"
23 | source: hosted
24 | version: "2.4.0"
25 | boolean_selector:
26 | dependency: transitive
27 | description:
28 | name: boolean_selector
29 | url: "https://pub.flutter-io.cn"
30 | source: hosted
31 | version: "1.0.5"
32 | charcode:
33 | dependency: transitive
34 | description:
35 | name: charcode
36 | url: "https://pub.flutter-io.cn"
37 | source: hosted
38 | version: "1.1.2"
39 | collection:
40 | dependency: transitive
41 | description:
42 | name: collection
43 | url: "https://pub.flutter-io.cn"
44 | source: hosted
45 | version: "1.14.11"
46 | convert:
47 | dependency: transitive
48 | description:
49 | name: convert
50 | url: "https://pub.flutter-io.cn"
51 | source: hosted
52 | version: "2.1.1"
53 | crypto:
54 | dependency: transitive
55 | description:
56 | name: crypto
57 | url: "https://pub.flutter-io.cn"
58 | source: hosted
59 | version: "2.1.3"
60 | cupertino_icons:
61 | dependency: "direct main"
62 | description:
63 | name: cupertino_icons
64 | url: "https://pub.flutter-io.cn"
65 | source: hosted
66 | version: "0.1.3"
67 | flutter:
68 | dependency: "direct main"
69 | description: flutter
70 | source: sdk
71 | version: "0.0.0"
72 | flutter_test:
73 | dependency: "direct dev"
74 | description: flutter
75 | source: sdk
76 | version: "0.0.0"
77 | image:
78 | dependency: transitive
79 | description:
80 | name: image
81 | url: "https://pub.flutter-io.cn"
82 | source: hosted
83 | version: "2.1.4"
84 | matcher:
85 | dependency: transitive
86 | description:
87 | name: matcher
88 | url: "https://pub.flutter-io.cn"
89 | source: hosted
90 | version: "0.12.6"
91 | meta:
92 | dependency: transitive
93 | description:
94 | name: meta
95 | url: "https://pub.flutter-io.cn"
96 | source: hosted
97 | version: "1.1.8"
98 | path:
99 | dependency: transitive
100 | description:
101 | name: path
102 | url: "https://pub.flutter-io.cn"
103 | source: hosted
104 | version: "1.6.4"
105 | pedantic:
106 | dependency: transitive
107 | description:
108 | name: pedantic
109 | url: "https://pub.flutter-io.cn"
110 | source: hosted
111 | version: "1.8.0+1"
112 | petitparser:
113 | dependency: transitive
114 | description:
115 | name: petitparser
116 | url: "https://pub.flutter-io.cn"
117 | source: hosted
118 | version: "2.4.0"
119 | quiver:
120 | dependency: transitive
121 | description:
122 | name: quiver
123 | url: "https://pub.flutter-io.cn"
124 | source: hosted
125 | version: "2.0.5"
126 | sky_engine:
127 | dependency: transitive
128 | description: flutter
129 | source: sdk
130 | version: "0.0.99"
131 | source_span:
132 | dependency: transitive
133 | description:
134 | name: source_span
135 | url: "https://pub.flutter-io.cn"
136 | source: hosted
137 | version: "1.5.5"
138 | stack_trace:
139 | dependency: transitive
140 | description:
141 | name: stack_trace
142 | url: "https://pub.flutter-io.cn"
143 | source: hosted
144 | version: "1.9.3"
145 | stream_channel:
146 | dependency: transitive
147 | description:
148 | name: stream_channel
149 | url: "https://pub.flutter-io.cn"
150 | source: hosted
151 | version: "2.0.0"
152 | string_scanner:
153 | dependency: transitive
154 | description:
155 | name: string_scanner
156 | url: "https://pub.flutter-io.cn"
157 | source: hosted
158 | version: "1.0.5"
159 | term_glyph:
160 | dependency: transitive
161 | description:
162 | name: term_glyph
163 | url: "https://pub.flutter-io.cn"
164 | source: hosted
165 | version: "1.1.0"
166 | test_api:
167 | dependency: transitive
168 | description:
169 | name: test_api
170 | url: "https://pub.flutter-io.cn"
171 | source: hosted
172 | version: "0.2.11"
173 | typed_data:
174 | dependency: transitive
175 | description:
176 | name: typed_data
177 | url: "https://pub.flutter-io.cn"
178 | source: hosted
179 | version: "1.1.6"
180 | vector_math:
181 | dependency: transitive
182 | description:
183 | name: vector_math
184 | url: "https://pub.flutter-io.cn"
185 | source: hosted
186 | version: "2.0.8"
187 | xml:
188 | dependency: transitive
189 | description:
190 | name: xml
191 | url: "https://pub.flutter-io.cn"
192 | source: hosted
193 | version: "3.5.0"
194 | sdks:
195 | dart: ">=2.4.0 <3.0.0"
196 |
--------------------------------------------------------------------------------
/pubspec.yaml:
--------------------------------------------------------------------------------
1 | name: flutter_dialog
2 | description: A new Flutter project.
3 |
4 | # The following defines the version and build number for your application.
5 | # A version number is three numbers separated by dots, like 1.2.43
6 | # followed by an optional build number separated by a +.
7 | # Both the version and the builder number may be overridden in flutter
8 | # build by specifying --build-name and --build-number, respectively.
9 | # In Android, build-name is used as versionName while build-number used as versionCode.
10 | # Read more about Android versioning at https://developer.android.com/studio/publish/versioning
11 | # In iOS, build-name is used as CFBundleShortVersionString while build-number used as CFBundleVersion.
12 | # Read more about iOS versioning at
13 | # https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
14 | version: 1.0.0+1
15 |
16 | environment:
17 | sdk: ">=2.1.0 <3.0.0"
18 |
19 | dependencies:
20 | flutter:
21 | sdk: flutter
22 |
23 | # The following adds the Cupertino Icons font to your application.
24 | # Use with the CupertinoIcons class for iOS style icons.
25 | cupertino_icons: ^0.1.2
26 |
27 | dev_dependencies:
28 | flutter_test:
29 | sdk: flutter
30 |
31 |
32 | # For information on the generic Dart part of this file, see the
33 | # following page: https://dart.dev/tools/pub/pubspec
34 |
35 | # The following section is specific to Flutter.
36 | flutter:
37 |
38 | # The following line ensures that the Material Icons font is
39 | # included with your application, so that you can use the icons in
40 | # the material Icons class.
41 | uses-material-design: true
42 |
43 | # To add assets to your application, add an assets section, like this:
44 | # assets:
45 | # - images/a_dot_burr.jpeg
46 | # - images/a_dot_ham.jpeg
47 |
48 | # An image asset can refer to one or more resolution-specific "variants", see
49 | # https://flutter.dev/assets-and-images/#resolution-aware.
50 |
51 | # For details regarding adding assets from package dependencies, see
52 | # https://flutter.dev/assets-and-images/#from-packages
53 |
54 | # To add custom fonts to your application, add a fonts section here,
55 | # in this "flutter" section. Each entry in this list should have a
56 | # "family" key with the font family name, and a "fonts" key with a
57 | # list giving the asset and other descriptors for the font. For
58 | # example:
59 | # fonts:
60 | # - family: Schyler
61 | # fonts:
62 | # - asset: fonts/Schyler-Regular.ttf
63 | # - asset: fonts/Schyler-Italic.ttf
64 | # style: italic
65 | # - family: Trajan Pro
66 | # fonts:
67 | # - asset: fonts/TrajanPro.ttf
68 | # - asset: fonts/TrajanPro_Bold.ttf
69 | # weight: 700
70 | #
71 | # For details regarding fonts from package dependencies,
72 | # see https://flutter.dev/custom-fonts/#from-packages
73 |
--------------------------------------------------------------------------------
/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 16.43.22.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 16.43.22.png
--------------------------------------------------------------------------------
/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 16.45.54.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 16.45.54.png
--------------------------------------------------------------------------------
/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 17.10.40.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 17.10.40.png
--------------------------------------------------------------------------------
/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 17.12.54.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/qqcc1388/flutter_dialog/3babc5572b07da351e63341004c1b702a5d55abb/resource/Simulator Screen Shot - iPhone 11 Pro Max - 2020-03-13 at 17.12.54.png
--------------------------------------------------------------------------------
/test/widget_test.dart:
--------------------------------------------------------------------------------
1 | // This is a basic Flutter widget test.
2 | //
3 | // To perform an interaction with a widget in your test, use the WidgetTester
4 | // utility that Flutter provides. For example, you can send tap and scroll
5 | // gestures. You can also use WidgetTester to find child widgets in the widget
6 | // tree, read text, and verify that the values of widget properties are correct.
7 |
8 | import 'package:flutter/material.dart';
9 | import 'package:flutter_test/flutter_test.dart';
10 |
11 | import 'package:flutter_dialog/main.dart';
12 |
13 | void main() {
14 | testWidgets('Counter increments smoke test', (WidgetTester tester) async {
15 | // Build our app and trigger a frame.
16 | await tester.pumpWidget(MyApp());
17 |
18 | // Verify that our counter starts at 0.
19 | expect(find.text('0'), findsOneWidget);
20 | expect(find.text('1'), findsNothing);
21 |
22 | // Tap the '+' icon and trigger a frame.
23 | await tester.tap(find.byIcon(Icons.add));
24 | await tester.pump();
25 |
26 | // Verify that our counter has incremented.
27 | expect(find.text('0'), findsNothing);
28 | expect(find.text('1'), findsOneWidget);
29 | });
30 | }
31 |
--------------------------------------------------------------------------------