2604 Commits

Author SHA1 Message Date
stuartmorgan
2bc0bfdab4
Send locale information in the macOS embedding (#20461)
Queries the system list of user-preferred languages, and sends it to the
engine just after starting it up, as well as after any OS locale change.

macOS portion of https://github.com/flutter/flutter/issues/45152
2020-08-12 19:31:22 -07:00
David Worsham
debb30eddd
Fix broken symbols on Fuchsia embedder (#20459)
See: b/163653659
2020-08-12 19:06:22 -07:00
David Worsham
9f146b5f47
Add --unoptimied and --asan to Fuchsia builds (#20427) 2020-08-12 14:47:55 -07:00
gaaclarke
2ac5b3460a
Revert "Refactor initial route code (#19684)" (#20450)
This reverts commit 8d08e6c369e349986831d83204a79af3fcb8d8ca.
2020-08-12 12:43:08 -07:00
xster
8d08e6c369
Refactor initial route code (#19684) 2020-08-11 19:52:04 -07:00
stuartmorgan
ccfc7e5179
Add missing reply in C++ MethodChannel unit test (#20420)
The test handler wasn't replying, which logged an error message during
the unit test.

Fixes https://github.com/flutter/flutter/issues/62560
2020-08-11 19:16:20 -07:00
David Worsham
6381b1511b
Fix broken shell_unittests on Fuchsia (#20422)
Fixes https://github.com/flutter/flutter/issues/53399
2020-08-11 17:31:25 -07:00
stuartmorgan
3242a69ee4
Add virtual destructors to ByteStream* (#20417) 2020-08-11 14:39:14 -07:00
Dan Field
dbc97c5c01
Use performDeferredCleanup instead of freeGpuResources (#20413) 2020-08-11 14:01:01 -07:00
stuartmorgan
49f647f957
Fix RTTI check in EncodableValue (#20398)
__has_feature(cxx_rtti) is a clang extension, but clients of this code
are mostly using the VS toolchain. This makes the RTTI check work with
more compilers.
2020-08-11 10:53:26 -07:00
David Worsham
fafbcd223b
Fix broken Fuchsia test (#20397) 2020-08-11 01:01:38 -07:00
David Reveman
0cf4809e24
Add Surface::GetContext() support on Fuchsia (#20391)
This improves raster cache control from apps and enables
GPU acceleration for some offscreen workloads that would
fallback to software.

Test: PlatformViewTests.GetGrContextTest

Co-authored-by: David Reveman <reveman@google.com>
2020-08-10 20:51:43 -07:00
Kaushik Iska
43067ed4fc
engineCallbackOnPresent should return false if glContext is invalid (#20337)
Co-authored-by: Kaushik Iska <kaushikiska@google.com>
2020-08-10 16:44:20 -07:00
guolinaileen
594284baee
Add TextInput performPrivateCommand to Flutter Engine (#20188)
New command for Crowdsource 2/2
2020-08-10 14:04:11 -07:00
Sanjay Chouksey
9632bf3921
Create scenic session with view focuser (#20288)
This change creates the scenic session with request to Focuser. The
focuser is used to request focus to a view, given it's ViewRef. The call to
requestFocus is made from PlatformView messages channel, which will
be used from Flutter side by ChildView.

Adds a PlatformView unittest for the requestFocus method.

Co-authored-by: Sanjay Chouksey <sanjayc@google.com>
2020-08-10 13:57:46 -07:00
David Worsham
de15313b7e
Dedupe sources for fuchsia shell/tests (#20343)
Remove the gni file, as it is confusing things
2020-08-10 13:52:19 -07:00
stuartmorgan
b28b1dfe68
Allow extending the C++ standard codec (#20317)
Standard*Codec allows for extensions to support arbitrary types; this
had not previously been implemented for the C++ version.

Overview of changes:
- EncodableValue's std::variant type now allows for a new CustomEncodableValue, which is a thin wrapper around std::any, to store arbitrary extension types.
- ByteBufferStream* has been split into an interface class and the buffer-based implementation, with the former now part of the public API surface to be used in standard codec extensions.
  - They also gained utility methods for some common data types to simplify writing extensions.
- StandardCodecSerializer is now part of the public API surface, and is subclassable.
- StandardCodecSerializer's ReadValue has been split into ReadValue and ReadValueOfType to match the structure used when subclassing on the Dart side, for easier porting of custom extensions across languages.
- Standard*Codec now optionally accepts a non-default serializer in GetInstance, providing a shared instance using that serializer.

Fixes https://github.com/flutter/flutter/issues/31174
2020-08-10 13:41:13 -07:00
LongCatIsLooong
33a68818c5
[iOS TextInput] Fixes selection clamping & composing range change logic (#20348) 2020-08-10 09:45:36 -07:00
stuartmorgan
cd4192d4ee
[windows] Rework controller/engine interaction in the API (#20266)
Changes the interaction between the view controller and engine in both the C API and
the engine API, so that there's always an engine (as on other platforms) rather than
the engine APIs being specific to headless mode.

While adjusting the C API, this does a large cleanup:
- Renames all methods to follow a `FlutterDesktop` (prefix) + "class" name + method-style name.
  E.g., `FlutterDestkopViewControllerCreate` rather than `FlutterDesktopCreateViewController`.
  This makes it easier to see what functions operate on which conceptual "object" in the API.
- Reorders and groups them by the object they operate on.

Fixes https://github.com/flutter/flutter/issues/61966
2020-08-10 09:41:18 -07:00
Ming Lyu (CareF)
409a5e5963
FrameTiming build start timestamp fix and add vsync start timestamp (#20229) 2020-08-07 19:41:01 -07:00
Emmanuel Garcia
18d286a6e4
Add FlutterFragmentActivity#getRenderMode() (#20245) 2020-08-07 18:41:01 -07:00
guolinaileen
ef1fd32b83
Add TextInput sendAppPrivateCommand to Flutter Engine (#20144)
Adds sendAppPrivateCommand for Crowdsource
2020-08-07 17:15:05 -07:00
gaaclarke
2ea8396860
Added unit tests to the engine. (#20216) 2020-08-07 15:55:58 -07:00
Adlai Holler
f571cddb33
android_external_texture: Use the available GrDirectContext arg (#20303)
getGrContext is going away, plus we already have the fully-powered-up GrDirectContext available and we previously weren't using it.
2020-08-06 12:11:36 -07:00
Zachary Anderson
47c1c61a92
Revert "fuchsia: Remove dead code / break dependencies (#19396)" (#20302)
This reverts commit 12a37478de2cc9aff7f8fc72bc3a47f5f02e083c.
2020-08-06 12:06:06 -07:00
chunhtai
aea9046b5c
fix ios layout change cause the accessibility focus to jump randomly. (#20167)
* fix ios layout change cause the accessibility focus to jump randomly.

* format

* addressing review comments
2020-08-05 16:32:59 -07:00
Jason Simmons
e363c58f5a
Fix the reversal of behavior in SerializeTypefaceWithData and WithoutData (#20250) 2020-08-05 13:16:02 -07:00
gaaclarke
d36c65c984
refactored the accessibility bridge to have a view controller instead of a view (#18800) 2020-08-05 10:00:52 -07:00
stuartmorgan
9178074e9a
[windows] Separate the engine from the view (#19896)
Refactors the Windows embedding internals to make an engine object that
owns things associated with the engine rather than the view, and updates
the API surface to allow using the engine directly.

This is an incremental step toward both a cleaner, non-struct-based
internal structure and a finalized API surface.
2020-08-05 08:09:13 -07:00
William Wold
7a022774c2
Improve FlRenderer interface in preperation for Wayland on Linux (#20006) 2020-08-05 12:04:01 +12:00
Robert Ancell
ab23dc3a74 Update code style to pass clang-tidy checks 2020-08-05 10:35:03 +12:00
Ming Lyu (CareF)
2905171d55
Remove null check for layer_tree pointer in Animator::Render (#20178) 2020-08-04 14:56:02 -07:00
stuartmorgan
3081844cb4
Make EncodableValue a thin std::variant wrapper (#19983)
Instead of a hand-rolled discriminated union (originally used to avoid a C++17
dependency, which is no longer an issue), implement EncodableValue as a
std::variant. Rather than simply changing the internals, this makes EncodableValue
a minimal std::variant subclass with only a handful of added methodS, replacing
the old IsFoo/FooValue APIs with the standard std::holds_alternative/std::get,
so that plugin code will use a standard-based API rather than a Flutter-specific
API for wrapped values.

This is a breaking change for Windows and GLFW plugins. In the short
term USE_LEGACY_ENCODABLE_VALUE can be set in builds to use the old
version, to separate rolling from updating.

Fixes https://github.com/flutter/flutter/issues/61970
2020-08-04 08:53:07 -07:00
David Worsham
12a37478de
fuchsia: Remove dead code / break dependencies (#19396)
The fuchsia code around metrics and sizing was just sending this
information through a side-channel, when the engine already had the
information available. So, delete all of it to make future CLs simpler.

Additionally, the SceneUpdateContext has many unneccesary dependencies
re: metrics and PaintTasks. Break those to make future CLs simpler.

Tested: Ran all unittests and ran workstation on Fuchsia
BUG: 53062, 53063
2020-08-03 22:09:26 -07:00
Justin McCandless
11964ec300
Clipboard hasStrings method on iOS (#19859)
* Implement Clipboard hasStrings method on iOS

* Test call to hasStrings

* Formatting fixes

* Move test to its own file

* Alphabetical order

* Update licenses

* arguments nil instead of empty dictionary

* Guarantee hasStrings will be true when tested

* Formatting
2020-08-03 16:08:52 -07:00
DongXu
fa16c3d0ba
iOS external texture supports rendering NV12 pixelbuffer (#20082) 2020-08-03 11:20:45 -07:00
Chris Yang
02d71d60ef
Use a single mask view to clip iOS platform view (#20050) 2020-08-03 10:07:19 -07:00
Robert Ancell
083282e33b Fix Implments typo 2020-08-03 10:45:01 +12:00
Robert Ancell
8fbdd3f1bd Fix parameter names 2020-08-03 10:44:20 +12:00
Mehmet Fidanboylu
908fe012d9
Fix navigation message relay. (#20193) 2020-08-02 14:28:27 -07:00
Zachary Anderson
7dd092dd31
Enable more linting (#20187) 2020-07-31 21:30:58 -07:00
Greg Spencer
98cfd1db78
Move platform specific information to PlatformConfiguration class (#19652) 2020-07-31 17:21:02 -07:00
Justin McCandless
fcc1eaf8ff
Fix iOS Keyboard stuck as UIKeyboardTypeNamePhonePad (#20181)
P0 bug fix
2020-07-31 11:57:48 -07:00
Emmanuel Garcia
7f5d044f36
Wait before switching surfaces (#20100) 2020-07-30 20:36:01 -07:00
Jason Simmons
ee4d50cd07
Revert "Enable lazy-async-stacks by-default in all modes (2) (#19270)" (#20165)
This reverts commit 06fef5e36360e61a557fed546d12048427eb2340.
2020-07-30 18:34:51 -07:00
LongCatIsLooong
f2b02d8fd5
[iOS] Fixes text input plugin crash (#20127) 2020-07-30 11:32:49 -07:00
Daco Harkes
8e1d48eece
Migrate some Dart_WeakPersistentHandle uses to Dart_FinalizableHandle (#20107) 2020-07-30 15:56:00 +02:00
Todd Volkert
941c442b83
Add ALERT SoundType enum value (#20139)
https://github.com/flutter/flutter/issues/62143
2020-07-29 23:55:38 -07:00
Jason Simmons
8464208863
Add missing MouseCursorPlugin destroy call (#19968) 2020-07-29 17:01:04 -07:00
Yuqian Li
145ef60b96
Remove confusing logs (#20121)
Fixes https://github.com/flutter/flutter/issues/62468
2020-07-29 15:31:01 -07:00