102 Commits

Author SHA1 Message Date
gaaclarke
18713e0c5d
Made Directionality forego dependency tracking for better performance. (#102336) 2022-04-25 15:39:05 -07:00
Michael Goderbauer
51bcdb9407
super parameters for framework (#100905) 2022-04-13 22:38:40 -07:00
Ian Hickson
ab89ce285f
Clean up the bindings APIs. (#89451) 2022-02-03 14:55:15 -08:00
chunhtai
28ca7bd789
Allow current leader of layerlink to detach before the previous leade… (#96810) 2022-01-24 11:50:11 -08:00
Jonah Williams
dafda50c6a
[framework] remove hashcode override for Element (#96644) 2022-01-14 15:45:18 -08:00
Anis Alibegić
a753d09cc9
Fixed several typos (#89485) 2021-09-07 14:56:04 -07:00
Darren Austin
e2fb5cc318
Updated skipped tests for widgets directory. (#87879) 2021-08-09 15:05:44 -07:00
Ren You
3dea9f0251
Revert "Clean up the bindings APIs (#86438)" (#86484)
This reverts commit d056500bfe6a712cdace450d06c4a8fb2290e63a.
2021-07-15 09:29:16 -07:00
Ian Hickson
d056500bfe
Clean up the bindings APIs (#86438) 2021-07-14 14:41:24 -07:00
Zachary Anderson
7f741e9181
Revert "Clean up the bindings APIs (#86388)" (#86404)
This reverts commit 31de052e3fddb4909ff88172a6937db7f3dc49db.
2021-07-13 21:32:29 -07:00
Ian Hickson
31de052e3f
Clean up the bindings APIs (#86388) 2021-07-13 18:31:11 -07:00
Ian Hickson
c800b9c3e4
Revert "Clean up the bindings APIs (#83843)" (#86386)
This reverts commit e2490f2906060d0aaecbbe34a9240ca3d54ef998.
2021-07-13 15:47:40 -07:00
Ian Hickson
e2490f2906
Clean up the bindings APIs (#83843) 2021-07-13 12:41:03 -07:00
Ahmed Ashour
a3dc90c4f5
Add space before curly parentheses. (#85306) 2021-07-01 13:51:05 -07:00
Greg Spencer
1ac209c222
Turn on avoid_dynamic_calls lint, make appropriate changes. (#84478) 2021-06-23 16:36:03 -07:00
Dan Field
c1fe2bd1e0
Reland "Dispose render objects when owning element is unmounted. (#82883)" (#83790) (#83920) 2021-06-07 18:39:02 -07:00
Dan Field
bcc8f083a2
Forbid calling findRenderObject on an unmounted element (#83962) 2021-06-07 16:37:55 -07:00
Ren You
63c49c3d83
Revert "Dispose render objects when owning element is unmounted. (#82883)" (#83790)
This reverts commit c75edc268ca336c66a103f1c0d82c4dff140fca0.
2021-06-02 07:54:19 -07:00
Dan Field
c75edc268c
Dispose render objects when owning element is unmounted. (#82883) 2021-06-01 22:29:02 -07:00
Michael Goderbauer
7b9a175557
Assert when duplicated keys are introduced in subsequent build (#81850) (#82201) 2021-05-11 09:41:02 -07:00
Michael Goderbauer
b8a2456737
Enable library_private_types_in_public_api lint (#81578) 2021-05-10 16:26:16 -07:00
Hans Muller
dbc8826816
Revert "Assert when duplicated keys are introduced in subsequent build (#81850)" (#82039)
This reverts commit 3ab799bbc934e5f6d032557cdcb1486ce6b93c4b.
2021-05-07 10:19:47 -07:00
Michael Goderbauer
3ab799bbc9
Assert when duplicated keys are introduced in subsequent build (#81850) 2021-05-06 19:49:02 -07:00
Todd Volkert
efc079657b
Allow reuse of NavigatorObserver in Navigator.observers (#81601) 2021-05-06 19:39:03 -07:00
Alexandre Ardhuin
1a3af88ced
add missing trailing commas (#81362) 2021-04-28 10:54:05 -07:00
Phil Quitslund
61c30c41b2
fix sort_directives violations (#80817) 2021-04-21 13:49:03 -07:00
Michael Goderbauer
ac8e1f8fc4
Reduce severity of memory leak when BuildContext/Element is retained (#79957) 2021-04-08 15:49:02 -07:00
Alexandre Ardhuin
8de7020a5f
remove unnecessary trailing commas (#79562) 2021-04-01 21:52:35 +02:00
Tong Mu
c4ba26e31b
Revert "Let InkWell/Ink/ancestor support GlobalKey so that splash does not stop when changing position. (#71138)" (#79300)
This reverts commit e7266dbb079d31fff0f886518c6a1b25bf89bb94.
2021-03-29 13:12:18 -07:00
YeungKC
e7266dbb07
Let InkWell/Ink/ancestor support GlobalKey so that splash does not stop when changing position. (#71138) 2021-03-26 19:39:01 -07:00
xubaolin
74eb9df21a
Check if MultiChildRenderObjectElement has an associated RO (#78854) 2021-03-25 19:29:03 -07:00
Michael Goderbauer
ed755fba5e
Enable avoid_unnecessary_containers lint (#77294) 2021-03-04 15:29:03 -08:00
Greg Spencer
c6ef4c75d9
Turn on sized_box_for_whitespace lint, fix instances. (#77099) 2021-03-03 17:29:02 -08:00
Michael Goderbauer
0f568298d8
enable use_key_in_widget_constructors lint (#77032) 2021-03-02 10:14:02 -08:00
Sam Rawlins
d69845b17f
Remove "unnecessary" imports in test/widgets (#75949) 2021-02-16 13:56:04 -08:00
Todd Volkert
835c7fab45
Fix FocusManager constructor (#75894)
The FocusManager constructor was registering global event handlers
on the shared RawKeyboard instance and the global pointer router.
This posed a few problems: (1) there was no way to unregister these
handlers, and (2) instantiating a second FocusManager would overwrite
the existing focus manager's RawKeyboard handler. This was manifesting
in unexpected ways, such as the fact that constructing a second
BuildOwner (for a parallel tree, for instance) was obliterating the
event handler for the main BuildOwner's focus manager, thus messing
with focus.

This change separates those global event registrations into a
dedicated method, registerGlobalHandlers(), and overrides dispose()
to properly unregister those handlers.
2021-02-12 17:19:20 -08:00
Todd Volkert
5584fce36e
Switch global key registry to be owned by the build owner. (#74701)
This gets away from the extra static map for global key registrations
in favor of the data structures being instance properties of the build
owner. This still allows for semantically-equivalent static access through
the binding (which in turn gives access to the build owner).

This also adds a `BuildOwner.globalKeyCount` getter to get the count
of global keys associated with widgets currently in the tree.
2021-01-26 14:28:58 -08:00
Michael Goderbauer
24d434d156
Revert "Revert "Fix _LateInitializationError for RenderObjectElement.renderObject (#70974)" (#73575)" (#73580) 2021-01-08 12:49:04 -08:00
Michael Goderbauer
edfb6305d8
Revert "Fix _LateInitializationError for RenderObjectElement.renderObject (#70974)" (#73575)
This reverts commit c243d834ce41bc5d279b0264efbc6b3c9e0df53d.
2021-01-08 10:24:10 -08:00
Michael Goderbauer
c243d834ce
Fix _LateInitializationError for RenderObjectElement.renderObject (#70974) 2021-01-08 09:35:10 -08:00
Todd Volkert
a1070e4f4c
Revert "Remove duplicate code in Element.rebuild() and BuildOwner.buildScope() (#71940)" (#72120)
This reverts commit c8f07aad563d9460eac0074be0a24a38158239af.
2020-12-10 23:24:21 -08:00
Todd Volkert
c8f07aad56
Remove duplicate code in Element.rebuild() and BuildOwner.buildScope() (#71940)
Element.rebuild() and BuildOwner.buildScope() both had code to
manager the `BuildOwner._debugCurrentBuildTarget` state variable.
Unfortunately, only one of the two places was using a try/finally
to ensure that the state variable was restored even if an error
was thrown.

This creates a private method to unify the copy/pasted code.
2020-12-08 17:58:28 -08:00
Todd Volkert
7ec3f6bdf9
Make FocusManager configurable in BuildOwner (#71872) 2020-12-08 12:42:39 -08:00
Michael Goderbauer
7a3a29e71f
Fixes Intrinsics for RenderParagraph and RenderWrap (#70656) 2020-11-20 17:24:58 -08:00
Darren Austin
7ce0dce2e5
Migrate even more Material framework tests to null safety. (#67849) 2020-10-12 11:30:26 -07:00
Alexandre Ardhuin
b007a81ad4
Reland "Nnbd widgets" (#65528)
* Reland "Nnbd widgets (#64672)"

This reverts commit 127e67902e8bbb0dcbfb3351b8fd00f7cbdf0178.

* remove non-nullable enforcement on AsyncSnapshot

* make data param non-nullable for AsyncSnapshot.withData

* make some Text params non-nullable
2020-09-15 16:42:00 +02:00
Michael Goderbauer
127e67902e
Revert "Nnbd widgets (#64672)" (#65488)
This reverts commit e682ec711a8c05fe78157595240b392de339fa32.
2020-09-09 15:18:54 -07:00
Alexandre Ardhuin
e682ec711a
Nnbd widgets (#64672)
* migrate widget to nullsafety

* remove double blank line after license

* address review comments in actions.dart

* nullable ObjectKey.value

* use local variable oldElement

* make State.build non-nullable

* make State.context non-nullable

* newline at eof

* make ProxyWidget.child non-nullable

* make _InactiveElements.debugContains non-nullable

* make Element.depth non-nullable

* make ProxyElement.build non-nullable

* make StatefulElement.state non-nullable

* remove 'Notice that'

* avoid cast of list in RenderObjectElement.updateChildren

* make IndexedSlot.value non-nullable

* avoid cast of list in MultiChildRenderObjectElement.mount

* make some WidgetsApp parameters non-nullable

* hitTest take non-nullable position

* make ScrollableState.position non-nullable

* use _pixels instead of pixels

* make ViewportOffset.pixels non-nullable

* make param and return type of IndexedWidgetBuilder non-nullable

* unused_import

* make context param non-nullable for Builder in animated_list.dart

* make ScrollMetrics.viewportDimension non-nullable

* make ScrollMetrics.{min,max}ScrollExtent non-nullable

* make _Location.file non-nullable

* _WidgetForTypeTests.createElement throw UnimplementedError

* update _NullWidget.build error message

* make _ShortcutsState.manager non-nullable

* Fix childCount issues for NNBD

* fix childCount computation on web

* increase max value on js side to compute childCount

* make aspect parameter of dependOnInheritedWidgetOfExactType nullable

* merge has{min,max}ScrollExtent into hasScrollExtents

* update focus_manager.dart

* address review comments in icon.dart

* address review comments in image.dart

* address review comments in routes.dart

* address review comments in scroll_activity.dart

* update doc comments

* make UserScrollNotification.direction non-nullable and required

* rename hasScrollExtents to hasContentDimensions

* unnecessary late

Co-authored-by: Ian Hickson <ian@hixie.ch>
2020-09-09 10:52:27 +02:00
xubaolin
aa1acd8e54
Ignore unmounted parent when _debugVerifyGlobalKeyReservation for GlobalKey check (#62323)
* Ignore unmounted parent when _debugVerifyGlobalKeyReservation (#62055)

* Ignore unmounted parent when _debugVerifyGlobalKeyReservation (#62055)

* Ignore unmounted parent when _debugVerifyGlobalKeyReservation (#62055)

* Ignore unmounted parent when _debugVerifyGlobalKeyReservation (#62055)

* Ignore unmounted parent when _debugVerifyGlobalKeyReservation (#62055)

* Ignore unmounted parent when _debugVerifyGlobalKeyReservation (#62055)
2020-07-30 10:07:18 -07:00
liyuqian
42e02d60d3
Reland non-breaking "Add clipBehavior to widgets with clipRect #55977" (#59364)
* Revert "Revert "Add clipBehavior to widgets with clipRect (#55977)" (#58344)"

This reverts commit 1d395c5e187370f2838bb043d3b438029b484bfc.

* Add missed Overflow
2020-06-17 10:57:40 -07:00