• Home
Name Date Size #Lines LOC

..--

android/12-May-2024-521463

ios/12-May-2024-1,1131,036

lib/12-May-2024-228193

.gitignoreD12-May-2024180 86

README.mdD12-May-20241.7 KiB4834

assemble_apk.shD12-May-2024138 84

compile_android_aot.shD12-May-20241.4 KiB5029

compile_ios_aot.shD12-May-20242.1 KiB7749

compile_ios_jit.shD12-May-20242.7 KiB8255

pubspec.yamlD12-May-2024304 117

run_ios_tests.shD12-May-2024515 2918

README.md

1# Scenario App
2
3This folder contains a dart:ui application and scripts to compile it to AOT
4for exercising embedders.
5
6It intentionally has no dependencies on the Flutter framework or tooling, such
7that it should be buildable as a presubmit or postsubmit to the engine even in
8the face of changes to Dart or dart:ui that require upstream changes in the
9Flutter tooling.
10
11To add a new scenario, create a new subclass of `Scenario` and add it to the
12map in `main.dart`. For an example, see animated_color_square.dart, which draws
13a continuously animating colored square that bounces off the sides of the
14viewport.
15
16## Building for iOS
17
18In this folder, after building the `ios_host` and `ios_profile` engine targets,
19run:
20
21```bash
22./compile_ios_aot.sh ../../../out/host_profile ../../../out/ios_profile/clang_x64/
23```
24
25This will create an `App.framework` copy it as well as the correct
26`Flutter.framework` to where the Xcode project expects to find them.
27
28You can then use `xcodebuild` to build the `ios/Scenarios/Scenarios.xcodeproj`,
29or open that in Xcode and build it that way.
30
31Currently, only AOT modes are supported.
32
33## Building for Android
34
35In this folder, after building the `host_profile` and `android_profile_arm64`
36engine targets, run:
37
38```bash
39./compile_android_aot.sh ../../../out/host_profile ../../../out/android_profile_arm64/clang_x64/
40```
41
42This will produce a suitable `libapp.so` for building with an Android app and
43copy it (along with flutter.jar) to where Gradle will expect to find it to build
44the app in the `android/` folder. The app can be run by opening it in Android
45Studio and running it, or by running `./gradlew assemble` in the `android/`
46folder and installing the APK from the correct folder in
47`android/app/build/outputs/apk`.
48