- 13 10月, 2020 2 次提交
-
-
由 Chris Bracken 提交于
Extracts a TextRange class with a base and extent, and start(), end(), collapsed(), and length() getters. The possibility of reversed base and extent in selections and composing ranges makes reasoning about them complex and increases the chances of errors in the code. This change migrates most uses of base and extent in the text model to start()/end() or position(). The position() method is intended purely as an aid to readability to indicate that a collapsed selection is expected at the call site; it also enforces a debug-time assertion that this is the case.
- 10 10月, 2020 5 次提交
-
-
由 gaaclarke 提交于
-
由 Alexander Markov 提交于
-
由 Greg Spencer 提交于
This is a PR for converting the dart:ui code in the engine to use a multi-window API. The goal here is to convert from the window singleton to an API that has the concept of multiple windows. Also, I'm matching up the new PlatformDispatcher class to talk directly to the PlatformConfiguration class in the engine. I'm not attempting to actually enable creating multiple windows here, just migrate to an API that has a concept of multiple windows. The multi-window API in this PR currently only ever creates one window. The design doc for this change is here. The major changes in this PR: Move the platfom-specific attributes out of Window, and into the new PlatformDispatcher class that holds all of the platform state, so that the platform code need only update the configuration on this class. Create FlutterView, FlutterWindow, and SingletonFlutterWindow classes to separate out the concepts of a view (of which there may be multiple in a window), a window (of which there may be multiple on a screen, and they host views), and a window where there is only ever expected to be one (this hosts the entire API of the former Window class, and will eventually be the type of the window singleton). Next step after this PR lands: Remove the Window class entirely (it is replaced by SingletonFlutterWindow). Some minor changes in the Framework are needed to switch to using SingletonFlutterWindow directly first. The Window class still exists in this PR, but will be removed as soon as the framework is converted to point to the SingletonFlutterWindow class instead. They share the same API, just have different names (Window is currently a subclass of SingletonFlutterWindow). The intention is that the Window name will be freed up to use as a widget class name in the framework for managing windows. The singleton called window will remain, and keep the same API it has now.
-
由 George Wright 提交于
-
由 Kaushik Iska 提交于
-
- 09 10月, 2020 8 次提交
-
-
由 Chris Bracken 提交于
At every call site for TextInputModel::DeleteSelected, we perform a check for a collapsed selection. This moves that check into the method itself.
-
由 Dan Field 提交于
-
由 J-P Nurmi 提交于
Fix lint issues caused by `google-readability-braces-around-statements`.
-
由 Hamdi Kahloun 提交于
Fix `java.lang.SecurityException: Permission Denial: reading com.android.providers.media.MediaProvider` Fixes flutter/flutter#66108 Co-authored-by: NDan Field <dfield@gmail.com>
-
由 Kaushik Iska 提交于
-
由 Kaushik Iska 提交于
-
由 Jason Simmons 提交于
-
由 Jonah Williams 提交于
Preserve specified AssetResolvers when performing a hot restart or updating the asset directory (#21611) Follow up from #21436 . That PR works for all embeddings except for Android, which creates a special JNI AssetResolver. Since the shell cannot recreate this resolver, update the logic to preserve existing resolvers instead.
-
- 08 10月, 2020 8 次提交
-
-
由 Dan Field 提交于
-
由 Chris Bracken 提交于
Neither of these methods mutate the state of the model.
-
由 Chris Bracken 提交于
Previously, the selection base and extent were stored internally as iterators over text_. Since iterators must be treated as invalidated whenever the underlying container changes, this requires that selection_base_ and selection_extent_ be re-assigned after every change to text_. This is not currently particularly problematic, but once we add fields to track the base and extent of the composing region for multi-step input method support, as well as support for the sub-range within the composing region to which edits/completions apply, we end up having to regenerate a lot of iterators with each change, many of which are logically unchanged in position. A side benefit is that this simplifies inspection of these fields when debugging.
-
由 Chinmay Garde 提交于
-
由 Pieter van Loon 提交于
-
由 Emmanuel Garcia 提交于
-
由 Kaushik Iska 提交于
-
由 Kaushik Iska 提交于
-
- 07 10月, 2020 4 次提交
-
-
由 David Worsham 提交于
-
由 Justin McCandless 提交于
hasStrings method for clipboard status, Linux
-
由 stuartmorgan 提交于
Adds the ability to pass engine switches temporarily at runtime via environment variables. Uses the same approach recently added to Windows and macOS. This is enabled only for debug/profile to avoid potential issues with tampering with released applications, but if there is a need for that in the future it could be added (potentially with a whitelist, as is currently used for Dart VM flags). Fixes flutter/flutter#60393
-
由 Chris Bracken 提交于
Previously, TextInputModel's SetEditingState method was a 1:1 mapping of the underlying protocol used on the text input channel between the framework and the engine. This breaks it up into two methods, which allows the selection to be updated independently of the text, and avoids tying the API the the underlying protocol. This will become more important when we add additional state to support composing regions for multi-step input methods such as those used for Japanese. SetText resets the selection rather than making a best-efforts attempt to preserve it. This choice was primarily to keep the code simple and make the API easier to reason about. An alternative would have been to make a best-effort attempt to preserve the selection, potentially clamping one or both to the end of the new string. In all cases where an embedder resets the string, it is expected that they also have the selection, so can call SetSelection with an updated selection if needed.
-
- 06 10月, 2020 2 次提交
-
-
由 Sanjay Chouksey 提交于
This change adds support for forwarding scenic's viewConnected, viewDisconnected and viewStateChanged events to flutter. The corrensponding change on fuchsia side is at: https://fuchsia-review.googlesource.com/c/topaz/+/434356 Test: Includes unittest to verify the events are forwarded. Co-authored-by: NSanjay Chouksey <sanjayc@google.com>
-
由 LongCatIsLooong 提交于
-
- 03 10月, 2020 5 次提交
-
-
由 Chris Yang 提交于
-
由 Sanjay Chouksey 提交于
This change adds a response to the platform view message: requestFocus This allows the caller to handle the case when the request fails with an error value. Co-authored-by: NSanjay Chouksey <sanjayc@google.com>
-
由 Justin McCandless 提交于
Fixes an infinite loop by eliminating an unnecessary engine/framework message.
-
由 Jason Simmons 提交于
-
由 Jason Simmons 提交于
Extract the WindowInsetsAnimation.Callback subclass into a separate class that will be lazily loaded (#21548) WindowInsetsAnimation.Callback was introduced in API level 30. This PR moves the text input plugin's WindowInsetsAnimation.Callback subclass into a class that will only be loaded if the embedding has checked for a sufficient API level. See https://github.com/flutter/flutter/issues/66908
-
- 02 10月, 2020 2 次提交
-
-
由 David Worsham 提交于
-
由 Yilong Li 提交于
When Flutter engine connects to Scenic, Scenic has already checked the display and graphics device availability before Scenic starts; so it is guaranteed that display devices are available and surface is valid when it is created. Thus this change removes the device watching details from flutter surface on Fuchsia so that it doesn't need to do duplicated checks and hides the device-specific details.
-
- 01 10月, 2020 2 次提交
-
-
由 stuartmorgan 提交于
The Windows and GLFW embeddings both had cases of missing returns after calling `Error` on a method channel result object, leading to incorrect double-calls on the result if the error paths were ever hit.
-
- 30 9月, 2020 2 次提交
-
-
由 Felipe Archondo 提交于
-
由 Greg Spencer 提交于
Use dispatchKeyEventPreIme, and handle keys sent to InputConnection.sendKeyEvent on Android (#21163) This switches from using dispatchKeyEvent to using dispatchKeyEventPreIme so that keys can be intercepted before they reach the IME and be handled by the framework. It also now intercepts key events sent to InputConnection.sendKeyEvent, as some IMEs do (e.g. the Hacker's Keyboard), and sends the to Flutter before sending them to the IME (which it now only does if they are not handled by the framework). This fixes the problem where pressing TAB on a hardware keyboard sends the tab to both the text field and to the focus traversal system. Note that we still can't intercept all keystrokes given to a soft keyboard, only those which the soft keyboard decides to send to InputConnection.sendKeyEvent.
-