Unverified Commit 4452bd0a authored by Yegor's avatar Yegor Committed by GitHub

Revert "Revert "make LocalHistoryRoute a proper super-mixin (#23382)"… (#23482)

* Revert "Revert "make LocalHistoryRoute a proper super-mixin (#23382)" (#23430)"

This reverts commit 3bbb3082.

This relands the LocalHistoryRoute change. The analyzer bug has been fixed.

* mark dartdocs as flaky
parent 3b137611
...@@ -459,6 +459,7 @@ tasks: ...@@ -459,6 +459,7 @@ tasks:
Tracks how many members are still lacking documentation. Tracks how many members are still lacking documentation.
stage: devicelab stage: devicelab
required_agent_capabilities: ["linux/android"] required_agent_capabilities: ["linux/android"]
flaky: true
flutter_test_performance: flutter_test_performance:
description: > description: >
......
...@@ -306,16 +306,14 @@ class LocalHistoryEntry { ...@@ -306,16 +306,14 @@ class LocalHistoryEntry {
} }
} }
/// A route that can handle back navigations internally by popping a list. /// A mixin used by routes to handle back navigations internally by popping a list.
/// ///
/// When a [Navigator] is instructed to pop, the current route is given an /// When a [Navigator] is instructed to pop, the current route is given an
/// opportunity to handle the pop internally. A LocalHistoryRoute handles the /// opportunity to handle the pop internally. A `LocalHistoryRoute` handles the
/// pop internally if its list of local history entries is non-empty. Rather /// pop internally if its list of local history entries is non-empty. Rather
/// than being removed as the current route, the most recent [LocalHistoryEntry] /// than being removed as the current route, the most recent [LocalHistoryEntry]
/// is removed from the list and its [LocalHistoryEntry.onRemove] is called. /// is removed from the list and its [LocalHistoryEntry.onRemove] is called.
/// mixin LocalHistoryRoute<T> on Route<T> {
/// This class is typically used as a mixin.
abstract class LocalHistoryRoute<T> extends Route<T> {
List<LocalHistoryEntry> _localHistory; List<LocalHistoryEntry> _localHistory;
/// Adds a local history entry to this route. /// Adds a local history entry to this route.
......
...@@ -12,7 +12,7 @@ final List<String> results = <String>[]; ...@@ -12,7 +12,7 @@ final List<String> results = <String>[];
Set<TestRoute> routes = HashSet<TestRoute>(); Set<TestRoute> routes = HashSet<TestRoute>();
class TestRoute extends LocalHistoryRoute<String> { class TestRoute extends Route<String> with LocalHistoryRoute<String> {
TestRoute(this.name); TestRoute(this.name);
final String name; final String name;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment