Skip to content

Commit 8a84ef9

Browse files
committed
chore: Add Flutter
1 parent 32ad000 commit 8a84ef9

File tree

124 files changed

+4715
-0
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

124 files changed

+4715
-0
lines changed

.gitignore

Lines changed: 119 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,3 +17,122 @@ Cargo.lock
1717
# Added by cargo
1818

1919
/target
20+
21+
# Miscellaneous
22+
*.class
23+
*.lock
24+
*.log
25+
*.pyc
26+
*.swp
27+
.DS_Store
28+
.atom/
29+
.buildlog/
30+
.history
31+
.svn/
32+
33+
# IntelliJ related
34+
*.iml
35+
*.ipr
36+
*.iws
37+
.idea/
38+
39+
# Visual Studio Code related
40+
.classpath
41+
.project
42+
.settings/
43+
.vscode/
44+
45+
# Flutter repo-specific
46+
/bin/cache/
47+
/bin/internal/bootstrap.bat
48+
/bin/internal/bootstrap.sh
49+
/bin/mingit/
50+
/dev/benchmarks/mega_gallery/
51+
/dev/bots/.recipe_deps
52+
/dev/bots/android_tools/
53+
/dev/devicelab/ABresults*.json
54+
/dev/docs/doc/
55+
/dev/docs/flutter.docs.zip
56+
/dev/docs/lib/
57+
/dev/docs/pubspec.yaml
58+
/dev/integration_tests/**/xcuserdata
59+
/dev/integration_tests/**/Pods
60+
/packages/flutter/coverage/
61+
version
62+
analysis_benchmark.json
63+
64+
# packages file containing multi-root paths
65+
.packages.generated
66+
67+
# Flutter/Dart/Pub related
68+
**/doc/api/
69+
.dart_tool/
70+
.flutter-plugins
71+
.flutter-plugins-dependencies
72+
**/generated_plugin_registrant.dart
73+
.packages
74+
.pub-cache/
75+
.pub/
76+
build/
77+
flutter_*.png
78+
linked_*.ds
79+
unlinked.ds
80+
unlinked_spec.ds
81+
82+
# Android related
83+
**/android/**/gradle-wrapper.jar
84+
**/android/.gradle
85+
**/android/captures/
86+
**/android/gradlew
87+
**/android/gradlew.bat
88+
**/android/local.properties
89+
**/android/**/GeneratedPluginRegistrant.java
90+
**/android/key.properties
91+
*.jks
92+
93+
# iOS/XCode related
94+
**/ios/**/*.mode1v3
95+
**/ios/**/*.mode2v3
96+
**/ios/**/*.moved-aside
97+
**/ios/**/*.pbxuser
98+
**/ios/**/*.perspectivev3
99+
**/ios/**/*sync/
100+
**/ios/**/.sconsign.dblite
101+
**/ios/**/.tags*
102+
**/ios/**/.vagrant/
103+
**/ios/**/DerivedData/
104+
**/ios/**/Icon?
105+
**/ios/**/Pods/
106+
**/ios/**/.symlinks/
107+
**/ios/**/profile
108+
**/ios/**/xcuserdata
109+
**/ios/.generated/
110+
**/ios/Flutter/.last_build_id
111+
**/ios/Flutter/App.framework
112+
**/ios/Flutter/Flutter.framework
113+
**/ios/Flutter/Flutter.podspec
114+
**/ios/Flutter/Generated.xcconfig
115+
**/ios/Flutter/ephemeral
116+
**/ios/Flutter/app.flx
117+
**/ios/Flutter/app.zip
118+
**/ios/Flutter/flutter_assets/
119+
**/ios/Flutter/flutter_export_environment.sh
120+
**/ios/ServiceDefinitions.json
121+
**/ios/Runner/GeneratedPluginRegistrant.*
122+
123+
# macOS
124+
**/macos/Flutter/GeneratedPluginRegistrant.swift
125+
126+
# Coverage
127+
coverage/
128+
129+
# Symbols
130+
app.*.symbols
131+
132+
# Exceptions to above rules.
133+
!**/ios/**/default.mode1v3
134+
!**/ios/**/default.mode2v3
135+
!**/ios/**/default.pbxuser
136+
!**/ios/**/default.perspectivev3
137+
!/packages/flutter_tools/test/data/dart_dependencies_test/**/.packages
138+
!/dev/ci/**/Gemfile.lock

analysis_options.yaml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
# This file configures the analyzer, which statically analyzes Dart code to
2+
# check for errors, warnings, and lints.
3+
#
4+
# The issues identified by the analyzer are surfaced in the UI of Dart-enabled
5+
# IDEs (https://dart.dev/tools#ides-and-editors). The analyzer can also be
6+
# invoked from the command line by running `flutter analyze`.
7+
8+
# The following line activates a set of recommended lints for Flutter apps,
9+
# packages, and plugins designed to encourage good coding practices.
10+
include: package:flutter_lints/flutter.yaml
11+
12+
linter:
13+
# The lint rules applied to this project can be customized in the
14+
# section below to disable rules from the `package:flutter_lints/flutter.yaml`
15+
# included above or to enable additional rules. A list of all available lints
16+
# and their documentation is published at https://dart.dev/lints.
17+
#
18+
# Instead of disabling a lint rule for the entire project in the
19+
# section below, it can also be suppressed for a single line of code
20+
# or a specific dart file by using the `// ignore: name_of_lint` and
21+
# `// ignore_for_file: name_of_lint` syntax on the line or in the file
22+
# producing the lint.
23+
rules:
24+
# avoid_print: false # Uncomment to disable the `avoid_print` rule
25+
# prefer_single_quotes: true # Uncomment to enable the `prefer_single_quotes` rule
26+
27+
# Additional information about this file can be found at
28+
# https://dart.dev/guides/language/analysis-options

android/.gitignore

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
gradle-wrapper.jar
2+
/.gradle
3+
/captures/
4+
/gradlew
5+
/gradlew.bat
6+
/local.properties
7+
GeneratedPluginRegistrant.java
8+
9+
# Remember to never publicly share your keystore.
10+
# See https://flutter.dev/docs/deployment/android#reference-the-keystore-from-the-app
11+
key.properties
12+
**/*.keystore
13+
**/*.jks

android/app/build.gradle

Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
plugins {
2+
id "com.android.application"
3+
id "kotlin-android"
4+
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
5+
id "dev.flutter.flutter-gradle-plugin"
6+
}
7+
8+
def localProperties = new Properties()
9+
def localPropertiesFile = rootProject.file("local.properties")
10+
if (localPropertiesFile.exists()) {
11+
localPropertiesFile.withReader("UTF-8") { reader ->
12+
localProperties.load(reader)
13+
}
14+
}
15+
16+
def flutterVersionCode = localProperties.getProperty("flutter.versionCode")
17+
if (flutterVersionCode == null) {
18+
flutterVersionCode = "1"
19+
}
20+
21+
def flutterVersionName = localProperties.getProperty("flutter.versionName")
22+
if (flutterVersionName == null) {
23+
flutterVersionName = "1.0"
24+
}
25+
26+
android {
27+
namespace = "com.example.player"
28+
compileSdk = flutter.compileSdkVersion
29+
ndkVersion = flutter.ndkVersion
30+
31+
compileOptions {
32+
sourceCompatibility = JavaVersion.VERSION_1_8
33+
targetCompatibility = JavaVersion.VERSION_1_8
34+
}
35+
36+
defaultConfig {
37+
// TODO: Specify your own unique Application ID (https://developer.android.com/studio/build/application-id.html).
38+
applicationId = "com.example.player"
39+
// You can update the following values to match your application needs.
40+
// For more information, see: https://docs.flutter.dev/deployment/android#reviewing-the-gradle-build-configuration.
41+
minSdk = flutter.minSdkVersion
42+
targetSdk = flutter.targetSdkVersion
43+
versionCode = flutterVersionCode.toInteger()
44+
versionName = flutterVersionName
45+
}
46+
47+
buildTypes {
48+
release {
49+
// TODO: Add your own signing config for the release build.
50+
// Signing with the debug keys for now, so `flutter run --release` works.
51+
signingConfig = signingConfigs.debug
52+
}
53+
}
54+
}
55+
56+
flutter {
57+
source = "../.."
58+
}
Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
<manifest xmlns:android="http://schemas.android.com/apk/res/android">
2+
<application
3+
android:label="player"
4+
android:name="${applicationName}"
5+
android:icon="@mipmap/ic_launcher">
6+
<activity
7+
android:name=".MainActivity"
8+
android:exported="true"
9+
android:launchMode="singleTop"
10+
android:taskAffinity=""
11+
android:theme="@style/LaunchTheme"
12+
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
13+
android:hardwareAccelerated="true"
14+
android:windowSoftInputMode="adjustResize">
15+
<!-- Specifies an Android theme to apply to this Activity as soon as
16+
the Android process has started. This theme is visible to the user
17+
while the Flutter UI initializes. After that, this theme continues
18+
to determine the Window background behind the Flutter UI. -->
19+
<meta-data
20+
android:name="io.flutter.embedding.android.NormalTheme"
21+
android:resource="@style/NormalTheme"
22+
/>
23+
<intent-filter>
24+
<action android:name="android.intent.action.MAIN"/>
25+
<category android:name="android.intent.category.LAUNCHER"/>
26+
</intent-filter>
27+
</activity>
28+
<!-- Don't delete the meta-data below.
29+
This is used by the Flutter tool to generate GeneratedPluginRegistrant.java -->
30+
<meta-data
31+
android:name="flutterEmbedding"
32+
android:value="2" />
33+
</application>
34+
<!-- Required to query activities that can process text, see:
35+
https://developer.android.com/training/package-visibility and
36+
https://developer.android.com/reference/android/content/Intent#ACTION_PROCESS_TEXT.
37+
38+
In particular, this is used by the Flutter engine in io.flutter.plugin.text.ProcessTextPlugin. -->
39+
<queries>
40+
<intent>
41+
<action android:name="android.intent.action.PROCESS_TEXT"/>
42+
<data android:mimeType="text/plain"/>
43+
</intent>
44+
</queries>
45+
</manifest>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
package com.example.player
2+
3+
import io.flutter.embedding.android.FlutterActivity
4+
5+
class MainActivity: FlutterActivity()
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!-- Modify this file to customize your launch splash screen -->
3+
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
4+
<item android:drawable="?android:colorBackground" />
5+
6+
<!-- You can insert your own image assets here -->
7+
<!-- <item>
8+
<bitmap
9+
android:gravity="center"
10+
android:src="@mipmap/launch_image" />
11+
</item> -->
12+
</layer-list>
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<!-- Modify this file to customize your launch splash screen -->
3+
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
4+
<item android:drawable="@android:color/white" />
5+
6+
<!-- You can insert your own image assets here -->
7+
<!-- <item>
8+
<bitmap
9+
android:gravity="center"
10+
android:src="@mipmap/launch_image" />
11+
</item> -->
12+
</layer-list>
544 Bytes
Loading
442 Bytes
Loading

0 commit comments

Comments
 (0)