11 Commits

Author SHA1 Message Date
Ming Lyu (CareF)
409a5e5963
FrameTiming build start timestamp fix and add vsync start timestamp (#20229) 2020-08-07 19:41:01 -07:00
Gary Qian
3a96741247
Platform resolved locale and Android localization refactor (#18645) 2020-06-16 04:29:50 -07:00
vsmenon
0ef67b5e74
opt out dart:ui from nnbd (#16473)
* opt out dart:ui from nnbd

* Annotate tests as well
2020-02-20 11:04:00 -08:00
Dan Field
6bd0ef3dfe
dart analysis of tests, cleanup (#13033) 2019-10-09 15:13:29 -07:00
liyuqian
4243324a03
Revert "Add a BroadcastStream to FrameTiming (#11041)" (#11841)
This reverts commit e97ed36e580c9b4c4a3d768cfe1a520f7bf8161d.

Reason for revert: Stream is considered a bad API: https://github.com/flutter/engine/pull/11041#issuecomment-526892247
2019-09-05 10:41:55 -07:00
liyuqian
e97ed36e58
Add a BroadcastStream to FrameTiming (#11041)
Without this, developers have to override `onReportTimings` to listen for `FrameTiming`.
That can potentially break previous `onReportTimings` listeners if they forget to call
the old listener in their new callback.

This PR replaces the similar RP in the framework: https://github.com/flutter/flutter/pull/38574

Once this PR landed, we'll have to create another framework PR to use the stream to replace
`onReportTimings` usages.

Once that's done, we can then propose the breaking change of removing the deprecated
`onReportTimings`.
2019-08-19 10:52:16 -07:00
liyuqian
9f088c65ee
Add onReportTimings and FrameRasterizedCallback API (#8983)
Using it, a Flutter app can monitor missing frames in the release mode, and a custom Flutter runner (e.g., Fuchsia) can add a custom FrameRasterizedCallback.

Related issues:
https://github.com/flutter/flutter/issues/26154
https://github.com/flutter/flutter/issues/31444
https://github.com/flutter/flutter/issues/32447

Need review as soon as possible so we can merge this before the end of May to catch the milestone.

Tests added:
* NoNeedToReportTimingsByDefault
* NeedsReportTimingsIsSetWithCallback
* ReportTimingsIsCalled
* FrameRasterizedCallbackIsCalled
* FrameTimingSetsAndGetsProperly
* onReportTimings preserves callback zone
* FrameTiming.toString has the correct format

This will need a manual engine roll as the TestWindow defined in the framework needs to implement onReportTimings.
2019-06-06 10:42:48 -07:00
Dan Field
2b1f9925e4
new lints (#8849)
Dart lints added:
* Avoid optional new
* Avoid optional const
* Prefer single quotes
* Prefer default assignment `=`
2019-05-07 16:10:21 -07:00
Dan Field
6179ac6377
fix up analysis for Dart in Engine (#7404)
* fix up analysis for Dart in Engine, particularly for tests
2019-01-11 13:50:58 -08:00
Michael Goderbauer
70a1106b50
Unify copyright lines (#6757) 2018-11-07 12:24:35 -08:00
Yegor
926c9a581f preserve Window callback zones (#3817)
* preserve Window callback zones

Run Window callbacks in the zone they are registered in. This is consistent with how other native API work, such as `scheduleMicrotask`, `Timer`, and `dart:io`. This also enables the developers to use the `Zone` API to capture and log unhandled Dart errors.

* refactor wrapping

* new line

* fewer if checks; group getters/setters/fields

* inline _invokeOnPointerDataPacket
2017-06-26 15:08:43 -07:00