Two becomes one (#8253)

Rename all the "2" classes related to scrolling to remove the "2". Now that the
old scrolling code is gone, we don't need to use the suffix.
This commit is contained in:
Adam Barth
2017-02-17 14:06:15 -08:00
committed by GitHub
parent e2ff674f31
commit e0b12ca17e
64 changed files with 364 additions and 364 deletions

View File

@@ -40,7 +40,7 @@ class ShrinePage extends StatefulWidget {
class ShrinePageState extends State<ShrinePage> {
int _appBarElevation = 0;
bool _handleScrollNotification(ScrollNotification2 notification) {
bool _handleScrollNotification(ScrollNotification notification) {
int elevation = notification.metrics.extentBefore <= 0.0 ? 0 : 1;
if (elevation != _appBarElevation) {
setState(() {
@@ -144,7 +144,7 @@ class ShrinePageState extends State<ShrinePage> {
]
),
floatingActionButton: config.floatingActionButton,
body: new NotificationListener<ScrollNotification2>(
body: new NotificationListener<ScrollNotification>(
onNotification: _handleScrollNotification,
child: config.body
)

View File

@@ -126,7 +126,7 @@ Future<Null> runSmokeTest(WidgetTester tester) async {
for (String routeName in routeNames) {
Finder finder = findGalleryItemByRouteName(tester, routeName);
Scrollable2.ensureVisible(tester.element(finder), alignment: 0.5);
Scrollable.ensureVisible(tester.element(finder), alignment: 0.5);
await tester.pump();
await tester.pumpUntilNoTransientCallbacks();
await smokeDemo(tester, routeName);