500 Commits

Author SHA1 Message Date
Amir Hardon
10cee612bb
Delete GL textures when they are released from the texture registry. (#7836)
On Android we were never deleting the textures allocated for
the texture registry, which resulted in a memory leak, see:
https://github.com/flutter/flutter/issues/24145
2019-02-15 13:11:49 -08:00
najeira
69e4606077 Fix NullPointerException in SurfaceTextureRegistryEntry (#7837) 2019-02-15 13:01:41 -08:00
najeira
9a965bc3d9 Fix NullPointerException in ResourceCleaner (#7838) 2019-02-15 12:56:37 -08:00
nathanrogersgoogle
e2394ad77e
Add flow events connecting pointer events to frames (#7807) 2019-02-13 22:27:12 -08:00
Stanislav Baranov
d48de7a3ec
Support for binary decompression of dynamic patches. (#7777) 2019-02-11 16:56:33 -08:00
Matt Carroll
4663d357a3
Recommended implementation of combining characters implementation. (#7758) 2019-02-11 15:27:55 -08:00
Jason Simmons
694300d325
Provide a default pressure range if a MotionEvent does not have a device (#7737)
Fixes https://github.com/flutter/flutter/issues/27641
2019-02-11 09:29:07 -08:00
Stanislav Baranov
aa275820bc
Support for loading dynamic patches in AOT mode. (#7744)
* Dynamic patching support for AOT mode.

* Cleanup.
2019-02-08 10:47:01 -08:00
Matt Carroll
211adeac3a
Introduced a number of Java system channels in io/flutter/embedding/engine/systemchannels/ (#7500) 2019-02-06 17:07:30 -08:00
Matt Carroll
cc27cafb84
Implemented Dark Mode for Android (#25525) (#7488) 2019-02-04 19:30:15 -08:00
Jason Simmons
050dcaad60
Embed ICU data inside libflutter.so on Android (#7588)
Prior to this the Android embedder code would extract the icudtl.dat asset out
of the APK and write it to local disk during the first startup of the app.

This change will make that work unnecessary and eliminate the risk of ICU
failures due to errors in the extraction process.
2019-01-30 11:56:17 -08:00
Chinmay Garde
79dc315dc4
Allow the engine to redirect traces to systrace via settings. (#7617) 2019-01-28 17:39:31 -08:00
jslavitz
c57e66fdae
fixes android pressure range (#7516) 2019-01-22 15:09:02 -08:00
Brian Osman
50ddc3712f
Remove SkColorSpaceXformCanvas, use color-managed SkSurfaces instead (#7548)
Behavior (visual) changes should be very minor. Things that are to be expected:
* A few things were not color managed correctly by the transform canvas (color emoji, some color filters). Those will be handled correctly with the tagged surfaces (although we're always transforming to sRGB, so nothing should change until we target a wider gamut).
* Image filtering will happen in the source color space, rather than the destination. Very minor.
* The transform canvas did caching of images in the destination color space. Now, the conversion happens at draw time. If there are performance issues, images can be pre-converted to the destination with makeColorSpace().
2019-01-22 15:34:51 -05:00
Dan Field
75cfebde06
Roll buildroot and update method of getting android SDK and support libs (#7284)
* Get support, use new SDK tooling from buildroot
* Roll NDK to 19
* Skip Android bits on Windows with note
2019-01-18 15:20:56 -08:00
Stanislav Baranov
5401803f67
Validate dynamic patches before attempting to install (#7496)
This change adds explicit validation of dynamic patches in all places
where they're used, instead of only validating it in some places which
wasn't as reliable because some of the code paths were missed.

This change also moves utility functions that deal with validating
patches from ResourceExtractor to ResourceUpdater, to make them
available as API for other places in code that need this validation.
2019-01-15 18:09:25 -08:00
Jason Simmons
395937380c
Log errors returned from method channel invocations in the text input plugin (#7476)
See https://github.com/flutter/flutter/issues/25715
2019-01-14 17:26:05 -08:00
Greg Spencer
918b28dbe1
Add hover event support to the engine (#6961)
This adds support for passing ACTION_HOVER_MOVE events to the framework, in preparation for supporting mouse hover events on Android and ChromeOS.
2019-01-14 16:15:20 -08:00
Stanislav Baranov
37d886ef85
Simplify rollback of dynamic patches (#7432) 2019-01-09 17:29:04 -08:00
Stanislav Baranov
6071286ef1
Download dynamic patch to separate file, then rename it to install. (#7428)
This fixes potential race condition when patch gets downloaded on top
of zip file that's currently in active use by resource extractor and/or
asset manager. This change is necessary since download can happen in
the background while normal application operations are in progress.
2019-01-09 16:26:24 -08:00
Chris Bracken
20d70d2bf4
Eliminate unused import of ZipException (#7429)
Use of this class was eliminated in https://github.com/flutter/engine/pull/7398.
2019-01-09 15:08:43 -08:00
Stanislav Baranov
844d27cb3c
Refactor dynamic patching to use clearer naming and structure. (#7426)
This is a no-op change, except for fixing a bug where download task
reference wasn't cleared after download was completed.

This change also removes call to output stream flush(), which is not
necessary according to Java spec.

The rest of the change deals with requiring the code to work directly
with ResourceUpdater object instead of having FlutterMain be a facade
that forwards some of ResourceUpdater's methods. This simplifies the
other (more essential) upcoming changes that will be landing in the
followings few PRs.
2019-01-09 14:21:36 -08:00
Stanislav Baranov
5e33f33a18
Refactor shared code into separate function to simplify further work. (#7410)
This should be a no-op change that behaves identical to as before.
2019-01-08 12:44:07 -08:00
David Guralnick
8eccb860de Add onStart hook to FlutterFragmentActivity (#6719)
Seems like this file was missed when onStart hooks were added recently in this pull request: https://github.com/flutter/engine/pull/5177
2019-01-07 17:16:06 -05:00
Dan Field
5ca8aadaa2
Announce in/out of list (#6918)
* Support in/out of list announcements on Android
2019-01-07 13:36:20 -08:00
Todd Volkert
4487d392da
Replace Java code with equivalent, more concise code. (#7398) 2019-01-07 11:28:00 -08:00
Stanislav Baranov
8cca33aea8
Give more control over when dynamic patches get downloaded and installed. (#7327)
This change introduces manifest properties that control when dynamic patches are downloaded and installed in the application lifecycle.

Application developer can choose whether between install on restart, install on resume, or immediate forced install of dynamic patches.
2019-01-02 10:40:37 -08:00
Stanislav Baranov
6f763fbad7
Minor refactoring of dynamic patching code. (#7325)
Minor refactoring of dynamic patching code.

- Changes naming of manifest properties to be consistent with documentation.
- Moves methods from inner class to outer class to make them more reusable.
2018-12-28 13:23:38 -08:00
Stanislav Baranov
868dc047b4
Support loading flutter assets from dynamic patch (#7308)
This replicates similar logic found in ApkAssetProvider that locates assets by their short name in a sudbirectory inside of an archive file, instead of only at the root of archive.
2018-12-28 10:34:47 -08:00
Stanislav Baranov
732ea7669c
Allow dynamic patches without a patch number. (#7309)
Unique patch numbers are mainly useful for canary and A-B testing, but otherwise complicate things and can now be omitted.

Also, always append .zip to patch download URL. This obviates the need to configure redirects on the server when not using patch numbers.
2018-12-27 11:56:56 -08:00
matthew-carroll
6b85ed3d93
Android embedding refactor PR1: JNI Extraction to FlutterJNI.java (#7098)
Android embedding refactor: JNI Extraction to FlutterJNI.java
2018-12-21 01:07:04 -05:00
Jason Simmons
41222d0555
Update usage of some Android APIs that are deprecated in API level 28 (#7261) 2018-12-19 17:39:53 -08:00
Jason Simmons
5ec8ef8509
Remove unused GrContext in AndroidSurfaceGL (#7258) 2018-12-19 15:06:58 -08:00
Stanislav Baranov
9edb4f72b9
Update dynamic patching terminilogy to match that of the flutter tool (#7248) 2018-12-19 10:31:54 -08:00
Dan Field
8b73b9d42c
Fix javadoc for Android-28 (#7254)
* Fix javadoc for Android-28

* build javadoc as part of pre-submit
2018-12-19 09:24:02 -08:00
Dan Field
cfbc948647
Roll buildroot to support Android SDK 28 (#7245)
* Roll to buildroot and support Android SDK 28

* Ubuntu 16 for android build test
2018-12-18 19:38:28 -08:00
Todd Volkert
fbce2bf145
Fix linter errors in ResourceUpdater (#7240) 2018-12-18 07:40:57 -08:00
Todd Volkert
f79f7f6312
Allow inferred types using diamond syntax (#7237) 2018-12-17 16:35:10 -08:00
Todd Volkert
951edf3e11
Simplify nested try-with-resources statements (#7239) 2018-12-17 16:34:54 -08:00
Jimmy Casey
f986a12e20 Correct spelling in doc comments (#7179)
Applies spelling corrections to accessibility-related doc comments and in the
license tool.
2018-12-16 12:51:00 -08:00
Ian Hickson
8a7ae957ff
Undeprecated BigInteger support, but document what it actually does. (#6903) 2018-12-15 08:32:20 -08:00
Stanislav Baranov
18a4e33c2a
Downloading and installation of dynamic updates on Android (#7207) 2018-12-13 10:17:37 -08:00
liyuqian
2bd75ae8ba
Support querying display refresh rate in engine (#7002)
The current implementation only deals with Android devices and we'll add iOS devices support soon.
2018-12-12 10:28:44 -08:00
Brian Salomon
e5195ee479 Remove unnecessary includes of Ganesh headers (#7189) 2018-12-12 10:58:14 -05:00
Rafael Ring
9071a39dd2 Fix keyboard not showing for targetSdk 28 (#6985)
After bumping the targetSdk of Flutter apps to 28, the keyboard doesn't open anymore when inputting text on an Android Pie devices. The problem is caused by a change on the way the focus in handled: when the call `mImm.showSoftInput(view, 0);` is made, the currently focused view is the `DecorView` from the `Activity` hosting Flutter but the passed view reference (`view` argument) is the `FlutterView`. As the `InputMethodManager` checks if both views are the same before showing the keyboard, it never appears because the `FlutterView` never has focus.
As Flutter doesn't have any input views as far as the Android side is concerned, the focus should always stay on the `FlutterView` itself and thus, this PR changes the `TextInputPlugin` to focus on the `FlutterView` as soon as it's created, fixing the keyboard issue.

Co-authored-by: Igor Borges <igorborges12@gmail.com>
2018-12-10 21:01:12 -08:00
Jason Simmons
3011c2b754
Handle null bundlePaths in FlutterRunArguments (#7161) 2018-12-10 14:38:44 -08:00
Stanislav Baranov
be36ba6468
Generalize runFromBundle to support multiple bundlePaths (#7151) 2018-12-10 12:19:22 -08:00
Dan Field
110a5f320c
Reset a11y bridge state on hot restart (#6857) 2018-11-14 11:13:39 -08:00
Dan Field
114d33d3ca
Set and unset accessibility flags even when re-entrant (#6853)
* Make sure to not unset a11y flags on reentrant calls to API
2018-11-13 23:54:45 -08:00
Michael Goderbauer
1e7e676e4d
Remove unused import (#6854) 2018-11-13 23:31:56 -08:00