2644 Commits

Author SHA1 Message Date
Sanjay Chouksey
a67ecd536d Update view attributes after creation (flutter/engine#20638) 2020-08-22 12:46:04 -07:00
LI DONGZE
38ad113515 Reporting back native stacktrace to dart side for crash reporting. (flutter/engine#20280)
* Add native stacktrace on iOS

* Add native stacktrace on Android

* format and changing naming to errorWithCode on iOS

* reformat

* Remove stacktrace from decodeEnvelope, not needed.

* Separate encodeErrorEnvelopeWithStacktrace with original encode function

* Add unit tests

* re-format

* change comments for stacktrace

* Remove changes for iOS

Co-authored-by: Ben Li <libe@google.com>
2020-08-21 19:59:36 -07:00
Chris Yang
23e891ddc8 Enable ios platform view by default (flutter/engine#20671) 2020-08-20 17:46:01 -07:00
stuartmorgan
ab823bd15e [windows] Mostly eliminate the state structs (flutter/engine#20662)
The Windows embedding was based on the GLFW embedding, which grew
organically from a singe-file implementation that used structs to manage
all of the important state. It is in the process of being converted to a
cleaner object-based architecture, but currently it is a hybrid of
objects and structs that have redundant data, making it very prone to
errors of forgetting to update pointers in multiple locations.

This reduces the remaining structs to only a single pointer to the
larger object that manages the responsibilities that handle is
associated with, so that there is no need to wire things together in
multiple places.

For now they continue to exist as projections of the larger objects, but
that will be eliminated over time by having an object structure that
better reflects the API structure.

Fixes https://github.com/flutter/flutter/issues/64250
2020-08-20 16:50:06 -07:00
Kaushik Iska
2021143b42 All shape related structs are together (flutter/engine#20665) 2020-08-20 15:21:02 -07:00
stuartmorgan
f6ff52c644 Use references for C++ MethodResult and EventSink (flutter/engine#20651)
The response APIs for method channels and event channels used pointers
for optional parameters; this kept the API surface simple, but meant
that they couldn't take rvalues. As a result, returning success values
or error details often took an extra line, declaring a variable for the
result just to have something to pass the address of.

This converts them to using references, with function overloading to
allow for optional parameters, so that values can be inlined.

For now the pointer versions are still present, so that conversion can
be done before it becomes a breaking change; they will be removed soon.

Part of https://github.com/flutter/flutter/issues/63975
2020-08-20 15:10:28 -07:00
David Worsham
3a6e0d47c6 fuchsia: Convert legacy permutations to build flag (flutter/engine#20647) 2020-08-19 19:09:51 -07:00
James Clarke
a1d268a61b Fix flutter#40068 Redraw issues on resize/minimize/maximize on Windows and startup in release (flutter/engine#20357)
* Fix redraw issues

* Address CR feedback.

* Fix build

* CR feedback
2020-08-19 16:19:09 -07:00
Kaushik Iska
a8c392e6b8 [embedder] Add FBO callback that takes frame info (flutter/engine#20617) 2020-08-19 16:06:02 -07:00
Dan Field
5e03f90cdd fix build (flutter/engine#20644) 2020-08-19 14:35:45 -07:00
Jason Simmons
72dabb020d Release the AccessibilityBridge when destroying a legacy FlutterView (flutter/engine#20610) 2020-08-19 14:11:02 -07:00
chunhtai
df10c2b3b4 Missing default focus when navigating to a page with no SemanticsNode that sets namesRoute:true (flutter/engine#20516) 2020-08-19 14:06:03 -07:00
Dan Field
73490a2ca4 Hint freed (flutter/engine#19842)
* Hint the VM when a layer or picture goes out of scope
2020-08-19 14:04:31 -07:00
egdaniel
0ee7007d63 Remove use of ctors on Skia Vulkan struct (flutter/engine#20630)
Skia is removing the ctors on these structs so removing them.
2020-08-19 13:18:25 -04:00
Stas Parshin
fa3e19be27 Fix NPE in PlatformViewsController.checkInputConnectionProxy (flutter/engine#20622) 2020-08-19 08:34:04 -07:00
Chris Yang
72162b7a66 Ensure threads are merged when tearing down the Rasterizer (flutter/engine#19919) 2020-08-19 08:31:01 -07:00
stuartmorgan
bb04632eeb [windows] Allow delegation of top-level WindowProc (flutter/engine#20613)
Adds APIs for runners to delegate WindowProc handlers into the Flutter
engine, and for plugins to register as possible delegates.

This allows for plugins to alter top-level window behavior in ways that
can only be done from the WindowProc, such as resize control. This
functionality remains entirely on the native side, so is synchronous.

Part of https://github.com/flutter/flutter/issues/53168
2020-08-19 06:49:39 -07:00
David Worsham
8b4e07c198 fuchsia: Increase timeout for flaky test (flutter/engine#20606) 2020-08-18 17:14:30 -07:00
Chase Latta
5f7105f763 convert zircon and fuchsia to null-safety (flutter/engine#20577) 2020-08-18 13:15:00 -07:00
Emmanuel Garcia
a2732e0538 Reland: Create PlatformView instance right after method channel call from Dart (flutter/engine#20568) 2020-08-17 16:28:15 -07:00
gaaclarke
9ef815d6dc Revert "Create PlatformView instance right after method channel call from Dart (#20500)" (flutter/engine#20564)
This reverts commit a87eaedcc22c1b96065222cdf6a05fe32c0b09f0.
2020-08-17 11:17:03 -07:00
stuartmorgan
85ffc9bb19 Send locale information in the Windows embedding (flutter/engine#20455)
Queries the system list of user-preferred languages, and sends it to the
engine just after starting it up.

Windows portion of https://github.com/flutter/flutter/issues/45152
2020-08-17 05:46:39 -07:00
stuartmorgan
67cf6c312c [windows] Expose the binary messenger from FlutterEngine (flutter/engine#20551)
Relands https://github.com/flutter/engine/pull/20399

Makes BinaryMessenger available from FlutterEngine, rather than just the plugin registrar. This allows for method channels directly in applications without building them as plugins, and matches the other platforms.

Requires some restructuring of code and GN targets in the client wrappers to make the internals in the shared section usable by the implementations of platform-specific parts of the wrappers. Also fixes a latent issue with EnableInputBlocking symbols being declared but not defined for Windows that came up during testing of the restructing.

Fixes https://github.com/flutter/flutter/issues/62871
2020-08-17 05:44:48 -07:00
Mehmet Fidanboylu
fd10b885d8 Enable iOS plumbing for network security and add tests (flutter/engine#20492) 2020-08-16 21:20:26 -07:00
stuartmorgan
02796951ef Revert "[windows] Expose the binary messenger from FlutterEngine (#20399)" (flutter/engine#20550)
This reverts commit f69ea6f127181cb5578a3de58f96a58e183e4cdf.
2020-08-16 14:49:19 -07:00
stuartmorgan
f69ea6f127 [windows] Expose the binary messenger from FlutterEngine (flutter/engine#20399)
Makes BinaryMessenger available from FlutterEngine, rather than just the plugin registrar. This allows for method channels directly in applications without building them as plugins, and matches the other platforms.

Requires some restructuring of code and GN targets in the client wrappers to make the internals in the shared section usable by the implementations of platform-specific parts of the wrappers. Also fixes a latent issue with EnableInputBlocking symbols being declared but not defined for Windows that came up during testing of the restructuring.

Fixes https://github.com/flutter/flutter/issues/62871
2020-08-16 14:28:57 -07:00
Chris Yang
e6ebeb9e68 Only create raster_thread_merge when explicitly requested by the embedding platform (flutter/engine#20487) 2020-08-16 10:31:01 -07:00
gaaclarke
df17cc6ccf Started stubbing in the FlutterView property of the mock (flutter/engine#20542)
FlutterViewControllers.
2020-08-15 21:03:20 -07:00
David Worsham
ad2bff1014 Reland: "fuchsia: Remove dead code / break dependencies" (flutter/engine#20532)
Reland #19396 with a fix for improper scale that was affecting internal tests

Tested: Ran all unittests, ran internal tests, and ran workstation on Fuchsia
BUG: 53062, 53063
2020-08-14 20:41:18 -07:00
Emmanuel Garcia
a87eaedcc2 Create PlatformView instance right after method channel call from Dart (flutter/engine#20500) 2020-08-14 15:06:02 -07:00
Diego Ballesteros Villamizar
4ba82d4d91 Handle glfwGetPrimaryMonitor returning nullptr (flutter/engine#20523)
* Handle glfwGetPrimaryMonitor returning nullptr

[glfwGetPrimaryMonitor](https://www.glfw.org/docs/3.3/group__monitor.html#ga721867d84c6d18d6790d64d2847ca0b1) may return NULL in non-error cases when no monitor is found. This started to happen recently with an update to the linux distribution, see internal b/162545223.

Handling this case avoids a crash and instead assumes a pixel density.
2020-08-14 23:03:50 +02:00
gaaclarke
6ac18e9203 Fixed the accessibility ios unit tests by sending in mock view (flutter/engine#20522)
controllers instead of views.
2020-08-14 10:42:21 -07:00
Justin McCandless
1fec9ca767 hasStrings on Android (flutter/engine#20393)
hasStrings message for checking for pasteable clipboard contents without actually reading them, for iOS14 clipboard alerts.
2020-08-14 08:45:18 -07:00
stuartmorgan
7e9b115eeb Fix the legacy EncodableValue codepaths (flutter/engine#20501)
A recent refactoring broke the USE_LEGACY_ENCODABLE_VALUE codepath in
standard_codec.cc, which went unnoticed since it wasn't being compiled.
This fixes the breakage, and also adds a temporary minimal unit test
target that ensures that all the USE_LEGACY_ENCODABLE_VALUE paths are
being compiled.
2020-08-13 23:02:20 -07:00
Jia Hao
89e5cf3dba Add missing nullable annotation (flutter/engine#20505) 2020-08-13 22:41:01 -07:00
Yuqian Li
4dec444c69 Add a service protocol for raster cache memory (flutter/engine#20466)
Related issue: https://github.com/flutter/flutter/issues/56719
2020-08-13 20:11:47 -07:00
David Worsham
877ae98e08 Fix unoptimized fuchsia builds (flutter/engine#20488) 2020-08-13 16:12:04 -07:00
Dan Field
b43d17a5a3 Remove the dummy rasterizer delegate now that flutter_runner is in tree, and cleanup ctor params (flutter/engine#20486) 2020-08-13 14:46:01 -07:00
xster
5ac78f5be6 Refactor initial route code take 2 (flutter/engine#20468) 2020-08-13 14:18:11 -07:00
Mehmet Fidanboylu
0f611fe4b7 Plumbing for setting domain network policy (flutter/engine#20218) 2020-08-13 07:26:43 -07:00
stuartmorgan
3d63be5265 Send locale information in the macOS embedding (flutter/engine#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
a001fb98a7 Fix broken symbols on Fuchsia embedder (flutter/engine#20459)
See: b/163653659
2020-08-12 19:06:22 -07:00
David Worsham
6d6047204d Add --unoptimied and --asan to Fuchsia builds (flutter/engine#20427) 2020-08-12 14:47:55 -07:00
gaaclarke
232d6c4fca Revert "Refactor initial route code (#19684)" (flutter/engine#20450)
This reverts commit 21404b56c6c183a829d9c758bec2330155e2d86d.
2020-08-12 12:43:08 -07:00
xster
21404b56c6 Refactor initial route code (flutter/engine#19684) 2020-08-11 19:52:04 -07:00
stuartmorgan
08a585be33 Add missing reply in C++ MethodChannel unit test (flutter/engine#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
4e60afdf2a Fix broken shell_unittests on Fuchsia (flutter/engine#20422)
Fixes https://github.com/flutter/flutter/issues/53399
2020-08-11 17:31:25 -07:00
stuartmorgan
916b06e657 Add virtual destructors to ByteStream* (flutter/engine#20417) 2020-08-11 14:39:14 -07:00
Dan Field
8c0b89b1f4 Use performDeferredCleanup instead of freeGpuResources (flutter/engine#20413) 2020-08-11 14:01:01 -07:00
stuartmorgan
bfeb4ed5a4 Fix RTTI check in EncodableValue (flutter/engine#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