4367 Commits

Author SHA1 Message Date
godofredoc
de593702de Add gen_snapshot to flutter_gtk. (flutter/engine#34287) 2022-06-27 17:00:06 +00:00
Xilai Zhang
9bbaf6212e [gn] use generated_files to encode entitlement information (flutter/engine#34216)
* generated_files

* for debugging push

* format files

* formate files

* trigger build

* add deps
2022-06-27 09:09:29 -07:00
J-P Nurmi
4eb93fed5a Fix build on Linux (flutter/engine#34312)
* Fix build on Linux

The MockBinaryMessenger tweaks applied by #33955 caused the newly added
tests in #33313 to not build.

* Fix clang-tidy failures
2022-06-27 08:03:37 -07:00
J-P Nurmi
433ac149bf [Linux][A11y] implement AtkEditableText interface (flutter/engine#33955)
* Make FlAccessibleNode derivable

This allows introducing specialized subclasses that implement such a11y
interfaces as AtkEditableText that should not be implemented for the
generic node.

* FlAccessibleNode: add set value, text selection & perform action

Prepare API required for the upcoming AtkEditableText implementation.

* FlViewAccessible: postpone child node creation

This changes the a11y node creation flow so that (unknown) child nodes
are not pre-created when their parent is updated but "pending" child
node IDs are collected for later. Parent-child relationships are
established at the end of update batches when all nodes have been
created.

* Add FlAccessibleTextField that implements AtkEditableText

Solves: flutter/flutter#103191
2022-06-27 10:11:40 +12:00
J-P Nurmi
514b0a43b8 [Linux][A11y] report disabled animations and high contrast accessibility features (flutter/engine#33313)
* FlEngine: add fl_engine_update_accessibility_features()
* FlSettings: add API for high-contrast & animations
* FlEngine: allow passing mock messenger at construction time
* FlSettingsPlugin: report accessibility features
2022-06-27 10:10:55 +12:00
Dan Field
3724bc6427 Implement toGpuImage, a synchronous, GPU-resident version of (flutter/engine#33736)
* Implement toGpuImage, a synchronous, GPU-resident version of
Picture.toImage.

This method kicks off asynchronous work on the raster task runner.
If it fails to rasterize, it will synchronously throw later when
the user attempts to draw to a canvas.

This supports several use cases:

- Quickly snapping off an expensive-to-rasterize image for reuse
  across multiple frames.
- Applying multi-pass filters to a render target.

This patch amends flutter_tester so that it can produce an image
object, but that image will always be a grey and white four square checkerboard.

Adds support for CanvasKit on Web, which basically already used
this method for its Picture.toImage implementation.

Throws an UnsupportedError for HTML on Web, since any implementation
there would almost certainly be slower than drawPicture.
2022-06-24 16:14:42 -07:00
Tong Mu
781a8e9e01 [Windows, Keyboard] Enqueue keyboard message (flutter/engine#34222) 2022-06-24 23:10:05 +00:00
J-P Nurmi
d79e1196c9 [Linux] remove duplicate clone_string() in favor of g_strdup() (flutter/engine#34031)
GLib's g_strdup() offers the same behavior that it returns NULL if the
argument is NULL: https://docs.gtk.org/glib/func.strdup.html
2022-06-24 12:24:33 -07:00
LongCatIsLooong
f879594eca Clean up text input configuration in clearTextInputClient (flutter/engine#34209) 2022-06-24 18:39:05 +00:00
Tong Mu
ee0e8303fb [Keyboard] Mark generated file names with infix .g. (flutter/engine#34123)
* Impl

* Format
2022-06-23 20:02:33 -07:00
LongCatIsLooong
185bdbb637 [Android Autofill] Don't set autofillHints to an empty array when there's no autofillhints (flutter/engine#34203) 2022-06-24 01:13:07 +00:00
Dan Field
f7163f555c Roll SwiftShader, ANGLE, use SwANGLE in test harnesses (flutter/engine#33814)
Roll Swiftshader, ANGLE, and Vulkan deps.

Updates license bot for new locations of licenses and new files
in roll.

Converts unit test harnesses to use SwANGLE, which is the
supported way of using SwiftShader as a software backend for GLES.

Updates goldens due to swiftshader changes.

Fixes up include paths to avoid directly including third_party
code by that name, which is unlikely to work in other build
environments.

Includes upstream patches to ANGLE and SwiftShader to build in our
windows environments, as well as patches to Skia to support
defining the location of VulkanMemoryAllocator and a patch to ANGLE
to support opting into a newer version of VMA.
2022-06-23 16:43:39 -07:00
Jason Simmons
07873d4e21 Delete local JNI references created within AndroidImageGenerator::DoDecodeImage (flutter/engine#34148) 2022-06-23 23:15:04 +00:00
Jason Simmons
729cd3e4a9 Revert "Bump Robolectric to 4.8.1 (#33024)" (flutter/engine#34263)
This reverts commit aaa190f63293b61c0579642a4e979221bf6c5ba1.
2022-06-23 15:29:57 -07:00
Jason Simmons
1243cc12c6 Add a null check to AndroidImageGenerator::GetPixels (flutter/engine#34149) 2022-06-23 20:39:04 +00:00
utzcoz
aaa190f632 Bump Robolectric to 4.8.1 (flutter/engine#33024) 2022-06-23 20:27:05 +00:00
Alex Wood
8269c91886 [MacOS] Accept first mouse-down (flutter/engine#34093) 2022-06-23 20:21:04 +00:00
Emmanuel Garcia
135a1c8e56 Handle SurfaceView in a VirtualDisplay (flutter/engine#33599) 2022-06-22 19:39:05 -07:00
Dan Field
0586f7b588 Drop --enable-display-list flag, remove associated branched code (flutter/engine#34233) 2022-06-23 00:07:04 +00:00
Chinmay Garde
0aa7b3495f [Impeller] Log a message when using Impeller. (flutter/engine#34242) 2022-06-22 16:59:07 -07:00
Chinmay Garde
20def47959 Remove unactionable verbose log about ignored viewport metrics. (flutter/engine#34231) 2022-06-22 12:34:06 -07:00
Jonah Williams
a184d04005 cleanup fractional translation ifdefs and config (flutter/engine#34198) 2022-06-22 09:00:57 -07:00
Tong Mu
869b09b201 [Keyboard] Update generated key codes (flutter/engine#34125)
* Impl

* Remove logical plane

* Revert "Remove logical plane"

This reverts commit a422c425d9c15a0d6576d1dfb5c0faab22038523.
2022-06-21 18:25:26 -07:00
Tong Mu
5de64c88b0 [Keyboard, Android] Mint physical keys on the Android plane (flutter/engine#34122) 2022-06-21 13:14:33 -07:00
Chris Bracken
53a9648da9 [lint] Merge impeller .clang-tidy into main config (flutter/engine#33692)
Merges most (but not all) of the impeller .clang-tidy rules into the
main .clang-tidy config. Merges:

readability-identifier-naming.PrivateMemberSuffix (_)
readability-identifier-naming.EnumConstantPrefix (k)
modernize-use-default-member-init.UseAssignment
Does not merge:

readability-identifier-naming.PublicMethodCase (CamelCase)
readability-identifier-naming.PrivateMethodCase (CamelCase)
These last two are not merged due to the non-trivial number of existing
field accessors that use field_name() methods to directly return
field_name_. While these are permitted by the C++ style guide, we may
want to move to a single, simple rule and name everything in CamelCase.
These can be enabled in a followup patch.

No new tests added, since this change is style-only.
2022-06-21 11:52:42 -07:00
J-P Nurmi
b7bfa342dd [Linux] Test text input (flutter/engine#34186)
This PR finishes what #33661 and #33111 started - most of `FlTextInputPlugin` is now covered by tests.
2022-06-21 10:03:30 -07:00
J-P Nurmi
024fd472b8 [Linux][Testing] reduce the boilerplate for MockBinaryMessenger (flutter/engine#34029)
Let MockBinaryMessenger internally manage the FlBinaryMessenger wrapper
instance and provide it via operator FlBinaryMessenger*() to avoid
having to create two objects in every test. The same technique was used
for MockSettings in #32618.
2022-06-21 09:07:05 +12:00
godofredoc
5e932a2524 Fixes for gn artifacts. (flutter/engine#34152) 2022-06-18 04:23:04 +00:00
toneyzeng
df87bef96d [android] Fix leak of bitmap object (android.graphics.Bitmap of Java) while using platform image decoder. (flutter/engine#33953) 2022-06-17 19:22:05 +00:00
godofredoc
d1e9f3570d Move flutter_patched_sdk to the correct location. (flutter/engine#34128) 2022-06-17 19:18:03 +00:00
Tong Mu
611b633ff4 [Windows, Keyboard] Fix crash on Up-only IME event (flutter/engine#33746)
* Impl and test

* Format and some doc

* Rewrite algorithm

* Format

* Simplify

* Fix

* Fix params
2022-06-16 16:13:55 -07:00
Matej Knopp
2c189a40f4 [macos] [NSViewController viewWillAppear] can be called multiple times (flutter/engine#34072)
Fixes https://github.com/flutter/flutter/issues/105963
2022-06-16 13:52:19 -07:00
Alexander Brusher
c73e679ebf [fuchsia][a11y] Set explicit hit regions per compositor layer on GFX. (flutter/engine#33852) 2022-06-16 11:28:00 -07:00
Callum Moffat
072058b4fe Reland "ChromeOS/Android trackpad gestures" (flutter/engine#34060)
* Android trackpad gestures

* Try to fix lint problem
2022-06-15 17:34:51 -07:00
Chris Yang
edad53fa5e iOS: Remove a11y workaround that disables the a11y when app is resigned. (flutter/engine#34086) 2022-06-15 20:38:04 +00:00
Chris Yang
ef9fb575ad iOS Accessibility: during layout change, only specify the focus object when it is changed. (flutter/engine#33972) 2022-06-15 10:08:05 -07:00
Matej Knopp
651843b2da [macOS] Put FlutterTextInputPlugin in view hierarchy (flutter/engine#33827) 2022-06-15 12:11:36 +02:00
Emmanuel Garcia
a01c2201b5 Reland: Re-enable scenario tests on Android (flutter/engine#34048) 2022-06-14 21:03:04 -07:00
Tong Mu
02e21614cc Revert "ChromeOS/Android trackpad gestures (#31595)" (flutter/engine#34046) 2022-06-14 14:18:56 -07:00
Emmanuel Garcia
f99e4563b9 Prevent TalkBack from announcing view in non-virtual a11y hierarchies (flutter/engine#34017) 2022-06-14 12:03:05 -07:00
Callum Moffat
20d8f266ac iPad trackpad gestures (flutter/engine#31591) 2022-06-13 20:48:04 -07:00
Chinmay Garde
16731be1a7 [Impeller] Allow for the specification of pipeline stage information at runtime. (flutter/engine#33882)
Towards implementing the FragmentProgram API in Impeller.

Specifies an Impeller specific format for data the renderer can use to create
pipelines with user supplied shader stages at runtime.

The data is in the form of a flatbuffer with a known schema.

This patch implements the wire format, creating and loading the program
payloads, and creating pipeline state objects using these payloads.

If the user supplied SPIRV intended for the older API, the loader will reject
this invalid payload. This is probably not going to be too much of an issue
because the FragmentProgram API will probably be modified to only allow buffers
loaded from asset managers. But still, in the meantime, I am using the old API
to pass these new buffers.

Fixes https://github.com/flutter/flutter/issues/104750
Fixes https://github.com/flutter/flutter/issues/105542
Towards resolving https://github.com/flutter/flutter/issues/102853
2022-06-13 18:33:00 -07:00
Callum Moffat
0720db98cc ChromeOS/Android trackpad gestures (flutter/engine#31595) 2022-06-13 17:03:04 -07:00
Jonah Williams
728640769b dont pixel snap raster cache if SUPPORT_FRACTIONAL_TRANSLATION is enabled (flutter/engine#34002) 2022-06-13 16:43:05 -07:00
Emircan Uysaler
7e533dc3cb [fuchsia] Remove to be deprecated pixel_scale field (flutter/engine#33932)
Bug: https://bugs.fuchsia.dev/p/fuchsia/issues/detail?id=102163
2022-06-13 11:30:27 -04:00
Rulong Chen(陈汝龙)
e915cd6a6b [android] Fixes 'drawRenderNode called on a context with no surface' crash (flutter/engine#33655) 2022-06-13 03:58:05 -07:00
Alexander Biggs
581afe50aa [fuchsia] Stop unimplemented TextInput from log spamming. (flutter/engine#33811) 2022-06-11 12:43:05 -07:00
J-P Nurmi
f7d46e29c2 [Linux] take first steps towards testable text input (flutter/engine#33661)
This PR is a continuation of #33111 and includes necessary changes to test the `TextInputType.setClient()` platform channel call. Testing the actual text input flow requires a mock IM context that will follow in a separate PR.

* [Linux] pass GdkWindow instead of FlView to FlTextInputPlugin
* [Linux] add MockBinaryMessenger::ReceiveMessage()
* [Linux] add test for TextInputType.setClient
* Drop the offscreen window

GdkOffscreenWindow requires display & screen which is a problem in
headless mode. Luckily, we don't really need a window instance in tests
because its only passed as a client window to the IM context which will
be mocked out when we get to tests that depend on it.
2022-06-10 11:17:22 -07:00
Alexander Markov
8292927857 Remove uses of --lazy-async-stack Dart VM flag (flutter/engine#33964) 2022-06-10 10:12:56 -07:00
Camille Simon
af20f79b0e Stop sending text to framework (flutter/engine#33892) 2022-06-08 17:13:01 -07:00