170 Commits

Author SHA1 Message Date
Shi-Hao Hong
63f40903de
Revert getSystemGestureExclusionRects and setSystemGestureExclusionRects (#17613)
* Revert getSystemGestureExclusionRects and setSystemGestureExclusionRects 

* Remove references to removed PlatformChannelTest.java file
2020-04-09 20:44:37 -07:00
Jason Simmons
288b66b1b6
Disconnect from platform views and virtual displays before detaching from the engine (#17379) 2020-04-02 18:16:05 -07:00
Dan Field
2e909652ac
Fix bad texture view config (#17486) 2020-04-02 15:06:03 -07:00
renyou
ba80c0c49a
Android change to match the Google internal changes. (#17331)
* Android change to match the google internal changes.

* Fix format.

* Revert format change, add super call.

* Remove comment for API version.
2020-03-25 18:02:46 -07:00
Emmanuel Garcia
025e2d82dd
Migrate embedding to AndroidX (#17075) 2020-03-13 21:19:24 -07:00
xster
1ff81bc117
Make a pass through all the embedding javadocs (#17109) 2020-03-13 16:34:34 -07:00
Matt Carroll
482155b3c6
Fixed splash screen crash when bringing Android app back to foreground after being evicted from memory. (#47635) (#16916) 2020-03-04 11:27:12 -08:00
Matt Carroll
f39bc73d6a
Exposes FlutterSurfaceView, and FlutterTextureView to FlutterActivity and FlutterFragment. (#41984, #47557) (#16552) 2020-02-12 19:21:00 -08:00
Michael Klimushyn
7c67573896
Fix multiline Javadoc code blocks (#16565)
The formatter didn't understand what was going on here and broke the
text. Changed these to use `<pre>{@code }</pre>` instead.
2020-02-12 15:07:16 -08:00
Matt Carroll
ca02b9197e
Prevent long flash when switching to Flutter app. (#47903) (#16527) 2020-02-11 15:26:27 -08:00
Matt Carroll
270421c103
Fix ensureInitializationCompleteAsync callback when already initialized. (#39675) (#16503) 2020-02-11 15:25:58 -08:00
Gityuan
5041ff1b1e
support endless trace buffer (#16520) 2020-02-11 15:08:03 -08:00
Michael Klimushyn
077918dcfd
Apply Google Java format (#16501)
This shouldn't result in any logical changes. I've done a quick smoke
test by building a local Android engine and running Flutter gallery, no
compile errors or other obvious issues.

Applied by running `/ci/format.sh | patch -p0` with the altered script
added in flutter/engine#16500. I did locally modify the script slightly
further so it would run against all Java files in the repo instead of
just modified ones.
2020-02-07 16:10:46 -08:00
Matt Carroll
9443518f62
Fix safe area reporting with transparent FlutterActivitys. (#46060) (#16208) 2020-02-07 14:57:06 -08:00
Jason Simmons
7c95cdada4
Ensure that Android embedding initialization always uses an application context (#16204)
Some parts of the embedding (e.g. VsyncWaiter) may hold global references to
system services obtained through the context used during initialization.
These must not be associated with an activity or other non-application context.

Fixes https://github.com/flutter/flutter/issues/49612
2020-01-31 12:09:38 -08:00
Matt Carroll
eecb5e5c25
Notify PlatformViewsController within FlutterEngine when a hot restart occurs. (#48518) (#16230) 2020-01-30 12:58:41 -08:00
Michael Klimushyn
6fa1fcda8f
Register plugins at the right time, once (#15979)
Currently we're automatically registering plugins both when the
FlutterEngine is constructed and in the `flutter create` template, when
FlutterActivity#configureFlutterEngine is called. The initial
registration is too early to contain a reference to the activity and the
second registration can cause problems in some plugins.

This alters the flow so automatic registration happens in two discrete
places, and contains the `activity` in its first and only call for most
apps.

1. We're no longer automatically registering plugins on `FlutterEngine`
in any of our activities/fragments at construction time. But since the
FlutterEngine default constructor still automatically registers plugins,
anyone constructing the engine themselves (for example, in a service) is
still going to get automatic registration at `FlutterEngine`
instantiation time.
2. We now automatically register plugins in the base `FlutterActivity`'s
`configureFlutterEngine` hook. Anyone using `FlutterActivity` (or
`FlutterFragment`) should be automatically registered once that hook is
called. Right now the `flutter create` template overrides the base class
method with a subclass that registers everything manually in the same
spot. But with this in place we can safely recommend to remove the
subclass and rely on this hook to automatically register going forward.
Registering at this time means `activity` is set correctly.
2020-01-25 00:34:52 -08:00
Chris Bracken
d1b0883883
Eliminate unused import in Android embedding (#15975)
Eliminates an unused dependency on android.os.build. The last remaining
use of this was eliminated in 0615f45623224bd99ee3ceb8ba4a0d4d04f58d54
with the removal of an unused method that contained an android version
check.
2020-01-24 16:19:00 -08:00
Matt Carroll
fec9573786
Prevent duplicate plugin registration in FlutterEnginePluginRegistry. (#49365) (#15956) 2020-01-24 15:57:51 -08:00
Matt Carroll
29e857ca2c
Release TextureView surface within FlutterTextureView when disconnected. (#48535) (#15899) 2020-01-23 13:19:42 -08:00
Michael Goderbauer
0615f45623 Remove unused Imports and private method (#15872) 2020-01-21 17:53:02 -08:00
xster
006e44d1d0 Reduce default verbosity of Android embedding (#15164) 2020-01-18 23:49:05 -08:00
Jason Simmons
0235a50843
Change the value of EXTRA_INITIAL_ROUTE to match the value used by the old embedding and flutter_tools (#15569) 2020-01-13 17:19:31 -08:00
Jason Simmons
fb52622304
Add a type parameter to SavedState.Creator in the new embedding (#15563) 2020-01-13 15:26:32 -08:00
Matt Carroll
4513205b13 Make BackgroundMode public. (#45747) (#14673) 2020-01-08 21:41:34 -08:00
Dan Field
2a1ade7908
Raise API level for reportFullyDrawn (#14146) 2019-12-05 14:51:55 -08:00
Dan Field
73da385c11
Disable a11y on detach (#14142) 2019-12-05 11:16:38 -08:00
Matt Carroll
7c5a954dd3
Removed GET_ACTIVITIES flag from all manifest meta-data lookups. (#38891) (#13932) 2019-11-21 15:00:27 -08:00
chunhtai
132d38cd22
Moves pointer event sanitizing to engine. (#13697)
* Moves pointer event sanitizing to engine

* fix comment format

* fix formatting

* addressing comment

* fix format

* fix format

* addressing comment
2019-11-19 09:48:25 -08:00
Matt Carroll
687a1a7541
Add support for --dart-flags in FlutterShellArgs. (#44855) (#13855) 2019-11-14 04:09:08 +00:00
Todd Volkert
9a3042cb50
Remove unused import (#13832) 2019-11-13 14:12:46 -08:00
chunhtai
1f1e2ba58e
reland add lifecycle enum (#13767)
This reverts commit 8ebb318401344793daa10c3bec97c34891cf7cc8.
2019-11-13 11:26:25 -08:00
Matt Carroll
e19ee72f31
Expose asset lookup from plugin binding. (#42019) (#13743) 2019-11-12 07:14:27 +00:00
Matt Carroll
55c64a92d8
Point old plugin registry accessors to new embedding plugin accessors. (#44225) (#13739) 2019-11-09 01:55:59 +00:00
Matt Carroll
6fd58edd3e
Removed scary experimental warnings for new embedding. (#44314) (#13738) 2019-11-07 22:54:10 +00:00
chunhtai
8ebb318401
Revert "Issues/39832 reland (#13642)" (#13720)
This reverts commit 1bfb928e071674a21779cee94908fbcae1c2e657.
2019-11-06 11:41:36 -08:00
Jason Simmons
47579164ad
Fix NPE in splash screen lookup (#13719) 2019-11-06 10:31:41 -08:00
Matt Carroll
e924d71627
Fix splash screen lookup. (#44131) (#13660) 2019-11-06 04:37:48 +00:00
Matt Carroll
58a6d6554f
Fix plugin registrant reflection path. (#44161) (#13698) 2019-11-05 23:36:35 +00:00
chunhtai
1bfb928e07
Issues/39832 reland (#13642)
* Reland "Added new lifecycle enum (#11913)"
2019-11-05 14:52:16 -08:00
Jason Simmons
76312eefdd
Fix Class.forName unchecked call warning (#13695) 2019-11-05 13:45:57 -08:00
chunhtai
fe0838e948
Revert "Added new lifecycle enum (#11913)" (#13632)
This reverts commit 02a479007420b05df8e075978ecdd15442ea520f.
2019-11-04 13:40:20 -08:00
chunhtai
02a4790074
Added new lifecycle enum (#11913) 2019-11-04 12:33:41 -08:00
xster
7aa40556a4
Release shim bindings when detaching (#13432) 2019-11-01 17:53:15 -07:00
Dan Field
ced6c63d1e
Request a reattach when creating the text input plugin on Android (#13474) 2019-11-01 15:29:33 -07:00
Matt Carroll
c882439cb3
Automatically register plugins in FlutterEngine. (#43855) (#13455) 2019-10-31 14:10:45 -07:00
Dan Field
4b76fadbf4
Fizzle onConfigurationChanged if no FlutterView (#13445) 2019-10-30 15:49:02 -07:00
Matt Carroll
97807b5341
Automatically destroy FlutterEngine when created by FlutterActivity or FlutterFragment. (#13423) 2019-10-30 15:01:57 -07:00
Matt Carroll
e96f8603f0
Converted ActivityAware and ServiceAware Lifecycles to opaque objects (#43670) (#13402) 2019-10-28 21:41:07 -07:00
Matt Carroll
55e9ad77ec
Remove multiplexed Flutter Android Lifecycle. (#43663) (#13394) 2019-10-28 16:22:11 -07:00