* Don't call `PlatformViewCreatedCallback`s after `AndroidViewController` is disposed
Before this change it was possible that, if a `AndroidViewController` was disposed before we got the notification that the platform view was created, `PlatformViewCreatedCallback`s where called even after calling `AndroidViewController.dispose`.
Also makes `_PlatformViewLinkState._onPlatformViewCreated` more carful to only call `setState` when mounted.
Closes#84628Closes#96384
* Allow all widgets to remove listeners from controller
* Remove assert
* Add expectations to test
* Add support for extending selection to paragraph on ctrl + shift + arrow up/down for common keyboard actions
* Add ctrl + shift + arrow up/down common text editing shortcuts/actions
* fix analyzer
---------
Co-authored-by: Renzo Olivares <roliv@google.com>
* Make _focusDebug not interpolate in debug mode
* Add test
* Revert undesired change
* Fix test to fail before too
* Remove accidental skips
* Switch to using a generating closure for arguments.
* Remove a word
* Add support for image insertion on Android
* Fix checks
* Use proper Dart syntax on snippet
* Specify type annotation on list
* Fix nits, add some asserts, and improve example code
* Add missing import
* Fix nullsafety error
* Fix nullsafety error
* Remove reference to contentCommitMimeTypes in docs
* Fix nits
* Fix warnings and import
* Add test for content commit in editable_text_test.dart
* Check that URIs are equal in test
* Fix nits and rename functions / classes to be more self-explanatory
* Fix failing debugFillProperties tests
* Add empty implementation to `insertContent` in TextInputClient
* Tweak documentation slightly
* Improve docs for contentInsertionMimeTypes and fix assert
* Rework contentInsertionMimeType asserts
* Add test for onContentInserted example
* Switch implementation to a configuration class for more granularity in setting mime types
* Fix nits
* Improve docs and fix doc tests
* Fix more nits (LongCatIsLooong)
* Fix failing tests
* Make parameters (guaranteed by platform to be non-nullable) non-nullable
* Fix analysis issues
The default implementation returns EdgeInsets.zero, the ShapeDecoration subclass already makes it non-nullable, and there isn't any benefit to returning null as far as I can tell.
* attempt to extend to paragraph
* second attempt
* clean up implementation
* clean up
* updates
* updates
* Fix implementation
* remove old
* update docs
* update docs
* fix analyzer
* Fix bug where new line character was selected and backwards selection failed
* remove print
* Add test for paragraph boundary
* Add text editing test for extending selection to paragraph for mac and ios
* rename to ExtendSelectionToParagraphBoundaryIntent
* fix analyzer
* Should default to downstream when collapsing selection
* get rid of _getParagraphAtOffset and move into getTextBoundaryAt
* Search for all line terminators
* iterate through code units instead of characters
* Address some reviewer comments"
* Add separate implementations for leading and trailing paragraph boundary methods
* Do not break after a carriage return if it is followed by a line feed
* test carriage return followed by a line feed
* more tests
* Do not continue if the line terminator is at the target text offset
* add hack to extend highlight to line terminator
* Revert "add hack to extend highlight to line terminator"
This reverts commit b4d3c434539b66c3c81c215e87c645b425902825.
* Revert "Do not continue if the line terminator is at the target text offset"
This reverts commit 789e1b838e54e7c25600bfa8852e59431ccaf5dc.
* Update ParagraphBoundary with latest TextBoundary changes
* Update implementation to iterate through indexes
* update getTrailingTextBoundaryAt to include the line terminator
* Updates
* more updates
* more updates
* updates
* updates
* Lets try this again
* clean up
* updates
* more updates
* updates
* fix
* Re-implement using custom paragraph boundary applying method
* Revert "Re-implement using custom paragraph boundary applying method"
This reverts commit cd2f7f4b6eb6726b28f82a43708812e06a49df95.
* Revert "fix"
This reverts commit 8ec1f8f58935cfb3eb86dc6afd2894537af4cf7b.
* updates
* Revert "updates"
This reverts commit 9dcca4a0031fe18ada9d6ffbbe77ba09918e82ae.
* Revert "Revert "fix""
This reverts commit 9cc1332cd3041badc472d0d223a106203e46afb8.
* Revert "Revert "Re-implement using custom paragraph boundary applying method""
This reverts commit 1acb606fb743fd840da20cca26d9a7c26accb71d.
* Fix paragraph boundaries
* Add failing test
* Address some comments
* group tests and fix analyzer
* fix typo
* fix remaining test
* updates
* more fixes and logs
* clean up and add another test
* Fix last test
* Add new test
* Clean up
* more clean up
* clean up comments
* address comments
* updates
* return null when position is out of bounds and 0 or end of text if appropriate
* Clean up cases
* Do not return null when OOB in the direction of iteration
* clean up
* simplify implementation thanks to LongCatIsLooong feedback
* Address comments
* Add line and paragraph separator
* Use _moveBeyondTextBoundary instead of custom _moveToParagraphBoundary
* Change some intent names and revert fromPosition change
* clean up docs
---------
Co-authored-by: Renzo Olivares <roliv@google.com>
This updates the framework to provide higher level wrappers around ui.instantiateImageCodecWithSize(). Functionally, this doesn't change anything (other than deprecating the older loadBuffer() method in favor of loadImage()), but it sets the stage for a simpler change that will allow us to provide a more flexible way to load sized images.
#118543
* Rename _*Marker classes to be _*Scope, for consistency
* [EMPTY] Commit to refresh the tree that is currently red (#118062)
* Fix remaining tests
Co-authored-by: Drew Roen <102626803+drewroengoogle@users.noreply.github.com>
* DragTarget part 1.
[WIP] Change GestureRecognizer. Sorry.
[WIP] Move from GestureRecognizer to MultiDragGestureRecognizer.
Make it a `Set<int>?`
Get bitwise operations working.
Fix test. Rename to allowedInputPointers.
Convert into a builder.
Improve code with default funciton.
Refactor everything again.
Rename to buttonEventFilter.
Use static function.
Fix analyzer.
Fix private reference.
Use // in private method.
* Fix Renzo request.
* Add `allowedButtonsFilter` everywhere.
* Refactor monoDrag for multi pointer support.
* Fix tests?
* Change default to always true.
* Fix PR comments.
* Completely refactor long press.
* Add forgotten class.
* Revert "Completely refactor long press."
This reverts commit 5038e8603e250e8c928b0f1754fb794b7b75738b.
* Add default value to LongPress
* Refactor doubleTap.
* Relax double tap.
* Write comment in LongPress.
* Use template.
* allow focus to leave FlutterView
* fix tests and docs
* small doc update
* fix analysis lint
* use closed loop for dialogs
* add tests for new API
* address comments
* test FocusScopeNode.traversalEdgeBehavior setter; reverse wrap-around
* rename actionResult to invokeResult
* address comments
* Revert "Revert "Add support for double tap and drag for text selection (#109573)" (#117497)"
This reverts commit 39fa0117a919bd401c4c8734c97ddb46fbc45cb7.
* Allow TapAndDragGestureRecognizer to accept pointer events from any devices -- the TapGestureRecognizer it replaces was previously doing this
Co-authored-by: Renzo Olivares <roliv@google.com>