Fix add_to_app sample (#2768)

The android_view add_to_app sample is currently broken.  It does not build:

* AGP version is incompatible.
* MIN_SDK is below Flutter min
* Flutter plugin module was renamed awhile ago: https://github.com/flutter/samples/pull/2714
pull/2775/head
Matt Boetger 8 months ago committed by GitHub
parent 3c112d0efc
commit 344740a22c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -12,7 +12,7 @@ android {
defaultConfig { defaultConfig {
applicationId "dev.flutter.example.androidView" applicationId "dev.flutter.example.androidView"
minSdkVersion 21 minSdkVersion 24
targetSdk 36 targetSdk 36
versionCode 1 versionCode 1
versionName "1.0" versionName "1.0"
@ -55,4 +55,4 @@ dependencies {
testImplementation 'junit:junit:4.+' testImplementation 'junit:junit:4.+'
androidTestImplementation 'androidx.test.ext:junit:1.2.1' androidTestImplementation 'androidx.test.ext:junit:1.2.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.6.1' androidTestImplementation 'androidx.test.espresso:espresso-core:3.6.1'
} }

@ -6,7 +6,7 @@ buildscript {
mavenCentral() mavenCentral()
} }
dependencies { dependencies {
classpath 'com.android.tools.build:gradle:8.9.0' classpath 'com.android.tools.build:gradle:8.9.1'
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
// NOTE: Do not place your application dependencies here; they belong // NOTE: Do not place your application dependencies here; they belong
@ -23,4 +23,4 @@ allprojects {
tasks.register('clean', Delete) { tasks.register('clean', Delete) {
delete rootProject.buildDir delete rootProject.buildDir
} }

@ -3,5 +3,5 @@ include ':app'
setBinding(new Binding([gradle: this])) setBinding(new Binding([gradle: this]))
evaluate(new File( evaluate(new File(
settingsDir.parentFile, settingsDir.parentFile,
'flutter_module_using_plugin/.android/include_flutter.groovy' 'flutter_module_using_plugin_android_view/.android/include_flutter.groovy'
)) ))

Loading…
Cancel
Save